AuthorizeNet / sample-code-php

This repository contains working code samples which demonstrate php integration with the Authorize.Net API
MIT License
175 stars 197 forks source link

sample-code-php/PaymentTransactions/create-an-accept-payment-transaction.php #128

Closed majidabbasi96 closed 5 years ago

majidabbasi96 commented 5 years ago

Hello,

When I am using this function with my API Login ID and Transaction Key I get the following result: Transaction Failed Error Code : E00001 Error Message : An error occurred during processing. Please try again.

After that I tested requirements and get the following results:

  1. I send request to https://apitest.authorize.net/xml/v1/request.api with curl to ensure that it works and get the following result: {"messages":{"resultCode":"Error","message":[{"code":"E00003","text":"Root element is missing."}]}}

  2. Send request to https://www.howsmyssl.com/a/check to check TLS version and get the following result: The connection uses TLS 1.2

  3. According to the https://community.developer.authorize.net/t5/The-Authorize-Net-Developer-Blog/Request-for-Comments-A..., that you sent I am going share available versions of each module with you: PHP Version: 7.1.22 OpenSSL: 1.0.2 cURL: 7.34.0

ashtru commented 5 years ago

@majidabbasi96 One scenario where we get E00003is when the request sent is not an xml object. So, when we hit https://apitest.authorize.net/xml/v1/request.api without a request body, we get this response. It's possibly not a TLS issue.

Can you please share the request object (barring the credentials part ) you are trying to send, how it is different from the sample for accept transaction?

And since, every Accept payment requires a unique token (valid for 15 minutes), can you share how you are getting the value set for token in Line 23 $opaqueData->setDataValue ?

gnongsie commented 5 years ago

Hi,

I'm closing this issue due to inactivity. Kindly reopen the issue when further information becomes available.