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

> ## Agent Instructions
> Use the public API base URL: https://api.teamfollowup.ai/api.
> Authenticate public API requests with Authorization: Bearer YOUR_API_KEY.
> Use product-owned terms: agents, campaigns, projects (GoHighLevel sub-accounts), contacts, calls, outcomes, skills, cadences, phone numbers.
> Scope requests by locationId rather than projectName.
> Read the guide linked from each API reference group before recommending an endpoint.

# List sub-account wallets

> Every connected sub-account with its wallet balance and debt, rebilling rate, auto-recharge, Credit Guard, and payments waiting for credit. Disconnected sub-accounts are not listed.

Allowed customer roles: `agency_admin`. The agency is the one the credential belongs to; no parameter selects another.

Required API key scope: `billing:read`.



## OpenAPI

````yaml /openapi.yaml get /api/billing/sub-accounts
openapi: 3.1.0
info:
  title: TFUAI Server API
  version: 1.0.0
  description: >-
    API reference for the TFUAI SaaS server.


    All published endpoints are mounted under `/api`. Responses use a standard
    envelope: `{ "success": true, ... }` on success and `{ "success": false,
    "error": "..." }` on failure.


    Product API modules are being launched module by module. This spec currently
    exposes only contracted public modules.


    Authenticate public API requests with an API key in the `Authorization`
    header: `Authorization: Bearer YOUR_API_KEY`.
servers:
  - url: https://api.teamfollowup.ai
    description: Production API origin. Public API paths are under /api.
security: []
tags:
  - name: Agents
    description: Manage voice agents, campaigns, workflows, and outcomes.
  - name: Analytics
    description: >-
      Minimal, non-billing performance summary: volume, conversion, and pickup
      metrics.
  - name: Billing
    description: >-
      Billing for your own agency: balance, spend, transaction history, invoices
      and sub-account wallets; auto-recharge, rebilling, Credit Guard and Stripe
      customers; and, with the billing:charge scope, purchases and charges.
  - name: Calls
    description: Review calls, test runs, and execution history.
  - name: Campaign Workflows
    description: >-
      What runs after a call lands: for each outcome (booked, opted out, asked
      for a callback…), an ordered chain of actions — tag the contact, move a
      pipeline stage, send an SMS, book an appointment. Stored as a graph:
      `nodes` are the actions, `edges` say what follows what, and
      `dispositionEntries` maps each outcome to the node its chain starts at.


      **Pick the narrowest endpoint that does the job.**


      | To | Call | |

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

      | See what fires per outcome | `GET .../workflow/digest` | Reads as plain
      text, no graph walking |

      | Add steps to an outcome | `POST .../outcomes/{outcome}/nodes` | Server
      derives node ids, edge ids, handles, layout |

      | Change a message, tag or setting | `PATCH .../workflow` | Merges;
      carries no graph, so it cannot damage one |

      | Remove one step | `DELETE .../nodes/{nodeId}` | Also re-links the chain
      around it |

      | Author or replace the whole graph | `PUT .../workflow` | Replaces
      everything you send |


      `PUT` is the only one that can re-wire, position nodes, build an `if`,
      save an unconfigured draft, or copy a whole workflow — and the only one
      that can overwrite a change someone else made after you read it. Use it
      when you are genuinely authoring the graph, and send `expectedVersion`
      when you do. For everything else the narrower endpoints are both easier
      and safer.
  - name: Contacts
    description: Contact list, filters, contact call history, and do-not-call actions.
  - name: GHL
    description: CRM variables and contact helpers used by agent and campaign setup flows.
  - name: Phone Numbers
    description: >-
      Caller ID pool, number search, assignment, movement, and release
      endpoints.
  - name: Power Dialer
    description: >-
      Power Dialer queue, lead cadence, callback, parked lead, and campaign
      schedule endpoints.
  - name: Projects
    description: >-
      Project management endpoints: list, update, disconnect, configure project
      campaigns, and validate setup.
  - name: Skills and Tools
    description: Manage reusable agent behaviors and in-call tool descriptions.
  - name: Split Testing
    description: >-
      Split live campaign traffic across agent variants and shift the weights
      between them.
  - name: Voices
    description: Voice catalogue endpoints for choosing the voice used by an agent.
paths:
  /api/billing/sub-accounts:
    get:
      tags:
        - Billing
      summary: List sub-account wallets
      description: >-
        Every connected sub-account with its wallet balance and debt, rebilling
        rate, auto-recharge, Credit Guard, and payments waiting for credit.
        Disconnected sub-accounts are not listed.


        Allowed customer roles: `agency_admin`. The agency is the one the
        credential belongs to; no parameter selects another.


        Required API key scope: `billing:read`.
      operationId: get-billing-sub-accounts
      parameters: []
      responses:
        '200':
          description: Sub-account wallets, by name.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingSubAccountsResponse'
              examples:
                default:
                  value:
                    success: true
                    data:
                      - locationId: rrHDPw5RIR5ULeUlfSAR
                        name: Bright Dental
                        isLive: true
                        rebilling:
                          enabled: true
                          clientRatePerMinute: 0.45
                        wallet:
                          balanceMinutes: 64.5
                          balanceUSD: 29.03
                          debtMinutes: 0
                          status: LOW_BALANCE
                          visibility: ENABLED
                        autoRecharge:
                          enabled: true
                          thresholdUSD: 25
                          rechargeAmountUSD: 100
                          blockedReason: null
                          requiresAction: false
                          recommendedAction: null
                          lastSuccessfulRechargeAt: '2026-09-10T09:30:00.000Z'
                          lastFailureAt: null
                        creditGuard:
                          enabled: false
                        pendingCredits:
                          count: 0
                          minutes: 0
                          amountUSD: 0
                      - locationId: q8LmVt2ZzYQ4pWnKdRb1
                        name: Harbour Roofing
                        isLive: true
                        rebilling:
                          enabled: false
                          clientRatePerMinute: null
                        wallet:
                          balanceMinutes: 0
                          balanceUSD: 0
                          debtMinutes: 0
                          status: DEPLETED
                          visibility: ENABLED
                        autoRecharge:
                          enabled: false
                          thresholdUSD: null
                          rechargeAmountUSD: null
                          blockedReason: null
                          requiresAction: false
                          recommendedAction: null
                          lastSuccessfulRechargeAt: null
                          lastFailureAt: null
                        creditGuard:
                          enabled: true
                        pendingCredits:
                          count: 0
                          minutes: 0
                          amountUSD: 0
        '400':
          description: >-
            A query parameter is malformed, unknown, or the window cannot be
            formed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingErrorResponse'
              examples:
                default:
                  value:
                    success: false
                    error: BadRequest
                    message: 'query: Unrecognized key: "status"'
        '401':
          description: Missing or invalid authentication.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingErrorResponse'
              examples:
                default:
                  value:
                    success: false
                    error: Unauthorized
        '403':
          description: >-
            The credential lacks `billing:read` (`InsufficientScope`), or it is
            not an agency admin's (`Forbidden`).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingErrorResponse'
              examples:
                default:
                  value:
                    success: false
                    error: InsufficientScope
                    message: This API key does not have the required scope.
                    requiredScope: billing:read
        '429':
          description: Rate limit exceeded.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingErrorResponse'
              examples:
                default:
                  value:
                    success: false
                    error: TooManyRequests
        '500':
          description: Unexpected server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingErrorResponse'
              examples:
                default:
                  value:
                    success: false
                    error: InternalError
                    message: Could not load billing usage.
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: bash
          label: cURL
          source: |-
            curl --request GET \
              --url https://api.teamfollowup.ai/api/billing/sub-accounts \
              --header 'Authorization: Bearer YOUR_API_KEY'
components:
  schemas:
    BillingSubAccountsResponse:
      type: object
      additionalProperties: false
      required:
        - success
        - data
      properties:
        success:
          type: boolean
          example: true
        data:
          type: array
          items:
            $ref: '#/components/schemas/BillingSubAccount'
    BillingErrorResponse:
      type: object
      additionalProperties: false
      required:
        - success
        - error
      properties:
        success:
          type: boolean
          example: false
        error:
          type: string
          description: Machine-readable code.
        message:
          type: string
          description: For a person.
        requiredScope:
          type: string
          description: On `InsufficientScope`, the scope the credential was missing.
    BillingSubAccount:
      type: object
      additionalProperties: false
      required:
        - locationId
        - name
        - isLive
        - rebilling
        - wallet
        - autoRecharge
        - creditGuard
        - pendingCredits
      properties:
        locationId:
          type: string
          description: The sub-account's GoHighLevel Location ID.
        name:
          type:
            - string
            - 'null'
          description: Display name. A label only; it can change.
        isLive:
          type:
            - boolean
            - 'null'
          description: >-
            `false` when the sub-account is paused. `null` when its status is
            unknown.
        rebilling:
          type: object
          additionalProperties: false
          required:
            - enabled
            - clientRatePerMinute
          properties:
            enabled:
              type: boolean
              description: >-
                Whether this sub-account pays for its own calls from its own
                wallet.
            clientRatePerMinute:
              type:
                - number
                - 'null'
              description: >-
                What you charge this sub-account per minute. `null` when
                rebilling is off.
        wallet:
          type: object
          additionalProperties: false
          required:
            - balanceMinutes
            - balanceUSD
            - debtMinutes
            - status
            - visibility
          properties:
            balanceMinutes:
              type: number
              description: Minutes left, bonus minutes included, expired batches excluded.
            balanceUSD:
              type: number
              description: Value of the paid minutes left.
            debtMinutes:
              type: number
              description: Minutes owed.
            status:
              type: string
              enum:
                - ACTIVE
                - LOW_BALANCE
                - IN_DEBT
                - DEPLETED
              description: >-
                `ACTIVE` above the low mark, `LOW_BALANCE` at or under it,
                `IN_DEBT` empty and owing, `DEPLETED` empty.
            visibility:
              type: string
              enum:
                - ENABLED
                - DISABLED
              description: Whether the sub-account can see its wallet.
        autoRecharge:
          type: object
          additionalProperties: false
          required:
            - enabled
            - thresholdUSD
            - rechargeAmountUSD
            - blockedReason
            - requiresAction
            - recommendedAction
            - lastSuccessfulRechargeAt
            - lastFailureAt
          properties:
            enabled:
              type: boolean
              description: Whether the sub-account tops itself up.
            thresholdUSD:
              type:
                - number
                - 'null'
              description: >-
                Top up when the wallet's dollar balance falls below this. `null`
                when not set.
            rechargeAmountUSD:
              type:
                - number
                - 'null'
              description: How much each top-up charges, in dollars. `null` when not set.
            blockedReason:
              type:
                - string
                - 'null'
              description: >-
                Why an enabled auto-recharge cannot charge, for example
                `NO_CUSTOMER`.
            requiresAction:
              type: boolean
              description: Whether someone has to act before it can charge again.
            recommendedAction:
              type:
                - string
                - 'null'
              description: What to do, for example `UPDATE_PAYMENT_METHOD`.
            lastSuccessfulRechargeAt:
              type:
                - string
                - 'null'
              format: date-time
              description: The last top-up that charged.
            lastFailureAt:
              type:
                - string
                - 'null'
              format: date-time
              description: The last top-up that failed.
        creditGuard:
          type: object
          additionalProperties: false
          required:
            - enabled
          properties:
            enabled:
              type: boolean
              description: >-
                Whether this sub-account stops its own calls when its wallet is
                empty.
        pendingCredits:
          $ref: '#/components/schemas/BillingPendingCreditRollup'
    BillingPendingCreditRollup:
      type: object
      additionalProperties: false
      required:
        - count
        - minutes
        - amountUSD
      properties:
        count:
          type: integer
          minimum: 0
          description: Payments waiting for credit.
        minutes:
          type: number
          description: Minutes they will add.
        amountUSD:
          type: number
          description: What was paid.
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer
      bearerFormat: API key
      description: 'Send your API key as `Authorization: Bearer YOUR_API_KEY`.'

````