Create a payment intent
Endpoint
POST /v1/payments/intents
POST
/v1/payments/intentsScope payments.write₹5 per successful callLiveCreate a payment intent (Razorpay-backed) for an order.
Request
Request parameters
| Field | Type | Description |
|---|---|---|
Authorizationrequired | header | Bearer <api-key> (e.g. sk_test_... in sandbox, sk_live_... in production). The x-api-key header is also accepted. |
Idempotency-Key | header | Optional idempotency key (1 to 255 characters), kept for 24 hours. The same key and the same request replays the stored response; the same key with a different request is 422 IDEMPOTENCY_KEY_REUSED; the same key while the first request is still running is 409 IDEMPOTENCY_IN_PROGRESS (see Retry-After). |
externalOrderIdrequired | string | Your reference for the order being paid. |
amountMinorrequired | integer | Amount in minor units (paise); positive integer. |
currencyrequired | string | Currency code, at least 3 characters, e.g. INR. |
paymentConnectionIdrequired | string | Id of one of your active payment connections. |
Example
Make the call
curl -X POST "https://api-b2b.stampmitra.in/v1/payments/intents" \
-H "Authorization: Bearer sk_test_xxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{"externalOrderId":"ord_ext_123","amountMinor":50000,"currency":"INR","paymentConnectionId":"pc_8d1f3a2b"}'Playground
Try it
Response
Response example
ResponseJSON
{
"id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"externalOrderId": "ord_ext_123",
"coreOrderId": null,
"amountMinor": 50000,
"currency": "INR",
"status": "CREATED",
"providerIntentId": "order_Nf3k2m9QxPz1Ab",
"createdAt": "2026-10-15T09:41:07.000Z"
}| Field | Type |
|---|---|
id | string |
externalOrderId | string |
coreOrderId | null |
amountMinor | number |
currency | string |
status | string |
providerIntentId | string |
createdAt | string |