Zoho Inventory contact-persons API

Contact-Persons Module

OpenAPI Specification

zoho-inventory-contact-persons-api-openapi.yml Raw ↑
openapi: 3.0.0
info:
  title: batches contact-persons API
  description: Batches help you track inventory items by batch numbers, manufacturing dates, and expiration dates.
  contact: {}
  version: 1.0.0
servers:
- url: https://www.zohoapis.com/inventory/v1
  description: API Endpoint
tags:
- name: contact-persons
  description: Contact-Persons Module
paths:
  /contacts/contactpersons:
    x-mcp-group:
    - Contact Persons
    parameters:
    - $ref: '#/components/parameters/organization_id'
    post:
      tags:
      - contact-persons
      operationId: create_contact_person
      summary: Create a contact person
      description: Create a contact person for contact.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/create-a-contact-person-request'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/create-a-contact-person-response'
      deprecated: false
      security:
      - Zoho_Auth:
        - ZohoInventory.contacts.CREATE
  /contacts/contactpersons/{contact_person_id}:
    x-mcp-group:
    - Contact Persons
    parameters:
    - name: contact_person_id
      in: path
      required: true
      description: Unique identifier of the contact person.
      schema:
        type: string
      example: 460000000026051
    - $ref: '#/components/parameters/organization_id'
    put:
      tags:
      - contact-persons
      operationId: update_contact_person
      summary: Update a contact person
      description: Update details of an existing contact person.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/update-a-contact-person-request'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/update-a-contact-person-response'
      deprecated: false
      security:
      - Zoho_Auth:
        - ZohoInventory.contacts.UPDATE
    delete:
      tags:
      - contact-persons
      operationId: delete_contact_person
      summary: Delete a contact person
      description: Delete an existing contact person.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/delete-a-contact-person-response'
      deprecated: false
      security:
      - Zoho_Auth:
        - ZohoInventory.contacts.DELETE
  /contacts/{contact_id}/contactpersons:
    x-mcp-group:
    - Contact Persons
    parameters:
    - name: contact_id
      in: path
      required: true
      description: Unique identifier of the contact.
      schema:
        type: string
      example: 460000000026049
    - $ref: '#/components/parameters/organization_id'
    get:
      tags:
      - contact-persons
      operationId: list_contact_persons
      summary: List contact persons
      description: List all contacts with pagination.
      parameters:
      - name: page
        in: query
        description: Page number to be fetched. Default value is 1.
        required: false
        schema:
          type: integer
          default: 1
        example: 1
      - name: per_page
        in: query
        description: Number of records to be fetched per page. Default value is 200.
        required: false
        schema:
          type: integer
          default: 200
        example: 200
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/list-contact-persons-response'
      deprecated: false
      security:
      - Zoho_Auth:
        - ZohoInventory.contacts.READ
  /contacts/{contact_id}/contactpersons/{contact_person_id}:
    x-mcp-group:
    - Contact Persons
    parameters:
    - name: contact_id
      in: path
      required: true
      description: Unique identifier of the contact.
      schema:
        type: string
      example: 460000000026049
    - $ref: '#/components/parameters/organization_id'
    get:
      tags:
      - contact-persons
      operationId: get_contact_person
      summary: Get a contact person
      description: Get the details of a contact person.
      parameters:
      - name: contact_person_id
        in: path
        required: true
        description: Unique identifier of the contact person.
        schema:
          type: string
        example: 460000000026051
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/get-a-contact-person-response'
      deprecated: false
      security:
      - Zoho_Auth:
        - ZohoInventory.contacts.READ
  /contacts/contactpersons/{contact_person_id}/primary:
    x-mcp-group:
    - Contact Persons
    parameters:
    - name: contact_person_id
      in: path
      required: true
      description: Unique identifier of the contact person.
      schema:
        type: string
      example: 460000000026051
    - $ref: '#/components/parameters/organization_id'
    post:
      tags:
      - contact-persons
      operationId: mark_contact_person_as_primary
      summary: Mark as primary contact person
      description: Mark a contact person as primary for contact.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/mark-as-primary-contact-person-response'
      deprecated: false
      security:
      - Zoho_Auth:
        - ZohoInventory.contacts.CREATE
components:
  schemas:
    delete-a-contact-person-response:
      type: object
      properties:
        code:
          type: integer
          example: 0
          readOnly: true
        message:
          type: string
          example: The contact person has been deleted.
          readOnly: true
    first_name:
      description: First Name of the contact. Maximum length allowed [100]
      type: string
      example: Will
    update-a-contact-person-response:
      type: object
      properties:
        code:
          type: integer
          example: 0
          readOnly: true
        message:
          type: string
          example: The contactperson details has been updated.
          readOnly: true
        contact_person:
          type: array
          items:
            type: object
            properties:
              contact_id:
                $ref: '#/components/schemas/contact_id'
              contact_person_id:
                $ref: '#/components/schemas/contact_person_id'
              salutation:
                $ref: '#/components/schemas/salutation'
              first_name:
                $ref: '#/components/schemas/first_name'
              last_name:
                $ref: '#/components/schemas/last_name'
              email:
                $ref: '#/components/schemas/email'
              phone:
                $ref: '#/components/schemas/phone'
              mobile:
                $ref: '#/components/schemas/mobile'
              is_primary_contact:
                $ref: '#/components/schemas/is_primary_contact'
              skype:
                $ref: '#/components/schemas/skype'
              designation:
                $ref: '#/components/schemas/designation'
              department:
                $ref: '#/components/schemas/department'
              is_added_in_portal:
                $ref: '#/components/schemas/is_added_in_portal'
              communication_preference:
                $ref: '#/components/schemas/communication_preference'
    phone:
      description: Phone number of the contact person. Maximum length [50]
      type: string
      example: +1-925-921-9201
    list-contact-persons-response:
      type: object
      properties:
        code:
          type: integer
          example: 0
          readOnly: true
        message:
          type: string
          example: success
          readOnly: true
        contact_persons:
          type: array
          items:
            type: object
            properties:
              contact_id:
                $ref: '#/components/schemas/contact_id'
              contact_person_id:
                $ref: '#/components/schemas/contact_person_id'
              salutation:
                $ref: '#/components/schemas/salutation'
              first_name:
                $ref: '#/components/schemas/first_name'
              last_name:
                $ref: '#/components/schemas/last_name'
              email:
                $ref: '#/components/schemas/email'
              phone:
                $ref: '#/components/schemas/phone'
              mobile:
                $ref: '#/components/schemas/mobile'
              is_primary_contact:
                $ref: '#/components/schemas/is_primary_contact'
              communication_preference:
                $ref: '#/components/schemas/communication_preference'
              skype:
                $ref: '#/components/schemas/skype'
              designation:
                $ref: '#/components/schemas/designation'
              department:
                $ref: '#/components/schemas/department'
              is_added_in_portal:
                $ref: '#/components/schemas/is_added_in_portal'
    contact_id:
      description: ID of the contact person
      type: string
      example: 460000000026049
    is_primary_contact:
      description: To mark contact person as primary for communication.
      type: boolean
      example: true
    mark-as-primary-contact-person-response:
      type: object
      properties:
        code:
          type: integer
          example: 0
          readOnly: true
        message:
          type: string
          example: This contact person has been marked as your primary contact person.
          readOnly: true
    is_added_in_portal:
      description: tells whether the contact person has portal access or not
      type: boolean
      example: true
    designation:
      description: designation of the contact person in the organisation. Maximum length [50]
      type: string
      example: Sales Engineer
    salutation:
      description: Salutation for the contact. Maximum length allowed [25]
      type: string
      example: Mr
    is_sms_enabled:
      description: Used to check if SMS communication preference is enabled for the contact person.
      type: boolean
      example: true
      x-node_available_in:
      - SMS integration
    email:
      description: Email ID of the contact person. Maximum length allowed [100]
      type: string
      example: willsmith@bowmanfurniture.com
    department:
      description: department to which the contact person belongs. Maximum length [50]
      type: string
      example: Sales
    communication_preference:
      description: Preferred modes of communication for the contact person.
      type: object
      properties:
        is_sms_enabled:
          $ref: '#/components/schemas/is_sms_enabled'
        is_whatsapp_enabled:
          $ref: '#/components/schemas/is_whatsapp_enabled'
    contact_person-response:
      type: object
      properties:
        contact_id:
          $ref: '#/components/schemas/contact_id'
        contact_person_id:
          $ref: '#/components/schemas/contact_person_id'
        salutation:
          $ref: '#/components/schemas/salutation'
        first_name:
          $ref: '#/components/schemas/first_name'
        last_name:
          $ref: '#/components/schemas/last_name'
        email:
          $ref: '#/components/schemas/email'
        phone:
          $ref: '#/components/schemas/phone'
        mobile:
          $ref: '#/components/schemas/mobile'
        is_primary_contact:
          $ref: '#/components/schemas/is_primary_contact'
        skype:
          $ref: '#/components/schemas/skype'
        designation:
          $ref: '#/components/schemas/designation'
        department:
          $ref: '#/components/schemas/department'
        is_added_in_portal:
          $ref: '#/components/schemas/is_added_in_portal'
        communication_preference:
          $ref: '#/components/schemas/communication_preference'
    get-a-contact-person-response:
      type: object
      properties:
        code:
          type: integer
          example: 0
          readOnly: true
        message:
          type: string
          example: success
          readOnly: true
        contact_person:
          type: object
          properties:
            contact_id:
              $ref: '#/components/schemas/contact_id'
            contact_person_id:
              $ref: '#/components/schemas/contact_person_id'
            salutation:
              $ref: '#/components/schemas/salutation'
            first_name:
              $ref: '#/components/schemas/first_name'
            last_name:
              $ref: '#/components/schemas/last_name'
            email:
              $ref: '#/components/schemas/email'
            phone:
              $ref: '#/components/schemas/phone'
            mobile:
              $ref: '#/components/schemas/mobile'
            is_primary_contact:
              $ref: '#/components/schemas/is_primary_contact'
            skype:
              $ref: '#/components/schemas/skype'
            designation:
              $ref: '#/components/schemas/designation'
            department:
              $ref: '#/components/schemas/department'
            is_added_in_portal:
              $ref: '#/components/schemas/is_added_in_portal'
            communication_preference:
              $ref: '#/components/schemas/communication_preference'
    create-a-contact-person-response:
      type: object
      properties:
        code:
          type: integer
          example: 0
          readOnly: true
        message:
          type: string
          example: The contact person has been Created
          readOnly: true
        contact_person:
          type: array
          items:
            $ref: '#/components/schemas/contact_person-response'
    update-a-contact-person-request:
      required:
      - contact_id
      - first_name
      type: object
      properties:
        contact_id:
          $ref: '#/components/schemas/contact_id'
        salutation:
          $ref: '#/components/schemas/salutation'
        first_name:
          $ref: '#/components/schemas/first_name'
        last_name:
          $ref: '#/components/schemas/last_name'
        email:
          $ref: '#/components/schemas/email'
        phone:
          $ref: '#/components/schemas/phone'
        mobile:
          $ref: '#/components/schemas/mobile'
        skype:
          $ref: '#/components/schemas/skype'
        designation:
          $ref: '#/components/schemas/designation'
        department:
          $ref: '#/components/schemas/department'
        enable_portal:
          $ref: '#/components/schemas/enable_portal'
        communication_preference:
          $ref: '#/components/schemas/communication_preference'
    last_name:
      description: Last Name of the contact. Maximum length allowed [100]
      type: string
      example: Smith
    is_whatsapp_enabled:
      description: Used to check if WhatsApp communication preference is enabled for the contact person.
      type: boolean
      example: true
      x-node_available_in:
      - WhatsApp integration
    mobile:
      description: Mobile/Cell number of the contact person. Maximum length [50]
      type: string
      example: +1-4054439562
    skype:
      description: skype address of the contact person. Maximum length [50]
      type: string
      example: zoho
    enable_portal:
      description: option to enable or disable portal access the contact person. allowed values <code>true</code>,<code>false</code>
      type: boolean
      example: true
    contact_person_id:
      description: The ID of the contact person
      type: string
      example: 460000000026051
    create-a-contact-person-request:
      required:
      - first_name
      type: object
      properties:
        contact_id:
          $ref: '#/components/schemas/contact_id'
        salutation:
          $ref: '#/components/schemas/salutation'
        first_name:
          $ref: '#/components/schemas/first_name'
        last_name:
          $ref: '#/components/schemas/last_name'
        email:
          $ref: '#/components/schemas/email'
        phone:
          $ref: '#/components/schemas/phone'
        mobile:
          $ref: '#/components/schemas/mobile'
        skype:
          $ref: '#/components/schemas/skype'
        designation:
          $ref: '#/components/schemas/designation'
        department:
          $ref: '#/components/schemas/department'
        enable_portal:
          $ref: '#/components/schemas/enable_portal'
        communication_preference:
          $ref: '#/components/schemas/communication_preference'
  parameters:
    organization_id:
      name: organization_id
      description: ID of the organization
      in: query
      required: true
      schema:
        type: string
      example: '10234695'
  securitySchemes:
    Zoho_Auth:
      type: oauth2
      flows:
        implicit:
          authorizationUrl: https://accounts.zoho.com/oauth/v2/auth
          scopes:
            ZohoInventory.items.CREATE: Create Items
            ZohoInventory.items.READ: Read Items
            ZohoInventory.items.UPDATE: Update Items
            ZohoInventory.items.DELETE: Delete Items