PhoneNumbers
Cancel a phone number
Stops the number’s monthly renewal. It keeps working until
lapsesAt, with no refund, then is released.
Retries: the cancellation is keyed on the number, so a repeat never cancels or bills twice.
POST
/
v1
/
workspaces
/
{workspaceId}
/
number-orders
/
cancellations
Cancel a phone number
curl --request POST \
--url https://api.lusor.ai/v1/workspaces/{workspaceId}/number-orders/cancellations \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"phoneNumberId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'const options = {
method: 'POST',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({phoneNumberId: '3c90c3cc-0d44-4b50-8888-8dd25736052a'})
};
fetch('https://api.lusor.ai/v1/workspaces/{workspaceId}/number-orders/cancellations', 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}/number-orders/cancellations"
payload = { "phoneNumberId": "3c90c3cc-0d44-4b50-8888-8dd25736052a" }
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"data": {
"phoneNumberId": "<string>",
"lapsesAt": "<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
Was this page helpful?
⌘I
Cancel a phone number
curl --request POST \
--url https://api.lusor.ai/v1/workspaces/{workspaceId}/number-orders/cancellations \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"phoneNumberId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'const options = {
method: 'POST',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({phoneNumberId: '3c90c3cc-0d44-4b50-8888-8dd25736052a'})
};
fetch('https://api.lusor.ai/v1/workspaces/{workspaceId}/number-orders/cancellations', 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}/number-orders/cancellations"
payload = { "phoneNumberId": "3c90c3cc-0d44-4b50-8888-8dd25736052a" }
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"data": {
"phoneNumberId": "<string>",
"lapsesAt": "<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>"
}
