Payment Orders
Introduction
A Payment Order is an object representing the intention to process a payment.
Integration mode
You have two possible methods of integration.
1- Hosted Fields (recommended)
This is a mode where the input fields are displayed on your website. These fields are fully customizable and it avoids you to exit the conversion tunnel.
How to use it?
You have to use PayGreen JS (the documentation can be found here). The first step of the payment process is to request our Payment API for the creation of a Payment Order (PO). Then, the Payment Order ID must be set in PGJS attribute paymentOrderID
.
2- Hosted Page
This is a classic integration that redirects the end user to a PayGreen secure payment page.
How do you do it?
After making an API server call to create a Payment Order, you just have to redirect the end user to the url you will find in the attribute hosted_payment_url
.
Status
Payment Orders with instant
mode can have the following status :
status | description |
---|---|
pending | Set when the PO is created and waiting for an authorization |
authorized | Set when the PO is authorized, or partly authorized if partial_allowed is set to true |
successed | Set when the PO has been captured, or partly captured |
canceled | Set when the PO has been canceled |
refused | Set when the PO has been refused |
error | Set when a technical error has occurred |
expired | Set when the PO has reached its Time to live (TTL) |
Updated about 1 month ago