Devices
Rename a phone, or move it to another workspace
{ name } renames the phone. { workspaceId } moves it to another
workspace of the same organization; with both, the move runs first.
An API key is bound to one workspace, so it may rename its phones but
never move one out of it (403). A signed-in user needs the admin or
member role and access to both workspaces. A move is refused while
the phone runs or has queued sessions (409 device_in_use), and when
the target workspace is at its plan’s phone limit (402).
Retries: safe: renaming to the same name again changes nothing; a repeated move answers 400 (already in that workspace).
PATCH
/
v1
/
devices
/
{deviceId}
Rename a phone, or move it to another workspace
curl --request PATCH \
--url https://api.lusor.ai/v1/devices/{deviceId} \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"workspaceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
}
'const options = {
method: 'PATCH',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({workspaceId: '3c90c3cc-0d44-4b50-8888-8dd25736052a', name: '<string>'})
};
fetch('https://api.lusor.ai/v1/devices/{deviceId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.lusor.ai/v1/devices/{deviceId}"
payload = {
"workspaceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
}
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"data": {
"deviceId": "<string>",
"sourceWorkspaceId": "<string>",
"workspaceId": "<string>",
"name": "<string>"
}
}{
"error": "validation_error",
"details": {}
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}Authorizations
ApiKeyBearerAuth
Body
application/json
Was this page helpful?
⌘I
Rename a phone, or move it to another workspace
curl --request PATCH \
--url https://api.lusor.ai/v1/devices/{deviceId} \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"workspaceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
}
'const options = {
method: 'PATCH',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({workspaceId: '3c90c3cc-0d44-4b50-8888-8dd25736052a', name: '<string>'})
};
fetch('https://api.lusor.ai/v1/devices/{deviceId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.lusor.ai/v1/devices/{deviceId}"
payload = {
"workspaceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
}
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"data": {
"deviceId": "<string>",
"sourceWorkspaceId": "<string>",
"workspaceId": "<string>",
"name": "<string>"
}
}{
"error": "validation_error",
"details": {}
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}
