Landing.ai Model API

The Model API from Landing.ai — 3 operation(s) for model.

OpenAPI Specification

landingai-model-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: 'LandingAI Agentic Document Extraction (ADE) API v1: Parse, Extract, Classify, Split, Section Classes Model API'
  version: 0.1.0
  description: 'Convert documents such as PDFs, images, and Office files into structured data with LandingAI''s Agentic Document Extraction (ADE) v1 endpoints. Includes Parse (documents to Markdown and structured chunks with grounding), Extract (schema-based field extraction), Classify (page-level classification), Split (separate multi-document files), and Section (hierarchical table of contents), plus asynchronous jobs for parsing and extraction. Documentation: https://docs.landing.ai'
servers:
- url: https://api.va.landing.ai
  description: Production vision tools API
tags:
- name: Model
paths:
  /v1/projects/{project_id}/models:
    get:
      tags:
      - Model
      summary: Get Models
      operationId: get_models_v1_projects__project_id__models_get
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: integer
          title: Project Id
      - name: timeout
        in: query
        required: false
        schema:
          anyOf:
          - type: integer
          - type: 'null'
          default: 60
          title: Timeout
      - name: apikey
        in: header
        required: false
        schema:
          anyOf:
          - type: string
          - type: 'null'
          title: Apikey
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ModelsResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /v1/projects/{project_id}/models/{model_id}:
    get:
      tags:
      - Model
      summary: Get Single Model
      operationId: get_single_model_v1_projects__project_id__models__model_id__get
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: integer
          title: Project Id
      - name: model_id
        in: path
        required: true
        schema:
          type: string
          format: uuid4
          title: Model Id
      - name: timeout
        in: query
        required: false
        schema:
          anyOf:
          - type: integer
          - type: 'null'
          default: 60
          title: Timeout
      - name: apikey
        in: header
        required: false
        schema:
          anyOf:
          - type: string
          - type: 'null'
          title: Apikey
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ModelResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /v1/projects/{project_id}/models/{model_id}/download:
    post:
      tags:
      - Model
      summary: Get Model Download Url
      operationId: get_model_download_url_v1_projects__project_id__models__model_id__download_post
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: integer
          title: Project Id
      - name: model_id
        in: path
        required: true
        schema:
          type: string
          format: uuid4
          title: Model Id
      - name: timeout
        in: query
        required: false
        schema:
          anyOf:
          - type: integer
          - type: 'null'
          default: 60
          title: Timeout
      - name: apikey
        in: header
        required: false
        schema:
          anyOf:
          - type: string
          - type: 'null'
          title: Apikey
      requestBody:
        content:
          application/json:
            schema:
              anyOf:
              - $ref: '#/components/schemas/ModelDownloadRequest'
              - type: 'null'
              title: Payload
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ModelDownloadResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    ModelDownloadResponse:
      properties:
        data:
          anyOf:
          - $ref: '#/components/schemas/ModelDownload'
          - type: 'null'
      type: object
      required:
      - data
      title: ModelDownloadResponse
    ModelResponse:
      properties:
        data:
          anyOf:
          - $ref: '#/components/schemas/ModelItem'
          - type: 'null'
      type: object
      required:
      - data
      title: ModelResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    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
    ModelsResponse:
      properties:
        data:
          anyOf:
          - items:
              $ref: '#/components/schemas/ModelItem'
            type: array
          - type: 'null'
          title: Data
      type: object
      required:
      - data
      title: ModelsResponse
    ModelDownload:
      properties:
        downloadUrl:
          anyOf:
          - type: string
          - type: 'null'
          title: Downloadurl
        threshold:
          type: number
          title: Threshold
      type: object
      required:
      - threshold
      title: ModelDownload
    ModelItem:
      properties:
        id:
          type: string
          format: uuid4
          title: Id
          description: The model ID
        name:
          anyOf:
          - type: string
          - type: 'null'
          title: Name
      type: object
      required:
      - id
      - name
      title: ModelItem
    ModelDownloadRequest:
      properties:
        threshold:
          type: number
          title: Threshold
      type: object
      required:
      - threshold
      title: ModelDownloadRequest
  securitySchemes:
    Basic Auth:
      type: http
      description: 'Your unique API key for authentication.


        Get your API key here: https://va.landing.ai/settings/api-key.


        If using the EU endpoint, get your API key here: https://va.eu-west-1.landing.ai/settings/api-key.'
      scheme: bearer
      bearerFormat: Basic