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

# List AI custom field definitions

> Get all custom field definitions for AI field extraction. (Permitted scopes: **fax:all:read**, **fax:ai_settings:read**)



## OpenAPI

````yaml get /accounts/self/ai/custom-fields
openapi: 3.0.1
info:
  title: Fax.Plus REST API
  description: >-
    This is the Fax.Plus API v3 developed for third party developers and
    organizations. In order to have a better coding experience with this API,
    let's quickly go through some points:<br /><br /> - This API assumes
    **/accounts** as an entry point with the base url of
    **https://restapi.fax.plus/v3**. <br /><br /> - This API treats all date and
    times sent to it in requests as **UTC**. Also, all dates and times returned
    in responses are in **UTC**<br /><br /> - Once you have an access_token, you
    can easily send a request to the resource server with the base url of
    **https://restapi.fax.plus/v3** to access your permitted resources. As an
    example to get the user's profile info you would send a request to
    **https://restapi.fax.plus/v3/accounts/self** when **Authorization** header
    is set to **Bearer YOUR_ACCESS_TOKEN** and custom header of
    **x-fax-clientid** is set to YOUR_CLIENT_ID
  version: 3.4.0
  contact:
    name: Fax.Plus
    email: info@fax.plus
    url: https://github.com/alohi
servers:
  - url: https://restapi.fax.plus/v3
  - url: /v3
security: []
paths:
  /accounts/self/ai/custom-fields:
    get:
      tags:
        - Fax AI
      summary: List AI custom field definitions
      description: >-
        Get all custom field definitions for AI field extraction. (Permitted
        scopes: **fax:all:read**, **fax:ai_settings:read**)
      operationId: listAiCustomFields
      responses:
        '200':
          $ref: '#/components/responses/AiCustomFieldList'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '500':
          $ref: '#/components/responses/ServerError'
      security:
        - oauth2:
            - all
        - personal_access_token:
            - fax:all:read
            - fax:ai_settings:read
components:
  responses:
    AiCustomFieldList:
      description: Response containing a list of custom field definitions
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/AiCustomFieldList'
    UnauthorizedError:
      description: Error object in case there's a problem with the authorization
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: unauthorized
            description: >-
              The access token provided is expired, revoked, malformed, or
              invalid for other reasons.
    ServerError:
      description: Error object in case there's a server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: internal_server_error
            description: An unexpected error happened, please contact support
  schemas:
    AiCustomFieldList:
      type: object
      description: List of AI custom field definitions
      properties:
        records:
          type: array
          items:
            $ref: '#/components/schemas/AiCustomField'
          description: List of custom field definitions
    Error:
      properties:
        description:
          type: string
        error:
          type: string
      additionalProperties: false
    AiCustomField:
      type: object
      description: AI custom field definition
      properties:
        id:
          type: string
          description: Unique identifier for the custom field
        name:
          type: string
          description: Display name of the custom field
        instructions:
          type: string
          description: AI extraction instructions for this field
        enabled:
          type: boolean
          description: Whether this custom field is active
      required:
        - id
        - name
        - instructions
        - enabled
      example:
        id: 507f1f77bcf86cd799439011
        name: Invoice Number
        instructions: Extract the invoice or reference number from the document
        enabled: true
  securitySchemes:
    oauth2:
      type: oauth2
      description: OAuth2 Authorization Grant
      flows:
        authorizationCode:
          authorizationUrl: >-
            https://accounts.fax.plus/login?response_type=code&client_id=YOUR_CLIENT_ID&redirect_uri=http://localhost&scope=all
          tokenUrl: https://accounts.fax.plus/token
          refreshUrl: >-
            https://accounts.fax.plus/token?grant_type=refresh_token&refresh_token=YOUR_REFRESH_TOKEN
          scopes:
            all: >-
              for now when a user grants permission, all grants will be
              permitted
    personal_access_token:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Personal Access Token (PAT) is a Bearer token used for secure API calls.
        For direct API calls, the PAT is used in the Authorization header as
        'Bearer {PAT}'. For MCP usage, configure your PAT in your MCP client
        settings (e.g., in your IDE's MCP server configuration) - authentication
        will be handled automatically.

````