I am trying to use the new ApplePayJS functionality to submit a payment through Safari.
I AM NOT USING AN APP. I AM DOING THIS IN SAFARI
(This is a brand new feature as of iOS10 - it was not previously possible to use ApplePay in Safari but now it is).
I used the sample code from here https://github.com/AuthorizeNet/sample-code-csharp/blob/master/MobileInappTransactions/CreateAnApple...
All my certificates work fine and I get a token from Apple that I try to send in the opaqueData field in this sample code file. I am taking the data from token.paymentData.data .
However whatever I do I get a frustratingly useless Error 153 : There was an error processing the payment data.
So don't know if I have an issue or Authorize.NET is not set up for ApplePayJS payments yet. Maybe they need to turn a switch on.
I have tried in both the sandbox and the production environments (for Apple sandbox you need to log out of iCloud and log into a dummy account). I get this same error whatever I do.
I am wondering if the dataDescriptor parameter needs to be different for ApplePayJS compared to ApplePay for apps. For instance is there something like "COMMON.APPLE.WEB.PAYMENT" instead of "COMMON.APPLE.INAPP.PAYMENT"?
I have been very careful in configuring everything as needed, and now I'm completely stuck and frustrated.
<createTransactionResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd">
<messages>
<resultCode>Error</resultCode>
<message>
<code>E00027</code>
<text>The transaction was unsuccessful.</text>
</message>
</messages>
<transactionResponse>
<responseCode>3</responseCode>
<authCode />
<avsResultCode>P</avsResultCode>
<cvvResultCode />
<cavvResultCode />
<transId>0</transId>
<refTransID />
<transHash>0F9A49F3737ACDD39985D027C40D9C63</transHash>
<testRequest>0</testRequest>
<accountNumber />
<accountType />
<errors>
<error>
<errorCode>153</errorCode>
<errorText>There was an error processing the payment data.</errorText>
</error>
</errors>
<transHashSha2 />
</transactionResponse>
</createTransactionResponse>
Token I get back from Apple (this one is NOT sandbox). I try to use the paymentData.data as my opaqueData:
{"paymentData":{"data":"IIybAsjcfZeh3rBdiDw89HOaV0fl7+G2341C36bvivhAeFOMNtjZ4DnzOx5VhIT3H3ihXdofnz6MgRDDCBWRGXjeHzJoxqVzKjRQn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b3EYKL0xcIqcRDD5tlIPAaVPj5tHYN5qYlyX0BC30=","ephemeralPublicKey":"MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEqbtW8gS4qY1SYqgEf55+Q0guxiBbuo6POFtDc+Fmr96dXfdzPruu8P8iKibg2ZYDoXFWXpSVEMdCiZoMz0X66g==","transactionId":"4a90cba9a8c169cfa610ed5be96be28b82e40b70e8a69fc104816f7f494901f0"},"version":"EC_v1"},"transactionIdentifier":"4A90CBA9A8C169CFA610ED5BE96BE28B82E40B70E8A69FC104816F7F494901F0","paymentMethod":{"network":"AmEx","type":"credit","displayName":"AmEx 3002"}}
09-15-2016 07:06 PM