Request quote
POST/quotes
For fixed rate shifts, a quote should be requested first.
A quote can be requested for either a depositAmount
or a settleAmount
.
When defining non-native tokens like AXS and USDT for depositCoin
and/or settleCoin
, the depositNetwork
and settleNetwork
fields must also be specified. This also applies to native tokens like ETH that supports multiple networks.
commissionRate
optional parameter can be used to adjust rates for your users. The default commission rate is 0.5%. Rates below the default offer better rates by reducing affiliate commission, while rates above the default are passed on to the user. The maximum commission rate is 2%.
Use the same commissionRate
in the /v2/pair
and /v2/pairs
endpoints as when creating the shift/quotes to get an accurate rate information. See Monetization for detailed examples of how commission rates affect rates.
If the API requests are sent from the integrations own server, the x-user-ip
header must be set to the end-user IP address. Otherwise the requests will be blocked. See Permissions.
After the quote request, a fixed rate shift should be created using the `id` returned by the /v2/quotes
endpoint.
A quote expires after 15 minutes.
x-sideshift-secret
is your account's private key. Never share it with anyone as it grants full access to your account and should be kept confidential.
Request
Header Parameters
end-user IP address for integrations API requests
- application/json
Body
required for non-native tokens (e.g. AXS, USDT) and multi-network native tokens (e.g. ETH).
required for non-native tokens (e.g. AXS, USDT) and multi-network native tokens (e.g. ETH).
if null, settleAmount is required
if null, depositAmount is required
Responses
- 201
- 400
- 401
- 403
- 404
- 500
- application/json
- Schema
- Example
Schema
{
"id": "c1d79240-0117-4867-afed-9cc4605c53aa",
"createdAt": "2023-10-17T03:33:21.230Z",
"depositCoin": "ETH",
"settleCoin": "ETH",
"depositNetwork": "arbitrum",
"settleNetwork": "ethereum",
"expiresAt": "2023-10-17T03:48:21.230Z",
"depositAmount": "0.14364577",
"settleAmount": "0.14078454",
"rate": "0.980081348723",
"affiliateId": "YQMi62XMb"
}
- application/json
- Schema
- Example
Schema
error object
{
"error": {
"message": "Bad request"
}
}
{
"error": {
"message": "Bad request: Invalid parameters: depositCoin"
}
}
{
"error": {
"message": "Method ETH/bitcoin not found"
}
}
{
"error": {
"message": "Invalid "affiliateId""
}
}
{
"error": {
"message": "Commission rate cannot be higher than 0.02"
}
}
{
"error": {
"message": "Invalid parameters: commissionRate: Must be a positive number"
}
}
- application/json
- Schema
- Example
Schema
error object
{
"error": {
"message": "Do not use the example affiliateId and x-sideshift-secret header from the documentation. Use your own from https://sideshift.ai/account"
}
}
- application/json
- Schema
- Example
Schema
error object
{
"error": {
"message": "Access denied. See https://sideshift.ai/access-denied"
}
}
- application/json
- Schema
- Example
Schema
error object
{
"error": {
"message": "Account not found"
}
}
- application/json
- Schema
- Example
Schema
error object
{
"error": {
"message": "Invalid coin"
}
}
{
"error": {
"message": "Invalid network"
}
}
{
"error": {
"message": "Amount too low. Settle amount is less than or equals to 0"
}
}
{
"error": {
"message": "Amount too low. Minimum deposit amount: 0.00010663."
}
}
{
"error": {
"message": "Amount too high. Maximum deposit amount: 0.5117083972"
}
}
{
"error": {
"message": "Cannot specify both depositAmount and settleAmount"
}
}