GET
https://api.cryptohopper.com/v1/exchange/{exchange}/ipwhitelist
Returns the Cryptohopper IP addresses to add to the IP whitelist of your API key on an exchange. If your account has no IP group on that exchange yet, this call reserves one.
OAuth scope:
read About scopes
copy_ip_addresses is formatted the way the exchange's whitelist field expects. When no IP addresses apply, the strings are empty and total is 0.
Example request
curl "https://api.cryptohopper.com/v1/exchange/EXCHANGE/ipwhitelist" \
-H "access-token: YOUR_ACCESS_TOKEN"
const response = await fetch('https://api.cryptohopper.com/v1/exchange/EXCHANGE/ipwhitelist', {
method: 'GET',
headers: {
"access-token": "YOUR_ACCESS_TOKEN"
}
});
const data = await response.json();
import requests
response = requests.get(
"https://api.cryptohopper.com/v1/exchange/EXCHANGE/ipwhitelist",
headers={
"access-token": "YOUR_ACCESS_TOKEN"
},
)
data = response.json()
$ch = curl_init('https://api.cryptohopper.com/v1/exchange/EXCHANGE/ipwhitelist');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'access-token: YOUR_ACCESS_TOKEN',
],
]);
$data = json_decode(curl_exec($ch), true);
Parameters
Headers
| Name | Type | Required | Description |
|---|---|---|---|
access-token |
string | Required | The OAuth access token of the user. |
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
exchange |
string | Required | Exchange key as returned by Get available exchanges, for example binance or kucoin. Case insensitive. An unknown key is ignored. |
Response
{
"data": {
"ip_addresses": "203.0.113.10 203.0.113.11",
"total": 2,
"copy_ip_addresses": "203.0.113.10,203.0.113.11",
"show_ip_addresses": "203.0.113.10, 203.0.113.11"
}
}