> ## 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.

# Edit Contact

> Updates complete details of a specific contact by its unique ID.



## OpenAPI

````yaml PATCH /v2/contact-detail/{id}/
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/contact-detail/{id}/:
    patch:
      summary: Update a contact
      description: Updates complete details of a specific contact by its unique ID.
      parameters:
        - name: id
          in: path
          required: true
          description: Unique ID of the contact (e.g., 4465)
          schema:
            type: integer
        - name: Company-Name
          in: header
          required: true
          description: The schema name for multi-tenancy (company-wise DB separation)
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EditContactRequest'
      responses:
        '200':
          description: Successfully updated contact details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EditContact'
        '400':
          description: Invalid request or missing headers
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    EditContactRequest:
      type: object
      properties:
        first_name:
          type: string
          description: First name of the contact
          example: test123Edit
        last_name:
          type: string
          description: Last name of the contact
          example: testEdit
        contact_number:
          type: string
          description: Phone number of the contact (without country code)
          example: '8570904784'
        country_code:
          type: string
          description: Country code for the contact number (in international format)
          example: '+91'
        email:
          type: string
          description: Email address of the contact
          example: info@agencys.ai
        company_name:
          type: string
          description: Name of the company the contact is associated with
          example: test
        industry:
          type: string
          description: Industry type for the contact
          example: SaaS
        tags:
          type: array
          description: List of tag names associated with the contact
          items:
            type: string
          example:
            - salesforce
            - real estate
            - Test campaign
      required:
        - first_name
        - last_name
        - contact_number
        - country_code
        - email
        - tags
    EditContact:
      type: object
      properties:
        success:
          type: boolean
          description: Indicates whether the contact edit operation was successful
          example: true
        message:
          type: string
          description: A message describing the outcome of the request
          example: Success
        data:
          type: object
          description: The updated contact object
          properties:
            id:
              type: integer
              description: Unique ID of the contact
              example: 4465
            contact_number:
              type: string
              description: Phone number of the contact
              example: '+918570904784'
            email:
              type: string
              description: Email address of the contact
              example: info@agencys.ai
            first_name:
              type: string
              description: First name of the contact
              example: test123edit
            last_name:
              type: string
              description: Last name of the contact
              example: testedit
            company_name:
              type: string
              description: Company associated with the contact
              example: test
            industry:
              type:
                - string
                - 'null'
              description: Industry the contact belongs to
              example: null
            custom1:
              type:
                - string
                - 'null'
              description: Custom field 1
              example: null
            custom2:
              type:
                - string
                - 'null'
              description: Custom field 2
              example: null
            custom3:
              type:
                - string
                - 'null'
              description: Custom field 3
              example: null
            custom4:
              type:
                - string
                - 'null'
              description: Custom field 4
              example: null
            isactive:
              type: boolean
              description: Indicates if the contact is active
              example: true
            address:
              type:
                - string
                - 'null'
              description: Address of the contact
              example: null
            contact_id:
              type:
                - string
                - 'null'
              description: External contact ID or integration ID
              example: 003au000008n5oiAAA
            tags:
              type: array
              description: List of tags associated with the contact
              items:
                type: object
                properties:
                  id:
                    type: integer
                    description: Unique ID of the tag
                    example: 56
                  tag_name:
                    type: string
                    description: Name of the tag
                    example: salesforce
                required:
                  - id
                  - tag_name
          required:
            - id
            - contact_number
            - email
            - first_name
            - last_name
            - company_name
            - isactive
            - contact_id
            - tags
      required:
        - success
        - message
        - data
    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

````