Developers / Docs / Security & signing
Security & signing
Every call is signed, scoped and logged.
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.
The model
| Control | How it works |
|---|---|
| Three credentials | Partner ID, API key and secret. The secret is shown once and stored only as a hash. |
| Signed requests | Timestamp, one-time number and signature, valid for five minutes. |
| Least privilege | Scopes per key. A leaked read key cannot redeem. |
| Idempotency | Every write carries a key, so a retry never doubles anything. |
| IP allow-list | Required for high-risk scopes in live. |
| Rate limits | Per key and per scope, with clear error codes. |
| Audit & abuse review | Every call is logged. Odd patterns open a staff case. |
| Minimal personal data | ProCo and first name only. Phone and email never leave Caship. |
Building the signature
The final algorithm will be published with the sandbox. The intended shape:
- 1 · CollectTimestamp, nonce, HTTP method, path and the raw body.
- 2 · JoinPut them in that order, one per line.
- 3 · SignHMAC-SHA256 with your secret, written in hex.
- 4 · SendPut the result in X-Caship-Signature as v1=….
Keeping secrets
- Never put the secret in a mobile app, a web page or a public repository.
- Sign on your server, not on the cashier's device.
- Rotate keys on staff changes, and any time a leak is possible. Revoke is immediate.
- Use one key per system so you can revoke one without stopping the rest.
Abuse review
Odd patterns, such as many failed signatures or a sudden burst of redemptions, open a case with Caship staff, who can clear it or suspend the key.
