This section describes all the available parameters of the trade resource.
It is a JSON object and when reading one from the (Get Trade Information) API you get the payload/s as described in this section.
Available parameters of the Trade resource
transferIn
andtransferOut
objects depend on the type of the trade created!This API distinguishes between three types of trades:
Card
Buy: Type of the trade where a Credit Card payment is used to purchase a cryptocurrency.Bank
Buy: Type of the trade where a Bank transfer payment is used to purchase a cryptocurrency.Blockchain
Sell: Type of the trade where a blockchain transaction is used to sell a cryptocurrency for a FIAT currency (e.g. USD, EUR)...The type of a trade is defined by the
transferIn.medium
andtransferOut.medium
parameter values.
transferIn.medium
defines the incoming transaction for the trade (i.e. payment method)
transferOut.medium
defines the outgoing transaction for the trade (i.e. payout method).Depending on the defined
medium
parameter values,transferIn
andtransferOut
objects will provide different relevant parameters and ßdata.
Trade Object
This is the general top-level trade object. On this level, the trade object is the same for any type of the trade:
Key | Type | Description |
---|---|---|
id | Integer | Unique ID for this trade |
traderId | Integer | Reference to the trader that created the trade |
traderEmail | String | Email address of trader that created the trade |
state | Trade state | The current state of the trade |
inCurrency | String | Currency (ISO 4217) denominating inAmount . |
outCurrency | String | Currency (ISO 4217) denominating outAmount or outAmountExpected . |
inAmount | Float | The amount of inAmount that this trade covers. Is always positive. |
outAmount | Float | (Optional) The amount of outCurrency that this trade resulted in. Is always positive. NOTE: This field is only defined if the state of the trade is completed . For all other states, see the outAmountExpected field. |
outAmountExpected | Float | The amount of outCurrency that this trade is expected to result in. Is always positive. |
transferIn | Transfer in object | Object describing how we (Coinify) will receive/have received the money to fund the trade. |
transferOut | Transfer out object | Object describing how we (Coinify) will send/have sent the result of the trade back to the trader. |
quoteExpireTime | ISO 8601 time | (Optional) The time when the price quote underlying this trade expires. NOTE: This field is only defined in the following states: awaiting_transfer_in , processing , reviewing , payment_authorized . |
updateTime | ISO 8601 time | The time when the trade was last updated. |
createTime | ISO 8601 time | Timestamp for when this trade was first created |
isPriceQuoteApproximate | Boolean | Defines whether the quote is guaranteed to the end-user. In case of Credit Card buy trade and blockchain sell trade it is false , meaning that the quote is guaranteed.In case of Bank buy trade it is set to true , meaning the quote is not guaranteed. This is due to the fact that the end-user can complete a bank transfer for a trade inside a 30 day window where the prices can change a lot. Thus, the quote is updated at the time of received bank transfer. |
transferIn
object available parameters:
transferIn
object available parameters:Parameter | Type | Description |
---|---|---|
id | Integer | ID of the transferIn object. |
sendAmount | Float | Amount that is/will be sent to this transfer. Denominated in currency . Is always positive. |
receiveAmount | Float | Amount that this transfer will result in. Denominated in currency . Is always positive and equal to or smaller then sendAmount . The difference between the sendAmount and the receiveAmount will be the fee of the transfer. |
currency | String | Currency (ISO 4217) that this transfer is/will be denominated in. |
medium | String | Transfer medium. The medium transferring the currency. |
details | Object | Information relevant for the defined incoming transaction (transferIn.medium ).Available parameters differ depending on the specified medium .See available parameters in case of: ▫️ transferIn.medium = card ▫️ transferIn.medium = bank ▫️ transferIn.medium = blockchain |
transferIn
.medium
parameter available values
transferIn
.medium
parameter available valuesAvailable medium
values for the transferIn
object. Describes the incoming transaction, i.e. payment method of a trade.
Medium | Description |
---|---|
card | Specifies Credit Card transaction as the incoming payment type for the trade. |
bank | Bank - Specifies Bank Transfer as the incoming payment type for the trade. In this case, Coinify's bank account details are provided in the transferIn.details object. |
blockchain | Blockchain - Specifies a blockchain transfer as the incoming transaction for the trade. E.g. end-user sending Bitcoin. NOTE: The currency field of the transfer object will determine which blockchain currency. |
transferOut
object available parameters
transferOut
object available parametersParameter | Type | Description |
---|---|---|
sendAmount | Float | FIAT amount that expected to be sent by the end-user to Coinify in order to complete the trade. Denominated in currency . Is always positive. |
receiveAmount | Float | FIAT amount that the end-user will receive for the completed trade. Denominated in currency . Is always positive and equal to or smaller than the sendAmount . The difference between the sendAmount and the receiveAmount will be the fee of the transfer. |
currency | String | Currency (ISO 4217) that this outgoing transfer is denominated in. |
medium | String | Transfer medium. The medium transferring the currency. |
mediumReceiveAccountId | Integer | Reference to our internal accounts. Note at the moment we only have internal bank accounts. |
details | Object | Information relevant for the defined outgoing transaction (transferOut.medium ).See available parameters in case of: ▫️ transferOut.medium = bank ▫️ transferOut.medium = blockchain (same value for Card and Bank buy trades) |
transferOut
. medium
available values
transferOut
. medium
available valuesAvailable medium
values for transferOut
object. Defines the outgoing transaction, usually the destination account.
Medium | Description |
---|---|
bank | Details of the end-user's receiving bank account to which a bank transfer for the Sell trade will be executed. |
blockchain | Blockchain - Transfer on a public blockchain, such as Bitcoin. NOTE: The currency field of the transfer object will determine which blockchain currency. |
transferIn.details
& transferOut.details
object parameters
transferIn.details
& transferOut.details
object parameterstransferIn.details
object and transferOut.details
object available parameters can be different depending on the specified transferIn.medium
and transferOut.medium
parameter values. Put differently, the details
objects' parameters differ based on the type of the specific trade.
As mentioned on the top of this page, currently, there are three main types of trades and in the following paragraphs the available details
object parameters will be described for each of the trade type.
💳 Credit Card Buy Trade
transferIn.Medium: card
& transferOut.Medium: blockchain
transferIn.Medium: card
& transferOut.Medium: blockchain
transferIn.details
:
transferIn.details
:Parameter | Type | Description |
---|---|---|
provider | String | Credit card processor that will be in charge for the credit card payment. |
returnUrl | String | The return URL to which the user to be sent back after the payment has been created. |
redirectUrl | String | The URL to which the end-user must be redirected in order to provide the credit card details to pay for the trade. |
cardPaymentId | Integer | ID of the card payment |
isApplePayAvailable | Boolean | Specifies whether Apple Pay is an available payment option for the trade. |
transferOut.details
:
transferOut.details
:Parameter | Type | Description |
---|---|---|
account | String | Blockchain address. The blockchain account receiving the money in this transfer (blockchain address). |
🏦 Bank Transfer Buy Trade
transferIn.Medium: bank
& transferOut.Medium: blockchain
transferIn.Medium: bank
& transferOut.Medium: blockchain
transferIn.details
:
transferIn.details
:Parameter | Type | Description |
---|---|---|
account | Object | Object with additional information about the bank account. |
→bic | String | For SEPA and international its the SWIFT/ BIC number and for danish accounts its the REG number. Optional in case of domestic bank transfers. |
→type | Bank account type | Type of the bank account. |
→number | String | For SEPA and international it’s the IBAN (International Bank Account Number). For danish accounts, it’s the BBAN (Basic Bank Account Number). Optional in case of domestic bank transfers. |
→currency | String | Currency of the bank account. |
referenceText | String | Text that the bank transfer must contain in order for Coinify's system to correctly match it what trade it concerns. |
→domesticAccountNumber | String | (Optional) Account Number for domestic transfers. |
→regNo | String | (Optional) Reg. No. used for some domestic transfers. |
→routingCode | String | Routing Code used for some domestic transfers. (Optional) |
→sortCode | String | Sort Code used for some domestic transfers. (Optional) |
→bsb | String | BSB used for some domestic transfers. (Optional) |
bank | Object | Object with additional information about the bank. |
→name | String | Name of the bank. |
→address | Object | Object with information about the address of the bank. |
→street | String | Street address. |
→zipcode | String | Zip/Postal code. |
→city | String | City as the part of the address where the bank is registered. |
→state | String | (Optional) State where the bank is located. |
→country | String | ISO 3166-1 alpha-2 country code. Country where the bank is located. |
holder | Object | Object with additional information about the bank account holder. |
→name | String | Name of the bank account holder. |
→address | Object | Object with information about the address of the account holder. |
→street | String | Street address. |
→zipcode | String | Zip/Postal code. |
→city | String | City. |
→state | String | (Optional) State where the holder is located. |
→country | String | ISO 3166-1 alpha-2 country code. |
transferOut.details
:
transferOut.details
:Parameter | Type | Description |
---|---|---|
account | String | Blockchain address. The blockchain account receiving the money in this transfer (blockchain address). |
⛓️ Blockchain Sell Trade
transferIn.Medium: blockchain
& transferOut.Medium: bank
transferIn.Medium: blockchain
& transferOut.Medium: bank
transferIn.details
transferIn.details
Parameter | Type | Description |
---|---|---|
account | String | Blockchain address. The blockchain account receiving the money in this transfer (blockchain address). |
accountSignature | String | HMAC-SHA-256 signature signing the account value. Only defined if a shared secret has been established with Coinify. |
memo | String | Optional memo for currencies where memo/destination tag is supported. |
transaction | String | Transaction sending the money in this transfer. Only defined if money has been sent. |
refundAccount | String | Account to refund the money in this transfer in case of failure. Only defined if currency != BTC . |
refundAccountSignature | String | HMAC-SHA-256 signature signing the refundAccount value. Only defined if refundAccount is defined and a shared secret has been established with Coinify. |
paymentUri | String | Payment URI scheme to generate QR code.) |
transferOut.details
:
transferOut.details
:Parameter | Type | Description |
---|---|---|
account | Object | Object with additional information about the bank account. |
→bic | String | For SEPA and international its the SWIFT/ BIC number and for danish accounts its the REG number. Optional in case of domestic bank transfers. |
→type | Bank account type | Type of the bank account. |
→number | String | For SEPA and international it’s the IBAN (International Bank Account Number). For danish accounts, it’s the BBAN (Basic Bank Account Number). Optional in case of domestic bank transfers. |
→currency | String | Currency of the bank account. |
referenceText | String | Text that the bank transfer must contain in order for Coinify's system to correctly match it what trade it concerns. |
→domesticAccountNumber | String | (Optional) Account Number for domestic transfers. |
→regNo | String | (Optional) Reg. No. used for some domestic transfers. |
→routingCode | String | Routing Code used for some domestic transfers. (Optional) |
→sortCode | String | Sort Code used for some domestic transfers. (Optional) |
→bsb | String | BSB used for some domestic transfers. (Optional) |
bank | Object | Object with additional information about the bank. |
→name | String | Name of the bank. |
→address | Object | Object with information about the address of the bank. |
→street | String | Street address. |
→zipcode | String | Zip/Postal code. |
→city | String | City as the part of the address where the bank is registered. |
→state | String | (Optional) State where the bank is located. |
→country | String | ISO 3166-1 alpha-2 country code. Country where the bank is located. |
holder | Object | Object with additional information about the bank account holder. |
→name | String | Name of the bank account holder. |
→address | Object | Object with information about the address of the account holder. |
→street | String | Street address. |
→zipcode | String | Zip/Postal code. |
→city | String | City. |
→state | String | (Optional) State where the holder is located. |
→country | String | ISO 3166-1 alpha-2 country code. |