Request & Response format

Request format

Data payloads in requests must be encoded using JSON, and accompanied by a Content-Type: application/json HTTP header.

šŸ‘

Request example:

See an example of Request headers and body to the right of the page.

šŸ“˜

Authentication:

Most endpoints require authentication. The authenticated person is the end-user/trader from Coinify's system point of view. Authentication is performed using the **Authorization** header and Beareraccess_token value.

See Authentication section on how to obtain one.

User-Agent header

In order for Coinify to easily track which API endpoints are being used by which partners (Coinify's clients using the Trade API or Trade Widget) - and to assist in integration troubleshooting, we strongly suggest that you supply a custom User-Agent HTTP header with a user agent string that is unique to your implementation.

As some parts of our API also read the user agent to optimize the experience for a specific platform, please also add Android or iOS to the user agent if you know that your end-user will be using one of those platforms.

Response format

The API always responds with a HTTP status code and usually a JSON object in the response body. This JSON object carries the data of the response, or an error object which provides more information about the error other than the HTTP status code. If the endpoint doesn’t return any data, the response body is empty.

You can determine whether a call was successful or not by checking the HTTP status code.

Success format

The body of a successful response (HTTP status code is 2xx) will always be a JSON object or an empty body (if no data needs to be returned).

The contents of the response JSON object depends entirely on the endpoint and the type of operation performed.

šŸ‘

Info:

Check the Success response example by clicking on the "200 - Result" button on the right.

Error format

Whenever a request fails (the HTTP status code is 4xx or 5xx), the API returns a JSON object with two or three strings:

error - Contains a machine-readable error code
error_description - Contains a human-readable error message
request_id - Contains an ID of the request used for troubleshooting

šŸ‘

Info:

Check the Error response example by clicking on the "400 - Result" button on the right.

Body Params
string
required
Defaults to -100
string
required
Defaults to EUR
string
required
Defaults to BTC
Headers
string
required
Defaults to app-api.coinify.com
string
required
Defaults to ExampleIntegration/1.0
string
required
Defaults to application/json
string
required
Defaults to Bearer eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE3MTUxNjcwNjAsImV4cCI6MTcxNTE2ODI2MCwidWlkIjo3MDM2MiwiZXYiOnRydWUsInNjIjp7InRfMjQ3NjUiOiIqIn19.x6qdZz036dy9v-3S28AXclYr9hoYKsL5rIiWsIbHxAYn_RnwvJIRj40I6K4NLQy436RPu3O0tar4l_N6xBK9vQ
Responses

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json