Skip to main content
PATCH
/
v1
/
phone-numbers
/
{phone_number_id}
Update phone number
curl --request PATCH \
  --url https://api.callrounded.com/v1/phone-numbers/{phone_number_id} \
  --header 'Content-Type: application/json' \
  --header 'X-Api-Key: <api-key>' \
  --data '
{
  "name": "<string>",
  "inbound_agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "redirect": false,
  "redirect_phone_number": "<string>"
}
'
{
  "message": "<string>",
  "data": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "number": "<string>",
    "name": "<string>",
    "created_at": "2023-11-07T05:31:56Z",
    "type": "pstn",
    "inbound_agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "redirect": false,
    "redirect_phone_number": "<string>"
  },
  "error": {
    "details": [
      {
        "field": "email",
        "message": "Invalid email format"
      }
    ],
    "message": "An error occurred while processing your request",
    "status": 400,
    "type": "generic_error"
  },
  "status": 200
}

Authorizations

X-Api-Key
string
header
required

The API Key created in Rounded Studio.

Path Parameters

phone_number_id
string<uuid>
required

The ID of the phone number to update.

Body

application/json

The phone number data to update.

name
string | null

The phone number friendly name.

inbound_agent_id
string<uuid> | null

The agent ID that will handle incoming calls to this phone number.

redirect
boolean | null
default:false

Whether to redirect the phone number.

redirect_phone_number
string | null

The phone number to redirect to.

Response

Successfully updated phone number

message
string
required
data
PSTN Phone Number · object
required
error
ApiResponseError · object
Example:
{
"details": [
{
"field": "email",
"message": "Invalid email format"
}
],
"message": "An error occurred while processing your request",
"status": 400,
"type": "generic_error"
}
status
integer
default:200

HTTP status code of the response.