Device Assignment
Unassign Device from Owner
Remove device-to-customer assignment
POST
/
api
/
ext-v1
/
deviceAssignment
/
unassignDeviceFromOwner
curl -X POST https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner \
-H "x-api-key: your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"deviceIdentifier": "SN-12345-ABCDE",
"customerEmail": "john.doe@example.com"
}'
const response = await fetch(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
{
method: 'POST',
headers: {
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
body: JSON.stringify({
deviceIdentifier: 'SN-12345-ABCDE',
customerEmail: 'john.doe@example.com'
})
}
);
const result = await response.json();
import requests
response = requests.post(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
headers={
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
json={
'deviceIdentifier': 'SN-12345-ABCDE',
'customerEmail': 'john.doe@example.com'
}
)
result = response.json()
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": ["SN-67890-FGHIJ"]
}
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": []
}
{
"error": "Customer not found for this organization"
}
{
"error": "Device is not assigned to this customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"currentDevices": ["SN-67890-FGHIJ", "SN-11111-KKKKK"]
}
{
"error": "Invalid email format"
}
{
"error": "Both deviceIdentifier and customerEmail are required"
}
{
"error": "Invalid JSON in request body"
}
Overview
Removes the device-to-customer assignment. Both records remain in the system; only the association is removed.After unassignment, device telemetry will no longer route to this customer. Reassign to new owner if device is still active.
Authentication
string
required
Your organization’s API key
Request Body
string
required
The unique identifier for the device (e.g., serial number, MAC address)
string
required
The email address of the customer to unassign the device from
Response
boolean
Indicates if the operation was successful
string
Description of the operation result
string
The unique identifier of the customer
string
The device identifier that was unassigned
array
Array of device identifiers still assigned to this customer after the unassignment
Examples
Request
curl -X POST https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner \
-H "x-api-key: your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"deviceIdentifier": "SN-12345-ABCDE",
"customerEmail": "john.doe@example.com"
}'
const response = await fetch(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
{
method: 'POST',
headers: {
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
body: JSON.stringify({
deviceIdentifier: 'SN-12345-ABCDE',
customerEmail: 'john.doe@example.com'
})
}
);
const result = await response.json();
import requests
response = requests.post(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
headers={
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
json={
'deviceIdentifier': 'SN-12345-ABCDE',
'customerEmail': 'john.doe@example.com'
}
)
result = response.json()
Response
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": ["SN-67890-FGHIJ"]
}
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": []
}
{
"error": "Customer not found for this organization"
}
{
"error": "Device is not assigned to this customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"currentDevices": ["SN-67890-FGHIJ", "SN-11111-KKKKK"]
}
curl -X POST https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner \
-H "x-api-key: your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"deviceIdentifier": "SN-12345-ABCDE",
"customerEmail": "john.doe@example.com"
}'
const response = await fetch(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
{
method: 'POST',
headers: {
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
body: JSON.stringify({
deviceIdentifier: 'SN-12345-ABCDE',
customerEmail: 'john.doe@example.com'
})
}
);
const result = await response.json();
import requests
response = requests.post(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
headers={
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
json={
'deviceIdentifier': 'SN-12345-ABCDE',
'customerEmail': 'john.doe@example.com'
}
)
result = response.json()
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": ["SN-67890-FGHIJ"]
}
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": []
}
{
"error": "Customer not found for this organization"
}
{
"error": "Device is not assigned to this customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"currentDevices": ["SN-67890-FGHIJ", "SN-11111-KKKKK"]
}
{
"error": "Invalid email format"
}
{
"error": "Both deviceIdentifier and customerEmail are required"
}
{
"error": "Invalid JSON in request body"
}
Status Codes
| Code | Description |
|---|---|
| 200 | Device successfully unassigned from customer |
| 400 | Invalid request (missing required fields, invalid email format, or device not assigned to customer) |
| 401 | Invalid or missing API key |
| 404 | Customer not found in your organization |
| 500 | Internal server error |
Notes
- Email format is validated before processing
- Non-destructive: customer and device records persist
- Response includes
devicesRemainingarray for tracking
Common Use Cases
- Device returns/replacements: Stop routing telemetry to this customer
- Ownership transfer: Unassign from old owner, then assign to new owner
- Account cleanup: Remove inactive devices from customer accounts
Transfer Pattern: Unassign from old owner → Assign to new owner. See Assign Device.
⌘I
curl -X POST https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner \
-H "x-api-key: your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"deviceIdentifier": "SN-12345-ABCDE",
"customerEmail": "john.doe@example.com"
}'
const response = await fetch(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
{
method: 'POST',
headers: {
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
body: JSON.stringify({
deviceIdentifier: 'SN-12345-ABCDE',
customerEmail: 'john.doe@example.com'
})
}
);
const result = await response.json();
import requests
response = requests.post(
'https://admin.telemetron.ai/api/ext-v1/deviceAssignment/unassignDeviceFromOwner',
headers={
'x-api-key': 'your_api_key_here',
'Content-Type': 'application/json'
},
json={
'deviceIdentifier': 'SN-12345-ABCDE',
'customerEmail': 'john.doe@example.com'
}
)
result = response.json()
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": ["SN-67890-FGHIJ"]
}
{
"success": true,
"message": "Device successfully unassigned from customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"devicesRemaining": []
}
{
"error": "Customer not found for this organization"
}
{
"error": "Device is not assigned to this customer",
"customerId": "cust_a1b2c3d4e5f6",
"deviceIdentifier": "SN-12345-ABCDE",
"currentDevices": ["SN-67890-FGHIJ", "SN-11111-KKKKK"]
}
{
"error": "Invalid email format"
}
{
"error": "Both deviceIdentifier and customerEmail are required"
}
{
"error": "Invalid JSON in request body"
}