Devices
Change a Lusor Phone's Internet exit country
Moves the phone’s Internet exit to country (lowercase ISO 3166-1
alpha-2, one of GET /internet/locations rotating), and optionally
its network (home or mobile; omit it to keep the current one).
A change re-rolls the phone’s IP and moves its GPS location. Not
billed.
A phone on its static IP answers 409 persistent_ip_active: take it
off with DELETE …/static-ip first. An API key may change phones in
its own workspace; a signed-in user needs the admin or member role.
Retries: safe: setting the same country and network again changes nothing (changed: false).
PUT
/
v1
/
workspaces
/
{workspaceId}
/
devices
/
{deviceId}
/
internet-location
Change a Lusor Phone's Internet exit country
curl --request PUT \
--url https://api.lusor.ai/v1/workspaces/{workspaceId}/devices/{deviceId}/internet-location \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"country": "<string>"
}
'const options = {
method: 'PUT',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({country: '<string>'})
};
fetch('https://api.lusor.ai/v1/workspaces/{workspaceId}/devices/{deviceId}/internet-location', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.lusor.ai/v1/workspaces/{workspaceId}/devices/{deviceId}/internet-location"
payload = { "country": "<string>" }
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text){
"data": {
"country": "<string>",
"generation": 123,
"applied": "route",
"network": "home",
"changed": true
}
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}Authorizations
ApiKeyBearerAuth
Path Parameters
Body
application/json
Was this page helpful?
⌘I
Change a Lusor Phone's Internet exit country
curl --request PUT \
--url https://api.lusor.ai/v1/workspaces/{workspaceId}/devices/{deviceId}/internet-location \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"country": "<string>"
}
'const options = {
method: 'PUT',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({country: '<string>'})
};
fetch('https://api.lusor.ai/v1/workspaces/{workspaceId}/devices/{deviceId}/internet-location', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.lusor.ai/v1/workspaces/{workspaceId}/devices/{deviceId}/internet-location"
payload = { "country": "<string>" }
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text){
"data": {
"country": "<string>",
"generation": 123,
"applied": "route",
"network": "home",
"changed": true
}
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}
