{ "components": { "securitySchemes": { "accountSid_authToken": { "scheme": "basic", "type": "http" } }, "schemas": { "authorization_document_enum_status": { "type": "string", "enum": [ "opened", "signing", "signed", "canceled", "failed" ], "description": "The status of the authorization document. Can be: `opened`, `signing`, `signed`, `canceled`, or `failed`." }, "numbers.v1.bulk_eligibility": { "type": "object", "properties": { "request_id": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^EC[0-9a-fA-F]{32}$", "nullable": true, "description": "The SID of the bulk eligibility check that you want to know about." }, "url": { "type": "string", "format": "uri", "nullable": true, "description": "This is the url of the request that you're trying to reach out to locate the resource." }, "results": { "type": "array", "items": {}, "nullable": true, "description": "The result set that contains the eligibility check response for each requested number, each result has at least the following attributes: phone_number: The requested phone number ,hosting_account_sid: The account sid where the phone number will be hosted, country: Phone number\u2019s country, eligibility_status: Indicates the eligibility status of the PN (Eligible/Ineligible), eligibility_sub_status: Indicates the sub status of the eligibility , ineligibility_reason: Reason for number's ineligibility (if applicable), next_step: Suggested next step in the hosting process based on the eligibility status." }, "friendly_name": { "type": "string", "nullable": true, "description": "This is the string that you assigned as a friendly name for describing the eligibility check request." }, "status": { "type": "string", "nullable": true, "description": "This is the status of the bulk eligibility check request. (Example: COMPLETE, IN_PROGRESS)" }, "date_created": { "type": "string", "format": "date-time", "nullable": true }, "date_completed": { "type": "string", "format": "date-time", "nullable": true } } }, "bulk_eligibility_enum_eligibility_status": { "type": "string", "enum": [ "ineligible", "eligible" ] }, "bulk_eligibility_enum_eligibility_sub_status": { "type": "string", "enum": [ "country-ineligible", "number-format-ineligible", "number-type-ineligible", "carrier-ineligible", "already-in-twilio", "internal-processing-error", "invalid-phone-number", "invalid-hosting-account-sid", "eligible", "eligible-by-manual-process" ] }, "dependent_order_enum_status": { "type": "string", "enum": [ "twilio-processing", "received", "pending-verification", "verified", "pending-loa", "carrier-processing", "testing", "completed", "failed", "action-required" ], "description": "The status of the hosted number order. Can be: `twilio-processing`, `received`, `pending-verification`, `verified`, `pending-loa`, `carrier-processing`, `testing`, `completed`, `failed`, or `action-required`." }, "dependent_order_enum_verification_type": { "type": "string", "enum": [ "phone-call", "phone-bill" ], "description": "The method used to verify ownership of the number to be hosted. Can be: `phone-call` or `phone-bill` and the default is `phone-call`." }, "numbers.v1.eligibility": { "type": "object", "properties": { "results": { "type": "array", "items": {}, "nullable": true, "description": "The result set that contains the eligibility check response for the requested number, each result has at least the following attributes: phone_number: The requested phone number ,hosting_account_sid: The account sid where the phone number will be hosted, date_last_checked: Datetime (ISO 8601) when the PN was last checked for eligibility, country: Phone number\u2019s country, eligibility_status: Indicates the eligibility status of the PN (Eligible/Ineligible), eligibility_sub_status: Indicates the sub status of the eligibility , ineligibility_reason: Reason for number's ineligibility (if applicable), next_step: Suggested next step in the hosting process based on the eligibility status." } } }, "eligibility_enum_eligibility_status": { "type": "string", "enum": [ "ineligible", "eligible" ] }, "eligibility_enum_eligibility_sub_status": { "type": "string", "enum": [ "country-ineligible", "number-format-ineligible", "number-type-ineligible", "carrier-ineligible", "already-in-twilio", "internal-processing-error", "invalid-phone-number", "invalid-hosting-account-sid", "eligible" ] }, "hosted_number_order_enum_status": { "type": "string", "enum": [ "twilio-processing", "received", "pending-verification", "verified", "pending-loa", "carrier-processing", "testing", "completed", "failed", "action-required" ], "description": "The status of the hosted number order. Can be: `twilio-processing`, `received`, `pending-verification`, `verified`, `pending-loa`, `carrier-processing`, `testing`, `completed`, `failed`, or `action-required`." }, "hosted_number_order_enum_verification_type": { "type": "string", "enum": [ "phone-call", "phone-bill" ], "description": "The method used to verify ownership of the number to be hosted. Can be: `phone-call` or `phone-bill` and the default is `phone-call`." }, "numbers.v1.porting_port_in": { "type": "object", "properties": { "port_in_request_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^KW[0-9a-fA-F]{32}$", "nullable": true, "description": "The SID of the Port In request. This is a unique identifier of the port in request." }, "url": { "type": "string", "format": "uri", "nullable": true, "description": "The URL of this Port In request" }, "account_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "nullable": true, "description": "Account Sid or subaccount where the phone number(s) will be Ported" }, "notification_emails": { "type": "array", "items": { "type": "string" }, "nullable": true, "description": "Additional emails to send a copy of the signed LOA to." }, "target_port_in_date": { "type": "string", "format": "date", "nullable": true, "description": "Target date to port the number. We cannot guarantee that this date will be honored by the other carriers, please work with Ops to get a confirmation of the firm order commitment (FOC) date. Expected format is ISO Local Date, example: \u20182011-12-03`. This date must be at least 7 days in the future for US ports and 10 days in the future for Japanese ports. If a start and end range is provided, the date will be converted to its UTC equivalent with the ranges as reference and stored in UTC. We can't guarantee the exact date and time, as this depends on the losing carrier." }, "target_port_in_time_range_start": { "type": "string", "nullable": true, "description": "The earliest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: \u201810:15:00-08:00'. We can't guarantee the exact date and time, as this depends on the losing carrier. The time will be stored and returned as UTC standard timezone." }, "target_port_in_time_range_end": { "type": "string", "nullable": true, "description": "The latest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: \u201810:15:00-08:00'. We can't guarantee the exact date and time, as this depends on the losing carrier. The time will be stored and returned as UTC standard timezone." }, "port_in_request_status": { "type": "string", "nullable": true, "description": "The status of the port in request. The possible values are: In progress, Completed, Expired, In review, Waiting for Signature, Action Required, and Canceled." }, "order_cancellation_reason": { "type": "string", "nullable": true, "description": "If the order is cancelled this field will provide further context on the cause of the cancellation." }, "losing_carrier_information": { "nullable": true, "$ref": "#/components/schemas/numbers.v1.porting_losing_carrier_information", "description": "Details regarding the customer\u2019s information with the losing carrier. These values will be used to generate the letter of authorization and should match the losing carrier\u2019s data as closely as possible to ensure the port is accepted." }, "phone_numbers": { "type": "array", "items": { "$ref": "#/components/schemas/numbers.v1.porting_port_in_phone_number_result" }, "nullable": true }, "bundle_sid": { "type": "string", "nullable": true, "description": "The bundle sid is an optional identifier to reference a group of regulatory documents for a port request." }, "portability_advance_carrier": { "type": "string", "nullable": true, "description": "A field only required for Japan port in requests. It is a unique identifier for the donor carrier service the line is being ported from." }, "auto_cancel_approval_numbers": { "type": "string", "nullable": true, "description": "Japan specific field, indicates the number of phone numbers to automatically approve for cancellation." }, "documents": { "type": "array", "items": { "type": "string" }, "nullable": true, "description": "List of document SIDs for all phone numbers included in the port in request. At least one document SID referring to a document of the type Utility Bill is required." }, "date_created": { "type": "string", "format": "date-time", "nullable": true }, "support_ticket_id": { "type": "integer", "description": "Unique ID of the request's support ticket" }, "signature_request_url": { "format": "uri", "type": "string", "nullable": true } } }, "numbers.v1.porting_port_in_phone_number": { "type": "object", "properties": { "port_in_request_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^KW[0-9a-fA-F]{32}$", "nullable": true, "description": "The unique identifier for the port in request that this phone number is associated with." }, "phone_number_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^PU[0-9a-fA-F]{32}$", "nullable": true, "description": "The unique identifier for this phone number associated with this port in request." }, "url": { "type": "string", "format": "uri", "nullable": true, "description": "URL reference for this resource." }, "account_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "nullable": true, "description": "Account Sid or subaccount where the phone number(s) will be Ported." }, "phone_number_type": { "type": "string", "nullable": true, "description": "The number type of the phone number. This can be: toll-free, local, mobile or unknown. This field may be null if the number is not portable or if the portability for a number has not yet been evaluated." }, "date_created": { "type": "string", "format": "date-time", "nullable": true, "description": "The timestamp for when this port in phone number was created." }, "country": { "type": "string", "format": "iso-country-code", "nullable": true, "description": "The ISO country code that this number is associated with. This field may be null if the number is not portable or if the portability for a number has not yet been evaluated." }, "missing_required_fields": { "type": "boolean", "nullable": true, "description": "Indicates if the phone number is missing required fields such as a PIN or account number. This field may be null if the number is not portable or if the portability for a number has not yet been evaluated." }, "last_updated": { "type": "string", "format": "date-time", "nullable": true, "description": "Timestamp indicating when the Port In Phone Number resource was last modified." }, "phone_number": { "type": "string", "format": "phone-number", "nullable": true, "description": "Phone number to be ported. This will be in the E164 Format." }, "portable": { "type": "boolean", "nullable": true, "description": "If the number is portable by Twilio or not. This field may be null if the number portability has not yet been evaluated. If a number is not portable reference the `not_portability_reason_code` and `not_portability_reason` fields for more details" }, "not_portability_reason": { "type": "string", "nullable": true, "description": "The not portability reason code description. This field may be null if the number is portable or if the portability for a number has not yet been evaluated." }, "not_portability_reason_code": { "type": "integer", "nullable": true, "description": "The not portability reason code. This field may be null if the number is portable or if the portability for a number has not yet been evaluated." }, "port_in_phone_number_status": { "type": "string", "nullable": true, "description": "The status of the port in phone number." }, "port_out_pin": { "type": "integer", "nullable": true, "description": "The pin required by the losing carrier to do the port out." }, "rejection_reason": { "type": "string", "nullable": true, "description": "The description of the rejection reason provided by the losing carrier. This field may be null if the number has not been rejected by the losing carrier." }, "rejection_reason_code": { "type": "integer", "nullable": true, "description": "The code for the rejection reason provided by the losing carrier. This field may be null if the number has not been rejected by the losing carrier." }, "port_date": { "type": "string", "format": "date-time", "nullable": true, "description": "The timestamp the phone number will be ported. This will only be set once a port date has been confirmed. Not all carriers can guarantee a specific time on the port date. Twilio will try its best to get the port completed by this time on the port date. Please subscribe to webhooks for confirmation on when a port has actually been completed." } } }, "numbers.v1.porting_portability": { "type": "object", "properties": { "phone_number": { "type": "string", "format": "phone-number", "nullable": true, "description": "The phone number which portability is to be checked. Phone numbers are in E.164 format (e.g. +16175551212).", "x-twilio": { "pii": { "handling": "standard", "deleteSla": 0 } } }, "account_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "nullable": true, "description": "Account Sid that the phone number belongs to in Twilio. This is only returned for phone numbers that already exist in Twilio\u2019s inventory and belong to your account or sub account." }, "portable": { "type": "boolean", "nullable": true, "description": "Boolean flag indicates if the phone number can be ported into Twilio through the Porting API or not." }, "pin_and_account_number_required": { "type": "boolean", "nullable": true, "description": "Indicates if the port in process will require a personal identification number (PIN) and an account number for this phone number. If this is true you will be required to submit both a PIN and account number from the losing carrier for this number when opening a port in request. These fields will be required in order to complete the port in process to Twilio." }, "not_portable_reason": { "type": "string", "nullable": true, "description": "Reason why the phone number cannot be ported into Twilio, `null` otherwise." }, "not_portable_reason_code": { "type": "integer", "nullable": true, "description": "The Portability Reason Code for the phone number if it cannot be ported into Twilio, `null` otherwise." }, "number_type": { "$ref": "#/components/schemas/porting_portability_enum_number_type" }, "country": { "type": "string", "format": "iso-country-code", "nullable": true, "description": "Country the phone number belongs to." }, "url": { "type": "string", "format": "uri", "nullable": true, "description": "This is the url of the request that you're trying to reach out to locate the resource." } } }, "porting_portability_enum_number_type": { "type": "string", "enum": [ "LOCAL", "UNKNOWN", "MOBILE", "TOLL-FREE" ], "description": "The type of the requested phone number. One of `LOCAL`, `UNKNOWN`, `MOBILE`, `TOLL-FREE`." }, "numbers.v1.porting_webhook_configuration": { "type": "object", "properties": { "url": { "type": "string", "format": "uri", "nullable": true, "description": "The URL of the webhook configuration request" }, "port_in_target_url": { "type": "string", "format": "uri", "nullable": true, "description": "The complete webhook url that will be called when a notification event for port in request or port in phone number happens" }, "port_out_target_url": { "type": "string", "format": "uri", "nullable": true, "description": "The complete webhook url that will be called when a notification event for a port out phone number happens." }, "notifications_of": { "type": "array", "items": { "type": "string" }, "nullable": true, "description": "A list to filter what notification events to receive for this account and its sub accounts. If it is an empty list, then it means that there are no filters for the notifications events to send in each webhook and all events will get sent." } } }, "numbers.v1.porting_webhook_configuration_delete": { "type": "object", "properties": { "url": { "type": "string", "format": "uri", "nullable": true, "description": "The URL of the webhook configuration request" }, "webhook_type": { "$ref": "#/components/schemas/porting_webhook_configuration_delete_enum_webhook_type" } } }, "porting_webhook_configuration_delete_enum_webhook_type": { "type": "string", "enum": [ "PORT_IN", "PORT_OUT" ], "description": "The of the webhook type of the configuration to be deleted" }, "numbers.v1.porting_webhook_configuration_fetch": { "type": "object", "properties": { "url": { "type": "string", "format": "uri", "nullable": true, "description": "The URL of the webhook configuration request" }, "port_in_target_url": { "type": "string", "format": "uri", "nullable": true, "description": "The complete webhook url that will be called when a notification event for port in request or port in phone number happens" }, "port_out_target_url": { "type": "string", "format": "uri", "nullable": true, "description": "The complete webhook url that will be called when a notification event for a port out phone number happens." }, "notifications_of": { "type": "array", "items": { "type": "string" }, "nullable": true, "description": "A list to filter what notification events to receive for this account and its sub accounts. If it is an empty list, then it means that there are no filters for the notifications events to send in each webhook and all events will get sent." }, "port_in_target_date_created": { "type": "string", "format": "date-time", "nullable": true, "description": "Creation date for the port in webhook configuration" }, "port_out_target_date_created": { "type": "string", "format": "date-time", "nullable": true, "description": "Creation date for the port out webhook configuration" } } }, "numbers.v1.signing_request_configuration": { "type": "object", "properties": { "logo_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^RD[0-9a-fA-F]{32}$", "nullable": true, "description": "The SID of the document that includes the logo that will appear in the LOA. To upload documents follow the following guide: https://www.twilio.com/docs/phone-numbers/regulatory/getting-started/create-new-bundle-public-rest-apis#supporting-document-create " }, "friendly_name": { "type": "string", "nullable": true, "description": "This is the string that you assigned as a friendly name for describing the creation of the configuration." }, "product": { "type": "string", "nullable": true, "description": "The product or service for which is requesting the signature." }, "country": { "type": "string", "format": "iso-country-code", "nullable": true, "description": "The country ISO code to apply the configuration." }, "email_subject": { "type": "string", "nullable": true, "description": "Subject of the email that the end client will receive ex: \u201cTwilio Hosting Request\u201d, maximum length of 255 characters." }, "email_message": { "type": "string", "nullable": true, "description": "Content of the email that the end client will receive ex: \u201cThis is a Hosting request from Twilio, please check the document and sign it\u201d, maximum length of 5,000 characters." }, "url_redirection": { "type": "string", "nullable": true, "description": "Url the end client will be redirected after signing a document." }, "url": { "type": "string", "format": "uri", "nullable": true } } }, "numbers.v1.port_in_request_list": { "type": "object", "properties": { "port_in_request_sid": { "type": "string", "nullable": false, "description": "The SID of the Port-in request" }, "port_in_request_status": { "type": "string", "nullable": true, "description": "Status of the Port In Request" }, "status_last_updated_timestamp": { "type": "string", "nullable": true, "description": "The last updated timestamp of the request" }, "phone_numbers_requested": { "type": "integer", "nullable": true, "description": "Amount of phone numbers requested" }, "phone_numbers_ported": { "type": "integer", "nullable": true, "description": "Amount of phone numbers ported" }, "suggested_action": { "type": "string", "nullable": true, "description": "Suggested action on this ticket" } } }, "numbers.v1.port_in_request_list_meta": { "type": "object", "properties": { "previous_token": { "type": "string", "nullable": true }, "next_token": { "type": "string", "nullable": true } } }, "numbers.v1.porting_port_in_create": { "title": "PortIn request", "type": "object", "properties": { "account_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "description": "Account Sid or subaccount where the phone number(s) will be Ported" }, "documents": { "type": "array", "items": { "type": "string" }, "description": "List of document SIDs for all phone numbers included in the port in request. At least one document SID referring to a document of the type Utility Bill is required." }, "phone_numbers": { "type": "array", "minItems": 1, "items": { "type": "object", "properties": { "phone_number": { "type": "string", "description": "Phone number to be ported. This must be in the E164 Format.", "x-twilio": { "shortDescription": "Phone number to be ported. This must be in the E164 Format." } }, "pin": { "type": "string", "description": "Some losing carriers require a PIN to authorize the port of a phone number. If the phone number is a US mobile phone number, the PIN is mandatory to process a porting request. Other carriers and number types may also require a PIN, you'll need to contact the losing carrier to determine what your phone number's PIN is.", "x-twilio": { "shortDescription": "The port out pin from the losing carrier." } } }, "required": [ "phone_number" ] }, "description": "List of phone numbers to be ported. Maximum of 1,000 phone numbers per request." }, "losing_carrier_information": { "$ref": "#/components/schemas/numbers.v1.porting_losing_carrier_information", "description": "Details regarding the customer's information with the losing carrier. These values will be used to generate the letter of authorization and should match the losing carrier's data as closely as possible to ensure the port is accepted." }, "notification_emails": { "type": "array", "items": { "type": "string" }, "nullable": true, "description": "Additional emails to send a copy of the signed LOA to." }, "target_port_in_date": { "type": "string", "format": "date", "nullable": true, "description": "Target date to port the number. We cannot guarantee that this date will be honored by the other carriers, please work with Ops to get a confirmation of the firm order commitment (FOC) date. Expected format is ISO Local Date, example: \u20182011-12-03`. This date must be at least 7 days in the future for US ports and 10 days in the future for Japanese ports. We can't guarantee the exact date and time, as this depends on the losing carrier" }, "target_port_in_time_range_start": { "type": "string", "nullable": true, "description": "The earliest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: \u201810:15:00-08:00'. We can't guarantee the exact date and time, as this depends on the losing carrier" }, "target_port_in_time_range_end": { "type": "string", "nullable": true, "description": "The latest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: \u201810:15:00-08:00'. We can't guarantee the exact date and time, as this depends on the losing carrier" }, "bundle_sid": { "type": "string", "nullable": true, "description": "The bundle sid is an optional identifier to reference a group of regulatory documents for a port request." }, "portability_advance_carrier": { "type": "string", "nullable": true, "description": "A field only required for Japan port in requests. It is a unique identifier for the donor carrier service the line is being ported from." }, "auto_cancel_approval_numbers": { "type": "string", "minLength": 0, "nullable": true, "description": "Japan specific field, indicates the number of phone numbers to automatically approve for cancellation." } }, "required": [ "account_sid", "documents", "losing_carrier_information" ] }, "numbers.v1.porting_losing_carrier_information": { "title": "Losing carrier information", "type": "object", "properties": { "customer_name": { "type": "string", "description": "Customer name as it is registered with the losing carrier. This can be an individual or a business name depending on the customer type selected." }, "account_number": { "type": "string", "description": "The account number of the customer for the losing carrier. Only require for mobile phone numbers." }, "account_telephone_number": { "type": "string", "description": "The account phone number of the customer for the losing carrier." }, "address_sid": { "type": "string", "description": "If you already have an Address SID that represents the address needed for the LOA, you can provide an Address SID instead of providing the address object in the request body. This will copy the address into the port in request. If changes are made to the Address SID after port in request creation, those changes will not be reflected in the port in request." }, "address": { "$ref": "#/components/schemas/numbers.v1.porting_address", "description": "The customer\u2019s billing address with the losing carrier. It must match the address they have registered with the losing carrier." }, "authorized_representative": { "type": "string", "description": "The first and last name of the person listed with the losing carrier who is authorized to make changes on the account." }, "authorized_representative_email": { "type": "string", "format": "email", "description": "Email address of the person (owner of the number) who will sign the letter of authorization for the port in request. This email address should belong to the person named in as the authorized representative." }, "customer_type": { "type": "string", "enum": [ "Business", "Individual" ], "description": "The type of customer account in the losing carrier. This should either be: 'Individual' or 'Business'." }, "authorized_representative_katakana": { "type": "string" }, "sub_municipality": { "type": "string" }, "building": { "type": "string" }, "katakana_name": { "type": "string" } }, "required": [ "customer_name", "authorized_representative", "authorized_representative_email" ] }, "numbers.v1.porting_address": { "title": "Address", "type": "object", "properties": { "street": { "type": "string", "description": "The street address, ex: 101 Spear St" }, "street_2": { "type": "string", "description": "The building information, ex : 5th floor." }, "city": { "type": "string", "description": "The city name, ex: San Francisco." }, "state": { "type": "string", "description": "The state name, ex: CA or California. Note this should match the losing carrier\u2019s information exactly. So if they spell out the entire state\u2019s name instead of abbreviating it, please do so." }, "zip": { "type": "string", "description": "The zip code, ex: 94105." }, "country": { "type": "string", "description": "The country, ex: USA." } }, "required": [ "street", "city", "state", "zip", "country" ] }, "numbers.v1.porting_port_in_phone_number_result": { "title": "Phone number result", "type": "object", "properties": { "not_portability_reason": { "type": "string", "nullable": true, "description": "The not portability reason code description. This field may be null if the number is portable or if the portability for a number has not yet been evaluated." }, "not_portability_reason_code": { "type": "integer", "nullable": true, "description": "The not portability reason code. This field may be null if the number is portable or if the portability for a number has not yet been evaluated." }, "number_type": { "type": "string", "nullable": true, "description": "The number type of the phone number. This can be: toll-free, local, mobile or unknown. This field may be null if the number is not portable or if the portability for a number has not yet been evaluated." }, "phone_number": { "type": "string", "nullable": false, "description": "Phone number to be ported. This will be in the E164 Format." }, "port_date": { "type": "string", "nullable": true, "format": "date-time", "description": "The timestamp the phone number will be ported. This will only be set once a port date has been confirmed. Not all carriers can guarantee a specific time on the port date. Twilio will try its best to get the port completed by this time on the port date. Please subscribe to webhooks for confirmation on when a port has actually been completed." }, "port_in_phone_number_sid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^PU[0-9a-fA-F]{32}$", "description": "The SID of the Phone number. This is a unique identifier of the phone number." }, "port_in_phone_number_status": { "type": "string", "nullable": false, "description": "The status of the port in phone number." }, "portable": { "type": "boolean", "nullable": true, "description": "Whether the number is portable by Twilio or not. This field may be null if the number portability has not yet been evaluated. If a number is not portable reference the `not_portability_reason_code` and `not_portability_reason` fields for more details" }, "rejection_reason": { "type": "string", "nullable": true, "description": "The description of the rejection reason provided by the losing carrier. This field may be null if the number has not been rejected by the losing carrier." }, "rejection_reason_code": { "type": "string", "nullable": true, "description": "The code for the rejection reason provided by the losing carrier. This field may be null if the number has not been rejected by the losing carrier." }, "status_last_time_updated_timestamp": { "type": "string", "nullable": true, "description": "Timestamp indicating when the Port In Phone Number resource was last modified." }, "external_porting_vendor_phone_number_id": { "type": "string", "nullable": true } } }, "numbers.v1.available_phone_number": { "type": "object", "properties": { "Did": { "type": "string", "format": "phone-number", "nullable": true, "description": "The phone number in E.164 format." }, "InventoryDidSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^ID[0-9a-fA-F]{32}$", "nullable": true, "description": "The unique string that identifies the inventory DID resource." }, "FriendlyName": { "type": "string", "nullable": true, "description": "A human-readable phone number in national format." }, "Type": { "type": "string", "nullable": true, "description": "The type of phone number. Can be Local, Mobile, TollFree, etc." }, "Npa": { "type": "string", "nullable": true, "description": "The North American Numbering Plan (NANP) area code of the phone number." }, "Nxx": { "type": "string", "nullable": true, "description": "The three-digit exchange code of the phone number." }, "Locked": { "type": "boolean", "nullable": true, "description": "Whether the phone number is locked for purchase." }, "LockedUntil": { "type": "integer", "nullable": true, "description": "The Unix timestamp when the phone number lock expires." }, "Capabilities": { "type": "object", "nullable": true, "properties": { "Voice": { "type": "boolean" }, "RestrictedVoice": { "type": "boolean" }, "Sms": { "type": "boolean" }, "RestrictedSms": { "type": "boolean" }, "Mms": { "type": "boolean" }, "RestrictedMms": { "type": "boolean" }, "Fax": { "type": "boolean" }, "RestrictedFax": { "type": "boolean" }, "Sip": { "type": "boolean" } }, "description": "The set of Boolean properties that describes the SMS, MMS, Voice, and Fax capabilities of the phone number." }, "Geography": { "type": "object", "nullable": true, "properties": { "IsoCountry": { "type": "string", "format": "iso-country-code" }, "Region": { "type": "string" }, "Locality": { "type": "string" }, "PostalCode": { "type": "string" }, "Latitude": { "type": "number" }, "Longitude": { "type": "number" }, "Lata": { "type": "string" }, "RateCenter": { "type": "string" } }, "description": "The geographic information associated with the phone number." }, "AddressRequirements": { "type": "string", "nullable": true, "description": "The type of Address resource the phone number requires." }, "Certifications": { "type": "object", "nullable": true, "properties": { "Resident": { "type": "boolean" }, "Non-Resident": { "type": "boolean" } }, "description": "The certifications required for the phone number." }, "Billing": { "type": "object", "nullable": true, "properties": { "RecurringBillableItemSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^BI[0-9a-fA-F]{32}$" }, "SetupBillableItemSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^BI[0-9a-fA-F]{32}$" } }, "description": "The billing information for the phone number." }, "DateCreated": { "type": "string", "format": "date-time", "nullable": true, "description": "The date and time in GMT when the resource was created specified in ISO 8601 format." }, "DateUpdated": { "type": "string", "format": "date-time", "nullable": true, "description": "The date and time in GMT when the resource was last updated specified in ISO 8601 format." }, "Beta": { "type": "boolean", "nullable": true, "description": "Whether the phone number is in beta." }, "VoiceEmergencyCapable": { "type": "boolean", "nullable": true, "description": "Whether the phone number can handle emergency calls." }, "Flags": { "type": "object", "nullable": true, "properties": { "National": { "type": "boolean" }, "International": { "type": "boolean" } }, "description": "The flags that describe the phone number features." } } }, "numbers.v1.a2p_registration_details": { "type": "object", "required": [ "accountSid", "phoneNumberSid", "phoneNumber", "externalPhoneNumberStatus" ], "properties": { "accountSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$", "nullable": false, "description": "Account Sid that the phone number belongs to in Twilio. This is only returned for phone numbers that already exist in Twilio\u2019s inventory and belong to your account or sub account." }, "phoneNumberSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^PN[0-9a-fA-F]{32}$", "nullable": false, "description": "Phone Number SID for the requested phone number resource" }, "phoneNumber": { "type": "string", "nullable": false }, "externalPhoneNumberStatus": { "type": "string", "nullable": false }, "campaignSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^CM[0-9a-fA-F]{32}$", "nullable": true, "description": "Campaign Sid associated with the phone number" }, "messagingServiceSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^MG[0-9a-fA-F]{32}$", "nullable": true, "description": "Messaging Service Sid that the number is associated with" }, "externalCampaignId": { "type": "string", "nullable": true, "description": "The identifier for a campaign in the registrar. Typically, this is the TCR Campaign Id." }, "lastUpdated": { "type": "string", "format": "date-time", "nullable": true, "description": "The date and time when the A2P registration details were last updated" } } }, "numbers.v1.a2p_brand_campaign_compliance_registration_sids": { "type": "object", "properties": { "campaignComplianceRegistrationSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^BU[0-9a-fA-F]{32}$", "nullable": true, "description": "Sid associated with campaign compliance registration" }, "brandComplianceRegistrationSid": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^BU[0-9a-fA-F]{32}$", "nullable": true, "description": "Sid associated with brand compliance registration" } } }, "numbers.v1.a2p_registration_details_list": { "type": "object", "required": [ "data" ], "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/numbers.v1.a2p_registration_details" } } } }, "numbers.v1.a2p_registration_details_fetch": { "type": "object", "allOf": [ { "$ref": "#/components/schemas/numbers.v1.a2p_registration_details" }, { "$ref": "#/components/schemas/numbers.v1.a2p_brand_campaign_compliance_registration_sids" } ], "description": "Single A2P registration details response including brand and campaign compliance registration SIDs" }, "numbers.v1.a2p_registration_details_campaign_list": { "type": "object", "required": [ "data" ], "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/numbers.v1.a2p_registration_details" }, "description": "List of A2P registration details for numbers in the campaign" }, "nextToken": { "type": "string", "nullable": true, "description": "Token for pagination to retrieve the next page of results" } } } } }, "info": { "title": "Twilio - Numbers", "description": "This is the public Twilio REST API.", "termsOfService": "https://www.twilio.com/legal/tos", "contact": { "name": "Twilio Support", "url": "https://support.twilio.com", "email": "support@twilio.com" }, "license": { "name": "Apache 2.0", "url": "https://www.apache.org/licenses/LICENSE-2.0.html" }, "version": "1.0.0", "x-twilio": { "apiStandards": "v0.1" } }, "openapi": "3.0.1", "paths": { "/v1/HostedNumber/Eligibility/Bulk": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [], "mountName": "bulk_eligibilities", "pathType": "list" }, "post": { "description": "Create a bulk eligibility check for a set of numbers that you want to host in Twilio.", "summary": "Create a bulk eligibility check for a set of numbers that you want to host in Twilio.", "tags": [ "NumbersV1BulkEligibility" ], "responses": { "202": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.bulk_eligibility" }, "examples": { "create": { "value": { "friendly_name": "Test", "status": "QUEUED", "date_created": "2023-05-03T03:12:30Z", "date_completed": null, "request_id": "ECaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "results": [], "url": "https://numbers.twilio.com/v1/HostedNumber/Eligibility/Bulk/ECaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "Accepted" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "CreateBulkEligibility", "requestBody": { "content": { "application/json": { "schema": { "type": "object", "title": "CreateBulkEligibilityRequest", "properties": {} } } } } } }, "/v1/HostedNumber/Eligibility/Bulk/{RequestId}": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [], "mountName": "bulk_eligibilities", "pathType": "instance" }, "get": { "description": "Fetch an eligibility bulk check that you requested to host in Twilio.", "summary": "Fetch an eligibility bulk check that you requested to host in Twilio.", "tags": [ "NumbersV1BulkEligibility" ], "parameters": [ { "name": "RequestId", "in": "path", "description": "The SID of the bulk eligibility check that you want to know about.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^EC[0-9a-fA-F]{32}$" }, "required": true } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.bulk_eligibility" }, "examples": { "fetch": { "value": { "friendly_name": "Foo", "status": "SUCCESSFUL", "date_created": "2023-04-24T14:47:04Z", "date_completed": "2023-04-24T14:47:06Z", "results": [ { "phone_number": "+18778894546", "account_sid": "AC93b447ff5bd2abac37f1cbab2a871430", "eligibility_status": "INELIGIBLE", "eligibility_sub_status": "ALREADY_IN_TWILIO", "ineligibility_reason": "ALREADY_IN_TWILIO_BUT_NOT_IN_USE", "next_step": "CONTACT_SUPPORT_INELIGIBLE_INVENTORY_STATUS", "voice_provider": null, "messaging_provider": null, "phone_number_type": "TOLL_FREE", "hosting_order_sid": null, "hosting_order_status": null, "iso_country_code": "US", "inventory_status": "in-testing", "inventory_account_sid": "AC93b447ff5bd2abac37f1cbab2a871430" } ], "url": "https://numbers.twilio.com/v1/HostedNumber/Eligibility/Bulk/ECaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "request_id": "ECaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "FetchBulkEligibility" } }, "/v1/HostedNumber/Eligibility": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [], "mountName": "eligibilities", "pathType": "list" }, "post": { "description": "Create an eligibility check for a number that you want to host in Twilio.", "summary": "Create an eligibility check for a number that you want to host in Twilio.", "tags": [ "NumbersV1Eligibility" ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.eligibility" }, "examples": { "create": { "value": { "results": [ { "phone_number": "+18778894546", "account_sid": "AC93b447ff5bd2abac37f1cbab2a871430", "eligibility_status": "INELIGIBLE", "eligibility_sub_status": "ALREADY_IN_TWILIO", "ineligibility_reason": "ALREADY_IN_TWILIO_BUT_NOT_IN_USE", "next_step": "CONTACT_SUPPORT_INELIGIBLE_INVENTORY_STATUS", "voice_provider": null, "messaging_provider": null, "phone_number_type": "TOLL_FREE", "hosting_order_sid": null, "hosting_order_status": null, "iso_country_code": "US", "inventory_status": "in-testing", "inventory_account_sid": "AC93b447ff5aa2abac37e3cbab2a871430" }, { "phone_number": "4565433456", "account_sid": null, "eligibility_status": "INELIGIBLE", "eligibility_sub_status": "NUMBER_FORMAT_INELIGIBLE", "ineligibility_reason": "NUMBER_FORMAT_INELIGIBLE", "next_step": "EDIT_INELIGIBLE_NUMBER", "voice_provider": null, "messaging_provider": null, "phone_number_type": null, "hosting_order_sid": null, "hosting_order_status": null, "iso_country_code": null, "inventory_status": null, "inventory_account_sid": null } ] } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "CreateEligibility", "requestBody": { "content": { "application/json": { "schema": { "type": "object", "title": "CreateEligibilityRequest", "properties": {} } } } } } }, "/v1/Porting/PortIn": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [ "port_in_request_sid" ], "mountName": "porting_port_ins", "pathType": "list" }, "post": { "description": "Allows to create a new port in request", "summary": "Allows to create a new port in request", "tags": [ "NumbersV1PortingPortIn" ], "responses": { "202": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.porting_port_in" }, "examples": { "create": { "value": { "port_in_request_sid": "KWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "notification_emails": [ "user@domain.com" ], "target_port_in_date": "2023-09-10", "target_port_in_time_range_start": "10:00:00+01:00", "target_port_in_time_range_end": "20:00:00+01:00", "support_ticket_id": 123456, "port_in_request_status": "pending", "order_cancellation_reason": null, "date_created": "2023-09-10T06:52:21Z", "losing_carrier_information": { "customer_type": "Business", "customer_name": "Customer name for carrier", "authorized_representative": "John Smith", "authorized_representative_email": "signer@domain.com", "account_number": "123456", "account_telephone_number": "+133232323", "address_sid": "ADaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "address": { "street": "Your Street", "street_2": "Other Street or null", "city": "City", "state": "State", "zip": "000000", "country": "US" } }, "phone_numbers": [ { "phone_number": "+16175551212", "portable": true, "not_portability_reason": "string", "port_in_phone_number_sid": "PUaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "port_in_phone_number_status": "In Review", "not_portability_reason_code": 0, "external_porting_vendor_phone_number_id": null } ], "bundle_sid": null, "portability_advance_carrier": null, "auto_cancel_approval_numbers": null, "documents": [ "RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" ], "signature_request_url": null, "url": "https://numbers.twilio.com/v1/Porting/PortIn/KWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "Accepted" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "CreatePortingPortIn", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.porting_port_in_create" } } }, "required": true } } }, "/v1/Porting/PortIn/{PortInRequestSid}": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [ "port_in_request_sid" ], "mountName": "porting_port_ins", "pathType": "instance" }, "delete": { "description": "Allows to cancel a port in request by SID", "summary": "Allows to cancel a port in request by SID", "tags": [ "NumbersV1PortingPortIn" ], "parameters": [ { "name": "PortInRequestSid", "in": "path", "description": "The SID of the Port In request. This is a unique identifier of the port in request.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^KW[0-9a-fA-F]{32}$" }, "required": true } ], "responses": { "204": { "description": "The resource was deleted successfully." } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "DeletePortingPortIn" }, "get": { "description": "Fetch a port in request by SID", "summary": "Fetch a port in request by SID", "tags": [ "NumbersV1PortingPortIn" ], "parameters": [ { "name": "PortInRequestSid", "in": "path", "description": "The SID of the Port In request. This is a unique identifier of the port in request.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^KW[0-9a-fA-F]{32}$" }, "required": true } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.porting_port_in" }, "examples": { "fetch": { "value": { "port_in_request_sid": "KWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "url": "https://numbers.twilio.com/v1/Porting/PortIn/KWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "bundle_sid": null, "portability_advance_carrier": null, "auto_cancel_approval_numbers": null, "notification_emails": [ "user@domain.com" ], "target_port_in_date": "2023-09-10", "target_port_in_time_range_start": "10:00:00+01:00", "target_port_in_time_range_end": "20:00:00+01:00", "port_in_request_status": "pending", "support_ticket_id": 123456, "order_cancellation_reason": null, "date_created": "2023-09-10T06:52:21Z", "losing_carrier_information": { "customer_type": "Business", "customer_name": "Customer name for carrier", "authorized_representative": "John Smith", "authorized_representative_email": "signer@domain.com", "account_number": "123456", "account_telephone_number": "+133232323", "address_sid": "ADaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "authorized_representative_katakana": "\u30b8\u30e7\u30f3 \u30b9\u30df\u30b9", "building": null, "katakana_name": null, "sub_municipality": null, "address": { "street": "Your Street", "street_2": "Other Street or null", "city": "City", "state": "State", "zip": "000000", "country": "US" } }, "phone_numbers": [ { "phone_number": "+16175551212", "number_type": "LOCAL", "rejection_reason": null, "rejection_reason_code": null, "status_last_time_updated_timestamp": "2025-01-01T00:52:21Z", "portable": true, "not_portability_reason": "string", "not_portability_reason_code": 0, "port_in_phone_number_sid": "PUaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "port_in_phone_number_status": "In Review", "port_date": "2023-09-17T00:00:00Z", "external_porting_vendor_phone_number_id": null } ], "documents": [ "RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" ], "signature_request_url": null } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "FetchPortingPortIn" } }, "/v1/Porting/PortIn/PortInRequests": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [], "mountName": "porting_all_port_ins", "pathType": "list" }, "get": { "description": "Retrieve a list of all PortInRequests for a user", "summary": "Fetch all PortInRequests for a user", "tags": [ "NumbersV1PortingPortIn" ], "parameters": [ { "name": "Token", "in": "query", "required": false, "description": "Page start token, if null then it will start from the beginning", "schema": { "type": "string" }, "examples": { "readEmpty": { "value": "KWbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb" } } }, { "name": "Size", "in": "query", "description": "Number of items per page", "required": false, "schema": { "type": "integer", "format": "int32", "default": 20, "minimum": 1, "maximum": 100 }, "examples": { "readEmpty": { "value": 20 } } }, { "name": "PortInRequestSid", "in": "query", "description": "Filter by Port in request SID, supports multiple values separated by comma", "required": false, "schema": { "type": "string" }, "examples": { "readEmpty": { "value": "KW123abc12345678901234567890abcd" } } }, { "name": "PortInRequestStatus", "in": "query", "description": "Filter by Port In request status", "required": false, "schema": { "type": "string" }, "examples": { "readEmpty": { "value": "Completed" } } }, { "name": "CreatedBefore", "in": "query", "description": "Find all created before a certain date", "required": false, "schema": { "type": "string" }, "examples": { "readEmpty": { "value": "2025-05-05" } } }, { "name": "CreatedAfter", "in": "query", "description": "Find all created after a certain date", "required": false, "schema": { "type": "string" }, "examples": { "readEmpty": { "value": "2025-01-05" } } } ], "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "port_in_requests": { "type": "array", "items": { "$ref": "#/components/schemas/numbers.v1.port_in_request_list" } }, "meta": { "$ref": "#/components/schemas/numbers.v1.port_in_request_list_meta" } }, "title": "ListPortInRequestsResponse" }, "examples": { "readFull": { "value": { "port_in_requests": [ { "port_in_request_sid": "KWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "port_in_request_status": "Completed", "status_last_updated_timestamp": "2025-04-30", "phone_numbers_requested": 1, "phone_numbers_ported": 0, "suggested_action": null } ], "meta": { "next_token": "KWbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb", "previous_token": null } } }, "readEmpty": { "value": { "port_in_requests": [], "meta": { "next_token": null, "previous_token": null } } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "ListPortInRequests" } }, "/v1/Porting/PortIn/{PortInRequestSid}/PhoneNumber/{PhoneNumberSid}": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [ "port_in_request_sid", "phone_number_sid" ], "mountName": "porting_port_in_phone_number", "pathType": "instance" }, "delete": { "description": "Allows to cancel a port in request phone number by SID", "summary": "Allows to cancel a port in request phone number by SID", "tags": [ "NumbersV1PortingPortInPhoneNumber" ], "parameters": [ { "name": "PortInRequestSid", "in": "path", "description": "The SID of the Port In request. This is a unique identifier of the port in request.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^KW[0-9a-fA-F]{32}$" }, "required": true }, { "name": "PhoneNumberSid", "in": "path", "description": "The SID of the Port In request phone number. This is a unique identifier of the phone number.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^PU[0-9a-fA-F]{32}$" }, "required": true } ], "responses": { "204": { "description": "The resource was deleted successfully." } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "DeletePortingPortInPhoneNumber" }, "get": { "description": "Fetch a phone number by port in request SID and phone number SID", "summary": "Fetch a phone number by port in request SID and phone number SID", "tags": [ "NumbersV1PortingPortInPhoneNumber" ], "parameters": [ { "name": "PortInRequestSid", "in": "path", "description": "The SID of the Port In request. This is a unique identifier of the port in request.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^KW[0-9a-fA-F]{32}$" }, "required": true }, { "name": "PhoneNumberSid", "in": "path", "description": "The SID of the Phone number. This is a unique identifier of the phone number.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^PU[0-9a-fA-F]{32}$" }, "required": true } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.porting_port_in_phone_number" }, "examples": { "fetch": { "value": { "port_in_request_sid": "KWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "phone_number_type": "LOCAL", "date_created": "2024-04-10T06:52:21Z", "country": "US", "missing_required_fields": false, "last_updated": "2024-03-12T06:52:21Z", "phone_number": "+15024953384", "portable": true, "not_portability_reason": "ALREADY_IN_TWILIO_DIFFERENT_OWNER", "not_portability_reason_code": 22132, "port_in_phone_number_status": "in_review", "phone_number_sid": "PUaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "port_out_pin": 1234, "rejection_reason": null, "rejection_reason_code": null, "port_date": "2024-05-17T00:00:00Z", "url": "https://numbers.twilio.com/v1/Porting/PortIn/KWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumber/PUaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "FetchPortingPortInPhoneNumber" } }, "/v1/Porting/Portability/PhoneNumber/{PhoneNumber}": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [], "mountName": "porting_portabilities", "pathType": "instance" }, "get": { "description": "Check if a single phone number can be ported to Twilio", "summary": "Check if a single phone number can be ported to Twilio", "tags": [ "NumbersV1PortingPortability" ], "parameters": [ { "name": "PhoneNumber", "in": "path", "description": "Phone number to check portability in e164 format.", "schema": { "type": "string", "format": "phone-number" }, "x-twilio": { "pii": { "handling": "standard", "deleteSla": 0 } }, "required": true }, { "name": "TargetAccountSid", "in": "query", "description": "Account Sid to which the number will be ported. This can be used to determine if a sub account already has the number in its inventory or a different sub account. If this is not provided, the authenticated account will be assumed to be the target account.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AC[0-9a-fA-F]{32}$" }, "examples": { "fetch": { "value": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa02" } } }, { "name": "AddressSid", "in": "query", "description": "Address Sid of customer to which the number will be ported.", "schema": { "type": "string", "minLength": 34, "maxLength": 34, "pattern": "^AD[0-9a-fA-F]{32}$" }, "examples": { "fetch": { "value": "ADaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa02" } } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.porting_portability" }, "examples": { "fetch": { "value": { "phone_number": "+18001234567", "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa01", "portable": false, "pin_and_account_number_required": false, "not_portable_reason": "MANUAL_PORTING_AVAILABLE", "not_portable_reason_code": 22133, "number_type": "TOLL-FREE", "country": "US", "url": "https://numbers.twilio.com/v1/Porting/Portability/PhoneNumber/+18001234567" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "FetchPortingPortability" } }, "/v1/Porting/Configuration/Webhook": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [], "pathType": "list" }, "post": { "description": "Create a Webhook Configuration", "summary": "Create a Webhook Configuration", "tags": [ "NumbersV1PortingWebhookConfiguration" ], "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.porting_webhook_configuration" }, "examples": { "create": { "value": { "port_in_target_url": "https://www.example.com/port-in", "port_out_target_url": "https://www.example.com/port-out", "notifications_of": [ "PortInWaitingForSignature", "PortInInProgress", "PortInCompleted", "PortInActionRequired", "PortInCanceled", "PortInExpired", "PortInPhoneNumberWaitingForSignature", "PortInPhoneNumberSubmitted", "PortInPhoneNumberPending", "PortInPhoneNumberCompleted", "PortInPhoneNumberRejected", "PortOutPhoneNumberCompleted" ], "url": "https://numbers.twilio.com/v1/Porting/Configuration/Webhook" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "Created" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "CreatePortingWebhookConfiguration", "requestBody": { "content": { "application/json": { "schema": { "type": "object", "title": "CreatePortingWebhookConfigurationRequest", "properties": {} } } } }, "x-twilio": { "mountName": "porting_webhook_configurations" } }, "get": { "description": "Allows to fetch the webhook configuration", "summary": "Allows to fetch the webhook configuration", "tags": [ "NumbersV1PortingWebhookConfigurationFetch" ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.porting_webhook_configuration_fetch" }, "examples": { "fetch": { "value": { "port_in_target_url": "https://www.example.com/port-in", "port_out_target_url": "https://www.example.com/port-out", "notifications_of": [ "PortInWaitingForSignature", "PortInInProgress", "PortInCompleted", "PortInActionRequired", "PortInCanceled", "PortInExpired", "PortInPhoneNumberWaitingForSignature", "PortInPhoneNumberSubmitted", "PortInPhoneNumberPending", "PortInPhoneNumberCompleted", "PortInPhoneNumberRejected", "PortOutPhoneNumberCompleted" ], "port_in_target_date_created": "2024-05-14T13:49:04Z", "port_out_target_date_created": "2024-05-14T13:49:07Z", "url": "https://numbers.twilio.com/v1/Porting/Configuration/Webhook" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "FetchPortingWebhookConfigurationFetch" } }, "/v1/Porting/Configuration/Webhook/{WebhookType}": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [], "mountName": "porting_webhook_configurations_delete", "className": "porting_webhook_configuration_delete", "pathType": "instance" }, "delete": { "description": "Allows the client to delete a webhook configuration.", "summary": "Allows the client to delete a webhook configuration.", "tags": [ "NumbersV1PortingWebhookConfigurationDelete" ], "parameters": [ { "name": "WebhookType", "in": "path", "description": "The webhook type for the configuration to be delete. `PORT_IN`, `PORT_OUT`", "schema": { "$ref": "#/components/schemas/porting_webhook_configuration_delete_enum_webhook_type" }, "required": true } ], "responses": { "204": { "description": "The resource was deleted successfully." } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "DeletePortingWebhookConfigurationDelete" } }, "/v1/SigningRequest/Configuration": { "servers": [ { "url": "https://numbers.twilio.com" } ], "description": "", "x-twilio": { "defaultOutputProperties": [ "product", "email_subject", "email_message" ], "mountName": "signing_request_configurations", "pathType": "list" }, "post": { "description": "Synchronous operation to insert or update a configuration for the customer.", "summary": "Synchronous operation to insert or update a configuration for the customer.", "tags": [ "NumbersV1SigningRequestConfiguration" ], "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/numbers.v1.signing_request_configuration" }, "examples": { "create": { "value": { "logo_sid": "RD00000000000000000000000000000000", "friendly_name": "Configuration", "product": "Porting", "country": "US", "email_subject": "Twilio Porting Request", "email_message": "This is a signature request from Twilio, please check the document and sign it", "url_redirection": "https://www.twilio.com/redirect-url", "url": "https://numbers.twilio.com/v1/SigningRequest/Configuration" } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "Created" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "CreateSigningRequestConfiguration", "requestBody": { "content": { "application/json": { "schema": { "type": "object", "title": "CreateSigningRequestConfigurationRequest", "properties": {} } } } } }, "get": { "description": "Synchronous operation to retrieve configurations for the customer.", "summary": "Synchronous operation to retrieve configurations for the customer.", "tags": [ "NumbersV1SigningRequestConfiguration" ], "parameters": [ { "name": "Country", "in": "query", "description": "The country ISO code to apply this configuration, this is an optional field, Example: US, MX", "schema": { "type": "string" }, "examples": { "readWithQueryParams": { "value": "MX" } } }, { "name": "Product", "in": "query", "description": "The product or service for which is requesting the signature, this is an optional field, Example: Porting, Hosting", "schema": { "type": "string" }, "examples": { "readWithQueryParams": { "value": "Porting" } } }, { "name": "PageSize", "in": "query", "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", "schema": { "type": "integer", "format": "int64", "minimum": 1, "maximum": 1000 } }, { "name": "Page", "in": "query", "description": "The page index. This value is simply for client state.", "schema": { "type": "integer", "minimum": 0 } }, { "name": "PageToken", "in": "query", "description": "The page token. This is provided by the API.", "schema": { "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "configurations": { "type": "array", "items": { "$ref": "#/components/schemas/numbers.v1.signing_request_configuration" } }, "meta": { "properties": { "first_page_url": { "format": "uri", "type": "string" }, "key": { "type": "string" }, "next_page_url": { "format": "uri", "nullable": true, "type": "string" }, "page": { "type": "integer" }, "page_size": { "type": "integer" }, "previous_page_url": { "format": "uri", "nullable": true, "type": "string" }, "url": { "format": "uri", "type": "string" } }, "type": "object" } }, "title": "ListSigningRequestConfigurationResponse" }, "examples": { "readWithoutQueryParams": { "value": { "configurations": [ { "logo_sid": "RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "friendly_name": "Hosting CL", "product": "Hosting", "country": "CL", "email_subject": "Email Subject", "email_message": "Email Message", "url_redirection": "https://www.twilio.com/redirect-url", "url": "https://numbers.twilio.com/v1/SigningRequest/Configuration" } ], "meta": { "page": 0, "page_size": 50, "first_page_url": "https://numbers.twilio.com/v1/SigningRequest/Configuration?PageSize=50&Page=0", "previous_page_url": null, "url": "https://numbers.twilio.com/v1/SigningRequest/Configuration?PageSize=50&Page=0", "next_page_url": null, "key": "configurations" } } }, "readWithQueryParams": { "value": { "configurations": [ { "logo_sid": "RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "friendly_name": "friendly name", "product": "Porting", "country": "MX", "email_subject": "Email Subject", "email_message": "Email Message", "url_redirection": "https://my-redirection-url.com/redirect", "url": "https://numbers.twilio.com/v1/SigningRequest/Configuration" } ], "meta": { "page": 0, "page_size": 50, "first_page_url": "https://numbers.twilio.com/v1/SigningRequest/Configuration?Product=Porting&Country=MX&PageSize=50&Page=0", "previous_page_url": null, "url": "https://numbers.twilio.com/v1/SigningRequest/Configuration?Product=Porting&Country=MX&PageSize=50&Page=0&PageToken=PTtestPageToken", "next_page_url": null, "key": "configurations" } } } } } }, "headers": { "Access-Control-Allow-Origin": { "description": "Specify the origin(s) allowed to access the resource", "schema": { "type": "string" }, "example": "*" }, "Access-Control-Allow-Methods": { "description": "Specify the HTTP methods allowed when accessing the resource", "schema": { "type": "string" }, "example": "POST, OPTIONS" }, "Access-Control-Allow-Headers": { "description": "Specify the headers allowed when accessing the resource", "schema": { "type": "string" }, "example": "Content-Type, Authorization" }, "Access-Control-Allow-Credentials": { "description": "Indicates whether the browser should include credentials", "schema": { "type": "boolean" } }, "Access-Control-Expose-Headers": { "description": "Headers exposed to the client", "schema": { "type": "string", "example": "X-Custom-Header1, X-Custom-Header2" } } }, "description": "OK" } }, "security": [ { "accountSid_authToken": [] } ], "operationId": "ListSigningRequestConfiguration" } } }, "servers": [ { "url": "https://numbers.twilio.com" } ], "tags": [ { "name": "NumbersV1AuthorizationDocument" }, { "name": "NumbersV1BulkEligibility" }, { "name": "NumbersV1DependentOrder" }, { "name": "NumbersV1Eligibility" }, { "name": "NumbersV1HostedNumberOrder" }, { "name": "NumbersV1Index" }, { "name": "NumbersV1PortingPortIn" }, { "name": "NumbersV1PortingPortInPhoneNumber" }, { "name": "NumbersV1PortingPortability" }, { "name": "NumbersV1PortingWebhookConfiguration" }, { "name": "NumbersV1PortingWebhookConfigurationDelete" }, { "name": "NumbersV1PortingWebhookConfigurationFetch" }, { "name": "NumbersV1SigningRequestConfiguration" }, { "name": "NumbersV1Version" }, { "name": "NumbersV1AvailablePhoneNumber" }, { "name": "NumbersV1A2pRegistrationDetails" } ], "security": [ { "accountSid_authToken": [] } ] }