We are continuously looking for the possible solution of our problem, though we tried follow the api documentation from VTEX for transaction process and faced a new error on the way. Let us describe the flow what we did:
Create a Gateway Affiliation on payment settings section for service “CCAvenue”, also mentioned the appKey and appToken for the same.
Created a payment condition for CCAvenue with no special conditions.
Called the API to create a new transaction “https://{accountName}.vtexpayments.com.br/api/pvt/transactions”
After receiving a newly created transaction Id , we called a API to send the payment information to VTEX i.e: “https://{accountName}.vtexpayments.com.br/api/pub/transactions/{transactionId}/payments” Received (201 Response)
The fourth and last step to create a new transaction, we called the API “https://{accountName}.vtexpayments.com.br/api/pvt/transactions/{transactionId}/authorization-request” , but here we got an error
{
"error": {
"code": "1403",
"message": "Authorization is pending for payments with Ids = 5311514DB8A04446B2F787E14F021515. A new authorization execution is needed for these payments.",
"exception": null
}
}
At this point , we are not sure how we can make a payment with CCavenue payment connector, also how we can solve this error.
IMPORTANT: In simple words, I want to make a payment using CCAvenue gateway affilation using vtex api, but API documentation is not useful. Also i am not using VTEX Client for my app store but created a custom react app which will call the VTEX rest api to do all actions (like “Get all products and sku from catalog”, “Get user/customer details”, “Add product to the cart”)
Hi @Saito ,
Thanks for your response,
I am also using the same json object,also even getting 201 on this particular request, but getting error on next step of transaction. i.e: https://{accountName}.vtexpayments.com.br/api/pvt/transactions/{transactionId}/authorization-request
Secondly, thanks for the similar topic link. but my main objective is to implement payment gateway through CCAvenue gateway affiliation in my custom react app (not vtex store), so i just want to understand the payment flow and how payment window will open on my custom app.
Hello @mohit.patel I just got a random example from the forum, so it´s not my approach.
Anyway, I found these 2 links that might help you with the “transaction API”