This question was asked at StackOverflow but did not receive an answer so I am asking it here.
I'm having some trouble making sense of the Transaction Details API. I'll try my best to be brief.
The only practical way of pulling transaction status updates from authorize (without using their 'silent post' feature, which seems like a big bag of nightmares* ), is to get a batch list of settled transactions (for let's say a day) and then pull transaction lists for every settled batch. Eg:
public function getTransactionsForDay($month = false, $day = false, $year = false) { $transactions = array(); $month = ($month ? $month : date('m')); $day = ($day ? $day : date('d')); $year = ($year ? $year : date('Y')); $firstSettlementDate = substr(date('c',mktime(0, 0, 0, (int)$month, (int)$day, (int)$year)),0,-6); $lastSettlementDate = substr(date('c',mktime(0, 0, 0, (int)$month, (int)$day, (int)$year)),0,-6); $response = $this->getSettledBatchList(true, $firstSettlementDate, $lastSettlementDate); $batches = $response->xpath("batchList/batch"); foreach ($batches as $batch) { $batch_id = (string)$batch->batchId; $request = new AuthorizeNetTD; $tran_list = $request->getTransactionList($batch_id); $transactions = array_merge($transactions, $tran_list->xpath("transactions/transaction")); } return $transactions; } $request = new AuthorizeNetTD; $transactions = $request->getTransactionsForDay(12, 8, 2010); $this->assertTrue(is_array($transactions));
Yet, there's a multitude of possible transaction statuses.
These appear to be 'final' and unchangeable:
The following appear to be 'pending' statuses:
These, I'm not sure about:
The getUnsettledTransactionList just dumps the last 1000 'unsettled' transactions on your lap, including declined, error, etc -- making it pretty unreliable, not mention you have to parse that junk. So, my questions are:
- What's up with the last four statuses above? Should I expect those to change or not?
- Which of these go into a 'settled' batch? (`settlementError` AND `settledSuccessfully`? JUST `settledSuccessfully`? )
- Do recurring billing transactions ([documentation here][2]) even show up in the settled batches?
- Is there really no way to pull just the 'pending' transactions from authorize, ignoring all the irrelevant `error`, `declined`, etc ones? It seems necessary for recurring billing -- because otherwise, an app (in lieu of a transaction id) has no way of knowing if there's a problem with a subscription transaction, until enough time passes that you can safely assume it should have showed up in a settled batch.
* due to the two second timeout, fail-and-never-talk-to-you-again policy, plus having to rely on users to properly configure their settings*
Solved! Go to Solution.
07-06-2011 07:54 AM
I'm working towards making more of an official document for defining these fields, but I thought I would post what I have so far:
BasicTransaction Statuses
I don't think these statuses need any further explanation, but let me know if I'm mistaken.
Fraud Detection Suite (FDS or AFDS) Specific Responses
Both of these statuses indicate that a transaction is pending manual review by the merchant.
eCheck Specific Responses
Other Errors
Transitional Transaction Statuses
These transaction statuses occur only as a transaction is taking place. They should not be returned by the Transaction Details API.
Legacy Statuses
These transaction statuses relate to services that we have not offered for over 3 years. Because an Authorize.Net merchant account stores only 2-3 years of history, you will not see these statuses actually returned in any normal operation.
08-19-2011 04:10 PM
A part of the confusion with the transaction statuses is that the transaction status object is built off of a similar object that we use internally and includes ever possible transaction status in our system. Some of these status will effectively never actually be seen by you as an external developer. I've checked our public knowledge base and confirmed that we don't currently have a good list of all of the transaction statuses, so I'm working on creating one for you. I'm working with our internal developers just to confirm some details on the statuses and I'll reply with that list as soon as I can. I can answer the rest of your questions right now.
Which of these go into a 'settled' batch? (`settlementError` AND `settledSuccessfully`? JUST `settledSuccessfully`? )
Within Authorize.Net, all transactions are moved into a batch when the transaction state is final. This is a significant difference in the Authorize.Net definition of a batch and the definition used by most merchant services provider. Because all of our reporting is organized into batches, it is important that all of your transactions ultimately end up in a batch.
Do recurring billing transactions ([documentation here][2]) even show up in the settled batches?
Yes, the transactions initiated by the Automated Recurring Billing (ARB) system are treated no different from any other transaction once they are created.
Is there really no way to pull just the 'pending' transactions from authorize, ignoring all the irrelevant `error`, `declined`, etc ones? It seems necessary for recurring billing -- because otherwise, an app (in lieu of a transaction id) has no way of knowing if there's a problem with a subscription transaction, until enough time passes that you can safely assume it should have showed up in a settled batch.
There is currently no way to pull a list of only successful unsettled transactions or of pulling only transactions that are associated with a specific ARB subscription. We are aware of this limitation and have a few ideas of how to address it, but unfortunately the only 100% reliable way of checking ARB transactions programmatically is to pull the whole batch after settlement.
07-08-2011 03:07 PM
I'm working towards making more of an official document for defining these fields, but I thought I would post what I have so far:
BasicTransaction Statuses
I don't think these statuses need any further explanation, but let me know if I'm mistaken.
Fraud Detection Suite (FDS or AFDS) Specific Responses
Both of these statuses indicate that a transaction is pending manual review by the merchant.
eCheck Specific Responses
Other Errors
Transitional Transaction Statuses
These transaction statuses occur only as a transaction is taking place. They should not be returned by the Transaction Details API.
Legacy Statuses
These transaction statuses relate to services that we have not offered for over 3 years. Because an Authorize.Net merchant account stores only 2-3 years of history, you will not see these statuses actually returned in any normal operation.
08-19-2011 04:10 PM
08-20-2011 06:34 PM
Hi Trevor,
Did you have a chance to create an official document after you finalized your research? Just wondering whether you have any new info since this post...
Thanks
03-07-2012 10:21 AM