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

# List contracts

> Retrieve a paginated list of contracts for your organization.

Returns contracts with comprehensive details including customer information, phases, products, and pricing. Supports filtering by customer, status, dates, and custom attributes. Results are sorted by creation date (newest first) by default.

Use cursor-based pagination to navigate through results. If no cursor is provided, returns the first page of results.



## OpenAPI

````yaml /openAPI/openapi-20240301.json get /contract_v2
openapi: 3.1.0
info:
  title: zenskar
  version: 2.0.0
servers:
  - url: https://api.zenskar.com
security:
  - ApiTokenAuth: []
    OrganisationAuth: []
paths:
  /contract_v2:
    get:
      tags:
        - Contracts
      summary: List contracts
      description: >-
        Retrieve a paginated list of contracts for your organization.


        Returns contracts with comprehensive details including customer
        information, phases, products, and pricing. Supports filtering by
        customer, status, dates, and custom attributes. Results are sorted by
        creation date (newest first) by default.


        Use cursor-based pagination to navigate through results. If no cursor is
        provided, returns the first page of results.
      operationId: List-contracts
      parameters:
        - name: cursor
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              The cursor indicating a unique set of results - this should be
              auto generated and you get it from the `next` and `previous`
              fields of the response
            examples:
              - V2VsbCBhcmV1IGN1cmlvdxM=
            title: Cursor
          description: >-
            The cursor indicating a unique set of results - this should be auto
            generated and you get it from the `next` and `previous` fields of
            the response
        - name: limit
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            description: The number of results to return - defaults to 10
            examples:
              - 10
            title: Limit
          description: The number of results to return - defaults to 10
        - name: order
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            examples:
              - order=created_at
            default: '-created_at'
            title: Order
        - name: id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Id
        - name: id__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Id  In
        - name: id__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Id  Isnull
        - name: customer_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Customer Id
        - name: customer_id__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Customer Id  In
        - name: customer_id__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Customer Id  Isnull
        - name: name
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Name
        - name: name__ilike
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Name  Ilike
        - name: name__like
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Name  Like
        - name: name__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Name  In
        - name: name__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Name  Isnull
        - name: start_date
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Start Date
        - name: start_date__neq
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Start Date  Neq
        - name: start_date__gt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Start Date  Gt
        - name: start_date__gte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Start Date  Gte
        - name: start_date__lt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Start Date  Lt
        - name: start_date__lte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Start Date  Lte
        - name: start_date__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Start Date  Isnull
        - name: start_date__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Start Date  In
        - name: created_at
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At
        - name: created_at__neq
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Neq
        - name: created_at__gt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Gt
        - name: created_at__gte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Gte
        - name: created_at__lt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Lt
        - name: created_at__lte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Lte
        - name: created_at__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Created At  Isnull
        - name: created_at__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Created At  In
        - name: end_date
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: End Date
        - name: end_date__neq
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: End Date  Neq
        - name: end_date__gt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: End Date  Gt
        - name: end_date__gte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: End Date  Gte
        - name: end_date__lt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: End Date  Lt
        - name: end_date__lte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: End Date  Lte
        - name: end_date__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: End Date  Isnull
        - name: end_date__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: End Date  In
        - name: status
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/ContractStatus'
              - type: 'null'
            title: Status
        - name: status__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Status  In
        - name: contract_type
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/ContractType'
              - type: 'null'
            title: Contract Type
        - name: contract_type__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Contract Type  In
        - name: contract_type__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Contract Type  Isnull
      responses:
        '200':
          description: Contracts retrieved successfully with pagination cursors
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedResults_ContractResponseSchema_'
        '400':
          description: Bad request - invalid filter parameters
          content:
            application/json:
              example:
                detail: Invalid date format in filter
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '500':
          description: Internal server error
          content:
            application/json:
              example:
                detail: An unexpected error occurred
components:
  schemas:
    ContractStatus:
      type: string
      enum:
        - draft
        - active
        - paused
        - expired
        - disputed
      title: ContractStatus
    ContractType:
      type: string
      enum:
        - standard
        - event_based
      title: ContractType
      description: >-
        Classifies how a contract is billed. STANDARD is the default;
        EVENT_BASED

        contracts are driven by usage events and require P1D cadence + postpaid.
    PaginatedResults_ContractResponseSchema_:
      properties:
        next:
          anyOf:
            - type: string
            - type: 'null'
          title: Next
          description: The cursor for the next page of results
          examples:
            - V2VsbCBhcmV1IGN1cmlvdxM=
        previous:
          anyOf:
            - type: string
            - type: 'null'
          title: Previous
          description: The cursor for the previous page of results
          examples:
            - GmBsbCBhcmV1IGN1cmlvdxM=
        total_count:
          anyOf:
            - type: integer
            - type: 'null'
          title: Total Count
          description: The total count of rows
        results:
          items:
            $ref: '#/components/schemas/ContractResponseSchema'
          type: array
          title: Results
          description: The results for the current page
      type: object
      required:
        - results
      title: PaginatedResults[ContractResponseSchema]
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ContractResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Unique identifier for this contract
        name:
          type: string
          title: Name
          description: >-
            Human-readable name for the contract. Used for identification and
            reporting purposes.
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: >-
            Detailed description of the contract terms, scope, or special
            conditions.
        tags:
          anyOf:
            - items: {}
              type: array
            - type: 'null'
          title: Tags
          description: >-
            List of tags for categorizing and filtering contracts. Useful for
            reporting and segmentation.
        status:
          $ref: '#/components/schemas/ContractStatus'
          description: >-
            Current status of the contract (e.g., active, draft, expired,
            terminated). System automatically updates to 'expired' when end_date
            is reached.
        currency:
          type: string
          title: Currency
          description: >-
            Three-letter ISO 4217 currency code for all monetary amounts in this
            contract (e.g., 'USD', 'EUR', 'GBP').
        start_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Start Date
          description: >-
            Date when the contract became or will become active. Billing and
            revenue recognition calculations start from this date.
        end_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: End Date
          description: >-
            Date when the contract expires. Null indicates an indefinite
            contract that continues until manually terminated.
        custom_attributes:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Custom Attributes
          description: >-
            Organization-specific metadata stored as key-value pairs. Can
            include fields like sales_rep, deal_id, region, or any custom data
            needed for reporting and integrations.
        source:
          additionalProperties: true
          type: object
          title: Source
          description: >-
            Metadata about the originating system or process that created this
            contract. Used for integration tracking and audit trails.
        created_at:
          type: string
          format: date-time
          title: Created At
          description: >-
            Timestamp when this contract was created in the system. Used for
            audit trails and reporting.
        updated_at:
          type: string
          format: date-time
          title: Updated At
          description: >-
            Timestamp of the last modification to this contract. Updates
            whenever any field or related entity changes.
        customer_id:
          type: string
          format: uuid
          title: Customer Id
          description: Unique identifier of the customer who is party to this contract.
        anchor_date:
          type: string
          format: date-time
          title: Anchor Date
          description: >-
            Reference date for billing cycle calculations. When set, billing
            cycles align to this date regardless of contract start date.
        is_last_day_of_month:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Last Day Of Month
          description: >-
            When true, billing cycles always end on the last day of the month,
            adjusting for varying month lengths.
        plan_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Plan Id
          description: >-
            Reference to the plan template used to create this contract, if
            applicable.
        renewal_policy:
          anyOf:
            - $ref: '#/components/schemas/RenewalPolicy'
            - type: 'null'
          description: >-
            Defines contract renewal behavior. Currently only 'do_not_renew' is
            supported—contracts must be manually renewed or replaced.
          default: do_not_renew
        phases:
          anyOf:
            - items:
                $ref: '#/components/schemas/ContractPhaseResponseSchema'
              type: array
            - type: 'null'
          title: Phases
          description: >-
            List of contract phases defining distinct periods with different
            terms, products, or pricing. Sorted chronologically by start date.
          default: []
        customer:
          $ref: '#/components/schemas/CustomerResponseSchema'
          description: >-
            Complete customer details including name, contact information, and
            billing preferences. The customer who is party to this contract.
        invoice_payer_customer:
          anyOf:
            - $ref: '#/components/schemas/CustomerResponseSchema'
            - type: 'null'
          description: >-
            Customer details for the invoice payer, if different from the
            contract customer. Used when one entity uses services but another
            pays for them.
        current_phase:
          anyOf:
            - $ref: '#/components/schemas/PhaseDetails'
            - type: 'null'
          description: >-
            The contract phase that is currently active based on today's date.
            Null if no phase is active or contract hasn't started.
        contract_link:
          anyOf:
            - type: string
            - type: 'null'
          title: Contract Link
          description: >-
            URL to external contract document, signed agreement, or related
            resource.
        bill_parent_customer:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Bill Parent Customer
          description: >-
            When true and customer has a parent relationship, invoices are sent
            to the parent customer instead.
          default: false
        invoice_payer_customer_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Invoice Payer Customer Id
          description: >-
            Customer ID who will receive and pay invoices for this contract, if
            different from the contract customer.
      type: object
      required:
        - id
        - name
        - status
        - currency
        - created_at
        - updated_at
        - customer_id
        - customer
      title: ContractResponseSchema
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    RenewalPolicy:
      type: string
      enum:
        - renew_with_default_contract
        - renew_with_existing
        - do_not_renew
      title: RenewalPolicy
      description: Enum for defining the renewal policy of a contract.
    ContractPhaseResponseSchema:
      properties:
        name:
          type: string
          title: Name
          description: >-
            Human-readable name for this phase. Used for identification in
            reports and UI.
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: >-
            Detailed description of what this phase represents, including any
            special terms or conditions.
        start_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Start Date
          description: >-
            Date when this phase begins. All billing and pricing in this phase
            start from this date.
        end_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: End Date
          description: >-
            Date when this phase ends. Null indicates this phase continues until
            contract end or next phase start.
        id:
          type: string
          format: uuid
          title: Id
          description: Unique identifier for this contract phase
        created_at:
          type: string
          format: date-time
          title: Created At
          description: Timestamp when this phase was created. Used for audit trails.
        updated_at:
          type: string
          format: date-time
          title: Updated At
          description: >-
            Timestamp of the last modification to this phase or its nested
            entities.
        contract_id:
          type: string
          format: uuid
          title: Contract Id
          description: Unique identifier of the parent contract this phase belongs to
        features:
          anyOf:
            - $ref: '#/components/schemas/ProductPricingResponseSchema'
            - type: 'null'
          description: >-
            Feature pricing configuration applied to all products in this phase,
            if applicable.
        pricings:
          anyOf:
            - items:
                $ref: '#/components/schemas/ContractPhasePricingResponseSchema'
              type: array
            - type: 'null'
          title: Pricings
          description: >-
            List of product-pricing associations active during this phase. Each
            defines a product, its pricing, and any phase-specific terms.
          default: []
        source_plan_phase_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Source Plan Phase Id
          description: >-
            Reference to the plan phase template used to create this phase, if
            applicable.
        phase_type:
          anyOf:
            - $ref: '#/components/schemas/PhaseType'
            - type: 'null'
          description: Type of phase indicating its purpose (e.g., active, trial, paused).
          default: active
        phase_metadata:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Phase Metadata
          description: >-
            Phase-specific metadata stored as key-value pairs. Can include
            campaign codes, discount reasons, or tracking data.
      type: object
      required:
        - name
        - id
        - created_at
        - updated_at
        - contract_id
      title: ContractPhaseResponseSchema
    CustomerResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Customer Id
        external_id:
          anyOf:
            - type: string
            - type: 'null'
          title: External Id
          description: External Customer Id
        customer_name:
          type: string
          title: Customer Name
          description: Customer name
        custom_data:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Custom Data
          description: Customer Custom Data
        address:
          anyOf:
            - $ref: '#/components/schemas/AddressResponse'
            - type: 'null'
          description: Customer Address
        ship_to_address:
          anyOf:
            - $ref: '#/components/schemas/AddressResponse'
            - type: 'null'
          description: Customer Ship To Address
        tax_info:
          anyOf:
            - items:
                $ref: '#/components/schemas/TaxId'
              type: array
            - type: 'null'
          title: Tax Info
          description: Customer Tax Ids
          default: []
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
          description: Customer primary email address
        custom_attributes:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Custom Attributes
          description: Customer Tags
        phone_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Phone Number
          description: Customer Phone Number
        communications_enabled:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Communications Enabled
          description: To enable/disable communications
          default: true
        auto_charge_enabled:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Auto Charge Enabled
          description: To enable/disable auto-charge
          default: true
        business_entity_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Business Entity Id
          description: Business Entity Id
      type: object
      required:
        - id
        - external_id
        - customer_name
        - custom_data
        - address
      title: CustomerResponseSchema
      description: Create Customer Response Schema
    PhaseDetails:
      properties:
        name:
          type: string
          title: Name
          description: Contract Phase name
        start_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Start Date
          description: Start Date
        end_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: End Date
          description: End Date
        id:
          type: string
          format: uuid
          title: Id
          description: Contract Phase ID
        phase_type:
          anyOf:
            - $ref: '#/components/schemas/PhaseType'
            - type: 'null'
          description: Phase Type
          default: active
        phase_metadata:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Phase Metadata
          description: Phase Metadata
      type: object
      required:
        - name
        - id
      title: PhaseDetails
    ProductPricingResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Pricing Model ID
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Pricing Model Name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Pricing Model Description
        pricing_data:
          oneOf:
            - $ref: '#/components/schemas/MatrixPricing'
            - $ref: '#/components/schemas/CustomTieredPricing'
            - $ref: '#/components/schemas/TwoDimensionalTieredPricing'
            - $ref: '#/components/schemas/PercentPricing'
            - $ref: '#/components/schemas/TieredPricing'
            - $ref: '#/components/schemas/TieredWithFlatFeePricing'
            - $ref: '#/components/schemas/VolumePricing'
            - $ref: '#/components/schemas/VolumeWithFlatFeePricing'
            - $ref: '#/components/schemas/StepPricing'
            - $ref: '#/components/schemas/PackagePricing'
            - $ref: '#/components/schemas/PerUnitPricing'
            - $ref: '#/components/schemas/FlatFee'
            - $ref: '#/components/schemas/FeaturesPricing'
            - $ref: '#/components/schemas/CustomPricing'
            - $ref: '#/components/schemas/BundlePricing'
          title: Pricing Data
          description: Pricing Data
          discriminator:
            propertyName: pricing_type
            mapping:
              bundle:
                $ref: '#/components/schemas/BundlePricing'
              custom_pricing:
                $ref: '#/components/schemas/CustomPricing'
              custom_tiered:
                $ref: '#/components/schemas/CustomTieredPricing'
              features:
                $ref: '#/components/schemas/FeaturesPricing'
              flat_fee:
                $ref: '#/components/schemas/FlatFee'
              matrix:
                $ref: '#/components/schemas/MatrixPricing'
              package:
                $ref: '#/components/schemas/PackagePricing'
              per_unit:
                $ref: '#/components/schemas/PerUnitPricing'
              percent:
                $ref: '#/components/schemas/PercentPricing'
              step:
                $ref: '#/components/schemas/StepPricing'
              tiered:
                $ref: '#/components/schemas/TieredPricing'
              tiered_with_flat_fee:
                $ref: '#/components/schemas/TieredWithFlatFeePricing'
              two_dimensional_tiered:
                $ref: '#/components/schemas/TwoDimensionalTieredPricing'
              volume:
                $ref: '#/components/schemas/VolumePricing'
              volume_with_flat_fee:
                $ref: '#/components/schemas/VolumeWithFlatFeePricing'
        quantity:
          anyOf:
            - $ref: '#/components/schemas/QuantityResponse'
            - type: 'null'
          description: Quantity
        grants:
          anyOf:
            - items:
                $ref: '#/components/schemas/GrantResponse'
              type: array
            - type: 'null'
          title: Grants
          description: Grants
          default: []
        consumptions:
          anyOf:
            - items:
                $ref: '#/components/schemas/ConsumptionResponse'
              type: array
            - type: 'null'
          title: Consumptions
          description: Consumptions
          default: []
        link_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Link Id
          description: Parent Link ID
        free_units:
          anyOf:
            - items:
                $ref: '#/components/schemas/FreeUnit'
              type: array
            - type: 'null'
          title: Free Units
          description: Free Units
          default: []
        discounts:
          anyOf:
            - items:
                $ref: '#/components/schemas/Discount'
              type: array
            - type: 'null'
          title: Discounts
          description: Discounts
          default: []
        commitments:
          anyOf:
            - items:
                $ref: '#/components/schemas/Commitment'
              type: array
            - type: 'null'
          title: Commitments
          description: Commitments
          default: []
        taxes:
          anyOf:
            - items:
                $ref: '#/components/schemas/Taxes'
              type: array
            - type: 'null'
          title: Taxes
          description: Taxes
          default: []
        payment_terms:
          anyOf:
            - items:
                $ref: '#/components/schemas/PaymentTerms'
              type: array
            - type: 'null'
          title: Payment Terms
          description: Payment Terms
          default: []
        service_fees:
          anyOf:
            - items:
                $ref: '#/components/schemas/ServiceFee'
              type: array
            - type: 'null'
          title: Service Fees
          description: Service Fees
          default: []
        execution_logic:
          anyOf:
            - $ref: '#/components/schemas/ExecutionLogic'
            - type: 'null'
          description: Execution Logic
        is_recurring:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Recurring
          description: Is Recurring or not
        billing_period:
          anyOf:
            - $ref: '#/components/schemas/Period'
            - type: 'null'
          description: Billing Cadence
        add_to_catalog:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Add To Catalog
          description: Part of product catalog or not
          default: true
        overage_pricing:
          anyOf:
            - $ref: '#/components/schemas/ProductPricingResponseSchema_Overagepricing'
            - type: 'null'
          description: Overage Pricing Configuration
        usage_report_configs:
          anyOf:
            - items:
                $ref: >-
                  #/components/schemas/ProductPricingUsageAssociationResponseSchema
              type: array
            - type: 'null'
          title: Usage Report Configs
          description: Usage Report Configurations associated with the pricing model
          default: []
      type: object
      required:
        - id
        - pricing_data
      title: ProductPricingResponseSchema
    ContractPhasePricingResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Contract Phase Pricing ID
        external_id:
          anyOf:
            - type: string
            - type: 'null'
          title: External Id
          description: External ID
        start_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Start Date
          description: Start Date
        end_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: End Date
          description: End Date
        anchor_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Anchor Date
          description: Anchor Date
        phase_id:
          type: string
          format: uuid
          title: Phase Id
          description: Contract Phase ID
        pricing_id:
          type: string
          format: uuid
          title: Pricing Id
          description: Pricing ID
        product_id:
          type: string
          format: uuid
          title: Product Id
          description: Product ID
        created_at:
          type: string
          format: date-time
          title: Created At
          description: Contract Phase Pricing created at
        updated_at:
          type: string
          format: date-time
          title: Updated At
          description: Contract Phase Pricing updated at
        product:
          $ref: '#/components/schemas/ProductResponseSchema'
          description: Product details
        pricing:
          $ref: '#/components/schemas/ProductBundlePricingResponseSchema'
          description: Pricing details (with overrides applied)
        custom_data:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Custom Data
          description: Pricing Association Metadata
        plan_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Plan Id
          description: Plan ID - reference to the plan_v3 this pricing is associated with
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: >-
            Line item description for this pricing association. Overrides
            pricing and product descriptions if provided.
        resolved_description:
          anyOf:
            - type: string
            - type: 'null'
          title: Resolved Description
          description: >-
            Effective description resolved from the fallback chain: description
            > pricing.description > product.description
        is_optional:
          type: boolean
          title: Is Optional
          description: >-
            When True, customers can enable/disable this line item in self-serve
            checkout
          default: false
        is_enabled:
          items:
            $ref: '#/components/schemas/EnabledEntry'
          type: array
          title: Is Enabled
          description: Schedule of enable/disable states for this line item over time
      type: object
      required:
        - id
        - phase_id
        - pricing_id
        - product_id
        - created_at
        - updated_at
        - product
        - pricing
      title: ContractPhasePricingResponseSchema
    PhaseType:
      type: string
      enum:
        - active
        - pause
        - trial
      title: PhaseType
    AddressResponse:
      properties:
        line1:
          anyOf:
            - type: string
            - type: 'null'
          title: Line1
          description: Street address line 1 (e.g., building number and street name)
        line2:
          anyOf:
            - type: string
            - type: 'null'
          title: Line2
          description: Street address line 2 (e.g., apartment, suite, unit number)
        line3:
          anyOf:
            - type: string
            - type: 'null'
          title: Line3
          description: Street address line 3 (additional address information)
        city:
          anyOf:
            - type: string
            - type: 'null'
          title: City
          description: City or locality name
        state:
          anyOf:
            - type: string
            - type: 'null'
          title: State
          description: State, province, or region
        zipCode:
          anyOf:
            - type: string
            - type: 'null'
          title: Zipcode
          description: Postal code or ZIP code
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: Country name (e.g., 'United States')
        country_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Country Code
          description: Two-letter ISO country code (e.g., 'US', 'GB')
        validation_status:
          anyOf:
            - type: string
            - type: 'null'
          title: Validation Status
          description: Address validation status
        connector_validation:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Connector Validation
          description: Validation data from external connector
      type: object
      title: AddressResponse
      description: Address Schema
    TaxId:
      properties:
        country_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Country Code
          description: Two-letter ISO country code for the tax ID (e.g., 'US', 'GB', 'IN')
        tax_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Tax Code
          description: Type of tax identifier (e.g., 'VAT', 'GST', 'EIN')
        tax_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Tax Id
          description: The actual tax identification number
      type: object
      title: TaxId
      description: Tax Id Schema
    MatrixPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        dimensions:
          items:
            $ref: '#/components/schemas/Dimension'
          type: array
          title: Dimensions
        prices:
          anyOf:
            - items:
                anyOf:
                  - type: number
                    minimum: 0
                  - type: 'null'
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Prices
        display_alias:
          items:
            type: string
          type: array
          title: Display Alias
        pricing_type:
          type: string
          const: matrix
          title: Pricing Type
      type: object
      required:
        - unit_amount
        - dimensions
        - prices
        - display_alias
        - pricing_type
      title: MatrixPricing
    CustomTieredPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Up To
        tier_type:
          items:
            type: string
            enum:
              - package
              - per_unit
          type: array
          title: Tier Type
        flat_fee:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Flat Fee
        package_sizes:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Package Sizes
        pricing_type:
          type: string
          const: custom_tiered
          title: Pricing Type
        model_type:
          type: string
          enum:
            - tiered
            - volume
          title: Model Type
      type: object
      required:
        - unit_amount
        - up_to
        - tier_type
        - flat_fee
        - package_sizes
        - pricing_type
        - model_type
      title: CustomTieredPricing
    TwoDimensionalTieredPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - items:
                items:
                  type: number
                  minimum: 0
                type: array
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Up To
        column_up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Column Up To
        pricing_type:
          type: string
          const: two_dimensional_tiered
          title: Pricing Type
      type: object
      required:
        - unit_amount
        - up_to
        - column_up_to
        - pricing_type
      title: TwoDimensionalTieredPricing
    PercentPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        pricing_type:
          type: string
          const: percent
          title: Pricing Type
        proration_type:
          anyOf:
            - $ref: '#/components/schemas/ProrationType'
            - type: 'null'
          description: Type of proration to be applied
          default: day_based
      type: object
      required:
        - unit_amount
        - pricing_type
      title: PercentPricing
    TieredPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Up To
        flat_fee:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Flat Fee
        pricing_type:
          type: string
          const: tiered
          title: Pricing Type
        cumulative_quantity:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Cumulative Quantity
      type: object
      required:
        - unit_amount
        - up_to
        - pricing_type
      title: TieredPricing
    TieredWithFlatFeePricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Up To
        flat_fee:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Flat Fee
        pricing_type:
          type: string
          const: tiered_with_flat_fee
          title: Pricing Type
      type: object
      required:
        - unit_amount
        - up_to
        - pricing_type
      title: TieredWithFlatFeePricing
    VolumePricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Up To
        flat_fee:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Flat Fee
        pricing_type:
          type: string
          const: volume
          title: Pricing Type
      type: object
      required:
        - unit_amount
        - up_to
        - pricing_type
      title: VolumePricing
    VolumeWithFlatFeePricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Up To
        flat_fee:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Flat Fee
        pricing_type:
          type: string
          const: volume_with_flat_fee
          title: Pricing Type
      type: object
      required:
        - unit_amount
        - up_to
        - pricing_type
      title: VolumeWithFlatFeePricing
    StepPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        up_to:
          anyOf:
            - items:
                type: number
                minimum: 0
              type: array
            - $ref: '#/components/schemas/EdgeInput'
          title: Up To
        pricing_type:
          type: string
          const: step
          title: Pricing Type
      type: object
      required:
        - unit_amount
        - up_to
        - pricing_type
      title: StepPricing
    PackagePricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        package_size:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Package Size
        pricing_type:
          type: string
          const: package
          title: Pricing Type
        quantity_is_package_count:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Quantity Is Package Count
          description: >-
            If true, the input quantity represents number of packages; if false
            (default), it represents base quantity that needs to be divided by
            package size
        proration_type:
          anyOf:
            - $ref: '#/components/schemas/ProrationType'
            - type: 'null'
          description: Type of proration to be applied
          default: day_based
      type: object
      required:
        - unit_amount
        - package_size
        - pricing_type
      title: PackagePricing
    PerUnitPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        charge_full_amount:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Charge Full Amount
          description: If true, the proration won't happen for non-metered products
          default: false
        proration_type:
          anyOf:
            - $ref: '#/components/schemas/ProrationType'
            - type: 'null'
          description: Type of proration to be applied
          default: day_based
        pricing_type:
          type: string
          const: per_unit
          title: Pricing Type
      type: object
      required:
        - unit_amount
        - pricing_type
      title: PerUnitPricing
    FlatFee:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        pricing_type:
          type: string
          const: flat_fee
          title: Pricing Type
        charge_full_amount:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Charge Full Amount
          description: Always charge full amount or not (proration is not allowed)
        proration_type:
          anyOf:
            - $ref: '#/components/schemas/ProrationType'
            - type: 'null'
          description: Type of proration to be applied
          default: day_based
      type: object
      required:
        - unit_amount
        - pricing_type
      title: FlatFee
    FeaturesPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Unit Amount
        pricing_type:
          type: string
          const: features
          title: Pricing Type
      type: object
      required:
        - pricing_type
      title: FeaturesPricing
    CustomPricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Unit Amount
        custom_pricing:
          additionalProperties: true
          type: object
          title: Custom Pricing
        pricing_type:
          type: string
          const: custom_pricing
          title: Pricing Type
        custom_py_script_location:
          type: string
          title: Custom Py Script Location
      type: object
      required:
        - custom_pricing
        - pricing_type
        - custom_py_script_location
      title: CustomPricing
    BundlePricing:
      properties:
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Unit Amount
        pricing_type:
          type: string
          const: bundle
          title: Pricing Type
      type: object
      required:
        - pricing_type
      title: BundlePricing
    QuantityResponse:
      properties:
        type:
          $ref: '#/components/schemas/QuantityType'
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
          description: Label
        quantity:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Quantity
          description: Quantity
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
          description: Unit
        aggregate_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Aggregate Id
          description: Aggregate ID
        quantity_entries:
          anyOf:
            - items:
                $ref: '#/components/schemas/QuantityEntry'
              type: array
            - type: 'null'
          title: Quantity Entries
        trigger_event:
          anyOf:
            - $ref: '#/components/schemas/GrantTriggerEvent'
            - type: 'null'
          description: ''
          default: invoice_approval
        expires_at:
          anyOf:
            - $ref: '#/components/schemas/GrantExpirationType'
            - type: 'null'
          description: Validity of the entitlement
          default: end_of_product_billing_period
        expiry_period:
          anyOf:
            - type: string
            - type: 'null'
          title: Expiry Period
          description: Custom validity of the entitlement
        grant_frequency_same_as_product:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Grant Frequency Same As Product
          description: Grant frequency same as product billing period
          default: true
        grant_frequency:
          anyOf:
            - type: string
            - type: 'null'
          title: Grant Frequency
          description: How often the product is granted
        feature_option_value:
          anyOf:
            - type: string
            - type: 'null'
          title: Feature Option Value
          description: Selected option from the option set for boolean entitlement
        numeric_value:
          anyOf:
            - type: number
            - type: 'null'
          title: Numeric Value
          description: Numeric value for boolean entitlement
        allow_mid_cycle_cancellation:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Allow Mid Cycle Cancellation
          description: Allow mid cycle cancellation
          default: false
        constraints:
          anyOf:
            - $ref: '#/components/schemas/QuantityConstraints'
            - type: 'null'
          description: 'Plan-level quantity constraints (None or {min: float, max: float})'
        aggregate:
          anyOf:
            - $ref: '#/components/schemas/GetAggregateResponseSchema'
            - type: 'null'
      type: object
      required:
        - type
      title: QuantityResponse
    GrantResponse:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        entitlement_id:
          type: string
          format: uuid
          title: Entitlement Id
        trigger_event:
          anyOf:
            - $ref: '#/components/schemas/GrantTriggerEvent'
            - type: 'null'
          description: ''
          default: invoice_approval
        type:
          $ref: '#/components/schemas/EntitlementType'
        expires_at:
          anyOf:
            - $ref: '#/components/schemas/GrantExpirationType'
            - type: 'null'
          default: end_of_product_billing_period
        expiry_period:
          anyOf:
            - type: string
            - type: 'null'
          title: Expiry Period
          description: ''
        grant_frequency_same_as_product:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Grant Frequency Same As Product
          description: Grant frequency same as product billing period
          default: true
        grant_period:
          anyOf:
            - type: string
            - type: 'null'
          title: Grant Period
          description: ''
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        start_date:
          anyOf:
            - type: string
              format: date-time
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Start Date
          description: Start date
        feature_option_value:
          anyOf:
            - type: string
            - type: 'null'
          title: Feature Option Value
          description: Selected option from the option set for feature type products
        numeric_value:
          anyOf:
            - type: number
            - type: 'null'
          title: Numeric Value
          description: Numeric value to store for feature type products
        entitlement:
          anyOf:
            - $ref: '#/components/schemas/EntitlementResponseSchema'
            - type: 'null'
      type: object
      required:
        - unit_amount
        - entitlement_id
        - type
      title: GrantResponse
    ConsumptionResponse:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        entitlement_id:
          type: string
          format: uuid
          title: Entitlement Id
        type:
          $ref: '#/components/schemas/EntitlementType'
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        show_additional_info:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Show Additional Info
          description: Show additional info or not
          default: false
        trigger_event:
          anyOf:
            - $ref: '#/components/schemas/ConsumptionTriggerEvent'
            - type: 'null'
          description: ''
          default: invoice_approval
        entitlement:
          anyOf:
            - $ref: '#/components/schemas/EntitlementResponseSchema'
            - type: 'null'
      type: object
      required:
        - entitlement_id
        - type
      title: ConsumptionResponse
    FreeUnit:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
        period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
      type: object
      required:
        - unit_amount
      title: FreeUnit
    Discount:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        type:
          $ref: '#/components/schemas/DiscountType'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
      type: object
      required:
        - type
        - unit_amount
      title: Discount
    Commitment:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        type:
          $ref: '#/components/schemas/CommitmentType'
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
          title: Unit Amount
        currency:
          anyOf:
            - type: string
            - type: 'null'
          title: Currency
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        charge_full_amount:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Charge Full Amount
          description: Charge full amount or not
          default: false
        skip_zero_amount:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Skip Zero Amount
          description: Skip when input to minimum commitment is zero
          default: false
      type: object
      required:
        - type
        - unit_amount
      title: Commitment
    Taxes:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        code:
          anyOf:
            - type: string
            - type: 'null'
          title: Code
        unit_amount:
          anyOf:
            - type: number
            - $ref: '#/components/schemas/EdgeInput'
            - type: 'null'
          title: Unit Amount
        type:
          $ref: '#/components/schemas/TaxType'
      type: object
      required:
        - type
      title: Taxes
    PaymentTerms:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
        payment_term_type:
          $ref: '#/components/schemas/PaymentTermType'
        due_days:
          type: integer
          exclusiveMinimum: 0
          title: Due Days
        payment_term_mode:
          anyOf:
            - $ref: '#/components/schemas/PaymentTermMode'
            - type: 'null'
          description: Payment Term Mode, relative or absolute
          default: relative
        last_day_of_month:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Last Day Of Month
          description: Last day of month or not
          default: false
      type: object
      required:
        - payment_term_type
        - due_days
      title: PaymentTerms
    ServiceFee:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Id
          description: Feature ID
        identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Identifier
          description: Unique identifier for the feature in the pricing instance
        priority:
          anyOf:
            - type: integer
            - type: 'null'
          title: Priority
          description: >-
            Priority of the feature, features get applied in ascending order of
            priority
        type:
          $ref: '#/components/schemas/ServiceFeeType'
        unit_amount:
          type: number
          minimum: 0
          title: Unit Amount
        pricing_period:
          anyOf:
            - $ref: '#/components/schemas/PeriodCadence'
            - type: 'null'
        label:
          anyOf:
            - type: string
            - type: 'null'
          title: Label
      type: object
      required:
        - type
        - unit_amount
      title: ServiceFee
    ExecutionLogic:
      properties:
        additional_steps:
          items:
            $ref: '#/components/schemas/ExecutionStep'
          type: array
          title: Additional Steps
          description: Additional nodes to add to the workflow
      type: object
      title: ExecutionLogic
      description: Defines custom execution logic for a pricing instance
    Period:
      properties:
        cadence:
          anyOf:
            - type: string
            - type: 'null'
          title: Cadence
          description: Cadence
        offset:
          $ref: '#/components/schemas/PeriodOffset'
          description: Offset
      type: object
      required:
        - offset
      title: Period
    ProductPricingResponseSchema_Overagepricing:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Pricing Model ID
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Pricing Model Name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Pricing Model Description
        pricing_data:
          oneOf:
            - $ref: '#/components/schemas/MatrixPricing'
            - $ref: '#/components/schemas/CustomTieredPricing'
            - $ref: '#/components/schemas/TwoDimensionalTieredPricing'
            - $ref: '#/components/schemas/PercentPricing'
            - $ref: '#/components/schemas/TieredPricing'
            - $ref: '#/components/schemas/TieredWithFlatFeePricing'
            - $ref: '#/components/schemas/VolumePricing'
            - $ref: '#/components/schemas/VolumeWithFlatFeePricing'
            - $ref: '#/components/schemas/StepPricing'
            - $ref: '#/components/schemas/PackagePricing'
            - $ref: '#/components/schemas/PerUnitPricing'
            - $ref: '#/components/schemas/FlatFee'
            - $ref: '#/components/schemas/FeaturesPricing'
            - $ref: '#/components/schemas/CustomPricing'
            - $ref: '#/components/schemas/BundlePricing'
          title: Pricing Data
          description: Pricing Data
          discriminator:
            propertyName: pricing_type
            mapping:
              bundle:
                $ref: '#/components/schemas/BundlePricing'
              custom_pricing:
                $ref: '#/components/schemas/CustomPricing'
              custom_tiered:
                $ref: '#/components/schemas/CustomTieredPricing'
              features:
                $ref: '#/components/schemas/FeaturesPricing'
              flat_fee:
                $ref: '#/components/schemas/FlatFee'
              matrix:
                $ref: '#/components/schemas/MatrixPricing'
              package:
                $ref: '#/components/schemas/PackagePricing'
              per_unit:
                $ref: '#/components/schemas/PerUnitPricing'
              percent:
                $ref: '#/components/schemas/PercentPricing'
              step:
                $ref: '#/components/schemas/StepPricing'
              tiered:
                $ref: '#/components/schemas/TieredPricing'
              tiered_with_flat_fee:
                $ref: '#/components/schemas/TieredWithFlatFeePricing'
              two_dimensional_tiered:
                $ref: '#/components/schemas/TwoDimensionalTieredPricing'
              volume:
                $ref: '#/components/schemas/VolumePricing'
              volume_with_flat_fee:
                $ref: '#/components/schemas/VolumeWithFlatFeePricing'
        quantity:
          anyOf:
            - $ref: '#/components/schemas/QuantityResponse'
            - type: 'null'
          description: Quantity
        grants:
          anyOf:
            - items:
                $ref: '#/components/schemas/GrantResponse'
              type: array
            - type: 'null'
          title: Grants
          description: Grants
          default: []
        consumptions:
          anyOf:
            - items:
                $ref: '#/components/schemas/ConsumptionResponse'
              type: array
            - type: 'null'
          title: Consumptions
          description: Consumptions
          default: []
        link_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Link Id
          description: Parent Link ID
        free_units:
          anyOf:
            - items:
                $ref: '#/components/schemas/FreeUnit'
              type: array
            - type: 'null'
          title: Free Units
          description: Free Units
          default: []
        discounts:
          anyOf:
            - items:
                $ref: '#/components/schemas/Discount'
              type: array
            - type: 'null'
          title: Discounts
          description: Discounts
          default: []
        commitments:
          anyOf:
            - items:
                $ref: '#/components/schemas/Commitment'
              type: array
            - type: 'null'
          title: Commitments
          description: Commitments
          default: []
        taxes:
          anyOf:
            - items:
                $ref: '#/components/schemas/Taxes'
              type: array
            - type: 'null'
          title: Taxes
          description: Taxes
          default: []
        payment_terms:
          anyOf:
            - items:
                $ref: '#/components/schemas/PaymentTerms'
              type: array
            - type: 'null'
          title: Payment Terms
          description: Payment Terms
          default: []
        service_fees:
          anyOf:
            - items:
                $ref: '#/components/schemas/ServiceFee'
              type: array
            - type: 'null'
          title: Service Fees
          description: Service Fees
          default: []
        execution_logic:
          anyOf:
            - $ref: '#/components/schemas/ExecutionLogic'
            - type: 'null'
          description: Execution Logic
        is_recurring:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Recurring
          description: Is Recurring or not
        billing_period:
          anyOf:
            - $ref: '#/components/schemas/Period'
            - type: 'null'
          description: Billing Cadence
        add_to_catalog:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Add To Catalog
          description: Part of product catalog or not
          default: true
        usage_report_configs:
          anyOf:
            - items:
                $ref: >-
                  #/components/schemas/ProductPricingUsageAssociationResponseSchema
              type: array
            - type: 'null'
          title: Usage Report Configs
          description: Usage Report Configurations associated with the pricing model
          default: []
      type: object
      required:
        - id
        - pricing_data
      title: ProductPricingResponseSchema
    ProductPricingUsageAssociationResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Product Pricing Usage Association ID
        aggregate_id:
          type: string
          format: uuid
          title: Aggregate Id
          description: Aggregate ID
        config:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Config
          description: Usage Report Configuration
          default: {}
        is_default:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Default
          description: Is Default or not
          default: false
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
          description: Created At
        updated_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updated At
          description: Updated At
        aggregate:
          anyOf:
            - $ref: '#/components/schemas/GetAggregateResponseSchema'
            - type: 'null'
          description: Aggregate
      type: object
      required:
        - id
        - aggregate_id
      title: ProductPricingUsageAssociationResponseSchema
    ProductResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Product ID
        name:
          type: string
          title: Name
          description: Product name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Product Description
        tags:
          anyOf:
            - items: {}
              type: array
            - type: 'null'
          title: Tags
          description: Product Tags
        sku:
          anyOf:
            - type: string
            - type: 'null'
          title: Sku
          description: Product SKU
        parent_link_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Parent Link Id
          description: Parent Link ID
        tax_codes:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Tax Codes
          description: Product Tax Codes
        is_active:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Active
          description: Is Active or not
        type:
          $ref: '#/components/schemas/ProductTypeV2'
          description: Product Type
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
          description: Created At
        updated_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updated At
          description: Updated At
        default_pricing_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Default Pricing Id
          description: Default Pricing ID
        custom_attributes:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Custom Attributes
          description: Custom Attributes
          default: {}
        product_category:
          anyOf:
            - $ref: '#/components/schemas/ProductCategory'
            - type: 'null'
          description: Product Category
        product_type:
          anyOf:
            - $ref: '#/components/schemas/ProductType'
            - type: 'null'
          description: Product Type
        product_sub_type:
          anyOf:
            - $ref: '#/components/schemas/ProductSubType'
            - type: 'null'
          description: Product Sub Type
        track_usage:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Track Usage
          description: Track Usage or not
        enum_values:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Enum Values
          description: Enum Values
        unit:
          anyOf:
            - type: string
            - type: 'null'
          title: Unit
          description: Unit
        entitlements:
          anyOf:
            - items:
                $ref: '#/components/schemas/EntitlementResponseSchema'
              type: array
            - type: 'null'
          title: Entitlements
          description: Entitlement
      type: object
      required:
        - id
        - name
        - type
      title: ProductResponseSchema
    ProductBundlePricingResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Pricing Model ID
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Pricing Model Name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Pricing Model Description
        pricing_data:
          oneOf:
            - $ref: '#/components/schemas/MatrixPricing'
            - $ref: '#/components/schemas/CustomTieredPricing'
            - $ref: '#/components/schemas/TwoDimensionalTieredPricing'
            - $ref: '#/components/schemas/PercentPricing'
            - $ref: '#/components/schemas/TieredPricing'
            - $ref: '#/components/schemas/TieredWithFlatFeePricing'
            - $ref: '#/components/schemas/VolumePricing'
            - $ref: '#/components/schemas/VolumeWithFlatFeePricing'
            - $ref: '#/components/schemas/StepPricing'
            - $ref: '#/components/schemas/PackagePricing'
            - $ref: '#/components/schemas/PerUnitPricing'
            - $ref: '#/components/schemas/FlatFee'
            - $ref: '#/components/schemas/FeaturesPricing'
            - $ref: '#/components/schemas/CustomPricing'
            - $ref: '#/components/schemas/BundlePricing'
          title: Pricing Data
          description: Pricing Data
          discriminator:
            propertyName: pricing_type
            mapping:
              bundle:
                $ref: '#/components/schemas/BundlePricing'
              custom_pricing:
                $ref: '#/components/schemas/CustomPricing'
              custom_tiered:
                $ref: '#/components/schemas/CustomTieredPricing'
              features:
                $ref: '#/components/schemas/FeaturesPricing'
              flat_fee:
                $ref: '#/components/schemas/FlatFee'
              matrix:
                $ref: '#/components/schemas/MatrixPricing'
              package:
                $ref: '#/components/schemas/PackagePricing'
              per_unit:
                $ref: '#/components/schemas/PerUnitPricing'
              percent:
                $ref: '#/components/schemas/PercentPricing'
              step:
                $ref: '#/components/schemas/StepPricing'
              tiered:
                $ref: '#/components/schemas/TieredPricing'
              tiered_with_flat_fee:
                $ref: '#/components/schemas/TieredWithFlatFeePricing'
              two_dimensional_tiered:
                $ref: '#/components/schemas/TwoDimensionalTieredPricing'
              volume:
                $ref: '#/components/schemas/VolumePricing'
              volume_with_flat_fee:
                $ref: '#/components/schemas/VolumeWithFlatFeePricing'
        quantity:
          anyOf:
            - $ref: '#/components/schemas/QuantityResponse'
            - type: 'null'
          description: Quantity
        grants:
          anyOf:
            - items:
                $ref: '#/components/schemas/GrantResponse'
              type: array
            - type: 'null'
          title: Grants
          description: Grants
          default: []
        consumptions:
          anyOf:
            - items:
                $ref: '#/components/schemas/ConsumptionResponse'
              type: array
            - type: 'null'
          title: Consumptions
          description: Consumptions
          default: []
        link_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Link Id
          description: Parent Link ID
        free_units:
          anyOf:
            - items:
                $ref: '#/components/schemas/FreeUnit'
              type: array
            - type: 'null'
          title: Free Units
          description: Free Units
          default: []
        discounts:
          anyOf:
            - items:
                $ref: '#/components/schemas/Discount'
              type: array
            - type: 'null'
          title: Discounts
          description: Discounts
          default: []
        commitments:
          anyOf:
            - items:
                $ref: '#/components/schemas/Commitment'
              type: array
            - type: 'null'
          title: Commitments
          description: Commitments
          default: []
        taxes:
          anyOf:
            - items:
                $ref: '#/components/schemas/Taxes'
              type: array
            - type: 'null'
          title: Taxes
          description: Taxes
          default: []
        payment_terms:
          anyOf:
            - items:
                $ref: '#/components/schemas/PaymentTerms'
              type: array
            - type: 'null'
          title: Payment Terms
          description: Payment Terms
          default: []
        service_fees:
          anyOf:
            - items:
                $ref: '#/components/schemas/ServiceFee'
              type: array
            - type: 'null'
          title: Service Fees
          description: Service Fees
          default: []
        execution_logic:
          anyOf:
            - $ref: '#/components/schemas/ExecutionLogic'
            - type: 'null'
          description: Execution Logic
        is_recurring:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Recurring
          description: Is Recurring or not
        billing_period:
          anyOf:
            - $ref: '#/components/schemas/Period'
            - type: 'null'
          description: Billing Cadence
        add_to_catalog:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Add To Catalog
          description: Part of product catalog or not
          default: true
        overage_pricing:
          anyOf:
            - $ref: '#/components/schemas/ProductPricingResponseSchema'
            - type: 'null'
          description: Overage Pricing Configuration
        usage_report_configs:
          anyOf:
            - items:
                $ref: >-
                  #/components/schemas/ProductPricingUsageAssociationResponseSchema
              type: array
            - type: 'null'
          title: Usage Report Configs
          description: Usage Report Configurations associated with the pricing model
          default: []
        products:
          anyOf:
            - items:
                $ref: '#/components/schemas/ProductInBundleResponseSchema'
              type: array
            - type: 'null'
          title: Products
          description: List of Bundled Products
      type: object
      required:
        - id
        - pricing_data
      title: ProductBundlePricingResponseSchema
    EnabledEntry:
      properties:
        value:
          type: boolean
          title: Value
          description: Whether the line item is enabled (True) or disabled (False)
        effective_from:
          type: string
          format: date
          title: Effective From
          description: Date when this state becomes effective
      type: object
      required:
        - value
        - effective_from
      title: EnabledEntry
      description: >-
        Entry for tracking enable/disable state over time.


        Used internally by self-serve checkout to track when a customer
        enables/disables

        optional products. This schema is not exposed in public API
        documentation.


        Attributes:
            value: Whether the line item is enabled (True) or disabled (False)
            effective_from: Date when this enable/disable state becomes effective (required)
    PeriodCadence:
      properties:
        cadence:
          anyOf:
            - type: string
            - type: 'null'
          title: Cadence
          description: Cadence
      type: object
      title: PeriodCadence
    EdgeInput:
      properties:
        step_name:
          type: string
          title: Step Name
          description: Step name
        output_field:
          type: string
          title: Output Field
          description: Output field
      type: object
      required:
        - step_name
        - output_field
      title: EdgeInput
      description: Represents an input that comes from another node's output
    Dimension:
      properties:
        name:
          type: string
          title: Name
        column_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Column Name
      type: object
      required:
        - name
      title: Dimension
    ProrationType:
      type: string
      enum:
        - day_based
        - cadence_based
      title: ProrationType
    QuantityType:
      type: string
      enum:
        - metered
        - fixed
      title: QuantityType
    QuantityEntry:
      properties:
        value:
          anyOf:
            - type: number
            - type: string
          title: Value
        effective_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Effective From
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
      type: object
      required:
        - value
      title: QuantityEntry
    GrantTriggerEvent:
      type: string
      enum:
        - payment_success
        - invoice_creation
        - invoice_approval
      title: GrantTriggerEvent
    GrantExpirationType:
      type: string
      enum:
        - never
        - end_of_contract_date
        - end_of_product_date
        - end_of_phase_date
        - end_of_product_billing_period
        - custom
      title: GrantExpirationType
    QuantityConstraints:
      properties:
        min:
          type: number
          minimum: 0
          title: Min
          description: Minimum quantity (required)
        max:
          type: number
          minimum: 0
          title: Max
          description: Maximum quantity (required)
      type: object
      required:
        - min
        - max
      title: QuantityConstraints
      description: |-
        Quantity constraints for plan-level quantity configuration

        Both min and max are required when constraints are provided.
        The constraints object itself is optional on Quantity, but when present,
        both fields must have values.

        Attributes:
            min: Minimum allowed quantity (required, >= 0)
            max: Maximum allowed quantity (required, >= 0, must be >= min)
    GetAggregateResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: aggregate Id
        name:
          type: string
          title: Name
          description: name of the aggregate
        dataschema:
          type: string
          title: Dataschema
          description: data schema of aggregate
        aggregation_query:
          type: string
          title: Aggregation Query
          description: aggregate query
        cust_agg_query:
          type: string
          title: Cust Agg Query
          description: customer aggregate query
        visual_query_builder:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Visual Query Builder
          description: visual query builder
        datasource:
          type: string
          format: uuid
          title: Datasource
          description: data source uuid
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
          description: Created_at
      type: object
      required:
        - id
        - name
        - dataschema
        - aggregation_query
        - cust_agg_query
        - visual_query_builder
        - datasource
      title: GetAggregateResponseSchema
      description: Aggregate Response Schema
    EntitlementType:
      type: string
      enum:
        - Feature
        - Quantity
        - Credits
      title: EntitlementType
    EntitlementResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Entitlement Id
        name:
          type: string
          title: Name
          description: Entitlement name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Entitlement Description
        entitlement_type:
          anyOf:
            - $ref: '#/components/schemas/EntitlementType'
            - type: 'null'
          description: Entitlement Type
        units:
          anyOf:
            - type: string
            - type: 'null'
          title: Units
          description: Entitlement Units
        is_active:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Active
          description: Entitlement is active
          default: true
        product_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Product Id
          description: Product ID
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
          description: created time
      type: object
      required:
        - id
        - name
      title: EntitlementResponseSchema
      description: Create Entitlement Response Schema
    ConsumptionTriggerEvent:
      type: string
      enum:
        - invoice_approval
        - invoice_creation
        - monitoring
      title: ConsumptionTriggerEvent
    DiscountType:
      type: string
      enum:
        - fixed
        - percent
        - quantity
      title: DiscountType
    CommitmentType:
      type: string
      enum:
        - minimum_spend
        - maximum_spend
      title: CommitmentType
    TaxType:
      type: string
      enum:
        - manual
        - avalara
      title: TaxType
    PaymentTermType:
      type: string
      enum:
        - on_approval
        - on_creation
      title: PaymentTermType
    PaymentTermMode:
      type: string
      enum:
        - relative
        - absolute
      title: PaymentTermMode
    ServiceFeeType:
      type: string
      enum:
        - fixed
        - percent
      title: ServiceFeeType
    ExecutionStep:
      properties:
        node_type:
          type: string
          title: Node Type
          description: Node type
        inputs:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Inputs
          description: Additional inputs for the node
        step_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Step Name
          description: Step name
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: Step ID
      type: object
      required:
        - node_type
      title: ExecutionStep
      description: Represents a custom execution step to be added to the workflow
    PeriodOffset:
      type: string
      enum:
        - prepaid
        - postpaid
      title: PeriodOffset
    ProductTypeV2:
      type: string
      enum:
        - product
        - group
      title: ProductTypeV2
    ProductCategory:
      type: string
      enum:
        - group
        - standalone
        - bundle
      title: ProductCategory
    ProductType:
      type: string
      enum:
        - time_dependent
        - time_independent
      title: ProductType
    ProductSubType:
      type: string
      enum:
        - quantity
        - boolean
        - credits
      title: ProductSubType
    ProductInBundleResponseSchema:
      properties:
        product:
          $ref: '#/components/schemas/ProductResponseSchema'
          description: Product
        pricing_model:
          $ref: '#/components/schemas/ProductPricingResponseSchema'
          description: Pricing Model
      type: object
      required:
        - product
        - pricing_model
      title: ProductInBundleResponseSchema
  securitySchemes:
    ApiTokenAuth:
      type: apiKey
      in: header
      name: x-api-key
      x-default: <your-api-key>
    OrganisationAuth:
      type: apiKey
      in: header
      name: organisation
      x-default: <your-organisation-id>

````