I am able to successfully setup a recurring payment using a credit card and ARB, but once I change up the code to use
a checking account, I get an error stating 'payment information is required'.
My code is:
$subscription = new AuthorizeNet_Subscription;
$subscription->name = "PHP Monthly Magazine";
$subscription->intervalLength = "1";
$subscription->intervalUnit = "months";
$subscription->startDate = "2014-08-12";
$subscription->totalOccurrences = "12";
$subscription->amount = "12.99";
$subscription->billToFirstName = "Rasmus";
$subscription->billToLastName = "Doe";
$subscription->accountType = "checking";
$subscription->routingNumber = "123456789";
$subscription->accountNumber = "12345345345";
$subscription->nameOnAccount = "Rasmus Doe";
$subscription->echeckType = "WEB";
$subscription->bankName = "Bank of America";
Per the documenation I have all the necessary fields for a bank account, so what am I missing?
07-13-2014 11:38 AM
If you using the SDK
the field name might be different
07-13-2014 01:03 PM
As Raynor indicated, this appears to just be a variable name issue. Each of the bank account related fields int he Subscription Object is preceded by "bankAccount". The specifc lines to change in your code would be as follows:
$subscription->bankAccountAccountType = "checking"; $subscription->bankAccountRoutingNumber = "123456789"; $subscription->bankAccountAccountNumber = "12345345345"; $subscription->bankAccountNameOnAccount = "Rasmus Doe"; $subscription->bankAccountEcheckType = "WEB"; $subscription->bankAccountBankName = "Bank of America";
07-16-2014 03:29 PM