Limits Mapping
Returns the limits Mapping .
Note: Rate limit for this API is 10req/min
Returns the all Config mapping
POST
https://api.onramp.money/onramp/api/v2/common/transaction/limits
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 |
---|---|---|
type* | String | 1 -> onramp 2 -> offramp 3 -> both |
{
"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 = {
type: 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/limits',
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 = {
type: 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/limits'
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": {
"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
}
}
}
}
Onramp Explanation
status -> 0 is for unsuccessful request, 1 is for a successful one.
data -> json containing onramp, offramp limits mapping.
Last updated