-
Notifications
You must be signed in to change notification settings - Fork 402
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ARB Subscription Request API Call missing option #280
Comments
Looks like you'd also need to add a getter to get the |
@zenphp did you get this to work? Would you share your code please? I need help. Did you create a arbTransactionsListType class and a arbTransactionType? |
@enterlight I have not had a chance to circle back on this. Will try to do so this weekend and let you know where I end up. |
I suspect that includeTransactions support has been implemented in the underlying Authorize.net API; however, the PHP SDK is woefully out of date. And no sample code has been forthcoming from Authorize.net (earliest request is from June 2016) So, For my purposes, I forked the PHP SDK: I implemented get ARB Transaction from Get Subscription sufficient for what I needed. Specifically, I modified the following 4 files: Immediately after setting setSubscriptionID in the sample code (https://github.com/AuthorizeNet/sample-code-php/blob/master/RecurringBilling/get-subscription-status.php) add the following:
Note: I have used TransactionDetailsType whereas I suspect the actual type should be something like ARBTransactionType, but the yaml definition is missing and I have not defined it The result is for now not all transaction data is populated; HOWEVER, transId IS populated and this is good enough to make an additional API call to get Transaction Details. Feel free to have at it. Code provided AS IS to the Community. YMMV |
I've finally worked with what @sjordan1975 provided and cleaned things up. I am using this code in production right now, and have submitted a PR to have it included in the base api. https://github.com/CGX-Development/sdk-php/tree/dev-1.9.4 |
includeTransactions has been added to the ARBGetSubscription request as part of the latest release! |
This is great news!! Thanks |
Working with the recurring billing portions of the API, I am trying to retrieve recent transactions related to a subscription. The documentation (https://developer.authorize.net/api/reference/#recurring-billing-get-subscription-status) for ARBGetSubscriptionRequest states that there is an optional parameter
includeTransactions
that will return recent transactions associated with the subscription.This does not seem to be present in the PHP SDK. Looking in the code (https://github.com/AuthorizeNet/sdk-php/blob/master/lib/net/authorize/api/contract/v1/ARBGetSubscriptionRequest.php) there is no property to store the value nor any accessors to set/retrieve the value.
Manually adding them, and updating the YML definition (https://github.com/AuthorizeNet/sdk-php/blob/master/lib/net/authorize/api/yml/v1/ARBGetSubscriptionRequest.yml) to define the property allows it to be set and transmitted, but no data appears to be returned to the client in the response.
The appropriate section of my application code:
Am I missing something? Or is the API missing something?
The text was updated successfully, but these errors were encountered: