API reference
Every endpoint of the ZeroPoint REST API, drawn from the OpenAPI document at /openapi.json.
Base URL
API conventions
Base path: /v1. JSON in, JSON out. Authenticate with Authorization: Bearer zp_test_....
Idempotency
An Idempotency-Key is required on these routes: POST /v1/merchants, POST /v1/merchants/{merchant_id}/terminals, POST /v1/payments, POST /v1/payments/{payment_id}/cancel, POST /v1/payments/{payment_id}/refund, POST /v1/payments/{payment_id}/void, POST /v1/payment_methods, POST /v1/webhooks, and POST /v1/webhooks/{webhook_id}/rotate-secret. On POST /v1/customers, POST /v1/products, POST /v1/prices, POST /v1/coupons and POST /v1/promotion_codes, which never reach the processor, it is optional, as on Stripe: sent, it works exactly as on the routes above; left out, the request runs once with no replay protection, so a retry creates a second object. Replays carry Idempotent-Replayed: true; a 5xx releases the key so a retry with it re-executes and resumes the same pending payment or refund (same processor request id) rather than starting a new one.
Keys are scoped per platform and mode: every API key of the same mode (test or live) belonging to a platform shares one key space, so the same key sent with two of your test keys replays the first request instead of starting a second one, while a test key and a live key never share a record. The OpenAPI document marks the Idempotency-Key header parameter as optional only because the requirement is enforced after authentication, not because it is optional in practice; it is required on every endpoint listed above.
- Same key, same body, already completed: you get the stored response with header
Idempotent-Replayed: true. - Same key, different body:
422with codeidempotency_key_reused, while the key's stored response or in-flight claim exists; a5xxanswer releases the key, so a later retry with that key is judged on its own body (and a pending keyed payment then appliespayment_resume_mismatch). - Same key, still in flight:
409with codeidempotency_in_progressandRetry-After: 2. - A refund or void blocked by an unresolved reversal returns
409 payment_not_refundablewithRetry-After: 2. This temporary response is not cached. Retry the original reversal with its original key; a new key cannot bypass an unknown processor outcome. - Missing key on an endpoint that requires it:
400with codeidempotency_key_required.
From the guide API conventions.
Errors
Every REST error has this shape, and every MCP tool error is an is_error result whose text contains this same JSON envelope (after the tool name prefix the MCP protocol adds):
{ "error": { "type": "authentication", "code": "api_key_invalid", "message": "...", "param": null, "request_id": "req_..." } }Types
| type | HTTP | Meaning |
|---|---|---|
invalid_request | 400, 405, 413, 422 | Malformed or missing input |
authentication | 401 | Missing, malformed, or invalid API key |
permission | 403 | The key is valid but not allowed to do this |
not_found | 404 | No such resource for this platform |
conflict | 409 | State conflict, including idempotency in progress |
rate_limited | 429 | Slow down; honor Retry-After |
payment_error | 402 | The payment itself failed; see the code |
upstream_error | 502 or 503 | The payments network failed, or the sandbox has no processor account; retry with the same Idempotency-Key on a 502 |
internal_error | 500 | Our fault; retry with the same Idempotency-Key, quote request_id |
From the guide Errors.
Resources
- Platform1 endpoint
- Merchants5 endpoints
- Terminals6 endpoints
- Payments10 endpoints
- Payment intents2 endpoints
- Refunds2 endpoints
- Webhooks13 endpoints
- Customers6 endpoints
- Payment methods6 endpoints
- Catalog23 endpoints
- Checkout5 endpoints
- Subscriptions6 endpoints
- Invoices5 endpoints
- Billing2 endpoints
- Billing portal1 endpoint
- Test helpers9 endpoints
- Sandbox1 endpoint
- Docs3 endpoints
- Meta2 endpoints