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

# Get account and plan state

> The authenticated whoami/entitlement read: the account email and plan/trial state for the calling token. Requires a live bearer token but NOT a Pro subscription; a free account gets 200 with its plan state and the upgrade URL. Never returns token material.



## OpenAPI

````yaml /api-reference/openapi-mintlify.json get /api/v1/account
openapi: 3.0.3
info:
  title: Finterm API
  version: 1.0.0
  description: >-
    The Finterm financial-data API. Every response is the two-key envelope:
    `finterm` (the meta header) and `data` (the published result contract), or
    `finterm` + `error` on failure.


    ## Error registry


    | Code | HTTP | Description | Message |

    | --- | --- | --- | --- |

    | `INVALID_REQUEST` | 400 | The request body failed schema validation, or
    the tool rejected the parameters as invalid or incomplete. | The request
    parameters are invalid or incomplete. |

    | `INVALID_JSON` | 400 | The request body was not valid JSON. | The request
    body was not valid JSON. |

    | `TOKEN_INVALID` | 401 | The bearer token is missing, expired, or not
    recognized. | The API key is missing, expired, or not recognized. |

    | `SUBSCRIPTION_REQUIRED` | 402 | An active Finterm Pro subscription is
    required. The envelope carries the machine-readable error.upgrade_url; after
    checkout there, retrying succeeds automatically. | An active Finterm Pro
    subscription is required. |

    | `RATE_LIMITED` | 429 | The caller has exceeded the request rate limit;
    retry later. | Too many requests; retry later. |

    | `RUNTIME_UNAVAILABLE` | 503 | The tool runtime is not available for this
    deployment. | The service is temporarily unavailable; retry later. |

    | `RUNTIME_QUEUE_FULL` | 429 | The tool runtime queue is full; retry later.
    | The service is busy; retry later. |

    | `RUNTIME_TOOL_UNAVAILABLE` | 501 | The tool is routed but not yet
    runnable. | This tool is not yet available. |

    | `RUNTIME_RUN_FAILED` | 502 | The tool runtime reported the run as a
    non-success terminal state. | The run did not complete successfully. |

    | `RUNTIME_CONTRACT_MISMATCH` | 502 | The tool runtime returned a result
    that did not match the published contract. | The service returned an
    unexpected result shape. |

    | `TOOL_EXECUTION_FAILED` | 502 | The tool executed but reported an upstream
    failure. | The tool ran but could not complete the request. |

    | `UPSTREAM_AUTH` | 502 | A data source rejected the service’s own
    credentials. A service-side configuration fault, not a caller authentication
    problem. | A data source could not be accessed due to a service
    configuration issue. |

    | `UPSTREAM_QUOTA` | 503 | A data source is over its service-side usage
    limit; retry later. | A data source is temporarily over capacity; retry
    later. |

    | `UPSTREAM_UNAVAILABLE` | 502 | A data source failed, timed out, or
    returned an unusable response; retry later. | A data source is temporarily
    unavailable; retry later. |

    | `BUNDLE_NOT_FOUND` | 404 | No bundle exists with the requested name. | No
    bundle exists with the requested name. |

    | `RUN_NOT_FOUND` | 404 | No run exists with the requested id for this
    caller. | No run exists with the requested id. |

    | `MANIFEST_NOT_READY` | 409 | The run has not completed, so the sync
    manifest is not yet available. | The run has not completed yet. |
servers:
  - url: https://api.finterm.ai
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Point Tools
    description: Single-purpose data tools (one request, one synchronous result).
  - name: Bundle Tools
    description: Composed multi-section tools served via the run lifecycle.
  - name: Account
    description: The authenticated account/entitlement read (works without Pro).
  - name: Feedback
    description: Submit bugs, questions, and feature requests (works without Pro).
paths:
  /api/v1/account:
    get:
      tags:
        - Account
      summary: Get account and plan state
      description: >-
        The authenticated whoami/entitlement read: the account email and
        plan/trial state for the calling token. Requires a live bearer token but
        NOT a Pro subscription; a free account gets 200 with its plan state and
        the upgrade URL. Never returns token material.
      operationId: getAccount
      responses:
        '200':
          description: The account envelope.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AccountEnvelope'
        '401':
          description: Error (TOKEN_MISSING, TOKEN_INVALID).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
components:
  schemas:
    AccountEnvelope:
      type: object
      description: The two-key success envelope carrying the account state.
      properties:
        finterm:
          $ref: '#/components/schemas/FintermMeta'
        data:
          $ref: '#/components/schemas/Account'
      required:
        - finterm
        - data
    ErrorEnvelope:
      type: object
      description: The two-key error envelope.
      properties:
        finterm:
          $ref: '#/components/schemas/FintermMeta'
        error:
          type: object
          properties:
            code:
              type: string
              description: Stable public error code.
            message:
              type: string
              description: Human-readable, external-clean message.
            upgrade_url:
              type: string
              description: >-
                Machine-readable upgrade URL, present only on
                SUBSCRIPTION_REQUIRED (402): complete checkout there, then
                retry; access activates automatically.
          required:
            - code
            - message
      required:
        - finterm
        - error
    FintermMeta:
      type: object
      description: Canonical result meta header.
      properties:
        schema:
          type: string
          description: The published result contract id.
        tool:
          type: string
          description: The snake_case tool id.
        args:
          type: object
          additionalProperties: true
          description: The arguments the caller requested.
        request_id:
          type: string
          description: Server-set, ephemeral request id.
        cursor:
          type: string
          description: Opaque pagination cursor (feed tools only).
      required:
        - schema
        - tool
        - args
    Account:
      type: object
      description: The calling account and its plan/entitlement state.
      properties:
        email:
          type: string
          description: The account email.
          nullable: true
        plan:
          type: string
          enum:
            - pro
            - free
          description: The resolved plan level.
        has_pro:
          type: boolean
          description: Whether the account is entitled to the paid API surface.
        subscription_status:
          type: string
          description: >-
            The raw subscription status (active | trialing | past_due | canceled
            | incomplete | unpaid), or null with no subscription.
          nullable: true
        trial_ends_at:
          type: number
          description: Epoch ms the trial ends, when the subscription is trialing.
          nullable: true
        current_period_end:
          type: number
          description: Epoch ms the current paid period ends, or null when not subscribed.
          nullable: true
        cancel_at_period_end:
          type: boolean
          description: Whether the subscription is set to cancel at period end.
        upgrade_url:
          type: string
          description: >-
            The upgrade/conversion URL, present only when the account is not
            entitled.
      required:
        - email
        - plan
        - has_pro
        - subscription_status
        - trial_ends_at
        - current_period_end
        - cancel_at_period_end
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: A live account API key from `FINTERM_API_KEY`.

````