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

# Billing status

> Subscription state, licensed seats, plan, and AI credit balance for one referred business.

<Note>`available_seats` counts only **partner-provided** Plus seats — `0` even if the business pays for Plus themselves. Call before [Add seats](/api-reference/partners/add-referred-business-seats) or [Add credits](/api-reference/partners/add-referred-business-credits).</Note>


## OpenAPI

````yaml /openapi/adam-v1.json get /referred-businesses/{business_uuid}/billing-status
openapi: 3.0.3
info:
  title: Tyms Developer API
  version: 1.0.0
  description: >-
    REST API for Tyms — the AI-Native Accounting Platform for small and
    medium-sized businesses across service, consulting, retail, and
    manufacturing. Paths are appended to the server URL.


    **Business key** (`tyms_sk_...`): all routes except partner distributor
    routes and OAuth authorization steps that document their own auth. **Partner
    key** (`adam_partner_sk_...` or equivalent): `POST /register-business`, `GET
    /referred-businesses`, billing status, and seat/credit grants on referred
    businesses. **OAuth**: integration apps use `tyms_pk_...` / `tyms_sk_...`
    plus user Bearer tokens — see the OAuth guide.


    Financial reports match what you see in the Tyms app. AI create endpoints
    accept optional attachment objects (`name`, `file`, `type`) — see the
    Attachments page in this docs site.
servers:
  - url: https://api.usetyms.com/v1/adam
    description: Production
  - url: https://staging-api.usetyms.com/v1/adam
    description: Sandbox (pre-production). Request credentials at developer@usetyms.com.
security:
  - apiKey: []
tags:
  - name: Partners
    description: >-
      Referral partner (distributor) flows — partner API key only. Register
      businesses, list referrals, read billing, and grant Plus seats or AI
      credits from partner holding.
  - name: Authentication
    description: Validate a business Developer API key.
  - name: OAuth
    description: >-
      Third-party integration authorization — connect Tyms users to your app
      without sharing their business secret keys.
  - name: Chart of accounts
    description: COA and bank-linked accounts.
  - name: Invoices
    description: Invoice CRUD and payments.
  - name: Bills
    description: Bill CRUD and payments.
  - name: Expenses
    description: Expense CRUD.
  - name: Income
    description: Income record CRUD.
  - name: Journals
    description: Journal entry CRUD.
  - name: Contacts
    description: Contact CRUD.
  - name: Banks
    description: Bank accounts.
  - name: Bank transactions
    description: Statement lines and AI-assisted upload.
  - name: Reports
    description: Financial statements (aligned with in-app reports).
paths:
  /referred-businesses/{business_uuid}/billing-status:
    get:
      tags:
        - Partners
      summary: Billing status
      description: >-
        Subscription state, licensed seats, plan, and AI credit balance for one
        referred business.
      operationId: getReferredBusinessBillingStatus
      parameters:
        - name: business_uuid
          in: path
          required: true
          schema:
            type: string
          description: UUID from register-business or your referred-businesses list.
      responses:
        '200':
          description: Billing snapshot
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AdamSuccessResponse'
              example:
                status: success
                message: Billing status retrieved successfully.
                data:
                  business_uuid: a1b2c3d4e5f6
                  name: Smith Enterprises
                  billing_currency: USD
                  subscription_status: active
                  available_seats: 3
                  subscription_plan: plus
                  credit_balance: 1250.5
                  subscription_expires_at: '2026-08-09T02:00:00.000000Z'
                  credit_from_referral_partner: false
                  gateway: referral_partner
        '401':
          description: Invalid partner key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Partner inactive or business not referred by you
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Business not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    AdamSuccessResponse:
      type: object
      required:
        - status
        - message
      properties:
        status:
          type: string
          example: success
        message:
          type: string
        data:
          description: >-
            Single resource, array of resources, statement sections, or async
            job metadata — see each operation's example.
        meta:
          type: object
          additionalProperties: true
          description: >-
            Pagination (`page`, `limit`, `total`) and/or report range (`from`,
            `to`). Cash flow may include `previous_period_end`.
    ErrorResponse:
      type: object
      properties:
        status:
          type: string
          example: failed
        message:
          type: string
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Business secret `tyms_sk_...` for business-scoped routes. Partner secret
        for register-business and referred-business distributor routes.
      x-default: your_tyms_sk_or_partner_key

````