Getting started

The base URL and the authorization rules that every request must follow.

BASE_URL https://api.speend.io

Two API keys

Two separate keys are generated in the merchant dashboard, in the API keys section. They are not interchangeable.

Key Used for
Main key All Payments API methods — payment/createStaticWallet, payment/createPayment, payment/info
Payout key All Payouts API methods — payout/create, payout/getStatus

Both keys go into the same key header — which one you send depends on the method you call. A key that does not match the method type (a payout key on payment/*, for example) will not pass authorization.
Your Merchant UUID is in the merchant dashboard, in the "Merchant" section.

Content-Type: application/json 
merchant: 019e****-****-****-****-*******69cab
key: <main key or payout key>

Error format and response codes

The API returns error responses in several formats depending on the kind of problem. All error messages are returned in English.

Code Format When
401 {"error": "No access", "data": []} Any authorization problem: a wrong or missing key, a missing merchant header, a key that does not match the merchant, a payout key sent to a Payments method (or the other way round)
404 {"status": false, "errors": ["string"]} Object not found. For example, the merchant has no payout with the order_id you sent (payout/getStatus)
422 {"status": false, "errors": ["string", ...]} A field validation or business-logic error. One format for every Payments and Payouts method
speend