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

# Custom Add Contact

> Adds a new custom contact with SIP trunk credentials and other optional fields.



## OpenAPI

````yaml POST /v2/add/contact/
openapi: 3.1.0
info:
  title: CloserX.ai API
  description: >-
    The CloserX.ai API provides programmatic access to manage AI-powered calling
    operations, including agent creation, campaign management, contact handling,
    telephony integration, and more. This API enables seamless automation and
    integration with CRM systems, telephony providers, and other third-party
    services for enhanced client communication and business operations.
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://app.closerx.ai/api
security:
  - api_key: []
paths:
  /v2/add/contact/:
    post:
      summary: Custom Add Contact
      description: >-
        Adds a new custom contact with SIP trunk credentials and other optional
        fields.
      parameters:
        - name: Company-Name
          in: header
          required: true
          description: Schema name for multi-tenancy
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CustomAddContactRequest'
            example:
              phone_number: string
              termination_uri: string
              sip_trunk_auth_username: string
              sip_trunk_auth_password: string
              nickname: string
              source_of_origin: string
      responses:
        '200':
          description: Contact created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CustomAddContactResponse'
              example:
                success: true
                message: contact created
                data:
                  pk: integer
                  phone_number: string
                  termination_uri: string
                  sip_trunk_auth_username: string
                  sip_trunk_auth_password: string
                  nickname: string
                  source_of_origin: string
                  phone_number_sid: string | null
                  verification_status: string | null
                  in_used_by_agent: string
                  is_auto_buyed: boolean
        '400':
          description: Invalid contact data or schema missing
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    CustomAddContactRequest:
      type: object
      required:
        - phone_number
        - termination_uri
        - sip_trunk_auth_username
        - sip_trunk_auth_password
        - nickname
        - source_of_origin
      properties:
        phone_number:
          type: string
          description: The phone number to register
          example: '+917418520030'
        termination_uri:
          type: string
          description: The SIP termination URI (used for routing)
          example: popuptesting
        sip_trunk_auth_username:
          type: string
          description: SIP trunk authentication username
          example: kadpro@gmail.com
        sip_trunk_auth_password:
          type: string
          description: SIP trunk authentication password
          example: 2345$
        nickname:
          type: string
          description: A friendly name or nickname for the number
          example: testingg
        source_of_origin:
          type: string
          description: The source from which the contact originates
          example: custom
    CustomAddContactResponse:
      type: object
      properties:
        success:
          type: boolean
          example: true
        message:
          type: string
          example: contact created
        data:
          type: object
          properties:
            pk:
              type: integer
              example: 68
            phone_number:
              type: string
              example: '+917418963066'
            termination_uri:
              type: string
              example: popuptesting
            sip_trunk_auth_username:
              type: string
              example: kadpro@gmail.com
            sip_trunk_auth_password:
              type: string
              example: 345$
            nickname:
              type: string
              example: testingg
            source_of_origin:
              type: string
              example: custom
            phone_number_sid:
              type:
                - string
                - 'null'
              example: null
            verification_status:
              type:
                - string
                - 'null'
              example: null
            in_used_by_agent:
              type: string
              example: none
            is_auto_buyed:
              type: boolean
              example: false
    Error:
      required:
        - success
        - message
        - data
      type: object
      properties:
        success:
          type: boolean
        message:
          type: string
        data:
          type: object
  securitySchemes:
    api_key:
      type: apiKey
      in: header
      name: api_key

````