Payment
2 API calls in this section.
Pay For Package
/express-shipping/payInitiates a NASS payment for an express shipping package. Requires tenant context. Request Body: - order_id (string, required): your package order_id - order_desc (string, optional) - back_ref (string, required): where to redirect user after payment (must be http/https) Response: - 200 OK: payment_id, status, redirect_url, transaction_params - 4xx/5xx on error
1curl --request POST "$ONDI_BASE_URL/express-shipping/pay" \2 --header "Content-Type: application/json" \3 --header "X-API-Key: {{api_key}}" \4 --header "Content-Type: application/json" \5 --data '{6 "order_id": "ORDER-123",7 "order_desc": "Express shipping payment",8 "back_ref": "https://app.example.com/payment/return"9}'1{2 "order_id": "ORDER-123",3 "order_desc": "Express shipping payment",4 "back_ref": "https://app.example.com/payment/return"5}Request body fields
order_idExampleExample field from the request body.
order_descExampleExample field from the request body.
back_refExampleExample field from the request body.
Headers
Content-TypeOptionalapplication/json
X-API-KeyOptional{{api_key}}
Static API key for Express Shipping (required)
Responses
1{2 "success": true,3 "data": {4 "payment_id": "pay-uuid-123",5 "status": "PENDING",6 "redirect_url": "https://nass.example/redirect",7 "transaction_params": {8 "AMOUNT": "1000",9 "CURRENCY": "368"10 }11 }12}1{2 "success": false,3 "message": "Package not found"4}1{2 "success": false,3 "message": "NASS transaction failed"4}Check Payment Status
/express-shipping/pay/statusChecks NASS transaction status by order_id (NASS ORDER). Updates the payment row and returns minimal status data. Request Body: - order_id (string, required): NASS ORDER returned in transactionParams.ORDER Response: - 200 OK: payment_id, order_id, status, paid, amount, currency, rrn, response_code, status_msg, timestamp - 4xx/5xx on error
1curl --request POST "$ONDI_BASE_URL/express-shipping/pay/status" \2 --header "Content-Type: application/json" \3 --header "X-API-Key: {{api_key}}" \4 --header "Content-Type: application/json" \5 --data '{6 "order_id": "1234567890123456"7}'1{2 "order_id": "1234567890123456"3}Request body fields
order_idExampleExample field from the request body.
Headers
Content-TypeOptionalapplication/json
X-API-KeyOptional{{api_key}}
Static API key for Express Shipping (required)
Responses
1{2 "success": true,3 "data": {4 "payment_id": "pay-uuid-123",5 "order_id": "1234567890123456",6 "status": "SUCCESS",7 "paid": true,8 "amount": 5000,9 "currency": "IQD",10 "rrn": "505801383493",11 "response_code": "00",12 "status_msg": "Approved",13 "timestamp": "20250301104625"14 }15}1{2 "success": false,3 "message": "Payment not found"4}