POS Web API
Integrate PayOrc point-of-sale payments via the POS Web API.
POS Web API
API Version: 3.0.0
The POS Web API lets you create orders and initiate card or UPI payments on a physical POS terminal (e.g. Mswipe). Use test or live API keys with channel pos_web.
Base URL
| Environment | Base URL |
|---|---|
| Production / Sandbox | https://api.payorc.com/pos/v1 |
Authentication
Every request requires these headers:
| Header | Required | Description |
|---|---|---|
merchant-key | Yes | POS Web API key |
merchant-secret | Yes | POS Web API secret |
Content-Type | Yes | application/json (for POST bodies) |
API keys must be issued for the POS Web channel (pos_web). Keys from other channels (hosted, S2S, etc.) are rejected with E0005.
| Code | Meaning |
|---|---|
E0001 | Missing merchant-key or merchant-secret |
E0002 | Invalid channel configuration |
E0003 | Invalid key or secret |
E0005 | Wrong channel key, or invalid merchant mode |
E0006 | Internal server error |
Integration flows
One-step — POS Payment: create order and generate PSP token in one call.
Two-step — Create Order → Initiate Payment.
Endpoints
| Method | Path | Description |
|---|---|---|
| POST | /payment | Create order + initiate payment |
| POST | /orders | Create order only |
| POST | /initiate-payment | Initiate payment for existing order |
| GET | /orders/:order_id | Get order / transaction details |
| POST | /orders/:order_id/cancel | Cancel a pending order |
Webhooks
Pass urls.webhook_url (HTTPS, or "") when creating a payment/order. PayOrc sends status updates to that URL when the payment completes. You can also poll Get Order.
Response envelope
Success:
{ "data": {}, "message": "...", "status": "success", "code": "00" }Validation error:
{ "message": "...", "status": "fail", "code": "E0021" }txn_type values
| Value | Description |
|---|---|
CARD | Card payment on terminal |
UPI | UPI / digital payment on terminal |
Total payable amount
When validating MID limits, total payable is:
(amount × quantity) + shipping_amount + convenience_fee