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

# Update Contract Usage Revenue

> Retrieve, update, and delete contract usage revenue records



## OpenAPI

````yaml https://api.meetcampfire.com/api/schema?format=json put /rr/api/v1/contracts/{contract_id}/usage/{id}
openapi: 3.0.3
info:
  title: Campfire Developer APIs
  version: 1.0.0
  description: >
    ## Introduction

    Campfire's developer APIs offer granular access to Campfire's core
    accounting,

    revenue recognition, and financial data features.


    These APIs are designed to be used by developers to build custom
    integrations,

    automate workflows, and perform any other programmatic operations.
servers:
  - url: https://api.meetcampfire.com
    description: Production server
security: []
tags:
  - name: Cash Management
    description: Operations related to accounts, transactions, and other bank-related data.
  - name: Core Accounting
    description: >-
      Operations related to core accounting data, such as the chart of accounts,
      entity management, and the general ledger.
  - name: Revenue Recognition
    description: >-
      Operations related to revenue recognition, contract management, and
      contract data aggregation.
  - name: Accounts Receivable
    description: Operations related to invoicing and the AR subledger
  - name: Accounts Payable
    description: Operations related to billing and the AP subledger.
  - name: Financial Statements
    description: Operations related to financial statement generation and data aggregation.
  - name: Settings
    description: Operations related to system and accounting settings configuration.
paths:
  /rr/api/v1/contracts/{contract_id}/usage/{id}:
    put:
      tags:
        - Revenue Recognition
      summary: Update Contract Usage Revenue
      description: Retrieve, update, and delete contract usage revenue records
      operationId: rr_api_v1_contracts_usage_update
      parameters:
        - in: path
          name: contract_id
          schema:
            type: integer
          required: true
        - in: path
          name: id
          schema:
            type: integer
          required: true
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ContractUsage'
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/ContractUsage'
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/ContractUsage'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContractUsage'
          description: ''
      security:
        - knoxApiToken: []
components:
  schemas:
    ContractUsage:
      type: object
      properties:
        id:
          type: integer
          readOnly: true
        contract:
          type: integer
        product:
          type: integer
          nullable: true
        product_bundle:
          type: string
          readOnly: true
        contract_product_bundle:
          allOf:
            - $ref: '#/components/schemas/ContractProductBundleRead'
          readOnly: true
        product_name:
          type: string
          readOnly: true
        product_bundle_name:
          type: string
          readOnly: true
        usage_group:
          type: integer
          nullable: true
        usage_group_name:
          type: string
          readOnly: true
        department:
          type: integer
          nullable: true
        tags:
          type: string
        description:
          type: string
          nullable: true
        start_date:
          type: string
          format: date
          nullable: true
        end_date:
          type: string
          format: date
          nullable: true
        lines:
          type: string
          readOnly: true
        created_at:
          type: string
          format: date-time
          readOnly: true
          nullable: true
        last_modified_at:
          type: string
          format: date-time
          readOnly: true
          nullable: true
      required:
        - contract
        - contract_product_bundle
        - created_at
        - id
        - last_modified_at
        - lines
        - product_bundle
        - product_bundle_name
        - product_name
        - usage_group_name
    ContractProductBundleRead:
      type: object
      description: Read-only serializer for ContractProductBundle in milestone responses.
      properties:
        id:
          type: integer
          readOnly: true
        source_bundle:
          type: integer
          nullable: true
          description: Original ProductBundle template this was created from
        source_bundle_name:
          type: string
          readOnly: true
          nullable: true
        total_amount:
          type: number
          format: double
          maximum: 1000000000000000000
          minimum: -1000000000000000000
          exclusiveMaximum: true
          exclusiveMinimum: true
          description: Total amount to be allocated across products
        currency:
          type: string
          maxLength: 3
        lines:
          type: array
          items:
            $ref: '#/components/schemas/ContractProductBundleLineRead'
          readOnly: true
      required:
        - id
        - lines
        - source_bundle_name
        - total_amount
    ContractProductBundleLineRead:
      type: object
      description: >-
        Read-only serializer for ContractProductBundleLine in milestone
        responses.
      properties:
        id:
          type: integer
          readOnly: true
        product:
          type: integer
        product_name:
          type: string
          readOnly: true
        amount:
          type: number
          format: double
          maximum: 1000000000000000000
          minimum: -1000000000000000000
          exclusiveMaximum: true
          exclusiveMinimum: true
          description: Dollar amount allocated to this product
        percentage:
          type: string
          readOnly: true
        original_percentage:
          type: number
          format: double
          maximum: 1000
          minimum: -1000
          exclusiveMaximum: true
          exclusiveMinimum: true
          nullable: true
          description: Original percentage from source ProductBundle for auditing
      required:
        - amount
        - id
        - percentage
        - product
        - product_name
  securitySchemes:
    knoxApiToken:
      type: apiKey
      in: header
      name: Authorization
      description: Token-based authentication with required prefix "Token"

````