Skip to content
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

ListOfAUDetailsType is incorrectly parsing JSON response #151

Open
IDSeal opened this issue Jul 19, 2019 · 0 comments
Open

ListOfAUDetailsType is incorrectly parsing JSON response #151

IDSeal opened this issue Jul 19, 2019 · 0 comments

Comments

@IDSeal
Copy link

IDSeal commented Jul 19, 2019

When running a GetAUJobDetailsRequest I am receiving a correct total amount, but both AuUpdate and AuDelete are empty. After digging into the raw response, I can see clearly that the auDetails response is populated.

More digging revealed that the response is intended to be delineated into AuUpdate and AuDelete, but there appears to be no code that handles this delineation, so even though there are valid results, the GetAUJobDetailsRequest returns empty values for AuUpdate and AuDelete.

I was able to fix this by adding the following to ListOfAUDetailsType::set() on line 177, which then allows the set to proceed to the custom class parsing for the result set.

            $data = array('AuUpdate' => $data);

I know this is a hack, so I didn't want to submit it as a PR. I imagine there is some missing logic for delineating out which AuDetails is an AuUpdate vs an AuDelete. I was going to build a preparser in the ListOfAUDetailsType class that determines which is which based on the reason_code returned for each AuDetail item.

Can the Authnet team either patch in the correct parsing logic, or provide more detail on the intentions in this ticket so that I may build it.


See the following link that describes this issue submitted by another user from over a year ago: https://community.developer.authorize.net/t5/Integration-and-Testing/Account-Updater-Job-Details-response-data-structure-does-not/td-p/61484

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant