ChargebeeAPI

Sales orders

Sales orders represent the contractual agreement and commitment for services between a seller and a buyer. They act as a seamless interface connecting any sales system (such as CPQ, CRM, or Customer Portal) with Chargebee Billing. The sales order captures the following essential components

  • Order Line Items including discounts and ramps
  • Billing and payment configuration
  • Contract terms and conditions
  • Customer information including billing and shipping contacts
  • Meta data

Sample Sales orderJSON

Sales orders attributes

id
required, string, max chars=50

External identifier of the sales order.

version
required, integer, default=1

Version of the sales order.

renewed_from_order_id
optional, string, max chars=50

The unique identifier of the original sales order from which this order was renewed. This field is used to track renewal orders and link them to their previous sales transactions.

updated_at
optional, timestamp(UTC) in seconds

Indicates the timestamp at which this sales order was last updated.

created_at
required, timestamp(UTC) in seconds

Timestamp indicating sales order created.

po_number
optional, string, max chars=100

Buyer's purchase order reference number.

meta_data
optional, string, max chars=65k

A set of key-value pairs stored as additional information for the subscription. Learn more .

quote_id
optional, string, max chars=100

Primary quote id for which the order was placed.

effective_date
required, timestamp(UTC) in seconds

Effective start date of the order signifies when the contract is signed and becomes legally binding.

end_date
optional, timestamp(UTC) in seconds

The date when the order is considered completed, cancelled, or no longer valid.

business_entity_id
optional, string, max chars=50

The unique ID of the business entity of this sales order.

customer_id
required, string, max chars=50

The unique ID of the customer to which this sales order belongs.

subscription_id
required, string, max chars=50
currency_code
required, string, max chars=3

The currency code (ISO 4217 format) of the sales order.

subscription_ids
optional, string

The unique identifiers of the subscriptions that are bundled as part of this sales order.

status
required, enumerated string, default=active

Status of the sales order.

Possible Enum Values
active

active

completed

completed

deleted
required, boolean
line_items
optional, list of line_item

Line items of this sales order

billing_addresses
optional, list of billing_address

Billing address for a customer.

discounts
optional, list of discount

List of discounts for this subscription

shipping_addresses
optional, list of shipping_address

Shipping address for the subscription.

line_item_tiers
optional, list of line_item_tier

The pricing details of line_items which have pricing_model as tiered , volume or stairstep. Learn more about pricing models.

payment_configuration
optional, payment_configuration

Payment configuration of this sales order

billing_configuration
optional, billing_configuration

Configurations controlling billing behavior and invoice generation workflows.

renewal_term
optional, renewal_term

Renewal term for this sales order.

credit_lines
optional, list of credit_line