> ## Documentation Index
> Fetch the complete documentation index at: https://developers.telnyx.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Request phone number verification

> Initiates phone number verification procedure. Supports DTMF extension dialing for voice calls to numbers behind IVR systems.



## OpenAPI

````yaml https://telnyx-openapi-ng.s3.us-east-1.amazonaws.com/real-time-communications/verified-numbers.yml post /verified_numbers
openapi: 3.1.0
info:
  title: Telnyx Verified Numbers API
  version: 2.0.0
  description: API for Verified numbers.
  contact:
    email: support@telnyx.com
servers:
  - url: https://api.telnyx.com/v2
security:
  - bearerAuth: []
paths:
  /verified_numbers:
    post:
      tags:
        - Verified Numbers
      summary: Request phone number verification
      description: >-
        Initiates phone number verification procedure. Supports DTMF extension
        dialing for voice calls to numbers behind IVR systems.
      operationId: CreateVerifiedNumber
      requestBody:
        content:
          application/json:
            schema:
              title: Create Verified Number Request
              type: object
              required:
                - phone_number
                - verification_method
              properties:
                phone_number:
                  example: '+15551234567'
                  type: string
                verification_method:
                  description: Verification method.
                  type: string
                  enum:
                    - sms
                    - call
                  example: sms
                extension:
                  example: ww243w1
                  type: string
                  description: >-
                    Optional DTMF extension sequence to dial after the call is
                    answered. This parameter enables verification of phone
                    numbers behind IVR systems that require extension dialing.
                    Valid characters: digits 0-9, letters A-D, symbols * and #.
                    Pauses: w = 0.5 second pause, W = 1 second pause. Maximum
                    length: 50 characters. Only works with 'call' verification
                    method.
                  default: null
                  maxLength: 50
                  pattern: ^[0-9A-D*#wW]*$
            examples:
              sms_verification:
                summary: SMS verification
                value:
                  phone_number: '+15551234567'
                  verification_method: sms
              call_verification:
                summary: Call verification
                value:
                  phone_number: '+15551234567'
                  verification_method: call
              call_with_extension:
                summary: Call verification with DTMF extension
                description: >-
                  Example for verifying a number behind an IVR system that
                  requires extension dialing
                value:
                  phone_number: '+15551234567'
                  verification_method: call
                  extension: ww243w1
        required: true
      responses:
        '200':
          description: Expected response to a valid request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateVerifiedNumberResponse'
        '400':
          $ref: '#/components/responses/verified-numbers_GenericErrorResponse'
        '401':
          $ref: '#/components/responses/UnauthorizedRequestErrorResponse'
        '422':
          $ref: >-
            #/components/responses/verified-numbers_UnprocessableEntityErrorResponse
      x-codeSamples:
        - lang: JavaScript
          source: |-
            import Telnyx from 'telnyx';

            const client = new Telnyx({
              apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
            });

            const verifiedNumber = await client.verifiedNumbers.create({
              phone_number: '+15551234567',
              verification_method: 'sms',
            });

            console.log(verifiedNumber.phone_number);
        - lang: Python
          source: |-
            import os
            from telnyx import Telnyx

            client = Telnyx(
                api_key=os.environ.get("TELNYX_API_KEY"),  # This is the default and can be omitted
            )
            verified_number = client.verified_numbers.create(
                phone_number="+15551234567",
                verification_method="sms",
            )
            print(verified_number.phone_number)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/team-telnyx/telnyx-go\"\n\t\"github.com/team-telnyx/telnyx-go/option\"\n)\n\nfunc main() {\n\tclient := telnyx.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\tverifiedNumber, err := client.VerifiedNumbers.New(context.TODO(), telnyx.VerifiedNumberNewParams{\n\t\tPhoneNumber:        \"+15551234567\",\n\t\tVerificationMethod: telnyx.VerifiedNumberNewParamsVerificationMethodSMS,\n\t})\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", verifiedNumber.PhoneNumber)\n}\n"
        - lang: Java
          source: >-
            package com.telnyx.sdk.example;


            import com.telnyx.sdk.client.TelnyxClient;

            import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;

            import
            com.telnyx.sdk.models.verifiednumbers.VerifiedNumberCreateParams;

            import
            com.telnyx.sdk.models.verifiednumbers.VerifiedNumberCreateResponse;


            public final class Main {
                private Main() {}

                public static void main(String[] args) {
                    TelnyxClient client = TelnyxOkHttpClient.fromEnv();

                    VerifiedNumberCreateParams params = VerifiedNumberCreateParams.builder()
                        .phoneNumber("+15551234567")
                        .verificationMethod(VerifiedNumberCreateParams.VerificationMethod.SMS)
                        .build();
                    VerifiedNumberCreateResponse verifiedNumber = client.verifiedNumbers().create(params);
                }
            }
        - lang: Ruby
          source: >-
            require "telnyx"


            telnyx = Telnyx::Client.new(api_key: "My API Key")


            verified_number = telnyx.verified_numbers.create(phone_number:
            "+15551234567", verification_method: :sms)


            puts(verified_number)
        - lang: CLI
          source: |-
            telnyx verified-numbers create \
              --api-key 'My API Key' \
              --phone-number +15551234567 \
              --verification-method sms
components:
  schemas:
    CreateVerifiedNumberResponse:
      title: CreateVerifiedNumberResponse
      type: object
      properties:
        phone_number:
          example: '+15551234567'
          type: string
        verification_method:
          example: sms
          type: string
    verified-numbers_Errors:
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/verified-numbers_Error'
      type: object
    verified-numbers_Error:
      required:
        - code
        - title
      properties:
        code:
          type: string
        title:
          type: string
        detail:
          type: string
        source:
          type: object
          properties:
            pointer:
              description: JSON pointer (RFC6901) to the offending entity.
              type: string
            parameter:
              description: Indicates which query parameter caused the error.
              type: string
        meta:
          type: object
          properties:
            url:
              type: string
              description: URL with additional information on the error.
      type: object
  responses:
    verified-numbers_GenericErrorResponse:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/verified-numbers_Errors'
    UnauthorizedRequestErrorResponse:
      description: Unauthorized Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/verified-numbers_Errors'
    verified-numbers_UnprocessableEntityErrorResponse:
      description: Unprocessable Entity
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/verified-numbers_Errors'
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````