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

# Create quote

> Create a new quote.



## OpenAPI

````yaml post /v1/quotes
openapi: 3.1.0
info:
  title: Hyperline API
  version: 0.0.0
servers:
  - url: https://api.hyperline.co
  - url: https://sandbox.api.hyperline.co
security: []
paths:
  /v1/quotes:
    post:
      tags:
        - Quoting
      summary: Create quote
      description: Create a new quote.
      operationId: createQuote
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateQuote'
          multipart/form-data:
            schema:
              allOf:
                - type: object
                  properties:
                    status:
                      type: string
                      enum:
                        - draft
                        - approved
                        - pending_signature
                      description: >-

                        Quote status.


                        - `draft`: The quote is a draft.

                        - `approved`: The quote is approved and ready to be sent
                        to the customer.

                        - `pending_signature`: The quote is awaiting the
                        customer's signature.
                          
                      example: draft
                    owner_email:
                      type: string
                      format: email
                      description: >-
                        Email address of the Hyperline user acting as the quote
                        owner. The user must be a member of your Hyperline
                        account. The owner requests approval when the quote is
                        finalized using an API key or finalized during creation.
                        If not specified, the Hyperline account owner will be
                        assigned.
                      example: joe@acme.com
                    customer_id:
                      type: string
                      description: ID of the customer the quote is addressed to.
                      example: cus_QalW2vTAdkR6IY
                    invoicing_entity_id:
                      type: string
                      description: ID of the invoicing entity attached to the quote.
                      example: ive_47484fjdhy5
                    catalog_version_id:
                      type:
                        - string
                        - 'null'
                      description: >-
                        ID of a published catalog version to price every product
                        of the quote from, instead of the live products catalog.
                        A product's own `catalog_version_id` takes precedence,
                        and explicit `prices` always win over both.
                      example: pcv_9x8v7u6t5s4r
                    comments:
                      type: string
                      description: Custom comments displayed on the quote.
                      example: >-
                        Please find the contract and subscription details we
                        discussed.
                    terms:
                      type: string
                      description: Custom quotation terms.
                      example: >-
                        By signing this quote, you accept our conditions of use
                        for the use of our products and services.
                    amount:
                      type:
                        - number
                        - 'null'
                      description: >-
                        Estimated contract value. When computed, a subscription
                        phase with neither an end date nor a fixed duration is
                        counted over a conventional horizon: the contract's
                        length for a single phase on a contract that has one,
                        otherwise 12 months or the longest billing interval if
                        longer. That horizon is not an end date: the
                        subscription can run past it. Usage-based and connected
                        seat lines are priced at their estimated quantity when
                        it exceeds the committed quantity and, for seats, the
                        live seat count. For subscription quotes, defaults to
                        the computed subscription value if not specified. For
                        one-off quotes, this field is ignored — the amount is
                        always derived from the linked invoice's
                        `amount_excluding_tax`.
                      example: 20000
                    contract_value:
                      type:
                        - number
                        - 'null'
                      description: >-
                        What the customer pays over the contract, each coupon
                        counted on the invoices it applies to. Computed from the
                        subscription for `subscription` and
                        `subscription_update` quotes, unless set manually. Not
                        set on `one_off` quotes. When specified, overrides the
                        computed value.
                      example: 18000
                    collect_payment_details:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: >-
                        Collect customer payment method mandate during signature
                        flow or not.
                      example: true
                    collect_custom_property_ids:
                      type: array
                      items:
                        type: string
                      description: >-
                        IDs of the customer custom properties required to be
                        filled during the signature flow.
                      example: []
                    contract_clause_ids:
                      type: array
                      items:
                        type: string
                      description: IDs of the contract clauses used in the quote terms.
                      example:
                        - ccl_QalW2vTAdkR6IY
                    require_tax_id:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: >-
                        Require the customer to provide a tax ID during the
                        signature flow.
                      example: false
                    custom_properties:
                      type: object
                      additionalProperties:
                        anyOf:
                          - type: string
                          - type: number
                          - type: boolean
                          - type: string
                            format: date-time
                            description: >-
                              UTC date time string in the [ISO
                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                              format.
                            example: '2024-12-20T16:04:11Z'
                          - type: array
                            items:
                              type: string
                          - type: 'null'
                      description: >-
                        Custom property values set on the quote itself, keyed by
                        slug. Custom property values of a quote's subscription
                        are returned on the subscription.
                    display_quote_value:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: Display the total quote value on the quote.
                      example: true
                    display_quote_value_with_tax:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: >-
                        Display the total quote value including tax on the
                        quote.
                      example: false
                    display_taxes:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: Display tax breakdown on the quote.
                      example: true
                    display_price_tiers:
                      anyOf:
                        - type: string
                          enum:
                            - all
                            - matching
                            - none
                            - unit_price
                        - anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                      description: >
                        Controls which price tiers are displayed on the quote.


                        - `all`: Display all pricing tiers.

                        - `matching`: Only display the tiers used to compute the
                        price based on quantity.

                        - `none`: Hide all pricing tiers.

                        - `unit_price`: Show only the unit price, without tiers.
                      example: matching
                    display_phase_value:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: Display per-phase value breakdown on the quote.
                      example: false
                    display_discounts_on_total:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: >-
                        Display discounts on the totals, with product prices
                        before discount. Totals then follow the contract value,
                        so discounts with a limited duration are included.
                      example: false
                    display_first_invoice_amount:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: Display the first invoice amount on the quote.
                      example: false
                    display_documents_in_preview:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: Display attached documents in the quote preview.
                      example: false
                    subscription_update_display:
                      type: string
                      enum:
                        - quote_update_details
                        - subscription_details
                        - both
                      description: >-
                        Sections displayed on subscription update quotes:
                        quote_update_details, subscription_details, or both.
                        Takes precedence over display_subscription_on_update.
                      example: quote_update_details
                    display_subscription_on_update:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      deprecated: true
                      description: >-
                        Deprecated. Use subscription_update_display. False
                        displays quote update details; true displays both
                        sections.
                      example: false
                    generate_draft_invoices:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: >-
                        When `true`, the invoice issued after signature stays in
                        `draft` status instead of being emitted for payment. Use
                        this when you want to review the final invoice manually
                        before sending it. Defaults to `false`.
                      example: false
                    automatically_start_subscription:
                      anyOf:
                        - type: boolean
                        - type: string
                          enum:
                            - 'true'
                            - 'false'
                      description: >-
                        Deprecated field, please use the phase activation
                        strategy `quote_signature` instead.
                      example: true
                      deprecated: true
                  required:
                    - customer_id
                - anyOf:
                    - type: object
                      properties:
                        template_id:
                          type: string
                          description: >-
                            ID of the quote template the quote is built from. If
                            not specified, a subscription configuration or an
                            `invoice` payload must be defined.
                          example: quot_9hNWq4c84Z146W
                        expires_at:
                          type: string
                          format: date-time
                          description: >-
                            Quote expiration date. UTC date time string in the
                            [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-04-28T14:12:09.293Z'
                        subscription:
                          allOf:
                            - type: object
                              properties:
                                name:
                                  type: string
                                  description: Subscription custom name.
                                purchase_order:
                                  type: string
                                  description: Reference to the purchase order.
                                invoicing_entity_id:
                                  type: string
                                  description: >-
                                    ID of the invoicing entity attached to the
                                    subscription. If not defined, fallback to
                                    customer's invoicing entity.
                                  example: ive_jerrb484RHn
                                crm_opportunity_id:
                                  type: string
                                  description: >-
                                    ID of the related opportunity/deal in the
                                    connected CRM.
                                commitment_interval:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: number
                                      minimum: 1
                                  required:
                                    - period
                                    - count
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example:
                                    period: years
                                    count: 1
                                  deprecated: true
                                renew_automatically:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  default: true
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example: true
                                  deprecated: true
                                renew_for:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: number
                                  required:
                                    - period
                                    - count
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example:
                                    period: years
                                    count: 1
                                  deprecated: true
                                minimum_invoice_fee:
                                  type:
                                    - number
                                    - 'null'
                                  description: >-
                                    Minimum fee applied to each invoice outside
                                    of one time payments.
                                  example: 250
                                contract_terms:
                                  allOf:
                                    - type: object
                                      properties:
                                        starts_at:
                                          type: string
                                          format: date-time
                                          description: >-
                                            Start date of the contract. UTC date
                                            time string in the [ISO
                                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                                            format.
                                          example: '2024-12-20T16:04:11Z'
                                        ends_at:
                                          type: string
                                          format: date-time
                                          description: >-
                                            End date of the contract. UTC date time
                                            string in the [ISO
                                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                                            format.
                                          example: '2024-12-20T16:04:11Z'
                                        duration:
                                          type: object
                                          properties:
                                            period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                            count:
                                              type: integer
                                              minimum: 1
                                              default: 1
                                          required:
                                            - period
                                          description: >-
                                            Interval over which the contract
                                            initially spans. Only applies to
                                            `duration` end strategy.
                                          example:
                                            count: 6
                                            period: months
                                        renew_automatically:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          description: >

                                            Indicates if the contract should be
                                            renewed automatically.


                                            - `true`: The contract will be renewed
                                            automatically.

                                            - `false`: The contract will not be
                                            renewed automatically.
                                          example: true
                                        renew_for_duration:
                                          type: object
                                          properties:
                                            period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                            count:
                                              type: integer
                                              minimum: 1
                                              default: 1
                                          required:
                                            - period
                                          description: >

                                            Interval over which the contract will be
                                            renewed. Only applies if
                                            `renew_automatically` is true.
                                          example:
                                            count: 1
                                            period: years
                                    - type: object
                                      properties:
                                        activation_strategy:
                                          type: string
                                          enum:
                                            - start_date
                                            - immediately
                                            - manual
                                            - quote_signature
                                            - checkout
                                          description: >

                                            Activation strategy of the contract.


                                            - `immediately`: The contract will be
                                            activated immediately.

                                            - `manual`: The contract will be
                                            activated when a user manually activates
                                            it.

                                            - `start_date`: The contract will be
                                            activated on a specified date.

                                            - `quote_signature`: The contract will
                                            be activated when the subscription quote
                                            is signed.

                                            - `checkout`: The contract will be
                                            activated when the subscription checkout
                                            is completed.
                                          example: start_date
                                        end_strategy:
                                          type: string
                                          enum:
                                            - end_date
                                            - duration
                                            - manual
                                          description: >

                                            End strategy of contract.


                                            - `manual`: The contract ends when a
                                            user manually stops it.

                                            - `end_date`: The contract ends on a
                                            specified date.

                                            - `duration`: The contract ends after a
                                            specific relative duration, unless
                                            `renew_automatically` is true.
                                          example: duration
                                      required:
                                        - activation_strategy
                                        - end_strategy
                                  description: Contract terms linked to the subscription.
                                starts_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Applies only if the activation strategy is
                                    `start_date`. UTC date time string in the
                                    [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                contract_start:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example: '2024-01-15T00:00:00Z'
                                  deprecated: true
                                contract_end:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example: '2025-01-15T00:00:00Z'
                                  deprecated: true
                                initial_billing_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Date when the subscription will start being
                                    billed. If not specified, it will correspond
                                    to the `starts_at` date. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                payment_method_id:
                                  type: string
                                  description: >-
                                    ID of the customer's payment method used to
                                    pay the subscription's invoices, instead of
                                    the customer's default one. Cannot be
                                    combined with `bank_account_id`. Omit to use
                                    the customer's payment method.
                                  example: pm_abc123
                                bank_account_id:
                                  type: string
                                  description: >-
                                    ID of the bank account displayed on the
                                    subscription's invoices, which are then paid
                                    by bank transfer, instead of the customer's
                                    default payment method. Cannot be combined
                                    with `payment_method_id`. Omit to use the
                                    customer's payment method.
                                  example: bac_abc123
                                shipping_address_id:
                                  type: string
                                  description: >-
                                    ID of the customer's active shipping address
                                    the subscription ships to. Omit to use the
                                    customer shipping destination: billing
                                    address or default shipping address.
                                  example: cad_abc123
                                display_shipping_details:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Indicates if the shipping details should be
                                    displayed on the subscription's invoices.
                                cancel_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Subscription cancel date. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                cancellation_strategy:
                                  type: string
                                  enum:
                                    - refund_prorata
                                    - refund_custom
                                    - charge_prorata
                                    - charge_custom
                                    - end_of_period
                                    - do_nothing
                                  description: >

                                    Strategy used to cancel the subscription. If
                                    not specified `do_nothing` is used.


                                    - `charge_prorata`: Will charge the customer
                                    the unpaid amount for the prorated period up
                                    to the end of the current period.

                                    - `charge_custom`: Will charge the customer
                                    a custom amount.

                                    - `refund_prorata`: Will refund to the
                                    customer the overpaid subscription amount
                                    using prorated calculations on the
                                    cancellation date.

                                    - `refund_custom`: Will refund to the
                                    customer a custom amount.

                                    - `end_of_period`: Will cancel the
                                    subscription at the end date of the current
                                    billing period.

                                    - `do_nothing`: Will only cease the
                                    subscription without any additional actions.
                                cancellation_amount:
                                  type: number
                                  description: >-
                                    Custom amount used when cancelling the
                                    subscription. Only applies to the
                                    `charge_custom` or the `refund_custom`
                                    cancellation strategy.
                                cancellation_refund_method:
                                  type: string
                                  enum:
                                    - wallet
                                    - original_payment_method
                                    - external
                                  description: >-
                                    Override the refund destination for credit
                                    notes generated by `refund_prorata` /
                                    `refund_custom` cancellation strategies.
                                    When omitted, falls back to the invoicing
                                    entity's `creditNoteWalletRefundEnabled`
                                    setting.
                                properties:
                                  type: object
                                  additionalProperties:
                                    anyOf:
                                      - type: string
                                      - type: number
                                      - type: boolean
                                      - type: 'null'
                                      - type: array
                                        items:
                                          anyOf:
                                            - type: string
                                            - type: number
                                            - type: boolean
                                            - type: 'null'
                                            - type: 'null'
                                      - type: 'null'
                                  description: >-
                                    Key/value pairs to store any metadata useful
                                    in your context.
                                custom_properties:
                                  type: object
                                  additionalProperties:
                                    anyOf:
                                      - type: string
                                      - type: number
                                      - type: boolean
                                      - type: string
                                        format: date-time
                                        description: >-
                                          UTC date time string in the [ISO
                                          8601](https://en.wikipedia.org/wiki/ISO_8601)
                                          format.
                                        example: '2024-12-20T16:04:11Z'
                                      - type: array
                                        items:
                                          type: string
                                      - type: 'null'
                                  description: >-
                                    A list of key value with the slug of the
                                    custom property as the key and the custom
                                    property value as value.
                                tax_only:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Only tax will be charged on this
                                    subscription.
                                generate_draft_invoices:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Generate draft invoices for the
                                    subscription. Each invoice will need to be
                                    reviewed and validated manually before being
                                    sent
                                generate_document:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Generate non-legal documents instead of
                                    invoices.
                                document_name:
                                  type:
                                    - string
                                    - 'null'
                                  description: >-
                                    If `generate_document` is turned on, allows
                                    you to give a name to your document.
                                add_tax_to_document:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    If `generate_document` is turned on, will
                                    add taxes to document.
                                do_not_charge_subscription:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Subscription will be invoiced but not
                                    charged (invoices/documents will be settled
                                    directly).
                                invoice_custom_note:
                                  type:
                                    - string
                                    - 'null'
                                  description: >-
                                    Default custom note added to invoices
                                    generated by the subscription.
                                invoice_schedule:
                                  type:
                                    - string
                                    - 'null'
                                  enum:
                                    - period_start
                                    - period_end
                                  description: >

                                    Defines when invoices are generated relative
                                    to the billing period.


                                    - `period_start`: Invoices are generated at
                                    the start of the billing period.

                                    - `period_end`: Invoices are generated at
                                    the end of the billing period.
                            - anyOf:
                                - type: object
                                  properties:
                                    phases:
                                      type: array
                                      items:
                                        type: object
                                        properties:
                                          name:
                                            type: string
                                            description: Name of the subscription phase.
                                            example: Initial term
                                          type:
                                            type: string
                                            enum:
                                              - setup
                                              - trial
                                              - standard
                                            default: standard
                                            description: >

                                              Type of subscription phase.


                                              - `setup`: The phase represents a
                                              non-recurring service setup period,
                                              often used before the actual recurring
                                              subscription begins.

                                              - `trial`: The phase represents a
                                              non-recurring trial period, often used
                                              to allow users to opt out or experience
                                              a free test.

                                              - `standard`: The phase represents a
                                              standard recurring billing.
                                            example: standard
                                          status:
                                            type: string
                                            enum:
                                              - finished
                                              - pending
                                            default: pending
                                            description: >

                                              Status of subscription phase.


                                              - `pending`: The phase is waiting to
                                              start (not started yet).

                                              - `active`: The phase is currently in
                                              progress.

                                              - `finished`: The phase has ended and is
                                              complete.
                                            example: pending
                                          order:
                                            type: number
                                            description: >-
                                              Order in which the phase is executed
                                              within all subscription phases.
                                            example: 0
                                          end_strategy:
                                            type: string
                                            enum:
                                              - manual
                                              - end_date
                                              - duration
                                              - contract_end_date
                                            description: >

                                              End strategy of subscription phase.


                                              - `manual`: The phase ends when a user
                                              manually stops it.

                                              - `end_date`: The phase ends on a
                                              specified date.

                                              - `duration`: The phase ends after a
                                              specific relative duration.

                                              - `contract_end_date`: The phase ends on
                                              the end date of the related subscription
                                              contract.
                                            example: duration
                                          duration:
                                            type: object
                                            properties:
                                              period:
                                                type: string
                                                enum:
                                                  - days
                                                  - weeks
                                                  - months
                                                  - years
                                              count:
                                                type: integer
                                                minimum: 1
                                                default: 1
                                            required:
                                              - period
                                            description: >-
                                              Interval over which the subscription
                                              phase spans. Only applies to `duration`
                                              end strategy.
                                            example:
                                              count: 1
                                              period: years
                                          billing_date_setting:
                                            type: string
                                            enum:
                                              - phase_start
                                              - specific_date
                                            description: >

                                              Represents when the first billing date
                                              occurs.


                                              - `phase_start`: Aligns with the start
                                              of the phase.

                                              - `specific_date`: Occurs on a specified
                                              date.
                                            example: phase_start
                                          initial_billing_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Date when the subscription phase will
                                              start being billed. Only applies to
                                              `specific_date` billing date setting.
                                              UTC date time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          starts_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Actual start date of the phase. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          ends_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Actual end date of the phase. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          billing_cycle_alignment:
                                            type: string
                                            enum:
                                              - calendar_period
                                              - anniversary
                                            description: >

                                              Alignment of product billing cycles. If
                                              omitted at creation, the billing cycles
                                              alignment configured in the account
                                              subscription settings applies.


                                              - `calendar_period`: The billing cycles
                                              of the products will be aligned on the
                                              calendar period, after the first period
                                              which will be invoiced taking into
                                              account the prorata of the first cycle
                                              compared to the product periodicity.

                                              - `anniversary`: The billing cycles of
                                              the products will be aligned on the
                                              anniversary of the phase initial billing
                                              date.
                                            example: anniversary
                                          do_not_invoice_phase:
                                            type: boolean
                                            default: false
                                            description: >-
                                              Indicates if the phase should be
                                              invoiced. If set to true, the phase will
                                              not generate any invoices.
                                            example: false
                                          minimum_invoice_fee:
                                            type:
                                              - number
                                              - 'null'
                                            minimum: 0
                                            description: >-
                                              Phase minimum fee in minor currency
                                              units, after discounts and before tax.
                                              Null disables it and clears the product
                                              selection.
                                            example: 10000
                                          minimum_invoice_fee_products:
                                            type:
                                              - array
                                              - 'null'
                                            items:
                                              type: string
                                            description: >-
                                              Catalog product IDs eligible for the
                                              phase minimum fee. Null or an empty list
                                              includes all billed debit products in
                                              the phase.
                                            example:
                                              - itm_aaaaaaaaaaaaaa
                                          transition_calculation_method:
                                            type: string
                                            enum:
                                              - prorata
                                              - pay_in_full
                                              - none
                                            default: prorata
                                            description: >

                                              Calculation method used when
                                              transitioning from one phase to the next
                                              one.


                                              - `prorata`: The prorated amount between
                                              the two phases relative to the end date
                                              (the transition date) must be paid.

                                              - `pay_in_full`: The full amount for the
                                              phase billing period must be paid.

                                              - `none`: No amount will need to be
                                              paid, phase will simply transition from
                                              one to the next.
                                            example: prorata
                                          transition_invoicing_schedule:
                                            type: string
                                            enum:
                                              - immediately
                                            default: immediately
                                            description: >

                                              Represents when the transition amount
                                              will be invoiced.


                                              - `immediately`: An invoice will be
                                              generated immediately with the
                                              corresponding amount.
                                            example: immediately
                                          products:
                                            type: array
                                            items:
                                              type: object
                                              properties:
                                                id:
                                                  type: string
                                                  description: Product ID.
                                                  example: itm_FJKlqUb8COXw55
                                                catalog_version_id:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  description: >-
                                                    ID of a published catalog version to
                                                    price this product from, instead of the
                                                    live products catalog. Ignored when
                                                    `price` or `prices` is set. The product
                                                    must be priced in that version.
                                                  example: pcv_9x8v7u6t5s4r
                                                price_configuration_id:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  description: >-
                                                    ID of the product's price configuration
                                                    to price this product from, instead of
                                                    the one the catalog rules select. It
                                                    must be a live base configuration of the
                                                    product (not archived or replaced by a
                                                    later catalog publish, and not specific
                                                    to a customer, price book, customer
                                                    segment or plan), in the subscription's
                                                    currency. Requires `payment_interval`,
                                                    which it must match. The configuration's
                                                    country and commitment restrictions are
                                                    not checked. With a pinned catalog
                                                    version, the product is priced from that
                                                    version's copy of the configuration, and
                                                    a configuration the version doesn't
                                                    price returns a 400. Cannot be combined
                                                    with `price`, `prices` or `plan_id`.
                                                  example: prc_8f3kXODIM1sBwB
                                                name:
                                                  type: string
                                                  description: >-
                                                    Product name. This will appear on the
                                                    final invoices.
                                                  example: Product name
                                                description:
                                                  type: string
                                                  description: >-
                                                    Product description. This will appear on
                                                    the final invoices.
                                                  example: A description of the product.
                                                description_display_interval_dates:
                                                  type: boolean
                                                  default: false
                                                  description: >-
                                                    Indicates if the dates of the interval
                                                    should be automatically added in the
                                                    product description on the invoices.
                                                payment_interval:
                                                  anyOf:
                                                    - type: object
                                                      properties:
                                                        period:
                                                          type: string
                                                          enum:
                                                            - once
                                                      required:
                                                        - period
                                                      title: Once
                                                      example:
                                                        period: once
                                                    - type: object
                                                      properties:
                                                        period:
                                                          type: string
                                                          enum:
                                                            - days
                                                            - weeks
                                                            - months
                                                            - years
                                                        count:
                                                          type: integer
                                                          minimum: 1
                                                          default: 1
                                                      required:
                                                        - period
                                                      title: Period
                                                      example:
                                                        period: months
                                                        count: 1
                                                  description: >-
                                                    Interval on which the product is billed.
                                                    This interval can be different between
                                                    products and can differ from the
                                                    subscription commitment interval.
                                                payment_schedule:
                                                  type: string
                                                  enum:
                                                    - start
                                                    - end
                                                  description: >-
                                                    Indicates if the product should be
                                                    billed at the start or the end of the
                                                    payment interval.
                                                  example: start
                                                price:
                                                  type: object
                                                  properties:
                                                    type:
                                                      type: string
                                                      enum:
                                                        - fee
                                                    amount:
                                                      type: number
                                                      description: >-
                                                        Monetary amount. Expressed in currency's
                                                        smallest unit.
                                                  required:
                                                    - type
                                                    - amount
                                                  description: >-
                                                    Similar to `prices`, allow to apply a
                                                    single fee price more easily.
                                                  example:
                                                    type: fee
                                                    amount: 200
                                                prices:
                                                  type: array
                                                  items:
                                                    oneOf:
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - fee
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount. Expressed in currency's
                                                              smallest unit.
                                                        required:
                                                          - type
                                                          - amount
                                                        title: Fee price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - volume
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                          from:
                                                            type: number
                                                            description: From limit.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          on_tier_incomplete:
                                                            type:
                                                              - string
                                                              - 'null'
                                                            enum:
                                                              - pro_rata
                                                              - pay_in_full
                                                              - do_not_charge
                                                              - flat_per_tier
                                                            default: pro_rata
                                                            description: >-

                                                              Logic used to compute the amount when
                                                              usage on the tier is incomplete.


                                                              - `pro_rata`: The amount is computed
                                                              using the pro rata of the tier's
                                                              consumption.

                                                              - `pay_in_full`: The amount corresponds
                                                              to the full payment of the tier.

                                                              - `do_not_charge`: The tier is not
                                                              charged and ignored.

                                                              - `flat_per_tier`: The tier's `amount`
                                                              is a flat fee, billed once as soon as
                                                              usage reaches the tier, whatever the
                                                              number of units in it. `unitCount` is
                                                              ignored. No usage bills nothing.
                                                                
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                          - from
                                                          - to
                                                        title: Volume price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - packaged
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                          from:
                                                            type: number
                                                            description: From limit.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          on_bucket_incomplete:
                                                            type:
                                                              - string
                                                              - 'null'
                                                            enum:
                                                              - pro_rata
                                                              - pay_in_full
                                                              - do_not_charge
                                                              - flat_per_tier
                                                            default: pro_rata
                                                            description: >-

                                                              Logic used to compute the amount when
                                                              usage reaches an incomplete bucket (the
                                                              bucket size corresponds to the
                                                              `unitCount`).

                                                                - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                                - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                                - `do_not_charge`: The bucket is not charged and ignored.
                                                                - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                                  
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                          - from
                                                          - to
                                                        title: Packaged price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - bulk
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          on_tier_incomplete:
                                                            type:
                                                              - string
                                                              - 'null'
                                                            enum:
                                                              - pro_rata
                                                              - pay_in_full
                                                              - do_not_charge
                                                              - flat_per_tier
                                                            default: pro_rata
                                                            description: >-

                                                              Logic used to compute the amount when
                                                              usage on the tier is incomplete.


                                                              - `pro_rata`: The amount is computed
                                                              using the pro rata of the tier's
                                                              consumption.

                                                              - `pay_in_full`: The amount corresponds
                                                              to the full payment of the tier.

                                                              - `do_not_charge`: The tier is not
                                                              charged and ignored.

                                                              - `flat_per_tier`: The tier's `amount`
                                                              is a flat fee, billed once as soon as
                                                              usage reaches the tier, whatever the
                                                              number of units in it. `unitCount` is
                                                              ignored. No usage bills nothing.
                                                                
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                          - to
                                                        title: Bulk price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - bps
                                                          from:
                                                            type: number
                                                            description: From limit.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          percentage:
                                                            type: number
                                                            description: >-
                                                              Percentage applied on each unit to
                                                              compute the usage.
                                                          per_unit_cap:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: >-
                                                              Maximum amount for one unit. Expressed
                                                              in currency's smallest unit.
                                                          per_unit_floor:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: >-
                                                              Minimum amount for one unit. Expressed
                                                              in currency's smallest unit.
                                                          per_unit_fee:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: >-
                                                              Fee amount applied per unit. Expressed
                                                              in currency's smallest unit.
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - from
                                                          - to
                                                          - percentage
                                                          - per_unit_cap
                                                          - per_unit_floor
                                                          - per_unit_fee
                                                        title: BPS price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - bundle
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                        title: Bundle price
                                                        description: >-
                                                          For seat products only, if you are
                                                          looking for credits, use a fee price
                                                  description: >-
                                                    Prices of the product. If not specified,
                                                    the matching prices (depending on the
                                                    currency, interval, etc) of the product
                                                    defined in the products catalog/plan are
                                                    used.
                                                  example:
                                                    - type: volume
                                                      from: 0
                                                      to: 20
                                                      amount: 200
                                                      unit_count: 1
                                                      on_tier_incomplete: null
                                                    - type: volume
                                                      from: 20
                                                      to: null
                                                      amount: 150
                                                      unit_count: 1
                                                      on_tier_incomplete: null
                                                count:
                                                  type: number
                                                  minimum: 1
                                                  description: >-
                                                    Number of product units. Only applies to
                                                    products of type `flat_fee`, `seat` or
                                                    `credit`.
                                                  example: 2
                                                unit_name:
                                                  type: string
                                                  description: >-
                                                    Product name. This will appear on the
                                                    final invoices. Only applies to products
                                                    of type `seat` or `usage`.
                                                  example: user
                                                min_committed_count:
                                                  type: number
                                                  minimum: 1
                                                  description: >-
                                                    Minimum of units committed. If usage is
                                                    less than this number, then this value
                                                    will be used. Only applies to products
                                                    of type `usage`.
                                                min_amount:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Minimum amount billed. If the final
                                                    computed amount from the usage for this
                                                    product is less than this amount, then
                                                    this value will be used. Only applies to
                                                    products of type `usage`.
                                                max_amount:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Maximum amount billed. If the final
                                                    computed amount from the usage for this
                                                    product is greater than this amount,
                                                    then this value will be used. Only
                                                    applies to products of type `usage`.
                                                charging_method:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - prorata
                                                    - pay_in_full
                                                    - do_not_charge
                                                  description: >-
                                                    Charging method for seat count updates
                                                    within the current billing period. Only
                                                    applies to connected seat products.


                                                    - `prorata`: Price calculated
                                                    proportionally to time elapsed in the
                                                    billing period.

                                                    - `pay_in_full`: Price calculated for
                                                    the entire billing period.

                                                    - `do_not_charge`: No charge for the
                                                    update.
                                                seat_invoicing_schedule:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - immediately
                                                    - next_invoice
                                                    - custom
                                                  description: >

                                                    Policy defining when seat count changes
                                                    are invoiced. Only applies to connected
                                                    seat products.


                                                    - `immediately`: Seat changes are
                                                    invoiced immediately.

                                                    - `next_invoice`: Seat changes are
                                                    invoiced at the next invoice.

                                                    - `custom`: Seat changes are invoiced on
                                                    a custom schedule.
                                                metering_interval_type:
                                                  type: string
                                                  enum:
                                                    - subscription_commitment
                                                    - payment_interval
                                                    - full_database
                                                    - phase_duration
                                                    - custom
                                                  description: >-

                                                    Indicates on which type of interval the
                                                    usage should be aggregated.


                                                    - `subscription_commitment`: For the
                                                    usage contained within the subscription
                                                    commitment period.

                                                    - `payment_interval`: For the usage
                                                    contained within the payment interval of
                                                    the product.

                                                    - `full_database`: For all the usage we
                                                    ingested for this product, no matter the
                                                    period.

                                                    - `phase_duration`: For the usage
                                                    contained within the subscription phase.

                                                    - `custom`: For the usage contained
                                                    within a custom interval that starts
                                                    with the phase and renews independently
                                                    of the billing interval. Requires
                                                    `metering_interval` to be set.
                                                       Only applies to products of type `usage`.
                                                metering_interval:
                                                  type: object
                                                  properties:
                                                    period:
                                                      type: string
                                                      enum:
                                                        - days
                                                        - weeks
                                                        - months
                                                        - years
                                                    count:
                                                      type: integer
                                                      minimum: 1
                                                  required:
                                                    - period
                                                    - count
                                                  description: >-
                                                    Custom interval for usage aggregation.
                                                    Required when `metering_interval_type`
                                                    is `custom`. The interval starts at the
                                                    phase start and renews on its own cycle
                                                    (e.g. `{ period: 'months', count: 3 }`
                                                    for quarterly metering with monthly
                                                    billing). Only applies to products of
                                                    type `usage`.
                                                bill_usage_difference:
                                                  anyOf:
                                                    - type: boolean
                                                    - type: string
                                                      enum:
                                                        - 'true'
                                                        - 'false'
                                                  default: false
                                                  description: >-
                                                    Only bill the usage difference comparing
                                                    to the previous period (i.e. actual
                                                    amount minus last invoice amount).
                                                    Doesn't apply to `payment_interval`
                                                    metering interval type. Only applies to
                                                    products of type `usage`.
                                                children_usage_aggregation:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - sum
                                                    - max
                                                  description: >-

                                                    Controls whether a parent organization's
                                                    metered usage is billed on the combined
                                                    usage of the parent and its direct
                                                    children, and how per-member values are
                                                    combined.


                                                    - `null`: Organization-based usage is
                                                    disabled. Only the subscription
                                                    customer's own usage is billed.

                                                    - `sum`: The usage values of the parent
                                                    and each direct child are added together
                                                    (organization total).

                                                    - `max`: Only the single
                                                    highest-consuming member (parent or one
                                                    direct child) is billed.
                                                     Only applies to products of type `usage`.
                                                credits_expiration_in_days:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Validity in days for credits that will
                                                    be topped-up automatically. Once the
                                                    period has passed, they'll expire.
                                                expire_credits_at_end_of_period:
                                                  anyOf:
                                                    - type: boolean
                                                    - type: string
                                                      enum:
                                                        - 'true'
                                                        - 'false'
                                                  default: false
                                                  description: >-
                                                    Automatically set the expiration date to
                                                    the end of the next period for each
                                                    topup. Takes priority on
                                                    `creditsExpirationInDays`
                                                credits_balance_auto_creation_enabled:
                                                  anyOf:
                                                    - type: boolean
                                                    - type: string
                                                      enum:
                                                        - 'true'
                                                        - 'false'
                                                  description: >-
                                                    Whether to create the customer credit
                                                    balance as soon as the product is added
                                                    to the subscription. Defaults to the
                                                    credit product's
                                                    `credits_balance_auto_creation_enabled`
                                                    (`true` when unset). Set to `false` to
                                                    create the balance by hand before
                                                    activation, e.g. on quote-based renewals
                                                    where the balance must not start
                                                    consuming before signature; the first
                                                    top-up creates it if still missing.
                                                estimated_count:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  minimum: 0
                                                  maximum: 1000000000000
                                                  description: >-
                                                    Estimated number of units, for recurring
                                                    usage-based and connected seat products
                                                    (ignored on any other product, and not
                                                    priced for a usage-based product with
                                                    several filtered price groups). It
                                                    prices the quote value and is shown as
                                                    an estimate on the quote, but is never
                                                    billed: invoices use the measured usage
                                                    or seat count.
                                                  example: 200
                                              required:
                                                - id
                                            description: >-
                                              Products comprising the subscription
                                              phase.
                                          coupons:
                                            type: array
                                            items:
                                              allOf:
                                                - anyOf:
                                                    - type: object
                                                      properties:
                                                        id:
                                                          type: string
                                                          description: >-
                                                            ID of the catalog coupon to apply to the
                                                            subscription.
                                                      required:
                                                        - id
                                                      title: Existing coupon
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - amount
                                                        name:
                                                          type: string
                                                          description: Coupon name.
                                                        discount_amount:
                                                          type: number
                                                          exclusiveMinimum: 0
                                                          description: >-
                                                            Coupon discount amount. Expressed in
                                                            currency's smallest unit.
                                                      required:
                                                        - type
                                                        - discount_amount
                                                      title: Coupon amount
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - percent
                                                        name:
                                                          type: string
                                                          description: Coupon name.
                                                        discount_percent:
                                                          type: number
                                                          exclusiveMinimum: 0
                                                          maximum: 100
                                                          description: Coupon discount percentage.
                                                      required:
                                                        - type
                                                        - discount_percent
                                                      title: Coupon percent
                                                - type: object
                                                  properties:
                                                    repeat:
                                                      type:
                                                        - string
                                                        - 'null'
                                                      enum:
                                                        - once
                                                        - forever
                                                        - custom
                                                        - duration
                                                      description: >

                                                        Coupon frequency. Required for inline
                                                        coupons. Optional when an existing
                                                        coupon `id` is provided: if omitted,
                                                        defaults to the catalog coupon's repeat
                                                        value.


                                                        - `once`: Will apply the coupon only to
                                                        the first one invoice.

                                                        - `forever`: Will apply the coupon to
                                                        all invoices.

                                                        - `custom`: Will apply to coupon until a
                                                        specified expiration date.

                                                        - `duration`: Will apply the coupon for
                                                        a specific duration (e.g., 3 months).
                                                    duration_period:
                                                      type: string
                                                      enum:
                                                        - days
                                                        - weeks
                                                        - months
                                                        - years
                                                      description: >-
                                                        Period of time for which the coupon will
                                                        be applied. Only applies to the
                                                        `duration` coupon frequency.
                                                    duration_count:
                                                      type: number
                                                      description: >-
                                                        Number of periods for which the coupon
                                                        will be applied. Only applies to the
                                                        `duration` coupon frequency.
                                                    expires_at:
                                                      type: string
                                                      format: date-time
                                                      description: >-
                                                        Coupon expiration date. Only applies to
                                                        the `custom` coupon frequency. UTC date
                                                        time string in the [ISO
                                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                        format.
                                                      example: '2024-12-20T16:04:11Z'
                                                    apply_at:
                                                      type: string
                                                      format: date-time
                                                      description: >-
                                                        Coupon first application date. UTC date
                                                        time string in the [ISO
                                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                        format.
                                                      example: '2024-12-20T16:04:11Z'
                                                    product_ids:
                                                      type:
                                                        - array
                                                        - 'null'
                                                      items:
                                                        type: string
                                                      minItems: 1
                                                      description: >-
                                                        Products the coupon is scoped to on this
                                                        subscription, read together with
                                                        `product_scope`: the only discounted
                                                        products when `include`, the products
                                                        never discounted when `exclude`, null
                                                        when `all`. When sent without
                                                        `product_scope`, it is an `include`
                                                        list, except that a coupon already
                                                        stored as `exclude` keeps `exclude` when
                                                        its phase is updated; when empty or
                                                        omitted, the catalog coupon's scope is
                                                        copied.
                                                    product_scope:
                                                      type:
                                                        - string
                                                        - 'null'
                                                      enum:
                                                        - all
                                                        - include
                                                        - exclude
                                                      description: >-
                                                        Which products the coupon discounts on
                                                        this subscription. `all`: every product
                                                        (`product_ids` must be empty).
                                                        `include`: only the products in
                                                        `product_ids`. `exclude`: every product
                                                        except those in `product_ids` (lines
                                                        without a product stay discounted). When
                                                        sent, it replaces the catalog coupon's
                                                        scope together with `product_ids`. When
                                                        omitted, it is inferred: `include` if
                                                        `product_ids` is non-empty, else the
                                                        catalog coupon's scope. On a phase
                                                        update, a coupon already stored as
                                                        `exclude` keeps `exclude` when
                                                        `product_ids` is sent without
                                                        `product_scope`.
                                            description: >-
                                              Coupons comprising the subscription
                                              phase.
                                          activation_strategy:
                                            type: string
                                            enum:
                                              - manual
                                              - start_date
                                              - quote_signature
                                              - contract_start_date
                                              - previous_phase_end
                                            description: >

                                              Activation strategy of subscription
                                              phase.


                                              - `immediately`: The phase starts as
                                              soon as the subscription is activated.

                                              - `manual`: The phase starts when a user
                                              manually activates it.

                                              - `start_date`: The phase starts on a
                                              specified date.

                                              - `quote_signature`: The phase starts
                                              when the subscription quote is signed.

                                              - `checkout`: The phase starts when the
                                              subscription checkout is completed.

                                              - `contract_start_date`: The phase
                                              starts on the start date of the related
                                              subscription contract.

                                              - `previous_phase_end`: The phase starts
                                              when the previous phase ends.
                                            example: manual
                                        required:
                                          - end_strategy
                                          - billing_date_setting
                                          - products
                                          - activation_strategy
                                  required:
                                    - phases
                                  title: With phases
                                - allOf:
                                    - type: object
                                      properties:
                                        activation_strategy:
                                          type: string
                                          enum:
                                            - start_date
                                            - manually
                                            - quote
                                          default: manually
                                          description: >

                                            Strategy used to activate the
                                            subscription.


                                            - `start_date`: The subscription will
                                            become active on the specified start
                                            date. If the start date is in the past,
                                            it will be activated immediately.

                                            - `manually`: The subscription requires
                                            activation through a manual action.

                                            - `checkout`: The subscription will be
                                            activated once the checkout is
                                            completed, but only if the start date is
                                            in the past. Otherwise, activation will
                                            occur later on the specified start date.

                                            - `quote`: The subscription will be
                                            activated depending on the configuration
                                            and the signature of the related quote.
                                          example: start_date
                                        products:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              id:
                                                type: string
                                                description: Product ID.
                                                example: itm_FJKlqUb8COXw55
                                              catalog_version_id:
                                                type:
                                                  - string
                                                  - 'null'
                                                description: >-
                                                  ID of a published catalog version to
                                                  price this product from, instead of the
                                                  live products catalog. Ignored when
                                                  `price` or `prices` is set. The product
                                                  must be priced in that version.
                                                example: pcv_9x8v7u6t5s4r
                                              price_configuration_id:
                                                type:
                                                  - string
                                                  - 'null'
                                                description: >-
                                                  ID of the product's price configuration
                                                  to price this product from, instead of
                                                  the one the catalog rules select. It
                                                  must be a live base configuration of the
                                                  product (not archived or replaced by a
                                                  later catalog publish, and not specific
                                                  to a customer, price book, customer
                                                  segment or plan), in the subscription's
                                                  currency. Requires `payment_interval`,
                                                  which it must match. The configuration's
                                                  country and commitment restrictions are
                                                  not checked. With a pinned catalog
                                                  version, the product is priced from that
                                                  version's copy of the configuration, and
                                                  a configuration the version doesn't
                                                  price returns a 400. Cannot be combined
                                                  with `price`, `prices` or `plan_id`.
                                                example: prc_8f3kXODIM1sBwB
                                              name:
                                                type: string
                                                description: >-
                                                  Product name. This will appear on the
                                                  final invoices.
                                                example: Product name
                                              description:
                                                type: string
                                                description: >-
                                                  Product description. This will appear on
                                                  the final invoices.
                                                example: A description of the product.
                                              description_display_interval_dates:
                                                type: boolean
                                                default: false
                                                description: >-
                                                  Indicates if the dates of the interval
                                                  should be automatically added in the
                                                  product description on the invoices.
                                              payment_interval:
                                                anyOf:
                                                  - type: object
                                                    properties:
                                                      period:
                                                        type: string
                                                        enum:
                                                          - once
                                                    required:
                                                      - period
                                                    title: Once
                                                    example:
                                                      period: once
                                                  - type: object
                                                    properties:
                                                      period:
                                                        type: string
                                                        enum:
                                                          - days
                                                          - weeks
                                                          - months
                                                          - years
                                                      count:
                                                        type: integer
                                                        minimum: 1
                                                        default: 1
                                                    required:
                                                      - period
                                                    title: Period
                                                    example:
                                                      period: months
                                                      count: 1
                                                description: >-
                                                  Interval on which the product is billed.
                                                  This interval can be different between
                                                  products and can differ from the
                                                  subscription commitment interval.
                                              payment_schedule:
                                                type: string
                                                enum:
                                                  - start
                                                  - end
                                                description: >-
                                                  Indicates if the product should be
                                                  billed at the start or the end of the
                                                  payment interval.
                                                example: start
                                              price:
                                                type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - fee
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount. Expressed in currency's
                                                      smallest unit.
                                                required:
                                                  - type
                                                  - amount
                                                description: >-
                                                  Similar to `prices`, allow to apply a
                                                  single fee price more easily.
                                                example:
                                                  type: fee
                                                  amount: 200
                                              prices:
                                                type: array
                                                items:
                                                  oneOf:
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - fee
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount. Expressed in currency's
                                                            smallest unit.
                                                      required:
                                                        - type
                                                        - amount
                                                      title: Fee price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - volume
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                        from:
                                                          type: number
                                                          description: From limit.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        on_tier_incomplete:
                                                          type:
                                                            - string
                                                            - 'null'
                                                          enum:
                                                            - pro_rata
                                                            - pay_in_full
                                                            - do_not_charge
                                                            - flat_per_tier
                                                          default: pro_rata
                                                          description: >-

                                                            Logic used to compute the amount when
                                                            usage on the tier is incomplete.


                                                            - `pro_rata`: The amount is computed
                                                            using the pro rata of the tier's
                                                            consumption.

                                                            - `pay_in_full`: The amount corresponds
                                                            to the full payment of the tier.

                                                            - `do_not_charge`: The tier is not
                                                            charged and ignored.

                                                            - `flat_per_tier`: The tier's `amount`
                                                            is a flat fee, billed once as soon as
                                                            usage reaches the tier, whatever the
                                                            number of units in it. `unitCount` is
                                                            ignored. No usage bills nothing.
                                                              
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                        - from
                                                        - to
                                                      title: Volume price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - packaged
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                        from:
                                                          type: number
                                                          description: From limit.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        on_bucket_incomplete:
                                                          type:
                                                            - string
                                                            - 'null'
                                                          enum:
                                                            - pro_rata
                                                            - pay_in_full
                                                            - do_not_charge
                                                            - flat_per_tier
                                                          default: pro_rata
                                                          description: >-

                                                            Logic used to compute the amount when
                                                            usage reaches an incomplete bucket (the
                                                            bucket size corresponds to the
                                                            `unitCount`).

                                                              - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                              - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                              - `do_not_charge`: The bucket is not charged and ignored.
                                                              - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                                
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                        - from
                                                        - to
                                                      title: Packaged price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - bulk
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        on_tier_incomplete:
                                                          type:
                                                            - string
                                                            - 'null'
                                                          enum:
                                                            - pro_rata
                                                            - pay_in_full
                                                            - do_not_charge
                                                            - flat_per_tier
                                                          default: pro_rata
                                                          description: >-

                                                            Logic used to compute the amount when
                                                            usage on the tier is incomplete.


                                                            - `pro_rata`: The amount is computed
                                                            using the pro rata of the tier's
                                                            consumption.

                                                            - `pay_in_full`: The amount corresponds
                                                            to the full payment of the tier.

                                                            - `do_not_charge`: The tier is not
                                                            charged and ignored.

                                                            - `flat_per_tier`: The tier's `amount`
                                                            is a flat fee, billed once as soon as
                                                            usage reaches the tier, whatever the
                                                            number of units in it. `unitCount` is
                                                            ignored. No usage bills nothing.
                                                              
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                        - to
                                                      title: Bulk price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - bps
                                                        from:
                                                          type: number
                                                          description: From limit.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        percentage:
                                                          type: number
                                                          description: >-
                                                            Percentage applied on each unit to
                                                            compute the usage.
                                                        per_unit_cap:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: >-
                                                            Maximum amount for one unit. Expressed
                                                            in currency's smallest unit.
                                                        per_unit_floor:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: >-
                                                            Minimum amount for one unit. Expressed
                                                            in currency's smallest unit.
                                                        per_unit_fee:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: >-
                                                            Fee amount applied per unit. Expressed
                                                            in currency's smallest unit.
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - from
                                                        - to
                                                        - percentage
                                                        - per_unit_cap
                                                        - per_unit_floor
                                                        - per_unit_fee
                                                      title: BPS price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - bundle
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                      title: Bundle price
                                                      description: >-
                                                        For seat products only, if you are
                                                        looking for credits, use a fee price
                                                description: >-
                                                  Prices of the product. If not specified,
                                                  the matching prices (depending on the
                                                  currency, interval, etc) of the product
                                                  defined in the products catalog/plan are
                                                  used.
                                                example:
                                                  - type: volume
                                                    from: 0
                                                    to: 20
                                                    amount: 200
                                                    unit_count: 1
                                                    on_tier_incomplete: null
                                                  - type: volume
                                                    from: 20
                                                    to: null
                                                    amount: 150
                                                    unit_count: 1
                                                    on_tier_incomplete: null
                                              count:
                                                type: number
                                                minimum: 1
                                                description: >-
                                                  Number of product units. Only applies to
                                                  products of type `flat_fee`, `seat` or
                                                  `credit`.
                                                example: 2
                                              unit_name:
                                                type: string
                                                description: >-
                                                  Product name. This will appear on the
                                                  final invoices. Only applies to products
                                                  of type `seat` or `usage`.
                                                example: user
                                              min_committed_count:
                                                type: number
                                                minimum: 1
                                                description: >-
                                                  Minimum of units committed. If usage is
                                                  less than this number, then this value
                                                  will be used. Only applies to products
                                                  of type `usage`.
                                              min_amount:
                                                type:
                                                  - number
                                                  - 'null'
                                                description: >-
                                                  Minimum amount billed. If the final
                                                  computed amount from the usage for this
                                                  product is less than this amount, then
                                                  this value will be used. Only applies to
                                                  products of type `usage`.
                                              max_amount:
                                                type:
                                                  - number
                                                  - 'null'
                                                description: >-
                                                  Maximum amount billed. If the final
                                                  computed amount from the usage for this
                                                  product is greater than this amount,
                                                  then this value will be used. Only
                                                  applies to products of type `usage`.
                                              charging_method:
                                                type:
                                                  - string
                                                  - 'null'
                                                enum:
                                                  - prorata
                                                  - pay_in_full
                                                  - do_not_charge
                                                description: >-
                                                  Charging method for seat count updates
                                                  within the current billing period. Only
                                                  applies to connected seat products.


                                                  - `prorata`: Price calculated
                                                  proportionally to time elapsed in the
                                                  billing period.

                                                  - `pay_in_full`: Price calculated for
                                                  the entire billing period.

                                                  - `do_not_charge`: No charge for the
                                                  update.
                                              seat_invoicing_schedule:
                                                type:
                                                  - string
                                                  - 'null'
                                                enum:
                                                  - immediately
                                                  - next_invoice
                                                  - custom
                                                description: >

                                                  Policy defining when seat count changes
                                                  are invoiced. Only applies to connected
                                                  seat products.


                                                  - `immediately`: Seat changes are
                                                  invoiced immediately.

                                                  - `next_invoice`: Seat changes are
                                                  invoiced at the next invoice.

                                                  - `custom`: Seat changes are invoiced on
                                                  a custom schedule.
                                              metering_interval_type:
                                                type: string
                                                enum:
                                                  - subscription_commitment
                                                  - payment_interval
                                                  - full_database
                                                  - phase_duration
                                                  - custom
                                                description: >-

                                                  Indicates on which type of interval the
                                                  usage should be aggregated.


                                                  - `subscription_commitment`: For the
                                                  usage contained within the subscription
                                                  commitment period.

                                                  - `payment_interval`: For the usage
                                                  contained within the payment interval of
                                                  the product.

                                                  - `full_database`: For all the usage we
                                                  ingested for this product, no matter the
                                                  period.

                                                  - `phase_duration`: For the usage
                                                  contained within the subscription phase.

                                                  - `custom`: For the usage contained
                                                  within a custom interval that starts
                                                  with the phase and renews independently
                                                  of the billing interval. Requires
                                                  `metering_interval` to be set.
                                                     Only applies to products of type `usage`.
                                              metering_interval:
                                                type: object
                                                properties:
                                                  period:
                                                    type: string
                                                    enum:
                                                      - days
                                                      - weeks
                                                      - months
                                                      - years
                                                  count:
                                                    type: integer
                                                    minimum: 1
                                                required:
                                                  - period
                                                  - count
                                                description: >-
                                                  Custom interval for usage aggregation.
                                                  Required when `metering_interval_type`
                                                  is `custom`. The interval starts at the
                                                  phase start and renews on its own cycle
                                                  (e.g. `{ period: 'months', count: 3 }`
                                                  for quarterly metering with monthly
                                                  billing). Only applies to products of
                                                  type `usage`.
                                              bill_usage_difference:
                                                anyOf:
                                                  - type: boolean
                                                  - type: string
                                                    enum:
                                                      - 'true'
                                                      - 'false'
                                                default: false
                                                description: >-
                                                  Only bill the usage difference comparing
                                                  to the previous period (i.e. actual
                                                  amount minus last invoice amount).
                                                  Doesn't apply to `payment_interval`
                                                  metering interval type. Only applies to
                                                  products of type `usage`.
                                              children_usage_aggregation:
                                                type:
                                                  - string
                                                  - 'null'
                                                enum:
                                                  - sum
                                                  - max
                                                description: >-

                                                  Controls whether a parent organization's
                                                  metered usage is billed on the combined
                                                  usage of the parent and its direct
                                                  children, and how per-member values are
                                                  combined.


                                                  - `null`: Organization-based usage is
                                                  disabled. Only the subscription
                                                  customer's own usage is billed.

                                                  - `sum`: The usage values of the parent
                                                  and each direct child are added together
                                                  (organization total).

                                                  - `max`: Only the single
                                                  highest-consuming member (parent or one
                                                  direct child) is billed.
                                                   Only applies to products of type `usage`.
                                              credits_expiration_in_days:
                                                type:
                                                  - number
                                                  - 'null'
                                                description: >-
                                                  Validity in days for credits that will
                                                  be topped-up automatically. Once the
                                                  period has passed, they'll expire.
                                              expire_credits_at_end_of_period:
                                                anyOf:
                                                  - type: boolean
                                                  - type: string
                                                    enum:
                                                      - 'true'
                                                      - 'false'
                                                default: false
                                                description: >-
                                                  Automatically set the expiration date to
                                                  the end of the next period for each
                                                  topup. Takes priority on
                                                  `creditsExpirationInDays`
                                              credits_balance_auto_creation_enabled:
                                                anyOf:
                                                  - type: boolean
                                                  - type: string
                                                    enum:
                                                      - 'true'
                                                      - 'false'
                                                description: >-
                                                  Whether to create the customer credit
                                                  balance as soon as the product is added
                                                  to the subscription. Defaults to the
                                                  credit product's
                                                  `credits_balance_auto_creation_enabled`
                                                  (`true` when unset). Set to `false` to
                                                  create the balance by hand before
                                                  activation, e.g. on quote-based renewals
                                                  where the balance must not start
                                                  consuming before signature; the first
                                                  top-up creates it if still missing.
                                              estimated_count:
                                                type:
                                                  - number
                                                  - 'null'
                                                minimum: 0
                                                maximum: 1000000000000
                                                description: >-
                                                  Estimated number of units, for recurring
                                                  usage-based and connected seat products
                                                  (ignored on any other product, and not
                                                  priced for a usage-based product with
                                                  several filtered price groups). It
                                                  prices the quote value and is shown as
                                                  an estimate on the quote, but is never
                                                  billed: invoices use the measured usage
                                                  or seat count.
                                                example: 200
                                            required:
                                              - id
                                          description: Products that make up the subscription.
                                        coupons:
                                          type: array
                                          items:
                                            allOf:
                                              - anyOf:
                                                  - type: object
                                                    properties:
                                                      id:
                                                        type: string
                                                        description: >-
                                                          ID of the catalog coupon to apply to the
                                                          subscription.
                                                    required:
                                                      - id
                                                    title: Existing coupon
                                                  - type: object
                                                    properties:
                                                      type:
                                                        type: string
                                                        enum:
                                                          - amount
                                                      name:
                                                        type: string
                                                        description: Coupon name.
                                                      discount_amount:
                                                        type: number
                                                        exclusiveMinimum: 0
                                                        description: >-
                                                          Coupon discount amount. Expressed in
                                                          currency's smallest unit.
                                                    required:
                                                      - type
                                                      - discount_amount
                                                    title: Coupon amount
                                                  - type: object
                                                    properties:
                                                      type:
                                                        type: string
                                                        enum:
                                                          - percent
                                                      name:
                                                        type: string
                                                        description: Coupon name.
                                                      discount_percent:
                                                        type: number
                                                        exclusiveMinimum: 0
                                                        maximum: 100
                                                        description: Coupon discount percentage.
                                                    required:
                                                      - type
                                                      - discount_percent
                                                    title: Coupon percent
                                              - type: object
                                                properties:
                                                  repeat:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - once
                                                      - forever
                                                      - custom
                                                      - duration
                                                    description: >

                                                      Coupon frequency. Required for inline
                                                      coupons. Optional when an existing
                                                      coupon `id` is provided: if omitted,
                                                      defaults to the catalog coupon's repeat
                                                      value.


                                                      - `once`: Will apply the coupon only to
                                                      the first one invoice.

                                                      - `forever`: Will apply the coupon to
                                                      all invoices.

                                                      - `custom`: Will apply to coupon until a
                                                      specified expiration date.

                                                      - `duration`: Will apply the coupon for
                                                      a specific duration (e.g., 3 months).
                                                  duration_period:
                                                    type: string
                                                    enum:
                                                      - days
                                                      - weeks
                                                      - months
                                                      - years
                                                    description: >-
                                                      Period of time for which the coupon will
                                                      be applied. Only applies to the
                                                      `duration` coupon frequency.
                                                  duration_count:
                                                    type: number
                                                    description: >-
                                                      Number of periods for which the coupon
                                                      will be applied. Only applies to the
                                                      `duration` coupon frequency.
                                                  expires_at:
                                                    type: string
                                                    format: date-time
                                                    description: >-
                                                      Coupon expiration date. Only applies to
                                                      the `custom` coupon frequency. UTC date
                                                      time string in the [ISO
                                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                      format.
                                                    example: '2024-12-20T16:04:11Z'
                                                  apply_at:
                                                    type: string
                                                    format: date-time
                                                    description: >-
                                                      Coupon first application date. UTC date
                                                      time string in the [ISO
                                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                      format.
                                                    example: '2024-12-20T16:04:11Z'
                                                  product_ids:
                                                    type:
                                                      - array
                                                      - 'null'
                                                    items:
                                                      type: string
                                                    minItems: 1
                                                    description: >-
                                                      Products the coupon is scoped to on this
                                                      subscription, read together with
                                                      `product_scope`: the only discounted
                                                      products when `include`, the products
                                                      never discounted when `exclude`, null
                                                      when `all`. When sent without
                                                      `product_scope`, it is an `include`
                                                      list, except that a coupon already
                                                      stored as `exclude` keeps `exclude` when
                                                      its phase is updated; when empty or
                                                      omitted, the catalog coupon's scope is
                                                      copied.
                                                  product_scope:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - all
                                                      - include
                                                      - exclude
                                                    description: >-
                                                      Which products the coupon discounts on
                                                      this subscription. `all`: every product
                                                      (`product_ids` must be empty).
                                                      `include`: only the products in
                                                      `product_ids`. `exclude`: every product
                                                      except those in `product_ids` (lines
                                                      without a product stay discounted). When
                                                      sent, it replaces the catalog coupon's
                                                      scope together with `product_ids`. When
                                                      omitted, it is inferred: `include` if
                                                      `product_ids` is non-empty, else the
                                                      catalog coupon's scope. On a phase
                                                      update, a coupon already stored as
                                                      `exclude` keeps `exclude` when
                                                      `product_ids` is sent without
                                                      `product_scope`.
                                          description: >-
                                            Coupons to be applied to the prices of
                                            subscription products.
                                    - type: object
                                      properties:
                                        trial:
                                          type: object
                                          properties:
                                            end_strategy:
                                              type: string
                                              enum:
                                                - manual
                                                - end_date
                                                - duration
                                              description: Defines how the free trial will end.
                                            starts_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Free trial start date. UTC date time
                                                string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            ends_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Free trial end date. Only applies if the
                                                end strategy is `end_date`. UTC date
                                                time string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            duration:
                                              type: object
                                              properties:
                                                period:
                                                  type: string
                                                  enum:
                                                    - days
                                                    - weeks
                                                    - months
                                                    - years
                                                  description: >-
                                                    Free trial duration period. Only applies
                                                    if the end strategy is `duration`.
                                                count:
                                                  type: number
                                                  minimum: 1
                                                  description: >-
                                                    Free trial duration count. Only applies
                                                    if the end strategy is `duration`.
                                              required:
                                                - period
                                                - count
                                          required:
                                            - end_strategy
                                          description: >-
                                            Create a free trial phase based on the
                                            plan configuration. Only applies if a
                                            `plan_id` is provided.
                                  title: Without phases
                          description: Subscription configuration constituting the quote.
                      required:
                        - template_id
                      title: Subscription from a template
                    - type: object
                      properties:
                        expires_at:
                          type: string
                          format: date-time
                          description: >-
                            Quote expiration date. UTC date time string in the
                            [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-04-28T14:12:09.293Z'
                        subscription:
                          allOf:
                            - type: object
                              properties:
                                name:
                                  type: string
                                  description: Subscription custom name.
                                purchase_order:
                                  type: string
                                  description: Reference to the purchase order.
                                invoicing_entity_id:
                                  type: string
                                  description: >-
                                    ID of the invoicing entity attached to the
                                    subscription. If not defined, fallback to
                                    customer's invoicing entity.
                                  example: ive_jerrb484RHn
                                crm_opportunity_id:
                                  type: string
                                  description: >-
                                    ID of the related opportunity/deal in the
                                    connected CRM.
                                commitment_interval:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: number
                                      minimum: 1
                                  required:
                                    - period
                                    - count
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example:
                                    period: years
                                    count: 1
                                  deprecated: true
                                renew_automatically:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  default: true
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example: true
                                  deprecated: true
                                renew_for:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: number
                                  required:
                                    - period
                                    - count
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example:
                                    period: years
                                    count: 1
                                  deprecated: true
                                minimum_invoice_fee:
                                  type:
                                    - number
                                    - 'null'
                                  description: >-
                                    Minimum fee applied to each invoice outside
                                    of one time payments.
                                  example: 250
                                contract_terms:
                                  allOf:
                                    - type: object
                                      properties:
                                        starts_at:
                                          type: string
                                          format: date-time
                                          description: >-
                                            Start date of the contract. UTC date
                                            time string in the [ISO
                                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                                            format.
                                          example: '2024-12-20T16:04:11Z'
                                        ends_at:
                                          type: string
                                          format: date-time
                                          description: >-
                                            End date of the contract. UTC date time
                                            string in the [ISO
                                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                                            format.
                                          example: '2024-12-20T16:04:11Z'
                                        duration:
                                          type: object
                                          properties:
                                            period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                            count:
                                              type: integer
                                              minimum: 1
                                              default: 1
                                          required:
                                            - period
                                          description: >-
                                            Interval over which the contract
                                            initially spans. Only applies to
                                            `duration` end strategy.
                                          example:
                                            count: 6
                                            period: months
                                        renew_automatically:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          description: >

                                            Indicates if the contract should be
                                            renewed automatically.


                                            - `true`: The contract will be renewed
                                            automatically.

                                            - `false`: The contract will not be
                                            renewed automatically.
                                          example: true
                                        renew_for_duration:
                                          type: object
                                          properties:
                                            period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                            count:
                                              type: integer
                                              minimum: 1
                                              default: 1
                                          required:
                                            - period
                                          description: >

                                            Interval over which the contract will be
                                            renewed. Only applies if
                                            `renew_automatically` is true.
                                          example:
                                            count: 1
                                            period: years
                                    - type: object
                                      properties:
                                        activation_strategy:
                                          type: string
                                          enum:
                                            - start_date
                                            - immediately
                                            - manual
                                            - quote_signature
                                            - checkout
                                          description: >

                                            Activation strategy of the contract.


                                            - `immediately`: The contract will be
                                            activated immediately.

                                            - `manual`: The contract will be
                                            activated when a user manually activates
                                            it.

                                            - `start_date`: The contract will be
                                            activated on a specified date.

                                            - `quote_signature`: The contract will
                                            be activated when the subscription quote
                                            is signed.

                                            - `checkout`: The contract will be
                                            activated when the subscription checkout
                                            is completed.
                                          example: start_date
                                        end_strategy:
                                          type: string
                                          enum:
                                            - end_date
                                            - duration
                                            - manual
                                          description: >

                                            End strategy of contract.


                                            - `manual`: The contract ends when a
                                            user manually stops it.

                                            - `end_date`: The contract ends on a
                                            specified date.

                                            - `duration`: The contract ends after a
                                            specific relative duration, unless
                                            `renew_automatically` is true.
                                          example: duration
                                      required:
                                        - activation_strategy
                                        - end_strategy
                                  description: Contract terms linked to the subscription.
                                starts_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Applies only if the activation strategy is
                                    `start_date`. UTC date time string in the
                                    [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                contract_start:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example: '2024-01-15T00:00:00Z'
                                  deprecated: true
                                contract_end:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Deprecated field, please use
                                    `contract_terms`.
                                  example: '2025-01-15T00:00:00Z'
                                  deprecated: true
                                initial_billing_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Date when the subscription will start being
                                    billed. If not specified, it will correspond
                                    to the `starts_at` date. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                payment_method_id:
                                  type: string
                                  description: >-
                                    ID of the customer's payment method used to
                                    pay the subscription's invoices, instead of
                                    the customer's default one. Cannot be
                                    combined with `bank_account_id`. Omit to use
                                    the customer's payment method.
                                  example: pm_abc123
                                bank_account_id:
                                  type: string
                                  description: >-
                                    ID of the bank account displayed on the
                                    subscription's invoices, which are then paid
                                    by bank transfer, instead of the customer's
                                    default payment method. Cannot be combined
                                    with `payment_method_id`. Omit to use the
                                    customer's payment method.
                                  example: bac_abc123
                                shipping_address_id:
                                  type: string
                                  description: >-
                                    ID of the customer's active shipping address
                                    the subscription ships to. Omit to use the
                                    customer shipping destination: billing
                                    address or default shipping address.
                                  example: cad_abc123
                                display_shipping_details:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Indicates if the shipping details should be
                                    displayed on the subscription's invoices.
                                cancel_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Subscription cancel date. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                cancellation_strategy:
                                  type: string
                                  enum:
                                    - refund_prorata
                                    - refund_custom
                                    - charge_prorata
                                    - charge_custom
                                    - end_of_period
                                    - do_nothing
                                  description: >

                                    Strategy used to cancel the subscription. If
                                    not specified `do_nothing` is used.


                                    - `charge_prorata`: Will charge the customer
                                    the unpaid amount for the prorated period up
                                    to the end of the current period.

                                    - `charge_custom`: Will charge the customer
                                    a custom amount.

                                    - `refund_prorata`: Will refund to the
                                    customer the overpaid subscription amount
                                    using prorated calculations on the
                                    cancellation date.

                                    - `refund_custom`: Will refund to the
                                    customer a custom amount.

                                    - `end_of_period`: Will cancel the
                                    subscription at the end date of the current
                                    billing period.

                                    - `do_nothing`: Will only cease the
                                    subscription without any additional actions.
                                cancellation_amount:
                                  type: number
                                  description: >-
                                    Custom amount used when cancelling the
                                    subscription. Only applies to the
                                    `charge_custom` or the `refund_custom`
                                    cancellation strategy.
                                cancellation_refund_method:
                                  type: string
                                  enum:
                                    - wallet
                                    - original_payment_method
                                    - external
                                  description: >-
                                    Override the refund destination for credit
                                    notes generated by `refund_prorata` /
                                    `refund_custom` cancellation strategies.
                                    When omitted, falls back to the invoicing
                                    entity's `creditNoteWalletRefundEnabled`
                                    setting.
                                properties:
                                  type: object
                                  additionalProperties:
                                    anyOf:
                                      - type: string
                                      - type: number
                                      - type: boolean
                                      - type: 'null'
                                      - type: array
                                        items:
                                          anyOf:
                                            - type: string
                                            - type: number
                                            - type: boolean
                                            - type: 'null'
                                            - type: 'null'
                                      - type: 'null'
                                  description: >-
                                    Key/value pairs to store any metadata useful
                                    in your context.
                                custom_properties:
                                  type: object
                                  additionalProperties:
                                    anyOf:
                                      - type: string
                                      - type: number
                                      - type: boolean
                                      - type: string
                                        format: date-time
                                        description: >-
                                          UTC date time string in the [ISO
                                          8601](https://en.wikipedia.org/wiki/ISO_8601)
                                          format.
                                        example: '2024-12-20T16:04:11Z'
                                      - type: array
                                        items:
                                          type: string
                                      - type: 'null'
                                  description: >-
                                    A list of key value with the slug of the
                                    custom property as the key and the custom
                                    property value as value.
                                tax_only:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Only tax will be charged on this
                                    subscription.
                                generate_draft_invoices:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Generate draft invoices for the
                                    subscription. Each invoice will need to be
                                    reviewed and validated manually before being
                                    sent
                                generate_document:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Generate non-legal documents instead of
                                    invoices.
                                document_name:
                                  type:
                                    - string
                                    - 'null'
                                  description: >-
                                    If `generate_document` is turned on, allows
                                    you to give a name to your document.
                                add_tax_to_document:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    If `generate_document` is turned on, will
                                    add taxes to document.
                                do_not_charge_subscription:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Subscription will be invoiced but not
                                    charged (invoices/documents will be settled
                                    directly).
                                invoice_custom_note:
                                  type:
                                    - string
                                    - 'null'
                                  description: >-
                                    Default custom note added to invoices
                                    generated by the subscription.
                                invoice_schedule:
                                  type:
                                    - string
                                    - 'null'
                                  enum:
                                    - period_start
                                    - period_end
                                  description: >

                                    Defines when invoices are generated relative
                                    to the billing period.


                                    - `period_start`: Invoices are generated at
                                    the start of the billing period.

                                    - `period_end`: Invoices are generated at
                                    the end of the billing period.
                            - anyOf:
                                - type: object
                                  properties:
                                    phases:
                                      type: array
                                      items:
                                        type: object
                                        properties:
                                          name:
                                            type: string
                                            description: Name of the subscription phase.
                                            example: Initial term
                                          type:
                                            type: string
                                            enum:
                                              - setup
                                              - trial
                                              - standard
                                            default: standard
                                            description: >

                                              Type of subscription phase.


                                              - `setup`: The phase represents a
                                              non-recurring service setup period,
                                              often used before the actual recurring
                                              subscription begins.

                                              - `trial`: The phase represents a
                                              non-recurring trial period, often used
                                              to allow users to opt out or experience
                                              a free test.

                                              - `standard`: The phase represents a
                                              standard recurring billing.
                                            example: standard
                                          status:
                                            type: string
                                            enum:
                                              - finished
                                              - pending
                                            default: pending
                                            description: >

                                              Status of subscription phase.


                                              - `pending`: The phase is waiting to
                                              start (not started yet).

                                              - `active`: The phase is currently in
                                              progress.

                                              - `finished`: The phase has ended and is
                                              complete.
                                            example: pending
                                          order:
                                            type: number
                                            description: >-
                                              Order in which the phase is executed
                                              within all subscription phases.
                                            example: 0
                                          end_strategy:
                                            type: string
                                            enum:
                                              - manual
                                              - end_date
                                              - duration
                                              - contract_end_date
                                            description: >

                                              End strategy of subscription phase.


                                              - `manual`: The phase ends when a user
                                              manually stops it.

                                              - `end_date`: The phase ends on a
                                              specified date.

                                              - `duration`: The phase ends after a
                                              specific relative duration.

                                              - `contract_end_date`: The phase ends on
                                              the end date of the related subscription
                                              contract.
                                            example: duration
                                          duration:
                                            type: object
                                            properties:
                                              period:
                                                type: string
                                                enum:
                                                  - days
                                                  - weeks
                                                  - months
                                                  - years
                                              count:
                                                type: integer
                                                minimum: 1
                                                default: 1
                                            required:
                                              - period
                                            description: >-
                                              Interval over which the subscription
                                              phase spans. Only applies to `duration`
                                              end strategy.
                                            example:
                                              count: 1
                                              period: years
                                          billing_date_setting:
                                            type: string
                                            enum:
                                              - phase_start
                                              - specific_date
                                            description: >

                                              Represents when the first billing date
                                              occurs.


                                              - `phase_start`: Aligns with the start
                                              of the phase.

                                              - `specific_date`: Occurs on a specified
                                              date.
                                            example: phase_start
                                          initial_billing_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Date when the subscription phase will
                                              start being billed. Only applies to
                                              `specific_date` billing date setting.
                                              UTC date time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          starts_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Actual start date of the phase. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          ends_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Actual end date of the phase. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          billing_cycle_alignment:
                                            type: string
                                            enum:
                                              - calendar_period
                                              - anniversary
                                            description: >

                                              Alignment of product billing cycles. If
                                              omitted at creation, the billing cycles
                                              alignment configured in the account
                                              subscription settings applies.


                                              - `calendar_period`: The billing cycles
                                              of the products will be aligned on the
                                              calendar period, after the first period
                                              which will be invoiced taking into
                                              account the prorata of the first cycle
                                              compared to the product periodicity.

                                              - `anniversary`: The billing cycles of
                                              the products will be aligned on the
                                              anniversary of the phase initial billing
                                              date.
                                            example: anniversary
                                          do_not_invoice_phase:
                                            type: boolean
                                            default: false
                                            description: >-
                                              Indicates if the phase should be
                                              invoiced. If set to true, the phase will
                                              not generate any invoices.
                                            example: false
                                          minimum_invoice_fee:
                                            type:
                                              - number
                                              - 'null'
                                            minimum: 0
                                            description: >-
                                              Phase minimum fee in minor currency
                                              units, after discounts and before tax.
                                              Null disables it and clears the product
                                              selection.
                                            example: 10000
                                          minimum_invoice_fee_products:
                                            type:
                                              - array
                                              - 'null'
                                            items:
                                              type: string
                                            description: >-
                                              Catalog product IDs eligible for the
                                              phase minimum fee. Null or an empty list
                                              includes all billed debit products in
                                              the phase.
                                            example:
                                              - itm_aaaaaaaaaaaaaa
                                          transition_calculation_method:
                                            type: string
                                            enum:
                                              - prorata
                                              - pay_in_full
                                              - none
                                            default: prorata
                                            description: >

                                              Calculation method used when
                                              transitioning from one phase to the next
                                              one.


                                              - `prorata`: The prorated amount between
                                              the two phases relative to the end date
                                              (the transition date) must be paid.

                                              - `pay_in_full`: The full amount for the
                                              phase billing period must be paid.

                                              - `none`: No amount will need to be
                                              paid, phase will simply transition from
                                              one to the next.
                                            example: prorata
                                          transition_invoicing_schedule:
                                            type: string
                                            enum:
                                              - immediately
                                            default: immediately
                                            description: >

                                              Represents when the transition amount
                                              will be invoiced.


                                              - `immediately`: An invoice will be
                                              generated immediately with the
                                              corresponding amount.
                                            example: immediately
                                          products:
                                            type: array
                                            items:
                                              type: object
                                              properties:
                                                id:
                                                  type: string
                                                  description: Product ID.
                                                  example: itm_FJKlqUb8COXw55
                                                catalog_version_id:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  description: >-
                                                    ID of a published catalog version to
                                                    price this product from, instead of the
                                                    live products catalog. Ignored when
                                                    `price` or `prices` is set. The product
                                                    must be priced in that version.
                                                  example: pcv_9x8v7u6t5s4r
                                                price_configuration_id:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  description: >-
                                                    ID of the product's price configuration
                                                    to price this product from, instead of
                                                    the one the catalog rules select. It
                                                    must be a live base configuration of the
                                                    product (not archived or replaced by a
                                                    later catalog publish, and not specific
                                                    to a customer, price book, customer
                                                    segment or plan), in the subscription's
                                                    currency. Requires `payment_interval`,
                                                    which it must match. The configuration's
                                                    country and commitment restrictions are
                                                    not checked. With a pinned catalog
                                                    version, the product is priced from that
                                                    version's copy of the configuration, and
                                                    a configuration the version doesn't
                                                    price returns a 400. Cannot be combined
                                                    with `price`, `prices` or `plan_id`.
                                                  example: prc_8f3kXODIM1sBwB
                                                name:
                                                  type: string
                                                  description: >-
                                                    Product name. This will appear on the
                                                    final invoices.
                                                  example: Product name
                                                description:
                                                  type: string
                                                  description: >-
                                                    Product description. This will appear on
                                                    the final invoices.
                                                  example: A description of the product.
                                                description_display_interval_dates:
                                                  type: boolean
                                                  default: false
                                                  description: >-
                                                    Indicates if the dates of the interval
                                                    should be automatically added in the
                                                    product description on the invoices.
                                                payment_interval:
                                                  anyOf:
                                                    - type: object
                                                      properties:
                                                        period:
                                                          type: string
                                                          enum:
                                                            - once
                                                      required:
                                                        - period
                                                      title: Once
                                                      example:
                                                        period: once
                                                    - type: object
                                                      properties:
                                                        period:
                                                          type: string
                                                          enum:
                                                            - days
                                                            - weeks
                                                            - months
                                                            - years
                                                        count:
                                                          type: integer
                                                          minimum: 1
                                                          default: 1
                                                      required:
                                                        - period
                                                      title: Period
                                                      example:
                                                        period: months
                                                        count: 1
                                                  description: >-
                                                    Interval on which the product is billed.
                                                    This interval can be different between
                                                    products and can differ from the
                                                    subscription commitment interval.
                                                payment_schedule:
                                                  type: string
                                                  enum:
                                                    - start
                                                    - end
                                                  description: >-
                                                    Indicates if the product should be
                                                    billed at the start or the end of the
                                                    payment interval.
                                                  example: start
                                                price:
                                                  type: object
                                                  properties:
                                                    type:
                                                      type: string
                                                      enum:
                                                        - fee
                                                    amount:
                                                      type: number
                                                      description: >-
                                                        Monetary amount. Expressed in currency's
                                                        smallest unit.
                                                  required:
                                                    - type
                                                    - amount
                                                  description: >-
                                                    Similar to `prices`, allow to apply a
                                                    single fee price more easily.
                                                  example:
                                                    type: fee
                                                    amount: 200
                                                prices:
                                                  type: array
                                                  items:
                                                    oneOf:
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - fee
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount. Expressed in currency's
                                                              smallest unit.
                                                        required:
                                                          - type
                                                          - amount
                                                        title: Fee price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - volume
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                          from:
                                                            type: number
                                                            description: From limit.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          on_tier_incomplete:
                                                            type:
                                                              - string
                                                              - 'null'
                                                            enum:
                                                              - pro_rata
                                                              - pay_in_full
                                                              - do_not_charge
                                                              - flat_per_tier
                                                            default: pro_rata
                                                            description: >-

                                                              Logic used to compute the amount when
                                                              usage on the tier is incomplete.


                                                              - `pro_rata`: The amount is computed
                                                              using the pro rata of the tier's
                                                              consumption.

                                                              - `pay_in_full`: The amount corresponds
                                                              to the full payment of the tier.

                                                              - `do_not_charge`: The tier is not
                                                              charged and ignored.

                                                              - `flat_per_tier`: The tier's `amount`
                                                              is a flat fee, billed once as soon as
                                                              usage reaches the tier, whatever the
                                                              number of units in it. `unitCount` is
                                                              ignored. No usage bills nothing.
                                                                
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                          - from
                                                          - to
                                                        title: Volume price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - packaged
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                          from:
                                                            type: number
                                                            description: From limit.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          on_bucket_incomplete:
                                                            type:
                                                              - string
                                                              - 'null'
                                                            enum:
                                                              - pro_rata
                                                              - pay_in_full
                                                              - do_not_charge
                                                              - flat_per_tier
                                                            default: pro_rata
                                                            description: >-

                                                              Logic used to compute the amount when
                                                              usage reaches an incomplete bucket (the
                                                              bucket size corresponds to the
                                                              `unitCount`).

                                                                - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                                - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                                - `do_not_charge`: The bucket is not charged and ignored.
                                                                - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                                  
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                          - from
                                                          - to
                                                        title: Packaged price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - bulk
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          on_tier_incomplete:
                                                            type:
                                                              - string
                                                              - 'null'
                                                            enum:
                                                              - pro_rata
                                                              - pay_in_full
                                                              - do_not_charge
                                                              - flat_per_tier
                                                            default: pro_rata
                                                            description: >-

                                                              Logic used to compute the amount when
                                                              usage on the tier is incomplete.


                                                              - `pro_rata`: The amount is computed
                                                              using the pro rata of the tier's
                                                              consumption.

                                                              - `pay_in_full`: The amount corresponds
                                                              to the full payment of the tier.

                                                              - `do_not_charge`: The tier is not
                                                              charged and ignored.

                                                              - `flat_per_tier`: The tier's `amount`
                                                              is a flat fee, billed once as soon as
                                                              usage reaches the tier, whatever the
                                                              number of units in it. `unitCount` is
                                                              ignored. No usage bills nothing.
                                                                
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                          - to
                                                        title: Bulk price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - bps
                                                          from:
                                                            type: number
                                                            description: From limit.
                                                          to:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: To limit.
                                                          percentage:
                                                            type: number
                                                            description: >-
                                                              Percentage applied on each unit to
                                                              compute the usage.
                                                          per_unit_cap:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: >-
                                                              Maximum amount for one unit. Expressed
                                                              in currency's smallest unit.
                                                          per_unit_floor:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: >-
                                                              Minimum amount for one unit. Expressed
                                                              in currency's smallest unit.
                                                          per_unit_fee:
                                                            type:
                                                              - number
                                                              - 'null'
                                                            description: >-
                                                              Fee amount applied per unit. Expressed
                                                              in currency's smallest unit.
                                                          metering_filter:
                                                            allOf:
                                                              - $ref: '#/components/schemas/MeteringFilter'
                                                              - type: object
                                                                description: >-
                                                                  Metering filter that scopes which
                                                                  billable events are eligible for this
                                                                  price tier. Only present when the price
                                                                  is filtered.
                                                        required:
                                                          - type
                                                          - from
                                                          - to
                                                          - percentage
                                                          - per_unit_cap
                                                          - per_unit_floor
                                                          - per_unit_fee
                                                        title: BPS price
                                                      - type: object
                                                        properties:
                                                          type:
                                                            type: string
                                                            enum:
                                                              - bundle
                                                          amount:
                                                            type: number
                                                            description: >-
                                                              Monetary amount of the price for the
                                                              number of units defined by `unit_count`.
                                                              Expressed in currency's smallest unit.
                                                          unit_count:
                                                            type: number
                                                            description: >-
                                                              Number of units considered for the
                                                              amount.
                                                        required:
                                                          - type
                                                          - amount
                                                          - unit_count
                                                        title: Bundle price
                                                        description: >-
                                                          For seat products only, if you are
                                                          looking for credits, use a fee price
                                                  description: >-
                                                    Prices of the product. If not specified,
                                                    the matching prices (depending on the
                                                    currency, interval, etc) of the product
                                                    defined in the products catalog/plan are
                                                    used.
                                                  example:
                                                    - type: volume
                                                      from: 0
                                                      to: 20
                                                      amount: 200
                                                      unit_count: 1
                                                      on_tier_incomplete: null
                                                    - type: volume
                                                      from: 20
                                                      to: null
                                                      amount: 150
                                                      unit_count: 1
                                                      on_tier_incomplete: null
                                                count:
                                                  type: number
                                                  minimum: 1
                                                  description: >-
                                                    Number of product units. Only applies to
                                                    products of type `flat_fee`, `seat` or
                                                    `credit`.
                                                  example: 2
                                                unit_name:
                                                  type: string
                                                  description: >-
                                                    Product name. This will appear on the
                                                    final invoices. Only applies to products
                                                    of type `seat` or `usage`.
                                                  example: user
                                                min_committed_count:
                                                  type: number
                                                  minimum: 1
                                                  description: >-
                                                    Minimum of units committed. If usage is
                                                    less than this number, then this value
                                                    will be used. Only applies to products
                                                    of type `usage`.
                                                min_amount:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Minimum amount billed. If the final
                                                    computed amount from the usage for this
                                                    product is less than this amount, then
                                                    this value will be used. Only applies to
                                                    products of type `usage`.
                                                max_amount:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Maximum amount billed. If the final
                                                    computed amount from the usage for this
                                                    product is greater than this amount,
                                                    then this value will be used. Only
                                                    applies to products of type `usage`.
                                                charging_method:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - prorata
                                                    - pay_in_full
                                                    - do_not_charge
                                                  description: >-
                                                    Charging method for seat count updates
                                                    within the current billing period. Only
                                                    applies to connected seat products.


                                                    - `prorata`: Price calculated
                                                    proportionally to time elapsed in the
                                                    billing period.

                                                    - `pay_in_full`: Price calculated for
                                                    the entire billing period.

                                                    - `do_not_charge`: No charge for the
                                                    update.
                                                seat_invoicing_schedule:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - immediately
                                                    - next_invoice
                                                    - custom
                                                  description: >

                                                    Policy defining when seat count changes
                                                    are invoiced. Only applies to connected
                                                    seat products.


                                                    - `immediately`: Seat changes are
                                                    invoiced immediately.

                                                    - `next_invoice`: Seat changes are
                                                    invoiced at the next invoice.

                                                    - `custom`: Seat changes are invoiced on
                                                    a custom schedule.
                                                metering_interval_type:
                                                  type: string
                                                  enum:
                                                    - subscription_commitment
                                                    - payment_interval
                                                    - full_database
                                                    - phase_duration
                                                    - custom
                                                  description: >-

                                                    Indicates on which type of interval the
                                                    usage should be aggregated.


                                                    - `subscription_commitment`: For the
                                                    usage contained within the subscription
                                                    commitment period.

                                                    - `payment_interval`: For the usage
                                                    contained within the payment interval of
                                                    the product.

                                                    - `full_database`: For all the usage we
                                                    ingested for this product, no matter the
                                                    period.

                                                    - `phase_duration`: For the usage
                                                    contained within the subscription phase.

                                                    - `custom`: For the usage contained
                                                    within a custom interval that starts
                                                    with the phase and renews independently
                                                    of the billing interval. Requires
                                                    `metering_interval` to be set.
                                                       Only applies to products of type `usage`.
                                                metering_interval:
                                                  type: object
                                                  properties:
                                                    period:
                                                      type: string
                                                      enum:
                                                        - days
                                                        - weeks
                                                        - months
                                                        - years
                                                    count:
                                                      type: integer
                                                      minimum: 1
                                                  required:
                                                    - period
                                                    - count
                                                  description: >-
                                                    Custom interval for usage aggregation.
                                                    Required when `metering_interval_type`
                                                    is `custom`. The interval starts at the
                                                    phase start and renews on its own cycle
                                                    (e.g. `{ period: 'months', count: 3 }`
                                                    for quarterly metering with monthly
                                                    billing). Only applies to products of
                                                    type `usage`.
                                                bill_usage_difference:
                                                  anyOf:
                                                    - type: boolean
                                                    - type: string
                                                      enum:
                                                        - 'true'
                                                        - 'false'
                                                  default: false
                                                  description: >-
                                                    Only bill the usage difference comparing
                                                    to the previous period (i.e. actual
                                                    amount minus last invoice amount).
                                                    Doesn't apply to `payment_interval`
                                                    metering interval type. Only applies to
                                                    products of type `usage`.
                                                children_usage_aggregation:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - sum
                                                    - max
                                                  description: >-

                                                    Controls whether a parent organization's
                                                    metered usage is billed on the combined
                                                    usage of the parent and its direct
                                                    children, and how per-member values are
                                                    combined.


                                                    - `null`: Organization-based usage is
                                                    disabled. Only the subscription
                                                    customer's own usage is billed.

                                                    - `sum`: The usage values of the parent
                                                    and each direct child are added together
                                                    (organization total).

                                                    - `max`: Only the single
                                                    highest-consuming member (parent or one
                                                    direct child) is billed.
                                                     Only applies to products of type `usage`.
                                                credits_expiration_in_days:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Validity in days for credits that will
                                                    be topped-up automatically. Once the
                                                    period has passed, they'll expire.
                                                expire_credits_at_end_of_period:
                                                  anyOf:
                                                    - type: boolean
                                                    - type: string
                                                      enum:
                                                        - 'true'
                                                        - 'false'
                                                  default: false
                                                  description: >-
                                                    Automatically set the expiration date to
                                                    the end of the next period for each
                                                    topup. Takes priority on
                                                    `creditsExpirationInDays`
                                                credits_balance_auto_creation_enabled:
                                                  anyOf:
                                                    - type: boolean
                                                    - type: string
                                                      enum:
                                                        - 'true'
                                                        - 'false'
                                                  description: >-
                                                    Whether to create the customer credit
                                                    balance as soon as the product is added
                                                    to the subscription. Defaults to the
                                                    credit product's
                                                    `credits_balance_auto_creation_enabled`
                                                    (`true` when unset). Set to `false` to
                                                    create the balance by hand before
                                                    activation, e.g. on quote-based renewals
                                                    where the balance must not start
                                                    consuming before signature; the first
                                                    top-up creates it if still missing.
                                                estimated_count:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  minimum: 0
                                                  maximum: 1000000000000
                                                  description: >-
                                                    Estimated number of units, for recurring
                                                    usage-based and connected seat products
                                                    (ignored on any other product, and not
                                                    priced for a usage-based product with
                                                    several filtered price groups). It
                                                    prices the quote value and is shown as
                                                    an estimate on the quote, but is never
                                                    billed: invoices use the measured usage
                                                    or seat count.
                                                  example: 200
                                              required:
                                                - id
                                            description: >-
                                              Products comprising the subscription
                                              phase.
                                          coupons:
                                            type: array
                                            items:
                                              allOf:
                                                - anyOf:
                                                    - type: object
                                                      properties:
                                                        id:
                                                          type: string
                                                          description: >-
                                                            ID of the catalog coupon to apply to the
                                                            subscription.
                                                      required:
                                                        - id
                                                      title: Existing coupon
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - amount
                                                        name:
                                                          type: string
                                                          description: Coupon name.
                                                        discount_amount:
                                                          type: number
                                                          exclusiveMinimum: 0
                                                          description: >-
                                                            Coupon discount amount. Expressed in
                                                            currency's smallest unit.
                                                      required:
                                                        - type
                                                        - discount_amount
                                                      title: Coupon amount
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - percent
                                                        name:
                                                          type: string
                                                          description: Coupon name.
                                                        discount_percent:
                                                          type: number
                                                          exclusiveMinimum: 0
                                                          maximum: 100
                                                          description: Coupon discount percentage.
                                                      required:
                                                        - type
                                                        - discount_percent
                                                      title: Coupon percent
                                                - type: object
                                                  properties:
                                                    repeat:
                                                      type:
                                                        - string
                                                        - 'null'
                                                      enum:
                                                        - once
                                                        - forever
                                                        - custom
                                                        - duration
                                                      description: >

                                                        Coupon frequency. Required for inline
                                                        coupons. Optional when an existing
                                                        coupon `id` is provided: if omitted,
                                                        defaults to the catalog coupon's repeat
                                                        value.


                                                        - `once`: Will apply the coupon only to
                                                        the first one invoice.

                                                        - `forever`: Will apply the coupon to
                                                        all invoices.

                                                        - `custom`: Will apply to coupon until a
                                                        specified expiration date.

                                                        - `duration`: Will apply the coupon for
                                                        a specific duration (e.g., 3 months).
                                                    duration_period:
                                                      type: string
                                                      enum:
                                                        - days
                                                        - weeks
                                                        - months
                                                        - years
                                                      description: >-
                                                        Period of time for which the coupon will
                                                        be applied. Only applies to the
                                                        `duration` coupon frequency.
                                                    duration_count:
                                                      type: number
                                                      description: >-
                                                        Number of periods for which the coupon
                                                        will be applied. Only applies to the
                                                        `duration` coupon frequency.
                                                    expires_at:
                                                      type: string
                                                      format: date-time
                                                      description: >-
                                                        Coupon expiration date. Only applies to
                                                        the `custom` coupon frequency. UTC date
                                                        time string in the [ISO
                                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                        format.
                                                      example: '2024-12-20T16:04:11Z'
                                                    apply_at:
                                                      type: string
                                                      format: date-time
                                                      description: >-
                                                        Coupon first application date. UTC date
                                                        time string in the [ISO
                                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                        format.
                                                      example: '2024-12-20T16:04:11Z'
                                                    product_ids:
                                                      type:
                                                        - array
                                                        - 'null'
                                                      items:
                                                        type: string
                                                      minItems: 1
                                                      description: >-
                                                        Products the coupon is scoped to on this
                                                        subscription, read together with
                                                        `product_scope`: the only discounted
                                                        products when `include`, the products
                                                        never discounted when `exclude`, null
                                                        when `all`. When sent without
                                                        `product_scope`, it is an `include`
                                                        list, except that a coupon already
                                                        stored as `exclude` keeps `exclude` when
                                                        its phase is updated; when empty or
                                                        omitted, the catalog coupon's scope is
                                                        copied.
                                                    product_scope:
                                                      type:
                                                        - string
                                                        - 'null'
                                                      enum:
                                                        - all
                                                        - include
                                                        - exclude
                                                      description: >-
                                                        Which products the coupon discounts on
                                                        this subscription. `all`: every product
                                                        (`product_ids` must be empty).
                                                        `include`: only the products in
                                                        `product_ids`. `exclude`: every product
                                                        except those in `product_ids` (lines
                                                        without a product stay discounted). When
                                                        sent, it replaces the catalog coupon's
                                                        scope together with `product_ids`. When
                                                        omitted, it is inferred: `include` if
                                                        `product_ids` is non-empty, else the
                                                        catalog coupon's scope. On a phase
                                                        update, a coupon already stored as
                                                        `exclude` keeps `exclude` when
                                                        `product_ids` is sent without
                                                        `product_scope`.
                                            description: >-
                                              Coupons comprising the subscription
                                              phase.
                                          activation_strategy:
                                            type: string
                                            enum:
                                              - manual
                                              - start_date
                                              - quote_signature
                                              - contract_start_date
                                              - previous_phase_end
                                            description: >

                                              Activation strategy of subscription
                                              phase.


                                              - `immediately`: The phase starts as
                                              soon as the subscription is activated.

                                              - `manual`: The phase starts when a user
                                              manually activates it.

                                              - `start_date`: The phase starts on a
                                              specified date.

                                              - `quote_signature`: The phase starts
                                              when the subscription quote is signed.

                                              - `checkout`: The phase starts when the
                                              subscription checkout is completed.

                                              - `contract_start_date`: The phase
                                              starts on the start date of the related
                                              subscription contract.

                                              - `previous_phase_end`: The phase starts
                                              when the previous phase ends.
                                            example: manual
                                        required:
                                          - end_strategy
                                          - billing_date_setting
                                          - products
                                          - activation_strategy
                                  required:
                                    - phases
                                  title: With phases
                                - allOf:
                                    - type: object
                                      properties:
                                        activation_strategy:
                                          type: string
                                          enum:
                                            - start_date
                                            - manually
                                            - quote
                                          default: manually
                                          description: >

                                            Strategy used to activate the
                                            subscription.


                                            - `start_date`: The subscription will
                                            become active on the specified start
                                            date. If the start date is in the past,
                                            it will be activated immediately.

                                            - `manually`: The subscription requires
                                            activation through a manual action.

                                            - `checkout`: The subscription will be
                                            activated once the checkout is
                                            completed, but only if the start date is
                                            in the past. Otherwise, activation will
                                            occur later on the specified start date.

                                            - `quote`: The subscription will be
                                            activated depending on the configuration
                                            and the signature of the related quote.
                                          example: start_date
                                        products:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              id:
                                                type: string
                                                description: Product ID.
                                                example: itm_FJKlqUb8COXw55
                                              catalog_version_id:
                                                type:
                                                  - string
                                                  - 'null'
                                                description: >-
                                                  ID of a published catalog version to
                                                  price this product from, instead of the
                                                  live products catalog. Ignored when
                                                  `price` or `prices` is set. The product
                                                  must be priced in that version.
                                                example: pcv_9x8v7u6t5s4r
                                              price_configuration_id:
                                                type:
                                                  - string
                                                  - 'null'
                                                description: >-
                                                  ID of the product's price configuration
                                                  to price this product from, instead of
                                                  the one the catalog rules select. It
                                                  must be a live base configuration of the
                                                  product (not archived or replaced by a
                                                  later catalog publish, and not specific
                                                  to a customer, price book, customer
                                                  segment or plan), in the subscription's
                                                  currency. Requires `payment_interval`,
                                                  which it must match. The configuration's
                                                  country and commitment restrictions are
                                                  not checked. With a pinned catalog
                                                  version, the product is priced from that
                                                  version's copy of the configuration, and
                                                  a configuration the version doesn't
                                                  price returns a 400. Cannot be combined
                                                  with `price`, `prices` or `plan_id`.
                                                example: prc_8f3kXODIM1sBwB
                                              name:
                                                type: string
                                                description: >-
                                                  Product name. This will appear on the
                                                  final invoices.
                                                example: Product name
                                              description:
                                                type: string
                                                description: >-
                                                  Product description. This will appear on
                                                  the final invoices.
                                                example: A description of the product.
                                              description_display_interval_dates:
                                                type: boolean
                                                default: false
                                                description: >-
                                                  Indicates if the dates of the interval
                                                  should be automatically added in the
                                                  product description on the invoices.
                                              payment_interval:
                                                anyOf:
                                                  - type: object
                                                    properties:
                                                      period:
                                                        type: string
                                                        enum:
                                                          - once
                                                    required:
                                                      - period
                                                    title: Once
                                                    example:
                                                      period: once
                                                  - type: object
                                                    properties:
                                                      period:
                                                        type: string
                                                        enum:
                                                          - days
                                                          - weeks
                                                          - months
                                                          - years
                                                      count:
                                                        type: integer
                                                        minimum: 1
                                                        default: 1
                                                    required:
                                                      - period
                                                    title: Period
                                                    example:
                                                      period: months
                                                      count: 1
                                                description: >-
                                                  Interval on which the product is billed.
                                                  This interval can be different between
                                                  products and can differ from the
                                                  subscription commitment interval.
                                              payment_schedule:
                                                type: string
                                                enum:
                                                  - start
                                                  - end
                                                description: >-
                                                  Indicates if the product should be
                                                  billed at the start or the end of the
                                                  payment interval.
                                                example: start
                                              price:
                                                type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - fee
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount. Expressed in currency's
                                                      smallest unit.
                                                required:
                                                  - type
                                                  - amount
                                                description: >-
                                                  Similar to `prices`, allow to apply a
                                                  single fee price more easily.
                                                example:
                                                  type: fee
                                                  amount: 200
                                              prices:
                                                type: array
                                                items:
                                                  oneOf:
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - fee
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount. Expressed in currency's
                                                            smallest unit.
                                                      required:
                                                        - type
                                                        - amount
                                                      title: Fee price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - volume
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                        from:
                                                          type: number
                                                          description: From limit.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        on_tier_incomplete:
                                                          type:
                                                            - string
                                                            - 'null'
                                                          enum:
                                                            - pro_rata
                                                            - pay_in_full
                                                            - do_not_charge
                                                            - flat_per_tier
                                                          default: pro_rata
                                                          description: >-

                                                            Logic used to compute the amount when
                                                            usage on the tier is incomplete.


                                                            - `pro_rata`: The amount is computed
                                                            using the pro rata of the tier's
                                                            consumption.

                                                            - `pay_in_full`: The amount corresponds
                                                            to the full payment of the tier.

                                                            - `do_not_charge`: The tier is not
                                                            charged and ignored.

                                                            - `flat_per_tier`: The tier's `amount`
                                                            is a flat fee, billed once as soon as
                                                            usage reaches the tier, whatever the
                                                            number of units in it. `unitCount` is
                                                            ignored. No usage bills nothing.
                                                              
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                        - from
                                                        - to
                                                      title: Volume price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - packaged
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                        from:
                                                          type: number
                                                          description: From limit.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        on_bucket_incomplete:
                                                          type:
                                                            - string
                                                            - 'null'
                                                          enum:
                                                            - pro_rata
                                                            - pay_in_full
                                                            - do_not_charge
                                                            - flat_per_tier
                                                          default: pro_rata
                                                          description: >-

                                                            Logic used to compute the amount when
                                                            usage reaches an incomplete bucket (the
                                                            bucket size corresponds to the
                                                            `unitCount`).

                                                              - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                              - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                              - `do_not_charge`: The bucket is not charged and ignored.
                                                              - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                                
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                        - from
                                                        - to
                                                      title: Packaged price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - bulk
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        on_tier_incomplete:
                                                          type:
                                                            - string
                                                            - 'null'
                                                          enum:
                                                            - pro_rata
                                                            - pay_in_full
                                                            - do_not_charge
                                                            - flat_per_tier
                                                          default: pro_rata
                                                          description: >-

                                                            Logic used to compute the amount when
                                                            usage on the tier is incomplete.


                                                            - `pro_rata`: The amount is computed
                                                            using the pro rata of the tier's
                                                            consumption.

                                                            - `pay_in_full`: The amount corresponds
                                                            to the full payment of the tier.

                                                            - `do_not_charge`: The tier is not
                                                            charged and ignored.

                                                            - `flat_per_tier`: The tier's `amount`
                                                            is a flat fee, billed once as soon as
                                                            usage reaches the tier, whatever the
                                                            number of units in it. `unitCount` is
                                                            ignored. No usage bills nothing.
                                                              
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                        - to
                                                      title: Bulk price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - bps
                                                        from:
                                                          type: number
                                                          description: From limit.
                                                        to:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: To limit.
                                                        percentage:
                                                          type: number
                                                          description: >-
                                                            Percentage applied on each unit to
                                                            compute the usage.
                                                        per_unit_cap:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: >-
                                                            Maximum amount for one unit. Expressed
                                                            in currency's smallest unit.
                                                        per_unit_floor:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: >-
                                                            Minimum amount for one unit. Expressed
                                                            in currency's smallest unit.
                                                        per_unit_fee:
                                                          type:
                                                            - number
                                                            - 'null'
                                                          description: >-
                                                            Fee amount applied per unit. Expressed
                                                            in currency's smallest unit.
                                                        metering_filter:
                                                          allOf:
                                                            - $ref: '#/components/schemas/MeteringFilter'
                                                            - type: object
                                                              description: >-
                                                                Metering filter that scopes which
                                                                billable events are eligible for this
                                                                price tier. Only present when the price
                                                                is filtered.
                                                      required:
                                                        - type
                                                        - from
                                                        - to
                                                        - percentage
                                                        - per_unit_cap
                                                        - per_unit_floor
                                                        - per_unit_fee
                                                      title: BPS price
                                                    - type: object
                                                      properties:
                                                        type:
                                                          type: string
                                                          enum:
                                                            - bundle
                                                        amount:
                                                          type: number
                                                          description: >-
                                                            Monetary amount of the price for the
                                                            number of units defined by `unit_count`.
                                                            Expressed in currency's smallest unit.
                                                        unit_count:
                                                          type: number
                                                          description: >-
                                                            Number of units considered for the
                                                            amount.
                                                      required:
                                                        - type
                                                        - amount
                                                        - unit_count
                                                      title: Bundle price
                                                      description: >-
                                                        For seat products only, if you are
                                                        looking for credits, use a fee price
                                                description: >-
                                                  Prices of the product. If not specified,
                                                  the matching prices (depending on the
                                                  currency, interval, etc) of the product
                                                  defined in the products catalog/plan are
                                                  used.
                                                example:
                                                  - type: volume
                                                    from: 0
                                                    to: 20
                                                    amount: 200
                                                    unit_count: 1
                                                    on_tier_incomplete: null
                                                  - type: volume
                                                    from: 20
                                                    to: null
                                                    amount: 150
                                                    unit_count: 1
                                                    on_tier_incomplete: null
                                              count:
                                                type: number
                                                minimum: 1
                                                description: >-
                                                  Number of product units. Only applies to
                                                  products of type `flat_fee`, `seat` or
                                                  `credit`.
                                                example: 2
                                              unit_name:
                                                type: string
                                                description: >-
                                                  Product name. This will appear on the
                                                  final invoices. Only applies to products
                                                  of type `seat` or `usage`.
                                                example: user
                                              min_committed_count:
                                                type: number
                                                minimum: 1
                                                description: >-
                                                  Minimum of units committed. If usage is
                                                  less than this number, then this value
                                                  will be used. Only applies to products
                                                  of type `usage`.
                                              min_amount:
                                                type:
                                                  - number
                                                  - 'null'
                                                description: >-
                                                  Minimum amount billed. If the final
                                                  computed amount from the usage for this
                                                  product is less than this amount, then
                                                  this value will be used. Only applies to
                                                  products of type `usage`.
                                              max_amount:
                                                type:
                                                  - number
                                                  - 'null'
                                                description: >-
                                                  Maximum amount billed. If the final
                                                  computed amount from the usage for this
                                                  product is greater than this amount,
                                                  then this value will be used. Only
                                                  applies to products of type `usage`.
                                              charging_method:
                                                type:
                                                  - string
                                                  - 'null'
                                                enum:
                                                  - prorata
                                                  - pay_in_full
                                                  - do_not_charge
                                                description: >-
                                                  Charging method for seat count updates
                                                  within the current billing period. Only
                                                  applies to connected seat products.


                                                  - `prorata`: Price calculated
                                                  proportionally to time elapsed in the
                                                  billing period.

                                                  - `pay_in_full`: Price calculated for
                                                  the entire billing period.

                                                  - `do_not_charge`: No charge for the
                                                  update.
                                              seat_invoicing_schedule:
                                                type:
                                                  - string
                                                  - 'null'
                                                enum:
                                                  - immediately
                                                  - next_invoice
                                                  - custom
                                                description: >

                                                  Policy defining when seat count changes
                                                  are invoiced. Only applies to connected
                                                  seat products.


                                                  - `immediately`: Seat changes are
                                                  invoiced immediately.

                                                  - `next_invoice`: Seat changes are
                                                  invoiced at the next invoice.

                                                  - `custom`: Seat changes are invoiced on
                                                  a custom schedule.
                                              metering_interval_type:
                                                type: string
                                                enum:
                                                  - subscription_commitment
                                                  - payment_interval
                                                  - full_database
                                                  - phase_duration
                                                  - custom
                                                description: >-

                                                  Indicates on which type of interval the
                                                  usage should be aggregated.


                                                  - `subscription_commitment`: For the
                                                  usage contained within the subscription
                                                  commitment period.

                                                  - `payment_interval`: For the usage
                                                  contained within the payment interval of
                                                  the product.

                                                  - `full_database`: For all the usage we
                                                  ingested for this product, no matter the
                                                  period.

                                                  - `phase_duration`: For the usage
                                                  contained within the subscription phase.

                                                  - `custom`: For the usage contained
                                                  within a custom interval that starts
                                                  with the phase and renews independently
                                                  of the billing interval. Requires
                                                  `metering_interval` to be set.
                                                     Only applies to products of type `usage`.
                                              metering_interval:
                                                type: object
                                                properties:
                                                  period:
                                                    type: string
                                                    enum:
                                                      - days
                                                      - weeks
                                                      - months
                                                      - years
                                                  count:
                                                    type: integer
                                                    minimum: 1
                                                required:
                                                  - period
                                                  - count
                                                description: >-
                                                  Custom interval for usage aggregation.
                                                  Required when `metering_interval_type`
                                                  is `custom`. The interval starts at the
                                                  phase start and renews on its own cycle
                                                  (e.g. `{ period: 'months', count: 3 }`
                                                  for quarterly metering with monthly
                                                  billing). Only applies to products of
                                                  type `usage`.
                                              bill_usage_difference:
                                                anyOf:
                                                  - type: boolean
                                                  - type: string
                                                    enum:
                                                      - 'true'
                                                      - 'false'
                                                default: false
                                                description: >-
                                                  Only bill the usage difference comparing
                                                  to the previous period (i.e. actual
                                                  amount minus last invoice amount).
                                                  Doesn't apply to `payment_interval`
                                                  metering interval type. Only applies to
                                                  products of type `usage`.
                                              children_usage_aggregation:
                                                type:
                                                  - string
                                                  - 'null'
                                                enum:
                                                  - sum
                                                  - max
                                                description: >-

                                                  Controls whether a parent organization's
                                                  metered usage is billed on the combined
                                                  usage of the parent and its direct
                                                  children, and how per-member values are
                                                  combined.


                                                  - `null`: Organization-based usage is
                                                  disabled. Only the subscription
                                                  customer's own usage is billed.

                                                  - `sum`: The usage values of the parent
                                                  and each direct child are added together
                                                  (organization total).

                                                  - `max`: Only the single
                                                  highest-consuming member (parent or one
                                                  direct child) is billed.
                                                   Only applies to products of type `usage`.
                                              credits_expiration_in_days:
                                                type:
                                                  - number
                                                  - 'null'
                                                description: >-
                                                  Validity in days for credits that will
                                                  be topped-up automatically. Once the
                                                  period has passed, they'll expire.
                                              expire_credits_at_end_of_period:
                                                anyOf:
                                                  - type: boolean
                                                  - type: string
                                                    enum:
                                                      - 'true'
                                                      - 'false'
                                                default: false
                                                description: >-
                                                  Automatically set the expiration date to
                                                  the end of the next period for each
                                                  topup. Takes priority on
                                                  `creditsExpirationInDays`
                                              credits_balance_auto_creation_enabled:
                                                anyOf:
                                                  - type: boolean
                                                  - type: string
                                                    enum:
                                                      - 'true'
                                                      - 'false'
                                                description: >-
                                                  Whether to create the customer credit
                                                  balance as soon as the product is added
                                                  to the subscription. Defaults to the
                                                  credit product's
                                                  `credits_balance_auto_creation_enabled`
                                                  (`true` when unset). Set to `false` to
                                                  create the balance by hand before
                                                  activation, e.g. on quote-based renewals
                                                  where the balance must not start
                                                  consuming before signature; the first
                                                  top-up creates it if still missing.
                                              estimated_count:
                                                type:
                                                  - number
                                                  - 'null'
                                                minimum: 0
                                                maximum: 1000000000000
                                                description: >-
                                                  Estimated number of units, for recurring
                                                  usage-based and connected seat products
                                                  (ignored on any other product, and not
                                                  priced for a usage-based product with
                                                  several filtered price groups). It
                                                  prices the quote value and is shown as
                                                  an estimate on the quote, but is never
                                                  billed: invoices use the measured usage
                                                  or seat count.
                                                example: 200
                                            required:
                                              - id
                                          description: Products that make up the subscription.
                                        coupons:
                                          type: array
                                          items:
                                            allOf:
                                              - anyOf:
                                                  - type: object
                                                    properties:
                                                      id:
                                                        type: string
                                                        description: >-
                                                          ID of the catalog coupon to apply to the
                                                          subscription.
                                                    required:
                                                      - id
                                                    title: Existing coupon
                                                  - type: object
                                                    properties:
                                                      type:
                                                        type: string
                                                        enum:
                                                          - amount
                                                      name:
                                                        type: string
                                                        description: Coupon name.
                                                      discount_amount:
                                                        type: number
                                                        exclusiveMinimum: 0
                                                        description: >-
                                                          Coupon discount amount. Expressed in
                                                          currency's smallest unit.
                                                    required:
                                                      - type
                                                      - discount_amount
                                                    title: Coupon amount
                                                  - type: object
                                                    properties:
                                                      type:
                                                        type: string
                                                        enum:
                                                          - percent
                                                      name:
                                                        type: string
                                                        description: Coupon name.
                                                      discount_percent:
                                                        type: number
                                                        exclusiveMinimum: 0
                                                        maximum: 100
                                                        description: Coupon discount percentage.
                                                    required:
                                                      - type
                                                      - discount_percent
                                                    title: Coupon percent
                                              - type: object
                                                properties:
                                                  repeat:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - once
                                                      - forever
                                                      - custom
                                                      - duration
                                                    description: >

                                                      Coupon frequency. Required for inline
                                                      coupons. Optional when an existing
                                                      coupon `id` is provided: if omitted,
                                                      defaults to the catalog coupon's repeat
                                                      value.


                                                      - `once`: Will apply the coupon only to
                                                      the first one invoice.

                                                      - `forever`: Will apply the coupon to
                                                      all invoices.

                                                      - `custom`: Will apply to coupon until a
                                                      specified expiration date.

                                                      - `duration`: Will apply the coupon for
                                                      a specific duration (e.g., 3 months).
                                                  duration_period:
                                                    type: string
                                                    enum:
                                                      - days
                                                      - weeks
                                                      - months
                                                      - years
                                                    description: >-
                                                      Period of time for which the coupon will
                                                      be applied. Only applies to the
                                                      `duration` coupon frequency.
                                                  duration_count:
                                                    type: number
                                                    description: >-
                                                      Number of periods for which the coupon
                                                      will be applied. Only applies to the
                                                      `duration` coupon frequency.
                                                  expires_at:
                                                    type: string
                                                    format: date-time
                                                    description: >-
                                                      Coupon expiration date. Only applies to
                                                      the `custom` coupon frequency. UTC date
                                                      time string in the [ISO
                                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                      format.
                                                    example: '2024-12-20T16:04:11Z'
                                                  apply_at:
                                                    type: string
                                                    format: date-time
                                                    description: >-
                                                      Coupon first application date. UTC date
                                                      time string in the [ISO
                                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                      format.
                                                    example: '2024-12-20T16:04:11Z'
                                                  product_ids:
                                                    type:
                                                      - array
                                                      - 'null'
                                                    items:
                                                      type: string
                                                    minItems: 1
                                                    description: >-
                                                      Products the coupon is scoped to on this
                                                      subscription, read together with
                                                      `product_scope`: the only discounted
                                                      products when `include`, the products
                                                      never discounted when `exclude`, null
                                                      when `all`. When sent without
                                                      `product_scope`, it is an `include`
                                                      list, except that a coupon already
                                                      stored as `exclude` keeps `exclude` when
                                                      its phase is updated; when empty or
                                                      omitted, the catalog coupon's scope is
                                                      copied.
                                                  product_scope:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - all
                                                      - include
                                                      - exclude
                                                    description: >-
                                                      Which products the coupon discounts on
                                                      this subscription. `all`: every product
                                                      (`product_ids` must be empty).
                                                      `include`: only the products in
                                                      `product_ids`. `exclude`: every product
                                                      except those in `product_ids` (lines
                                                      without a product stay discounted). When
                                                      sent, it replaces the catalog coupon's
                                                      scope together with `product_ids`. When
                                                      omitted, it is inferred: `include` if
                                                      `product_ids` is non-empty, else the
                                                      catalog coupon's scope. On a phase
                                                      update, a coupon already stored as
                                                      `exclude` keeps `exclude` when
                                                      `product_ids` is sent without
                                                      `product_scope`.
                                          description: >-
                                            Coupons to be applied to the prices of
                                            subscription products.
                                    - type: object
                                      properties:
                                        trial:
                                          type: object
                                          properties:
                                            end_strategy:
                                              type: string
                                              enum:
                                                - manual
                                                - end_date
                                                - duration
                                              description: Defines how the free trial will end.
                                            starts_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Free trial start date. UTC date time
                                                string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            ends_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Free trial end date. Only applies if the
                                                end strategy is `end_date`. UTC date
                                                time string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            duration:
                                              type: object
                                              properties:
                                                period:
                                                  type: string
                                                  enum:
                                                    - days
                                                    - weeks
                                                    - months
                                                    - years
                                                  description: >-
                                                    Free trial duration period. Only applies
                                                    if the end strategy is `duration`.
                                                count:
                                                  type: number
                                                  minimum: 1
                                                  description: >-
                                                    Free trial duration count. Only applies
                                                    if the end strategy is `duration`.
                                              required:
                                                - period
                                                - count
                                          required:
                                            - end_strategy
                                          description: >-
                                            Create a free trial phase based on the
                                            plan configuration. Only applies if a
                                            `plan_id` is provided.
                                  title: Without phases
                            - type: object
                              properties:
                                plan_id:
                                  type: string
                                  description: Deprecated field, please use `template_id`.
                                  example: plan_zHmjoDee4ZRmQV
                                  deprecated: true
                                template_id:
                                  type: string
                                  description: >-
                                    ID of the template that the subscription is
                                    linked to.
                                  example: subt_7gdusOkqr5L0B8
                                template_configuration_id:
                                  type: string
                                  description: >-
                                    ID of the template configuration that the
                                    subscription is linked to.
                                  example: subtc_7mHWOlPStUogvp
                          description: Subscription configuration constituting the quote.
                      required:
                        - expires_at
                        - subscription
                      title: Subscription
                    - type: object
                      properties:
                        expires_at:
                          type: string
                          format: date-time
                          description: >-
                            Quote expiration date. UTC date time string in the
                            [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-04-28T14:12:09.293Z'
                        subscription_update:
                          $ref: '#/components/schemas/CreateQuoteSubscriptionUpdate'
                      required:
                        - expires_at
                        - subscription_update
                      title: Subscription update
                    - type: object
                      properties:
                        expires_at:
                          type: string
                          format: date-time
                          description: >-
                            Quote expiration date. UTC date time string in the
                            [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-04-28T14:12:09.293Z'
                        invoice:
                          $ref: '#/components/schemas/CreateQuoteInvoice'
                      required:
                        - expires_at
                        - invoice
                      title: One-off invoice
                - type: object
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreatedQuote'
      security:
        - bearer: []
components:
  schemas:
    CreateQuote:
      allOf:
        - type: object
          properties:
            status:
              type: string
              enum:
                - draft
                - approved
                - pending_signature
              description: >-

                Quote status.


                - `draft`: The quote is a draft.

                - `approved`: The quote is approved and ready to be sent to the
                customer.

                - `pending_signature`: The quote is awaiting the customer's
                signature.
                  
              example: draft
            owner_email:
              type: string
              format: email
              description: >-
                Email address of the Hyperline user acting as the quote owner.
                The user must be a member of your Hyperline account. The owner
                requests approval when the quote is finalized using an API key
                or finalized during creation. If not specified, the Hyperline
                account owner will be assigned.
              example: joe@acme.com
            customer_id:
              type: string
              description: ID of the customer the quote is addressed to.
              example: cus_QalW2vTAdkR6IY
            invoicing_entity_id:
              type: string
              description: ID of the invoicing entity attached to the quote.
              example: ive_47484fjdhy5
            catalog_version_id:
              type:
                - string
                - 'null'
              description: >-
                ID of a published catalog version to price every product of the
                quote from, instead of the live products catalog. A product's
                own `catalog_version_id` takes precedence, and explicit `prices`
                always win over both.
              example: pcv_9x8v7u6t5s4r
            comments:
              type: string
              description: Custom comments displayed on the quote.
              example: Please find the contract and subscription details we discussed.
            terms:
              type: string
              description: Custom quotation terms.
              example: >-
                By signing this quote, you accept our conditions of use for the
                use of our products and services.
            amount:
              type:
                - number
                - 'null'
              description: >-
                Estimated contract value. When computed, a subscription phase
                with neither an end date nor a fixed duration is counted over a
                conventional horizon: the contract's length for a single phase
                on a contract that has one, otherwise 12 months or the longest
                billing interval if longer. That horizon is not an end date: the
                subscription can run past it. Usage-based and connected seat
                lines are priced at their estimated quantity when it exceeds the
                committed quantity and, for seats, the live seat count. For
                subscription quotes, defaults to the computed subscription value
                if not specified. For one-off quotes, this field is ignored —
                the amount is always derived from the linked invoice's
                `amount_excluding_tax`.
              example: 20000
            contract_value:
              type:
                - number
                - 'null'
              description: >-
                What the customer pays over the contract, each coupon counted on
                the invoices it applies to. Computed from the subscription for
                `subscription` and `subscription_update` quotes, unless set
                manually. Not set on `one_off` quotes. When specified, overrides
                the computed value.
              example: 18000
            collect_payment_details:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: >-
                Collect customer payment method mandate during signature flow or
                not.
              example: true
            collect_custom_property_ids:
              type: array
              items:
                type: string
              description: >-
                IDs of the customer custom properties required to be filled
                during the signature flow.
              example: []
            contract_clause_ids:
              type: array
              items:
                type: string
              description: IDs of the contract clauses used in the quote terms.
              example:
                - ccl_QalW2vTAdkR6IY
            require_tax_id:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: >-
                Require the customer to provide a tax ID during the signature
                flow.
              example: false
            custom_properties:
              type: object
              additionalProperties:
                anyOf:
                  - type: string
                  - type: number
                  - type: boolean
                  - type: string
                    format: date-time
                    description: >-
                      UTC date time string in the [ISO
                      8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                    example: '2024-12-20T16:04:11Z'
                  - type: array
                    items:
                      type: string
                  - type: 'null'
              description: >-
                Custom property values set on the quote itself, keyed by slug.
                Custom property values of a quote's subscription are returned on
                the subscription.
            display_quote_value:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: Display the total quote value on the quote.
              example: true
            display_quote_value_with_tax:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: Display the total quote value including tax on the quote.
              example: false
            display_taxes:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: Display tax breakdown on the quote.
              example: true
            display_price_tiers:
              anyOf:
                - type: string
                  enum:
                    - all
                    - matching
                    - none
                    - unit_price
                - anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - 'true'
                        - 'false'
              description: >
                Controls which price tiers are displayed on the quote.


                - `all`: Display all pricing tiers.

                - `matching`: Only display the tiers used to compute the price
                based on quantity.

                - `none`: Hide all pricing tiers.

                - `unit_price`: Show only the unit price, without tiers.
              example: matching
            display_phase_value:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: Display per-phase value breakdown on the quote.
              example: false
            display_discounts_on_total:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: >-
                Display discounts on the totals, with product prices before
                discount. Totals then follow the contract value, so discounts
                with a limited duration are included.
              example: false
            display_first_invoice_amount:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: Display the first invoice amount on the quote.
              example: false
            display_documents_in_preview:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: Display attached documents in the quote preview.
              example: false
            subscription_update_display:
              type: string
              enum:
                - quote_update_details
                - subscription_details
                - both
              description: >-
                Sections displayed on subscription update quotes:
                quote_update_details, subscription_details, or both. Takes
                precedence over display_subscription_on_update.
              example: quote_update_details
            display_subscription_on_update:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              deprecated: true
              description: >-
                Deprecated. Use subscription_update_display. False displays
                quote update details; true displays both sections.
              example: false
            generate_draft_invoices:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: >-
                When `true`, the invoice issued after signature stays in `draft`
                status instead of being emitted for payment. Use this when you
                want to review the final invoice manually before sending it.
                Defaults to `false`.
              example: false
            automatically_start_subscription:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: >-
                Deprecated field, please use the phase activation strategy
                `quote_signature` instead.
              example: true
              deprecated: true
          required:
            - customer_id
        - anyOf:
            - type: object
              properties:
                template_id:
                  type: string
                  description: >-
                    ID of the quote template the quote is built from. If not
                    specified, a subscription configuration or an `invoice`
                    payload must be defined.
                  example: quot_9hNWq4c84Z146W
                expires_at:
                  type: string
                  format: date-time
                  description: >-
                    Quote expiration date. UTC date time string in the [ISO
                    8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                  example: '2024-04-28T14:12:09.293Z'
                subscription:
                  allOf:
                    - type: object
                      properties:
                        name:
                          type: string
                          description: Subscription custom name.
                        purchase_order:
                          type: string
                          description: Reference to the purchase order.
                        invoicing_entity_id:
                          type: string
                          description: >-
                            ID of the invoicing entity attached to the
                            subscription. If not defined, fallback to customer's
                            invoicing entity.
                          example: ive_jerrb484RHn
                        crm_opportunity_id:
                          type: string
                          description: >-
                            ID of the related opportunity/deal in the connected
                            CRM.
                        commitment_interval:
                          type: object
                          properties:
                            period:
                              type: string
                              enum:
                                - days
                                - weeks
                                - months
                                - years
                            count:
                              type: number
                              minimum: 1
                          required:
                            - period
                            - count
                          description: Deprecated field, please use `contract_terms`.
                          example:
                            period: years
                            count: 1
                          deprecated: true
                        renew_automatically:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          default: true
                          description: Deprecated field, please use `contract_terms`.
                          example: true
                          deprecated: true
                        renew_for:
                          type: object
                          properties:
                            period:
                              type: string
                              enum:
                                - days
                                - weeks
                                - months
                                - years
                            count:
                              type: number
                          required:
                            - period
                            - count
                          description: Deprecated field, please use `contract_terms`.
                          example:
                            period: years
                            count: 1
                          deprecated: true
                        minimum_invoice_fee:
                          type:
                            - number
                            - 'null'
                          description: >-
                            Minimum fee applied to each invoice outside of one
                            time payments.
                          example: 250
                        contract_terms:
                          allOf:
                            - type: object
                              properties:
                                starts_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Start date of the contract. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                ends_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    End date of the contract. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                duration:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: integer
                                      minimum: 1
                                      default: 1
                                  required:
                                    - period
                                  description: >-
                                    Interval over which the contract initially
                                    spans. Only applies to `duration` end
                                    strategy.
                                  example:
                                    count: 6
                                    period: months
                                renew_automatically:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >

                                    Indicates if the contract should be renewed
                                    automatically.


                                    - `true`: The contract will be renewed
                                    automatically.

                                    - `false`: The contract will not be renewed
                                    automatically.
                                  example: true
                                renew_for_duration:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: integer
                                      minimum: 1
                                      default: 1
                                  required:
                                    - period
                                  description: >

                                    Interval over which the contract will be
                                    renewed. Only applies if
                                    `renew_automatically` is true.
                                  example:
                                    count: 1
                                    period: years
                            - type: object
                              properties:
                                activation_strategy:
                                  type: string
                                  enum:
                                    - start_date
                                    - immediately
                                    - manual
                                    - quote_signature
                                    - checkout
                                  description: >

                                    Activation strategy of the contract.


                                    - `immediately`: The contract will be
                                    activated immediately.

                                    - `manual`: The contract will be activated
                                    when a user manually activates it.

                                    - `start_date`: The contract will be
                                    activated on a specified date.

                                    - `quote_signature`: The contract will be
                                    activated when the subscription quote is
                                    signed.

                                    - `checkout`: The contract will be activated
                                    when the subscription checkout is completed.
                                  example: start_date
                                end_strategy:
                                  type: string
                                  enum:
                                    - end_date
                                    - duration
                                    - manual
                                  description: >

                                    End strategy of contract.


                                    - `manual`: The contract ends when a user
                                    manually stops it.

                                    - `end_date`: The contract ends on a
                                    specified date.

                                    - `duration`: The contract ends after a
                                    specific relative duration, unless
                                    `renew_automatically` is true.
                                  example: duration
                              required:
                                - activation_strategy
                                - end_strategy
                          description: Contract terms linked to the subscription.
                        starts_at:
                          type: string
                          format: date-time
                          description: >-
                            Applies only if the activation strategy is
                            `start_date`. UTC date time string in the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        contract_start:
                          type: string
                          format: date-time
                          description: Deprecated field, please use `contract_terms`.
                          example: '2024-01-15T00:00:00Z'
                          deprecated: true
                        contract_end:
                          type: string
                          format: date-time
                          description: Deprecated field, please use `contract_terms`.
                          example: '2025-01-15T00:00:00Z'
                          deprecated: true
                        initial_billing_at:
                          type: string
                          format: date-time
                          description: >-
                            Date when the subscription will start being billed.
                            If not specified, it will correspond to the
                            `starts_at` date. UTC date time string in the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        payment_method_id:
                          type: string
                          description: >-
                            ID of the customer's payment method used to pay the
                            subscription's invoices, instead of the customer's
                            default one. Cannot be combined with
                            `bank_account_id`. Omit to use the customer's
                            payment method.
                          example: pm_abc123
                        bank_account_id:
                          type: string
                          description: >-
                            ID of the bank account displayed on the
                            subscription's invoices, which are then paid by bank
                            transfer, instead of the customer's default payment
                            method. Cannot be combined with `payment_method_id`.
                            Omit to use the customer's payment method.
                          example: bac_abc123
                        shipping_address_id:
                          type: string
                          description: >-
                            ID of the customer's active shipping address the
                            subscription ships to. Omit to use the customer
                            shipping destination: billing address or default
                            shipping address.
                          example: cad_abc123
                        display_shipping_details:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            Indicates if the shipping details should be
                            displayed on the subscription's invoices.
                        cancel_at:
                          type: string
                          format: date-time
                          description: >-
                            Subscription cancel date. UTC date time string in
                            the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        cancellation_strategy:
                          type: string
                          enum:
                            - refund_prorata
                            - refund_custom
                            - charge_prorata
                            - charge_custom
                            - end_of_period
                            - do_nothing
                          description: >

                            Strategy used to cancel the subscription. If not
                            specified `do_nothing` is used.


                            - `charge_prorata`: Will charge the customer the
                            unpaid amount for the prorated period up to the end
                            of the current period.

                            - `charge_custom`: Will charge the customer a custom
                            amount.

                            - `refund_prorata`: Will refund to the customer the
                            overpaid subscription amount using prorated
                            calculations on the cancellation date.

                            - `refund_custom`: Will refund to the customer a
                            custom amount.

                            - `end_of_period`: Will cancel the subscription at
                            the end date of the current billing period.

                            - `do_nothing`: Will only cease the subscription
                            without any additional actions.
                        cancellation_amount:
                          type: number
                          description: >-
                            Custom amount used when cancelling the subscription.
                            Only applies to the `charge_custom` or the
                            `refund_custom` cancellation strategy.
                        cancellation_refund_method:
                          type: string
                          enum:
                            - wallet
                            - original_payment_method
                            - external
                          description: >-
                            Override the refund destination for credit notes
                            generated by `refund_prorata` / `refund_custom`
                            cancellation strategies. When omitted, falls back to
                            the invoicing entity's
                            `creditNoteWalletRefundEnabled` setting.
                        properties:
                          type: object
                          additionalProperties:
                            anyOf:
                              - type: string
                              - type: number
                              - type: boolean
                              - type: 'null'
                              - type: array
                                items:
                                  anyOf:
                                    - type: string
                                    - type: number
                                    - type: boolean
                                    - type: 'null'
                                    - type: 'null'
                              - type: 'null'
                          description: >-
                            Key/value pairs to store any metadata useful in your
                            context.
                        custom_properties:
                          type: object
                          additionalProperties:
                            anyOf:
                              - type: string
                              - type: number
                              - type: boolean
                              - type: string
                                format: date-time
                                description: >-
                                  UTC date time string in the [ISO
                                  8601](https://en.wikipedia.org/wiki/ISO_8601)
                                  format.
                                example: '2024-12-20T16:04:11Z'
                              - type: array
                                items:
                                  type: string
                              - type: 'null'
                          description: >-
                            A list of key value with the slug of the custom
                            property as the key and the custom property value as
                            value.
                        tax_only:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: Only tax will be charged on this subscription.
                        generate_draft_invoices:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            Generate draft invoices for the subscription. Each
                            invoice will need to be reviewed and validated
                            manually before being sent
                        generate_document:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: Generate non-legal documents instead of invoices.
                        document_name:
                          type:
                            - string
                            - 'null'
                          description: >-
                            If `generate_document` is turned on, allows you to
                            give a name to your document.
                        add_tax_to_document:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            If `generate_document` is turned on, will add taxes
                            to document.
                        do_not_charge_subscription:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            Subscription will be invoiced but not charged
                            (invoices/documents will be settled directly).
                        invoice_custom_note:
                          type:
                            - string
                            - 'null'
                          description: >-
                            Default custom note added to invoices generated by
                            the subscription.
                        invoice_schedule:
                          type:
                            - string
                            - 'null'
                          enum:
                            - period_start
                            - period_end
                          description: >

                            Defines when invoices are generated relative to the
                            billing period.


                            - `period_start`: Invoices are generated at the
                            start of the billing period.

                            - `period_end`: Invoices are generated at the end of
                            the billing period.
                    - anyOf:
                        - type: object
                          properties:
                            phases:
                              type: array
                              items:
                                type: object
                                properties:
                                  name:
                                    type: string
                                    description: Name of the subscription phase.
                                    example: Initial term
                                  type:
                                    type: string
                                    enum:
                                      - setup
                                      - trial
                                      - standard
                                    default: standard
                                    description: >

                                      Type of subscription phase.


                                      - `setup`: The phase represents a
                                      non-recurring service setup period, often
                                      used before the actual recurring
                                      subscription begins.

                                      - `trial`: The phase represents a
                                      non-recurring trial period, often used to
                                      allow users to opt out or experience a
                                      free test.

                                      - `standard`: The phase represents a
                                      standard recurring billing.
                                    example: standard
                                  status:
                                    type: string
                                    enum:
                                      - finished
                                      - pending
                                    default: pending
                                    description: >

                                      Status of subscription phase.


                                      - `pending`: The phase is waiting to start
                                      (not started yet).

                                      - `active`: The phase is currently in
                                      progress.

                                      - `finished`: The phase has ended and is
                                      complete.
                                    example: pending
                                  order:
                                    type: number
                                    description: >-
                                      Order in which the phase is executed
                                      within all subscription phases.
                                    example: 0
                                  end_strategy:
                                    type: string
                                    enum:
                                      - manual
                                      - end_date
                                      - duration
                                      - contract_end_date
                                    description: >

                                      End strategy of subscription phase.


                                      - `manual`: The phase ends when a user
                                      manually stops it.

                                      - `end_date`: The phase ends on a
                                      specified date.

                                      - `duration`: The phase ends after a
                                      specific relative duration.

                                      - `contract_end_date`: The phase ends on
                                      the end date of the related subscription
                                      contract.
                                    example: duration
                                  duration:
                                    type: object
                                    properties:
                                      period:
                                        type: string
                                        enum:
                                          - days
                                          - weeks
                                          - months
                                          - years
                                      count:
                                        type: integer
                                        minimum: 1
                                        default: 1
                                    required:
                                      - period
                                    description: >-
                                      Interval over which the subscription phase
                                      spans. Only applies to `duration` end
                                      strategy.
                                    example:
                                      count: 1
                                      period: years
                                  billing_date_setting:
                                    type: string
                                    enum:
                                      - phase_start
                                      - specific_date
                                    description: >

                                      Represents when the first billing date
                                      occurs.


                                      - `phase_start`: Aligns with the start of
                                      the phase.

                                      - `specific_date`: Occurs on a specified
                                      date.
                                    example: phase_start
                                  initial_billing_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Date when the subscription phase will
                                      start being billed. Only applies to
                                      `specific_date` billing date setting. UTC
                                      date time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  starts_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Actual start date of the phase. UTC date
                                      time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  ends_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Actual end date of the phase. UTC date
                                      time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  billing_cycle_alignment:
                                    type: string
                                    enum:
                                      - calendar_period
                                      - anniversary
                                    description: >

                                      Alignment of product billing cycles. If
                                      omitted at creation, the billing cycles
                                      alignment configured in the account
                                      subscription settings applies.


                                      - `calendar_period`: The billing cycles of
                                      the products will be aligned on the
                                      calendar period, after the first period
                                      which will be invoiced taking into account
                                      the prorata of the first cycle compared to
                                      the product periodicity.

                                      - `anniversary`: The billing cycles of the
                                      products will be aligned on the
                                      anniversary of the phase initial billing
                                      date.
                                    example: anniversary
                                  do_not_invoice_phase:
                                    type: boolean
                                    default: false
                                    description: >-
                                      Indicates if the phase should be invoiced.
                                      If set to true, the phase will not
                                      generate any invoices.
                                    example: false
                                  minimum_invoice_fee:
                                    type:
                                      - number
                                      - 'null'
                                    minimum: 0
                                    description: >-
                                      Phase minimum fee in minor currency units,
                                      after discounts and before tax. Null
                                      disables it and clears the product
                                      selection.
                                    example: 10000
                                  minimum_invoice_fee_products:
                                    type:
                                      - array
                                      - 'null'
                                    items:
                                      type: string
                                    description: >-
                                      Catalog product IDs eligible for the phase
                                      minimum fee. Null or an empty list
                                      includes all billed debit products in the
                                      phase.
                                    example:
                                      - itm_aaaaaaaaaaaaaa
                                  transition_calculation_method:
                                    type: string
                                    enum:
                                      - prorata
                                      - pay_in_full
                                      - none
                                    default: prorata
                                    description: >

                                      Calculation method used when transitioning
                                      from one phase to the next one.


                                      - `prorata`: The prorated amount between
                                      the two phases relative to the end date
                                      (the transition date) must be paid.

                                      - `pay_in_full`: The full amount for the
                                      phase billing period must be paid.

                                      - `none`: No amount will need to be paid,
                                      phase will simply transition from one to
                                      the next.
                                    example: prorata
                                  transition_invoicing_schedule:
                                    type: string
                                    enum:
                                      - immediately
                                    default: immediately
                                    description: >

                                      Represents when the transition amount will
                                      be invoiced.


                                      - `immediately`: An invoice will be
                                      generated immediately with the
                                      corresponding amount.
                                    example: immediately
                                  products:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        id:
                                          type: string
                                          description: Product ID.
                                          example: itm_FJKlqUb8COXw55
                                        catalog_version_id:
                                          type:
                                            - string
                                            - 'null'
                                          description: >-
                                            ID of a published catalog version to
                                            price this product from, instead of the
                                            live products catalog. Ignored when
                                            `price` or `prices` is set. The product
                                            must be priced in that version.
                                          example: pcv_9x8v7u6t5s4r
                                        price_configuration_id:
                                          type:
                                            - string
                                            - 'null'
                                          description: >-
                                            ID of the product's price configuration
                                            to price this product from, instead of
                                            the one the catalog rules select. It
                                            must be a live base configuration of the
                                            product (not archived or replaced by a
                                            later catalog publish, and not specific
                                            to a customer, price book, customer
                                            segment or plan), in the subscription's
                                            currency. Requires `payment_interval`,
                                            which it must match. The configuration's
                                            country and commitment restrictions are
                                            not checked. With a pinned catalog
                                            version, the product is priced from that
                                            version's copy of the configuration, and
                                            a configuration the version doesn't
                                            price returns a 400. Cannot be combined
                                            with `price`, `prices` or `plan_id`.
                                          example: prc_8f3kXODIM1sBwB
                                        name:
                                          type: string
                                          description: >-
                                            Product name. This will appear on the
                                            final invoices.
                                          example: Product name
                                        description:
                                          type: string
                                          description: >-
                                            Product description. This will appear on
                                            the final invoices.
                                          example: A description of the product.
                                        description_display_interval_dates:
                                          type: boolean
                                          default: false
                                          description: >-
                                            Indicates if the dates of the interval
                                            should be automatically added in the
                                            product description on the invoices.
                                        payment_interval:
                                          anyOf:
                                            - type: object
                                              properties:
                                                period:
                                                  type: string
                                                  enum:
                                                    - once
                                              required:
                                                - period
                                              title: Once
                                              example:
                                                period: once
                                            - type: object
                                              properties:
                                                period:
                                                  type: string
                                                  enum:
                                                    - days
                                                    - weeks
                                                    - months
                                                    - years
                                                count:
                                                  type: integer
                                                  minimum: 1
                                                  default: 1
                                              required:
                                                - period
                                              title: Period
                                              example:
                                                period: months
                                                count: 1
                                          description: >-
                                            Interval on which the product is billed.
                                            This interval can be different between
                                            products and can differ from the
                                            subscription commitment interval.
                                        payment_schedule:
                                          type: string
                                          enum:
                                            - start
                                            - end
                                          description: >-
                                            Indicates if the product should be
                                            billed at the start or the end of the
                                            payment interval.
                                          example: start
                                        price:
                                          type: object
                                          properties:
                                            type:
                                              type: string
                                              enum:
                                                - fee
                                            amount:
                                              type: number
                                              description: >-
                                                Monetary amount. Expressed in currency's
                                                smallest unit.
                                          required:
                                            - type
                                            - amount
                                          description: >-
                                            Similar to `prices`, allow to apply a
                                            single fee price more easily.
                                          example:
                                            type: fee
                                            amount: 200
                                        prices:
                                          type: array
                                          items:
                                            oneOf:
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - fee
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount. Expressed in currency's
                                                      smallest unit.
                                                required:
                                                  - type
                                                  - amount
                                                title: Fee price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - volume
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                  from:
                                                    type: number
                                                    description: From limit.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  on_tier_incomplete:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - pro_rata
                                                      - pay_in_full
                                                      - do_not_charge
                                                      - flat_per_tier
                                                    default: pro_rata
                                                    description: >-

                                                      Logic used to compute the amount when
                                                      usage on the tier is incomplete.


                                                      - `pro_rata`: The amount is computed
                                                      using the pro rata of the tier's
                                                      consumption.

                                                      - `pay_in_full`: The amount corresponds
                                                      to the full payment of the tier.

                                                      - `do_not_charge`: The tier is not
                                                      charged and ignored.

                                                      - `flat_per_tier`: The tier's `amount`
                                                      is a flat fee, billed once as soon as
                                                      usage reaches the tier, whatever the
                                                      number of units in it. `unitCount` is
                                                      ignored. No usage bills nothing.
                                                        
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                  - from
                                                  - to
                                                title: Volume price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - packaged
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                  from:
                                                    type: number
                                                    description: From limit.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  on_bucket_incomplete:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - pro_rata
                                                      - pay_in_full
                                                      - do_not_charge
                                                      - flat_per_tier
                                                    default: pro_rata
                                                    description: >-

                                                      Logic used to compute the amount when
                                                      usage reaches an incomplete bucket (the
                                                      bucket size corresponds to the
                                                      `unitCount`).

                                                        - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                        - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                        - `do_not_charge`: The bucket is not charged and ignored.
                                                        - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                          
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                  - from
                                                  - to
                                                title: Packaged price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - bulk
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  on_tier_incomplete:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - pro_rata
                                                      - pay_in_full
                                                      - do_not_charge
                                                      - flat_per_tier
                                                    default: pro_rata
                                                    description: >-

                                                      Logic used to compute the amount when
                                                      usage on the tier is incomplete.


                                                      - `pro_rata`: The amount is computed
                                                      using the pro rata of the tier's
                                                      consumption.

                                                      - `pay_in_full`: The amount corresponds
                                                      to the full payment of the tier.

                                                      - `do_not_charge`: The tier is not
                                                      charged and ignored.

                                                      - `flat_per_tier`: The tier's `amount`
                                                      is a flat fee, billed once as soon as
                                                      usage reaches the tier, whatever the
                                                      number of units in it. `unitCount` is
                                                      ignored. No usage bills nothing.
                                                        
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                  - to
                                                title: Bulk price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - bps
                                                  from:
                                                    type: number
                                                    description: From limit.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  percentage:
                                                    type: number
                                                    description: >-
                                                      Percentage applied on each unit to
                                                      compute the usage.
                                                  per_unit_cap:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: >-
                                                      Maximum amount for one unit. Expressed
                                                      in currency's smallest unit.
                                                  per_unit_floor:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: >-
                                                      Minimum amount for one unit. Expressed
                                                      in currency's smallest unit.
                                                  per_unit_fee:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: >-
                                                      Fee amount applied per unit. Expressed
                                                      in currency's smallest unit.
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - from
                                                  - to
                                                  - percentage
                                                  - per_unit_cap
                                                  - per_unit_floor
                                                  - per_unit_fee
                                                title: BPS price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - bundle
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                title: Bundle price
                                                description: >-
                                                  For seat products only, if you are
                                                  looking for credits, use a fee price
                                          description: >-
                                            Prices of the product. If not specified,
                                            the matching prices (depending on the
                                            currency, interval, etc) of the product
                                            defined in the products catalog/plan are
                                            used.
                                          example:
                                            - type: volume
                                              from: 0
                                              to: 20
                                              amount: 200
                                              unit_count: 1
                                              on_tier_incomplete: null
                                            - type: volume
                                              from: 20
                                              to: null
                                              amount: 150
                                              unit_count: 1
                                              on_tier_incomplete: null
                                        count:
                                          type: number
                                          minimum: 1
                                          description: >-
                                            Number of product units. Only applies to
                                            products of type `flat_fee`, `seat` or
                                            `credit`.
                                          example: 2
                                        unit_name:
                                          type: string
                                          description: >-
                                            Product name. This will appear on the
                                            final invoices. Only applies to products
                                            of type `seat` or `usage`.
                                          example: user
                                        min_committed_count:
                                          type: number
                                          minimum: 1
                                          description: >-
                                            Minimum of units committed. If usage is
                                            less than this number, then this value
                                            will be used. Only applies to products
                                            of type `usage`.
                                        min_amount:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Minimum amount billed. If the final
                                            computed amount from the usage for this
                                            product is less than this amount, then
                                            this value will be used. Only applies to
                                            products of type `usage`.
                                        max_amount:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Maximum amount billed. If the final
                                            computed amount from the usage for this
                                            product is greater than this amount,
                                            then this value will be used. Only
                                            applies to products of type `usage`.
                                        charging_method:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - prorata
                                            - pay_in_full
                                            - do_not_charge
                                          description: >-
                                            Charging method for seat count updates
                                            within the current billing period. Only
                                            applies to connected seat products.


                                            - `prorata`: Price calculated
                                            proportionally to time elapsed in the
                                            billing period.

                                            - `pay_in_full`: Price calculated for
                                            the entire billing period.

                                            - `do_not_charge`: No charge for the
                                            update.
                                        seat_invoicing_schedule:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - immediately
                                            - next_invoice
                                            - custom
                                          description: >

                                            Policy defining when seat count changes
                                            are invoiced. Only applies to connected
                                            seat products.


                                            - `immediately`: Seat changes are
                                            invoiced immediately.

                                            - `next_invoice`: Seat changes are
                                            invoiced at the next invoice.

                                            - `custom`: Seat changes are invoiced on
                                            a custom schedule.
                                        metering_interval_type:
                                          type: string
                                          enum:
                                            - subscription_commitment
                                            - payment_interval
                                            - full_database
                                            - phase_duration
                                            - custom
                                          description: >-

                                            Indicates on which type of interval the
                                            usage should be aggregated.


                                            - `subscription_commitment`: For the
                                            usage contained within the subscription
                                            commitment period.

                                            - `payment_interval`: For the usage
                                            contained within the payment interval of
                                            the product.

                                            - `full_database`: For all the usage we
                                            ingested for this product, no matter the
                                            period.

                                            - `phase_duration`: For the usage
                                            contained within the subscription phase.

                                            - `custom`: For the usage contained
                                            within a custom interval that starts
                                            with the phase and renews independently
                                            of the billing interval. Requires
                                            `metering_interval` to be set.
                                               Only applies to products of type `usage`.
                                        metering_interval:
                                          type: object
                                          properties:
                                            period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                            count:
                                              type: integer
                                              minimum: 1
                                          required:
                                            - period
                                            - count
                                          description: >-
                                            Custom interval for usage aggregation.
                                            Required when `metering_interval_type`
                                            is `custom`. The interval starts at the
                                            phase start and renews on its own cycle
                                            (e.g. `{ period: 'months', count: 3 }`
                                            for quarterly metering with monthly
                                            billing). Only applies to products of
                                            type `usage`.
                                        bill_usage_difference:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          default: false
                                          description: >-
                                            Only bill the usage difference comparing
                                            to the previous period (i.e. actual
                                            amount minus last invoice amount).
                                            Doesn't apply to `payment_interval`
                                            metering interval type. Only applies to
                                            products of type `usage`.
                                        children_usage_aggregation:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - sum
                                            - max
                                          description: >-

                                            Controls whether a parent organization's
                                            metered usage is billed on the combined
                                            usage of the parent and its direct
                                            children, and how per-member values are
                                            combined.


                                            - `null`: Organization-based usage is
                                            disabled. Only the subscription
                                            customer's own usage is billed.

                                            - `sum`: The usage values of the parent
                                            and each direct child are added together
                                            (organization total).

                                            - `max`: Only the single
                                            highest-consuming member (parent or one
                                            direct child) is billed.
                                             Only applies to products of type `usage`.
                                        credits_expiration_in_days:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Validity in days for credits that will
                                            be topped-up automatically. Once the
                                            period has passed, they'll expire.
                                        expire_credits_at_end_of_period:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          default: false
                                          description: >-
                                            Automatically set the expiration date to
                                            the end of the next period for each
                                            topup. Takes priority on
                                            `creditsExpirationInDays`
                                        credits_balance_auto_creation_enabled:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          description: >-
                                            Whether to create the customer credit
                                            balance as soon as the product is added
                                            to the subscription. Defaults to the
                                            credit product's
                                            `credits_balance_auto_creation_enabled`
                                            (`true` when unset). Set to `false` to
                                            create the balance by hand before
                                            activation, e.g. on quote-based renewals
                                            where the balance must not start
                                            consuming before signature; the first
                                            top-up creates it if still missing.
                                        estimated_count:
                                          type:
                                            - number
                                            - 'null'
                                          minimum: 0
                                          maximum: 1000000000000
                                          description: >-
                                            Estimated number of units, for recurring
                                            usage-based and connected seat products
                                            (ignored on any other product, and not
                                            priced for a usage-based product with
                                            several filtered price groups). It
                                            prices the quote value and is shown as
                                            an estimate on the quote, but is never
                                            billed: invoices use the measured usage
                                            or seat count.
                                          example: 200
                                      required:
                                        - id
                                    description: >-
                                      Products comprising the subscription
                                      phase.
                                  coupons:
                                    type: array
                                    items:
                                      allOf:
                                        - anyOf:
                                            - type: object
                                              properties:
                                                id:
                                                  type: string
                                                  description: >-
                                                    ID of the catalog coupon to apply to the
                                                    subscription.
                                              required:
                                                - id
                                              title: Existing coupon
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - amount
                                                name:
                                                  type: string
                                                  description: Coupon name.
                                                discount_amount:
                                                  type: number
                                                  exclusiveMinimum: 0
                                                  description: >-
                                                    Coupon discount amount. Expressed in
                                                    currency's smallest unit.
                                              required:
                                                - type
                                                - discount_amount
                                              title: Coupon amount
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - percent
                                                name:
                                                  type: string
                                                  description: Coupon name.
                                                discount_percent:
                                                  type: number
                                                  exclusiveMinimum: 0
                                                  maximum: 100
                                                  description: Coupon discount percentage.
                                              required:
                                                - type
                                                - discount_percent
                                              title: Coupon percent
                                        - type: object
                                          properties:
                                            repeat:
                                              type:
                                                - string
                                                - 'null'
                                              enum:
                                                - once
                                                - forever
                                                - custom
                                                - duration
                                              description: >

                                                Coupon frequency. Required for inline
                                                coupons. Optional when an existing
                                                coupon `id` is provided: if omitted,
                                                defaults to the catalog coupon's repeat
                                                value.


                                                - `once`: Will apply the coupon only to
                                                the first one invoice.

                                                - `forever`: Will apply the coupon to
                                                all invoices.

                                                - `custom`: Will apply to coupon until a
                                                specified expiration date.

                                                - `duration`: Will apply the coupon for
                                                a specific duration (e.g., 3 months).
                                            duration_period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                              description: >-
                                                Period of time for which the coupon will
                                                be applied. Only applies to the
                                                `duration` coupon frequency.
                                            duration_count:
                                              type: number
                                              description: >-
                                                Number of periods for which the coupon
                                                will be applied. Only applies to the
                                                `duration` coupon frequency.
                                            expires_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Coupon expiration date. Only applies to
                                                the `custom` coupon frequency. UTC date
                                                time string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            apply_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Coupon first application date. UTC date
                                                time string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            product_ids:
                                              type:
                                                - array
                                                - 'null'
                                              items:
                                                type: string
                                              minItems: 1
                                              description: >-
                                                Products the coupon is scoped to on this
                                                subscription, read together with
                                                `product_scope`: the only discounted
                                                products when `include`, the products
                                                never discounted when `exclude`, null
                                                when `all`. When sent without
                                                `product_scope`, it is an `include`
                                                list, except that a coupon already
                                                stored as `exclude` keeps `exclude` when
                                                its phase is updated; when empty or
                                                omitted, the catalog coupon's scope is
                                                copied.
                                            product_scope:
                                              type:
                                                - string
                                                - 'null'
                                              enum:
                                                - all
                                                - include
                                                - exclude
                                              description: >-
                                                Which products the coupon discounts on
                                                this subscription. `all`: every product
                                                (`product_ids` must be empty).
                                                `include`: only the products in
                                                `product_ids`. `exclude`: every product
                                                except those in `product_ids` (lines
                                                without a product stay discounted). When
                                                sent, it replaces the catalog coupon's
                                                scope together with `product_ids`. When
                                                omitted, it is inferred: `include` if
                                                `product_ids` is non-empty, else the
                                                catalog coupon's scope. On a phase
                                                update, a coupon already stored as
                                                `exclude` keeps `exclude` when
                                                `product_ids` is sent without
                                                `product_scope`.
                                    description: Coupons comprising the subscription phase.
                                  activation_strategy:
                                    type: string
                                    enum:
                                      - manual
                                      - start_date
                                      - quote_signature
                                      - contract_start_date
                                      - previous_phase_end
                                    description: >

                                      Activation strategy of subscription phase.


                                      - `immediately`: The phase starts as soon
                                      as the subscription is activated.

                                      - `manual`: The phase starts when a user
                                      manually activates it.

                                      - `start_date`: The phase starts on a
                                      specified date.

                                      - `quote_signature`: The phase starts when
                                      the subscription quote is signed.

                                      - `checkout`: The phase starts when the
                                      subscription checkout is completed.

                                      - `contract_start_date`: The phase starts
                                      on the start date of the related
                                      subscription contract.

                                      - `previous_phase_end`: The phase starts
                                      when the previous phase ends.
                                    example: manual
                                required:
                                  - end_strategy
                                  - billing_date_setting
                                  - products
                                  - activation_strategy
                          required:
                            - phases
                          title: With phases
                        - allOf:
                            - type: object
                              properties:
                                activation_strategy:
                                  type: string
                                  enum:
                                    - start_date
                                    - manually
                                    - quote
                                  default: manually
                                  description: >

                                    Strategy used to activate the subscription.


                                    - `start_date`: The subscription will become
                                    active on the specified start date. If the
                                    start date is in the past, it will be
                                    activated immediately.

                                    - `manually`: The subscription requires
                                    activation through a manual action.

                                    - `checkout`: The subscription will be
                                    activated once the checkout is completed,
                                    but only if the start date is in the past.
                                    Otherwise, activation will occur later on
                                    the specified start date.

                                    - `quote`: The subscription will be
                                    activated depending on the configuration and
                                    the signature of the related quote.
                                  example: start_date
                                products:
                                  type: array
                                  items:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        description: Product ID.
                                        example: itm_FJKlqUb8COXw55
                                      catalog_version_id:
                                        type:
                                          - string
                                          - 'null'
                                        description: >-
                                          ID of a published catalog version to
                                          price this product from, instead of the
                                          live products catalog. Ignored when
                                          `price` or `prices` is set. The product
                                          must be priced in that version.
                                        example: pcv_9x8v7u6t5s4r
                                      price_configuration_id:
                                        type:
                                          - string
                                          - 'null'
                                        description: >-
                                          ID of the product's price configuration
                                          to price this product from, instead of
                                          the one the catalog rules select. It
                                          must be a live base configuration of the
                                          product (not archived or replaced by a
                                          later catalog publish, and not specific
                                          to a customer, price book, customer
                                          segment or plan), in the subscription's
                                          currency. Requires `payment_interval`,
                                          which it must match. The configuration's
                                          country and commitment restrictions are
                                          not checked. With a pinned catalog
                                          version, the product is priced from that
                                          version's copy of the configuration, and
                                          a configuration the version doesn't
                                          price returns a 400. Cannot be combined
                                          with `price`, `prices` or `plan_id`.
                                        example: prc_8f3kXODIM1sBwB
                                      name:
                                        type: string
                                        description: >-
                                          Product name. This will appear on the
                                          final invoices.
                                        example: Product name
                                      description:
                                        type: string
                                        description: >-
                                          Product description. This will appear on
                                          the final invoices.
                                        example: A description of the product.
                                      description_display_interval_dates:
                                        type: boolean
                                        default: false
                                        description: >-
                                          Indicates if the dates of the interval
                                          should be automatically added in the
                                          product description on the invoices.
                                      payment_interval:
                                        anyOf:
                                          - type: object
                                            properties:
                                              period:
                                                type: string
                                                enum:
                                                  - once
                                            required:
                                              - period
                                            title: Once
                                            example:
                                              period: once
                                          - type: object
                                            properties:
                                              period:
                                                type: string
                                                enum:
                                                  - days
                                                  - weeks
                                                  - months
                                                  - years
                                              count:
                                                type: integer
                                                minimum: 1
                                                default: 1
                                            required:
                                              - period
                                            title: Period
                                            example:
                                              period: months
                                              count: 1
                                        description: >-
                                          Interval on which the product is billed.
                                          This interval can be different between
                                          products and can differ from the
                                          subscription commitment interval.
                                      payment_schedule:
                                        type: string
                                        enum:
                                          - start
                                          - end
                                        description: >-
                                          Indicates if the product should be
                                          billed at the start or the end of the
                                          payment interval.
                                        example: start
                                      price:
                                        type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - fee
                                          amount:
                                            type: number
                                            description: >-
                                              Monetary amount. Expressed in currency's
                                              smallest unit.
                                        required:
                                          - type
                                          - amount
                                        description: >-
                                          Similar to `prices`, allow to apply a
                                          single fee price more easily.
                                        example:
                                          type: fee
                                          amount: 200
                                      prices:
                                        type: array
                                        items:
                                          oneOf:
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - fee
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount. Expressed in currency's
                                                    smallest unit.
                                              required:
                                                - type
                                                - amount
                                              title: Fee price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - volume
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                                from:
                                                  type: number
                                                  description: From limit.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                on_tier_incomplete:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - pro_rata
                                                    - pay_in_full
                                                    - do_not_charge
                                                    - flat_per_tier
                                                  default: pro_rata
                                                  description: >-

                                                    Logic used to compute the amount when
                                                    usage on the tier is incomplete.


                                                    - `pro_rata`: The amount is computed
                                                    using the pro rata of the tier's
                                                    consumption.

                                                    - `pay_in_full`: The amount corresponds
                                                    to the full payment of the tier.

                                                    - `do_not_charge`: The tier is not
                                                    charged and ignored.

                                                    - `flat_per_tier`: The tier's `amount`
                                                    is a flat fee, billed once as soon as
                                                    usage reaches the tier, whatever the
                                                    number of units in it. `unitCount` is
                                                    ignored. No usage bills nothing.
                                                      
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                                - from
                                                - to
                                              title: Volume price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - packaged
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                                from:
                                                  type: number
                                                  description: From limit.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                on_bucket_incomplete:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - pro_rata
                                                    - pay_in_full
                                                    - do_not_charge
                                                    - flat_per_tier
                                                  default: pro_rata
                                                  description: >-

                                                    Logic used to compute the amount when
                                                    usage reaches an incomplete bucket (the
                                                    bucket size corresponds to the
                                                    `unitCount`).

                                                      - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                      - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                      - `do_not_charge`: The bucket is not charged and ignored.
                                                      - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                        
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                                - from
                                                - to
                                              title: Packaged price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - bulk
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                on_tier_incomplete:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - pro_rata
                                                    - pay_in_full
                                                    - do_not_charge
                                                    - flat_per_tier
                                                  default: pro_rata
                                                  description: >-

                                                    Logic used to compute the amount when
                                                    usage on the tier is incomplete.


                                                    - `pro_rata`: The amount is computed
                                                    using the pro rata of the tier's
                                                    consumption.

                                                    - `pay_in_full`: The amount corresponds
                                                    to the full payment of the tier.

                                                    - `do_not_charge`: The tier is not
                                                    charged and ignored.

                                                    - `flat_per_tier`: The tier's `amount`
                                                    is a flat fee, billed once as soon as
                                                    usage reaches the tier, whatever the
                                                    number of units in it. `unitCount` is
                                                    ignored. No usage bills nothing.
                                                      
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                                - to
                                              title: Bulk price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - bps
                                                from:
                                                  type: number
                                                  description: From limit.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                percentage:
                                                  type: number
                                                  description: >-
                                                    Percentage applied on each unit to
                                                    compute the usage.
                                                per_unit_cap:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Maximum amount for one unit. Expressed
                                                    in currency's smallest unit.
                                                per_unit_floor:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Minimum amount for one unit. Expressed
                                                    in currency's smallest unit.
                                                per_unit_fee:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Fee amount applied per unit. Expressed
                                                    in currency's smallest unit.
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - from
                                                - to
                                                - percentage
                                                - per_unit_cap
                                                - per_unit_floor
                                                - per_unit_fee
                                              title: BPS price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - bundle
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                              title: Bundle price
                                              description: >-
                                                For seat products only, if you are
                                                looking for credits, use a fee price
                                        description: >-
                                          Prices of the product. If not specified,
                                          the matching prices (depending on the
                                          currency, interval, etc) of the product
                                          defined in the products catalog/plan are
                                          used.
                                        example:
                                          - type: volume
                                            from: 0
                                            to: 20
                                            amount: 200
                                            unit_count: 1
                                            on_tier_incomplete: null
                                          - type: volume
                                            from: 20
                                            to: null
                                            amount: 150
                                            unit_count: 1
                                            on_tier_incomplete: null
                                      count:
                                        type: number
                                        minimum: 1
                                        description: >-
                                          Number of product units. Only applies to
                                          products of type `flat_fee`, `seat` or
                                          `credit`.
                                        example: 2
                                      unit_name:
                                        type: string
                                        description: >-
                                          Product name. This will appear on the
                                          final invoices. Only applies to products
                                          of type `seat` or `usage`.
                                        example: user
                                      min_committed_count:
                                        type: number
                                        minimum: 1
                                        description: >-
                                          Minimum of units committed. If usage is
                                          less than this number, then this value
                                          will be used. Only applies to products
                                          of type `usage`.
                                      min_amount:
                                        type:
                                          - number
                                          - 'null'
                                        description: >-
                                          Minimum amount billed. If the final
                                          computed amount from the usage for this
                                          product is less than this amount, then
                                          this value will be used. Only applies to
                                          products of type `usage`.
                                      max_amount:
                                        type:
                                          - number
                                          - 'null'
                                        description: >-
                                          Maximum amount billed. If the final
                                          computed amount from the usage for this
                                          product is greater than this amount,
                                          then this value will be used. Only
                                          applies to products of type `usage`.
                                      charging_method:
                                        type:
                                          - string
                                          - 'null'
                                        enum:
                                          - prorata
                                          - pay_in_full
                                          - do_not_charge
                                        description: >-
                                          Charging method for seat count updates
                                          within the current billing period. Only
                                          applies to connected seat products.


                                          - `prorata`: Price calculated
                                          proportionally to time elapsed in the
                                          billing period.

                                          - `pay_in_full`: Price calculated for
                                          the entire billing period.

                                          - `do_not_charge`: No charge for the
                                          update.
                                      seat_invoicing_schedule:
                                        type:
                                          - string
                                          - 'null'
                                        enum:
                                          - immediately
                                          - next_invoice
                                          - custom
                                        description: >

                                          Policy defining when seat count changes
                                          are invoiced. Only applies to connected
                                          seat products.


                                          - `immediately`: Seat changes are
                                          invoiced immediately.

                                          - `next_invoice`: Seat changes are
                                          invoiced at the next invoice.

                                          - `custom`: Seat changes are invoiced on
                                          a custom schedule.
                                      metering_interval_type:
                                        type: string
                                        enum:
                                          - subscription_commitment
                                          - payment_interval
                                          - full_database
                                          - phase_duration
                                          - custom
                                        description: >-

                                          Indicates on which type of interval the
                                          usage should be aggregated.


                                          - `subscription_commitment`: For the
                                          usage contained within the subscription
                                          commitment period.

                                          - `payment_interval`: For the usage
                                          contained within the payment interval of
                                          the product.

                                          - `full_database`: For all the usage we
                                          ingested for this product, no matter the
                                          period.

                                          - `phase_duration`: For the usage
                                          contained within the subscription phase.

                                          - `custom`: For the usage contained
                                          within a custom interval that starts
                                          with the phase and renews independently
                                          of the billing interval. Requires
                                          `metering_interval` to be set.
                                             Only applies to products of type `usage`.
                                      metering_interval:
                                        type: object
                                        properties:
                                          period:
                                            type: string
                                            enum:
                                              - days
                                              - weeks
                                              - months
                                              - years
                                          count:
                                            type: integer
                                            minimum: 1
                                        required:
                                          - period
                                          - count
                                        description: >-
                                          Custom interval for usage aggregation.
                                          Required when `metering_interval_type`
                                          is `custom`. The interval starts at the
                                          phase start and renews on its own cycle
                                          (e.g. `{ period: 'months', count: 3 }`
                                          for quarterly metering with monthly
                                          billing). Only applies to products of
                                          type `usage`.
                                      bill_usage_difference:
                                        anyOf:
                                          - type: boolean
                                          - type: string
                                            enum:
                                              - 'true'
                                              - 'false'
                                        default: false
                                        description: >-
                                          Only bill the usage difference comparing
                                          to the previous period (i.e. actual
                                          amount minus last invoice amount).
                                          Doesn't apply to `payment_interval`
                                          metering interval type. Only applies to
                                          products of type `usage`.
                                      children_usage_aggregation:
                                        type:
                                          - string
                                          - 'null'
                                        enum:
                                          - sum
                                          - max
                                        description: >-

                                          Controls whether a parent organization's
                                          metered usage is billed on the combined
                                          usage of the parent and its direct
                                          children, and how per-member values are
                                          combined.


                                          - `null`: Organization-based usage is
                                          disabled. Only the subscription
                                          customer's own usage is billed.

                                          - `sum`: The usage values of the parent
                                          and each direct child are added together
                                          (organization total).

                                          - `max`: Only the single
                                          highest-consuming member (parent or one
                                          direct child) is billed.
                                           Only applies to products of type `usage`.
                                      credits_expiration_in_days:
                                        type:
                                          - number
                                          - 'null'
                                        description: >-
                                          Validity in days for credits that will
                                          be topped-up automatically. Once the
                                          period has passed, they'll expire.
                                      expire_credits_at_end_of_period:
                                        anyOf:
                                          - type: boolean
                                          - type: string
                                            enum:
                                              - 'true'
                                              - 'false'
                                        default: false
                                        description: >-
                                          Automatically set the expiration date to
                                          the end of the next period for each
                                          topup. Takes priority on
                                          `creditsExpirationInDays`
                                      credits_balance_auto_creation_enabled:
                                        anyOf:
                                          - type: boolean
                                          - type: string
                                            enum:
                                              - 'true'
                                              - 'false'
                                        description: >-
                                          Whether to create the customer credit
                                          balance as soon as the product is added
                                          to the subscription. Defaults to the
                                          credit product's
                                          `credits_balance_auto_creation_enabled`
                                          (`true` when unset). Set to `false` to
                                          create the balance by hand before
                                          activation, e.g. on quote-based renewals
                                          where the balance must not start
                                          consuming before signature; the first
                                          top-up creates it if still missing.
                                      estimated_count:
                                        type:
                                          - number
                                          - 'null'
                                        minimum: 0
                                        maximum: 1000000000000
                                        description: >-
                                          Estimated number of units, for recurring
                                          usage-based and connected seat products
                                          (ignored on any other product, and not
                                          priced for a usage-based product with
                                          several filtered price groups). It
                                          prices the quote value and is shown as
                                          an estimate on the quote, but is never
                                          billed: invoices use the measured usage
                                          or seat count.
                                        example: 200
                                    required:
                                      - id
                                  description: Products that make up the subscription.
                                coupons:
                                  type: array
                                  items:
                                    allOf:
                                      - anyOf:
                                          - type: object
                                            properties:
                                              id:
                                                type: string
                                                description: >-
                                                  ID of the catalog coupon to apply to the
                                                  subscription.
                                            required:
                                              - id
                                            title: Existing coupon
                                          - type: object
                                            properties:
                                              type:
                                                type: string
                                                enum:
                                                  - amount
                                              name:
                                                type: string
                                                description: Coupon name.
                                              discount_amount:
                                                type: number
                                                exclusiveMinimum: 0
                                                description: >-
                                                  Coupon discount amount. Expressed in
                                                  currency's smallest unit.
                                            required:
                                              - type
                                              - discount_amount
                                            title: Coupon amount
                                          - type: object
                                            properties:
                                              type:
                                                type: string
                                                enum:
                                                  - percent
                                              name:
                                                type: string
                                                description: Coupon name.
                                              discount_percent:
                                                type: number
                                                exclusiveMinimum: 0
                                                maximum: 100
                                                description: Coupon discount percentage.
                                            required:
                                              - type
                                              - discount_percent
                                            title: Coupon percent
                                      - type: object
                                        properties:
                                          repeat:
                                            type:
                                              - string
                                              - 'null'
                                            enum:
                                              - once
                                              - forever
                                              - custom
                                              - duration
                                            description: >

                                              Coupon frequency. Required for inline
                                              coupons. Optional when an existing
                                              coupon `id` is provided: if omitted,
                                              defaults to the catalog coupon's repeat
                                              value.


                                              - `once`: Will apply the coupon only to
                                              the first one invoice.

                                              - `forever`: Will apply the coupon to
                                              all invoices.

                                              - `custom`: Will apply to coupon until a
                                              specified expiration date.

                                              - `duration`: Will apply the coupon for
                                              a specific duration (e.g., 3 months).
                                          duration_period:
                                            type: string
                                            enum:
                                              - days
                                              - weeks
                                              - months
                                              - years
                                            description: >-
                                              Period of time for which the coupon will
                                              be applied. Only applies to the
                                              `duration` coupon frequency.
                                          duration_count:
                                            type: number
                                            description: >-
                                              Number of periods for which the coupon
                                              will be applied. Only applies to the
                                              `duration` coupon frequency.
                                          expires_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Coupon expiration date. Only applies to
                                              the `custom` coupon frequency. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          apply_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Coupon first application date. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          product_ids:
                                            type:
                                              - array
                                              - 'null'
                                            items:
                                              type: string
                                            minItems: 1
                                            description: >-
                                              Products the coupon is scoped to on this
                                              subscription, read together with
                                              `product_scope`: the only discounted
                                              products when `include`, the products
                                              never discounted when `exclude`, null
                                              when `all`. When sent without
                                              `product_scope`, it is an `include`
                                              list, except that a coupon already
                                              stored as `exclude` keeps `exclude` when
                                              its phase is updated; when empty or
                                              omitted, the catalog coupon's scope is
                                              copied.
                                          product_scope:
                                            type:
                                              - string
                                              - 'null'
                                            enum:
                                              - all
                                              - include
                                              - exclude
                                            description: >-
                                              Which products the coupon discounts on
                                              this subscription. `all`: every product
                                              (`product_ids` must be empty).
                                              `include`: only the products in
                                              `product_ids`. `exclude`: every product
                                              except those in `product_ids` (lines
                                              without a product stay discounted). When
                                              sent, it replaces the catalog coupon's
                                              scope together with `product_ids`. When
                                              omitted, it is inferred: `include` if
                                              `product_ids` is non-empty, else the
                                              catalog coupon's scope. On a phase
                                              update, a coupon already stored as
                                              `exclude` keeps `exclude` when
                                              `product_ids` is sent without
                                              `product_scope`.
                                  description: >-
                                    Coupons to be applied to the prices of
                                    subscription products.
                            - type: object
                              properties:
                                trial:
                                  type: object
                                  properties:
                                    end_strategy:
                                      type: string
                                      enum:
                                        - manual
                                        - end_date
                                        - duration
                                      description: Defines how the free trial will end.
                                    starts_at:
                                      type: string
                                      format: date-time
                                      description: >-
                                        Free trial start date. UTC date time
                                        string in the [ISO
                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                        format.
                                      example: '2024-12-20T16:04:11Z'
                                    ends_at:
                                      type: string
                                      format: date-time
                                      description: >-
                                        Free trial end date. Only applies if the
                                        end strategy is `end_date`. UTC date
                                        time string in the [ISO
                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                        format.
                                      example: '2024-12-20T16:04:11Z'
                                    duration:
                                      type: object
                                      properties:
                                        period:
                                          type: string
                                          enum:
                                            - days
                                            - weeks
                                            - months
                                            - years
                                          description: >-
                                            Free trial duration period. Only applies
                                            if the end strategy is `duration`.
                                        count:
                                          type: number
                                          minimum: 1
                                          description: >-
                                            Free trial duration count. Only applies
                                            if the end strategy is `duration`.
                                      required:
                                        - period
                                        - count
                                  required:
                                    - end_strategy
                                  description: >-
                                    Create a free trial phase based on the plan
                                    configuration. Only applies if a `plan_id`
                                    is provided.
                          title: Without phases
                  description: Subscription configuration constituting the quote.
              required:
                - template_id
              title: Subscription from a template
            - type: object
              properties:
                expires_at:
                  type: string
                  format: date-time
                  description: >-
                    Quote expiration date. UTC date time string in the [ISO
                    8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                  example: '2024-04-28T14:12:09.293Z'
                subscription:
                  allOf:
                    - type: object
                      properties:
                        name:
                          type: string
                          description: Subscription custom name.
                        purchase_order:
                          type: string
                          description: Reference to the purchase order.
                        invoicing_entity_id:
                          type: string
                          description: >-
                            ID of the invoicing entity attached to the
                            subscription. If not defined, fallback to customer's
                            invoicing entity.
                          example: ive_jerrb484RHn
                        crm_opportunity_id:
                          type: string
                          description: >-
                            ID of the related opportunity/deal in the connected
                            CRM.
                        commitment_interval:
                          type: object
                          properties:
                            period:
                              type: string
                              enum:
                                - days
                                - weeks
                                - months
                                - years
                            count:
                              type: number
                              minimum: 1
                          required:
                            - period
                            - count
                          description: Deprecated field, please use `contract_terms`.
                          example:
                            period: years
                            count: 1
                          deprecated: true
                        renew_automatically:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          default: true
                          description: Deprecated field, please use `contract_terms`.
                          example: true
                          deprecated: true
                        renew_for:
                          type: object
                          properties:
                            period:
                              type: string
                              enum:
                                - days
                                - weeks
                                - months
                                - years
                            count:
                              type: number
                          required:
                            - period
                            - count
                          description: Deprecated field, please use `contract_terms`.
                          example:
                            period: years
                            count: 1
                          deprecated: true
                        minimum_invoice_fee:
                          type:
                            - number
                            - 'null'
                          description: >-
                            Minimum fee applied to each invoice outside of one
                            time payments.
                          example: 250
                        contract_terms:
                          allOf:
                            - type: object
                              properties:
                                starts_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    Start date of the contract. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                ends_at:
                                  type: string
                                  format: date-time
                                  description: >-
                                    End date of the contract. UTC date time
                                    string in the [ISO
                                    8601](https://en.wikipedia.org/wiki/ISO_8601)
                                    format.
                                  example: '2024-12-20T16:04:11Z'
                                duration:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: integer
                                      minimum: 1
                                      default: 1
                                  required:
                                    - period
                                  description: >-
                                    Interval over which the contract initially
                                    spans. Only applies to `duration` end
                                    strategy.
                                  example:
                                    count: 6
                                    period: months
                                renew_automatically:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >

                                    Indicates if the contract should be renewed
                                    automatically.


                                    - `true`: The contract will be renewed
                                    automatically.

                                    - `false`: The contract will not be renewed
                                    automatically.
                                  example: true
                                renew_for_duration:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: integer
                                      minimum: 1
                                      default: 1
                                  required:
                                    - period
                                  description: >

                                    Interval over which the contract will be
                                    renewed. Only applies if
                                    `renew_automatically` is true.
                                  example:
                                    count: 1
                                    period: years
                            - type: object
                              properties:
                                activation_strategy:
                                  type: string
                                  enum:
                                    - start_date
                                    - immediately
                                    - manual
                                    - quote_signature
                                    - checkout
                                  description: >

                                    Activation strategy of the contract.


                                    - `immediately`: The contract will be
                                    activated immediately.

                                    - `manual`: The contract will be activated
                                    when a user manually activates it.

                                    - `start_date`: The contract will be
                                    activated on a specified date.

                                    - `quote_signature`: The contract will be
                                    activated when the subscription quote is
                                    signed.

                                    - `checkout`: The contract will be activated
                                    when the subscription checkout is completed.
                                  example: start_date
                                end_strategy:
                                  type: string
                                  enum:
                                    - end_date
                                    - duration
                                    - manual
                                  description: >

                                    End strategy of contract.


                                    - `manual`: The contract ends when a user
                                    manually stops it.

                                    - `end_date`: The contract ends on a
                                    specified date.

                                    - `duration`: The contract ends after a
                                    specific relative duration, unless
                                    `renew_automatically` is true.
                                  example: duration
                              required:
                                - activation_strategy
                                - end_strategy
                          description: Contract terms linked to the subscription.
                        starts_at:
                          type: string
                          format: date-time
                          description: >-
                            Applies only if the activation strategy is
                            `start_date`. UTC date time string in the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        contract_start:
                          type: string
                          format: date-time
                          description: Deprecated field, please use `contract_terms`.
                          example: '2024-01-15T00:00:00Z'
                          deprecated: true
                        contract_end:
                          type: string
                          format: date-time
                          description: Deprecated field, please use `contract_terms`.
                          example: '2025-01-15T00:00:00Z'
                          deprecated: true
                        initial_billing_at:
                          type: string
                          format: date-time
                          description: >-
                            Date when the subscription will start being billed.
                            If not specified, it will correspond to the
                            `starts_at` date. UTC date time string in the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        payment_method_id:
                          type: string
                          description: >-
                            ID of the customer's payment method used to pay the
                            subscription's invoices, instead of the customer's
                            default one. Cannot be combined with
                            `bank_account_id`. Omit to use the customer's
                            payment method.
                          example: pm_abc123
                        bank_account_id:
                          type: string
                          description: >-
                            ID of the bank account displayed on the
                            subscription's invoices, which are then paid by bank
                            transfer, instead of the customer's default payment
                            method. Cannot be combined with `payment_method_id`.
                            Omit to use the customer's payment method.
                          example: bac_abc123
                        shipping_address_id:
                          type: string
                          description: >-
                            ID of the customer's active shipping address the
                            subscription ships to. Omit to use the customer
                            shipping destination: billing address or default
                            shipping address.
                          example: cad_abc123
                        display_shipping_details:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            Indicates if the shipping details should be
                            displayed on the subscription's invoices.
                        cancel_at:
                          type: string
                          format: date-time
                          description: >-
                            Subscription cancel date. UTC date time string in
                            the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        cancellation_strategy:
                          type: string
                          enum:
                            - refund_prorata
                            - refund_custom
                            - charge_prorata
                            - charge_custom
                            - end_of_period
                            - do_nothing
                          description: >

                            Strategy used to cancel the subscription. If not
                            specified `do_nothing` is used.


                            - `charge_prorata`: Will charge the customer the
                            unpaid amount for the prorated period up to the end
                            of the current period.

                            - `charge_custom`: Will charge the customer a custom
                            amount.

                            - `refund_prorata`: Will refund to the customer the
                            overpaid subscription amount using prorated
                            calculations on the cancellation date.

                            - `refund_custom`: Will refund to the customer a
                            custom amount.

                            - `end_of_period`: Will cancel the subscription at
                            the end date of the current billing period.

                            - `do_nothing`: Will only cease the subscription
                            without any additional actions.
                        cancellation_amount:
                          type: number
                          description: >-
                            Custom amount used when cancelling the subscription.
                            Only applies to the `charge_custom` or the
                            `refund_custom` cancellation strategy.
                        cancellation_refund_method:
                          type: string
                          enum:
                            - wallet
                            - original_payment_method
                            - external
                          description: >-
                            Override the refund destination for credit notes
                            generated by `refund_prorata` / `refund_custom`
                            cancellation strategies. When omitted, falls back to
                            the invoicing entity's
                            `creditNoteWalletRefundEnabled` setting.
                        properties:
                          type: object
                          additionalProperties:
                            anyOf:
                              - type: string
                              - type: number
                              - type: boolean
                              - type: 'null'
                              - type: array
                                items:
                                  anyOf:
                                    - type: string
                                    - type: number
                                    - type: boolean
                                    - type: 'null'
                                    - type: 'null'
                              - type: 'null'
                          description: >-
                            Key/value pairs to store any metadata useful in your
                            context.
                        custom_properties:
                          type: object
                          additionalProperties:
                            anyOf:
                              - type: string
                              - type: number
                              - type: boolean
                              - type: string
                                format: date-time
                                description: >-
                                  UTC date time string in the [ISO
                                  8601](https://en.wikipedia.org/wiki/ISO_8601)
                                  format.
                                example: '2024-12-20T16:04:11Z'
                              - type: array
                                items:
                                  type: string
                              - type: 'null'
                          description: >-
                            A list of key value with the slug of the custom
                            property as the key and the custom property value as
                            value.
                        tax_only:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: Only tax will be charged on this subscription.
                        generate_draft_invoices:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            Generate draft invoices for the subscription. Each
                            invoice will need to be reviewed and validated
                            manually before being sent
                        generate_document:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: Generate non-legal documents instead of invoices.
                        document_name:
                          type:
                            - string
                            - 'null'
                          description: >-
                            If `generate_document` is turned on, allows you to
                            give a name to your document.
                        add_tax_to_document:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            If `generate_document` is turned on, will add taxes
                            to document.
                        do_not_charge_subscription:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >-
                            Subscription will be invoiced but not charged
                            (invoices/documents will be settled directly).
                        invoice_custom_note:
                          type:
                            - string
                            - 'null'
                          description: >-
                            Default custom note added to invoices generated by
                            the subscription.
                        invoice_schedule:
                          type:
                            - string
                            - 'null'
                          enum:
                            - period_start
                            - period_end
                          description: >

                            Defines when invoices are generated relative to the
                            billing period.


                            - `period_start`: Invoices are generated at the
                            start of the billing period.

                            - `period_end`: Invoices are generated at the end of
                            the billing period.
                    - anyOf:
                        - type: object
                          properties:
                            phases:
                              type: array
                              items:
                                type: object
                                properties:
                                  name:
                                    type: string
                                    description: Name of the subscription phase.
                                    example: Initial term
                                  type:
                                    type: string
                                    enum:
                                      - setup
                                      - trial
                                      - standard
                                    default: standard
                                    description: >

                                      Type of subscription phase.


                                      - `setup`: The phase represents a
                                      non-recurring service setup period, often
                                      used before the actual recurring
                                      subscription begins.

                                      - `trial`: The phase represents a
                                      non-recurring trial period, often used to
                                      allow users to opt out or experience a
                                      free test.

                                      - `standard`: The phase represents a
                                      standard recurring billing.
                                    example: standard
                                  status:
                                    type: string
                                    enum:
                                      - finished
                                      - pending
                                    default: pending
                                    description: >

                                      Status of subscription phase.


                                      - `pending`: The phase is waiting to start
                                      (not started yet).

                                      - `active`: The phase is currently in
                                      progress.

                                      - `finished`: The phase has ended and is
                                      complete.
                                    example: pending
                                  order:
                                    type: number
                                    description: >-
                                      Order in which the phase is executed
                                      within all subscription phases.
                                    example: 0
                                  end_strategy:
                                    type: string
                                    enum:
                                      - manual
                                      - end_date
                                      - duration
                                      - contract_end_date
                                    description: >

                                      End strategy of subscription phase.


                                      - `manual`: The phase ends when a user
                                      manually stops it.

                                      - `end_date`: The phase ends on a
                                      specified date.

                                      - `duration`: The phase ends after a
                                      specific relative duration.

                                      - `contract_end_date`: The phase ends on
                                      the end date of the related subscription
                                      contract.
                                    example: duration
                                  duration:
                                    type: object
                                    properties:
                                      period:
                                        type: string
                                        enum:
                                          - days
                                          - weeks
                                          - months
                                          - years
                                      count:
                                        type: integer
                                        minimum: 1
                                        default: 1
                                    required:
                                      - period
                                    description: >-
                                      Interval over which the subscription phase
                                      spans. Only applies to `duration` end
                                      strategy.
                                    example:
                                      count: 1
                                      period: years
                                  billing_date_setting:
                                    type: string
                                    enum:
                                      - phase_start
                                      - specific_date
                                    description: >

                                      Represents when the first billing date
                                      occurs.


                                      - `phase_start`: Aligns with the start of
                                      the phase.

                                      - `specific_date`: Occurs on a specified
                                      date.
                                    example: phase_start
                                  initial_billing_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Date when the subscription phase will
                                      start being billed. Only applies to
                                      `specific_date` billing date setting. UTC
                                      date time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  starts_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Actual start date of the phase. UTC date
                                      time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  ends_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Actual end date of the phase. UTC date
                                      time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  billing_cycle_alignment:
                                    type: string
                                    enum:
                                      - calendar_period
                                      - anniversary
                                    description: >

                                      Alignment of product billing cycles. If
                                      omitted at creation, the billing cycles
                                      alignment configured in the account
                                      subscription settings applies.


                                      - `calendar_period`: The billing cycles of
                                      the products will be aligned on the
                                      calendar period, after the first period
                                      which will be invoiced taking into account
                                      the prorata of the first cycle compared to
                                      the product periodicity.

                                      - `anniversary`: The billing cycles of the
                                      products will be aligned on the
                                      anniversary of the phase initial billing
                                      date.
                                    example: anniversary
                                  do_not_invoice_phase:
                                    type: boolean
                                    default: false
                                    description: >-
                                      Indicates if the phase should be invoiced.
                                      If set to true, the phase will not
                                      generate any invoices.
                                    example: false
                                  minimum_invoice_fee:
                                    type:
                                      - number
                                      - 'null'
                                    minimum: 0
                                    description: >-
                                      Phase minimum fee in minor currency units,
                                      after discounts and before tax. Null
                                      disables it and clears the product
                                      selection.
                                    example: 10000
                                  minimum_invoice_fee_products:
                                    type:
                                      - array
                                      - 'null'
                                    items:
                                      type: string
                                    description: >-
                                      Catalog product IDs eligible for the phase
                                      minimum fee. Null or an empty list
                                      includes all billed debit products in the
                                      phase.
                                    example:
                                      - itm_aaaaaaaaaaaaaa
                                  transition_calculation_method:
                                    type: string
                                    enum:
                                      - prorata
                                      - pay_in_full
                                      - none
                                    default: prorata
                                    description: >

                                      Calculation method used when transitioning
                                      from one phase to the next one.


                                      - `prorata`: The prorated amount between
                                      the two phases relative to the end date
                                      (the transition date) must be paid.

                                      - `pay_in_full`: The full amount for the
                                      phase billing period must be paid.

                                      - `none`: No amount will need to be paid,
                                      phase will simply transition from one to
                                      the next.
                                    example: prorata
                                  transition_invoicing_schedule:
                                    type: string
                                    enum:
                                      - immediately
                                    default: immediately
                                    description: >

                                      Represents when the transition amount will
                                      be invoiced.


                                      - `immediately`: An invoice will be
                                      generated immediately with the
                                      corresponding amount.
                                    example: immediately
                                  products:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        id:
                                          type: string
                                          description: Product ID.
                                          example: itm_FJKlqUb8COXw55
                                        catalog_version_id:
                                          type:
                                            - string
                                            - 'null'
                                          description: >-
                                            ID of a published catalog version to
                                            price this product from, instead of the
                                            live products catalog. Ignored when
                                            `price` or `prices` is set. The product
                                            must be priced in that version.
                                          example: pcv_9x8v7u6t5s4r
                                        price_configuration_id:
                                          type:
                                            - string
                                            - 'null'
                                          description: >-
                                            ID of the product's price configuration
                                            to price this product from, instead of
                                            the one the catalog rules select. It
                                            must be a live base configuration of the
                                            product (not archived or replaced by a
                                            later catalog publish, and not specific
                                            to a customer, price book, customer
                                            segment or plan), in the subscription's
                                            currency. Requires `payment_interval`,
                                            which it must match. The configuration's
                                            country and commitment restrictions are
                                            not checked. With a pinned catalog
                                            version, the product is priced from that
                                            version's copy of the configuration, and
                                            a configuration the version doesn't
                                            price returns a 400. Cannot be combined
                                            with `price`, `prices` or `plan_id`.
                                          example: prc_8f3kXODIM1sBwB
                                        name:
                                          type: string
                                          description: >-
                                            Product name. This will appear on the
                                            final invoices.
                                          example: Product name
                                        description:
                                          type: string
                                          description: >-
                                            Product description. This will appear on
                                            the final invoices.
                                          example: A description of the product.
                                        description_display_interval_dates:
                                          type: boolean
                                          default: false
                                          description: >-
                                            Indicates if the dates of the interval
                                            should be automatically added in the
                                            product description on the invoices.
                                        payment_interval:
                                          anyOf:
                                            - type: object
                                              properties:
                                                period:
                                                  type: string
                                                  enum:
                                                    - once
                                              required:
                                                - period
                                              title: Once
                                              example:
                                                period: once
                                            - type: object
                                              properties:
                                                period:
                                                  type: string
                                                  enum:
                                                    - days
                                                    - weeks
                                                    - months
                                                    - years
                                                count:
                                                  type: integer
                                                  minimum: 1
                                                  default: 1
                                              required:
                                                - period
                                              title: Period
                                              example:
                                                period: months
                                                count: 1
                                          description: >-
                                            Interval on which the product is billed.
                                            This interval can be different between
                                            products and can differ from the
                                            subscription commitment interval.
                                        payment_schedule:
                                          type: string
                                          enum:
                                            - start
                                            - end
                                          description: >-
                                            Indicates if the product should be
                                            billed at the start or the end of the
                                            payment interval.
                                          example: start
                                        price:
                                          type: object
                                          properties:
                                            type:
                                              type: string
                                              enum:
                                                - fee
                                            amount:
                                              type: number
                                              description: >-
                                                Monetary amount. Expressed in currency's
                                                smallest unit.
                                          required:
                                            - type
                                            - amount
                                          description: >-
                                            Similar to `prices`, allow to apply a
                                            single fee price more easily.
                                          example:
                                            type: fee
                                            amount: 200
                                        prices:
                                          type: array
                                          items:
                                            oneOf:
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - fee
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount. Expressed in currency's
                                                      smallest unit.
                                                required:
                                                  - type
                                                  - amount
                                                title: Fee price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - volume
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                  from:
                                                    type: number
                                                    description: From limit.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  on_tier_incomplete:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - pro_rata
                                                      - pay_in_full
                                                      - do_not_charge
                                                      - flat_per_tier
                                                    default: pro_rata
                                                    description: >-

                                                      Logic used to compute the amount when
                                                      usage on the tier is incomplete.


                                                      - `pro_rata`: The amount is computed
                                                      using the pro rata of the tier's
                                                      consumption.

                                                      - `pay_in_full`: The amount corresponds
                                                      to the full payment of the tier.

                                                      - `do_not_charge`: The tier is not
                                                      charged and ignored.

                                                      - `flat_per_tier`: The tier's `amount`
                                                      is a flat fee, billed once as soon as
                                                      usage reaches the tier, whatever the
                                                      number of units in it. `unitCount` is
                                                      ignored. No usage bills nothing.
                                                        
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                  - from
                                                  - to
                                                title: Volume price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - packaged
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                  from:
                                                    type: number
                                                    description: From limit.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  on_bucket_incomplete:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - pro_rata
                                                      - pay_in_full
                                                      - do_not_charge
                                                      - flat_per_tier
                                                    default: pro_rata
                                                    description: >-

                                                      Logic used to compute the amount when
                                                      usage reaches an incomplete bucket (the
                                                      bucket size corresponds to the
                                                      `unitCount`).

                                                        - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                        - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                        - `do_not_charge`: The bucket is not charged and ignored.
                                                        - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                          
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                  - from
                                                  - to
                                                title: Packaged price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - bulk
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  on_tier_incomplete:
                                                    type:
                                                      - string
                                                      - 'null'
                                                    enum:
                                                      - pro_rata
                                                      - pay_in_full
                                                      - do_not_charge
                                                      - flat_per_tier
                                                    default: pro_rata
                                                    description: >-

                                                      Logic used to compute the amount when
                                                      usage on the tier is incomplete.


                                                      - `pro_rata`: The amount is computed
                                                      using the pro rata of the tier's
                                                      consumption.

                                                      - `pay_in_full`: The amount corresponds
                                                      to the full payment of the tier.

                                                      - `do_not_charge`: The tier is not
                                                      charged and ignored.

                                                      - `flat_per_tier`: The tier's `amount`
                                                      is a flat fee, billed once as soon as
                                                      usage reaches the tier, whatever the
                                                      number of units in it. `unitCount` is
                                                      ignored. No usage bills nothing.
                                                        
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                  - to
                                                title: Bulk price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - bps
                                                  from:
                                                    type: number
                                                    description: From limit.
                                                  to:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: To limit.
                                                  percentage:
                                                    type: number
                                                    description: >-
                                                      Percentage applied on each unit to
                                                      compute the usage.
                                                  per_unit_cap:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: >-
                                                      Maximum amount for one unit. Expressed
                                                      in currency's smallest unit.
                                                  per_unit_floor:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: >-
                                                      Minimum amount for one unit. Expressed
                                                      in currency's smallest unit.
                                                  per_unit_fee:
                                                    type:
                                                      - number
                                                      - 'null'
                                                    description: >-
                                                      Fee amount applied per unit. Expressed
                                                      in currency's smallest unit.
                                                  metering_filter:
                                                    allOf:
                                                      - $ref: '#/components/schemas/MeteringFilter'
                                                      - type: object
                                                        description: >-
                                                          Metering filter that scopes which
                                                          billable events are eligible for this
                                                          price tier. Only present when the price
                                                          is filtered.
                                                required:
                                                  - type
                                                  - from
                                                  - to
                                                  - percentage
                                                  - per_unit_cap
                                                  - per_unit_floor
                                                  - per_unit_fee
                                                title: BPS price
                                              - type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - bundle
                                                  amount:
                                                    type: number
                                                    description: >-
                                                      Monetary amount of the price for the
                                                      number of units defined by `unit_count`.
                                                      Expressed in currency's smallest unit.
                                                  unit_count:
                                                    type: number
                                                    description: >-
                                                      Number of units considered for the
                                                      amount.
                                                required:
                                                  - type
                                                  - amount
                                                  - unit_count
                                                title: Bundle price
                                                description: >-
                                                  For seat products only, if you are
                                                  looking for credits, use a fee price
                                          description: >-
                                            Prices of the product. If not specified,
                                            the matching prices (depending on the
                                            currency, interval, etc) of the product
                                            defined in the products catalog/plan are
                                            used.
                                          example:
                                            - type: volume
                                              from: 0
                                              to: 20
                                              amount: 200
                                              unit_count: 1
                                              on_tier_incomplete: null
                                            - type: volume
                                              from: 20
                                              to: null
                                              amount: 150
                                              unit_count: 1
                                              on_tier_incomplete: null
                                        count:
                                          type: number
                                          minimum: 1
                                          description: >-
                                            Number of product units. Only applies to
                                            products of type `flat_fee`, `seat` or
                                            `credit`.
                                          example: 2
                                        unit_name:
                                          type: string
                                          description: >-
                                            Product name. This will appear on the
                                            final invoices. Only applies to products
                                            of type `seat` or `usage`.
                                          example: user
                                        min_committed_count:
                                          type: number
                                          minimum: 1
                                          description: >-
                                            Minimum of units committed. If usage is
                                            less than this number, then this value
                                            will be used. Only applies to products
                                            of type `usage`.
                                        min_amount:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Minimum amount billed. If the final
                                            computed amount from the usage for this
                                            product is less than this amount, then
                                            this value will be used. Only applies to
                                            products of type `usage`.
                                        max_amount:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Maximum amount billed. If the final
                                            computed amount from the usage for this
                                            product is greater than this amount,
                                            then this value will be used. Only
                                            applies to products of type `usage`.
                                        charging_method:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - prorata
                                            - pay_in_full
                                            - do_not_charge
                                          description: >-
                                            Charging method for seat count updates
                                            within the current billing period. Only
                                            applies to connected seat products.


                                            - `prorata`: Price calculated
                                            proportionally to time elapsed in the
                                            billing period.

                                            - `pay_in_full`: Price calculated for
                                            the entire billing period.

                                            - `do_not_charge`: No charge for the
                                            update.
                                        seat_invoicing_schedule:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - immediately
                                            - next_invoice
                                            - custom
                                          description: >

                                            Policy defining when seat count changes
                                            are invoiced. Only applies to connected
                                            seat products.


                                            - `immediately`: Seat changes are
                                            invoiced immediately.

                                            - `next_invoice`: Seat changes are
                                            invoiced at the next invoice.

                                            - `custom`: Seat changes are invoiced on
                                            a custom schedule.
                                        metering_interval_type:
                                          type: string
                                          enum:
                                            - subscription_commitment
                                            - payment_interval
                                            - full_database
                                            - phase_duration
                                            - custom
                                          description: >-

                                            Indicates on which type of interval the
                                            usage should be aggregated.


                                            - `subscription_commitment`: For the
                                            usage contained within the subscription
                                            commitment period.

                                            - `payment_interval`: For the usage
                                            contained within the payment interval of
                                            the product.

                                            - `full_database`: For all the usage we
                                            ingested for this product, no matter the
                                            period.

                                            - `phase_duration`: For the usage
                                            contained within the subscription phase.

                                            - `custom`: For the usage contained
                                            within a custom interval that starts
                                            with the phase and renews independently
                                            of the billing interval. Requires
                                            `metering_interval` to be set.
                                               Only applies to products of type `usage`.
                                        metering_interval:
                                          type: object
                                          properties:
                                            period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                            count:
                                              type: integer
                                              minimum: 1
                                          required:
                                            - period
                                            - count
                                          description: >-
                                            Custom interval for usage aggregation.
                                            Required when `metering_interval_type`
                                            is `custom`. The interval starts at the
                                            phase start and renews on its own cycle
                                            (e.g. `{ period: 'months', count: 3 }`
                                            for quarterly metering with monthly
                                            billing). Only applies to products of
                                            type `usage`.
                                        bill_usage_difference:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          default: false
                                          description: >-
                                            Only bill the usage difference comparing
                                            to the previous period (i.e. actual
                                            amount minus last invoice amount).
                                            Doesn't apply to `payment_interval`
                                            metering interval type. Only applies to
                                            products of type `usage`.
                                        children_usage_aggregation:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - sum
                                            - max
                                          description: >-

                                            Controls whether a parent organization's
                                            metered usage is billed on the combined
                                            usage of the parent and its direct
                                            children, and how per-member values are
                                            combined.


                                            - `null`: Organization-based usage is
                                            disabled. Only the subscription
                                            customer's own usage is billed.

                                            - `sum`: The usage values of the parent
                                            and each direct child are added together
                                            (organization total).

                                            - `max`: Only the single
                                            highest-consuming member (parent or one
                                            direct child) is billed.
                                             Only applies to products of type `usage`.
                                        credits_expiration_in_days:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Validity in days for credits that will
                                            be topped-up automatically. Once the
                                            period has passed, they'll expire.
                                        expire_credits_at_end_of_period:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          default: false
                                          description: >-
                                            Automatically set the expiration date to
                                            the end of the next period for each
                                            topup. Takes priority on
                                            `creditsExpirationInDays`
                                        credits_balance_auto_creation_enabled:
                                          anyOf:
                                            - type: boolean
                                            - type: string
                                              enum:
                                                - 'true'
                                                - 'false'
                                          description: >-
                                            Whether to create the customer credit
                                            balance as soon as the product is added
                                            to the subscription. Defaults to the
                                            credit product's
                                            `credits_balance_auto_creation_enabled`
                                            (`true` when unset). Set to `false` to
                                            create the balance by hand before
                                            activation, e.g. on quote-based renewals
                                            where the balance must not start
                                            consuming before signature; the first
                                            top-up creates it if still missing.
                                        estimated_count:
                                          type:
                                            - number
                                            - 'null'
                                          minimum: 0
                                          maximum: 1000000000000
                                          description: >-
                                            Estimated number of units, for recurring
                                            usage-based and connected seat products
                                            (ignored on any other product, and not
                                            priced for a usage-based product with
                                            several filtered price groups). It
                                            prices the quote value and is shown as
                                            an estimate on the quote, but is never
                                            billed: invoices use the measured usage
                                            or seat count.
                                          example: 200
                                      required:
                                        - id
                                    description: >-
                                      Products comprising the subscription
                                      phase.
                                  coupons:
                                    type: array
                                    items:
                                      allOf:
                                        - anyOf:
                                            - type: object
                                              properties:
                                                id:
                                                  type: string
                                                  description: >-
                                                    ID of the catalog coupon to apply to the
                                                    subscription.
                                              required:
                                                - id
                                              title: Existing coupon
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - amount
                                                name:
                                                  type: string
                                                  description: Coupon name.
                                                discount_amount:
                                                  type: number
                                                  exclusiveMinimum: 0
                                                  description: >-
                                                    Coupon discount amount. Expressed in
                                                    currency's smallest unit.
                                              required:
                                                - type
                                                - discount_amount
                                              title: Coupon amount
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - percent
                                                name:
                                                  type: string
                                                  description: Coupon name.
                                                discount_percent:
                                                  type: number
                                                  exclusiveMinimum: 0
                                                  maximum: 100
                                                  description: Coupon discount percentage.
                                              required:
                                                - type
                                                - discount_percent
                                              title: Coupon percent
                                        - type: object
                                          properties:
                                            repeat:
                                              type:
                                                - string
                                                - 'null'
                                              enum:
                                                - once
                                                - forever
                                                - custom
                                                - duration
                                              description: >

                                                Coupon frequency. Required for inline
                                                coupons. Optional when an existing
                                                coupon `id` is provided: if omitted,
                                                defaults to the catalog coupon's repeat
                                                value.


                                                - `once`: Will apply the coupon only to
                                                the first one invoice.

                                                - `forever`: Will apply the coupon to
                                                all invoices.

                                                - `custom`: Will apply to coupon until a
                                                specified expiration date.

                                                - `duration`: Will apply the coupon for
                                                a specific duration (e.g., 3 months).
                                            duration_period:
                                              type: string
                                              enum:
                                                - days
                                                - weeks
                                                - months
                                                - years
                                              description: >-
                                                Period of time for which the coupon will
                                                be applied. Only applies to the
                                                `duration` coupon frequency.
                                            duration_count:
                                              type: number
                                              description: >-
                                                Number of periods for which the coupon
                                                will be applied. Only applies to the
                                                `duration` coupon frequency.
                                            expires_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Coupon expiration date. Only applies to
                                                the `custom` coupon frequency. UTC date
                                                time string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            apply_at:
                                              type: string
                                              format: date-time
                                              description: >-
                                                Coupon first application date. UTC date
                                                time string in the [ISO
                                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                                format.
                                              example: '2024-12-20T16:04:11Z'
                                            product_ids:
                                              type:
                                                - array
                                                - 'null'
                                              items:
                                                type: string
                                              minItems: 1
                                              description: >-
                                                Products the coupon is scoped to on this
                                                subscription, read together with
                                                `product_scope`: the only discounted
                                                products when `include`, the products
                                                never discounted when `exclude`, null
                                                when `all`. When sent without
                                                `product_scope`, it is an `include`
                                                list, except that a coupon already
                                                stored as `exclude` keeps `exclude` when
                                                its phase is updated; when empty or
                                                omitted, the catalog coupon's scope is
                                                copied.
                                            product_scope:
                                              type:
                                                - string
                                                - 'null'
                                              enum:
                                                - all
                                                - include
                                                - exclude
                                              description: >-
                                                Which products the coupon discounts on
                                                this subscription. `all`: every product
                                                (`product_ids` must be empty).
                                                `include`: only the products in
                                                `product_ids`. `exclude`: every product
                                                except those in `product_ids` (lines
                                                without a product stay discounted). When
                                                sent, it replaces the catalog coupon's
                                                scope together with `product_ids`. When
                                                omitted, it is inferred: `include` if
                                                `product_ids` is non-empty, else the
                                                catalog coupon's scope. On a phase
                                                update, a coupon already stored as
                                                `exclude` keeps `exclude` when
                                                `product_ids` is sent without
                                                `product_scope`.
                                    description: Coupons comprising the subscription phase.
                                  activation_strategy:
                                    type: string
                                    enum:
                                      - manual
                                      - start_date
                                      - quote_signature
                                      - contract_start_date
                                      - previous_phase_end
                                    description: >

                                      Activation strategy of subscription phase.


                                      - `immediately`: The phase starts as soon
                                      as the subscription is activated.

                                      - `manual`: The phase starts when a user
                                      manually activates it.

                                      - `start_date`: The phase starts on a
                                      specified date.

                                      - `quote_signature`: The phase starts when
                                      the subscription quote is signed.

                                      - `checkout`: The phase starts when the
                                      subscription checkout is completed.

                                      - `contract_start_date`: The phase starts
                                      on the start date of the related
                                      subscription contract.

                                      - `previous_phase_end`: The phase starts
                                      when the previous phase ends.
                                    example: manual
                                required:
                                  - end_strategy
                                  - billing_date_setting
                                  - products
                                  - activation_strategy
                          required:
                            - phases
                          title: With phases
                        - allOf:
                            - type: object
                              properties:
                                activation_strategy:
                                  type: string
                                  enum:
                                    - start_date
                                    - manually
                                    - quote
                                  default: manually
                                  description: >

                                    Strategy used to activate the subscription.


                                    - `start_date`: The subscription will become
                                    active on the specified start date. If the
                                    start date is in the past, it will be
                                    activated immediately.

                                    - `manually`: The subscription requires
                                    activation through a manual action.

                                    - `checkout`: The subscription will be
                                    activated once the checkout is completed,
                                    but only if the start date is in the past.
                                    Otherwise, activation will occur later on
                                    the specified start date.

                                    - `quote`: The subscription will be
                                    activated depending on the configuration and
                                    the signature of the related quote.
                                  example: start_date
                                products:
                                  type: array
                                  items:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        description: Product ID.
                                        example: itm_FJKlqUb8COXw55
                                      catalog_version_id:
                                        type:
                                          - string
                                          - 'null'
                                        description: >-
                                          ID of a published catalog version to
                                          price this product from, instead of the
                                          live products catalog. Ignored when
                                          `price` or `prices` is set. The product
                                          must be priced in that version.
                                        example: pcv_9x8v7u6t5s4r
                                      price_configuration_id:
                                        type:
                                          - string
                                          - 'null'
                                        description: >-
                                          ID of the product's price configuration
                                          to price this product from, instead of
                                          the one the catalog rules select. It
                                          must be a live base configuration of the
                                          product (not archived or replaced by a
                                          later catalog publish, and not specific
                                          to a customer, price book, customer
                                          segment or plan), in the subscription's
                                          currency. Requires `payment_interval`,
                                          which it must match. The configuration's
                                          country and commitment restrictions are
                                          not checked. With a pinned catalog
                                          version, the product is priced from that
                                          version's copy of the configuration, and
                                          a configuration the version doesn't
                                          price returns a 400. Cannot be combined
                                          with `price`, `prices` or `plan_id`.
                                        example: prc_8f3kXODIM1sBwB
                                      name:
                                        type: string
                                        description: >-
                                          Product name. This will appear on the
                                          final invoices.
                                        example: Product name
                                      description:
                                        type: string
                                        description: >-
                                          Product description. This will appear on
                                          the final invoices.
                                        example: A description of the product.
                                      description_display_interval_dates:
                                        type: boolean
                                        default: false
                                        description: >-
                                          Indicates if the dates of the interval
                                          should be automatically added in the
                                          product description on the invoices.
                                      payment_interval:
                                        anyOf:
                                          - type: object
                                            properties:
                                              period:
                                                type: string
                                                enum:
                                                  - once
                                            required:
                                              - period
                                            title: Once
                                            example:
                                              period: once
                                          - type: object
                                            properties:
                                              period:
                                                type: string
                                                enum:
                                                  - days
                                                  - weeks
                                                  - months
                                                  - years
                                              count:
                                                type: integer
                                                minimum: 1
                                                default: 1
                                            required:
                                              - period
                                            title: Period
                                            example:
                                              period: months
                                              count: 1
                                        description: >-
                                          Interval on which the product is billed.
                                          This interval can be different between
                                          products and can differ from the
                                          subscription commitment interval.
                                      payment_schedule:
                                        type: string
                                        enum:
                                          - start
                                          - end
                                        description: >-
                                          Indicates if the product should be
                                          billed at the start or the end of the
                                          payment interval.
                                        example: start
                                      price:
                                        type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - fee
                                          amount:
                                            type: number
                                            description: >-
                                              Monetary amount. Expressed in currency's
                                              smallest unit.
                                        required:
                                          - type
                                          - amount
                                        description: >-
                                          Similar to `prices`, allow to apply a
                                          single fee price more easily.
                                        example:
                                          type: fee
                                          amount: 200
                                      prices:
                                        type: array
                                        items:
                                          oneOf:
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - fee
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount. Expressed in currency's
                                                    smallest unit.
                                              required:
                                                - type
                                                - amount
                                              title: Fee price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - volume
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                                from:
                                                  type: number
                                                  description: From limit.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                on_tier_incomplete:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - pro_rata
                                                    - pay_in_full
                                                    - do_not_charge
                                                    - flat_per_tier
                                                  default: pro_rata
                                                  description: >-

                                                    Logic used to compute the amount when
                                                    usage on the tier is incomplete.


                                                    - `pro_rata`: The amount is computed
                                                    using the pro rata of the tier's
                                                    consumption.

                                                    - `pay_in_full`: The amount corresponds
                                                    to the full payment of the tier.

                                                    - `do_not_charge`: The tier is not
                                                    charged and ignored.

                                                    - `flat_per_tier`: The tier's `amount`
                                                    is a flat fee, billed once as soon as
                                                    usage reaches the tier, whatever the
                                                    number of units in it. `unitCount` is
                                                    ignored. No usage bills nothing.
                                                      
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                                - from
                                                - to
                                              title: Volume price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - packaged
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                                from:
                                                  type: number
                                                  description: From limit.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                on_bucket_incomplete:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - pro_rata
                                                    - pay_in_full
                                                    - do_not_charge
                                                    - flat_per_tier
                                                  default: pro_rata
                                                  description: >-

                                                    Logic used to compute the amount when
                                                    usage reaches an incomplete bucket (the
                                                    bucket size corresponds to the
                                                    `unitCount`).

                                                      - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                      - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                      - `do_not_charge`: The bucket is not charged and ignored.
                                                      - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                        
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                                - from
                                                - to
                                              title: Packaged price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - bulk
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                on_tier_incomplete:
                                                  type:
                                                    - string
                                                    - 'null'
                                                  enum:
                                                    - pro_rata
                                                    - pay_in_full
                                                    - do_not_charge
                                                    - flat_per_tier
                                                  default: pro_rata
                                                  description: >-

                                                    Logic used to compute the amount when
                                                    usage on the tier is incomplete.


                                                    - `pro_rata`: The amount is computed
                                                    using the pro rata of the tier's
                                                    consumption.

                                                    - `pay_in_full`: The amount corresponds
                                                    to the full payment of the tier.

                                                    - `do_not_charge`: The tier is not
                                                    charged and ignored.

                                                    - `flat_per_tier`: The tier's `amount`
                                                    is a flat fee, billed once as soon as
                                                    usage reaches the tier, whatever the
                                                    number of units in it. `unitCount` is
                                                    ignored. No usage bills nothing.
                                                      
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                                - to
                                              title: Bulk price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - bps
                                                from:
                                                  type: number
                                                  description: From limit.
                                                to:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: To limit.
                                                percentage:
                                                  type: number
                                                  description: >-
                                                    Percentage applied on each unit to
                                                    compute the usage.
                                                per_unit_cap:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Maximum amount for one unit. Expressed
                                                    in currency's smallest unit.
                                                per_unit_floor:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Minimum amount for one unit. Expressed
                                                    in currency's smallest unit.
                                                per_unit_fee:
                                                  type:
                                                    - number
                                                    - 'null'
                                                  description: >-
                                                    Fee amount applied per unit. Expressed
                                                    in currency's smallest unit.
                                                metering_filter:
                                                  allOf:
                                                    - $ref: '#/components/schemas/MeteringFilter'
                                                    - type: object
                                                      description: >-
                                                        Metering filter that scopes which
                                                        billable events are eligible for this
                                                        price tier. Only present when the price
                                                        is filtered.
                                              required:
                                                - type
                                                - from
                                                - to
                                                - percentage
                                                - per_unit_cap
                                                - per_unit_floor
                                                - per_unit_fee
                                              title: BPS price
                                            - type: object
                                              properties:
                                                type:
                                                  type: string
                                                  enum:
                                                    - bundle
                                                amount:
                                                  type: number
                                                  description: >-
                                                    Monetary amount of the price for the
                                                    number of units defined by `unit_count`.
                                                    Expressed in currency's smallest unit.
                                                unit_count:
                                                  type: number
                                                  description: >-
                                                    Number of units considered for the
                                                    amount.
                                              required:
                                                - type
                                                - amount
                                                - unit_count
                                              title: Bundle price
                                              description: >-
                                                For seat products only, if you are
                                                looking for credits, use a fee price
                                        description: >-
                                          Prices of the product. If not specified,
                                          the matching prices (depending on the
                                          currency, interval, etc) of the product
                                          defined in the products catalog/plan are
                                          used.
                                        example:
                                          - type: volume
                                            from: 0
                                            to: 20
                                            amount: 200
                                            unit_count: 1
                                            on_tier_incomplete: null
                                          - type: volume
                                            from: 20
                                            to: null
                                            amount: 150
                                            unit_count: 1
                                            on_tier_incomplete: null
                                      count:
                                        type: number
                                        minimum: 1
                                        description: >-
                                          Number of product units. Only applies to
                                          products of type `flat_fee`, `seat` or
                                          `credit`.
                                        example: 2
                                      unit_name:
                                        type: string
                                        description: >-
                                          Product name. This will appear on the
                                          final invoices. Only applies to products
                                          of type `seat` or `usage`.
                                        example: user
                                      min_committed_count:
                                        type: number
                                        minimum: 1
                                        description: >-
                                          Minimum of units committed. If usage is
                                          less than this number, then this value
                                          will be used. Only applies to products
                                          of type `usage`.
                                      min_amount:
                                        type:
                                          - number
                                          - 'null'
                                        description: >-
                                          Minimum amount billed. If the final
                                          computed amount from the usage for this
                                          product is less than this amount, then
                                          this value will be used. Only applies to
                                          products of type `usage`.
                                      max_amount:
                                        type:
                                          - number
                                          - 'null'
                                        description: >-
                                          Maximum amount billed. If the final
                                          computed amount from the usage for this
                                          product is greater than this amount,
                                          then this value will be used. Only
                                          applies to products of type `usage`.
                                      charging_method:
                                        type:
                                          - string
                                          - 'null'
                                        enum:
                                          - prorata
                                          - pay_in_full
                                          - do_not_charge
                                        description: >-
                                          Charging method for seat count updates
                                          within the current billing period. Only
                                          applies to connected seat products.


                                          - `prorata`: Price calculated
                                          proportionally to time elapsed in the
                                          billing period.

                                          - `pay_in_full`: Price calculated for
                                          the entire billing period.

                                          - `do_not_charge`: No charge for the
                                          update.
                                      seat_invoicing_schedule:
                                        type:
                                          - string
                                          - 'null'
                                        enum:
                                          - immediately
                                          - next_invoice
                                          - custom
                                        description: >

                                          Policy defining when seat count changes
                                          are invoiced. Only applies to connected
                                          seat products.


                                          - `immediately`: Seat changes are
                                          invoiced immediately.

                                          - `next_invoice`: Seat changes are
                                          invoiced at the next invoice.

                                          - `custom`: Seat changes are invoiced on
                                          a custom schedule.
                                      metering_interval_type:
                                        type: string
                                        enum:
                                          - subscription_commitment
                                          - payment_interval
                                          - full_database
                                          - phase_duration
                                          - custom
                                        description: >-

                                          Indicates on which type of interval the
                                          usage should be aggregated.


                                          - `subscription_commitment`: For the
                                          usage contained within the subscription
                                          commitment period.

                                          - `payment_interval`: For the usage
                                          contained within the payment interval of
                                          the product.

                                          - `full_database`: For all the usage we
                                          ingested for this product, no matter the
                                          period.

                                          - `phase_duration`: For the usage
                                          contained within the subscription phase.

                                          - `custom`: For the usage contained
                                          within a custom interval that starts
                                          with the phase and renews independently
                                          of the billing interval. Requires
                                          `metering_interval` to be set.
                                             Only applies to products of type `usage`.
                                      metering_interval:
                                        type: object
                                        properties:
                                          period:
                                            type: string
                                            enum:
                                              - days
                                              - weeks
                                              - months
                                              - years
                                          count:
                                            type: integer
                                            minimum: 1
                                        required:
                                          - period
                                          - count
                                        description: >-
                                          Custom interval for usage aggregation.
                                          Required when `metering_interval_type`
                                          is `custom`. The interval starts at the
                                          phase start and renews on its own cycle
                                          (e.g. `{ period: 'months', count: 3 }`
                                          for quarterly metering with monthly
                                          billing). Only applies to products of
                                          type `usage`.
                                      bill_usage_difference:
                                        anyOf:
                                          - type: boolean
                                          - type: string
                                            enum:
                                              - 'true'
                                              - 'false'
                                        default: false
                                        description: >-
                                          Only bill the usage difference comparing
                                          to the previous period (i.e. actual
                                          amount minus last invoice amount).
                                          Doesn't apply to `payment_interval`
                                          metering interval type. Only applies to
                                          products of type `usage`.
                                      children_usage_aggregation:
                                        type:
                                          - string
                                          - 'null'
                                        enum:
                                          - sum
                                          - max
                                        description: >-

                                          Controls whether a parent organization's
                                          metered usage is billed on the combined
                                          usage of the parent and its direct
                                          children, and how per-member values are
                                          combined.


                                          - `null`: Organization-based usage is
                                          disabled. Only the subscription
                                          customer's own usage is billed.

                                          - `sum`: The usage values of the parent
                                          and each direct child are added together
                                          (organization total).

                                          - `max`: Only the single
                                          highest-consuming member (parent or one
                                          direct child) is billed.
                                           Only applies to products of type `usage`.
                                      credits_expiration_in_days:
                                        type:
                                          - number
                                          - 'null'
                                        description: >-
                                          Validity in days for credits that will
                                          be topped-up automatically. Once the
                                          period has passed, they'll expire.
                                      expire_credits_at_end_of_period:
                                        anyOf:
                                          - type: boolean
                                          - type: string
                                            enum:
                                              - 'true'
                                              - 'false'
                                        default: false
                                        description: >-
                                          Automatically set the expiration date to
                                          the end of the next period for each
                                          topup. Takes priority on
                                          `creditsExpirationInDays`
                                      credits_balance_auto_creation_enabled:
                                        anyOf:
                                          - type: boolean
                                          - type: string
                                            enum:
                                              - 'true'
                                              - 'false'
                                        description: >-
                                          Whether to create the customer credit
                                          balance as soon as the product is added
                                          to the subscription. Defaults to the
                                          credit product's
                                          `credits_balance_auto_creation_enabled`
                                          (`true` when unset). Set to `false` to
                                          create the balance by hand before
                                          activation, e.g. on quote-based renewals
                                          where the balance must not start
                                          consuming before signature; the first
                                          top-up creates it if still missing.
                                      estimated_count:
                                        type:
                                          - number
                                          - 'null'
                                        minimum: 0
                                        maximum: 1000000000000
                                        description: >-
                                          Estimated number of units, for recurring
                                          usage-based and connected seat products
                                          (ignored on any other product, and not
                                          priced for a usage-based product with
                                          several filtered price groups). It
                                          prices the quote value and is shown as
                                          an estimate on the quote, but is never
                                          billed: invoices use the measured usage
                                          or seat count.
                                        example: 200
                                    required:
                                      - id
                                  description: Products that make up the subscription.
                                coupons:
                                  type: array
                                  items:
                                    allOf:
                                      - anyOf:
                                          - type: object
                                            properties:
                                              id:
                                                type: string
                                                description: >-
                                                  ID of the catalog coupon to apply to the
                                                  subscription.
                                            required:
                                              - id
                                            title: Existing coupon
                                          - type: object
                                            properties:
                                              type:
                                                type: string
                                                enum:
                                                  - amount
                                              name:
                                                type: string
                                                description: Coupon name.
                                              discount_amount:
                                                type: number
                                                exclusiveMinimum: 0
                                                description: >-
                                                  Coupon discount amount. Expressed in
                                                  currency's smallest unit.
                                            required:
                                              - type
                                              - discount_amount
                                            title: Coupon amount
                                          - type: object
                                            properties:
                                              type:
                                                type: string
                                                enum:
                                                  - percent
                                              name:
                                                type: string
                                                description: Coupon name.
                                              discount_percent:
                                                type: number
                                                exclusiveMinimum: 0
                                                maximum: 100
                                                description: Coupon discount percentage.
                                            required:
                                              - type
                                              - discount_percent
                                            title: Coupon percent
                                      - type: object
                                        properties:
                                          repeat:
                                            type:
                                              - string
                                              - 'null'
                                            enum:
                                              - once
                                              - forever
                                              - custom
                                              - duration
                                            description: >

                                              Coupon frequency. Required for inline
                                              coupons. Optional when an existing
                                              coupon `id` is provided: if omitted,
                                              defaults to the catalog coupon's repeat
                                              value.


                                              - `once`: Will apply the coupon only to
                                              the first one invoice.

                                              - `forever`: Will apply the coupon to
                                              all invoices.

                                              - `custom`: Will apply to coupon until a
                                              specified expiration date.

                                              - `duration`: Will apply the coupon for
                                              a specific duration (e.g., 3 months).
                                          duration_period:
                                            type: string
                                            enum:
                                              - days
                                              - weeks
                                              - months
                                              - years
                                            description: >-
                                              Period of time for which the coupon will
                                              be applied. Only applies to the
                                              `duration` coupon frequency.
                                          duration_count:
                                            type: number
                                            description: >-
                                              Number of periods for which the coupon
                                              will be applied. Only applies to the
                                              `duration` coupon frequency.
                                          expires_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Coupon expiration date. Only applies to
                                              the `custom` coupon frequency. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          apply_at:
                                            type: string
                                            format: date-time
                                            description: >-
                                              Coupon first application date. UTC date
                                              time string in the [ISO
                                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                                              format.
                                            example: '2024-12-20T16:04:11Z'
                                          product_ids:
                                            type:
                                              - array
                                              - 'null'
                                            items:
                                              type: string
                                            minItems: 1
                                            description: >-
                                              Products the coupon is scoped to on this
                                              subscription, read together with
                                              `product_scope`: the only discounted
                                              products when `include`, the products
                                              never discounted when `exclude`, null
                                              when `all`. When sent without
                                              `product_scope`, it is an `include`
                                              list, except that a coupon already
                                              stored as `exclude` keeps `exclude` when
                                              its phase is updated; when empty or
                                              omitted, the catalog coupon's scope is
                                              copied.
                                          product_scope:
                                            type:
                                              - string
                                              - 'null'
                                            enum:
                                              - all
                                              - include
                                              - exclude
                                            description: >-
                                              Which products the coupon discounts on
                                              this subscription. `all`: every product
                                              (`product_ids` must be empty).
                                              `include`: only the products in
                                              `product_ids`. `exclude`: every product
                                              except those in `product_ids` (lines
                                              without a product stay discounted). When
                                              sent, it replaces the catalog coupon's
                                              scope together with `product_ids`. When
                                              omitted, it is inferred: `include` if
                                              `product_ids` is non-empty, else the
                                              catalog coupon's scope. On a phase
                                              update, a coupon already stored as
                                              `exclude` keeps `exclude` when
                                              `product_ids` is sent without
                                              `product_scope`.
                                  description: >-
                                    Coupons to be applied to the prices of
                                    subscription products.
                            - type: object
                              properties:
                                trial:
                                  type: object
                                  properties:
                                    end_strategy:
                                      type: string
                                      enum:
                                        - manual
                                        - end_date
                                        - duration
                                      description: Defines how the free trial will end.
                                    starts_at:
                                      type: string
                                      format: date-time
                                      description: >-
                                        Free trial start date. UTC date time
                                        string in the [ISO
                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                        format.
                                      example: '2024-12-20T16:04:11Z'
                                    ends_at:
                                      type: string
                                      format: date-time
                                      description: >-
                                        Free trial end date. Only applies if the
                                        end strategy is `end_date`. UTC date
                                        time string in the [ISO
                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                        format.
                                      example: '2024-12-20T16:04:11Z'
                                    duration:
                                      type: object
                                      properties:
                                        period:
                                          type: string
                                          enum:
                                            - days
                                            - weeks
                                            - months
                                            - years
                                          description: >-
                                            Free trial duration period. Only applies
                                            if the end strategy is `duration`.
                                        count:
                                          type: number
                                          minimum: 1
                                          description: >-
                                            Free trial duration count. Only applies
                                            if the end strategy is `duration`.
                                      required:
                                        - period
                                        - count
                                  required:
                                    - end_strategy
                                  description: >-
                                    Create a free trial phase based on the plan
                                    configuration. Only applies if a `plan_id`
                                    is provided.
                          title: Without phases
                    - type: object
                      properties:
                        plan_id:
                          type: string
                          description: Deprecated field, please use `template_id`.
                          example: plan_zHmjoDee4ZRmQV
                          deprecated: true
                        template_id:
                          type: string
                          description: >-
                            ID of the template that the subscription is linked
                            to.
                          example: subt_7gdusOkqr5L0B8
                        template_configuration_id:
                          type: string
                          description: >-
                            ID of the template configuration that the
                            subscription is linked to.
                          example: subtc_7mHWOlPStUogvp
                  description: Subscription configuration constituting the quote.
              required:
                - expires_at
                - subscription
              title: Subscription
            - type: object
              properties:
                expires_at:
                  type: string
                  format: date-time
                  description: >-
                    Quote expiration date. UTC date time string in the [ISO
                    8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                  example: '2024-04-28T14:12:09.293Z'
                subscription_update:
                  $ref: '#/components/schemas/CreateQuoteSubscriptionUpdate'
              required:
                - expires_at
                - subscription_update
              title: Subscription update
            - type: object
              properties:
                expires_at:
                  type: string
                  format: date-time
                  description: >-
                    Quote expiration date. UTC date time string in the [ISO
                    8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                  example: '2024-04-28T14:12:09.293Z'
                invoice:
                  $ref: '#/components/schemas/CreateQuoteInvoice'
              required:
                - expires_at
                - invoice
              title: One-off invoice
    MeteringFilter:
      type:
        - object
        - 'null'
      properties:
        name:
          type: string
          description: Name of the metering filter.
          example: VISA credit cards
        configuration:
          $ref: '#/components/schemas/MeteringFilterConfiguration'
      required:
        - name
        - configuration
      description: Metering filter to scope eligible billable events.
    CreateQuoteSubscriptionUpdate:
      type: object
      properties:
        source_subscription_id:
          type: string
          description: >-
            ID of the subscription the quote updates. It must belong to the
            quote's customer.
          example: sub_B6ClkdqNqVNBgY
        calculation_method:
          type: string
          enum:
            - do_not_charge
            - pro_rata
            - pro_rata_separate_documents
          description: >

            How the billing period in progress is settled at the transition
            date. Defaults to `do_not_charge`.


            - `do_not_charge`: no transition document is issued, and units added
            to already invoiced one-off products are not billed. With
            `keep_current_billing_cycle`, usage and end-of-period products are
            billed for the whole period at period end, with the new prices. With
            `align_to_new_billing_cycle`, usage and end-of-period products
            elapsed before the transition date are never billed, and
            start-of-period products are neither credited nor charged until the
            following renewal.

            - `pro_rata`: issues one document that nets both configurations.
            Previous configuration: start-of-period products are credited for
            the rest of the period, end-of-period products are charged prorated
            up to the transition date, and usage is charged up to the transition
            date. New configuration: start-of-period products are charged until
            the period end with `keep_current_billing_cycle`, or for a full new
            period with `align_to_new_billing_cycle`. Equal and opposite lines
            are removed. The document is a credit note when its total is
            negative, otherwise an invoice. Not available when the invoicing
            entity issues credit notes and invoices as separate documents.

            - `pro_rata_separate_documents`: the same lines as `pro_rata`, split
            into one document for the previous configuration and one for the new
            configuration. Each document is a credit note when its own total is
            negative, otherwise an invoice.


            With `application_schedule` `last_renewal` and `pro_rata` or
            `pro_rata_separate_documents`, the lines already invoiced for the
            current period are credited, and the period is invoiced again with
            the new prices.
        billing_cycle_transition_method:
          type: string
          enum:
            - keep_current_billing_cycle
            - align_to_new_billing_cycle
          description: >

            How the billing cycle is handled at the transition date. Defaults to
            `keep_current_billing_cycle`.


            - `keep_current_billing_cycle`: the current billing period continues
            with the new configuration, and the next renewal date is unchanged.
            Rejected when the two configurations share no product billing
            periodicity, as the cycle cannot then be preserved: use
            `align_to_new_billing_cycle` instead.

            - `align_to_new_billing_cycle`: a new billing period starts on the
            transition date, and the billing cycle is aligned to it.


            See `calculation_method` for what each option bills.
        application_schedule:
          type: string
          enum:
            - quote_signature
            - scheduled
            - last_renewal
          default: quote_signature
          description: >

            When the update is applied to the subscription. Defaults to
            `quote_signature`.


            - `quote_signature`: when the quote is signed.

            - `scheduled`: on `transition_date`, once the quote is signed. The
            quote must be signed before that date.

            - `last_renewal`: retroactively to the start of the billing period
            in progress when the quote is created, once the quote is signed. The
            quote must be signed before that period ends.
        transition_date:
          type: string
          format: date-time
          description: >-
            Date at which the update is applied. Required when
            `application_schedule` is `scheduled`, ignored otherwise. UTC date
            time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-12-20T16:04:11Z'
        target_subscription:
          allOf:
            - type: object
              properties:
                name:
                  type: string
                  description: Subscription custom name.
                purchase_order:
                  type: string
                  description: Reference to the purchase order.
                invoicing_entity_id:
                  type: string
                  description: >-
                    ID of the invoicing entity attached to the subscription. If
                    not defined, fallback to customer's invoicing entity.
                  example: ive_jerrb484RHn
                crm_opportunity_id:
                  type: string
                  description: ID of the related opportunity/deal in the connected CRM.
                commitment_interval:
                  type: object
                  properties:
                    period:
                      type: string
                      enum:
                        - days
                        - weeks
                        - months
                        - years
                    count:
                      type: number
                      minimum: 1
                  required:
                    - period
                    - count
                  description: Deprecated field, please use `contract_terms`.
                  example:
                    period: years
                    count: 1
                  deprecated: true
                renew_for:
                  type: object
                  properties:
                    period:
                      type: string
                      enum:
                        - days
                        - weeks
                        - months
                        - years
                    count:
                      type: number
                  required:
                    - period
                    - count
                  description: Deprecated field, please use `contract_terms`.
                  example:
                    period: years
                    count: 1
                  deprecated: true
                minimum_invoice_fee:
                  type:
                    - number
                    - 'null'
                  description: >-
                    Minimum fee applied to each invoice outside of one time
                    payments.
                  example: 250
                contract_terms:
                  allOf:
                    - type: object
                      properties:
                        starts_at:
                          type: string
                          format: date-time
                          description: >-
                            Start date of the contract. UTC date time string in
                            the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        ends_at:
                          type: string
                          format: date-time
                          description: >-
                            End date of the contract. UTC date time string in
                            the [ISO
                            8601](https://en.wikipedia.org/wiki/ISO_8601)
                            format.
                          example: '2024-12-20T16:04:11Z'
                        duration:
                          type: object
                          properties:
                            period:
                              type: string
                              enum:
                                - days
                                - weeks
                                - months
                                - years
                            count:
                              type: integer
                              minimum: 1
                              default: 1
                          required:
                            - period
                          description: >-
                            Interval over which the contract initially spans.
                            Only applies to `duration` end strategy.
                          example:
                            count: 6
                            period: months
                        renew_automatically:
                          anyOf:
                            - type: boolean
                            - type: string
                              enum:
                                - 'true'
                                - 'false'
                          description: >

                            Indicates if the contract should be renewed
                            automatically.


                            - `true`: The contract will be renewed
                            automatically.

                            - `false`: The contract will not be renewed
                            automatically.
                          example: true
                        renew_for_duration:
                          type: object
                          properties:
                            period:
                              type: string
                              enum:
                                - days
                                - weeks
                                - months
                                - years
                            count:
                              type: integer
                              minimum: 1
                              default: 1
                          required:
                            - period
                          description: >

                            Interval over which the contract will be renewed.
                            Only applies if `renew_automatically` is true.
                          example:
                            count: 1
                            period: years
                    - type: object
                      properties:
                        activation_strategy:
                          type: string
                          enum:
                            - start_date
                            - immediately
                            - manual
                            - quote_signature
                            - checkout
                          description: >

                            Activation strategy of the contract.


                            - `immediately`: The contract will be activated
                            immediately.

                            - `manual`: The contract will be activated when a
                            user manually activates it.

                            - `start_date`: The contract will be activated on a
                            specified date.

                            - `quote_signature`: The contract will be activated
                            when the subscription quote is signed.

                            - `checkout`: The contract will be activated when
                            the subscription checkout is completed.
                          example: start_date
                        end_strategy:
                          type: string
                          enum:
                            - end_date
                            - duration
                            - manual
                          description: >

                            End strategy of contract.


                            - `manual`: The contract ends when a user manually
                            stops it.

                            - `end_date`: The contract ends on a specified date.

                            - `duration`: The contract ends after a specific
                            relative duration, unless `renew_automatically` is
                            true.
                          example: duration
                      required:
                        - activation_strategy
                        - end_strategy
                  description: Contract terms linked to the subscription.
                starts_at:
                  type: string
                  format: date-time
                  description: >-
                    Applies only if the activation strategy is `start_date`. UTC
                    date time string in the [ISO
                    8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                  example: '2024-12-20T16:04:11Z'
                contract_start:
                  type: string
                  format: date-time
                  description: Deprecated field, please use `contract_terms`.
                  example: '2024-01-15T00:00:00Z'
                  deprecated: true
                contract_end:
                  type: string
                  format: date-time
                  description: Deprecated field, please use `contract_terms`.
                  example: '2025-01-15T00:00:00Z'
                  deprecated: true
                initial_billing_at:
                  type: string
                  format: date-time
                  description: >-
                    Date when the subscription will start being billed. If not
                    specified, it will correspond to the `starts_at` date. UTC
                    date time string in the [ISO
                    8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                  example: '2024-12-20T16:04:11Z'
                payment_method_id:
                  type: string
                  description: >-
                    ID of the customer's payment method used to pay the
                    subscription's invoices, instead of the customer's default
                    one. Cannot be combined with `bank_account_id`. Omit to use
                    the customer's payment method.
                  example: pm_abc123
                bank_account_id:
                  type: string
                  description: >-
                    ID of the bank account displayed on the subscription's
                    invoices, which are then paid by bank transfer, instead of
                    the customer's default payment method. Cannot be combined
                    with `payment_method_id`. Omit to use the customer's payment
                    method.
                  example: bac_abc123
                shipping_address_id:
                  type: string
                  description: >-
                    ID of the customer's active shipping address the
                    subscription ships to. Omit to use the customer shipping
                    destination: billing address or default shipping address.
                  example: cad_abc123
                display_shipping_details:
                  anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - 'true'
                        - 'false'
                  description: >-
                    Indicates if the shipping details should be displayed on the
                    subscription's invoices.
                cancel_at:
                  type: string
                  format: date-time
                  description: >-
                    Subscription cancel date. UTC date time string in the [ISO
                    8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                  example: '2024-12-20T16:04:11Z'
                cancellation_strategy:
                  type: string
                  enum:
                    - refund_prorata
                    - refund_custom
                    - charge_prorata
                    - charge_custom
                    - end_of_period
                    - do_nothing
                  description: >

                    Strategy used to cancel the subscription. If not specified
                    `do_nothing` is used.


                    - `charge_prorata`: Will charge the customer the unpaid
                    amount for the prorated period up to the end of the current
                    period.

                    - `charge_custom`: Will charge the customer a custom amount.

                    - `refund_prorata`: Will refund to the customer the overpaid
                    subscription amount using prorated calculations on the
                    cancellation date.

                    - `refund_custom`: Will refund to the customer a custom
                    amount.

                    - `end_of_period`: Will cancel the subscription at the end
                    date of the current billing period.

                    - `do_nothing`: Will only cease the subscription without any
                    additional actions.
                cancellation_amount:
                  type: number
                  description: >-
                    Custom amount used when cancelling the subscription. Only
                    applies to the `charge_custom` or the `refund_custom`
                    cancellation strategy.
                cancellation_refund_method:
                  type: string
                  enum:
                    - wallet
                    - original_payment_method
                    - external
                  description: >-
                    Override the refund destination for credit notes generated
                    by `refund_prorata` / `refund_custom` cancellation
                    strategies. When omitted, falls back to the invoicing
                    entity's `creditNoteWalletRefundEnabled` setting.
                properties:
                  type: object
                  additionalProperties:
                    anyOf:
                      - type: string
                      - type: number
                      - type: boolean
                      - type: 'null'
                      - type: array
                        items:
                          anyOf:
                            - type: string
                            - type: number
                            - type: boolean
                            - type: 'null'
                            - type: 'null'
                      - type: 'null'
                  description: >-
                    Key/value pairs to store any metadata useful in your
                    context.
                custom_properties:
                  type: object
                  additionalProperties:
                    anyOf:
                      - type: string
                      - type: number
                      - type: boolean
                      - type: string
                        format: date-time
                        description: >-
                          UTC date time string in the [ISO
                          8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                        example: '2024-12-20T16:04:11Z'
                      - type: array
                        items:
                          type: string
                      - type: 'null'
                  description: >-
                    A list of key value with the slug of the custom property as
                    the key and the custom property value as value.
                tax_only:
                  anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - 'true'
                        - 'false'
                  description: Only tax will be charged on this subscription.
                generate_draft_invoices:
                  anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - 'true'
                        - 'false'
                  description: >-
                    Generate draft invoices for the subscription. Each invoice
                    will need to be reviewed and validated manually before being
                    sent
                generate_document:
                  anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - 'true'
                        - 'false'
                  description: Generate non-legal documents instead of invoices.
                document_name:
                  type:
                    - string
                    - 'null'
                  description: >-
                    If `generate_document` is turned on, allows you to give a
                    name to your document.
                add_tax_to_document:
                  anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - 'true'
                        - 'false'
                  description: >-
                    If `generate_document` is turned on, will add taxes to
                    document.
                do_not_charge_subscription:
                  anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - 'true'
                        - 'false'
                  description: >-
                    Subscription will be invoiced but not charged
                    (invoices/documents will be settled directly).
                invoice_custom_note:
                  type:
                    - string
                    - 'null'
                  description: >-
                    Default custom note added to invoices generated by the
                    subscription.
                invoice_schedule:
                  type:
                    - string
                    - 'null'
                  enum:
                    - period_start
                    - period_end
                  description: >

                    Defines when invoices are generated relative to the billing
                    period.


                    - `period_start`: Invoices are generated at the start of the
                    billing period.

                    - `period_end`: Invoices are generated at the end of the
                    billing period.
            - type: object
              properties:
                plan_id:
                  type: string
                  description: Deprecated field, please use `template_id`.
                  example: plan_zHmjoDee4ZRmQV
                  deprecated: true
                template_id:
                  type: string
                  description: ID of the template that the subscription is linked to.
                  example: subt_7gdusOkqr5L0B8
                template_configuration_id:
                  type: string
                  description: >-
                    ID of the template configuration that the subscription is
                    linked to.
                  example: subtc_7mHWOlPStUogvp
            - anyOf:
                - type: object
                  properties:
                    phases:
                      type: array
                      items:
                        type: object
                        properties:
                          name:
                            type: string
                            description: Name of the subscription phase.
                            example: Initial term
                          type:
                            type: string
                            enum:
                              - setup
                              - trial
                              - standard
                            default: standard
                            description: >

                              Type of subscription phase.


                              - `setup`: The phase represents a non-recurring
                              service setup period, often used before the actual
                              recurring subscription begins.

                              - `trial`: The phase represents a non-recurring
                              trial period, often used to allow users to opt out
                              or experience a free test.

                              - `standard`: The phase represents a standard
                              recurring billing.
                            example: standard
                          status:
                            type: string
                            enum:
                              - finished
                              - pending
                            default: pending
                            description: >

                              Status of subscription phase.


                              - `pending`: The phase is waiting to start (not
                              started yet).

                              - `active`: The phase is currently in progress.

                              - `finished`: The phase has ended and is complete.
                            example: pending
                          order:
                            type: number
                            description: >-
                              Order in which the phase is executed within all
                              subscription phases.
                            example: 0
                          activation_strategy:
                            type: string
                            enum:
                              - immediately
                              - manual
                              - start_date
                              - quote_signature
                              - checkout
                              - contract_start_date
                              - previous_phase_end
                            description: >

                              Activation strategy of subscription phase.


                              - `immediately`: The phase starts as soon as the
                              subscription is activated.

                              - `manual`: The phase starts when a user manually
                              activates it.

                              - `start_date`: The phase starts on a specified
                              date.

                              - `quote_signature`: The phase starts when the
                              subscription quote is signed.

                              - `checkout`: The phase starts when the
                              subscription checkout is completed.

                              - `contract_start_date`: The phase starts on the
                              start date of the related subscription contract.

                              - `previous_phase_end`: The phase starts when the
                              previous phase ends.
                            example: manual
                          end_strategy:
                            type: string
                            enum:
                              - manual
                              - end_date
                              - duration
                              - contract_end_date
                            description: >

                              End strategy of subscription phase.


                              - `manual`: The phase ends when a user manually
                              stops it.

                              - `end_date`: The phase ends on a specified date.

                              - `duration`: The phase ends after a specific
                              relative duration.

                              - `contract_end_date`: The phase ends on the end
                              date of the related subscription contract.
                            example: duration
                          duration:
                            type: object
                            properties:
                              period:
                                type: string
                                enum:
                                  - days
                                  - weeks
                                  - months
                                  - years
                              count:
                                type: integer
                                minimum: 1
                                default: 1
                            required:
                              - period
                            description: >-
                              Interval over which the subscription phase spans.
                              Only applies to `duration` end strategy.
                            example:
                              count: 1
                              period: years
                          billing_date_setting:
                            type: string
                            enum:
                              - phase_start
                              - specific_date
                            description: >

                              Represents when the first billing date occurs.


                              - `phase_start`: Aligns with the start of the
                              phase.

                              - `specific_date`: Occurs on a specified date.
                            example: phase_start
                          initial_billing_at:
                            type: string
                            format: date-time
                            description: >-
                              Date when the subscription phase will start being
                              billed. Only applies to `specific_date` billing
                              date setting. UTC date time string in the [ISO
                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                              format.
                            example: '2024-12-20T16:04:11Z'
                          starts_at:
                            type: string
                            format: date-time
                            description: >-
                              Actual start date of the phase. UTC date time
                              string in the [ISO
                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                              format.
                            example: '2024-12-20T16:04:11Z'
                          ends_at:
                            type: string
                            format: date-time
                            description: >-
                              Actual end date of the phase. UTC date time string
                              in the [ISO
                              8601](https://en.wikipedia.org/wiki/ISO_8601)
                              format.
                            example: '2024-12-20T16:04:11Z'
                          billing_cycle_alignment:
                            type: string
                            enum:
                              - calendar_period
                              - anniversary
                            description: >

                              Alignment of product billing cycles. If omitted at
                              creation, the billing cycles alignment configured
                              in the account subscription settings applies.


                              - `calendar_period`: The billing cycles of the
                              products will be aligned on the calendar period,
                              after the first period which will be invoiced
                              taking into account the prorata of the first cycle
                              compared to the product periodicity.

                              - `anniversary`: The billing cycles of the
                              products will be aligned on the anniversary of the
                              phase initial billing date.
                            example: anniversary
                          do_not_invoice_phase:
                            type: boolean
                            default: false
                            description: >-
                              Indicates if the phase should be invoiced. If set
                              to true, the phase will not generate any invoices.
                            example: false
                          minimum_invoice_fee:
                            type:
                              - number
                              - 'null'
                            minimum: 0
                            description: >-
                              Phase minimum fee in minor currency units, after
                              discounts and before tax. Null disables it and
                              clears the product selection.
                            example: 10000
                          minimum_invoice_fee_products:
                            type:
                              - array
                              - 'null'
                            items:
                              type: string
                            description: >-
                              Catalog product IDs eligible for the phase minimum
                              fee. Null or an empty list includes all billed
                              debit products in the phase.
                            example:
                              - itm_aaaaaaaaaaaaaa
                          transition_calculation_method:
                            type: string
                            enum:
                              - prorata
                              - pay_in_full
                              - none
                            default: prorata
                            description: >

                              Calculation method used when transitioning from
                              one phase to the next one.


                              - `prorata`: The prorated amount between the two
                              phases relative to the end date (the transition
                              date) must be paid.

                              - `pay_in_full`: The full amount for the phase
                              billing period must be paid.

                              - `none`: No amount will need to be paid, phase
                              will simply transition from one to the next.
                            example: prorata
                          transition_invoicing_schedule:
                            type: string
                            enum:
                              - immediately
                            default: immediately
                            description: >

                              Represents when the transition amount will be
                              invoiced.


                              - `immediately`: An invoice will be generated
                              immediately with the corresponding amount.
                            example: immediately
                          products:
                            type: array
                            items:
                              type: object
                              properties:
                                id:
                                  type: string
                                  description: Product ID.
                                  example: itm_FJKlqUb8COXw55
                                catalog_version_id:
                                  type:
                                    - string
                                    - 'null'
                                  description: >-
                                    ID of a published catalog version to price
                                    this product from, instead of the live
                                    products catalog. Ignored when `price` or
                                    `prices` is set. The product must be priced
                                    in that version.
                                  example: pcv_9x8v7u6t5s4r
                                price_configuration_id:
                                  type:
                                    - string
                                    - 'null'
                                  description: >-
                                    ID of the product's price configuration to
                                    price this product from, instead of the one
                                    the catalog rules select. It must be a live
                                    base configuration of the product (not
                                    archived or replaced by a later catalog
                                    publish, and not specific to a customer,
                                    price book, customer segment or plan), in
                                    the subscription's currency. Requires
                                    `payment_interval`, which it must match. The
                                    configuration's country and commitment
                                    restrictions are not checked. With a pinned
                                    catalog version, the product is priced from
                                    that version's copy of the configuration,
                                    and a configuration the version doesn't
                                    price returns a 400. Cannot be combined with
                                    `price`, `prices` or `plan_id`.
                                  example: prc_8f3kXODIM1sBwB
                                name:
                                  type: string
                                  description: >-
                                    Product name. This will appear on the final
                                    invoices.
                                  example: Product name
                                description:
                                  type: string
                                  description: >-
                                    Product description. This will appear on the
                                    final invoices.
                                  example: A description of the product.
                                description_display_interval_dates:
                                  type: boolean
                                  default: false
                                  description: >-
                                    Indicates if the dates of the interval
                                    should be automatically added in the product
                                    description on the invoices.
                                payment_interval:
                                  anyOf:
                                    - type: object
                                      properties:
                                        period:
                                          type: string
                                          enum:
                                            - once
                                      required:
                                        - period
                                      title: Once
                                      example:
                                        period: once
                                    - type: object
                                      properties:
                                        period:
                                          type: string
                                          enum:
                                            - days
                                            - weeks
                                            - months
                                            - years
                                        count:
                                          type: integer
                                          minimum: 1
                                          default: 1
                                      required:
                                        - period
                                      title: Period
                                      example:
                                        period: months
                                        count: 1
                                  description: >-
                                    Interval on which the product is billed.
                                    This interval can be different between
                                    products and can differ from the
                                    subscription commitment interval.
                                payment_schedule:
                                  type: string
                                  enum:
                                    - start
                                    - end
                                  description: >-
                                    Indicates if the product should be billed at
                                    the start or the end of the payment
                                    interval.
                                  example: start
                                price:
                                  type: object
                                  properties:
                                    type:
                                      type: string
                                      enum:
                                        - fee
                                    amount:
                                      type: number
                                      description: >-
                                        Monetary amount. Expressed in currency's
                                        smallest unit.
                                  required:
                                    - type
                                    - amount
                                  description: >-
                                    Similar to `prices`, allow to apply a single
                                    fee price more easily.
                                  example:
                                    type: fee
                                    amount: 200
                                prices:
                                  type: array
                                  items:
                                    oneOf:
                                      - type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - fee
                                          amount:
                                            type: number
                                            description: >-
                                              Monetary amount. Expressed in currency's
                                              smallest unit.
                                        required:
                                          - type
                                          - amount
                                        title: Fee price
                                      - type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - volume
                                          amount:
                                            type: number
                                            description: >-
                                              Monetary amount of the price for the
                                              number of units defined by `unit_count`.
                                              Expressed in currency's smallest unit.
                                          unit_count:
                                            type: number
                                            description: >-
                                              Number of units considered for the
                                              amount.
                                          from:
                                            type: number
                                            description: From limit.
                                          to:
                                            type:
                                              - number
                                              - 'null'
                                            description: To limit.
                                          on_tier_incomplete:
                                            type:
                                              - string
                                              - 'null'
                                            enum:
                                              - pro_rata
                                              - pay_in_full
                                              - do_not_charge
                                              - flat_per_tier
                                            default: pro_rata
                                            description: >-

                                              Logic used to compute the amount when
                                              usage on the tier is incomplete.


                                              - `pro_rata`: The amount is computed
                                              using the pro rata of the tier's
                                              consumption.

                                              - `pay_in_full`: The amount corresponds
                                              to the full payment of the tier.

                                              - `do_not_charge`: The tier is not
                                              charged and ignored.

                                              - `flat_per_tier`: The tier's `amount`
                                              is a flat fee, billed once as soon as
                                              usage reaches the tier, whatever the
                                              number of units in it. `unitCount` is
                                              ignored. No usage bills nothing.
                                                
                                          metering_filter:
                                            allOf:
                                              - $ref: '#/components/schemas/MeteringFilter'
                                              - type: object
                                                description: >-
                                                  Metering filter that scopes which
                                                  billable events are eligible for this
                                                  price tier. Only present when the price
                                                  is filtered.
                                        required:
                                          - type
                                          - amount
                                          - unit_count
                                          - from
                                          - to
                                        title: Volume price
                                      - type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - packaged
                                          amount:
                                            type: number
                                            description: >-
                                              Monetary amount of the price for the
                                              number of units defined by `unit_count`.
                                              Expressed in currency's smallest unit.
                                          unit_count:
                                            type: number
                                            description: >-
                                              Number of units considered for the
                                              amount.
                                          from:
                                            type: number
                                            description: From limit.
                                          to:
                                            type:
                                              - number
                                              - 'null'
                                            description: To limit.
                                          on_bucket_incomplete:
                                            type:
                                              - string
                                              - 'null'
                                            enum:
                                              - pro_rata
                                              - pay_in_full
                                              - do_not_charge
                                              - flat_per_tier
                                            default: pro_rata
                                            description: >-

                                              Logic used to compute the amount when
                                              usage reaches an incomplete bucket (the
                                              bucket size corresponds to the
                                              `unitCount`).

                                                - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                                - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                                - `do_not_charge`: The bucket is not charged and ignored.
                                                - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                  
                                          metering_filter:
                                            allOf:
                                              - $ref: '#/components/schemas/MeteringFilter'
                                              - type: object
                                                description: >-
                                                  Metering filter that scopes which
                                                  billable events are eligible for this
                                                  price tier. Only present when the price
                                                  is filtered.
                                        required:
                                          - type
                                          - amount
                                          - unit_count
                                          - from
                                          - to
                                        title: Packaged price
                                      - type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - bulk
                                          amount:
                                            type: number
                                            description: >-
                                              Monetary amount of the price for the
                                              number of units defined by `unit_count`.
                                              Expressed in currency's smallest unit.
                                          unit_count:
                                            type: number
                                            description: >-
                                              Number of units considered for the
                                              amount.
                                          to:
                                            type:
                                              - number
                                              - 'null'
                                            description: To limit.
                                          on_tier_incomplete:
                                            type:
                                              - string
                                              - 'null'
                                            enum:
                                              - pro_rata
                                              - pay_in_full
                                              - do_not_charge
                                              - flat_per_tier
                                            default: pro_rata
                                            description: >-

                                              Logic used to compute the amount when
                                              usage on the tier is incomplete.


                                              - `pro_rata`: The amount is computed
                                              using the pro rata of the tier's
                                              consumption.

                                              - `pay_in_full`: The amount corresponds
                                              to the full payment of the tier.

                                              - `do_not_charge`: The tier is not
                                              charged and ignored.

                                              - `flat_per_tier`: The tier's `amount`
                                              is a flat fee, billed once as soon as
                                              usage reaches the tier, whatever the
                                              number of units in it. `unitCount` is
                                              ignored. No usage bills nothing.
                                                
                                          metering_filter:
                                            allOf:
                                              - $ref: '#/components/schemas/MeteringFilter'
                                              - type: object
                                                description: >-
                                                  Metering filter that scopes which
                                                  billable events are eligible for this
                                                  price tier. Only present when the price
                                                  is filtered.
                                        required:
                                          - type
                                          - amount
                                          - unit_count
                                          - to
                                        title: Bulk price
                                      - type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - bps
                                          from:
                                            type: number
                                            description: From limit.
                                          to:
                                            type:
                                              - number
                                              - 'null'
                                            description: To limit.
                                          percentage:
                                            type: number
                                            description: >-
                                              Percentage applied on each unit to
                                              compute the usage.
                                          per_unit_cap:
                                            type:
                                              - number
                                              - 'null'
                                            description: >-
                                              Maximum amount for one unit. Expressed
                                              in currency's smallest unit.
                                          per_unit_floor:
                                            type:
                                              - number
                                              - 'null'
                                            description: >-
                                              Minimum amount for one unit. Expressed
                                              in currency's smallest unit.
                                          per_unit_fee:
                                            type:
                                              - number
                                              - 'null'
                                            description: >-
                                              Fee amount applied per unit. Expressed
                                              in currency's smallest unit.
                                          metering_filter:
                                            allOf:
                                              - $ref: '#/components/schemas/MeteringFilter'
                                              - type: object
                                                description: >-
                                                  Metering filter that scopes which
                                                  billable events are eligible for this
                                                  price tier. Only present when the price
                                                  is filtered.
                                        required:
                                          - type
                                          - from
                                          - to
                                          - percentage
                                          - per_unit_cap
                                          - per_unit_floor
                                          - per_unit_fee
                                        title: BPS price
                                      - type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - bundle
                                          amount:
                                            type: number
                                            description: >-
                                              Monetary amount of the price for the
                                              number of units defined by `unit_count`.
                                              Expressed in currency's smallest unit.
                                          unit_count:
                                            type: number
                                            description: >-
                                              Number of units considered for the
                                              amount.
                                        required:
                                          - type
                                          - amount
                                          - unit_count
                                        title: Bundle price
                                        description: >-
                                          For seat products only, if you are
                                          looking for credits, use a fee price
                                  description: >-
                                    Prices of the product. If not specified, the
                                    matching prices (depending on the currency,
                                    interval, etc) of the product defined in the
                                    products catalog/plan are used.
                                  example:
                                    - type: volume
                                      from: 0
                                      to: 20
                                      amount: 200
                                      unit_count: 1
                                      on_tier_incomplete: null
                                    - type: volume
                                      from: 20
                                      to: null
                                      amount: 150
                                      unit_count: 1
                                      on_tier_incomplete: null
                                count:
                                  type: number
                                  minimum: 1
                                  description: >-
                                    Number of product units. Only applies to
                                    products of type `flat_fee`, `seat` or
                                    `credit`.
                                  example: 2
                                unit_name:
                                  type: string
                                  description: >-
                                    Product name. This will appear on the final
                                    invoices. Only applies to products of type
                                    `seat` or `usage`.
                                  example: user
                                min_committed_count:
                                  type: number
                                  minimum: 1
                                  description: >-
                                    Minimum of units committed. If usage is less
                                    than this number, then this value will be
                                    used. Only applies to products of type
                                    `usage`.
                                min_amount:
                                  type:
                                    - number
                                    - 'null'
                                  description: >-
                                    Minimum amount billed. If the final computed
                                    amount from the usage for this product is
                                    less than this amount, then this value will
                                    be used. Only applies to products of type
                                    `usage`.
                                max_amount:
                                  type:
                                    - number
                                    - 'null'
                                  description: >-
                                    Maximum amount billed. If the final computed
                                    amount from the usage for this product is
                                    greater than this amount, then this value
                                    will be used. Only applies to products of
                                    type `usage`.
                                charging_method:
                                  type:
                                    - string
                                    - 'null'
                                  enum:
                                    - prorata
                                    - pay_in_full
                                    - do_not_charge
                                  description: >-
                                    Charging method for seat count updates
                                    within the current billing period. Only
                                    applies to connected seat products.


                                    - `prorata`: Price calculated proportionally
                                    to time elapsed in the billing period.

                                    - `pay_in_full`: Price calculated for the
                                    entire billing period.

                                    - `do_not_charge`: No charge for the update.
                                seat_invoicing_schedule:
                                  type:
                                    - string
                                    - 'null'
                                  enum:
                                    - immediately
                                    - next_invoice
                                    - custom
                                  description: >

                                    Policy defining when seat count changes are
                                    invoiced. Only applies to connected seat
                                    products.


                                    - `immediately`: Seat changes are invoiced
                                    immediately.

                                    - `next_invoice`: Seat changes are invoiced
                                    at the next invoice.

                                    - `custom`: Seat changes are invoiced on a
                                    custom schedule.
                                metering_interval_type:
                                  type: string
                                  enum:
                                    - subscription_commitment
                                    - payment_interval
                                    - full_database
                                    - phase_duration
                                    - custom
                                  description: >-

                                    Indicates on which type of interval the
                                    usage should be aggregated.


                                    - `subscription_commitment`: For the usage
                                    contained within the subscription commitment
                                    period.

                                    - `payment_interval`: For the usage
                                    contained within the payment interval of the
                                    product.

                                    - `full_database`: For all the usage we
                                    ingested for this product, no matter the
                                    period.

                                    - `phase_duration`: For the usage contained
                                    within the subscription phase.

                                    - `custom`: For the usage contained within a
                                    custom interval that starts with the phase
                                    and renews independently of the billing
                                    interval. Requires `metering_interval` to be
                                    set.
                                       Only applies to products of type `usage`.
                                metering_interval:
                                  type: object
                                  properties:
                                    period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                    count:
                                      type: integer
                                      minimum: 1
                                  required:
                                    - period
                                    - count
                                  description: >-
                                    Custom interval for usage aggregation.
                                    Required when `metering_interval_type` is
                                    `custom`. The interval starts at the phase
                                    start and renews on its own cycle (e.g. `{
                                    period: 'months', count: 3 }` for quarterly
                                    metering with monthly billing). Only applies
                                    to products of type `usage`.
                                bill_usage_difference:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  default: false
                                  description: >-
                                    Only bill the usage difference comparing to
                                    the previous period (i.e. actual amount
                                    minus last invoice amount). Doesn't apply to
                                    `payment_interval` metering interval type.
                                    Only applies to products of type `usage`.
                                children_usage_aggregation:
                                  type:
                                    - string
                                    - 'null'
                                  enum:
                                    - sum
                                    - max
                                  description: >-

                                    Controls whether a parent organization's
                                    metered usage is billed on the combined
                                    usage of the parent and its direct children,
                                    and how per-member values are combined.


                                    - `null`: Organization-based usage is
                                    disabled. Only the subscription customer's
                                    own usage is billed.

                                    - `sum`: The usage values of the parent and
                                    each direct child are added together
                                    (organization total).

                                    - `max`: Only the single highest-consuming
                                    member (parent or one direct child) is
                                    billed.
                                     Only applies to products of type `usage`.
                                credits_expiration_in_days:
                                  type:
                                    - number
                                    - 'null'
                                  description: >-
                                    Validity in days for credits that will be
                                    topped-up automatically. Once the period has
                                    passed, they'll expire.
                                expire_credits_at_end_of_period:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  default: false
                                  description: >-
                                    Automatically set the expiration date to the
                                    end of the next period for each topup. Takes
                                    priority on `creditsExpirationInDays`
                                credits_balance_auto_creation_enabled:
                                  anyOf:
                                    - type: boolean
                                    - type: string
                                      enum:
                                        - 'true'
                                        - 'false'
                                  description: >-
                                    Whether to create the customer credit
                                    balance as soon as the product is added to
                                    the subscription. Defaults to the credit
                                    product's
                                    `credits_balance_auto_creation_enabled`
                                    (`true` when unset). Set to `false` to
                                    create the balance by hand before
                                    activation, e.g. on quote-based renewals
                                    where the balance must not start consuming
                                    before signature; the first top-up creates
                                    it if still missing.
                              required:
                                - id
                            description: Products comprising the subscription phase.
                          coupons:
                            type: array
                            items:
                              allOf:
                                - anyOf:
                                    - type: object
                                      properties:
                                        id:
                                          type: string
                                          description: >-
                                            ID of the catalog coupon to apply to the
                                            subscription.
                                      required:
                                        - id
                                      title: Existing coupon
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - amount
                                        name:
                                          type: string
                                          description: Coupon name.
                                        discount_amount:
                                          type: number
                                          exclusiveMinimum: 0
                                          description: >-
                                            Coupon discount amount. Expressed in
                                            currency's smallest unit.
                                      required:
                                        - type
                                        - discount_amount
                                      title: Coupon amount
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - percent
                                        name:
                                          type: string
                                          description: Coupon name.
                                        discount_percent:
                                          type: number
                                          exclusiveMinimum: 0
                                          maximum: 100
                                          description: Coupon discount percentage.
                                      required:
                                        - type
                                        - discount_percent
                                      title: Coupon percent
                                - type: object
                                  properties:
                                    repeat:
                                      type:
                                        - string
                                        - 'null'
                                      enum:
                                        - once
                                        - forever
                                        - custom
                                        - duration
                                      description: >

                                        Coupon frequency. Required for inline
                                        coupons. Optional when an existing
                                        coupon `id` is provided: if omitted,
                                        defaults to the catalog coupon's repeat
                                        value.


                                        - `once`: Will apply the coupon only to
                                        the first one invoice.

                                        - `forever`: Will apply the coupon to
                                        all invoices.

                                        - `custom`: Will apply to coupon until a
                                        specified expiration date.

                                        - `duration`: Will apply the coupon for
                                        a specific duration (e.g., 3 months).
                                    duration_period:
                                      type: string
                                      enum:
                                        - days
                                        - weeks
                                        - months
                                        - years
                                      description: >-
                                        Period of time for which the coupon will
                                        be applied. Only applies to the
                                        `duration` coupon frequency.
                                    duration_count:
                                      type: number
                                      description: >-
                                        Number of periods for which the coupon
                                        will be applied. Only applies to the
                                        `duration` coupon frequency.
                                    expires_at:
                                      type: string
                                      format: date-time
                                      description: >-
                                        Coupon expiration date. Only applies to
                                        the `custom` coupon frequency. UTC date
                                        time string in the [ISO
                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                        format.
                                      example: '2024-12-20T16:04:11Z'
                                    apply_at:
                                      type: string
                                      format: date-time
                                      description: >-
                                        Coupon first application date. UTC date
                                        time string in the [ISO
                                        8601](https://en.wikipedia.org/wiki/ISO_8601)
                                        format.
                                      example: '2024-12-20T16:04:11Z'
                                    product_ids:
                                      type:
                                        - array
                                        - 'null'
                                      items:
                                        type: string
                                      minItems: 1
                                      description: >-
                                        Products the coupon is scoped to on this
                                        subscription, read together with
                                        `product_scope`: the only discounted
                                        products when `include`, the products
                                        never discounted when `exclude`, null
                                        when `all`. When sent without
                                        `product_scope`, it is an `include`
                                        list, except that a coupon already
                                        stored as `exclude` keeps `exclude` when
                                        its phase is updated; when empty or
                                        omitted, the catalog coupon's scope is
                                        copied.
                                    product_scope:
                                      type:
                                        - string
                                        - 'null'
                                      enum:
                                        - all
                                        - include
                                        - exclude
                                      description: >-
                                        Which products the coupon discounts on
                                        this subscription. `all`: every product
                                        (`product_ids` must be empty).
                                        `include`: only the products in
                                        `product_ids`. `exclude`: every product
                                        except those in `product_ids` (lines
                                        without a product stay discounted). When
                                        sent, it replaces the catalog coupon's
                                        scope together with `product_ids`. When
                                        omitted, it is inferred: `include` if
                                        `product_ids` is non-empty, else the
                                        catalog coupon's scope. On a phase
                                        update, a coupon already stored as
                                        `exclude` keeps `exclude` when
                                        `product_ids` is sent without
                                        `product_scope`.
                            description: Coupons comprising the subscription phase.
                        required:
                          - activation_strategy
                          - end_strategy
                          - billing_date_setting
                          - products
                  required:
                    - phases
                  title: With phases
                - allOf:
                    - type: object
                      properties:
                        products:
                          type: array
                          items:
                            type: object
                            properties:
                              id:
                                type: string
                                description: Product ID.
                                example: itm_FJKlqUb8COXw55
                              catalog_version_id:
                                type:
                                  - string
                                  - 'null'
                                description: >-
                                  ID of a published catalog version to price
                                  this product from, instead of the live
                                  products catalog. Ignored when `price` or
                                  `prices` is set. The product must be priced in
                                  that version.
                                example: pcv_9x8v7u6t5s4r
                              price_configuration_id:
                                type:
                                  - string
                                  - 'null'
                                description: >-
                                  ID of the product's price configuration to
                                  price this product from, instead of the one
                                  the catalog rules select. It must be a live
                                  base configuration of the product (not
                                  archived or replaced by a later catalog
                                  publish, and not specific to a customer, price
                                  book, customer segment or plan), in the
                                  subscription's currency. Requires
                                  `payment_interval`, which it must match. The
                                  configuration's country and commitment
                                  restrictions are not checked. With a pinned
                                  catalog version, the product is priced from
                                  that version's copy of the configuration, and
                                  a configuration the version doesn't price
                                  returns a 400. Cannot be combined with
                                  `price`, `prices` or `plan_id`.
                                example: prc_8f3kXODIM1sBwB
                              name:
                                type: string
                                description: >-
                                  Product name. This will appear on the final
                                  invoices.
                                example: Product name
                              description:
                                type: string
                                description: >-
                                  Product description. This will appear on the
                                  final invoices.
                                example: A description of the product.
                              description_display_interval_dates:
                                type: boolean
                                default: false
                                description: >-
                                  Indicates if the dates of the interval should
                                  be automatically added in the product
                                  description on the invoices.
                              payment_interval:
                                anyOf:
                                  - type: object
                                    properties:
                                      period:
                                        type: string
                                        enum:
                                          - once
                                    required:
                                      - period
                                    title: Once
                                    example:
                                      period: once
                                  - type: object
                                    properties:
                                      period:
                                        type: string
                                        enum:
                                          - days
                                          - weeks
                                          - months
                                          - years
                                      count:
                                        type: integer
                                        minimum: 1
                                        default: 1
                                    required:
                                      - period
                                    title: Period
                                    example:
                                      period: months
                                      count: 1
                                description: >-
                                  Interval on which the product is billed. This
                                  interval can be different between products and
                                  can differ from the subscription commitment
                                  interval.
                              payment_schedule:
                                type: string
                                enum:
                                  - start
                                  - end
                                description: >-
                                  Indicates if the product should be billed at
                                  the start or the end of the payment interval.
                                example: start
                              price:
                                type: object
                                properties:
                                  type:
                                    type: string
                                    enum:
                                      - fee
                                  amount:
                                    type: number
                                    description: >-
                                      Monetary amount. Expressed in currency's
                                      smallest unit.
                                required:
                                  - type
                                  - amount
                                description: >-
                                  Similar to `prices`, allow to apply a single
                                  fee price more easily.
                                example:
                                  type: fee
                                  amount: 200
                              prices:
                                type: array
                                items:
                                  oneOf:
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - fee
                                        amount:
                                          type: number
                                          description: >-
                                            Monetary amount. Expressed in currency's
                                            smallest unit.
                                      required:
                                        - type
                                        - amount
                                      title: Fee price
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - volume
                                        amount:
                                          type: number
                                          description: >-
                                            Monetary amount of the price for the
                                            number of units defined by `unit_count`.
                                            Expressed in currency's smallest unit.
                                        unit_count:
                                          type: number
                                          description: >-
                                            Number of units considered for the
                                            amount.
                                        from:
                                          type: number
                                          description: From limit.
                                        to:
                                          type:
                                            - number
                                            - 'null'
                                          description: To limit.
                                        on_tier_incomplete:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - pro_rata
                                            - pay_in_full
                                            - do_not_charge
                                            - flat_per_tier
                                          default: pro_rata
                                          description: >-

                                            Logic used to compute the amount when
                                            usage on the tier is incomplete.


                                            - `pro_rata`: The amount is computed
                                            using the pro rata of the tier's
                                            consumption.

                                            - `pay_in_full`: The amount corresponds
                                            to the full payment of the tier.

                                            - `do_not_charge`: The tier is not
                                            charged and ignored.

                                            - `flat_per_tier`: The tier's `amount`
                                            is a flat fee, billed once as soon as
                                            usage reaches the tier, whatever the
                                            number of units in it. `unitCount` is
                                            ignored. No usage bills nothing.
                                              
                                        metering_filter:
                                          allOf:
                                            - $ref: '#/components/schemas/MeteringFilter'
                                            - type: object
                                              description: >-
                                                Metering filter that scopes which
                                                billable events are eligible for this
                                                price tier. Only present when the price
                                                is filtered.
                                      required:
                                        - type
                                        - amount
                                        - unit_count
                                        - from
                                        - to
                                      title: Volume price
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - packaged
                                        amount:
                                          type: number
                                          description: >-
                                            Monetary amount of the price for the
                                            number of units defined by `unit_count`.
                                            Expressed in currency's smallest unit.
                                        unit_count:
                                          type: number
                                          description: >-
                                            Number of units considered for the
                                            amount.
                                        from:
                                          type: number
                                          description: From limit.
                                        to:
                                          type:
                                            - number
                                            - 'null'
                                          description: To limit.
                                        on_bucket_incomplete:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - pro_rata
                                            - pay_in_full
                                            - do_not_charge
                                            - flat_per_tier
                                          default: pro_rata
                                          description: >-

                                            Logic used to compute the amount when
                                            usage reaches an incomplete bucket (the
                                            bucket size corresponds to the
                                            `unitCount`).

                                              - `pro_rata`: The amount is computed using the pro rata of the bucket's consumption.
                                              - `pay_in_full`: The amount corresponds to the full payment of the bucket.
                                              - `do_not_charge`: The bucket is not charged and ignored.
                                              - `flat_per_tier`: The tier's `amount` is a flat fee, billed once as soon as usage reaches the tier, whatever the number of units in it. `unitCount` is ignored. No usage bills nothing.
                                                
                                        metering_filter:
                                          allOf:
                                            - $ref: '#/components/schemas/MeteringFilter'
                                            - type: object
                                              description: >-
                                                Metering filter that scopes which
                                                billable events are eligible for this
                                                price tier. Only present when the price
                                                is filtered.
                                      required:
                                        - type
                                        - amount
                                        - unit_count
                                        - from
                                        - to
                                      title: Packaged price
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - bulk
                                        amount:
                                          type: number
                                          description: >-
                                            Monetary amount of the price for the
                                            number of units defined by `unit_count`.
                                            Expressed in currency's smallest unit.
                                        unit_count:
                                          type: number
                                          description: >-
                                            Number of units considered for the
                                            amount.
                                        to:
                                          type:
                                            - number
                                            - 'null'
                                          description: To limit.
                                        on_tier_incomplete:
                                          type:
                                            - string
                                            - 'null'
                                          enum:
                                            - pro_rata
                                            - pay_in_full
                                            - do_not_charge
                                            - flat_per_tier
                                          default: pro_rata
                                          description: >-

                                            Logic used to compute the amount when
                                            usage on the tier is incomplete.


                                            - `pro_rata`: The amount is computed
                                            using the pro rata of the tier's
                                            consumption.

                                            - `pay_in_full`: The amount corresponds
                                            to the full payment of the tier.

                                            - `do_not_charge`: The tier is not
                                            charged and ignored.

                                            - `flat_per_tier`: The tier's `amount`
                                            is a flat fee, billed once as soon as
                                            usage reaches the tier, whatever the
                                            number of units in it. `unitCount` is
                                            ignored. No usage bills nothing.
                                              
                                        metering_filter:
                                          allOf:
                                            - $ref: '#/components/schemas/MeteringFilter'
                                            - type: object
                                              description: >-
                                                Metering filter that scopes which
                                                billable events are eligible for this
                                                price tier. Only present when the price
                                                is filtered.
                                      required:
                                        - type
                                        - amount
                                        - unit_count
                                        - to
                                      title: Bulk price
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - bps
                                        from:
                                          type: number
                                          description: From limit.
                                        to:
                                          type:
                                            - number
                                            - 'null'
                                          description: To limit.
                                        percentage:
                                          type: number
                                          description: >-
                                            Percentage applied on each unit to
                                            compute the usage.
                                        per_unit_cap:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Maximum amount for one unit. Expressed
                                            in currency's smallest unit.
                                        per_unit_floor:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Minimum amount for one unit. Expressed
                                            in currency's smallest unit.
                                        per_unit_fee:
                                          type:
                                            - number
                                            - 'null'
                                          description: >-
                                            Fee amount applied per unit. Expressed
                                            in currency's smallest unit.
                                        metering_filter:
                                          allOf:
                                            - $ref: '#/components/schemas/MeteringFilter'
                                            - type: object
                                              description: >-
                                                Metering filter that scopes which
                                                billable events are eligible for this
                                                price tier. Only present when the price
                                                is filtered.
                                      required:
                                        - type
                                        - from
                                        - to
                                        - percentage
                                        - per_unit_cap
                                        - per_unit_floor
                                        - per_unit_fee
                                      title: BPS price
                                    - type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - bundle
                                        amount:
                                          type: number
                                          description: >-
                                            Monetary amount of the price for the
                                            number of units defined by `unit_count`.
                                            Expressed in currency's smallest unit.
                                        unit_count:
                                          type: number
                                          description: >-
                                            Number of units considered for the
                                            amount.
                                      required:
                                        - type
                                        - amount
                                        - unit_count
                                      title: Bundle price
                                      description: >-
                                        For seat products only, if you are
                                        looking for credits, use a fee price
                                description: >-
                                  Prices of the product. If not specified, the
                                  matching prices (depending on the currency,
                                  interval, etc) of the product defined in the
                                  products catalog/plan are used.
                                example:
                                  - type: volume
                                    from: 0
                                    to: 20
                                    amount: 200
                                    unit_count: 1
                                    on_tier_incomplete: null
                                  - type: volume
                                    from: 20
                                    to: null
                                    amount: 150
                                    unit_count: 1
                                    on_tier_incomplete: null
                              count:
                                type: number
                                minimum: 1
                                description: >-
                                  Number of product units. Only applies to
                                  products of type `flat_fee`, `seat` or
                                  `credit`.
                                example: 2
                              unit_name:
                                type: string
                                description: >-
                                  Product name. This will appear on the final
                                  invoices. Only applies to products of type
                                  `seat` or `usage`.
                                example: user
                              min_committed_count:
                                type: number
                                minimum: 1
                                description: >-
                                  Minimum of units committed. If usage is less
                                  than this number, then this value will be
                                  used. Only applies to products of type
                                  `usage`.
                              min_amount:
                                type:
                                  - number
                                  - 'null'
                                description: >-
                                  Minimum amount billed. If the final computed
                                  amount from the usage for this product is less
                                  than this amount, then this value will be
                                  used. Only applies to products of type
                                  `usage`.
                              max_amount:
                                type:
                                  - number
                                  - 'null'
                                description: >-
                                  Maximum amount billed. If the final computed
                                  amount from the usage for this product is
                                  greater than this amount, then this value will
                                  be used. Only applies to products of type
                                  `usage`.
                              charging_method:
                                type:
                                  - string
                                  - 'null'
                                enum:
                                  - prorata
                                  - pay_in_full
                                  - do_not_charge
                                description: >-
                                  Charging method for seat count updates within
                                  the current billing period. Only applies to
                                  connected seat products.


                                  - `prorata`: Price calculated proportionally
                                  to time elapsed in the billing period.

                                  - `pay_in_full`: Price calculated for the
                                  entire billing period.

                                  - `do_not_charge`: No charge for the update.
                              seat_invoicing_schedule:
                                type:
                                  - string
                                  - 'null'
                                enum:
                                  - immediately
                                  - next_invoice
                                  - custom
                                description: >

                                  Policy defining when seat count changes are
                                  invoiced. Only applies to connected seat
                                  products.


                                  - `immediately`: Seat changes are invoiced
                                  immediately.

                                  - `next_invoice`: Seat changes are invoiced at
                                  the next invoice.

                                  - `custom`: Seat changes are invoiced on a
                                  custom schedule.
                              metering_interval_type:
                                type: string
                                enum:
                                  - subscription_commitment
                                  - payment_interval
                                  - full_database
                                  - phase_duration
                                  - custom
                                description: >-

                                  Indicates on which type of interval the usage
                                  should be aggregated.


                                  - `subscription_commitment`: For the usage
                                  contained within the subscription commitment
                                  period.

                                  - `payment_interval`: For the usage contained
                                  within the payment interval of the product.

                                  - `full_database`: For all the usage we
                                  ingested for this product, no matter the
                                  period.

                                  - `phase_duration`: For the usage contained
                                  within the subscription phase.

                                  - `custom`: For the usage contained within a
                                  custom interval that starts with the phase and
                                  renews independently of the billing interval.
                                  Requires `metering_interval` to be set.
                                     Only applies to products of type `usage`.
                              metering_interval:
                                type: object
                                properties:
                                  period:
                                    type: string
                                    enum:
                                      - days
                                      - weeks
                                      - months
                                      - years
                                  count:
                                    type: integer
                                    minimum: 1
                                required:
                                  - period
                                  - count
                                description: >-
                                  Custom interval for usage aggregation.
                                  Required when `metering_interval_type` is
                                  `custom`. The interval starts at the phase
                                  start and renews on its own cycle (e.g. `{
                                  period: 'months', count: 3 }` for quarterly
                                  metering with monthly billing). Only applies
                                  to products of type `usage`.
                              bill_usage_difference:
                                anyOf:
                                  - type: boolean
                                  - type: string
                                    enum:
                                      - 'true'
                                      - 'false'
                                default: false
                                description: >-
                                  Only bill the usage difference comparing to
                                  the previous period (i.e. actual amount minus
                                  last invoice amount). Doesn't apply to
                                  `payment_interval` metering interval type.
                                  Only applies to products of type `usage`.
                              children_usage_aggregation:
                                type:
                                  - string
                                  - 'null'
                                enum:
                                  - sum
                                  - max
                                description: >-

                                  Controls whether a parent organization's
                                  metered usage is billed on the combined usage
                                  of the parent and its direct children, and how
                                  per-member values are combined.


                                  - `null`: Organization-based usage is
                                  disabled. Only the subscription customer's own
                                  usage is billed.

                                  - `sum`: The usage values of the parent and
                                  each direct child are added together
                                  (organization total).

                                  - `max`: Only the single highest-consuming
                                  member (parent or one direct child) is billed.
                                   Only applies to products of type `usage`.
                              credits_expiration_in_days:
                                type:
                                  - number
                                  - 'null'
                                description: >-
                                  Validity in days for credits that will be
                                  topped-up automatically. Once the period has
                                  passed, they'll expire.
                              expire_credits_at_end_of_period:
                                anyOf:
                                  - type: boolean
                                  - type: string
                                    enum:
                                      - 'true'
                                      - 'false'
                                default: false
                                description: >-
                                  Automatically set the expiration date to the
                                  end of the next period for each topup. Takes
                                  priority on `creditsExpirationInDays`
                              credits_balance_auto_creation_enabled:
                                anyOf:
                                  - type: boolean
                                  - type: string
                                    enum:
                                      - 'true'
                                      - 'false'
                                description: >-
                                  Whether to create the customer credit balance
                                  as soon as the product is added to the
                                  subscription. Defaults to the credit product's
                                  `credits_balance_auto_creation_enabled`
                                  (`true` when unset). Set to `false` to create
                                  the balance by hand before activation, e.g. on
                                  quote-based renewals where the balance must
                                  not start consuming before signature; the
                                  first top-up creates it if still missing.
                            required:
                              - id
                          description: Products that make up the subscription.
                        coupons:
                          type: array
                          items:
                            allOf:
                              - anyOf:
                                  - type: object
                                    properties:
                                      id:
                                        type: string
                                        description: >-
                                          ID of the catalog coupon to apply to the
                                          subscription.
                                    required:
                                      - id
                                    title: Existing coupon
                                  - type: object
                                    properties:
                                      type:
                                        type: string
                                        enum:
                                          - amount
                                      name:
                                        type: string
                                        description: Coupon name.
                                      discount_amount:
                                        type: number
                                        exclusiveMinimum: 0
                                        description: >-
                                          Coupon discount amount. Expressed in
                                          currency's smallest unit.
                                    required:
                                      - type
                                      - discount_amount
                                    title: Coupon amount
                                  - type: object
                                    properties:
                                      type:
                                        type: string
                                        enum:
                                          - percent
                                      name:
                                        type: string
                                        description: Coupon name.
                                      discount_percent:
                                        type: number
                                        exclusiveMinimum: 0
                                        maximum: 100
                                        description: Coupon discount percentage.
                                    required:
                                      - type
                                      - discount_percent
                                    title: Coupon percent
                              - type: object
                                properties:
                                  repeat:
                                    type:
                                      - string
                                      - 'null'
                                    enum:
                                      - once
                                      - forever
                                      - custom
                                      - duration
                                    description: >

                                      Coupon frequency. Required for inline
                                      coupons. Optional when an existing coupon
                                      `id` is provided: if omitted, defaults to
                                      the catalog coupon's repeat value.


                                      - `once`: Will apply the coupon only to
                                      the first one invoice.

                                      - `forever`: Will apply the coupon to all
                                      invoices.

                                      - `custom`: Will apply to coupon until a
                                      specified expiration date.

                                      - `duration`: Will apply the coupon for a
                                      specific duration (e.g., 3 months).
                                  duration_period:
                                    type: string
                                    enum:
                                      - days
                                      - weeks
                                      - months
                                      - years
                                    description: >-
                                      Period of time for which the coupon will
                                      be applied. Only applies to the `duration`
                                      coupon frequency.
                                  duration_count:
                                    type: number
                                    description: >-
                                      Number of periods for which the coupon
                                      will be applied. Only applies to the
                                      `duration` coupon frequency.
                                  expires_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Coupon expiration date. Only applies to
                                      the `custom` coupon frequency. UTC date
                                      time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  apply_at:
                                    type: string
                                    format: date-time
                                    description: >-
                                      Coupon first application date. UTC date
                                      time string in the [ISO
                                      8601](https://en.wikipedia.org/wiki/ISO_8601)
                                      format.
                                    example: '2024-12-20T16:04:11Z'
                                  product_ids:
                                    type:
                                      - array
                                      - 'null'
                                    items:
                                      type: string
                                    minItems: 1
                                    description: >-
                                      Products the coupon is scoped to on this
                                      subscription, read together with
                                      `product_scope`: the only discounted
                                      products when `include`, the products
                                      never discounted when `exclude`, null when
                                      `all`. When sent without `product_scope`,
                                      it is an `include` list, except that a
                                      coupon already stored as `exclude` keeps
                                      `exclude` when its phase is updated; when
                                      empty or omitted, the catalog coupon's
                                      scope is copied.
                                  product_scope:
                                    type:
                                      - string
                                      - 'null'
                                    enum:
                                      - all
                                      - include
                                      - exclude
                                    description: >-
                                      Which products the coupon discounts on
                                      this subscription. `all`: every product
                                      (`product_ids` must be empty). `include`:
                                      only the products in `product_ids`.
                                      `exclude`: every product except those in
                                      `product_ids` (lines without a product
                                      stay discounted). When sent, it replaces
                                      the catalog coupon's scope together with
                                      `product_ids`. When omitted, it is
                                      inferred: `include` if `product_ids` is
                                      non-empty, else the catalog coupon's
                                      scope. On a phase update, a coupon already
                                      stored as `exclude` keeps `exclude` when
                                      `product_ids` is sent without
                                      `product_scope`.
                    - type: object
                      properties:
                        trial:
                          type: object
                          properties:
                            end_strategy:
                              type: string
                              enum:
                                - manual
                                - end_date
                                - duration
                              description: Defines how the free trial will end.
                            starts_at:
                              type: string
                              format: date-time
                              description: >-
                                Free trial start date. UTC date time string in
                                the [ISO
                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                format.
                              example: '2024-12-20T16:04:11Z'
                            ends_at:
                              type: string
                              format: date-time
                              description: >-
                                Free trial end date. Only applies if the end
                                strategy is `end_date`. UTC date time string in
                                the [ISO
                                8601](https://en.wikipedia.org/wiki/ISO_8601)
                                format.
                              example: '2024-12-20T16:04:11Z'
                            duration:
                              type: object
                              properties:
                                period:
                                  type: string
                                  enum:
                                    - days
                                    - weeks
                                    - months
                                    - years
                                  description: >-
                                    Free trial duration period. Only applies if
                                    the end strategy is `duration`.
                                count:
                                  type: number
                                  minimum: 1
                                  description: >-
                                    Free trial duration count. Only applies if
                                    the end strategy is `duration`.
                              required:
                                - period
                                - count
                          required:
                            - end_strategy
                          description: >-
                            Create a free trial phase based on the plan
                            configuration. Only applies if a `plan_id` is
                            provided.
                  title: Without phases
          description: >-
            Configuration the subscription has once the update is applied. It is
            billed in the source subscription's currency.
      required:
        - source_subscription_id
        - target_subscription
      description: >-
        Update of an existing subscription constituting the quote. When
        provided, a `subscription_update` quote is created: the update is
        applied to the subscription once the quote is signed. Cannot be combined
        with `subscription`, `invoice` or `template_id`.
    CreateQuoteInvoice:
      type: object
      properties:
        invoicing_entity_id:
          type: string
          description: ID of the invoicing entity issuing the invoice.
          example: ive_47484fjdhy5
        number:
          type: string
          description: >-
            Invoice number. If specified, the invoice will be considered as
            imported from an external source and the number will not be
            generated by Hyperline. You are responsible for avoiding duplicates
            and ensuring it does not impact the numbering sequence in Hyperline.
          example: INV-35
        reference:
          type: string
          description: >-
            Unique identifier to ease reconciliation with payment. Useful for
            bank transfer.
          example: V0KAHOU6J3
        purchase_order:
          type: string
          description: Reference to the purchase order linked to the invoice.
          example: PO-12345
        custom_note:
          type: string
          description: Custom note added to the invoice.
          example: Thank you for your purchase!
        additional_info:
          type: string
          description: >-
            Additional information added to the invoice. If not defined, it will
            be inherited from the invoicing entity's settings.
          example: >-
            This invoice must be paid within the payment delay indicated. After
            this period a late payment penalty of 10% will be applied.
        footer:
          type: string
          description: >-
            Footer added to the invoice. If not defined, it will be inherited
            from the invoicing entity's settings.
          example: ACME (Acme SAS) is a company registered in France | SIREN N°123456
        tax_scheme:
          type: string
          enum:
            - auto
            - not_eligible
          default: auto
          description: |-
            Tax scheme of the invoice.

            - `auto`: Tax is automatically computed and applied.
            - `not_eligible`: Tax collection is disabled for the invoice.
              
          example: auto
        payment_method_strategy:
          type: string
          enum:
            - current
            - external
          description: >

            Payment method strategy used to charge the invoice. Only applies to
            `to_pay` status.


            - `current`: Use the current default payment method of the customer.

            - `external`: Manage the payment of the invoice outside of
            Hyperline.
          example: external
        payment_method_id:
          type: string
          description: >-
            ID of the default payment method used to pay the invoice.
            Transactions related to the invoice may use different payment
            methods.
          example: pm_1ryTrMj4TTAT1N
        bank_account_id:
          type: string
          description: >-
            ID of the bank account displayed on the invoice. Transactions
            related to the invoice may use different bank accounts.
          example: bac_KJyPrMA1toAqRG
        subscription_id:
          type: string
          description: >-
            ID of an existing subscription of the customer to attach the invoice
            to.
          example: sub_amiaWZ3lzDIWaoT
        emitted_at:
          type: string
          format: date-time
          description: Issue date of the invoice.
          example: '2026-10-13T00:00:00.000Z'
        due_at:
          type: string
          format: date-time
          description: >-
            Due date of the invoice. Computed from the issue date and the
            payment delay configured in your settings.
          example: '2026-11-12T00:00:00.000Z'
        properties:
          type: object
          additionalProperties:
            anyOf:
              - type: string
              - type: number
              - type: boolean
              - type: 'null'
              - type: array
                items:
                  anyOf:
                    - type: string
                    - type: number
                    - type: boolean
                    - type: 'null'
                    - type: 'null'
              - type: 'null'
          description: Key/value pairs to store any metadata useful in your context.
        custom_properties:
          type: object
          additionalProperties:
            anyOf:
              - type: string
              - type: number
              - type: boolean
              - type: string
                format: date-time
                description: >-
                  UTC date time string in the [ISO
                  8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                example: '2024-12-20T16:04:11Z'
              - type: array
                items:
                  type: string
              - type: 'null'
          description: >-
            Values for custom properties defined for the `invoice` entity, keyed
            by slug.
        line_items:
          type: array
          items:
            $ref: '#/components/schemas/CreateQuoteInvoiceLineItem'
          minItems: 1
          description: >-
            Line items of the invoice to be issued upon quote signature. At
            least one line item is required. Each line must reference a catalog
            product via `product_id`; `unit_amount` and `name` optionally
            override the catalog price and label for this quote.
        coupons:
          type: array
          items:
            anyOf:
              - type: object
                properties:
                  coupon_id:
                    type: string
                    description: ID of the catalog coupon to apply to the invoice.
                    example: cou_1eTaiytfA0i2Vb
                  name:
                    type: string
                    minLength: 1
                    description: Name of the coupon.
                    example: Black Friday 2026
                  discount_amount:
                    type: number
                    exclusiveMinimum: 0
                    description: >-
                      Amount corresponding to the discounted part of the total
                      amount.
                    example: 500
                  discount_percent:
                    type: number
                    exclusiveMinimum: 0
                    maximum: 100
                    description: >-
                      Percentage overriding the catalog coupon value, applied to
                      the eligible line items amount (excluding tax), between 0
                      (excluded) and 100. Cannot be combined with
                      `discount_amount`.
                    example: 10
                  line_item_indexes:
                    type:
                      - array
                      - 'null'
                    items:
                      type: number
                    description: >-
                      Index of the line items to which the coupon applies. Null
                      means all line items.
                    example:
                      - 0
                      - 1
                required:
                  - coupon_id
                title: Coupon amount
              - type: object
                properties:
                  name:
                    type: string
                    minLength: 1
                    description: Name of the coupon.
                    example: Black Friday 2026
                  discount_amount:
                    type: number
                    exclusiveMinimum: 0
                    description: >-
                      Amount corresponding to the discounted part of the total
                      amount.
                    example: 500
                  line_item_indexes:
                    type:
                      - array
                      - 'null'
                    items:
                      type: number
                    description: >-
                      Index of the line items to which the coupon applies. Null
                      means all line items.
                    example:
                      - 0
                      - 1
                required:
                  - discount_amount
                  - line_item_indexes
                title: Inline coupon
              - type: object
                properties:
                  name:
                    type: string
                    minLength: 1
                    description: Name of the coupon.
                    example: Black Friday 2026
                  discount_percent:
                    type: number
                    exclusiveMinimum: 0
                    maximum: 100
                    description: >-
                      Percentage of the eligible line items amount (excluding
                      tax) to discount, between 0 (excluded) and 100.
                    example: 10
                  line_item_indexes:
                    type:
                      - array
                      - 'null'
                    items:
                      type: number
                    description: >-
                      Index of the line items to which the coupon applies. Null
                      means all line items.
                    example:
                      - 0
                      - 1
                required:
                  - discount_percent
                additionalProperties: false
                title: Inline percent coupon
          description: >-
            Coupons to apply to the invoice. Each coupon either references an
            existing coupon by id or defines an inline discount.
      required:
        - line_items
      description: >-
        Invoice configuration constituting the one-off quote. When provided, a
        draft invoice is created and linked to the quote. Cannot be combined
        with `subscription` or `template_id`.
    CreatedQuote:
      allOf:
        - $ref: '#/components/schemas/Quote'
        - type: object
          properties:
            warnings:
              type: array
              items:
                $ref: '#/components/schemas/QuoteWarning'
              description: >-
                Non-blocking issues met while creating the quote. Empty when
                there are none.
          required:
            - warnings
    MeteringFilterConfiguration:
      type: object
      properties:
        conditional:
          type: string
          enum:
            - and
            - or
          description: >-
            Logical operator used to combine multiple filter fields. `and`
            requires all fields to match, `or` requires at least one.
        fields:
          type: array
          items:
            allOf:
              - type: object
                properties:
                  property:
                    type: string
                    description: Name of the event property to filter on.
                required:
                  - property
              - oneOf:
                  - type: object
                    properties:
                      operator:
                        type: string
                        enum:
                          - is_null
                          - is_not_null
                        description: Comparison operator to apply on the property value.
                    required:
                      - operator
                    title: Null check
                  - type: object
                    properties:
                      operator:
                        type: string
                        enum:
                          - in
                          - not_in
                        description: Comparison operator to apply on the property value.
                      value:
                        type: string
                    required:
                      - operator
                      - value
                    title: List match
                  - type: object
                    properties:
                      operator:
                        type: string
                        enum:
                          - gte
                          - gt
                          - lt
                          - lte
                        description: Comparison operator to apply on the property value.
                      value:
                        type: number
                    required:
                      - operator
                      - value
                    title: Numeric comparison
                  - type: object
                    properties:
                      operator:
                        type: string
                        enum:
                          - equals
                          - not_equal
                        description: Comparison operator to apply on the property value.
                      value:
                        anyOf:
                          - type: string
                          - type: number
                          - type: boolean
                    required:
                      - operator
                      - value
                    title: Equality check
      required:
        - conditional
        - fields
      description: Configuration of the rules used to filter eligible events.
      example:
        conditional: and
        fields:
          - property: card_type
            operator: equals
            value: visa
          - property: kind
            operator: equals
            value: credit_card
    CreateQuoteInvoiceLineItem:
      type: object
      properties:
        description:
          type: string
          maxLength: 5000
          description: >-
            Description of the line item as it will appear on the invoice.
            Default to the product description.
          example: Access fee from October 13 to November 13, 2026
        product_id:
          type: string
        price_configuration_id:
          type:
            - string
            - 'null'
          description: >-
            ID of the catalog price configuration linked to the line. Determines
            the product and revenue classification when subscription terms
            cannot be resolved. Must belong to the supplied product, if any. On
            finalized invoices, changing this link never changes amounts or
            taxes.
          example: pcf_monthly
        units_count:
          type: number
          default: 1
          description: Count of units of the product related to the invoice line item.
          example: 1
        tax_rate:
          type: number
          minimum: 0
          maximum: 100
          description: Tax rate of the invoice line item.
          example: 20
        period_start:
          type: string
          format: date-time
          description: Start date of the line item's service period.
          example: '2026-10-13T00:00:00.000Z'
        period_end:
          type: string
          format: date-time
          description: End date of the line item's service period.
          example: '2026-11-13T00:00:00.000Z'
        revenue_type:
          type: string
          enum:
            - recurring
            - variable
            - one_off
          description: >-
            Revenue classification for custom or imported lines without
            resolvable subscription or catalog billing terms. Derived
            automatically when a source exists; conflicting explicit values are
            rejected. New lines without a source or explicit classification
            default to one_off. Existing lines retain their classification
            unless corrected.
          example: recurring
        revenue_interval_count:
          type:
            - integer
            - 'null'
          exclusiveMinimum: 0
          description: >-
            Number of billing interval periods for recurring or variable revenue
            (e.g., 1 with months for monthly, 1 with years for annual). This is
            separate from the line service dates.
          example: 1
        revenue_interval_period:
          type:
            - string
            - 'null'
          enum:
            - days
            - weeks
            - months
            - quarters
            - years
          description: >-
            Billing interval unit for recurring or variable revenue (days,
            weeks, months, quarters, years). One-off revenue has no billing
            interval.
          example: months
        display_unit_amount:
          type: boolean
          description: >-
            Whether the unit amount is displayed on the invoice PDF. Defaults to
            true.
          example: true
        display_service_period:
          type: boolean
          description: >-
            Whether the service period dates are displayed in the line item
            description on the invoice PDF. Defaults to true.
          example: true
        name:
          type: string
          description: >-
            Name of the line item as it will appear on the invoice. Default to
            the product name.
          example: Platform access
        unit_amount:
          type: number
          description: >-
            Amount of one unit of the product related to the invoice line item.
            Default to the product price amount. Expressed in currency's
            smallest unit.
          example: 24000
      required:
        - product_id
    Quote:
      anyOf:
        - $ref: '#/components/schemas/QuoteDraft'
        - $ref: '#/components/schemas/QuoteAwaitingApproval'
        - $ref: '#/components/schemas/QuoteReadyForSignature'
        - $ref: '#/components/schemas/QuoteSigned'
        - $ref: '#/components/schemas/QuoteVoided'
    QuoteWarning:
      type: object
      properties:
        code:
          type: string
          enum:
            - subscription_template_configuration_not_found
          description: >

            Warning code.


            - `subscription_template_configuration_not_found`: The quote
            template's subscription template has no configuration matching the
            customer's currency and country, so the quote was created without a
            subscription.
        subscription_template_id:
          type: string
          description: ID of the quote template's subscription template.
          example: subt_ieLWHmDZVMoznt
        currency:
          type:
            - string
            - 'null'
          enum:
            - EUR
            - AED
            - AFN
            - XCD
            - ALL
            - AMD
            - AOA
            - ARS
            - USD
            - AUD
            - AWG
            - AZN
            - BAM
            - BBD
            - BDT
            - BGN
            - BHD
            - BIF
            - XOF
            - BMD
            - BND
            - BOB
            - BRL
            - BSD
            - BTN
            - NOK
            - BWP
            - BYR
            - BZD
            - CAD
            - CDF
            - XAF
            - CHF
            - NZD
            - CLP
            - CNY
            - COP
            - CRC
            - CUP
            - CVE
            - ANG
            - CZK
            - DJF
            - DKK
            - DOP
            - DZD
            - EGP
            - MAD
            - ERN
            - ETB
            - FJD
            - FKP
            - GBP
            - GEL
            - GHS
            - GIP
            - GMD
            - GNF
            - GTQ
            - GYD
            - HKD
            - HNL
            - HRK
            - HTG
            - HUF
            - IDR
            - ILS
            - INR
            - IQD
            - IRR
            - ISK
            - JMD
            - JOD
            - JPY
            - KES
            - KGS
            - KHR
            - KMF
            - KPW
            - KRW
            - KWD
            - KYD
            - KZT
            - LAK
            - LBP
            - LKR
            - LRD
            - LSL
            - LYD
            - MDL
            - MGA
            - MKD
            - MMK
            - MNT
            - MOP
            - MRO
            - MUR
            - MVR
            - MWK
            - MXN
            - MYR
            - MZN
            - NAD
            - XPF
            - NGN
            - NIO
            - NPR
            - OMR
            - PAB
            - PEN
            - PGK
            - PHP
            - PKR
            - PLN
            - PYG
            - QAR
            - RON
            - RSD
            - RUB
            - RWF
            - SAR
            - SBD
            - SCR
            - SDG
            - SEK
            - SGD
            - SHP
            - SLL
            - SOS
            - SRD
            - SSP
            - STD
            - SYP
            - SZL
            - THB
            - TJS
            - TMT
            - TND
            - TOP
            - TRY
            - TTD
            - TWD
            - TZS
            - UAH
            - UGX
            - UYU
            - UZS
            - VEF
            - VND
            - VUV
            - WST
            - YER
            - ZAR
            - ZMW
            - ZWL
          description: >-
            Customer currency used to match a subscription template
            configuration. `null` when the customer has no currency.
          example: EUR
        country:
          type:
            - string
            - 'null'
          enum:
            - AD
            - AE
            - AF
            - AG
            - AI
            - AL
            - AM
            - AO
            - AQ
            - AR
            - AS
            - AT
            - AU
            - AW
            - AX
            - AZ
            - BA
            - BB
            - BD
            - BE
            - BG
            - BH
            - BI
            - BJ
            - BL
            - BM
            - BN
            - BO
            - BQ
            - BR
            - BS
            - BT
            - BF
            - BV
            - BW
            - BY
            - BZ
            - CA
            - CC
            - CD
            - CF
            - CG
            - CH
            - CI
            - CK
            - CL
            - CM
            - CN
            - CO
            - CR
            - CU
            - CV
            - CW
            - CX
            - CY
            - CZ
            - DE
            - DJ
            - DK
            - DM
            - DO
            - DZ
            - EC
            - EE
            - EG
            - EH
            - ER
            - ES
            - ES-CE
            - ES-ML
            - ET
            - FI
            - FJ
            - FK
            - FM
            - FO
            - FR
            - GA
            - GB
            - GD
            - GE
            - GF
            - GG
            - GH
            - GI
            - GL
            - GM
            - GN
            - GP
            - GQ
            - GR
            - GS
            - GT
            - GU
            - GW
            - GY
            - HK
            - HM
            - HN
            - HR
            - HT
            - HU
            - IC
            - ID
            - IE
            - IL
            - IM
            - IN
            - IO
            - IQ
            - IR
            - IS
            - IT
            - JE
            - JM
            - JO
            - JP
            - KE
            - KG
            - KH
            - KI
            - KM
            - KN
            - KP
            - KR
            - KW
            - KY
            - KZ
            - LA
            - LB
            - LC
            - LI
            - LK
            - LR
            - LS
            - LT
            - LU
            - LV
            - LY
            - MA
            - MC
            - MD
            - ME
            - MF
            - MG
            - MH
            - MK
            - ML
            - MM
            - MN
            - MO
            - MP
            - MQ
            - MR
            - MS
            - MT
            - MU
            - MV
            - MW
            - MX
            - MY
            - MZ
            - NA
            - NC
            - NE
            - NF
            - NG
            - NI
            - NL
            - 'NO'
            - NP
            - NR
            - NU
            - NZ
            - OM
            - PA
            - PE
            - PF
            - PG
            - PH
            - PK
            - PL
            - PM
            - PN
            - PR
            - PS
            - PT
            - PT-20
            - PT-30
            - PW
            - PY
            - QA
            - RE
            - RO
            - RS
            - RU
            - RW
            - SA
            - SB
            - SC
            - SD
            - SE
            - SG
            - SH
            - SI
            - SJ
            - SK
            - SL
            - SM
            - SN
            - SO
            - SR
            - SS
            - ST
            - SV
            - SX
            - SY
            - SZ
            - TC
            - TD
            - TF
            - TG
            - TH
            - TJ
            - TK
            - TL
            - TM
            - TN
            - TO
            - TR
            - TT
            - TV
            - TW
            - TZ
            - UA
            - UG
            - UM
            - US
            - UY
            - UZ
            - VA
            - VC
            - VE
            - VG
            - VI
            - VN
            - VU
            - WF
            - WS
            - XK
            - YE
            - YT
            - ZA
            - ZM
            - ZW
          description: >-
            Customer country used to match a subscription template
            configuration. `null` when the customer has no country.
          example: DE
      required:
        - code
        - subscription_template_id
        - currency
        - country
    QuoteDraft:
      type: object
      properties:
        id:
          type: string
          description: Quote ID.
          example: quo_hXQCd5y8P3GYXa
        type:
          type:
            - string
            - 'null'
          enum:
            - subscription
            - subscription_update
            - one_off
            - mixed
          description: >

            Quote type.


            - `subscription`: The quote will create one or more subscriptions.

            - `subscription_update`: The quote will update one or more existing
            subscriptions.

            - `one_off`: The quote will issue one or more one-off invoices.

            - `mixed`: Mixed configuration types.

            - `null`: Empty quote.
        status:
          type: string
          enum:
            - draft
          description: >

            Quote status.


            - `draft`: The quote is a draft.

            - `pending_approval`: The quote is pending manager review and
            approval.

            - `changes_requested`: Some changes have been requested following
            manager review.

            - `approved`: The quote is approved and ready to be sent to the
            customer.

            - `pending_signature`: The quote is awaiting the customer's
            signature.

            - `signed`: The quote is signed and fully finalized.

            - `voided`: The quote is voided.
          example: draft
        amount:
          type:
            - number
            - 'null'
          description: >-
            Estimated contract value. When computed, a subscription phase with
            neither an end date nor a fixed duration is counted over a
            conventional horizon: the contract's length for a single phase on a
            contract that has one, otherwise 12 months or the longest billing
            interval if longer. That horizon is not an end date: the
            subscription can run past it. Usage-based and connected seat lines
            are priced at their estimated quantity when it exceeds the committed
            quantity and, for seats, the live seat count.
          example: 200000
        customer_id:
          type: string
          description: ID of the customer the quote is addressed to.
          example: cus_QalW2vTAdkR6IY
        invoicing_entity_id:
          type: string
          description: ID of the invoicing entity attached to the quote.
          example: ive_47484fjdhy5
        configurations:
          type: array
          items:
            $ref: '#/components/schemas/QuoteConfiguration'
          description: Ordered configurations included in the quote.
        template_id:
          type:
            - string
            - 'null'
          description: ID of the quote template the quote is built from.
          example: quot_9hNWq4c84Z146W
        crm_opportunity_id:
          type:
            - string
            - 'null'
          description: ID of the related opportunity/deal in the connected CRM.
          example: opp_Z2oSqnBCUoo1bQ
        custom_properties:
          type:
            - object
            - 'null'
          additionalProperties:
            anyOf:
              - type: string
              - type: number
              - type: boolean
              - type: string
                format: date-time
                description: >-
                  UTC date time string in the [ISO
                  8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                example: '2024-12-20T16:04:11Z'
              - type: array
                items:
                  type: string
              - type: 'null'
          description: >-
            Custom property values set on the quote itself, keyed by slug.
            Custom property values of a quote's subscription are returned on the
            subscription.
        contract_value:
          type:
            - number
            - 'null'
          description: >-
            What the customer pays over the contract, each coupon counted on the
            invoices it applies to. Computed from the subscription for
            `subscription` and `subscription_update` quotes, unless set
            manually. Not set on `one_off` quotes.
          example: 18000
        number:
          type: string
          description: Quote sequential number.
          example: '327'
        comments:
          type:
            - string
            - 'null'
          description: Custom comments displayed on the quote.
          example: Please find the contract and subscription details we discussed.
        terms:
          type:
            - string
            - 'null'
          description: Custom quotation terms.
          example: >-
            By signing this quote, you accept our conditions of use for the use
            of our products and services.
        owner_email:
          type:
            - string
            - 'null'
          format: email
          description: >-
            Email address of the Hyperline user acting as the quote owner. The
            user must be a member of your Hyperline account. The owner requests
            approval when the quote is finalized using an API key or finalized
            during creation.
          example: joe@acme.com
        collect_payment_details:
          type: boolean
          description: >-
            Collect customer payment method mandate during signature flow or
            not.
          example: true
        collect_custom_property_ids:
          type: array
          items:
            type: string
          description: >-
            IDs of the customer custom properties required to be filled during
            the signature flow.
          example: []
        require_tax_id:
          type: boolean
          description: Require the customer to provide a tax ID during the signature flow.
          example: false
        display_quote_value:
          type: boolean
          description: Display the total quote value on the quote.
          example: true
        display_quote_value_with_tax:
          type: boolean
          description: Display the total quote value including tax on the quote.
          example: false
        display_taxes:
          type: boolean
          description: Display tax breakdown on the quote.
          example: true
        display_price_tiers:
          type: string
          enum:
            - all
            - matching
            - none
            - unit_price
          description: >
            Controls which price tiers are displayed on the quote.


            - `all`: Display all pricing tiers.

            - `matching`: Only display the tiers used to compute the price based
            on quantity.

            - `none`: Hide all pricing tiers.

            - `unit_price`: Show only the unit price, without tiers.
          example: matching
        display_phase_value:
          type: boolean
          description: Display per-phase value breakdown on the quote.
          example: false
        display_discounts_on_total:
          type: boolean
          description: >-
            Display discounts on the totals, with product prices before
            discount. Totals then follow the contract value, so discounts with a
            limited duration are included.
          example: false
        display_first_invoice_amount:
          type: boolean
          description: Display the first invoice amount on the quote.
          example: false
        display_documents_in_preview:
          type: boolean
          description: Display attached documents in the quote preview.
          example: false
        subscription_update_display:
          type: string
          enum:
            - quote_update_details
            - subscription_details
            - both
          description: >-
            Sections displayed on subscription update quotes:
            quote_update_details, subscription_details, or both. Takes
            precedence over display_subscription_on_update.
          example: quote_update_details
        post_signature_activation_enabled:
          type: boolean
          description: >-
            Whether the subscription is automatically orchestrated after the
            quote is signed. Only applies to the Hyperline CPQ-only product.
          example: true
        generate_draft_invoices:
          type: boolean
          description: >-
            When `true`, the invoice issued after signature stays in `draft`
            status instead of being emitted for payment. Use this when you want
            to review the final invoice manually before sending it. Defaults to
            `false`.
          example: false
        attachments:
          type: array
          items:
            $ref: '#/components/schemas/QuoteFile'
          description: List of documents attached to the quote.
          example:
            - id: quof_5GYXy8P3QCdaXh
              name: General Conditions of Sale
              mimetype: application/pdf
        signed_file:
          allOf:
            - $ref: '#/components/schemas/QuoteFile'
            - type:
                - object
                - 'null'
              description: Final signed quote (manually uploaded).
              example: null
        url:
          type:
            - string
            - 'null'
          format: uri
          description: >-
            URL to access the quote publicly. Only applies to the
            `pending_signature` or `signed` quote.
          example: https://billing.hyperline.co/quote/quo_hXQCd5y8P3GYXa
        created_at:
          type: string
          format: date-time
          description: >-
            Quote creation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T09:10:00.220Z'
        updated_at:
          type: string
          format: date-time
          description: >-
            Quote update date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T10:22:08.100Z'
        expires_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            Quote expiration date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: null
        subscription_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].subscription_id`.
        invoice_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].invoice_id`.
        child_subscription_ids:
          type: array
          items:
            type: string
          deprecated: true
          description: >-
            Deprecated field, please use `GET /v2/subscriptions` with the
            `original_quote_id` filter.
        display_subscription_on_update:
          type: boolean
          deprecated: true
          description: >-
            Deprecated. Use subscription_update_display. False displays quote
            update details; true displays both sections.
          example: false
      required:
        - id
        - type
        - status
        - amount
        - customer_id
        - invoicing_entity_id
        - configurations
        - template_id
        - crm_opportunity_id
        - custom_properties
        - contract_value
        - number
        - comments
        - terms
        - owner_email
        - collect_payment_details
        - collect_custom_property_ids
        - require_tax_id
        - display_quote_value
        - display_quote_value_with_tax
        - display_taxes
        - display_price_tiers
        - display_phase_value
        - display_discounts_on_total
        - display_first_invoice_amount
        - display_documents_in_preview
        - subscription_update_display
        - post_signature_activation_enabled
        - generate_draft_invoices
        - attachments
        - signed_file
        - url
        - created_at
        - updated_at
        - expires_at
        - subscription_id
        - display_subscription_on_update
      title: Draft
    QuoteAwaitingApproval:
      type: object
      properties:
        id:
          type: string
          description: Quote ID.
          example: quo_hXQCd5y8P3GYXa
        type:
          type:
            - string
            - 'null'
          enum:
            - subscription
            - subscription_update
            - one_off
            - mixed
          description: >

            Quote type.


            - `subscription`: The quote will create one or more subscriptions.

            - `subscription_update`: The quote will update one or more existing
            subscriptions.

            - `one_off`: The quote will issue one or more one-off invoices.

            - `mixed`: Mixed configuration types.

            - `null`: Empty quote.
        status:
          type: string
          enum:
            - pending_approval
            - changes_requested
          description: >

            Quote status.


            - `draft`: The quote is a draft.

            - `pending_approval`: The quote is pending manager review and
            approval.

            - `changes_requested`: Some changes have been requested following
            manager review.

            - `approved`: The quote is approved and ready to be sent to the
            customer.

            - `pending_signature`: The quote is awaiting the customer's
            signature.

            - `signed`: The quote is signed and fully finalized.

            - `voided`: The quote is voided.
          example: pending_approval
        amount:
          type: number
          description: >-
            Estimated contract value. When computed, a subscription phase with
            neither an end date nor a fixed duration is counted over a
            conventional horizon: the contract's length for a single phase on a
            contract that has one, otherwise 12 months or the longest billing
            interval if longer. That horizon is not an end date: the
            subscription can run past it. Usage-based and connected seat lines
            are priced at their estimated quantity when it exceeds the committed
            quantity and, for seats, the live seat count.
          example: 20000
        customer_id:
          type: string
          description: ID of the customer the quote is addressed to.
          example: cus_QalW2vTAdkR6IY
        invoicing_entity_id:
          type: string
          description: ID of the invoicing entity attached to the quote.
          example: ive_47484fjdhy5
        configurations:
          type: array
          items:
            $ref: '#/components/schemas/QuoteConfiguration'
          description: Ordered configurations included in the quote.
        template_id:
          type:
            - string
            - 'null'
          description: ID of the quote template the quote is built from.
          example: quot_9hNWq4c84Z146W
        crm_opportunity_id:
          type:
            - string
            - 'null'
          description: ID of the related opportunity/deal in the connected CRM.
          example: opp_Z2oSqnBCUoo1bQ
        custom_properties:
          type:
            - object
            - 'null'
          additionalProperties:
            anyOf:
              - type: string
              - type: number
              - type: boolean
              - type: string
                format: date-time
                description: >-
                  UTC date time string in the [ISO
                  8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                example: '2024-12-20T16:04:11Z'
              - type: array
                items:
                  type: string
              - type: 'null'
          description: >-
            Custom property values set on the quote itself, keyed by slug.
            Custom property values of a quote's subscription are returned on the
            subscription.
        contract_value:
          type:
            - number
            - 'null'
          description: >-
            What the customer pays over the contract, each coupon counted on the
            invoices it applies to. Computed from the subscription for
            `subscription` and `subscription_update` quotes, unless set
            manually. Not set on `one_off` quotes.
          example: 18000
        number:
          type: string
          description: Quote sequential number.
          example: '327'
        comments:
          type:
            - string
            - 'null'
          description: Custom comments displayed on the quote.
          example: Please find the contract and subscription details we discussed.
        terms:
          type:
            - string
            - 'null'
          description: Custom quotation terms.
          example: >-
            By signing this quote, you accept our conditions of use for the use
            of our products and services.
        owner_email:
          type:
            - string
            - 'null'
          format: email
          description: >-
            Email address of the Hyperline user acting as the quote owner. The
            user must be a member of your Hyperline account. The owner requests
            approval when the quote is finalized using an API key or finalized
            during creation.
          example: joe@acme.com
        collect_payment_details:
          type: boolean
          description: >-
            Collect customer payment method mandate during signature flow or
            not.
          example: true
        collect_custom_property_ids:
          type: array
          items:
            type: string
          description: >-
            IDs of the customer custom properties required to be filled during
            the signature flow.
          example: []
        require_tax_id:
          type: boolean
          description: Require the customer to provide a tax ID during the signature flow.
          example: false
        display_quote_value:
          type: boolean
          description: Display the total quote value on the quote.
          example: true
        display_quote_value_with_tax:
          type: boolean
          description: Display the total quote value including tax on the quote.
          example: false
        display_taxes:
          type: boolean
          description: Display tax breakdown on the quote.
          example: true
        display_price_tiers:
          type: string
          enum:
            - all
            - matching
            - none
            - unit_price
          description: >
            Controls which price tiers are displayed on the quote.


            - `all`: Display all pricing tiers.

            - `matching`: Only display the tiers used to compute the price based
            on quantity.

            - `none`: Hide all pricing tiers.

            - `unit_price`: Show only the unit price, without tiers.
          example: matching
        display_phase_value:
          type: boolean
          description: Display per-phase value breakdown on the quote.
          example: false
        display_discounts_on_total:
          type: boolean
          description: >-
            Display discounts on the totals, with product prices before
            discount. Totals then follow the contract value, so discounts with a
            limited duration are included.
          example: false
        display_first_invoice_amount:
          type: boolean
          description: Display the first invoice amount on the quote.
          example: false
        display_documents_in_preview:
          type: boolean
          description: Display attached documents in the quote preview.
          example: false
        subscription_update_display:
          type: string
          enum:
            - quote_update_details
            - subscription_details
            - both
          description: >-
            Sections displayed on subscription update quotes:
            quote_update_details, subscription_details, or both. Takes
            precedence over display_subscription_on_update.
          example: quote_update_details
        post_signature_activation_enabled:
          type: boolean
          description: >-
            Whether the subscription is automatically orchestrated after the
            quote is signed. Only applies to the Hyperline CPQ-only product.
          example: true
        generate_draft_invoices:
          type: boolean
          description: >-
            When `true`, the invoice issued after signature stays in `draft`
            status instead of being emitted for payment. Use this when you want
            to review the final invoice manually before sending it. Defaults to
            `false`.
          example: false
        attachments:
          type: array
          items:
            $ref: '#/components/schemas/QuoteFile'
          description: List of documents attached to the quote.
          example:
            - id: quof_5GYXy8P3QCdaXh
              name: General Conditions of Sale
              mimetype: application/pdf
        signed_file:
          allOf:
            - $ref: '#/components/schemas/QuoteFile'
            - type:
                - object
                - 'null'
              description: Final signed quote (manually uploaded).
              example: null
        url:
          type:
            - string
            - 'null'
          format: uri
          description: >-
            URL to access the quote publicly. Only applies to the
            `pending_signature` or `signed` quote.
          example: https://billing.hyperline.co/quote/quo_hXQCd5y8P3GYXa
        created_at:
          type: string
          format: date-time
          description: >-
            Quote creation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T09:10:00.220Z'
        updated_at:
          type: string
          format: date-time
          description: >-
            Quote update date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T10:22:08.100Z'
        expires_at:
          type: string
          format: date-time
          description: >-
            Quote expiration date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-28T14:12:09.293Z'
        subscription_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].subscription_id`.
        invoice_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].invoice_id`.
        child_subscription_ids:
          type: array
          items:
            type: string
          deprecated: true
          description: >-
            Deprecated field, please use `GET /v2/subscriptions` with the
            `original_quote_id` filter.
        display_subscription_on_update:
          type: boolean
          deprecated: true
          description: >-
            Deprecated. Use subscription_update_display. False displays quote
            update details; true displays both sections.
          example: false
      required:
        - id
        - type
        - status
        - amount
        - customer_id
        - invoicing_entity_id
        - configurations
        - template_id
        - crm_opportunity_id
        - custom_properties
        - contract_value
        - number
        - comments
        - terms
        - owner_email
        - collect_payment_details
        - collect_custom_property_ids
        - require_tax_id
        - display_quote_value
        - display_quote_value_with_tax
        - display_taxes
        - display_price_tiers
        - display_phase_value
        - display_discounts_on_total
        - display_first_invoice_amount
        - display_documents_in_preview
        - subscription_update_display
        - post_signature_activation_enabled
        - generate_draft_invoices
        - attachments
        - signed_file
        - url
        - created_at
        - updated_at
        - expires_at
        - subscription_id
        - display_subscription_on_update
      title: Awaiting approval
    QuoteReadyForSignature:
      type: object
      properties:
        id:
          type: string
          description: Quote ID.
          example: quo_hXQCd5y8P3GYXa
        type:
          type:
            - string
            - 'null'
          enum:
            - subscription
            - subscription_update
            - one_off
            - mixed
          description: >

            Quote type.


            - `subscription`: The quote will create one or more subscriptions.

            - `subscription_update`: The quote will update one or more existing
            subscriptions.

            - `one_off`: The quote will issue one or more one-off invoices.

            - `mixed`: Mixed configuration types.

            - `null`: Empty quote.
        status:
          type: string
          enum:
            - approved
            - pending_signature
          description: >

            Quote status.


            - `draft`: The quote is a draft.

            - `pending_approval`: The quote is pending manager review and
            approval.

            - `changes_requested`: Some changes have been requested following
            manager review.

            - `approved`: The quote is approved and ready to be sent to the
            customer.

            - `pending_signature`: The quote is awaiting the customer's
            signature.

            - `signed`: The quote is signed and fully finalized.

            - `voided`: The quote is voided.
          example: pending_signature
        amount:
          type: number
          description: >-
            Estimated contract value. When computed, a subscription phase with
            neither an end date nor a fixed duration is counted over a
            conventional horizon: the contract's length for a single phase on a
            contract that has one, otherwise 12 months or the longest billing
            interval if longer. That horizon is not an end date: the
            subscription can run past it. Usage-based and connected seat lines
            are priced at their estimated quantity when it exceeds the committed
            quantity and, for seats, the live seat count.
          example: 20000
        customer_id:
          type: string
          description: ID of the customer the quote is addressed to.
          example: cus_QalW2vTAdkR6IY
        invoicing_entity_id:
          type: string
          description: ID of the invoicing entity attached to the quote.
          example: ive_47484fjdhy5
        configurations:
          type: array
          items:
            $ref: '#/components/schemas/QuoteConfiguration'
          description: Ordered configurations included in the quote.
        template_id:
          type:
            - string
            - 'null'
          description: ID of the quote template the quote is built from.
          example: quot_9hNWq4c84Z146W
        crm_opportunity_id:
          type:
            - string
            - 'null'
          description: ID of the related opportunity/deal in the connected CRM.
          example: opp_Z2oSqnBCUoo1bQ
        custom_properties:
          type:
            - object
            - 'null'
          additionalProperties:
            anyOf:
              - type: string
              - type: number
              - type: boolean
              - type: string
                format: date-time
                description: >-
                  UTC date time string in the [ISO
                  8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                example: '2024-12-20T16:04:11Z'
              - type: array
                items:
                  type: string
              - type: 'null'
          description: >-
            Custom property values set on the quote itself, keyed by slug.
            Custom property values of a quote's subscription are returned on the
            subscription.
        contract_value:
          type:
            - number
            - 'null'
          description: >-
            What the customer pays over the contract, each coupon counted on the
            invoices it applies to. Computed from the subscription for
            `subscription` and `subscription_update` quotes, unless set
            manually. Not set on `one_off` quotes.
          example: 18000
        number:
          type: string
          description: Quote sequential number.
          example: '327'
        comments:
          type:
            - string
            - 'null'
          description: Custom comments displayed on the quote.
          example: Please find the contract and subscription details we discussed.
        terms:
          type:
            - string
            - 'null'
          description: Custom quotation terms.
          example: >-
            By signing this quote, you accept our conditions of use for the use
            of our products and services.
        owner_email:
          type:
            - string
            - 'null'
          format: email
          description: >-
            Email address of the Hyperline user acting as the quote owner. The
            user must be a member of your Hyperline account. The owner requests
            approval when the quote is finalized using an API key or finalized
            during creation.
          example: joe@acme.com
        collect_payment_details:
          type: boolean
          description: >-
            Collect customer payment method mandate during signature flow or
            not.
          example: true
        collect_custom_property_ids:
          type: array
          items:
            type: string
          description: >-
            IDs of the customer custom properties required to be filled during
            the signature flow.
          example: []
        require_tax_id:
          type: boolean
          description: Require the customer to provide a tax ID during the signature flow.
          example: false
        display_quote_value:
          type: boolean
          description: Display the total quote value on the quote.
          example: true
        display_quote_value_with_tax:
          type: boolean
          description: Display the total quote value including tax on the quote.
          example: false
        display_taxes:
          type: boolean
          description: Display tax breakdown on the quote.
          example: true
        display_price_tiers:
          type: string
          enum:
            - all
            - matching
            - none
            - unit_price
          description: >
            Controls which price tiers are displayed on the quote.


            - `all`: Display all pricing tiers.

            - `matching`: Only display the tiers used to compute the price based
            on quantity.

            - `none`: Hide all pricing tiers.

            - `unit_price`: Show only the unit price, without tiers.
          example: matching
        display_phase_value:
          type: boolean
          description: Display per-phase value breakdown on the quote.
          example: false
        display_discounts_on_total:
          type: boolean
          description: >-
            Display discounts on the totals, with product prices before
            discount. Totals then follow the contract value, so discounts with a
            limited duration are included.
          example: false
        display_first_invoice_amount:
          type: boolean
          description: Display the first invoice amount on the quote.
          example: false
        display_documents_in_preview:
          type: boolean
          description: Display attached documents in the quote preview.
          example: false
        subscription_update_display:
          type: string
          enum:
            - quote_update_details
            - subscription_details
            - both
          description: >-
            Sections displayed on subscription update quotes:
            quote_update_details, subscription_details, or both. Takes
            precedence over display_subscription_on_update.
          example: quote_update_details
        post_signature_activation_enabled:
          type: boolean
          description: >-
            Whether the subscription is automatically orchestrated after the
            quote is signed. Only applies to the Hyperline CPQ-only product.
          example: true
        generate_draft_invoices:
          type: boolean
          description: >-
            When `true`, the invoice issued after signature stays in `draft`
            status instead of being emitted for payment. Use this when you want
            to review the final invoice manually before sending it. Defaults to
            `false`.
          example: false
        attachments:
          type: array
          items:
            $ref: '#/components/schemas/QuoteFile'
          description: List of documents attached to the quote.
          example:
            - id: quof_5GYXy8P3QCdaXh
              name: General Conditions of Sale
              mimetype: application/pdf
        signed_file:
          allOf:
            - $ref: '#/components/schemas/QuoteFile'
            - type:
                - object
                - 'null'
              description: Final signed quote (manually uploaded).
              example: null
        url:
          type:
            - string
            - 'null'
          format: uri
          description: >-
            URL to access the quote publicly. Only applies to the
            `pending_signature` or `signed` quote.
          example: https://billing.hyperline.co/quote/quo_hXQCd5y8P3GYXa
        created_at:
          type: string
          format: date-time
          description: >-
            Quote creation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T09:10:00.220Z'
        updated_at:
          type: string
          format: date-time
          description: >-
            Quote update date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T10:22:08.100Z'
        expires_at:
          type: string
          format: date-time
          description: >-
            Quote expiration date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-28T14:12:09.293Z'
        approved_at:
          type: string
          format: date-time
          description: >-
            Quote approbation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-24T09:10:00.220Z'
        subscription_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].subscription_id`.
        invoice_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].invoice_id`.
        child_subscription_ids:
          type: array
          items:
            type: string
          deprecated: true
          description: >-
            Deprecated field, please use `GET /v2/subscriptions` with the
            `original_quote_id` filter.
        display_subscription_on_update:
          type: boolean
          deprecated: true
          description: >-
            Deprecated. Use subscription_update_display. False displays quote
            update details; true displays both sections.
          example: false
      required:
        - id
        - type
        - status
        - amount
        - customer_id
        - invoicing_entity_id
        - configurations
        - template_id
        - crm_opportunity_id
        - custom_properties
        - contract_value
        - number
        - comments
        - terms
        - owner_email
        - collect_payment_details
        - collect_custom_property_ids
        - require_tax_id
        - display_quote_value
        - display_quote_value_with_tax
        - display_taxes
        - display_price_tiers
        - display_phase_value
        - display_discounts_on_total
        - display_first_invoice_amount
        - display_documents_in_preview
        - subscription_update_display
        - post_signature_activation_enabled
        - generate_draft_invoices
        - attachments
        - signed_file
        - url
        - created_at
        - updated_at
        - expires_at
        - approved_at
        - subscription_id
        - display_subscription_on_update
      title: Ready for signature
    QuoteSigned:
      type: object
      properties:
        id:
          type: string
          description: Quote ID.
          example: quo_hXQCd5y8P3GYXa
        type:
          type:
            - string
            - 'null'
          enum:
            - subscription
            - subscription_update
            - one_off
            - mixed
          description: >

            Quote type.


            - `subscription`: The quote will create one or more subscriptions.

            - `subscription_update`: The quote will update one or more existing
            subscriptions.

            - `one_off`: The quote will issue one or more one-off invoices.

            - `mixed`: Mixed configuration types.

            - `null`: Empty quote.
        status:
          type: string
          enum:
            - signed
          description: >

            Quote status.


            - `draft`: The quote is a draft.

            - `pending_approval`: The quote is pending manager review and
            approval.

            - `changes_requested`: Some changes have been requested following
            manager review.

            - `approved`: The quote is approved and ready to be sent to the
            customer.

            - `pending_signature`: The quote is awaiting the customer's
            signature.

            - `signed`: The quote is signed and fully finalized.

            - `voided`: The quote is voided.
          example: signed
        amount:
          type: number
          description: >-
            Estimated contract value. When computed, a subscription phase with
            neither an end date nor a fixed duration is counted over a
            conventional horizon: the contract's length for a single phase on a
            contract that has one, otherwise 12 months or the longest billing
            interval if longer. That horizon is not an end date: the
            subscription can run past it. Usage-based and connected seat lines
            are priced at their estimated quantity when it exceeds the committed
            quantity and, for seats, the live seat count.
          example: 20000
        customer_id:
          type: string
          description: ID of the customer the quote is addressed to.
          example: cus_QalW2vTAdkR6IY
        invoicing_entity_id:
          type: string
          description: ID of the invoicing entity attached to the quote.
          example: ive_47484fjdhy5
        configurations:
          type: array
          items:
            $ref: '#/components/schemas/QuoteConfiguration'
          description: Ordered configurations included in the quote.
        template_id:
          type:
            - string
            - 'null'
          description: ID of the quote template the quote is built from.
          example: quot_9hNWq4c84Z146W
        crm_opportunity_id:
          type:
            - string
            - 'null'
          description: ID of the related opportunity/deal in the connected CRM.
          example: opp_Z2oSqnBCUoo1bQ
        custom_properties:
          type:
            - object
            - 'null'
          additionalProperties:
            anyOf:
              - type: string
              - type: number
              - type: boolean
              - type: string
                format: date-time
                description: >-
                  UTC date time string in the [ISO
                  8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                example: '2024-12-20T16:04:11Z'
              - type: array
                items:
                  type: string
              - type: 'null'
          description: >-
            Custom property values set on the quote itself, keyed by slug.
            Custom property values of a quote's subscription are returned on the
            subscription.
        contract_value:
          type:
            - number
            - 'null'
          description: >-
            What the customer pays over the contract, each coupon counted on the
            invoices it applies to. Computed from the subscription for
            `subscription` and `subscription_update` quotes, unless set
            manually. Not set on `one_off` quotes.
          example: 18000
        number:
          type: string
          description: Quote sequential number.
          example: '327'
        comments:
          type:
            - string
            - 'null'
          description: Custom comments displayed on the quote.
          example: Please find the contract and subscription details we discussed.
        terms:
          type:
            - string
            - 'null'
          description: Custom quotation terms.
          example: >-
            By signing this quote, you accept our conditions of use for the use
            of our products and services.
        owner_email:
          type:
            - string
            - 'null'
          format: email
          description: >-
            Email address of the Hyperline user acting as the quote owner. The
            user must be a member of your Hyperline account. The owner requests
            approval when the quote is finalized using an API key or finalized
            during creation.
          example: joe@acme.com
        collect_payment_details:
          type: boolean
          description: >-
            Collect customer payment method mandate during signature flow or
            not.
          example: true
        collect_custom_property_ids:
          type: array
          items:
            type: string
          description: >-
            IDs of the customer custom properties required to be filled during
            the signature flow.
          example: []
        require_tax_id:
          type: boolean
          description: Require the customer to provide a tax ID during the signature flow.
          example: false
        display_quote_value:
          type: boolean
          description: Display the total quote value on the quote.
          example: true
        display_quote_value_with_tax:
          type: boolean
          description: Display the total quote value including tax on the quote.
          example: false
        display_taxes:
          type: boolean
          description: Display tax breakdown on the quote.
          example: true
        display_price_tiers:
          type: string
          enum:
            - all
            - matching
            - none
            - unit_price
          description: >
            Controls which price tiers are displayed on the quote.


            - `all`: Display all pricing tiers.

            - `matching`: Only display the tiers used to compute the price based
            on quantity.

            - `none`: Hide all pricing tiers.

            - `unit_price`: Show only the unit price, without tiers.
          example: matching
        display_phase_value:
          type: boolean
          description: Display per-phase value breakdown on the quote.
          example: false
        display_discounts_on_total:
          type: boolean
          description: >-
            Display discounts on the totals, with product prices before
            discount. Totals then follow the contract value, so discounts with a
            limited duration are included.
          example: false
        display_first_invoice_amount:
          type: boolean
          description: Display the first invoice amount on the quote.
          example: false
        display_documents_in_preview:
          type: boolean
          description: Display attached documents in the quote preview.
          example: false
        subscription_update_display:
          type: string
          enum:
            - quote_update_details
            - subscription_details
            - both
          description: >-
            Sections displayed on subscription update quotes:
            quote_update_details, subscription_details, or both. Takes
            precedence over display_subscription_on_update.
          example: quote_update_details
        post_signature_activation_enabled:
          type: boolean
          description: >-
            Whether the subscription is automatically orchestrated after the
            quote is signed. Only applies to the Hyperline CPQ-only product.
          example: true
        generate_draft_invoices:
          type: boolean
          description: >-
            When `true`, the invoice issued after signature stays in `draft`
            status instead of being emitted for payment. Use this when you want
            to review the final invoice manually before sending it. Defaults to
            `false`.
          example: false
        attachments:
          type: array
          items:
            $ref: '#/components/schemas/QuoteFile'
          description: List of documents attached to the quote.
          example:
            - id: quof_5GYXy8P3QCdaXh
              name: General Conditions of Sale
              mimetype: application/pdf
        signed_file:
          allOf:
            - $ref: '#/components/schemas/QuoteFile'
            - type:
                - object
                - 'null'
              description: Final signed quote (manually uploaded).
              example: null
        url:
          type:
            - string
            - 'null'
          format: uri
          description: >-
            URL to access the quote publicly. Only applies to the
            `pending_signature` or `signed` quote.
          example: https://billing.hyperline.co/quote/quo_hXQCd5y8P3GYXa
        created_at:
          type: string
          format: date-time
          description: >-
            Quote creation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T09:10:00.220Z'
        updated_at:
          type: string
          format: date-time
          description: >-
            Quote update date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T10:22:08.100Z'
        expires_at:
          type: string
          format: date-time
          description: >-
            Quote expiration date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-28T14:12:09.293Z'
        approved_at:
          type: string
          format: date-time
          description: >-
            Quote approbation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-24T09:10:00.220Z'
        signature:
          oneOf:
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - basic
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: basic
                signerName:
                  type: string
                  description: Signer name of the quote.
                  example: Acme
              required:
                - mode
                - signerName
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - electronic
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: electronic
                signerName:
                  type: string
                  description: Signer name of the quote.
                  example: Acme
              required:
                - mode
                - signerName
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - external
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: external
              required:
                - mode
          description: Quote signature. Only applies to the `signed` quote.
          example:
            mode: basic
            signerName: Acme
        signed_at:
          type: string
          format: date-time
          description: Quote signature date. Only applies to the `signed` quote.
          example: '2024-04-25T12:22:08.100Z'
        subscription_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].subscription_id`.
        invoice_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].invoice_id`.
        child_subscription_ids:
          type: array
          items:
            type: string
          deprecated: true
          description: >-
            Deprecated field, please use `GET /v2/subscriptions` with the
            `original_quote_id` filter.
        display_subscription_on_update:
          type: boolean
          deprecated: true
          description: >-
            Deprecated. Use subscription_update_display. False displays quote
            update details; true displays both sections.
          example: false
      required:
        - id
        - type
        - status
        - amount
        - customer_id
        - invoicing_entity_id
        - configurations
        - template_id
        - crm_opportunity_id
        - custom_properties
        - contract_value
        - number
        - comments
        - terms
        - owner_email
        - collect_payment_details
        - collect_custom_property_ids
        - require_tax_id
        - display_quote_value
        - display_quote_value_with_tax
        - display_taxes
        - display_price_tiers
        - display_phase_value
        - display_discounts_on_total
        - display_first_invoice_amount
        - display_documents_in_preview
        - subscription_update_display
        - post_signature_activation_enabled
        - generate_draft_invoices
        - attachments
        - signed_file
        - url
        - created_at
        - updated_at
        - expires_at
        - approved_at
        - signature
        - signed_at
        - subscription_id
        - display_subscription_on_update
      title: Signed
    QuoteVoided:
      type: object
      properties:
        id:
          type: string
          description: Quote ID.
          example: quo_hXQCd5y8P3GYXa
        type:
          type:
            - string
            - 'null'
          enum:
            - subscription
            - subscription_update
            - one_off
            - mixed
          description: >

            Quote type.


            - `subscription`: The quote will create one or more subscriptions.

            - `subscription_update`: The quote will update one or more existing
            subscriptions.

            - `one_off`: The quote will issue one or more one-off invoices.

            - `mixed`: Mixed configuration types.

            - `null`: Empty quote.
        status:
          type: string
          enum:
            - voided
          description: >

            Quote status.


            - `draft`: The quote is a draft.

            - `pending_approval`: The quote is pending manager review and
            approval.

            - `changes_requested`: Some changes have been requested following
            manager review.

            - `approved`: The quote is approved and ready to be sent to the
            customer.

            - `pending_signature`: The quote is awaiting the customer's
            signature.

            - `signed`: The quote is signed and fully finalized.

            - `voided`: The quote is voided.
          example: voided
        amount:
          type:
            - number
            - 'null'
          description: >-
            Estimated contract value. When computed, a subscription phase with
            neither an end date nor a fixed duration is counted over a
            conventional horizon: the contract's length for a single phase on a
            contract that has one, otherwise 12 months or the longest billing
            interval if longer. That horizon is not an end date: the
            subscription can run past it. Usage-based and connected seat lines
            are priced at their estimated quantity when it exceeds the committed
            quantity and, for seats, the live seat count.
          example: 20000
        customer_id:
          type: string
          description: ID of the customer the quote is addressed to.
          example: cus_QalW2vTAdkR6IY
        invoicing_entity_id:
          type: string
          description: ID of the invoicing entity attached to the quote.
          example: ive_47484fjdhy5
        configurations:
          type: array
          items:
            $ref: '#/components/schemas/QuoteConfiguration'
          description: Ordered configurations included in the quote.
        template_id:
          type:
            - string
            - 'null'
          description: ID of the quote template the quote is built from.
          example: quot_9hNWq4c84Z146W
        crm_opportunity_id:
          type:
            - string
            - 'null'
          description: ID of the related opportunity/deal in the connected CRM.
          example: opp_Z2oSqnBCUoo1bQ
        custom_properties:
          type:
            - object
            - 'null'
          additionalProperties:
            anyOf:
              - type: string
              - type: number
              - type: boolean
              - type: string
                format: date-time
                description: >-
                  UTC date time string in the [ISO
                  8601](https://en.wikipedia.org/wiki/ISO_8601) format.
                example: '2024-12-20T16:04:11Z'
              - type: array
                items:
                  type: string
              - type: 'null'
          description: >-
            Custom property values set on the quote itself, keyed by slug.
            Custom property values of a quote's subscription are returned on the
            subscription.
        contract_value:
          type:
            - number
            - 'null'
          description: >-
            What the customer pays over the contract, each coupon counted on the
            invoices it applies to. Computed from the subscription for
            `subscription` and `subscription_update` quotes, unless set
            manually. Not set on `one_off` quotes.
          example: 18000
        number:
          type: string
          description: Quote sequential number.
          example: '327'
        comments:
          type:
            - string
            - 'null'
          description: Custom comments displayed on the quote.
          example: Please find the contract and subscription details we discussed.
        terms:
          type:
            - string
            - 'null'
          description: Custom quotation terms.
          example: >-
            By signing this quote, you accept our conditions of use for the use
            of our products and services.
        owner_email:
          type:
            - string
            - 'null'
          format: email
          description: >-
            Email address of the Hyperline user acting as the quote owner. The
            user must be a member of your Hyperline account. The owner requests
            approval when the quote is finalized using an API key or finalized
            during creation.
          example: joe@acme.com
        collect_payment_details:
          type: boolean
          description: >-
            Collect customer payment method mandate during signature flow or
            not.
          example: true
        collect_custom_property_ids:
          type: array
          items:
            type: string
          description: >-
            IDs of the customer custom properties required to be filled during
            the signature flow.
          example: []
        require_tax_id:
          type: boolean
          description: Require the customer to provide a tax ID during the signature flow.
          example: false
        display_quote_value:
          type: boolean
          description: Display the total quote value on the quote.
          example: true
        display_quote_value_with_tax:
          type: boolean
          description: Display the total quote value including tax on the quote.
          example: false
        display_taxes:
          type: boolean
          description: Display tax breakdown on the quote.
          example: true
        display_price_tiers:
          type: string
          enum:
            - all
            - matching
            - none
            - unit_price
          description: >
            Controls which price tiers are displayed on the quote.


            - `all`: Display all pricing tiers.

            - `matching`: Only display the tiers used to compute the price based
            on quantity.

            - `none`: Hide all pricing tiers.

            - `unit_price`: Show only the unit price, without tiers.
          example: matching
        display_phase_value:
          type: boolean
          description: Display per-phase value breakdown on the quote.
          example: false
        display_discounts_on_total:
          type: boolean
          description: >-
            Display discounts on the totals, with product prices before
            discount. Totals then follow the contract value, so discounts with a
            limited duration are included.
          example: false
        display_first_invoice_amount:
          type: boolean
          description: Display the first invoice amount on the quote.
          example: false
        display_documents_in_preview:
          type: boolean
          description: Display attached documents in the quote preview.
          example: false
        subscription_update_display:
          type: string
          enum:
            - quote_update_details
            - subscription_details
            - both
          description: >-
            Sections displayed on subscription update quotes:
            quote_update_details, subscription_details, or both. Takes
            precedence over display_subscription_on_update.
          example: quote_update_details
        post_signature_activation_enabled:
          type: boolean
          description: >-
            Whether the subscription is automatically orchestrated after the
            quote is signed. Only applies to the Hyperline CPQ-only product.
          example: true
        generate_draft_invoices:
          type: boolean
          description: >-
            When `true`, the invoice issued after signature stays in `draft`
            status instead of being emitted for payment. Use this when you want
            to review the final invoice manually before sending it. Defaults to
            `false`.
          example: false
        attachments:
          type: array
          items:
            $ref: '#/components/schemas/QuoteFile'
          description: List of documents attached to the quote.
          example:
            - id: quof_5GYXy8P3QCdaXh
              name: General Conditions of Sale
              mimetype: application/pdf
        signed_file:
          allOf:
            - $ref: '#/components/schemas/QuoteFile'
            - type:
                - object
                - 'null'
              description: Final signed quote (manually uploaded).
              example: null
        url:
          type:
            - string
            - 'null'
          format: uri
          description: >-
            URL to access the quote publicly. Only applies to the
            `pending_signature` or `signed` quote.
          example: https://billing.hyperline.co/quote/quo_hXQCd5y8P3GYXa
        created_at:
          type: string
          format: date-time
          description: >-
            Quote creation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T09:10:00.220Z'
        updated_at:
          type: string
          format: date-time
          description: >-
            Quote update date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-23T10:22:08.100Z'
        void_reason:
          type: string
          description: Quote voiding reason. Only applies to the `voided` quote.
          example: The customer is ultimately not interested.
        voided_at:
          type: string
          format: date-time
          description: Quote voiding date. Only applies to the `voided` quote.
          example: '2024-04-26T12:00:01.320Z'
        expires_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            Quote expiration date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: null
        approved_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            Quote approbation date. UTC date time string in the [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) format.
          example: '2024-04-24T09:10:00.220Z'
        signature:
          anyOf:
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - basic
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: basic
              required:
                - mode
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - electronic
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: electronic
              required:
                - mode
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - external
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: external
              required:
                - mode
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - basic
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: basic
                signerName:
                  type: string
                  description: Signer name of the quote.
                  example: Acme
              required:
                - mode
                - signerName
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - electronic
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: electronic
                signerName:
                  type: string
                  description: Signer name of the quote.
                  example: Acme
              required:
                - mode
                - signerName
            - type: object
              properties:
                mode:
                  type: string
                  enum:
                    - external
                  description: >

                    Signature mode.


                    - `basic`: Basic signature. The signer manually put his
                    name. No legal value.

                    - `electronic`: Certified electronic signature. Legally
                    compliant.

                    - `external`: Signed outside of Hyperline. A signed file has
                    been uploaded.
                  example: external
              required:
                - mode
            - type: 'null'
          description: Quote signature. Only applies to the `signed` quote.
          example:
            mode: basic
            signerName: Acme
        signed_at:
          type:
            - string
            - 'null'
          format: date-time
          description: Quote signature date. Only applies to the `signed` quote.
          example: '2024-04-25T12:22:08.100Z'
        subscription_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].subscription_id`.
        invoice_id:
          type:
            - string
            - 'null'
          deprecated: true
          description: Deprecated field, please use `configurations[].invoice_id`.
        child_subscription_ids:
          type: array
          items:
            type: string
          deprecated: true
          description: >-
            Deprecated field, please use `GET /v2/subscriptions` with the
            `original_quote_id` filter.
        display_subscription_on_update:
          type: boolean
          deprecated: true
          description: >-
            Deprecated. Use subscription_update_display. False displays quote
            update details; true displays both sections.
          example: false
      required:
        - id
        - type
        - status
        - amount
        - customer_id
        - invoicing_entity_id
        - configurations
        - template_id
        - crm_opportunity_id
        - custom_properties
        - contract_value
        - number
        - comments
        - terms
        - owner_email
        - collect_payment_details
        - collect_custom_property_ids
        - require_tax_id
        - display_quote_value
        - display_quote_value_with_tax
        - display_taxes
        - display_price_tiers
        - display_phase_value
        - display_discounts_on_total
        - display_first_invoice_amount
        - display_documents_in_preview
        - subscription_update_display
        - post_signature_activation_enabled
        - generate_draft_invoices
        - attachments
        - signed_file
        - url
        - created_at
        - updated_at
        - void_reason
        - voided_at
        - expires_at
        - approved_at
        - signature
        - signed_at
        - subscription_id
        - display_subscription_on_update
      title: Voided
    QuoteConfiguration:
      oneOf:
        - $ref: '#/components/schemas/QuoteSubscriptionConfiguration'
        - $ref: '#/components/schemas/QuoteInvoiceConfiguration'
      discriminator:
        propertyName: type
        mapping:
          subscription: '#/components/schemas/QuoteSubscriptionConfiguration'
          subscription_update: '#/components/schemas/QuoteSubscriptionConfiguration'
          one_off: '#/components/schemas/QuoteInvoiceConfiguration'
    QuoteFile:
      type: object
      properties:
        id:
          type: string
          description: Quote file ID.
        name:
          type: string
          description: Quote file name.
        mimetype:
          type: string
          description: Quote file MIME type.
      required:
        - id
        - name
        - mimetype
    QuoteSubscriptionConfiguration:
      type: object
      properties:
        id:
          type: string
          description: Quote configuration ID.
        customer_id:
          type:
            - string
            - 'null'
          description: >-
            ID of the child customer the configuration applies to, or null to
            use the quote customer.
        position:
          type: integer
          description: Configuration order within the quote, starting at zero.
        amount:
          type:
            - number
            - 'null'
          description: Configuration amount excluding tax, in minor currency units.
        applied_at:
          type:
            - string
            - 'null'
          format: date-time
          description: When the post-signature action completed, or null if not applied.
          example: '2024-12-20T16:04:11Z'
        type:
          type: string
          enum:
            - subscription
            - subscription_update
          description: Configuration type.
        subscription_id:
          type:
            - string
            - 'null'
          description: ID of the configuration's subscription, or null if not configured.
        contract_terms:
          type:
            - object
            - 'null'
          properties:
            status:
              type: string
              enum:
                - active
                - pending
                - finished
              description: >

                Contract status.


                - `active`: The contract is active.

                - `pending`: The contract is pending. It will be activated
                according to the activation strategy.

                - `finished`: The contract has ended.
              example: active
            activation_strategy:
              type: string
              enum:
                - start_date
                - immediately
                - manual
                - quote_signature
                - checkout
              description: >

                Activation strategy of the contract.


                - `immediately`: The contract will be activated immediately.

                - `manual`: The contract will be activated when a user manually
                activates it.

                - `start_date`: The contract will be activated on a specified
                date.

                - `quote_signature`: The contract will be activated when the
                subscription quote is signed.

                - `checkout`: The contract will be activated when the
                subscription checkout is completed.
              example: start_date
            end_strategy:
              type: string
              enum:
                - end_date
                - duration
                - manual
              description: >

                End strategy of contract.


                - `manual`: The contract ends when a user manually stops it.

                - `end_date`: The contract ends on a specified date.

                - `duration`: The contract ends after a specific relative
                duration, unless `renew_automatically` is true.
              example: duration
            starts_at:
              type:
                - string
                - 'null'
              format: date-time
              description: >-
                Start date of the contract. UTC date time string in the [ISO
                8601](https://en.wikipedia.org/wiki/ISO_8601) format.
              example: '2024-12-31T23:00:00.000Z'
            ends_at:
              type:
                - string
                - 'null'
              format: date-time
              description: >-
                End date of the contract. UTC date time string in the [ISO
                8601](https://en.wikipedia.org/wiki/ISO_8601) format.
              example: '2025-06-30T21:59:59.999Z'
            duration:
              type:
                - object
                - 'null'
              properties:
                period:
                  type: string
                  enum:
                    - days
                    - weeks
                    - months
                    - years
                count:
                  type: number
                  exclusiveMinimum: 0
              required:
                - period
                - count
              description: >-
                Interval over which the contract initially spans. Only applies
                to `duration` end strategy.
              example:
                count: 6
                period: months
            renew_automatically:
              anyOf:
                - type: boolean
                - type: string
                  enum:
                    - 'true'
                    - 'false'
              description: |

                Indicates if the contract should be renewed automatically.

                - `true`: The contract will be renewed automatically.
                - `false`: The contract will not be renewed automatically.
              example: true
            renew_for_duration:
              type:
                - object
                - 'null'
              properties:
                period:
                  type: string
                  enum:
                    - days
                    - weeks
                    - months
                    - years
                count:
                  type: number
                  exclusiveMinimum: 0
              required:
                - period
                - count
              description: >

                Interval over which the contract will be renewed. Only applies
                if `renew_automatically` is true.
              example:
                count: 1
                period: years
            price_adjustment:
              oneOf:
                - $ref: '#/components/schemas/ContractTermsRenewalPriceAdjustment'
                - $ref: '#/components/schemas/ContractTermsDurationPriceAdjustment'
                - type: 'null'
              description: >-
                Price adjustment applied to the subscription prices over the
                contract. `null` if the contract has no price adjustment.
              example:
                frequency: renewal
                percent: 7
            current_period_started_at:
              type:
                - string
                - 'null'
              format: date-time
              description: >-
                Start date of the current contract period. UTC date time string
                in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
                format.
              example: '2025-06-30T22:00:00.000Z'
            current_period_ends_at:
              type:
                - string
                - 'null'
              format: date-time
              description: >-
                End date of the current contract period. UTC date time string in
                the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
              example: '2026-06-30T21:59:59.999Z'
          required:
            - status
            - activation_strategy
            - end_strategy
            - starts_at
            - ends_at
            - duration
            - renew_automatically
            - renew_for_duration
            - price_adjustment
            - current_period_started_at
            - current_period_ends_at
          description: >-
            Contract terms (start, duration, renewal) of the configuration's
            subscription, or null when it has no custom contract. On a
            `subscription_update` configuration, these are the terms the quote
            proposes, read from its draft copy of the subscription: `status` is
            the amended contract's status when the quote was created, and
            `current_period_started_at` and `current_period_ends_at` are null
            (read them on the subscription).
        estimates:
          type: array
          items:
            $ref: '#/components/schemas/QuoteProductEstimate'
          description: >-
            Estimated quantities declared on the quote for its usage-based and
            connected seat lines of the configuration. They price the quote
            value and are never billed. Once the quote is signed (a subscription
            update quote: once applied) they are frozen with their periods and
            amounts, as the record of what the quote sold.
      required:
        - id
        - customer_id
        - position
        - amount
        - applied_at
        - type
        - subscription_id
        - contract_terms
        - estimates
      title: Subscription or update
    QuoteInvoiceConfiguration:
      type: object
      properties:
        id:
          type: string
          description: Quote configuration ID.
        customer_id:
          type:
            - string
            - 'null'
          description: >-
            ID of the child customer the configuration applies to, or null to
            use the quote customer.
        position:
          type: integer
          description: Configuration order within the quote, starting at zero.
        amount:
          type:
            - number
            - 'null'
          description: Configuration amount excluding tax, in minor currency units.
        applied_at:
          type:
            - string
            - 'null'
          format: date-time
          description: When the post-signature action completed, or null if not applied.
          example: '2024-12-20T16:04:11Z'
        type:
          type: string
          enum:
            - one_off
          description: Configuration type.
        invoice_id:
          type:
            - string
            - 'null'
          description: ID of the configuration's draft invoice, or null if not configured.
      required:
        - id
        - customer_id
        - position
        - amount
        - applied_at
        - type
        - invoice_id
      title: One-off invoice
    ContractTermsRenewalPriceAdjustment:
      type: object
      properties:
        frequency:
          type: string
          enum:
            - renewal
          description: |

            When the price adjustment is applied.

            - `renewal`: At each contract renewal.
            - `duration`: Every `interval`, during the contract.
        percent:
          type: number
          description: >-
            Percentage applied to the prices each time the adjustment applies
            (e.g. `7` for +7%, `-5` for -5%).
          example: 7
      required:
        - frequency
        - percent
      additionalProperties: false
      title: Renewal
    ContractTermsDurationPriceAdjustment:
      type: object
      properties:
        frequency:
          type: string
          enum:
            - duration
          description: |

            When the price adjustment is applied.

            - `renewal`: At each contract renewal.
            - `duration`: Every `interval`, during the contract.
        percent:
          type: number
          description: >-
            Percentage applied to the prices each time the adjustment applies
            (e.g. `7` for +7%, `-5` for -5%).
          example: 7
        interval:
          type: object
          properties:
            period:
              type: string
              enum:
                - days
                - weeks
                - months
                - years
            count:
              type: number
              exclusiveMinimum: 0
          required:
            - period
            - count
          description: Interval between two price adjustments.
          example:
            count: 1
            period: years
      required:
        - frequency
        - percent
        - interval
      additionalProperties: false
      title: Duration
    QuoteProductEstimate:
      type: object
      properties:
        product_id:
          type: string
          description: ID of the estimated product in the catalog.
          example: itm_3kXODIM1sBwBbJ
        price_configuration_id:
          type:
            - string
            - 'null'
          description: >-
            ID of the catalog price configuration the line was priced from, if
            any.
          example: prc_8f3kXODIM1sBwB
        phase_order:
          type: integer
          description: Order of the quote phase holding the estimated line.
          example: 0
        period_start:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            Start of the period the estimate was sold for: its phase's start, or
            for a first phase starting only once the subscription does
            (signature, checkout, payment, a manual start) the contract's start,
            else the subscription's, else the signature date. For a subscription
            update quote, its first updated phase starts at the update's
            effective date. Null until the quote is signed, and for a phase
            starting after one that ends manually.
          example: '2026-01-01T00:00:00.000Z'
        period_end:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            End of the period the estimate was sold for: its phase's end (the
            contract's end for a phase ending with it), else, for an open-ended
            phase, the horizon the quote value counts: the contract's length for
            a single phase on a contract that has one, otherwise 12 months or
            the longest billing interval if longer. That horizon is a
            convention, not an end date: an open-ended subscription can run past
            it. Null when `period_start` is.
          example: '2026-12-31T23:59:59.999Z'
        estimated_count:
          type: number
          description: Estimated number of units per billing period.
          example: 200
        estimated_amount:
          type:
            - number
            - 'null'
          description: >-
            Amount of one billing period of the line (its billing interval)
            priced at the estimate: the first one, excluding taxes, with its
            discounts applied. Null when the estimate doesn't raise the price,
            and until the quote is signed.
          example: 2000
        estimated_total_amount:
          type:
            - number
            - 'null'
          description: >-
            What the line bills at the estimate over every billing period
            between `period_start` and `period_end`, excluding taxes, each
            period with the discounts applying to it. It can differ from the
            quote value, which counts a phase without dates over its own
            horizon. Null when `estimated_amount` or `period_start` is. The
            frozen record never follows later changes to the subscription: when
            several update quotes cover the same line and period, the latest
            signed one is the current estimate, which `GET
            /v1/subscriptions/{id}/estimates` resolves.
          example: 24000
      required:
        - product_id
        - price_configuration_id
        - phase_order
        - period_start
        - period_end
        - estimated_count
        - estimated_amount
        - estimated_total_amount
  securitySchemes:
    bearer:
      type: http
      scheme: bearer
      bearerFormat: JWT

````

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