Search K
Appearance
Appearance
Activates a device on a reseller plan.
This is a special endpoint for resellers to activate a device on a reseller plan.
If you want to activate a device on a modern plan, see the V2 API.
The ID of the device to activate.
56892
integer
The ID of the reseller plan, which must relate to your reseller account.
10
integer
The expiry date for the activation in milliseconds since epoch. The device will be deactivated at this time.
1767698219828
date-time
curl -X GET \
'https://api.lightbug.cloud/api/devices/id/activateOnResellerPlan?resellerPlanId=10&expiry=1767698219828' \
-H "Content-Type: application/json"
fetch('https://api.lightbug.cloud/api/devices/id/activateOnResellerPlan?resellerPlanId=10&expiry=1767698219828', {headers:{'Content-Type':'application/json'}})
.then(response => response.json())
.then(data => console.log(data));
<?php
$url = 'https://api.lightbug.cloud/api/devices/id/activateOnResellerPlan';
$method = 'GET';
$headers = [
'Content-Type' => 'application/json',
];
$query = http_build_query([
'resellerPlanId' => '10',
'expiry' => '1767698219828',
]);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url . '?' . $query);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
?>
import requests
url = 'https://api.lightbug.cloud/api/devices/id/activateOnResellerPlan'
params = {
'resellerPlanId': '10',
'expiry': [
1767698219828
]
}
headers = {
'Content-Type': 'application/json'
}
response = requests.get(url, params=params, headers=headers)
print(response.json())