Approximate quote
Example of query parameters
{
"baseAmount": -100,
"baseCurrency": "EUR",
"quoteCurrency": "BTC",
"transferInMedium": "card",
"transferOutMedium": "blockchain"
}
Example response
{
"baseAmount": -100, // Requested amount that customer specified to send
"baseCurrency": "EUR", // Base currency that customer specified to send
"quoteAmount": 0.0012814, // The Approximate Quote amount.
"quoteCurrency": "BTC", // Currency the customer specified to receive
"transferIn": { // Object with details of the incoming transaction method (from customer)
"medium": "card", // Incoiming transaction type
"feeAmount": 4.99, // Incoming transfer fee. Added on top of "baseAmount" on checkout. I.e. customer would pay 104.99 EUR total in this example.
"currency": "EUR" // Incoming currency
},
"transferOut": { // Object with details of the outgoing transaction method (to customer)
"medium": "blockchain", // Outgoing transaction type
"feeAmount": 0.000195, // Outgoing transaction fee. Already included in the "quoteAmount".
"currency": "BTC" // Outgoing currency
}
}
GET https://app-api.coinify.com/partners/:partner-id/approximate-quote
Endpoints returns the approximate quote. If transfer media are provided (transferInMedium
and transferOutMedium
) transfer fees are also used for calculating the quote amount.
See request query and response example with additional info about the parameters on the right.
See trade quote for details and explanation of how to create an actual quote you can use to create a trade.
Returned quote is just approximate and can not be used as a real quote. BothtransferInMedium
and transferOutMedium
have to be provided for transfer fees to be included.
Query params
Parameter | Description |
---|---|
baseAmount | Amount to get a price quote for. Denominated in baseCurrency . |
baseCurrency | Currency to get a quote for. |
quoteCurrency | Currency to get the quote in. |
transferInMedium | (optional) Transfer in medium see payment methods. |
transferOutMedium | (optional) Transfer out medium see payment methods. |
See more details about the approximate quote response parameters in the [trade price quote section] (#trade-quote-request).
Trader KYC
Example of JWT payload
{
"traderId": 123,
"externalId": "id-of-the-partner-kyc-review"
}
Example of a request
{
"traderId": 123,
"externalId": "id-of-the-partner-kyc-review",
"state": "completed",
"approveTime": "2018-11-19T01:23:35Z",
"createTime": "2018-11-19T00:23:35Z",
"pep": {
"approved": true,
"approveTime": "2018-11-19T01:23:35Z"
},
"sanction": {
"approved": true,
"approveTime": "2018-11-19T01:23:35Z"
},
"profile": {
"citizenCountry": "DK",
"name": "John doe",
"dateOfBirth": "1988-12-14",
"address": {
"street": "London Street 123",
"city": "London",
"postalCode": "2001",
"country": "UK"
}
}
}
Example of a response
{
"id": "6b54f095-db25-4507-9912-0461fe70768f",
"externalId": "id-of-the-partner-kyc-review"
}
POST https://app-api.coinify.com/partners/:partner-id/kyc
This endpoint will be used by partners to send us KYC review information
for traders who are KYC approved by the partner.
Please contact Coinify if you want to use this endpoint.
For trader to be approved, we also require at least one valid document, see Upload supporting documentsAuthentication
To authenticate request we will use public / private key from trusted email validation.
JWT payload will be different, see example to the right
The JWT token should be sent as a Bearer token in the Authorization header like this
Authorization: Bearer <jwt_token>
Request params
Example of JWT payload
{
"traderId": 123,
"externalId": "id-of-the-partner-kyc-review"
}
Parameter | Type | Default | Description |
---|---|---|---|
traderId | Integer | Required | ID of the trader |
externalId | String | Required | Identifier for this KYC review |
state | String | Required | State of the review, only completed so far |
approveTime | ISO 8601 | Required | Timestamp of approval |
createTime | ISO 8601 | Required | Timestamp of creation |
pep | Object | Required | Object containing PEP details (politically exposed person) |
pep.approved | Boolean | Required | If profile was pep checked |
pep.approveTime | ISO 8601 | Required | Timestamp of approval |
sanction | Object | Required | Object containing sanction check details |
sanction.approved | Boolean | Required | If profile was sanction checked |
sanction.approveTime | ISO 8601 | Required | Timestamp of approval |
profile | Object | Required | Containing profile information |
profile.citizenCountry | ISO 3166 alpha-2 | Required | Citizen country code |
profile.name | String | Required | Full name of the trader |
profile.dateOfBirth | String | Required | Date of birth (YYYY-MM-DD) |
profile.address | Object | Required | Object containing address details |
profile.address.street | String | Required | Street with number |
profile.address.city | String | Required | City |
profile.address.state | String | Required | State |
profile.address.postalCode | String | Required | Postal code |
profile.address.country | ISO 3166 alpha-2 | Required | Country of residence |
Response
If the response status code is 500
or larger, the partner should resend request using some exponential backoff strategy.
HTTP Response code | JSON data |
---|---|
200 OK | Success, review already exists (nothing changed). |
201 Created | Success. |
400 Bad request | Error interpreting the request. |
401 Unauthorized | Error, authentication failed. |
A 200
or 201
response object contains the following fields:
Key | Type | Description |
---|---|---|
id | String (UUID) | Unique identifier for the KYC review. Use this id to upload supporting documents |
externalId | String | The externalId provided in the request |
Upload supporting documents
Example of JWT payload
{
"reviewId": "6b54f095-db25-4507-9912-0461fe70768f",
"externalId": "your-reference-for-this-document"
}
Raw HTTP Request example
POST /partners/:partner-id/kyc/:review-id/documents HTTP/1.1
Host: app-api.coinify.com
Authorization: Bearer <jwt_token>
Content-Type: image/jpeg
Content-Length: 284
X-Upload-Filename: my_filename.jpg
X-Upload-Document-Type: national_id
X-Upload-External-Id: your-reference-for-this-document
<<raw image content>>
Example response
{
"id": "3ebb9ba1-015e-4a71-816d-56f57f711f4c",
"externalId": "your-reference-for-this-document"
}
POST https://app-api.coinify.com/partners/:partner-id/kyc/:review-id/documents
You can upload supporting documents to an existing KYC review by making a POST
request to
this endpoint, where :review-id
is the id
returned from the
POST /partners/:partner-id/kyc
endpoint.
The body of the request must contain the raw document data
Note that the maximum file size for documents uploaded through this endpoint is 25 MBRequest headers
All of the HTTP headers in below table are required. Failure to provide either will result in an error
Name | Description |
---|---|
Authorization | Must contain Bearer <jwt_token> |
Content-Type | MIME type of supporting document |
X-Upload-External-Id | Your (partner's) reference for this document. This must match the externalId value in the supplied <jwt_token> . |
X-Upload-Document-Type | Document type. Must be one of the following values: passport , national_id , or drivers_license accompanied by a selfie . |
X-Upload-Filename | Original filename of document |
Content-Type: multipart/form-data
requests.JWT payload
The JWT Bearer
token supplied in the Authorization
header must contain the following data: (see example to the right)
Key | Type | Description |
---|---|---|
reviewId | String (UUID) | Identifier for the review to upload document to. Must match the :review-id path parameter. |
externalId | String | Unique identifier for the supporting document. Must match the X-Upload-External-Id header value provided in the request |
Response
If the response status code is 500
or larger, the partner should resend request using some exponential backoff strategy.
HTTP Response code | JSON data |
---|---|
201 Created | Success |
400 Bad request | Error interpreting the request. |
401 Unauthorized | Error, authentication failed. |
A 200
or 201
response object contains the following fields:
Key | Type | Description |
---|---|---|
id | String (UUID) | Unique identifier for the supporting document. |
externalId | String | The X-Upload-External-Id header value provided in the request |
Supported countries
Example of the response
{
"AT": {
"supported": true,
"supportedTransferInMedia": [
"card"
]
},
"BE": {
"supported": true,
"supportedTransferInMedia": [
"card",
"bank",
"blockchain"
]
},
"BG": {
"supported": true,
"supportedTransferInMedia": [
"card",
"bank",
"blockchain"
]
},
"HR": {
"supported": true,
"supportedTransferInMedia": [
"card",
"bank",
"blockchain"
]
},
...
"US": {
"supported": false,
"states": {
"LA": {
"supported": false,
"supportedTransferInMedia": []
},
"OR": {
"supported": false,
"supportedTransferInMedia": [
"card",
"bank",
"blockchain"
]
},
"CT": {
"supported": false,
"supportedTransferInMedia": [
"card",
"bank",
"blockchain"
]
}
...
}
}
}
GET https://app-api.coinify.com/countries/:id
This endpoint will be used by partners to get the list of supported countries and the transfer media supported in each country/state.
Request params
Parameter | Type | Description |
---|---|---|
id | UUID | UUID provided to the partner |
Response
HTTP Response code | JSON data |
---|---|
200 OK | Success, response as shown to the right |
400 Bad request | Error invalid_request : id is invalid. |
404 Bad request | Error not_found : id is missing from the request. |
Payment methods
GET https://app-api.coinify.com/partners/:id/payment-methods
This endpoint will be used by partners to get list of supported payment methods and minimum / maximum limits before signing up the trader.
Because we use individual risk assessment limits might be different for the individual trader.
You can find more info on the blockchain network and smart contract address behind each supported cryptocurrency here for:
Request params
Parameter | Type | Description |
---|---|---|
id | UUID | UUID provided to the partner |
Response
Response is similar to Payment methods endpoint from trader requests, except canTrade
and cannotTradeReasons
because they apply to individual traders.
HTTP Response code | JSON data |
---|---|
200 OK | Success, response as shown to the right |
400 Bad request | Error invalid_request : id is invalid. |
404 Bad request | Error not_found : id is missing from the request. |