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

# Model Selection

> Endpoint for fetching all available models.

> [!WARNING]
>
> **API v1 is deprecated.** This version is no longer being developed — new endpoints, parameters and models are added> to v2 only. Use the v2 endpoints to stay current: [v2 API documentation](https://docs.deapi.ai/api/v2/overview.md).


## OpenAPI

````yaml openapi-v1.json GET /api/v1/client/models
openapi: 3.0.0
info:
  title: deAPI REST API v1 (legacy)
  description: >-
    Legacy v1 API. For new integrations use API v2 — its OpenAPI spec is
    https://docs.deapi.ai/openapi.json. Decentralized AI inference API for image
    generation, video processing, audio transcription, and more.
  contact:
    name: deAPI Support
    url: https://deapi.ai
    email: support@deapi.ai
  version: 0.0.1
servers:
  - url: https://api.deapi.ai
    description: Production API Server base URL
security:
  - bearerAuth: []
tags:
  - name: Client API
    description: Endpoints for client operations
paths:
  /api/v1/client/models:
    get:
      tags:
        - Client API
      description: Endpoint for fetching all available models.
      operationId: clientModels
      parameters:
        - $ref: '#/components/parameters/AcceptHeader'
        - name: limit
          in: query
          description: >-
            Page size: how many models a single call returns. **Always send
            `limit=50`** — it is the maximum page size and returns the whole
            catalogue in one call. Omit it and the endpoint falls back to 25
            models and gives no indication that the rest are missing. A value
            above 50 is clamped to 50, not rejected. This is the parameter that
            widens the page; `per_page` does not work.
          required: false
          example: 50
          schema:
            type: integer
            default: 25
            minimum: 1
            maximum: 50
            example: 50
        - name: per_page
          in: query
          description: >-
            Accepted but currently ignored: it does not change the page size
            regardless of the value sent. Use `limit` to widen the page and
            `page` to retrieve the remaining results.
          required: false
          schema:
            type: integer
            default: 25
        - name: page
          in: query
          description: >-
            Page number, starting at 1. Rarely needed: with `limit=50` the whole
            catalogue is returned on page 1 and `meta.last_page` reads 1. Should
            the catalogue ever outgrow 50 entries, `meta.last_page` becomes
            greater than 1 and you fetch the remaining pages with this
            parameter.
          required: false
          schema:
            type: integer
            default: 1
        - name: filter[inference_types]
          in: query
          description: >-
            Comma-separated list of inference types to filter by. Example:
            txt2img,txt2audio. Values must match the `inference_types` strings
            returned by this endpoint exactly — note that some of them use
            hyphens (`img-upscale`, `img-rmbg`, `vid-upscale`). An unrecognised
            value is not rejected: the endpoint returns an empty `data` array.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: string
              enum:
                - txt2img
                - img2txt
                - txt2audio
                - txt2music
                - txt2video
                - img2video
                - img2img
                - audio2video
                - img-upscale
                - img-rmbg
                - vid-upscale
                - txt2embedding
                - audio2text
                - video2text
                - audio_file2text
                - video_file2text
      responses:
        '200':
          description: List of available models.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClientDiffusionModelCollection'
        '401':
          description: Unauthorized user.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/response_error_default'
        '404':
          description: Request not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/response_error_default'
        '429':
          $ref: '#/components/responses/RateLimitExceeded'
      security:
        - bearerAuth: []
components:
  parameters:
    AcceptHeader:
      name: Accept
      in: header
      required: true
      schema:
        type: string
        default: application/json
        enum:
          - application/json
  schemas:
    ClientDiffusionModelCollection:
      properties:
        data:
          description: List of available models
          type: array
          items:
            $ref: '#/components/schemas/ClientDiffusionModelResource'
      type: object
    response_error_default:
      properties:
        data:
          description: Information from success endpoint
          type: object
        message:
          description: Error general message
          type: string
        errors:
          description: Information about errors
          type: array
          items: {}
        statusCode:
          description: Status code
          type: integer
      type: object
    ClientDiffusionModelResource:
      properties:
        name:
          type: string
        slug:
          type: string
        inference_types:
          description: >-
            Available inference types for this model with their specific
            configurations
          type: object
        info:
          description: >-
            Model specifications including limits, features, and defaults.
            Structure varies by model type.
          type: object
          example:
            limits:
              min_width: 64
              max_width: 2048
              min_height: 64
              max_height: 2048
              min_steps: 1
              max_steps: 150
              min_cfg_scale: 1
              max_cfg_scale: 30
              min_duration: 0.5
              max_duration: 10
              min_fps: 8
              max_fps: 30
            features:
              supports_last_frame: true
              supports_negative_prompt: true
              supports_controlnet: false
              supports_lora: true
              supports_voice_presets: true
              supports_custom_voice: false
            defaults:
              width: 512
              height: 512
              steps: 20
              cfg_scale: 7.5
              negative_prompt: no disfigurations
              fps: 24
              duration: 4
              voice: alloy
          additionalProperties: true
        loras:
          description: >-
            Available LoRA models for this diffusion model. Only present when
            the model supports LoRA and has LoRA models available.
          type: array
          items:
            $ref: '#/components/schemas/ClientLoraResource'
          nullable: true
        languages:
          description: >-
            Available languages and voices for this model. Only present for TTS
            models that support multiple languages.
          type: array
          items:
            $ref: '#/components/schemas/ClientLanguageResource'
          nullable: true
      type: object
    response_error_rate_limit:
      description: Rate limit exceeded response
      properties:
        message:
          description: Error message
          type: string
          example: Too Many Attempts.
      type: object
    ClientLoraResource:
      properties:
        display_name:
          description: Human friendly Lora name
          type: string
        name:
          description: Lora name
          type: string
      type: object
    ClientLanguageResource:
      properties:
        name:
          description: Language display name
          type: string
        slug:
          description: Language identifier slug
          type: string
        voices:
          description: Available voices for this language
          type: array
          items:
            $ref: '#/components/schemas/ClientVoiceResource'
      type: object
    ClientVoiceResource:
      properties:
        name:
          description: Voice display name
          type: string
        slug:
          description: Voice identifier slug
          type: string
        gender:
          description: Voice gender classification
          type: string
          nullable: true
      type: object
  responses:
    RateLimitExceeded:
      description: >-
        Rate limit exceeded. Check X-RateLimit-Type header to determine if
        minute (RPM) or daily (RPD) limit was hit.
      headers:
        X-RateLimit-Limit:
          description: Maximum requests allowed per minute (RPM)
          schema:
            type: integer
            example: 3
        X-RateLimit-Remaining:
          description: Remaining requests in current minute window
          schema:
            type: integer
            example: 0
        X-RateLimit-Daily-Limit:
          description: Maximum requests allowed per day (RPD)
          schema:
            type: integer
            example: 100
        X-RateLimit-Daily-Remaining:
          description: Remaining requests in current day window
          schema:
            type: integer
            example: 95
        X-RateLimit-Type:
          description: 'Type of rate limit exceeded: "minute" for RPM, "daily" for RPD'
          schema:
            type: string
            enum:
              - minute
              - daily
            example: minute
        Retry-After:
          description: >-
            Seconds until rate limit resets (60 for minute, up to 86400 for
            daily)
          schema:
            type: integer
            example: 60
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/response_error_rate_limit'
  securitySchemes:
    bearerAuth:
      type: http
      bearerFormat: JWT
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.