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

# List Batches

> List batch jobs for the authenticated key's owner.

Returns MeshAPI's own BatchJob records (unified view across all providers)
in the OpenAI list format: `{"object": "list", "data": [...], "has_more": bool}`.
Supports cursor-based pagination via `after` (batch_id) and `limit`.



## OpenAPI

````yaml /api/openapi.json get /v1/batches
openapi: 3.1.0
info:
  title: MeshAPI
  description: One key, all AI models.
  version: 0.1.0
servers:
  - url: https://api.meshapi.ai
security:
  - BearerAuth: []
paths:
  /v1/batches:
    get:
      tags:
        - Batch
      summary: List Batches
      description: >-
        List batch jobs for the authenticated key's owner.


        Returns MeshAPI's own BatchJob records (unified view across all
        providers)

        in the OpenAI list format: `{"object": "list", "data": [...],
        "has_more": bool}`.

        Supports cursor-based pagination via `after` (batch_id) and `limit`.
      operationId: list_batches
      parameters:
        - name: after
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: After
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 100
            minimum: 1
            default: 20
            title: Limit
        - in: header
          name: X-Mesh-Version
          required: false
          schema:
            type: string
            enum:
              - 2026-08
            default: 2026-08
          example: 2026-08
          description: >-
            Dated version of the API contract to pin this request to. Omit it
            and the request is served under `2026-08` — the oldest supported
            version, so an existing integration is never moved by a release. A
            malformed or unsupported value is rejected with `400
            invalid_api_version` rather than falling back silently. The version
            actually served is echoed as `X-Mesh-Version` on every response,
            including errors.
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
              examples:
                default:
                  summary: Example response
                  value:
                    object: list
                    data:
                      - id: batch_6a46708ba644819099dacb31e0339a86
                        object: batch
                        endpoint: /v1/chat/completions
                        input_file_id: file-2LvNxHkyRFbSPcLEnEdHW9
                        completion_window: 24h
                        status: completed
                        created_at: 1783001227
                        completed_at: 1783004827
                        request_counts:
                          total: 2
                          completed: 2
                          failed: 0
                        metadata:
                          job_name: nightly-support-summaries
                    has_more: false
                    first_id: batch_6a46708ba644819099dacb31e0339a86
                    last_id: batch_6a46708ba644819099dacb31e0339a86
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - BearerAuth: []
components:
  schemas:
    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
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Enter your MeshAPI key (`rsk_...`) — sent as `Authorization: Bearer
        <key>`.

````