ZeroPointPayments

API reference

Terminals

Common headers

Every endpoint on this page takes these headers.

NameDescription
ZeroPoint-Accountheader, string or null

Optional. The merchant (mch_...) this request acts on, when the body has no merchant_id: the analogue of Stripe's Stripe-Account header.

Stripe-Accountheader, string or null

Optional. A synonym of ZeroPoint-Account; holds a merchant id (mch_...).

Common responses

Every endpoint on this page can answer with these.

StatusDescriptionBody
400

Invalid request. A parameter, header or body field failed validation (code parameter_invalid, with param naming it), or another invalid_request code this operation's description lists. Fix the request; do not retry it unchanged.

ErrorResponse
401

The API key is missing, malformed, unknown or revoked (api_key_missing, api_key_malformed, api_key_invalid). Fix the Authorization header.

ErrorResponse
403

The key is valid but may not do this: platform_suspended, insufficient_scope, live_mode_unavailable, or a permission code this operation's description lists (for example processor_currency_unsupported).

ErrorResponse
404

No such resource for this platform (resource_missing), or another not_found code this operation's description lists.

ErrorResponse
429

Too many requests (rate_limited). Wait for the Retry-After header, then retry.

ErrorResponse

List a merchant's terminals

GET/v1/merchants/{merchant_id}/terminals

Lists physical and simulated terminals registered to the merchant, newest first.

Arguments: merchant_id, limit, cursor.

Returns a list of terminal objects.

Errors: resource_missing.

Next step: POST /v1/payments with method terminal and a terminal_id.

Parameters

NameDescription
merchant_idpath, stringRequired
limitquery, integer

Items per page, default 20.

cursorquery, string or null

next_cursor from the previous page.

starting_afterquery, string or null

Stripe's name for cursor: the id of the last object of the previous page. Same value, same meaning. Send cursor or starting_after, not both.

ending_beforequery, string or null

Not supported: answers 400 parameter_unavailable. Lists page newest first; page forward with starting_after.

Responses

StatusDescriptionBody
200

Successful Response

ListOut_TerminalOut_

Example

Shell
curl -X GET "https://api.zeropointapp.com/v1/merchants/{merchant_id}/terminals" \
  -H "Authorization: Bearer zp_test_..."

Create a simulated terminal or register a physical one

POST/v1/merchants/{merchant_id}/terminals

kind=simulated creates a terminal you drive from the API with no hardware (start here). kind=physical registers a device returned by /terminals/discover.

Arguments: kind, label, sim_behavior + sim_delay_s (simulated), device_id + serial + model (physical).

Returns the terminal object with status online.

Errors: idempotency_key_required, parameter_invalid, resource_missing, device_not_found, terminal_already_registered, processor_currency_unsupported (403; card payments are held for this merchant), sandbox_processor_unconfigured (physical, 503), physical_terminal_unavailable (400, test mode reserves physical terminals; use simulated).

Next step: POST /v1/payments with method terminal.

Parameters

NameDescription
merchant_idpath, stringRequired
Idempotency-Keyheader, string or null

Required on this endpoint. Any unique string up to 255 characters (a UUID is fine). Reuse it only to retry the same request.

Request body

FieldDescription
kindstringRequired

simulated needs no hardware; physical registers a discovered device.

One of: "simulated", "physical"

labelstringRequired

Your name for the terminal.

sim_behaviorstring

Simulated only. manual: you call /v1/sandbox/terminals/{id}/simulate; auto_approve/auto_decline: the terminal answers by itself after sim_delay_s.

One of: "manual", "auto_approve", "auto_decline"

Default: "manual"

sim_delay_sinteger

Simulated only.

Default: 0

device_idstring or null

Physical only: device_id from /terminals/discover.

serialstring or null
modelstring or null

Responses

StatusDescriptionBody
201

Successful Response

TerminalOut
409

Conflict with the current state: idempotency_in_progress (another request with this Idempotency-Key is still running; wait for Retry-After), or a conflict code this operation's description lists.

ErrorResponse
413

The request body is over 1048576 bytes, its Content-Length is not a number, or it is sent chunked (code payload_too_large). Every write method is checked, before routing. Send a smaller body with a Content-Length.

ErrorResponse
422

This Idempotency-Key was already used with a different request body (code idempotency_key_reused). Send the original body to retry, or a new key for a new request.

ErrorResponse
502

The payments network failed or gave no decision (processor_unavailable). The outcome may be unknown: a 5xx releases the Idempotency-Key, so retry with the same key and body.

ErrorResponse
503

No processor is available for this merchant or deployment (processor_not_connected, sandbox_processor_unconfigured, connect_unavailable).

ErrorResponse

Example

Shell
curl -X POST "https://api.zeropointapp.com/v1/merchants/{merchant_id}/terminals" \
  -H "Authorization: Bearer zp_test_..." \
  -H "Idempotency-Key: <Idempotency-Key>" \
  -H "Content-Type: application/json" \
  -d '{
    "kind": <kind>,
    "label": <label>
  }'

Discover physical devices on the merchant's processor account

POST/v1/merchants/{merchant_id}/terminals/discover

Asks the processor which activated card readers belong to this merchant. Use it before registering a physical terminal.

Arguments: merchant_id.

Returns a list of discovered_device objects with device_id, serial, store, and whether each is already registered.

Errors: resource_missing, processor_currency_unsupported (403; card payments are held for this merchant), sandbox_processor_unconfigured (503), processor_unavailable (502).

Next step: POST /v1/merchants/{id}/terminals with kind physical and one device_id.

Parameters

NameDescription
merchant_idpath, stringRequired

Responses

StatusDescriptionBody
200

Successful Response

ListOut_DiscoveredDeviceOut_
413

The request body is over 1048576 bytes, its Content-Length is not a number, or it is sent chunked (code payload_too_large). Every write method is checked, before routing. Send a smaller body with a Content-Length.

ErrorResponse
502

The payments network failed or gave no decision (processor_unavailable). Nothing was changed by this request; retry it later.

ErrorResponse
503

No processor is available for this merchant or deployment (processor_not_connected, sandbox_processor_unconfigured, connect_unavailable).

ErrorResponse

Example

Shell
curl -X POST "https://api.zeropointapp.com/v1/merchants/{merchant_id}/terminals/discover" \
  -H "Authorization: Bearer zp_test_..."

Retrieve a terminal

GET/v1/terminals/{terminal_id}

Returns one terminal.

Arguments: terminal_id (term_...).

Returns the terminal object.

Errors: resource_missing.

Next step: POST /v1/terminals/{id}/ping to refresh status.

Parameters

NameDescription
terminal_idpath, stringRequired

Responses

StatusDescriptionBody
200

Successful Response

TerminalOut

Example

Shell
curl -X GET "https://api.zeropointapp.com/v1/terminals/{terminal_id}" \
  -H "Authorization: Bearer zp_test_..."

Update a terminal

PATCH/v1/terminals/{terminal_id}

Changes label, or sim_behavior and sim_delay_s on a simulated terminal. Use auto_decline to test your failure handling without calling simulate.

Arguments: any subset.

Returns the terminal object.

Errors: resource_missing, parameter_invalid (sim fields on a physical terminal, unknown behavior).

Next step: create a payment.

Parameters

NameDescription
terminal_idpath, stringRequired

Request body

FieldDescription
labelstring or null
sim_behaviorstring or null
sim_delay_sinteger or null

Responses

StatusDescriptionBody
200

Successful Response

TerminalOut
413

The request body is over 1048576 bytes, its Content-Length is not a number, or it is sent chunked (code payload_too_large). Every write method is checked, before routing. Send a smaller body with a Content-Length.

ErrorResponse

Example

Shell
curl -X PATCH "https://api.zeropointapp.com/v1/terminals/{terminal_id}" \
  -H "Authorization: Bearer zp_test_..." \
  -H "Content-Type: application/json" \
  -d '{}'

Check whether a terminal is reachable

POST/v1/terminals/{terminal_id}/ping

Refreshes status. Simulated terminals are always online; physical ones are looked up on the processor account.

Arguments: terminal_id.

Returns the terminal with status and last_seen; emits terminal.online or terminal.offline when the status changes.

Errors: resource_missing, processor_currency_unsupported (403; card payments are held for this merchant), sandbox_processor_unconfigured, processor_unavailable.

Next step: create a payment if online.

Parameters

NameDescription
terminal_idpath, stringRequired

Responses

StatusDescriptionBody
200

Successful Response

TerminalOut
413

The request body is over 1048576 bytes, its Content-Length is not a number, or it is sent chunked (code payload_too_large). Every write method is checked, before routing. Send a smaller body with a Content-Length.

ErrorResponse
502

The payments network failed or gave no decision (processor_unavailable). Nothing was changed by this request; retry it later.

ErrorResponse
503

No processor is available for this merchant or deployment (processor_not_connected, sandbox_processor_unconfigured, connect_unavailable).

ErrorResponse

Example

Shell
curl -X POST "https://api.zeropointapp.com/v1/terminals/{terminal_id}/ping" \
  -H "Authorization: Bearer zp_test_..."