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

# List integration tools

> List all tools from an integration. For MCP: fetches from MCP server with name-based cursors. For HTTP: returns tools from database with UUID cursors. Automatically syncs MCP tools.



## OpenAPI

````yaml /api-reference/openapi.json get /v1/integration/{integration_id}/tool
openapi: 3.1.0
info:
  title: Diga API
  version: 0.1.0
servers:
  - url: https://api.diga.io
    description: Production
security: []
paths:
  /v1/integration/{integration_id}/tool:
    get:
      tags:
        - Integration
      summary: List integration tools
      description: >-
        List all tools from an integration. For MCP: fetches from MCP server
        with name-based cursors. For HTTP: returns tools from database with UUID
        cursors. Automatically syncs MCP tools.
      operationId: list_tools_v1_integration__integration_id__tool_get
      parameters:
        - name: integration_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            description: Integration ID
            title: Integration Id
          description: Integration ID
        - name: after
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: After
        - name: before
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Before
        - name: page
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
                minimum: 1
              - type: 'null'
            title: Page
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 100
            minimum: 1
            default: 20
            title: Limit
        - name: order
          in: query
          required: false
          schema:
            enum:
              - asc
              - desc
            type: string
            default: desc
            title: Order
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/PaginatedResponse_Union_HttpToolResponseSchema__McpToolSchema__
        '400':
          description: Bad request - Invalid integration type
          content:
            application/json:
              example:
                status: error
                error_code: INTEGRATION_TYPE
                message: Invalid integration type
              schema:
                $ref: '#/components/schemas/ErrorResponseSchema'
        '401':
          description: Unauthorized - MCP authentication failed
          content:
            application/json:
              example:
                status: error
                error_code: M_C_P_AUTHENTICATION_FAILED
                message: MCP server authentication failed
              schema:
                $ref: '#/components/schemas/ErrorResponseSchema'
        '403':
          description: Forbidden - Insufficient permissions
          content:
            application/json:
              example:
                status: error
                error_code: INTERNAL_SERVER_ERROR
                message: Missing required permissions to view integration tools
              schema:
                $ref: '#/components/schemas/ErrorResponseSchema'
        '404':
          description: Integration Not Found
          content:
            application/json:
              example:
                status: error
                error_code: INTEGRATION_NOT_FOUND
                message: Integration 550e8400-e29b-41d4-a716-446655440000 not found
              schema:
                $ref: '#/components/schemas/ErrorResponseSchema'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '500':
          description: Internal Server Error
          content:
            application/json:
              example:
                status: error
                error_code: INTERNAL_SERVER_ERROR
                message: 'Error: Internal Server Error'
              schema:
                $ref: '#/components/schemas/ErrorResponseSchema'
        '502':
          description: Bad gateway - MCP server error
          content:
            application/json:
              example:
                status: error
                error_code: M_C_P_SERVER_ERROR
                message: MCP server returned an error
              schema:
                $ref: '#/components/schemas/ErrorResponseSchema'
        '504':
          description: Gateway timeout - MCP connection timeout
          content:
            application/json:
              example:
                status: error
                error_code: M_C_P_CONNECTION_TIMEOUT
                message: Connection to MCP server timed out
              schema:
                $ref: '#/components/schemas/ErrorResponseSchema'
      security:
        - CustomHTTPBearer: []
components:
  schemas:
    PaginatedResponse_Union_HttpToolResponseSchema__McpToolSchema__:
      properties:
        data:
          items:
            anyOf:
              - $ref: '#/components/schemas/HttpToolResponseSchema'
              - $ref: '#/components/schemas/McpToolSchema'
          type: array
          title: Data
        first_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: First Id
        last_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Last Id
        has_more:
          type: boolean
          title: Has More
        current_page:
          anyOf:
            - type: integer
            - type: 'null'
          title: Current Page
        total_pages:
          anyOf:
            - type: integer
            - type: 'null'
          title: Total Pages
      type: object
      required:
        - data
        - has_more
      title: PaginatedResponse[Union[HttpToolResponseSchema, McpToolSchema]]
    ErrorResponseSchema:
      properties:
        status:
          type: string
          title: Status
          description: Status of the response, always 'error' for error responses
          default: error
        error_code:
          type: string
          title: Error Code
          description: Machine-readable error code in SCREAMING_SNAKE_CASE format
          examples:
            - PROJECT_NOT_FOUND
            - INVALID_EMAIL
            - UNAUTHORIZED_ROLE
        message:
          type: string
          title: Message
          description: Human-readable error message with details
          examples:
            - Project with id 550e8400-e29b-41d4-a716-446655440000 not found
            - The email invalid@email is not valid
            - Insufficient permissions to perform this action
      type: object
      required:
        - error_code
        - message
      title: ErrorResponseSchema
      description: Standard error response format for all API errors.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    HttpToolResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Tool Id
          description: The unique identifier for the tool
        type:
          type: string
          const: HTTP
          title: Type
          default: HTTP
        name:
          type: string
          title: Tool Name
          description: The name of the tool
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: The description given to the agent to understand the tool
        endpoint_path:
          anyOf:
            - type: string
            - type: 'null'
          title: Endpoint URL
          description: The URL to the endpoint of the tool
        query:
          anyOf:
            - items:
                $ref: '#/components/schemas/QueryParamSchema'
              type: array
            - type: 'null'
          title: Query Parameters
          description: The query parameters for the tool
          default: []
        body:
          anyOf:
            - items:
                $ref: '#/components/schemas/BodyParamSchema-Output'
              type: array
            - type: 'null'
          title: Body Parameters
          description: The body parameters for the tool
          default: []
        headers:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Headers
          description: The headers for the tool
        method:
          $ref: '#/components/schemas/HttpMethods'
          title: Method
          description: The HTTP method for the tool
        timeout:
          anyOf:
            - type: integer
            - type: 'null'
          title: Timeout
          description: Timeout for the API to send a response
          default: 5
        approval_required:
          type: boolean
          title: Approval Required
          description: If true, the agent will ask for confirmation before executing
          default: false
        execution_audio:
          anyOf:
            - $ref: '#/components/schemas/ExecutionAudio'
            - type: 'null'
          title: Execution Sound
          description: Background sound to play while the tool is executing
        pre_speech:
          type: string
          enum:
            - auto
            - force
          title: Pre-Speech
          description: 'Whether agent should speak before executing: ''auto'' or ''force'''
          default: auto
      type: object
      required:
        - id
        - name
        - headers
        - method
      title: HttpToolResponseSchema
    McpToolSchema:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Tool Id
          description: The unique identifier for the tool in the database
        type:
          type: string
          const: MCP
          title: Type
          default: MCP
        name:
          type: string
          title: Tool Name
          description: The name of the tool
        description:
          type: string
          title: Description
          description: The description given to the agent to understand the tool
        parameters:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Input Schema
          description: JSON schema for the tool parameters
        approval_required:
          type: boolean
          title: Approval Required
          description: If true, the agent will ask for confirmation before executing
          default: false
      type: object
      required:
        - name
        - description
      title: McpToolSchema
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    QueryParamSchema:
      properties:
        name:
          type: string
          title: Parameter Name
          description: Parameter name without spaces
        data_type:
          $ref: '#/components/schemas/SimpleDataTypes'
          title: Type
          description: Data type of the parameter
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Description of what the parameter does
        required:
          type: boolean
          title: Required
          description: Indicates if the parameter is required.
          default: true
        value_source:
          $ref: '#/components/schemas/ParamValueSource'
          title: Value Source
          description: Source of the parameter value (llm or fixed)
          default: llm
        fixed_value:
          anyOf:
            - type: string
            - type: integer
            - type: number
            - type: boolean
            - type: 'null'
          title: Fixed Value
          description: Fixed value for the parameter when value_source is FIXED
      type: object
      required:
        - name
        - data_type
      title: QueryParamSchema
      description: Schema for defining parameters with specific validations.
    BodyParamSchema-Output:
      properties:
        name:
          type: string
          title: Parameter Name
          description: Parameter name without spaces
        data_type:
          $ref: '#/components/schemas/DataTypes'
          title: Type
          description: Data type of the parameter
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Description of what the parameter does
        required:
          type: boolean
          title: Required
          description: Indicates if the parameter is required.
          default: true
        value_source:
          $ref: '#/components/schemas/ParamValueSource'
          title: Value Source
          description: Source of the parameter value (llm or fixed)
          default: llm
        fixed_value:
          anyOf:
            - type: string
            - type: integer
            - type: number
            - type: boolean
            - type: 'null'
          title: Fixed Value
          description: Fixed value for the parameter when value_source is FIXED
        properties:
          anyOf:
            - items:
                $ref: '#/components/schemas/BodyParamSchema-Output'
              type: array
            - type: 'null'
          title: Nested Properties
          description: Nested parameters for object/complex types
      type: object
      required:
        - name
        - data_type
      title: BodyParamSchema
      description: Schema for defining parameters with specific validations.
    HttpMethods:
      type: string
      enum:
        - GET
        - POST
        - PUT
        - DELETE
        - PATCH
      title: HttpMethods
    ExecutionAudio:
      type: string
      enum:
        - waiting_music
        - typing
      title: ExecutionAudio
    SimpleDataTypes:
      type: string
      enum:
        - string
        - integer
        - number
        - boolean
      title: SimpleDataTypes
    ParamValueSource:
      type: string
      enum:
        - llm
        - fixed
        - dynamic
      title: ParamValueSource
    DataTypes:
      type: string
      enum:
        - string
        - integer
        - number
        - boolean
        - object
      title: DataTypes
  securitySchemes:
    CustomHTTPBearer:
      type: http
      scheme: bearer

````