Skip to main content

Webhook

2 API calls in this section.

NASS Webhook

Billing & Subscriptions / Webhook
POST/payment/webhooks/nass

NASS webhook that confirms the payment internally using ORDER/rrn.

Most OnDi APIs require an authenticated session or service token. Public endpoints are marked by their path and module context.
Request
curl
1curl --request POST "$ONDI_BASE_URL/payment/webhooks/nass" \2  --header "Content-Type: application/json" \3  --header "Content-Type: application/json" \4  --data '{5  "terminal": "00053402",6  "actionCode": "0",7  "responseCode": "00",8  "statusMsg": "Approved",9  "amount": "5000",10  "currency": "368",11  "rrn": "505801383493",12  "orderId": "<ORDER_FROM_INITIATE>"13}'
Request body
json
1{2  "terminal": "00053402",3  "actionCode": "0",4  "responseCode": "00",5  "statusMsg": "Approved",6  "amount": "5000",7  "currency": "368",8  "rrn": "505801383493",9  "orderId": "<ORDER_FROM_INITIATE>"10}

Request body fields

terminalExample
string

Example field from the request body.

actionCodeExample
string

Example field from the request body.

responseCodeExample
string

Example field from the request body.

statusMsgExample
string

Example field from the request body.

amountExample
string

Example field from the request body.

currencyExample
string

Example field from the request body.

rrnExample
string

Example field from the request body.

orderIdExample
string

Example field from the request body.

Headers

Content-TypeOptional
header string

application/json

Responses

No response example is available for this endpoint yet.

Payment Gateway Webhook

Billing & Subscriptions / Webhook
POST/payment/webhooks/:gateway_code

Handles webhook notifications from payment gateways with signature verification and payment status updates.

Most OnDi APIs require an authenticated session or service token. Public endpoints are marked by their path and module context.
Request
curl
1curl --request POST "$ONDI_BASE_URL/payment/webhooks/:gateway_code" \2  --header "Content-Type: application/json" \3  --header "X-Razorpay-Signature: {{razorpay_signature}}" \4  --header "Content-Type: application/json" \5  --data '{6  "entity": "event",7  "account_id": "acc_BFQ7uQEaa4j3z7",8  "event": "payment.captured",9  "contains": [10    "payment"11  ],12  "payload": {13    "payment": {14      "entity": {15        "id": "pay_BFQ7uQEaa4j3z8",16        "entity": "payment",17        "amount": 29999,18        "currency": "USD",19        "status": "captured",20        "order_id": "order_BFQ7uQEaa4j3z9",21        "method": "card",22        "description": "Payment for order order-12345",23        "email": "user@example.com",24        "notes": {25          "order_id": "order-12345",26          "customer_id": "user-uuid-456"27        },28        "created_at": 170123456729      }30    }31  },32  "created_at": 170123456733}'
Request body
json
1{2  "entity": "event",3  "account_id": "acc_BFQ7uQEaa4j3z7",4  "event": "payment.captured",5  "contains": [6    "payment"7  ],8  "payload": {9    "payment": {10      "entity": {11        "id": "pay_BFQ7uQEaa4j3z8",12        "entity": "payment",13        "amount": 29999,14        "currency": "USD",15        "status": "captured",16        "order_id": "order_BFQ7uQEaa4j3z9",17        "method": "card",18        "description": "Payment for order order-12345",19        "email": "user@example.com",20        "notes": {21          "order_id": "order-12345",22          "customer_id": "user-uuid-456"23        },24        "created_at": 170123456725      }26    }27  },28  "created_at": 170123456729}

Path parameters

gateway_codeRequired
path string

razorpay

Gateway identifier (razorpay, stripe, etc.)

Request body fields

entityExample
string

Example field from the request body.

account_idExample
string

Example field from the request body.

eventExample
string

Example field from the request body.

containsExample
array<string>

Example field from the request body.

payloadExample
object

Example field from the request body.

payload.paymentExample
object

Example field from the request body.

payload.payment.entityExample
object

Example field from the request body.

created_atExample
number

Example field from the request body.

Headers

Content-TypeOptional
header string

application/json

X-Razorpay-SignatureOptional
header string

{{razorpay_signature}}

Razorpay webhook signature for verification

Responses

No response example is available for this endpoint yet.