Generate a Checkout Link API
/api/checkout/v1/ordersGenerate an Infinity Checkout link. Returns a redirect URL where the customer can complete payment on Pine Labs' hosted checkout page.
Bearer token. Get token →Header Parameters
| Field | Details |
|---|---|
Request-Timestampstringdate-time | ISO 8601 UTC timestamp of the request. Used for idempotency and audit. |
Request-IDstring | Use a global unique identifier [GUID] for the request. Constraints Minimum length: 1 characterMaximum length: 50 characters |
Request Bodyrequired
| Field | Details |
|---|---|
merchant_order_referencestringrequired | Idempotency Key. Unique identifier for the order request. Duplicate requests with the same |
order_amountobjectrequired2 nested fields | Monetary amount with currency. |
integration_modestring | The integration mode through which you want to accept payments. By default, the integration mode is set to REDIRECT. Allowed values: REDIRECTIFRAMESDKSEAMLESS |
pre_authboolean | The pre-authorization type. false (default): When pre-authorization is not required. true: When pre-authorization is needed. |
allowed_payment_methodsstring[] | The type of payment methods you want to offer your customers. Constraints Allowed item values: CARDUPIPOINTSNETBANKINGWALLETCREDIT_EMIDEBIT_EMIBNPL |
notesstring | The note you want to show against an order. |
callback_urlstring | URL to redirect your customers to specific success or failure pages. |
purchase_detailsobject2 nested fields | Object that contains the details of customer information and product details. |
Response
| Field | Details |
|---|---|
tokenstring | Token generated by Pine Labs for Infinity Checkout. |
order_idstring | Unique identifier of the order in the Pine Labs Online database. |
redirect_urlstring | The checkout link generated on Pine Labs system. |
response_codeinteger | Response code of the request. |
response_messagestring | Corresponding message to the response code. |
Status Codes
200 | Checkout link generated successfully. |
400 | The request was malformed or missing required fields. |
401 | Authentication failed — missing, expired, or invalid Bearer token. |
422 | Unprocessable entity. |
500 | An unexpected error occurred on the server. |
curl --request POST \
--url https://pluraluat.v2.pinepg.in/api/checkout/v1/orders \
--header 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
--header 'Content-Type: application/json' \
--header 'Request-ID: a1b2c3d4-e5f6-7890-abcd-ef1234567890' \
--header 'Request-Timestamp: 2024-10-01T10:30:00Z' \
--data '{
"merchant_order_reference": "112345",
"order_amount": {
"value": 50000,
"currency": "INR"
},
"integration_mode": "REDIRECT",
"allowed_payment_methods": [
"CARD",
"UPI"
],
"notes": "Order1",
"callback_url": "https://sample-callback-url",
"purchase_details": {
"customer": {
"email_id": "john@example.com",
"first_name": "Kevin",
"last_name": "Bob",
"customer_id": "123456",
"mobile_number": "9876543210",
"country_code": "91",
"billing_address": {
"address1": "10 Downing Street Westminster London",
"address2": "Oxford Street Westminster London",
"address3": "Baker Street Westminster London",
"pincode": "51524036",
"city": "Westminster",
"state": "Westminster",
"country": "London",
"full_name": "Kevin Bob",
"address_type": "Home",
"address_category": "billing"
},
"shipping_address": {
"address1": "10 Downing Street Westminster London",
"address2": "Oxford Street Westminster London",
"address3": "Baker Street Westminster London",
"pincode": "51524036",
"city": "Westminster",
"state": "Westminster",
"country": "London",
"full_name": "Kevin Bob",
"address_type": "Home",
"address_category": "billing"
}
},
"product": [
{
"product_code": "redmi_10",
"product_amount": {
"value": 50000,
"currency": "INR"
}
}
]
}
}'{
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"order_id": "v1-5757575757-aa-hU1rUd",
"redirect_url": "https://api.pluralonline.com/api/v3/checkout-bff/redirect/checkout?token=REDIRECT_TOKEN",
"response_code": 200,
"response_message": "Order Creation Successful."
}