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

# PATCH /admin/api/price-tiers/{id}



## OpenAPI

````yaml /generated/openapi.json patch /admin/api/price-tiers/{id}
openapi: 3.1.0
info:
  description: >-
    Forwarding, management, portal and OAuth APIs generated from Rust types.
    Input and output schemas preserve their respective Serde contracts.
    Streaming events and WebSocket messages are documented alongside HTTP
    payloads.
  title: GPROXY HTTP API
  version: 4.2.1
servers: []
security:
  - bearer: []
  - anthropicKey: []
  - googleKey: []
  - queryKey: []
paths:
  /admin/api/price-tiers/{id}:
    patch:
      tags:
        - Management
      summary: PATCH /admin/api/price-tiers/{id}
      parameters:
        - in: path
          name: id
          required: true
          schema:
            type: string
        - description: Administrative scope selected by the caller.
          in: header
          name: x-gproxy-admin-scope
          required: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Input_PriceTierPatch'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Output_PriceTierDto'
          description: Success
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Output_Envelope'
          description: Gateway error
      security:
        - consoleSession: []
        - bearer: []
        - anthropicKey: []
        - googleKey: []
components:
  schemas:
    Input_PriceTierPatch:
      properties:
        audioInputPerMillion:
          default: null
          type:
            - string
            - 'null'
        audioOutputPerMillion:
          default: null
          type:
            - string
            - 'null'
        cacheCreationPerMillion:
          default: null
          items:
            $ref: '#/components/schemas/Input_CacheCreationPriceDto'
          type:
            - array
            - 'null'
        cacheReadPerMillion:
          default: null
          type:
            - string
            - 'null'
        cachedAudioInputPerMillion:
          default: null
          type:
            - string
            - 'null'
        imageInputPerMillion:
          default: null
          type:
            - string
            - 'null'
        imageOutputPerMillion:
          default: null
          type:
            - string
            - 'null'
        inputPerMillion:
          default: null
          type:
            - string
            - 'null'
        minPromptTokens:
          default: null
          format: int64
          type:
            - integer
            - 'null'
        multiplier:
          default: null
          type:
            - string
            - 'null'
        outputPerMillion:
          default: null
          type:
            - string
            - 'null'
        priority:
          default: null
          format: int32
          type:
            - integer
            - 'null'
        reasoningPerMillion:
          default: null
          type:
            - string
            - 'null'
        serviceTier:
          default: null
          type:
            - string
            - 'null'
        videoInputPerMillion:
          default: null
          type:
            - string
            - 'null'
        videoPerMillion:
          default: null
          type:
            - string
            - 'null'
      type: object
    Output_PriceTierDto:
      description: |-
        A context or service-tier override inside one rule. Every per-million
        price is optional: None inherits, zero is explicitly free.
      properties:
        audioInputPerMillion:
          type:
            - string
            - 'null'
        audioOutputPerMillion:
          type:
            - string
            - 'null'
        cacheCreationPerMillion:
          default: []
          items:
            $ref: '#/components/schemas/Output_CacheCreationPriceDto'
          type: array
        cacheReadPerMillion:
          type:
            - string
            - 'null'
        cachedAudioInputPerMillion:
          type:
            - string
            - 'null'
        id:
          type: string
        imageInputPerMillion:
          type:
            - string
            - 'null'
        imageOutputPerMillion:
          type:
            - string
            - 'null'
        inputPerMillion:
          type:
            - string
            - 'null'
        minPromptTokens:
          format: int64
          type: integer
        multiplier:
          type:
            - string
            - 'null'
        outputPerMillion:
          type:
            - string
            - 'null'
        priceRuleId:
          type: string
        priority:
          format: int32
          type: integer
        reasoningPerMillion:
          type:
            - string
            - 'null'
        serviceTier:
          description: >-
            None is a context tier; otherwise `standard`, `priority`, `flex`, …
            .
          type:
            - string
            - 'null'
        videoInputPerMillion:
          type:
            - string
            - 'null'
        videoPerMillion:
          type:
            - string
            - 'null'
      required:
        - id
        - priceRuleId
        - serviceTier
        - minPromptTokens
        - priority
        - multiplier
        - inputPerMillion
        - outputPerMillion
        - cacheReadPerMillion
        - cacheCreationPerMillion
        - reasoningPerMillion
        - imageInputPerMillion
        - imageOutputPerMillion
        - audioInputPerMillion
        - cachedAudioInputPerMillion
        - audioOutputPerMillion
        - videoInputPerMillion
        - videoPerMillion
      type: object
    Output_Envelope:
      properties:
        error:
          $ref: '#/components/schemas/Output_EnvelopeBody'
      required:
        - error
      type: object
    Input_CacheCreationPriceDto:
      description: A cache-write price per million tokens. No TTL is the fallback price.
      properties:
        price:
          type: string
        ttlSeconds:
          default: null
          format: uint64
          minimum: 0
          type:
            - integer
            - 'null'
      required:
        - price
      type: object
    Output_CacheCreationPriceDto:
      description: A cache-write price per million tokens. No TTL is the fallback price.
      properties:
        price:
          type: string
        ttlSeconds:
          default: null
          format: uint64
          minimum: 0
          type:
            - integer
            - 'null'
      required:
        - ttlSeconds
        - price
      type: object
    Output_EnvelopeBody:
      properties:
        code:
          type: string
        message:
          type: string
      required:
        - code
        - message
      type: object
  securitySchemes:
    bearer:
      scheme: bearer
      type: http
    anthropicKey:
      in: header
      name: x-api-key
      type: apiKey
    googleKey:
      in: header
      name: x-goog-api-key
      type: apiKey
    queryKey:
      in: query
      name: key
      type: apiKey
    consoleSession:
      in: cookie
      name: gproxy_session
      type: apiKey

````

## Related topics

- [POST /admin/api/price-tiers/batch](https://gproxy.leenhawk.com/api-reference/management/post-adminapiprice-tiersbatch.md)
- [DELETE /admin/api/price-tiers/{id}](https://gproxy.leenhawk.com/api-reference/management/delete-adminapiprice-tiers.md)
- [GET /admin/api/price-tiers/{id}](https://gproxy.leenhawk.com/api-reference/management/get-adminapiprice-tiers-1.md)
- [GET /admin/api/price-tiers](https://gproxy.leenhawk.com/api-reference/management/get-adminapiprice-tiers.md)
- [POST /admin/api/price-tiers](https://gproxy.leenhawk.com/api-reference/management/post-adminapiprice-tiers.md)


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