If you have specific terms of service you want to display and the payer to
approve during the payment process, you can do this by adding a
termsOfServiceUrl
to the urls
node of your paymentOrder
request.
The url will appear as a clickable hyperlink below the pay button in the payment UI. The terms of service open in a separate tab when clicked.
Request
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
POST /psp/paymentorders HTTP/1.1
Host: api.externalintegration.payex.com
Authorization: Bearer <AccessToken>
Content-Type: application/json;version=3.1/3.0/2.0 // Version optional for 3.0 and 2.0
{
"urls": {
"hostUrls": [ "https://example.com", "https://example.net" ],
"completeUrl": "https://example.com/payment-completed",
"cancelUrl": "https://example.com/payment-cancelled",
"callbackUrl": "https://api.example.com/payment-callback",
"termsOfServiceUrl": "https://example.com/termsandconditions.pdf",
"logoUrl": "https://example.com/logo.png"
}
}
}
Field | Type | Description | |
---|---|---|---|
check | urls |
object |
The urls object, containing the URLs relevant for the payment order. |
check | termsOfServiceUrl |
string |
The URL to the terms of service document which the payer must accept in order to complete the payment. HTTPS is a requirement. |