GET
https://api.cryptohopper.com/v1/subscription/plans/{plan_id}
Returns one subscription plan and whether the user has an active subscription on it (subscribed is 1 or 0).
Needs a valid access token, but no specific scope. Some internal plans return 404.
Example request
curl "https://api.cryptohopper.com/v1/subscription/plans/PLAN_ID" \
-H "access-token: YOUR_ACCESS_TOKEN"
const response = await fetch('https://api.cryptohopper.com/v1/subscription/plans/PLAN_ID', {
method: 'GET',
headers: {
"access-token": "YOUR_ACCESS_TOKEN"
}
});
const data = await response.json();
import requests
response = requests.get(
"https://api.cryptohopper.com/v1/subscription/plans/PLAN_ID",
headers={
"access-token": "YOUR_ACCESS_TOKEN"
},
)
data = response.json()
$ch = curl_init('https://api.cryptohopper.com/v1/subscription/plans/PLAN_ID');
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 |
|---|---|---|---|
plan_id |
string | Required | ID of the plan, as returned by Get subscription plans. |
Response
{
"data": {
"plan_id": "2",
"name": "Adventurer",
"description": "For traders who want more positions and faster checks.",
"price_month": "69.00",
"price_year": "690.00",
"subscribed": 0
}
}