开发者

Authorize.net: getTransactionDetails in PHP

I'm using SIM. I perform a transaction, but Authorize.net doesn't return all the transaction details that I need in the response. So I have to manually make a call for the details after the transaction.

This is the API I found

I'm unfamiliar with SOAP. How can I do this开发者_如何学JAVA?


Presumably:

$soap = new SoapClient('https://api.authorize.net/soap/v1/Service.asmx?WSDL');
var_dump($soap->GetTransactionDetails(
    (object)array(
       'merchantAuthentication' => (object)array(
           'name'           => $name,
           'transactionKey' => $key),
       'transId' => $your_transaction_id)));

Examing the output of $soap->__getTypes() && $soap->__getFunctions() usually tells you all you need to know.


There is probably no reason for you to be using SIM. Use direct post it is much easier.

In fact, this is how the supplied Authorize.net PHP SDK works. So use their sdk and call the function directly.

Compared to some gateways, authorize.net has great documentaion. So learn to read the docs, it will save lots of headache.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜