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

# Get Leads

> This endpoint provides a list of leads containing session IDs and user information such as name, email, and phone number.



## OpenAPI

````yaml POST /get-conversation-ids/{bot_id}
openapi: 3.0.1
info:
  title: OpenAPI Plant Store
  description: >-
    A sample API that uses a plant store as an example to demonstrate features
    in the OpenAPI specification
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.public.chatnode.ai/v1
security:
  - bearerAuth: []
paths:
  /get-conversation-ids/{bot_id}:
    post:
      description: >-
        This endpoint provides a list of leads containing session IDs and user
        information such as name, email, and phone number.
      parameters:
        - name: bot_id
          in: path
          description: The agent id associated with the trained agent model.
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Conversation list response.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Conversation'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Unauthorized'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Forbidden'
components:
  schemas:
    Conversation:
      required:
        - session_id
        - created_at
      type: object
      properties:
        session_id:
          type: string
          description: The unique ID of the lead.
          example: aki56d7-1719768767426
        created_at:
          type: string
          format: date-time
          description: The timestamp when the session was lead.
          example: '2024-06-30T17:32:53.518+00:00'
        enduser_name:
          type: string
          description: The name of the end user associated with the lead.
          example: John Doe
        enduser_email:
          type: string
          description: The email address of the end user associated with the lead.
          example: john@doe.com
        enduser_phone:
          type: string
          description: The phone number of the end user associated with the lead.
          example: '+13434346567'
        for_agent:
          type: boolean
          description: >-
            A boolean flag that indicates whether the conversation has been
            transferred to a live agent.
          example: false
    Unauthorized:
      required:
        - message
      type: object
      properties:
        message:
          type: string
          example: Bearer token missing or unknown
    Forbidden:
      required:
        - message
      type: object
      properties:
        message:
          type: string
          example: Bot access not allowed
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````