Skip to main content

Update a Phone Number

PUT 

/phone_numbers/:id

Updates the specific Phone Number by setting the values of any parameters passed in. Any parameters not provided will be unchanged.

Permissions

The API token must include the following scopes: Numbers.

Request

Path Parameters

    id uuidrequired

    Unique ID of the phone number

Body

required

    namestring

    The name given to the phone number. Helps to distinguish different phone numbers within your project.

    Example: Jenny
    call_handlerstring

    What type of handler you want to run on inbound calls.

    Possible values: [relay_script, relay_context, relay_topic, relay_application, laml_webhooks, laml_application, dialogflow, relay_connector, relay_sip_endpoint, relay_verto_endpoint, video_room]

    Example: relay_context
    call_receive_modestring

    How do you want to receive the incoming call. Possible values are: voice or fax. Default is voice.

    Example: voice
    call_request_urlstring

    The URL to make a request to when using the laml_webhooks call handler.

    Example:
    call_request_methodstring

    The HTTP method to use when making a request to the call_request_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    call_fallback_urlstring

    The fallback URL to make a request to when using the laml_webhooks call handler and the call_request_url fails.

    Example:
    call_fallback_methodstring

    The HTTP method to use when making a request to the call_fallback_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    call_status_callback_urlstring

    The URL to make status callbacks to when using the laml_webhooks call handler.

    Example:
    call_status_callback_methodstring

    The HTTP method to use when making a request to the call_status_callback_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    call_laml_application_idstring

    The ID of the LaML Application to use when using the laml_application call handler.

    Example: null
    call_dialogflow_agent_idstring

    The ID of the Dialogflow Agent to start when using the dialogflow call handler.

    Example: null
    call_relay_topicstring

    A string representing the Relay topic to forward incoming calls to. This is only used (and required) when call_handler is set to relay_topic. Alias of call_relay_application. If both are sent, call_relay_application takes precedence.

    Example: office
    call_relay_topic_status_callback_urlstring

    A string representing a URL to send status change messages to. This is only used (and required) when call_handler is set to relay_topic.

    Example: https://myapplication/handle_relay_callbacks
    call_relay_contextstringdeprecated

    This handler type is deprecated. Please use call_relay_application or call_relay_topic instead.

    Example: my_relay_app
    call_relay_context_status_callback_urlstringdeprecated

    This property is deprecated. Please use call_relay_topic_status_callback_url instead.

    Example: https://myapplication/handle_relay_callbacks
    call_relay_applicationstring

    The name of the Relay Application to send this call to when using the relay_application call handler. Alias of call_relay_context. If both are sent, call_relay_application takes precedence.

    Example: my_relay_app
    call_relay_connector_idstring

    The ID of the Relay Connector to send this call to when using the relay_connector call handler.

    Example: null
    call_sip_endpoint_idstring

    The ID of the Relay SIP Endpoint to send this call to when using the relay_sip_endpoint call handler.

    Example: null
    call_verto_resourcestring

    The name of the Verto Relay Endpoint to send this call to when using the relay_verto_endpoint call handler.

    Example:
    call_video_room_iduuid

    The ID of the Video Room to send this call to when using the video_room call handler.

    Example: fe4093d9-58c2-4931-b4b9-5679f82652c6
    message_handlerstring

    What type of handler you want to run on inbound messages. Possible values are: relay_context, relay_topic, relay_application, laml_webhooks, laml_application.

    Example: relay_application
    message_request_urlstring

    The URL to make a request to when using the laml_webhooks message handler.

    Example:
    message_request_methodstring

    The HTTP method to use when making a request to the message_request_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    message_fallback_urlstring

    The fallback URL to make a request to when using the laml_webhooks message handler and the message_request_url fails.

    Example:
    message_fallback_methodstring

    The HTTP method to use when making a request to the message_fallback_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    message_laml_application_idstring

    The ID of the LaML Application to use when using the laml_application message handler.

    Example: null
    message_relay_topicstring

    The name of the Relay Topic to send this message to when using the relay_topic message handler. Alias of message_relay_application. If both are sent, message_relay_application takes precedence.

    Example: my_relay_app
    message_relay_contextstringdeprecated

    This handler type is deprecated. Please use message_relay_application or message_relay_topic instead.

    Example: my_relay_app
    message_relay_applicationstring

    The name of the Relay Application to send this message to when using the relay_application message handler. Alias of message_relay_context. If both are sent, message_relay_application takes precedence.

    Example: my_relay_app

Responses

OK

Schema

    iduuid

    The unique identifier of the Phone Number on SignalWire. This can be used to find, update or delete the phone number programmatically.

    numberstringrequired

    The phone number in E164 format.

    Example: +15558675309
    namestring

    The name given to the phone number. Helps to distinguish different phone numbers within your project.

    Example: Jenny
    call_handlerstring

    What type of handler you want to run on inbound calls.

    Possible values: [relay_script, relay_context, relay_topic, relay_application, laml_webhooks, laml_application, dialogflow, relay_connector, relay_sip_endpoint, relay_verto_endpoint, video_room]

    Example: relay_context
    call_receive_modestring

    How do you want to receive the incoming call. Possible values are: voice or fax. Default is voice.

    Example: voice
    call_request_urlstring

    The URL to make a request to when using the laml_webhooks call handler.

    Example:
    call_request_methodstring

    The HTTP method to use when making a request to the call_request_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    call_fallback_urlstring

    The fallback URL to make a request to when using the laml_webhooks call handler and the call_request_url fails.

    Example:
    call_fallback_methodstring

    The HTTP method to use when making a request to the call_fallback_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    call_status_callback_urlstring

    The URL to make status callbacks to when using the laml_webhooks call handler.

    Example:
    call_status_callback_methodstring

    The HTTP method to use when making a request to the call_status_callback_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    call_laml_application_idstring

    The ID of the LaML Application to use when using the laml_application call handler.

    Example: null
    call_dialogflow_agent_idstring

    The ID of the Dialogflow Agent to start when using the dialogflow call handler.

    Example: null
    call_relay_topicstring

    A string representing the Relay topic to forward incoming calls to. This is only used (and required) when call_handler is set to relay_topic. Alias of call_relay_application. If both are sent, call_relay_application takes precedence.

    Example: office
    call_relay_topic_status_callback_urlstring

    A string representing a URL to send status change messages to. This is only used (and required) when call_handler is set to relay_topic.

    Example: https://myapplication/handle_relay_callbacks
    call_relay_contextstring

    The name of the Relay Context to send this call to when using the relay_context call handler. Alias of message_relay_application. If both are sent, call_relay_application takes precedence.

    Example: my_relay_app
    call_relay_context_status_callback_urlstring

    A string representing a URL to send status change messages to. This is only used (and required) when call_handler is set to relay_context.

    Example: https://myapplication/handle_relay_callbacks
    call_relay_applicationstring

    The name of the Relay Application to send this call to when using the relay_application call handler. Alias of call_relay_context. If both are sent, call_relay_application takes precedence.

    Example: my_relay_app
    call_relay_connector_idstring

    The ID of the Relay Connector to send this call to when using the relay_connector call handler.

    Example: null
    call_sip_endpoint_idstring

    The ID of the Relay SIP Endpoint to send this call to when using the relay_sip_endpoint call handler.

    Example: null
    call_verto_resourcestring

    The name of the Verto Relay Endpoint to send this call to when using the relay_verto_endpoint call handler.

    Example:
    call_video_room_iduuid

    The ID of the Video Room to send this call to when using the video_room call handler.

    Example: fe4093d9-58c2-4931-b4b9-5679f82652c6
    message_handlerstring

    What type of handler you want to run on inbound messages. Possible values are: relay_context, relay_topic, relay_application, laml_webhooks, laml_application.

    Example: relay_application
    message_request_urlstring

    The URL to make a request to when using the laml_webhooks message handler.

    Example:
    message_request_methodstring

    The HTTP method to use when making a request to the message_request_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    message_fallback_urlstring

    The fallback URL to make a request to when using the laml_webhooks message handler and the message_request_url fails.

    Example:
    message_fallback_methodstring

    The HTTP method to use when making a request to the message_fallback_url. Possible values are: POST or GET. Default is POST.

    Example: POST
    message_laml_application_idstring

    The ID of the LaML Application to use when using the laml_application message handler.

    Example: null
    message_relay_topicstring

    The name of the Relay Topic to send this message to when using the relay_topic message handler. Alias of message_relay_application. If both are sent, message_relay_application takes precedence.

    Example: my_relay_app
    message_relay_contextstring

    The name of the Relay Context to send this message to when using the relay_context message handler. Alias of message_relay_application. If both are sent, message_relay_application takes precedence.

    Example: my_relay_app
    message_relay_applicationstring

    The name of the Relay Application to send this message to when using the relay_application message handler. Alias of message_relay_context. If both are sent, message_relay_application takes precedence.

    Example: my_relay_app
    capabilitiesstring[]

    A list of communication methods this phone number supports. Possible values are: voice, fax, sms, mms.

    Example: ["voice","sms","mms","fax"]
    number_typestring

    The type of number this is defined as. Possible values are: toll-free or longcode.

    Example: toll-free
    e911_address_idstring

    A list of communication methods this phone number supports.

    Example: null
    created_atdate-time

    The date the number was added to your project.

    updated_atdate-time

    The date the number was last updated.

    next_billed_atdate-time

    The next date the number will be billed for.