Coin limits mapping
Returns the coin limits Mapping .
Note: Rate limit for this API is 10req/min
Returns the all coin limits mapping
POST
https://api.onramp.money/onramp/api/v2/common/transaction/allCoinLimits
Headers
Name | Type | Description |
---|---|---|
X-ONRAMP-APIKEY* | String | Your api key |
X-ONRAMP-PAYLOAD* | String | payload generated for the request |
X-ONRAMP-SIGNATURE* | String | signature generated for the request |
Request Body
Name | Type | Description |
---|---|---|
fiatType* | String | fiatType as returned from the all Config endpoint. |
{
"status": 1,
"code": 200,
"data": {
"onramp": {
"1": {
"min": 100,
"max": 500000
},
"2": {
"min": 300,
"max": 50000
},
"3": {
"min": 50,
"max": 75000
},
"4": {
"min": 200,
"max": 500000
},
"5": {
"min": 300000,
"max": 450000000
},
"6": {
"min": 5000,
"max": 2000000
},
"7": {
"min": 55,
"max": 50000
},
"8": {
"min": 19,
"max": 45000
},
"9": {
"min": 20000,
"max": 41000000
},
"10": {
"min": 5000,
"max": 8000000
},
"12": {
"min": 12,
"max": 8000000
},
"14": {
"min": 160000,
"max": 1000000000
}
}
}
}
Sample Request
var CryptoJS = require('crypto-js');
var axios = require('axios');
async function allLimitsMapping() {
try {
let body = {
fiatType: 1
}
let payload = {
timestamp: new Date().getTime(),
body
}
let apiKey = 'API_KEY', apiSecret = 'API_SECRET';
payload = Buffer.from(JSON.stringify(payload)).toString('base64');
let signature = CryptoJS.enc.Hex.stringify(CryptoJS.HmacSHA512(payload, apiSecret));
let options = {
url: 'https://api.onramp.money/onramp/api/v2/common/transaction/allCoinLimits',
method: 'POST',
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json;charset=UTF-8',
'X-ONRAMP-SIGNATURE': signature,
'X-ONRAMP-APIKEY': apiKey,
'X-ONRAMP-PAYLOAD': payload
},
data: body
};
let data = await axios(options)
console.log(data?.data);
} catch (error) {
console.log(error?.response?.data)
}
}
allLimitsMapping();
import json
import requests
import hashlib
import hmac
from base64 import b64encode
from datetime import datetime
async def all_limits_mapping():
try:
body = {
fiatType: 1
}
payload = {
"timestamp": int(datetime.now().timestamp() * 1000),
"body": body
}
api_key = 'API_KEY'
api_secret = 'API_SECRET'
payload_base64 = b64encode(json.dumps(payload).encode()).decode()
signature = hmac.new(api_secret.encode(), payload_base64.encode(), hashlib.sha512).hexdigest()
url = 'https://api.onramp.money/onramp/api/v2/common/transaction/allCoinLimits'
headers = {
'Accept': 'application/json',
'Content-Type': 'application/json;charset=UTF-8',
'X-ONRAMP-SIGNATURE': signature,
'X-ONRAMP-APIKEY': api_key,
'X-ONRAMP-PAYLOAD': payload_base64
}
options = {
'url': url,
'method': 'POST',
'headers': headers,
'json': body
}
response = await requests.post(**options)
print(response.json())
except Exception as error:
print(error)
await all_limits_mapping()
{
"status": 1,
"code": 200,
"data": {
"0": {
"0": 2123.14,
"1": 182,
"5": 182,
"10002": 4423.22,
"10004": 4423.22,
"10116": 3619,
"10168": 182,
"10174": 5549.13
},
"1": {
"0": 2112.28,
"1": 182,
"5": 182,
"10007": 990.13
},
"2": {
"10008": 1250.62,
"10009": 1250.62,
"10175": 1250.62
},
"3": {
"10008": 795.77,
"10009": 182,
"10175": 578.74
},
"4": {
"1": 182,
"10010": 329.08
},
"5": {
"10011": 182,
"10176": 182
},
"6": {
"0": 2388.42,
"1": 182,
"2": 586.25,
"3": 100,
"5": 182,
"13": 191.07,
"16": 1365,
"17": 1365,
"18": 1365,
"19": 1365,
"20": 1365,
"21": 1365,
"10013": 238.84,
"10116": 2453.56,
"10169": 238.84,
"10171": 238.84,
"10173": 2496.98
},
"10": {
"1": 182,
"5": 182,
"10014": 182
},
"13": {
"1": 182,
"5": 182,
"10017": 791.82
},
"14": {
"0": 2167.59,
"1": 182,
"5": 182,
"10018": 182,
"10177": 182
},
"15": {
"10019": 182
},
"16": {
"0": 2163.03,
"1": 182,
"2": 182,
"5": 182
},
"18": {
"1": 182,
"5": 182,
"10008": 182,
"10021": 182
},
"19": {
"1": 182,
"10022": 182
},
"20": {
"1": 182,
"5": 182,
"8": 182
},
"22": {
"10024": 182
},
"24": {
"1": 182,
"5": 182,
"10025": 420.42
},
"26": {
"10026": 182
},
"27": {
"1": 182,
"10027": 182
},
"28": {
"0": 2177.72
},
"29": {
"0": 2153.21
},
"32": {
"0": 2161.28
},
"34": {
"0": 2772.89,
"1": 182,
"10028": 182
},
"35": {
"10029": 182
},
"37": {
"10179": 182
},
"40": {
"0": 2103.79,
"1": 182
},
"42": {
"0": 2212.29,
"1": 182
},
"43": {
"0": 2094,
"3": 182
},
"46": {
"0": 2112
},
"50": {
"0": 2164.11
},
"51": {
"10033": 182
},
"52": {
"0": 2143.2,
"1": 182,
"10180": 182
},
"53": {
"0": 1604.31
},
"54": {
"0": 5005,
"1": 182,
"2": 1001,
"3": 100,
"4": 200.2,
"5": 1001,
"8": 1001,
"10": 100,
"11": 100.1,
"13": 1001,
"10013": 1001,
"10039": 1001,
"10042": 1001,
"10046": 1092,
"10076": 5005,
"10116": 182,
"10163": 1001,
"10181": 391.3,
"10208": 1001
},
}
}
Onramp Explanation
status -> 0 is for unsuccessful request, 1 is for a successful one.
data -> JSON that encompasses a mapping of coin limits. The JSON structure adheres to the format: {coinId: {chainId: {}}}.
Last updated