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

# Create an agent rate card

> Make a new card. An `llm` row states as much as it wants to constrain — provider, model, both, or neither — and the most specific matching row prices a call. `fallback_per_usd` prices anything the card does not name, off the USD price registry. `denomination` and `currency` are fixed at creation.



## OpenAPI

````yaml post /v1/ai/billing/rate-cards
openapi: 3.1.0
info:
  title: Hyperline API
  version: 0.0.0
servers:
  - url: https://api.hyperline.co
  - url: https://sandbox.api.hyperline.co
security: []
paths:
  /v1/ai/billing/rate-cards:
    post:
      tags:
        - AI > Billing
      summary: Create an agent rate card
      description: >-
        Make a new card. An `llm` row states as much as it wants to constrain —
        provider, model, both, or neither — and the most specific matching row
        prices a call. `fallback_per_usd` prices anything the card does not
        name, off the USD price registry. `denomination` and `currency` are
        fixed at creation.
      operationId: createAgentRateCard
      requestBody:
        description: Create rate card payload
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  minLength: 1
                  maxLength: 120
                  description: Human-readable resource name.
                  example: Support agent plan
                fallback_per_usd:
                  type:
                    - string
                    - 'null'
                  maxLength: 40
                  pattern: ^\d+(\.\d+)?$
                  description: >-
                    Credits, allowance units, or major currency units per USD of
                    provider cost. Null leaves unmatched usage unpriced.
                  example: '1'
                rows:
                  type: array
                  items:
                    type: object
                    properties:
                      kind:
                        type: string
                        enum:
                          - llm
                          - item
                        description: |-
                          Pricing row kind.

                          - llm: Prices token usage by provider and model.
                          - item: Prices non-LLM usage by vendor and item.
                        example: llm
                      provider:
                        type:
                          - string
                          - 'null'
                        minLength: 1
                        maxLength: 64
                        description: >-
                          AI model provider, or the vendor of a custom cost
                          item. This is not an integration connection.
                        example: anthropic
                      model:
                        type:
                          - string
                          - 'null'
                        minLength: 1
                        maxLength: 128
                        description: >-
                          Model identifier, or custom item identifier. Null on
                          wildcard pricing rows.
                        example: claude-sonnet-5
                      rate_per_m_input:
                        type:
                          - string
                          - 'null'
                        maxLength: 40
                        pattern: ^\d+(\.\d+)?$
                        description: >-
                          Price per million input tokens, in credits, allowance
                          units, or major currency units according to the card
                          denomination.
                        example: '3'
                      rate_per_m_output:
                        type:
                          - string
                          - 'null'
                        maxLength: 40
                        pattern: ^\d+(\.\d+)?$
                        description: >-
                          Price per million output tokens, in the card
                          denomination; currency cards use major currency units.
                        example: '15'
                      rate_unit:
                        type:
                          - string
                          - 'null'
                        maxLength: 40
                        pattern: ^\d+(\.\d+)?$
                        description: >-
                          Price per item unit, in the card denomination;
                          currency cards use major currency units.
                        example: '0.01'
                      rate_per_m_cached_input:
                        type:
                          - string
                          - 'null'
                        maxLength: 40
                        pattern: ^\d+(\.\d+)?$
                        description: >-
                          Price per million cached input tokens. Null falls back
                          to the card conversion for this dimension.
                        example: '0.3'
                      rate_per_m_cache_write:
                        type:
                          - string
                          - 'null'
                        maxLength: 40
                        pattern: ^\d+(\.\d+)?$
                        description: >-
                          Price per million cache-write tokens. Null falls back
                          to the card conversion for this dimension.
                        example: '3.75'
                      dimensions:
                        type:
                          - array
                          - 'null'
                        items:
                          type: object
                          properties:
                            key:
                              type: string
                              pattern: ^[a-z0-9_.]{1,64}$
                              description: >-
                                Dimension or allowance identifier used by usage
                                payloads and meter results.
                              example: cached_input_tokens
                            rate:
                              type: string
                              maxLength: 40
                              pattern: ^\d+(\.\d+)?$
                              description: >-
                                Applied rate. Receipt lines may contain a
                                human-readable rate expression.
                              example: '3'
                            per:
                              type: string
                              enum:
                                - 1m
                                - 1k
                                - unit
                              description: |-
                                Quantity basis for the dimension rate.

                                - 1m: Per million units.
                                - 1k: Per thousand units.
                                - unit: Per single unit.
                              example: 1m
                          required:
                            - key
                            - rate
                            - per
                        maxItems: 20
                        description: >-
                          Additional billable dimensions; each key matches a
                          usage_extra key and rates use the owning card's units
                          or USD for cost-catalog dimensions.
                        example:
                          - key: cached_input_tokens
                            rate: '0.3'
                            per: 1m
                    required:
                      - kind
                  maxItems: 1000
                  description: >-
                    All pricing rows on the card; replacement replaces the
                    complete list.
                  example: []
                denomination:
                  type: string
                  enum:
                    - credits
                    - units
                    - currency
                  description: |-
                    Unit in which rate-card prices are expressed.

                    - credits: Credit counts.
                    - units: Weighted rolling-allowance units.
                    - currency: Major units of the specified currency.
                  example: currency
                currency:
                  type:
                    - string
                    - 'null'
                  enum:
                    - EUR
                    - AED
                    - AFN
                    - XCD
                    - ALL
                    - AMD
                    - AOA
                    - ARS
                    - USD
                    - AUD
                    - AWG
                    - AZN
                    - BAM
                    - BBD
                    - BDT
                    - BGN
                    - BHD
                    - BIF
                    - XOF
                    - BMD
                    - BND
                    - BOB
                    - BRL
                    - BSD
                    - BTN
                    - NOK
                    - BWP
                    - BYR
                    - BZD
                    - CAD
                    - CDF
                    - XAF
                    - CHF
                    - NZD
                    - CLP
                    - CNY
                    - COP
                    - CRC
                    - CUP
                    - CVE
                    - ANG
                    - CZK
                    - DJF
                    - DKK
                    - DOP
                    - DZD
                    - EGP
                    - MAD
                    - ERN
                    - ETB
                    - FJD
                    - FKP
                    - GBP
                    - GEL
                    - GHS
                    - GIP
                    - GMD
                    - GNF
                    - GTQ
                    - GYD
                    - HKD
                    - HNL
                    - HRK
                    - HTG
                    - HUF
                    - IDR
                    - ILS
                    - INR
                    - IQD
                    - IRR
                    - ISK
                    - JMD
                    - JOD
                    - JPY
                    - KES
                    - KGS
                    - KHR
                    - KMF
                    - KPW
                    - KRW
                    - KWD
                    - KYD
                    - KZT
                    - LAK
                    - LBP
                    - LKR
                    - LRD
                    - LSL
                    - LYD
                    - MDL
                    - MGA
                    - MKD
                    - MMK
                    - MNT
                    - MOP
                    - MRO
                    - MUR
                    - MVR
                    - MWK
                    - MXN
                    - MYR
                    - MZN
                    - NAD
                    - XPF
                    - NGN
                    - NIO
                    - NPR
                    - OMR
                    - PAB
                    - PEN
                    - PGK
                    - PHP
                    - PKR
                    - PLN
                    - PYG
                    - QAR
                    - RON
                    - RSD
                    - RUB
                    - RWF
                    - SAR
                    - SBD
                    - SCR
                    - SDG
                    - SEK
                    - SGD
                    - SHP
                    - SLL
                    - SOS
                    - SRD
                    - SSP
                    - STD
                    - SYP
                    - SZL
                    - THB
                    - TJS
                    - TMT
                    - TND
                    - TOP
                    - TRY
                    - TTD
                    - TWD
                    - TZS
                    - UAH
                    - UGX
                    - UYU
                    - UZS
                    - VEF
                    - VND
                    - VUV
                    - WST
                    - YER
                    - ZAR
                    - ZMW
                    - ZWL
                  description: >-
                    ISO 4217 currency code for monetary values. Null for counts
                    or historical amounts without recorded currency.
                  example: USD
              required:
                - name
                - rows
                - denomination
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: Unique Hyperline identifier for this resource.
                    example: d18603dd-7285-4bf5-a45e-88d7de8f37c9
                  name:
                    type: string
                    description: Human-readable resource name.
                    example: Support agent plan
                  denomination:
                    type: string
                    enum:
                      - credits
                      - units
                      - currency
                    description: |-
                      Unit in which rate-card prices are expressed.

                      - credits: Credit counts.
                      - units: Weighted rolling-allowance units.
                      - currency: Major units of the specified currency.
                    example: currency
                  currency:
                    type:
                      - string
                      - 'null'
                    enum:
                      - EUR
                      - AED
                      - AFN
                      - XCD
                      - ALL
                      - AMD
                      - AOA
                      - ARS
                      - USD
                      - AUD
                      - AWG
                      - AZN
                      - BAM
                      - BBD
                      - BDT
                      - BGN
                      - BHD
                      - BIF
                      - XOF
                      - BMD
                      - BND
                      - BOB
                      - BRL
                      - BSD
                      - BTN
                      - NOK
                      - BWP
                      - BYR
                      - BZD
                      - CAD
                      - CDF
                      - XAF
                      - CHF
                      - NZD
                      - CLP
                      - CNY
                      - COP
                      - CRC
                      - CUP
                      - CVE
                      - ANG
                      - CZK
                      - DJF
                      - DKK
                      - DOP
                      - DZD
                      - EGP
                      - MAD
                      - ERN
                      - ETB
                      - FJD
                      - FKP
                      - GBP
                      - GEL
                      - GHS
                      - GIP
                      - GMD
                      - GNF
                      - GTQ
                      - GYD
                      - HKD
                      - HNL
                      - HRK
                      - HTG
                      - HUF
                      - IDR
                      - ILS
                      - INR
                      - IQD
                      - IRR
                      - ISK
                      - JMD
                      - JOD
                      - JPY
                      - KES
                      - KGS
                      - KHR
                      - KMF
                      - KPW
                      - KRW
                      - KWD
                      - KYD
                      - KZT
                      - LAK
                      - LBP
                      - LKR
                      - LRD
                      - LSL
                      - LYD
                      - MDL
                      - MGA
                      - MKD
                      - MMK
                      - MNT
                      - MOP
                      - MRO
                      - MUR
                      - MVR
                      - MWK
                      - MXN
                      - MYR
                      - MZN
                      - NAD
                      - XPF
                      - NGN
                      - NIO
                      - NPR
                      - OMR
                      - PAB
                      - PEN
                      - PGK
                      - PHP
                      - PKR
                      - PLN
                      - PYG
                      - QAR
                      - RON
                      - RSD
                      - RUB
                      - RWF
                      - SAR
                      - SBD
                      - SCR
                      - SDG
                      - SEK
                      - SGD
                      - SHP
                      - SLL
                      - SOS
                      - SRD
                      - SSP
                      - STD
                      - SYP
                      - SZL
                      - THB
                      - TJS
                      - TMT
                      - TND
                      - TOP
                      - TRY
                      - TTD
                      - TWD
                      - TZS
                      - UAH
                      - UGX
                      - UYU
                      - UZS
                      - VEF
                      - VND
                      - VUV
                      - WST
                      - YER
                      - ZAR
                      - ZMW
                      - ZWL
                    description: >-
                      ISO 4217 currency code for monetary values. Null for
                      counts or historical amounts without recorded currency.
                    example: USD
                  fallback_per_usd:
                    type:
                      - string
                      - 'null'
                    pattern: ^-?\d+(\.\d+)?(e[+-]?\d+)?$/i
                    description: >-
                      Credits, allowance units, or major currency units per USD
                      of provider cost. Null leaves unmatched usage unpriced.
                    example: '1'
                  rows:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          description: Unique Hyperline identifier for this resource.
                          example: d18603dd-7285-4bf5-a45e-88d7de8f37c9
                        kind:
                          type: string
                          enum:
                            - llm
                            - item
                          description: |-
                            Pricing row kind.

                            - llm: Prices token usage by provider and model.
                            - item: Prices non-LLM usage by vendor and item.
                          example: llm
                        provider:
                          type:
                            - string
                            - 'null'
                          description: >-
                            AI model provider, or the vendor of a custom cost
                            item. This is not an integration connection.
                          example: anthropic
                        model:
                          type:
                            - string
                            - 'null'
                          description: >-
                            Model identifier, or custom item identifier. Null on
                            wildcard pricing rows.
                          example: claude-sonnet-5
                        rate_per_m_input:
                          type:
                            - string
                            - 'null'
                          pattern: ^-?\d+(\.\d+)?(e[+-]?\d+)?$/i
                          description: >-
                            Price per million input tokens, in credits,
                            allowance units, or major currency units according
                            to the card denomination.
                          example: '3'
                        rate_per_m_output:
                          type:
                            - string
                            - 'null'
                          pattern: ^-?\d+(\.\d+)?(e[+-]?\d+)?$/i
                          description: >-
                            Price per million output tokens, in the card
                            denomination; currency cards use major currency
                            units.
                          example: '15'
                        rate_unit:
                          type:
                            - string
                            - 'null'
                          pattern: ^-?\d+(\.\d+)?(e[+-]?\d+)?$/i
                          description: >-
                            Price per item unit, in the card denomination;
                            currency cards use major currency units.
                          example: '0.01'
                        rate_per_m_cached_input:
                          type:
                            - string
                            - 'null'
                          pattern: ^-?\d+(\.\d+)?(e[+-]?\d+)?$/i
                          description: >-
                            Price per million cached input tokens. Null falls
                            back to the card conversion for this dimension.
                          example: '0.3'
                        rate_per_m_cache_write:
                          type:
                            - string
                            - 'null'
                          pattern: ^-?\d+(\.\d+)?(e[+-]?\d+)?$/i
                          description: >-
                            Price per million cache-write tokens. Null falls
                            back to the card conversion for this dimension.
                          example: '3.75'
                        dimensions:
                          type: array
                          items:
                            type: object
                            properties:
                              key:
                                type: string
                                pattern: ^[a-z0-9_.]{1,64}$
                                description: >-
                                  Dimension or allowance identifier used by
                                  usage payloads and meter results.
                                example: cached_input_tokens
                              rate:
                                type: string
                                maxLength: 40
                                pattern: ^\d+(\.\d+)?$
                                description: >-
                                  Applied rate. Receipt lines may contain a
                                  human-readable rate expression.
                                example: '3'
                              per:
                                type: string
                                enum:
                                  - 1m
                                  - 1k
                                  - unit
                                description: |-
                                  Quantity basis for the dimension rate.

                                  - 1m: Per million units.
                                  - 1k: Per thousand units.
                                  - unit: Per single unit.
                                example: 1m
                            required:
                              - key
                              - rate
                              - per
                          description: >-
                            Additional billable dimensions; each key matches a
                            usage_extra key and rates use the owning card's
                            units or USD for cost-catalog dimensions.
                          example:
                            - key: cached_input_tokens
                              rate: '0.3'
                              per: 1m
                      required:
                        - id
                        - kind
                        - provider
                        - model
                        - rate_per_m_input
                        - rate_per_m_output
                        - rate_unit
                        - rate_per_m_cached_input
                        - rate_per_m_cache_write
                        - dimensions
                    description: >-
                      All pricing rows on the card; replacement replaces the
                      complete list.
                    example: []
                  attached_product_id:
                    type:
                      - string
                      - 'null'
                    description: Credit product using this card as its default, or null.
                    example: prd_credits
                  using_policy_count:
                    type: number
                    description: >-
                      Number of customer policy scopes referencing this
                      resource.
                    example: 1
                  using_policies:
                    type: array
                    items:
                      type: object
                      properties:
                        customer_id:
                          type: string
                          description: Hyperline customer identifier.
                          example: cus_example
                        customer_name:
                          type: string
                          description: Customer display name.
                          example: Acme
                        agent_slug:
                          type:
                            - string
                            - 'null'
                          description: >-
                            Agent scope identifier. Null is the customer's
                            shared pool.
                          example: support
                      required:
                        - customer_id
                        - customer_name
                        - agent_slug
                    description: >-
                      Bounded sample of customer scopes using this card;
                      using_policy_count is the complete count.
                    example:
                      - customer_id: cus_example
                        customer_name: Acme
                        agent_slug: support
                  using_plan_count:
                    type: number
                    description: Number of plans referencing this rate card.
                    example: 1
                required:
                  - id
                  - name
                  - denomination
                  - currency
                  - fallback_per_usd
                  - rows
                  - attached_product_id
                  - using_policy_count
                  - using_policies
                  - using_plan_count
        '400':
          description: Invalid request.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                required:
                  - message
        '409':
          description: The request conflicts with the current configuration.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                required:
                  - message
      security:
        - bearer: []
components:
  securitySchemes:
    bearer:
      type: http
      scheme: bearer
      bearerFormat: JWT

````

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