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

# List Document Templates

> Retrieve a paginated list of document templates with optional filtering. Useful for browsing available templates and selecting one for document processing.

**Pagination:**
- Control page size with `page[size]` (default: 15, max: 100)
- Navigate using cursor-based pagination with `page[after]` and `page[before]`
- Include total count with `page[total]=true` (note: may impact performance)
- Use response `links` for easy navigation between pages

**Filtering:**
- Filter by `status` to show only 'published' templates
- Filter by `is_active` to show only currently active templates

**Common Queries:**
- Active templates: `?filter[is_active]=true`
- Recent templates: `?page[size]=10` (sorted by creation date)



## OpenAPI

````yaml GET /v1/document-templates
openapi: 3.1.0
info:
  title: Beltic Document API
  version: 1.0.0
  description: >-
    # The Beltic Document API provides a comprehensive solution for document
    processing with AI-powered data extraction and fraud detection capabilities.


    ## Key Features


    - **Template-Based Processing**: Create reusable document templates with
    predefined schemas and processing configurations

    - **Ad-Hoc Processing**: Process documents without templates using custom
    configurations

    - **AI Data Extraction**: Intelligent document data extraction powered by AI

    - **Fraud Detection**: Document authenticity verification and fraud analysis

    - **Secure File Handling**: Pre-signed URLs for secure file uploads


    ## Workflow


    1. **Create a Document Template**: Define a template with extraction schema
    and fraud detection settings

    2. **Create a Document**: Initialize a document with either a template
    reference or ad-hoc configuration

    3. **Upload File**: Use the pre-signed URL to upload your document file

    4. **Automatic Processing**: Once uploaded, the document is automatically
    processed with extraction and fraud detection

    5. **Retrieve Results**: Fetch the document to access extracted data and
    fraud analysis results


    ## Authentication


    All endpoints require authentication. Include your API key in the
    `X-Api-Key` header:

    ```

    X-Api-Key: YOUR_API_KEY

    ```


    ## Response Format


    All responses follow the JSON:API specification for consistent data
    structures.
  contact:
    name: Beltic API Support
    email: engineering@beltic.com
servers:
  - url: https://api.beltic.com
    description: Production
security:
  - ApiKeyAuth: []
tags:
  - name: Document Templates
    description: >-
      Manage document templates for repeatable processing workflows. Templates
      define the structure and processing configuration for documents including
      JSON schemas for data extraction and fraud detection settings.
  - name: Documents
    description: >-
      Create and manage documents for processing. Documents can be associated
      with a template for standardized processing, or configured ad-hoc with
      custom settings. The workflow involves creating a document record,
      uploading the file via pre-signed URL, and automatically processing the
      document with AI-powered extraction and fraud detection. Documents track
      their processing status and store extracted data and fraud analysis
      results.
  - name: Webhooks
    description: >-
      Configure webhook endpoints to receive real-time notifications when
      document status changes. Webhooks support automatic retries with
      exponential backoff and provide options for manual resend and DLQ
      reprocessing.
externalDocs:
  description: Beltic Platform Documentation
  url: https://docs.beltic.com
paths:
  /v1/document-templates:
    get:
      tags:
        - Document Templates
      summary: List document templates
      description: >-
        Retrieve a paginated list of document templates with optional filtering.
        Useful for browsing available templates and selecting one for document
        processing.


        **Pagination:**

        - Control page size with `page[size]` (default: 15, max: 100)

        - Navigate using cursor-based pagination with `page[after]` and
        `page[before]`

        - Include total count with `page[total]=true` (note: may impact
        performance)

        - Use response `links` for easy navigation between pages


        **Filtering:**

        - Filter by `status` to show only 'published' templates

        - Filter by `is_active` to show only currently active templates


        **Common Queries:**

        - Active templates: `?filter[is_active]=true`

        - Recent templates: `?page[size]=10` (sorted by creation date)
      parameters:
        - schema:
            type: string
            pattern: ^\d+$
            description: 'Number of items per page (default: 15)'
            example: '15'
          required: false
          description: 'Number of items per page (default: 15)'
          name: page[size]
          in: query
        - schema:
            type: string
            description: Cursor for fetching items after this point
            example: >-
              eyJ2YWx1ZXMiOnsiY3JlYXRlZF9hdCI6IjIwMjUtMTAtMjJUMjI6MTM6NDguMTQ5WiJ9LCJpZCI6IjNkZjk3MWQwLWNkNTYtNDAwNi05YmM0LTFjYmMzMjc1OWI2ZiJ9
          required: false
          description: Cursor for fetching items after this point
          name: page[after]
          in: query
        - schema:
            type: string
            description: Cursor for fetching items before this point
            example: >-
              eyJ2YWx1ZXMiOnsiY3JlYXRlZF9hdCI6IjIwMjUtMTAtMjJUMjI6MTM6NDguMTQ5WiJ9LCJpZCI6IjNkZjk3MWQwLWNkNTYtNDAwNi05YmM0LTFjYmMzMjc1OWI2ZiJ9
          required: false
          description: Cursor for fetching items before this point
          name: page[before]
          in: query
        - schema:
            type: string
            enum:
              - 'true'
              - 'false'
            description: Include total count in response (may impact performance)
            example: 'true'
          required: false
          description: Include total count in response (may impact performance)
          name: page[total]
          in: query
        - schema:
            type: string
            enum:
              - published
            description: Filter templates by status
            example: published
          required: false
          description: Filter templates by status
          name: filter[status]
          in: query
        - schema:
            type: string
            enum:
              - 'true'
              - 'false'
            description: 'Filter templates by active state (default: true)'
            example: 'true'
          required: false
          description: 'Filter templates by active state (default: true)'
          name: filter[is_active]
          in: query
      responses:
        '200':
          description: Templates retrieved successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        type:
                          type: string
                          enum:
                            - document-template
                        id:
                          type: string
                          format: uuid
                          description: Template unique identifier
                          example: 123e4567-e89b-12d3-a456-426614174000
                        attributes:
                          type: object
                          properties:
                            name:
                              type: string
                            description:
                              type:
                                - string
                                - 'null'
                            extraction_config:
                              type: object
                              properties:
                                enabled:
                                  type: boolean
                                schema: {}
                                extraction_rules:
                                  type: string
                              required:
                                - enabled
                            fraud_config:
                              type: object
                              properties:
                                enabled:
                                  type: boolean
                                requires_digital_signature:
                                  type: boolean
                              required:
                                - enabled
                            status:
                              type: string
                              enum:
                                - published
                            is_active:
                              type: boolean
                            created_at:
                              type: string
                            updated_at:
                              type: string
                          required:
                            - name
                            - extraction_config
                            - fraud_config
                        relationships:
                          type: object
                          properties: {}
                      required:
                        - type
                        - id
                        - attributes
                  meta:
                    type: object
                    properties:
                      page:
                        type: object
                        properties:
                          cursors:
                            type: object
                            properties:
                              start:
                                type:
                                  - string
                                  - 'null'
                              end:
                                type:
                                  - string
                                  - 'null'
                            required:
                              - start
                              - end
                          hasNextPage:
                            type: boolean
                          hasPreviousPage:
                            type: boolean
                          total:
                            type: number
                        required:
                          - cursors
                          - hasNextPage
                          - hasPreviousPage
                    required:
                      - page
                  links:
                    type: object
                    properties:
                      self:
                        type: string
                      first:
                        type: string
                      next:
                        type: string
                      prev:
                        type: string
                      last:
                        type: string
                    required:
                      - self
                      - first
                required:
                  - data
                  - meta
                  - links
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: array
                    items:
                      type: object
                      properties:
                        status:
                          type: string
                        title:
                          type: string
                        detail:
                          type: string
                      required:
                        - status
                        - title
                        - detail
                required:
                  - errors
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-Api-Key
      description: |-
        API key for authentication.
        Access https://console.beltic.com/ to obtain your API key.

````