Skip to content

Sending clientId causes E00013 "The field is invalid." #474

@WillCodeForCats

Description

@WillCodeForCats

I was suddenly getting an E00013 error response when it worked normally before. After some digging I figured out this problem appears to be caused by the PHP SDK sending a clientId in the request.

$this->apiRequest->setClientId("sdk-php-" . \net\authorize\api\constants\ANetEnvironment::VERSION);

I noticed this after comparing what the PHP SDK was generating for requests compared to the API documentation, and clientId is not listed anywhere in the API request field description. I cannot find any changelogs for the API that say this was a field that was removed, but clearly it doesn't like seeing it now and it wasn't a problem before. This line makes setClientId() method useless anyway since this overrides it if you try to set it to null when setting up AnetAPI\CreateTransactionRequest().

So if you're here because you're having this problem, delete (or comment out) this line in the execute() method of lib/net/authorize/api/controller/base/ApiOperationBase.php and see if that fixes the problem.

API fields ref: https://developer.authorize.net/api/reference/index.html#payment-transactions-charge-a-credit-card

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions