Caship Sign in

Developers / Docs / 15-minute quick start

15-minute quick start

From nothing to a working sandbox call.

Illustrative. The Partner API is a proposal. Names, fields and numbers on this page show the intended shape; the final contract will be published as an OpenAPI file with the sandbox.

Before you start

  • An approved application with sandbox keys. See Getting keys.
  • A server that can make HTTPS requests and keep a secret.

Five steps

  1. 1 · Keep the secret safeStore the Partner ID, API key and secret in your server settings. The secret is shown once and cannot be recovered, only rotated.
  2. 2 · Check the connectionCall the ping route with your test key.
  3. 3 · Look up a test customerUse a sandbox ProCo from the test data page.
  4. 4 · Submit a test saleSend a bill with an idempotency key. An amount ending .99 will decline, which is how you test failures.
  5. 5 · Receive the eventPoint a webhook endpoint at your server and watch sale.approved arrive. Replay it from the tester page.

Your first call

GET sandbox-api.[domain]/v1/ping
Authorization: Bearer ck_test_••••
X-Caship-Partner: CP-4F9K2
X-Caship-Timestamp: 1733400000
X-Caship-Nonce: 6d1f3a90
X-Caship-Signature: v1=9f2c…

A healthy answer is a short JSON object with your Partner ID and the key mode, test.

A test sale

POST /v1/sales  ·  Idempotency-Key: bill-2041
{
  "customer": "PROCO-TEST1",
  "outlet_id": "OUT-0001",
  "bill_no": "2041",
  "bill_amount": 54900
}

Amounts are in paise, so 54900 is Rs 549.00. Send the same call twice and you get the first answer back, not a second reward.

Where next

Read Security & signing to build the signature properly, then pick a use case.