Checkout API
Create a checkout session that redirects your buyer to a GLODIPAY-hosted payment page, or returns a shareable payment link.
Endpoint: POST /v2/checkout
Content-Type: application/json
Request Parameters
| Field | Type | Required | Description |
|---|---|---|---|
| merchantId | String(1–50) | M | Merchant's ID. E.g. 1100000123 |
| orderRef | String(1–250) | M | Your transaction reference. E.g. ORDER-2026-001 |
| amount | Float | M | Invoice amount. Up to 2 decimal places. Must be within the amount limits of your merchant account (default 1–2000). E.g. 100.00 |
| currency | String(3) | M | ISO 4217 currency code supported by your assigned payment providers. E.g. USD |
| paymentMethod | String | M | Payment method(s) to display. E.g. checkout. See Payment Methods |
| callbackUrl | String(1–300) | M | Redirect URL after successful payment. Outside sandbox it must resolve to a public internet address. Not required for PAYMENT_LINK. E.g. https://yoursite.com/return. See Callback URL |
| notificationUrl | String(1–300) | M | Your server endpoint for IPN webhooks. Outside sandbox it must resolve to a public internet address. Not required for PAYMENT_LINK. E.g. https://yoursite.com/webhook |
| cancelUrl | String(1–300) | M | Redirect URL on cancellation. Not required for PAYMENT_LINK. E.g. https://yoursite.com/cancel |
| errorUrl | String(1–300) | M | Redirect URL on error. Not required for PAYMENT_LINK. E.g. https://yoursite.com/error |
| connectionMode | String | O | API, DIRECT_POST or PAYMENT_LINK. See Connection Modes |
| orderDescription | String(max:3000) | O | Short description shown on the checkout screen. HTML tags are removed. E.g. Order #2026-001 |
| metadata | String (JSON) | O | JSON-encoded string of key-value pairs, returned in IPN and query responses. E.g. "{\"orderId\":\"12345\"}" |
| paymentFilter | String (JSON) | O | JSON-encoded array of payment method types to exclude from the session. E.g. "[\"card\"]" |
| paymentSorter | String (JSON) | O | JSON-encoded ordered array controlling display order. Allowed values: card, paypal, ibanking_push, local_bank_transfer, wire_transfer, wallet, skrill, alipay, wechat, googlepay, applepay, crypto, apm. E.g. "[\"card\",\"wallet\"]" |
| feeBySeller | Number(0–100) | O | % of processing fee paid by merchant, up to 2 decimal places. 0 = buyer pays 100%. E.g. 50 |
| billingFirstName | String(max:255) | O | Billing first name. E.g. John |
| billingLastName | String(max:255) | O | Billing last name. E.g. Doe |
| billingEmail | String(max:255) | O | Buyer email address; must be a valid email. E.g. john.doe@example.com |
| billingStreet1 | String(max:255) | O | Billing street address line 1. E.g. 123 Main St |
| billingStreet2 | String(max:255) | O | Billing street address line 2. E.g. Suite 4B |
| billingCity | String(max:255) | O | Billing city. E.g. New York |
| billingState | String(2–255) | O | Billing state / province. E.g. NY |
| billingCountry | String | O | ISO 3166-1 alpha-2 country code. E.g. US. See Country Codes |
| billingPostalCode | String(max:25) | O | Postal / ZIP code. E.g. 10001 |
| billingPhoneCountryCode | String(max:10) | O | Phone country code. E.g. 1 for US |
| billingPhoneNumber | String(max:20) | O | Phone number. E.g. 5551234567 |
| brandName | String(1–255) | O | Override brand name on the hosted checkout screen. E.g. My Store |
| colorMode | String(1–255) | O | Up to 3 colors separated by ---. Accepts color names, HEX, or RGBA. E.g. #2e7d32---#e8f5e9---#81c784 |
| logoSource | String(1–255) | O | Override the logo on the hosted checkout screen. E.g. https://yoursite.com/logo.png |
| customerIp | String | O | IP address of the customer; must be a valid IP. E.g. 203.0.113.42 |
| websiteUrl | String(max:300) | O | Merchant website URL. E.g. https://yoursite.com |
| expiresAt | String | O | Session expiry, UTC, format YYYY-MM-DDTHH:mm:ss.ffffffZ (6-digit microseconds). Default: 24 hours. E.g. 2026-04-22T10:00:00.000000Z |
| signature | String(max:750) | M | RSA-MD5 signature. See Signature |
M = Mandatory, O = Optional. Callback, notification, cancel and error URLs also accept the snake_case names
callback_url,notification_url,cancel_url,error_url.
Defaults for optional fields
What the gateway applies when the field is omitted.
| Field | Default when omitted |
|---|---|
| connectionMode | API when the Content-Type header is exactly application/json (no charset parameter); otherwise DIRECT_POST |
| feeBySeller | The Fee by seller percentage configured for your merchant account in the Portal. The buyer's share is 100 − feeBySeller |
| expiresAt | 24 hours after the request |
| websiteUrl | callbackUrl — its host is what the allowed-domain check validates |
| brandName | Your company name as registered in the Portal |
| logoSource | Your merchant logo as uploaded in the Portal |
| colorMode | The default GLODIPAY theme |
| customerIp | The IP of the incoming request — with connectionMode: API that is your server's IP, so send customerIp explicitly if geo routing matters. The buyer's real IP is recorded when they open the checkout page |
| paymentFilter | [] — no payment method is excluded |
| paymentSorter | [] — methods keep the order configured for your merchant account |
| metadata | Absent — nothing extra is added to the IPN or query response |
| billing* fields | Empty — the buyer fills them in on the checkout page |
Response
connectionMode: API and PAYMENT_LINK
| Field | Type | Description |
|---|---|---|
| status | String | created on success, error on failure |
| transactionId | String (ULID) | GLODIPAY transaction ID |
| paymentLink | String | Redirect the buyer to this URL to complete payment |
| message | String | Human-readable message |
Success:
{
"status": "created",
"transactionId": "01jza90dy6w82dfrrqvadn5vs4",
"paymentLink": "https://payment.gpayprocessing.com/v2/checkout/01jza90dy6w82dfrrqvadn5vs4?...",
"message": "Payment Link created successfully"
}
Error (HTTP 200):
{
"status": "error",
"transactionId": null,
"paymentLink": null,
"message": "No active payment service providers found. Please contact support."
}
Possible message values:
| Message | When |
|---|---|
No active payment service providers found. Please contact support. | No active provider is available for the request |
Your region is not currently supported. Please contact support. | No provider supports the buyer's region |
This transaction amount is not supported. Please contact support. | No provider accepts the amount |
This payment provider does not support the checkout flow. Please contact support. | The selected provider has no hosted checkout |
Payment link is disabled. Please contact support. | PAYMENT_LINK is used but not enabled for your merchant account |
connectionMode: DIRECT_POST
The buyer's browser is redirected directly to the GLODIPAY-hosted checkout page. No JSON response is returned to your server.
connectionMode: PAYMENT_LINK
Same response as API. Requires payment links to be enabled for your merchant account. After payment the buyer lands on the GLODIPAY confirmation page — callbackUrl, cancelUrl and errorUrl are not used.
Request errors
Validation, signature, merchant status and domain checks return:
| connectionMode | Response |
|---|---|
API, PAYMENT_LINK | HTTP 500 {"status": "error", "message": "..."} |
DIRECT_POST | Redirect to errorUrl?payload={base64-encoded-json} |
Decoded errorUrl payload: status (rejected for validation errors, error otherwise), ref (your orderRef), msg (message), field (failing field, validation only). Validation stops at the first failing field.
Signature, merchant status and domain checks run before the connectionMode default is applied: send connectionMode explicitly to receive these errors as JSON, otherwise they are returned as a DIRECT_POST redirect.
| Message | Cause |
|---|---|
Invalid signature with merchantId: {merchantId} | Signature does not verify |
[{merchantId}] Merchant create transaction feature is not available. Status is {status} | Merchant account is not active |
Domain is not in the list of allowed domains | websiteUrl (or callbackUrl) host is not an allowed domain. Not checked in sandbox |
The {field} must resolve to a public internet address. | callbackUrl / notificationUrl points to a private address. Not checked in sandbox |
An unknown merchantId returns HTTP 404.
Callback URL
After a successful payment, GLODIPAY performs a GET redirect to your callbackUrl with a payload query parameter (appended with & if callbackUrl already has a query string):
GET {callbackUrl}?payload={base64-encoded-json}
Decoded payload fields:
| Field | Type | Description |
|---|---|---|
| status | String | successful. See Status Values |
| transactionId | String | GLODIPAY transaction ID |
| ref | String | Merchant's orderRef |
| amount | Float | Invoice amount |
| currency | String | Currency code |
| paymentMethodType | String | Payment method the buyer used |
| signature | String | RSA-MD5 signature — verify with RSA Public Key |
Always verify the
signaturein the callback payload before trusting thestatus. Use the Transaction Query endpoint to get complete payment details.
IPN Notification
GLODIPAY posts a payment result to your notificationUrl when the transaction reaches a terminal state. See IPN Notifications for the full payload and acknowledgement format.
Transaction Query
Use POST /v2/checkout/query to check the status of a transaction at any time. See Transaction Query.
Source
This page is derived from GLODIPAY_Checkout_API_Specification_v2.