This endpoint is responsible for initiating a buy/sell trade offer on behalf of the user.
The request triggers the creation of a trade offer that can later be accepted by the user within its validity (as defined in offer_validity
& expires_at
response parameters).
The offer includes details such as the asset to be traded, the fiat currency and the amount either in fiat currency or in units of the asset being traded.
By accommodating both fiat and asset unit denominations, the user experience is enhanced, catering to a wide range of trading preferences and strategies.
The trade offer response outlines the details of the proposed trade, including: asset, amount, price, fees, preliminary tax calculations if applicable, and any warning messages relevant to the user.
The offer to be created.
New offer has been created
User not verified
Forbidden
Error
Insufficient funds
Error
Too Many Requests
Error
Maintenance or Service unavailable
{- "type": "buy",
- "fiat_id": 1,
- "asset_id": 1,
- "amount": "1.99",
- "amount_defined_for": "fiat"
}
{- "data": {
- "id": "2e4c89ac-1290-426f-8de0-4c7b40b91d3a",
- "type": "buy",
- "fiat_id": 1,
- "asset_id": 1,
- "fiat_amount": "1.89",
- "tax_amount": "0.1",
- "total_amount": "1.99",
- "asset_amount": "0.00004884",
- "asset_price": "40743.41527688",
- "offer_validity": 60,
- "expires_at": "2021-07-01T18:00:09+03:00",
- "time": "2021-07-01T17:59:09+03:00",
- "warning": [
- {
- "message": "Please keep in mind that if you sell your assets now,you will lose your right to receive dividends for the amount you sell !",
- "message_key": "corporate.action.dividend.warning.message.sell",
- "helpdesk_article_id": "360020583999",
- "link_message": "For further information, please visit our helpdesk.",
- "link_message_key": "corporate.action.dividend.warning.link.message"
}, - {
- "message": "Tax withholding provider is not available",
- "message_key": "tax.withholding.not.available",
- "helpdesk_article_id": "",
- "link_message": "",
- "link_message_key": ""
}
], - "spread": "0.12"
}
}