I have been using the same code for the past year or so with no issues, and have validated many transactions through the API with no issue. My script creates a payment profile, then a customer profile, and afterwards creates a recurring subscription.
I recently came across one contact that was getting the following error:
The following script is running that is getting the error:
define("AUTHORIZENET_LOG_FILE", "../$subdomain/authorize.log"); define("MERCHANT_TRANSACTION_KEY", authorize_transaction_key); define("MERCHANT_LOGIN_ID",authorize_login_id); // Common setup for API credentials $merchantAuthentication = new AnetAPI\MerchantAuthenticationType(); $merchantAuthentication->setName(MERCHANT_LOGIN_ID); $merchantAuthentication->setTransactionKey(MERCHANT_TRANSACTION_KEY); $refId = 'ref' . time(); // Create the payment data for a bank account $bankAccount = new AnetAPI\BankAccountType(); $bankAccount->setAccountType($read_AccountType); $bankAccount->setRoutingNumber($read_RoutingNumber); $bankAccount->setAccountNumber($read_AccountNumber); $bankAccount->setNameOnAccount($read_NameOnAccount); $bankAccount->setEcheckType('WEB'); $bankAccount->setBankName($read_BankName); $paymentBankAccount = new AnetAPI\PaymentType(); $paymentBankAccount->setBankAccount($bankAccount); // Create the Bill To info $billto = new AnetAPI\CustomerAddressType(); $billto->setFirstName($read_FirstName); $billto->setLastName($read_LastName); $billto->setCompany($read_Company); $billto->setAddress($read_Address); $billto->setCity($read_City); $billto->setState($read_State); $billto->setZip($read_Zip); $billto->setCountry($read_Country); // Create a Customer Profile Request // 1. create a Payment Profile // 2. create a Customer Profile // 3. Submit a CreateCustomerProfile Request // 4. Validate Profile ID returned // Create Payment Profile $paymentprofile = new AnetAPI\CustomerPaymentProfileType(); $paymentprofile->setCustomerType('individual'); $paymentprofile->setBillTo($billto); $paymentprofile->setPayment($paymentBankAccount); $paymentprofiles[] = $paymentprofile; // Create Customer Profile $customerprofile = new AnetAPI\CustomerProfileType(); $customerprofile->setDescription("Profile created by InfusedGym"); $customerprofile->setMerchantCustomerId($read_ContactId); $customerprofile->setEmail($read_Email); $customerprofile->setPaymentProfiles($paymentprofiles); // Send Request $request = new AnetAPI\CreateCustomerProfileRequest(); $request->setMerchantAuthentication($merchantAuthentication); $request->setRefId($refId); $request->setProfile($customerprofile); $controller = new AnetController\CreateCustomerProfileController($request); $response = $controller->executeWithApiResponse( \net\authorize\api\constants\ANetEnvironment::PRODUCTION);
I verified the bank account info and it was indeed valid. I was able to successfully run the charge through the virtual terminal. So I'm super confused. Authorize.net support advised me to set validation to "None" by adding the following code:
$validationmode = "None"; $request->setValidationMode($validationmode);
Upon doing so, I now get this error below:
So while I can add the contact's billing manually through the authorize.net terminal, I'm just confused why this contact out of many others I have run is having validation issues, and why I cannot turn validation off. Any help is greatly appreciated. Thank you.
03-21-2017 12:22 PM
Hi David,
The proper value for validationMode to turn off validation would be "none" (note the capitalization). It would be useful to know if you get the same error with it sent to "none". However, turning off validation wouldn't be a solution, just a troubleshooting step. Additionally, I'm not sure validationMode is even applicable for eCheck.
Our response code lookup tool indicates that an error code of 128 corresponds to "The customer's financial institution does not currently allow transactions for this account". However, you can do the charge via the virtual terminal, so either virtual terminal doesn't do the same level of checking, or something else is going on.
What happens if you try to create a profile in the merchant interface, using the same exact data?
03-21-2017 01:18 PM
Hey Aaron. Changing the value to "none" once again gives me the previous error E00027.
I was able to successfully create a payment profile inside the authorize.net portal.
What is puzzling is that in the past I made a profile through the API for this same contact. I have other contacts that I have made profiles for since this one with no issue.
Is this just some bizarre anomaly?
03-21-2017 01:33 PM
@DavidFFA wrote:
Is this just some bizarre anomaly?
Yes?
That's not a good enough answer really, but looking any further into this would require us to potentially get the offending data from you to try it here, or to go digging deep into logs on our end. If it doesn't happen again, we'll just assume something got garbled on that one request. If it does every pop up again, though, let us know ASAP.
03-21-2017 02:49 PM