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

> ## Agent Instructions
> Base URL: https://api.checkfu.com. Current wire version: `2026-08-31` (`Checkfu-Version: 2026-08-31`).
> Mutating HTTP requests require `Authorization: Bearer $CHECKFU_API_KEY`, `Checkfu-Version: 2026-08-31`, `Content-Type: application/json`, and `Idempotency-Key` on retriable writes. Ordinary API keys are Workspace-bound; do not send a Workspace selector header.
> Core workflow: create an Agent (`POST /v1/agents`) and Environment (`POST /v1/environments`), grant `use_environment` (`POST /v1/permission-assignments`), create a Session (`POST /v1/sessions`), send events (`POST /v1/sessions/{id}/events`), stream progress (`GET /v1/sessions/{id}/events/stream`), and read the input result (`GET /v1/sessions/{id}/inputs/{input_id}/result`).
> Domain model: an Agent is mutable configuration; a Session freezes its AgentVersion and Environment at creation and owns its private workspace and ordered event history. Vault stores secret credentials; Connection links an external account; ActionApproval records human approval before an action runs.
> Capability status combines `audience`, `stability`, `availability`, evaluated prerequisites, and release evidence; check https://docs.checkfu.com/getting-started/status (`GET /v1/support/capabilities`) for live `available` status.

# List prepaid usage charges

> Returns a page of the Workspace's prepaid usage charges, oldest first or newest first with order=desc: one per Cloudflare usage fact (a gateway model…



## OpenAPI

````yaml /openapi.json get /v1/billing/charges
openapi: 3.1.0
info:
  title: Checkfu API
  version: '2026-08-31'
  description: >-
    Authentication is declared per operation: API-key, runtime, or connector
    bearer; Automation signature; or credential-free pairing redemption. Every
    general Checkfu REST request requires the dated `Checkfu-Version` header
    (one of: 2026-08-31); the three MCP JSON-RPC transports use
    `MCP-Protocol-Version`, and the provider OAuth callback carries neither
    Checkfu header. API keys resolve one Workspace without a request selector;
    authenticated responses identify it with `Checkfu-Workspace-Id`.
servers:
  - url: https://api.checkfu.com
security:
  - bearerAuth: []
tags:
  - name: organizations
  - name: sourceRepositories
  - name: tenants
  - name: workspaces
  - name: principals
  - name: principalGroups
  - name: principalAccessCredentials
  - name: apiKeys
  - name: agents
  - name: harnessRuntime
  - name: permissionAssignments
  - name: actionPolicies
  - name: organizationActionPolicies
  - name: files
  - name: memoryStores
  - name: modelCredentials
  - name: modelRoutingProfiles
  - name: toolSources
  - name: skills
  - name: skillSources
  - name: skillProposals
  - name: instructionProposals
  - name: catalog
  - name: concepts
  - name: support
  - name: connections
  - name: connectionAssignments
  - name: connectedRuntimes
  - name: fileTrees
  - name: collaboration
  - name: automations
  - name: actionApprovals
  - name: standingApprovals
  - name: workloadReviewPolicies
  - name: usage
  - name: models
  - name: budgets
  - name: billing
  - name: sessions
  - name: audit
  - name: sessionExports
  - name: runs
  - name: runnerPools
  - name: transcripts
  - name: sessionWatches
  - name: sessionCapsules
  - name: sessionTrajectories
  - name: webhookEndpoints
  - name: integrationGateway
  - name: environments
  - name: vaults
  - name: apiMcp
  - name: agentPlacementMessages
paths:
  /v1/billing/charges:
    get:
      tags:
        - billing
      summary: List prepaid usage charges
      description: >-
        Returns a page of the Workspace's prepaid usage charges, oldest first or
        newest first with `order=desc`: one per Cloudflare usage fact (a gateway
        model call, a container boot, or a retained storage day), each with its
        lines at list price, the markup, the platform rate and the exact amount
        in pico-USD. Pass `session_id` for one Session's charges. A charge
        appears once its usage settles; usage still held is in the billing
        status's reserved figure.


        Checkfu support posture: preview; rollout_fenced. Required evidence
        journey: platform-supply-billing. Deployment-specific readiness and the
        latest proven release are available from GET /v1/support/capabilities.
      operationId: billing.listPrepaidCharges
      parameters:
        - name: checkfu-version
          in: header
          schema:
            type: string
            enum:
              - '2026-08-31'
          required: true
        - name: limit
          in: query
          schema:
            type: integer
            minimum: 1
          required: false
        - name: page
          in: query
          schema:
            type: string
            pattern: ^c1_[0-9a-z]+$
          required: false
        - name: session_id
          in: query
          schema:
            $ref: '#/components/schemas/SessionId'
          required: false
        - name: order
          in: query
          schema:
            type: string
            enum:
              - asc
              - desc
          required: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      anyOf:
                        - $ref: '#/components/schemas/PrepaidUsageChargeAgreement'
                        - $ref: '#/components/schemas/PrepaidUsageChargeAgreement_1'
                        - $ref: '#/components/schemas/PrepaidUsageChargeAgreement_2'
                  next_page:
                    anyOf:
                      - type: string
                      - type: 'null'
                required:
                  - data
                  - next_page
                additionalProperties: false
          headers:
            checkfu-workspace-id:
              description: The Workspace resolved from the authenticated bearer credential.
              required: true
              schema:
                $ref: '#/components/schemas/WorkspaceId'
        '400':
          description: Typed Checkfu wire error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationMalformedError'
        '401':
          description: Typed Checkfu wire error
          content:
            application/json:
              schema:
                type: object
                properties:
                  type:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - authentication_error
                      code:
                        type: string
                        enum:
                          - auth.invalid_key
                      message:
                        type: string
                      more:
                        type: string
                        enum:
                          - >-
                            https://docs.checkfu.com/reference/errors#auth-invalid-key
                        description: >-
                          Stable public documentation and remedy for this error
                          type.
                    required:
                      - type
                      - code
                      - message
                      - more
                    additionalProperties: false
                  request_id:
                    type: string
                    minLength: 1
                required:
                  - type
                  - error
                  - request_id
                additionalProperties: false
        '403':
          description: >-
            The organization, tenant, or workspace backing this key is
            administratively disabled. | Deployment governance or retention
            policy denied the request.
          content:
            application/json:
              schema:
                anyOf:
                  - type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - error
                      error:
                        type: object
                        properties:
                          type:
                            type: string
                            enum:
                              - permission_error
                          code:
                            type: string
                            enum:
                              - auth.disabled_tenancy
                          message:
                            type: string
                          more:
                            type: string
                            enum:
                              - >-
                                https://docs.checkfu.com/reference/errors#auth-disabled-tenancy
                            description: >-
                              Stable public documentation and remedy for this
                              error type.
                        required:
                          - type
                          - code
                          - message
                          - more
                        additionalProperties: false
                      request_id:
                        type: string
                        minLength: 1
                    required:
                      - type
                      - error
                      - request_id
                    additionalProperties: false
                  - $ref: '#/components/schemas/PolicyDeniedError'
        '429':
          description: Typed Checkfu wire error
          headers:
            retry-after:
              description: >-
                Delay in seconds for rate limits or deployment quotas with a
                known release or UTC reset boundary
              required: false
              schema:
                type: integer
                minimum: 1
          content:
            application/json:
              schema:
                type: object
                properties:
                  type:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - rate_limit_error
                      code:
                        type: string
                        enum:
                          - budget.exceeded
                      message:
                        type: string
                      more:
                        type: string
                        enum:
                          - >-
                            https://docs.checkfu.com/reference/errors#budget-exceeded
                        description: >-
                          Stable public documentation and remedy for this error
                          type.
                    required:
                      - type
                      - code
                      - message
                      - more
                    additionalProperties: false
                  request_id:
                    type: string
                    minLength: 1
                required:
                  - type
                  - error
                  - request_id
                additionalProperties: false
        '500':
          description: >-
            An unexpected internal failure occurred; the message contains an
            opaque incident reference.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RuntimeInternalError'
      security:
        - bearerAuth: []
components:
  schemas:
    SessionId:
      type: string
      pattern: ^sess_[0-9a-f]{32}$
    PrepaidUsageChargeAgreement:
      type: object
      properties:
        charge_type:
          type: string
          enum:
            - gateway_model_call
        id:
          $ref: '#/components/schemas/BillingChargeId'
        organization_id:
          $ref: '#/components/schemas/OrganizationId'
        workspace_id:
          $ref: '#/components/schemas/WorkspaceId'
        session_id:
          $ref: '#/components/schemas/Union_353'
        run_id:
          $ref: '#/components/schemas/Union_354'
        currency:
          type: string
          enum:
            - usd
        tariff:
          $ref: '#/components/schemas/Objects_162'
        admitted_at:
          $ref: '#/components/schemas/CanonicalInstant'
        lines:
          $ref: '#/components/schemas/Arrays_36'
        base_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        markup_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        platform_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        amount_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        remainder_numerator:
          $ref: '#/components/schemas/DecimalInteger'
        remainder_denominator:
          $ref: '#/components/schemas/DecimalInteger'
        recorded_at:
          $ref: '#/components/schemas/CanonicalInstant'
        usage_fact:
          type: object
          properties:
            kind:
              type: string
              enum:
                - ai_gateway_request
            gateway_id:
              type: string
              minLength: 1
              maxLength: 255
            operation_id:
              type: string
              minLength: 1
              maxLength: 255
          required:
            - kind
            - gateway_id
            - operation_id
          additionalProperties: false
        payer:
          type: string
          enum:
            - managed
            - byok
        provider:
          type: string
          minLength: 1
          maxLength: 255
        model:
          type: string
          minLength: 1
          maxLength: 255
        tokens:
          type: object
          properties:
            input:
              type: integer
              minimum: 0
              maximum: 9007199254740991
            output:
              type: integer
              minimum: 0
              maximum: 9007199254740991
            cache_read:
              type: integer
              minimum: 0
              maximum: 9007199254740991
            cache_write_5m:
              type: integer
              minimum: 0
              maximum: 9007199254740991
            cache_write_1h:
              type: integer
              minimum: 0
              maximum: 9007199254740991
          required:
            - input
            - output
            - cache_read
            - cache_write_5m
            - cache_write_1h
          additionalProperties: false
      required:
        - charge_type
        - id
        - organization_id
        - workspace_id
        - session_id
        - run_id
        - currency
        - tariff
        - admitted_at
        - lines
        - base_picousd
        - markup_picousd
        - platform_picousd
        - amount_picousd
        - remainder_numerator
        - remainder_denominator
        - recorded_at
        - usage_fact
        - payer
        - provider
        - model
        - tokens
      additionalProperties: false
    PrepaidUsageChargeAgreement_1:
      type: object
      properties:
        charge_type:
          type: string
          enum:
            - container_usage
        id:
          $ref: '#/components/schemas/BillingChargeId'
        organization_id:
          $ref: '#/components/schemas/OrganizationId'
        workspace_id:
          $ref: '#/components/schemas/WorkspaceId'
        session_id:
          $ref: '#/components/schemas/Union_353'
        run_id:
          $ref: '#/components/schemas/Union_354'
        currency:
          type: string
          enum:
            - usd
        tariff:
          $ref: '#/components/schemas/Objects_162'
        admitted_at:
          $ref: '#/components/schemas/CanonicalInstant'
        lines:
          $ref: '#/components/schemas/Arrays_36'
        base_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        markup_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        platform_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        amount_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        remainder_numerator:
          $ref: '#/components/schemas/DecimalInteger'
        remainder_denominator:
          $ref: '#/components/schemas/DecimalInteger'
        recorded_at:
          $ref: '#/components/schemas/CanonicalInstant'
        usage_fact:
          type: object
          properties:
            kind:
              type: string
              enum:
                - container_boot
            allocation_digest:
              type: string
              minLength: 1
              maxLength: 255
            boot_number:
              type: integer
              maximum: 9007199254740991
              exclusiveMinimum: 0
          required:
            - kind
            - allocation_digest
            - boot_number
          additionalProperties: false
        instance_ids:
          type: array
          prefixItems:
            - type: string
              minLength: 1
              maxLength: 255
          minItems: 1
          items:
            type: string
            minLength: 1
            maxLength: 255
        period_started_at:
          $ref: '#/components/schemas/CanonicalInstant'
        period_ended_at:
          $ref: '#/components/schemas/CanonicalInstant'
        usage:
          type: object
          properties:
            cpu_time_sec:
              $ref: '#/components/schemas/DecimalQuantity'
            allocated_memory_byte_seconds:
              $ref: '#/components/schemas/DecimalInteger'
            allocated_disk_byte_seconds:
              $ref: '#/components/schemas/DecimalInteger'
            tx_bytes:
              $ref: '#/components/schemas/DecimalInteger'
            egress_region:
              type: string
              enum:
                - north_america_europe
                - oceania_korea_taiwan
                - rest_of_world
            instance_seconds:
              $ref: '#/components/schemas/DecimalQuantity'
          required:
            - cpu_time_sec
            - allocated_memory_byte_seconds
            - allocated_disk_byte_seconds
            - tx_bytes
            - egress_region
          additionalProperties: false
      required:
        - charge_type
        - id
        - organization_id
        - workspace_id
        - session_id
        - run_id
        - currency
        - tariff
        - admitted_at
        - lines
        - base_picousd
        - markup_picousd
        - platform_picousd
        - amount_picousd
        - remainder_numerator
        - remainder_denominator
        - recorded_at
        - usage_fact
        - instance_ids
        - period_started_at
        - period_ended_at
        - usage
      additionalProperties: false
    PrepaidUsageChargeAgreement_2:
      type: object
      properties:
        charge_type:
          type: string
          enum:
            - retained_storage
        id:
          $ref: '#/components/schemas/BillingChargeId'
        organization_id:
          $ref: '#/components/schemas/OrganizationId'
        workspace_id:
          $ref: '#/components/schemas/WorkspaceId'
        session_id:
          $ref: '#/components/schemas/Union_353'
        run_id:
          $ref: '#/components/schemas/Union_354'
        currency:
          type: string
          enum:
            - usd
        tariff:
          $ref: '#/components/schemas/Objects_162'
        admitted_at:
          $ref: '#/components/schemas/CanonicalInstant'
        lines:
          $ref: '#/components/schemas/Arrays_36'
        base_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        markup_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        platform_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        amount_picousd:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        remainder_numerator:
          $ref: '#/components/schemas/DecimalInteger'
        remainder_denominator:
          $ref: '#/components/schemas/DecimalInteger'
        recorded_at:
          $ref: '#/components/schemas/CanonicalInstant'
        usage_fact:
          type: object
          properties:
            kind:
              type: string
              enum:
                - r2_storage_day
            bucket:
              type: string
              minLength: 1
              maxLength: 255
            prefix:
              type: string
              minLength: 1
              maxLength: 255
            usage_date:
              $ref: '#/components/schemas/UsageDate'
          required:
            - kind
            - bucket
            - prefix
            - usage_date
          additionalProperties: false
        peak_bytes:
          $ref: '#/components/schemas/DecimalInteger'
      required:
        - charge_type
        - id
        - organization_id
        - workspace_id
        - session_id
        - run_id
        - currency
        - tariff
        - admitted_at
        - lines
        - base_picousd
        - markup_picousd
        - platform_picousd
        - amount_picousd
        - remainder_numerator
        - remainder_denominator
        - recorded_at
        - usage_fact
        - peak_bytes
      additionalProperties: false
    WorkspaceId:
      type: string
      pattern: ^wrkspc_[0-9a-f]{32}$
    ValidationMalformedError:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              enum:
                - invalid_request_error
            message:
              type: string
            more:
              type: string
              enum:
                - https://docs.checkfu.com/reference/errors#validation-malformed
              description: Stable public documentation and remedy for this error type.
            code:
              type: string
              enum:
                - validation.malformed
          required:
            - type
            - message
            - more
            - code
          additionalProperties: false
        type:
          type: string
          enum:
            - error
        request_id:
          type: string
          minLength: 1
      required:
        - error
        - type
        - request_id
      additionalProperties: false
      description: >-
        The request could not be decoded or violated a declared input
        constraint.
    PolicyDeniedError:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              enum:
                - permission_error
            message:
              type: string
            more:
              type: string
              enum:
                - https://docs.checkfu.com/reference/errors#policy-denied
              description: Stable public documentation and remedy for this error type.
            code:
              type: string
              enum:
                - policy.denied
          required:
            - type
            - message
            - more
            - code
          additionalProperties: false
        type:
          type: string
          enum:
            - error
        request_id:
          type: string
          minLength: 1
      required:
        - error
        - type
        - request_id
      additionalProperties: false
      description: Deployment governance or retention policy denied the request.
    RuntimeInternalError:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              enum:
                - api_error
            message:
              type: string
            more:
              type: string
              enum:
                - https://docs.checkfu.com/reference/errors#runtime-internal
              description: Stable public documentation and remedy for this error type.
            code:
              type: string
              enum:
                - runtime.internal
          required:
            - type
            - message
            - more
            - code
          additionalProperties: false
        type:
          type: string
          enum:
            - error
        request_id:
          type: string
          minLength: 1
      required:
        - error
        - type
        - request_id
      additionalProperties: false
      description: >-
        An unexpected internal failure occurred; the message contains an opaque
        incident reference.
    BillingChargeId:
      type: string
      pattern: ^chg_[0-9a-f]{32}$
    OrganizationId:
      type: string
      pattern: ^org_[0-9a-f]{32}$
    Union_353:
      anyOf:
        - $ref: '#/components/schemas/SessionId'
        - type: 'null'
    Union_354:
      anyOf:
        - $ref: '#/components/schemas/RunId'
        - type: 'null'
    Objects_162:
      type: object
      properties:
        tariff_id:
          type: string
          enum:
            - checkfu-prepaid
        tariff_version:
          type: integer
          maximum: 9007199254740991
          exclusiveMinimum: 0
        markup_basis_points:
          type: integer
          minimum: 0
          maximum: 100000
      required:
        - tariff_id
        - tariff_version
        - markup_basis_points
      additionalProperties: false
    CanonicalInstant:
      type: string
      maxLength: 24
      allOf:
        - pattern: ^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$
          x-checkfu-current-timestamp: true
          description: A canonical UTC ISO-8601 instant with millisecond precision.
    Arrays_36:
      type: array
      items:
        type: object
        properties:
          dimension:
            type: string
            enum:
              - tokens.input
              - tokens.output
              - tokens.cache_read
              - tokens.cache_write_5m
              - tokens.cache_write_1h
              - container.active_vcpu_seconds
              - container.memory_byte_seconds
              - container.disk_byte_seconds
              - container.egress_bytes.north_america_europe
              - container.egress_bytes.oceania_korea_taiwan
              - container.egress_bytes.rest_of_world
              - storage.r2_standard_peak_byte_days
              - platform.container_instance_seconds
          quantity:
            $ref: '#/components/schemas/DecimalQuantity'
          rate:
            type: object
            properties:
              picousd:
                type: integer
                minimum: 0
                maximum: 9007199254740991
              per_units:
                type: integer
                maximum: 9007199254740991
                exclusiveMinimum: 0
            required:
              - picousd
              - per_units
            additionalProperties: false
          base_picousd:
            type: integer
            minimum: 0
            maximum: 9007199254740991
        required:
          - dimension
          - quantity
          - rate
          - base_picousd
        additionalProperties: false
    DecimalInteger:
      type: string
    DecimalQuantity:
      type: string
    UsageDate:
      type: string
    RunId:
      type: string
      pattern: ^run_[0-9a-f]{32}$
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.