API Version
Product Catalog
Library

Note: This doc is for the latest version of Chargebee Orders. If you enabled Chargebee Orders before September-30-2018, you may be using the legacy version of the feature and its API. For help in migrating to the current system or using the legacy API for Chargebee Orders, please contact support

Orders are automatically generated for an invoice when it gets paid, based on the shipping preference chosen for the invoice's product and the shipping date configuration. They can be updated either via api or merchant web console (a.k.a admin console).

Sample order [ JSON ]

{ "created_at": 1517678686, "created_by": "full_access_key_v1", "deleted": false, "id": "__test__KyVnHhSBWlm1j2m7", "invoice_id": "__demo_inv__2", "object": "order", "order_type": "manual", "price_type": "tax_exclusive", "status": "new", "status_update_at": 1517678686 }

API Index URL GET

https://{site}.chargebee.com/api/v2/orders

Model Class

id
string, max chars=40
Uniquely identifies the order. It is the api identifier for the order
document_number
optional, string, max chars=50
The order's serial number
invoice_id
optional, string, max chars=50
The invoice number which acts as an identifier for invoice and is generated sequentially.
subscription_id
optional, string, max chars=50
The subscription for which the order is created
customer_id
optional, string, max chars=50
The customer for which the order is created
status
optional, enumerated string, default=new
The status of this order.
Possible values are
newOrder has been created. Applicable only if you are using Chargebee's legacy order management system.processingOrder is being processed. Applicable only if you are using Chargebee's legacy order management systemcompleteOrder has been processed successfully. Applicable only if you are using Chargebee's legacy order management systemcancelledOrder has been cancelled. Applicable only if you are using Chargebee's legacy order management system
Show all values[+]
cancellation_reason
optional, enumerated string
Cancellation reason
Possible values are
shipping_cut_off_passedThe invoice has been paid late and Chargebee cancel's the first order for the invoice.product_unsatisfactoryProduct unsatisfactory.third_party_cancellationThird party cancellation.product_not_requiredProduct not required.
Show all values[+]
payment_status
optional, enumerated string
The payment status of the order
Possible values are
not_paidNOT_PAIDpaidPAID
Show all values[+]
order_type
optional, enumerated string
Order type
Possible values are
manualThe order has been created by the the user using Chargebee's legacy order management system.system_generatedThe order has been created by Chargebee automatically based on the preferences set by the user.
Show all values[+]
price_type
enumerated string, default=tax_exclusive
The price type of the order
Possible values are
tax_exclusiveAll amounts in the document are exclusive of tax.tax_inclusiveAll amounts in the document are inclusive of tax.
Show all values[+]
reference_id
optional, string, max chars=50
Reference id can be used to map the orders in the shipping/order management application to the orders in ChargeBee. The reference_id generally is same as the order id in the third party application.
fulfillment_status
optional, string, max chars=50
The fulfillment status of an order as reflected in the shipping/order management application. Typical statuses include Shipped,Awaiting Shipment,Not fulfilled etc;
order_date
optional, timestamp(UTC) in seconds
The date on which the order will start getting processed.
shipping_date
optional, timestamp(UTC) in seconds
This is the date on which the order will be delivered to the customer.
note
optional, string, max chars=600
The custom note for the order.
tracking_id
optional, string, max chars=50
The tracking id of the order.
tracking_url
optional, string, max chars=255
The tracking url of the order.
batch_id
optional, string, max chars=50
Unique id to identify a group of orders.
created_by
optional, string, max chars=50
The source (or the user) from where the order has been created.
shipment_carrier
optional, string, max chars=50
Shipment carrier
invoice_round_off_amount
optional, in cents, min=0
The total round off taken from the invoice level
tax
optional, in cents, min=0
The total tax for the order.
amount_paid
optional, in cents, min=0
Total amount paid for the order.
amount_adjusted
optional, in cents, min=0
Total amount adjusted for the order.
refundable_credits_issued
optional, in cents, min=0
The total amount issued as credits on behalf of this order.
refundable_credits
optional, in cents, min=0
The total amount that can be issued as credits for this order.
rounding_adjustement
optional, in cents
Rounding adjustment
paid_on
optional, timestamp(UTC) in seconds
The timestamp indicating the date & time the order's invoice got paid.
shipping_cut_off_date
optional, timestamp(UTC) in seconds
The time after which an order becomes unservicable
created_at
timestamp(UTC) in seconds
The time at which the order was created
status_update_at
optional, timestamp(UTC) in seconds
The time at which the order status was last updated.
delivered_at
optional, timestamp(UTC) in seconds
The time at which the order was delivered
shipped_at
optional, timestamp(UTC) in seconds
The time at which the order was shipped.
resource_version
optional, long
Version number of this resource. The resource_version is updated with a new timestamp in milliseconds for every change made to the resource. This attribute will be present only if the resource has been updated after 2016-09-28.
updated_at
optional, timestamp(UTC) in seconds
The order's last modified time.
cancelled_at
optional, timestamp(UTC) in seconds
The time at which the order was cancelled.
resent_status
optional, enumerated string
Resent status of the order.
Possible values are
fully_resentOrder is Fully resentpartially_resentOrder is Partially resent
Show all values[+]
is_resent
boolean, default=false
Show if the order is resent order or not.
original_order_id
optional, string, max chars=40
Refers to the original order id of the resent order.
discount
optional, in cents, min=0
Total discount given for the order.
sub_total
optional, in cents, min=0
The order's sub-total
total
optional, in cents, min=0
Total amount charged for the order.
deleted
boolean
Indicates that this resource has been deleted.
currency_code
optional, string, max chars=3
The currency code (ISO 4217 format) for the invoice
is_gifted
optional, boolean, default=false
Boolean indicating whether this order is gifted or not.
gift_note
optional, string, max chars=500
The gift message added by the gifter during purchase
gift_id
optional, string, max chars=50
The gift_id if the order is a gift order
resend_reason
optional, string, max chars=100
Reason code for resending the order. Must be one from a list of reason codes set in the Chargebee app in Settings > Configure Chargebee > Reason Codes > Orders > Order Resend. Must be passed if set as mandatory in the app. The codes are case-sensitive
business_entity_id
optional, string, max chars=50
The unique ID of the business entity of this subscription. This is always the same as the business entity of the customer.
order_line_items
Show attributes [+]
optional, list of order_line_item
The list of line items for this order.
shipping_address
Show attributes [+]
optional, shipping_address
Shipping address for the order.
billing_address
Show attributes [+]
optional, billing_address
Billing address for the order.
line_item_taxes
Show attributes [+]
optional, list of line_item_tax
The list of taxes applied on the order line items.
line_item_discounts
Show attributes [+]
optional, list of line_item_discount
The list of discounts applied for the order
linked_credit_notes
Show attributes [+]
optional, list of order_line_item_linked_credit
The credit notes linked to the order
resent_orders
Show attributes [+]
optional, list of resent_order
The list of resent orders applied on the order.
id id
string, max chars=40
Uniquely identifies the order. It is the api identifier for the order
document_number document_number
optional, string, max chars=50
The order's serial number
invoice_id invoice_id
optional, string, max chars=50
The invoice number which acts as an identifier for invoice and is generated sequentially.
subscription_id subscription_id
optional, string, max chars=50
The subscription for which the order is created
customer_id customer_id
optional, string, max chars=50
The customer for which the order is created
status status
optional, enumerated string, default=new
The status of this order.
cancellation_reason cancellation_reason
optional, enumerated string
Cancellation reason
payment_status payment_status
optional, enumerated string
The payment status of the order
order_type order_type
optional, enumerated string
Order type
price_type price_type
enumerated string, default=tax_exclusive
The price type of the order
reference_id reference_id
optional, string, max chars=50
Reference id can be used to map the orders in the shipping/order management application to the orders in ChargeBee. The reference_id generally is same as the order id in the third party application.
fulfillment_status fulfillment_status
optional, string, max chars=50
The fulfillment status of an order as reflected in the shipping/order management application. Typical statuses include Shipped,Awaiting Shipment,Not fulfilled etc;
order_date order_date
optional, timestamp(UTC) in seconds
The date on which the order will start getting processed.
shipping_date shipping_date
optional, timestamp(UTC) in seconds
This is the date on which the order will be delivered to the customer.
note note
optional, string, max chars=600
The custom note for the order.
tracking_id tracking_id
optional, string, max chars=50
The tracking id of the order.
tracking_url tracking_url
optional, string, max chars=255
The tracking url of the order.
batch_id batch_id
optional, string, max chars=50
Unique id to identify a group of orders.
created_by created_by
optional, string, max chars=50
The source (or the user) from where the order has been created.
shipment_carrier shipment_carrier
optional, string, max chars=50
Shipment carrier
invoice_round_off_amount invoice_round_off_amount
optional, in cents, min=0
The total round off taken from the invoice level
tax tax
optional, in cents, min=0
The total tax for the order.
amount_paid amount_paid
optional, in cents, min=0
Total amount paid for the order.
amount_adjusted amount_adjusted
optional, in cents, min=0
Total amount adjusted for the order.
refundable_credits_issued refundable_credits_issued
optional, in cents, min=0
The total amount issued as credits on behalf of this order.
refundable_credits refundable_credits
optional, in cents, min=0
The total amount that can be issued as credits for this order.
rounding_adjustement rounding_adjustement
optional, in cents
Rounding adjustment
paid_on
optional, timestamp(UTC) in seconds
The timestamp indicating the date & time the order's invoice got paid.
shipping_cut_off_date shipping_cut_off_date
optional, timestamp(UTC) in seconds
The time after which an order becomes unservicable
created_at created_at
timestamp(UTC) in seconds
The time at which the order was created
status_update_at status_update_at
optional, timestamp(UTC) in seconds
The time at which the order status was last updated.
delivered_at delivered_at
optional, timestamp(UTC) in seconds
The time at which the order was delivered
shipped_at shipped_at
optional, timestamp(UTC) in seconds
The time at which the order was shipped.
resource_version resource_version
optional, long
Version number of this resource. The resource_version is updated with a new timestamp in milliseconds for every change made to the resource. This attribute will be present only if the resource has been updated after 2016-09-28.
updated_at updated_at
optional, timestamp(UTC) in seconds
The order's last modified time.
cancelled_at cancelled_at
optional, timestamp(UTC) in seconds
The time at which the order was cancelled.
resent_status resent_status
optional, enumerated string
Resent status of the order.
is_resent is_resent
boolean, default=false
Show if the order is resent order or not.
original_order_id original_order_id
optional, string, max chars=40
Refers to the original order id of the resent order.
discount discount
optional, in cents, min=0
Total discount given for the order.
sub_total sub_total
optional, in cents, min=0
The order's sub-total
total total
optional, in cents, min=0
Total amount charged for the order.
deleted deleted
boolean
Indicates that this resource has been deleted.
currency_code currency_code
optional, string, max chars=3
The currency code (ISO 4217 format) for the invoice
is_gifted is_gifted
optional, boolean, default=false
Boolean indicating whether this order is gifted or not.
gift_note gift_note
optional, string, max chars=500
The gift message added by the gifter during purchase
gift_id gift_id
optional, string, max chars=50
The gift_id if the order is a gift order
resend_reason resend_reason
optional, string, max chars=100
Reason code for resending the order. Must be one from a list of reason codes set in the Chargebee app in Settings > Configure Chargebee > Reason Codes > Orders > Order Resend. Must be passed if set as mandatory in the app. The codes are case-sensitive
business_entity_id business_entity_id
optional, string, max chars=50
The unique ID of the business entity of this subscription. This is always the same as the business entity of the customer.
order_line_items
optional, list of order_line_item
The list of line items for this order.
shipping_address
optional, shipping_address
Shipping address for the order.
billing_address
optional, billing_address
Billing address for the order.
line_item_taxes
optional, list of line_item_tax
The list of taxes applied on the order line items.
line_item_discounts
optional, list of line_item_discount
The list of discounts applied for the order
linked_credit_notes
optional, list of order_line_item_linked_credit
The credit notes linked to the order
resent_orders
optional, list of resent_order
The list of resent orders applied on the order.

Deprecated

Chargebee no longer supports this endpoint, see here for more information. Contact Support for additional assistance or if you have concerns about this update.

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders \
     -u {site_api_key}:\
     -d invoice_id="__demo_inv__2"
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "created_at": 1517678686,
        "created_by": "full_access_key_v1",
        "deleted": false,
        "id": "__test__KyVnHhSBWlm1j2m7",
        "invoice_id": "__demo_inv__2",
        "object": "order",
        "order_type": "manual",
        "price_type": "tax_exclusive",
        "status": "new",
        "status_update_at": 1517678686
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders

Method

id[]
optional, string, max chars=40
Uniquely identifies the order. If not given, this will be auto-generated.
invoice_id[]
required, string, max chars=50
The invoice number which acts as an identifier for invoice and is generated sequentially.
status[]
optional, enumerated string
The order status.
Possible values are
newOrder has been created. Applicable only if you are using Chargebee's legacy order management system.processingOrder is being processed. Applicable only if you are using Chargebee's legacy order management systemcompleteOrder has been processed successfully. Applicable only if you are using Chargebee's legacy order management systemcancelledOrder has been cancelled. Applicable only if you are using Chargebee's legacy order management system
Show all values[+]
reference_id[]
optional, string, max chars=50
Reference id can be used to map the orders in the shipping/order management application to the orders in ChargeBee. The reference_id generally is same as the order id in the third party application.
fulfillment_status[]
optional, string, max chars=50
The fulfillment status of an order as reflected in the shipping/order management application. Typical statuses include Shipped,Awaiting Shipment,Not fulfilled etc;.
note[]
optional, string, max chars=600
The custom note for the order.
tracking_id[]
optional, string, max chars=50
The tracking id of the order.
tracking_url[]
optional, string, max chars=255
The tracking url of the order.
batch_id[]
optional, string, max chars=50
Unique id to identify a group of orders.
order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
Updates an order. If the status of an order is changed while updating the order, the status_update_at attribute is set with the current time.

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/1 \
     -u {site_api_key}:\
     -d status="DELIVERED" \
     -d shipped_at=1517073906 \
     -d delivered_at=1517678706
# updates the order shipping address.
curl  https://{site}.chargebee.com/api/v2/orders/__test__KyVnHhSBWlrq92oh \
     -u {site_api_key}:\
     -d shipping_address[first_name]="John" \
     -d shipping_address[last_name]="Doe" \
     -d shipping_address[email]="john@user.com" \
     -d shipping_address[line1]="PO Box 9999" \
     -d shipping_address[city]="Walnut" \
     -d shipping_address[state]="California" \
     -d shipping_address[zip]="91789" \
     -d shipping_address[country]="US"
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 40000,
        "base_currency_code": "USD",
        "created_at": 1517505909,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__KyVnHhSBWlr4r2o7",
        "deleted": false,
        "delivered_at": 1517678706,
        "discount": 0,
        "document_number": "1",
        "exchange_rate": 1,
        "id": "1",
        "invoice_id": "__demo_inv__1",
        "is_gifted": false,
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1517505907,
        "order_line_items": [
            {
                "amount": 40000,
                "amount_adjusted": 0,
                "amount_paid": 40000,
                "description": "MB1S1P",
                "discount_amount": 0,
                "entity_id": "MB1S1P",
                "entity_type": "plan",
                "fulfillment_amount": 40000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__KyVnGlSBWlrF727W",
                "invoice_id": "__demo_inv__1",
                "invoice_line_item_id": "li___test__KyVnHhSBWlr692o9",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 40000,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 40000
            },
            {..}
        ],
        "order_type": "system_generated",
        "paid_on": 1517505907,
        "payment_status": "paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 40000,
        "refundable_credits_issued": 0,
        "resource_version": 1517678706000,
        "rounding_adjustement": 0,
        "shipped_at": 1517073906,
        "shipping_date": 1517505907,
        "status": "delivered",
        "status_update_at": 1517678706,
        "sub_total": 40000,
        "subscription_id": "__test__KyVnHhSBWlr4r2o7",
        "tax": 0,
        "total": 40000,
        "updated_at": 1517678706
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/{order-id}

Method

reference_id[]
optional, string, max chars=50
Reference id is the unique identifier of the order in the shipping/order management application.
batch_id[]
optional, string, max chars=50
Unique id to identify a group of orders.
note[]
optional, string, max chars=600
The custom note for the order.
shipping_date[]
optional, timestamp(UTC) in seconds
The date on which the order should be shipped to the customer.
order_date[]
optional, timestamp(UTC) in seconds
The order date.
cancelled_at[]
optional, timestamp(UTC) in seconds
The time at which the order was cancelled.
cancellation_reason[]
optional, enumerated string
Cancellation reason.
Possible values are
shipping_cut_off_passedThe invoice has been paid late and Chargebee cancel's the first order for the invoice.product_unsatisfactoryProduct unsatisfactory.third_party_cancellationThird party cancellation.product_not_requiredProduct not required.
Show all values[+]
shipped_at[]
optional, timestamp(UTC) in seconds
The time at which the order was shipped.
delivered_at[]
optional, timestamp(UTC) in seconds
The time at which the order was delivered.
tracking_url[]
optional, string, max chars=255
The tracking url of the order.
tracking_id[]
optional, string, max chars=50
The tracking id of the order.
shipment_carrier[]
optional, string, max chars=50
The carrier used to ship the goods to the customer. Ex:- FedEx.
fulfillment_status[]
optional, string, max chars=50
The fulfillment status of an order as reflected in the shipping/order management application. Typical statuses include Shipped,Awaiting Shipment,Not fulfilled etc;.
status[]
optional, enumerated string, default=new
The order status.
Possible values are
newOrder has been created. Applicable only if you are using Chargebee's legacy order management system.processingOrder is being processed. Applicable only if you are using Chargebee's legacy order management systemcompleteOrder has been processed successfully. Applicable only if you are using Chargebee's legacy order management systemcancelledOrder has been cancelled. Applicable only if you are using Chargebee's legacy order management system
Show all values[+]
shipping_address[first_name]
optional, string, max chars=150
shipping_address[last_name]
optional, string, max chars=150
shipping_address[email]
optional, string, max chars=70
shipping_address[company]
optional, string, max chars=250
shipping_address[phone]
optional, string, max chars=50
shipping_address[line1]
optional, string, max chars=150
shipping_address[line2]
optional, string, max chars=150
shipping_address[line3]
optional, string, max chars=150
shipping_address[city]
optional, string, max chars=50
shipping_address[state_code]
optional, string, max chars=50
shipping_address[state]
optional, string, max chars=50
shipping_address[zip]
optional, string, max chars=20
shipping_address[country]
optional, string, max chars=50
shipping_address[validation_status]
optional, enumerated string, default=not_validated
Possible values are
not_validatedAddress is not yet validated.validAddress was validated successfully.partially_validThe address is valid for taxability but has not been validated for shipping.invalidAddress is invalid.
Show all values[+]
order_line_items[id][0..n]
optional, string, max chars=40
order_line_items[status][0..n]
optional, enumerated string, default=queued
Possible values are
queuedNot processed for shipping yet.awaiting_shipmentMoved to shipping platform.on_holdThe delivery has been moved to "On hold" status.deliveredThe order line item has been delivered.
Show all values[+]
order_line_items[sku][0..n]
optional, string, max chars=250
order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
Import an order for an invoice with one or more line items. The import order bulk operation is to be applied on an imported invoice.
This API is not enabled for live sites by default. Please contact support to get this enabled.

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/import_order \
     -u {site_api_key}:\
     -d invoice_id="ship_inv" \
     -d subscription_id="__test__sZEDgk5GSLmev7p7J" \
     -d order_date=1519879210 \
     -d status="QUEUED" \
     -d created_at=1517460010 \
     -d shipping_date=1522557610
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 0,
        "base_currency_code": "USD",
        "created_at": 1517460010,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__sZEDgk5GSLmev7p7J",
        "deleted": false,
        "discount": 0,
        "exchange_rate": 1,
        "id": "2",
        "invoice_id": "ship_inv",
        "is_gifted": false,
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1519879210,
        "order_line_items": [
            {
                "amount": 2000,
                "amount_adjusted": 0,
                "amount_paid": 0,
                "description": "shippable plan",
                "discount_amount": 0,
                "entity_id": "shippable",
                "entity_type": "plan",
                "fulfillment_amount": 2000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__sZEDgk5GSLmevt27U",
                "invoice_id": "ship_inv",
                "invoice_line_item_id": "li___test__sZEDgk5GSLmevGj7R",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 0,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 2000
            },
            {..}
        ],
        "order_type": "system_generated",
        "payment_status": "not_paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 0,
        "refundable_credits_issued": 0,
        "resource_version": 1517657205622,
        "rounding_adjustement": 0,
        "shipping_date": 1522557610,
        "status": "queued",
        "sub_total": 2000,
        "subscription_id": "__test__sZEDgk5GSLmev7p7J",
        "tax": 0,
        "total": 2000,
        "updated_at": 1517657205
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/import_order

Method

id[]
optional, string, max chars=40
Uniquely identifies the order. It is the api identifier for the order.

Order id will always be assigned incrementally from the last generated Order ID.

If Orders imported has an Order ID which is a string, Chargebee will just validate if the Order ID is unique

Recommendation: For orders being imported, set the same prefix and the serial number that is used for the Document number, which will make this into a string. This will ensure that imported orders don't conflict with orders created by Chargebee. Chargebee will ensure there aren’t orders with duplicate Order IDs.
.
document_number[]
optional, string, max chars=50
The order's serial number.

Document number passed cannot be greater than the series mentioned in the configuration. For instance, if you have set Document number series in Order Configurations with a Prefix as ‘ORDER’ and Starting number as ‘1000’, orders up to the sequence number ‘ORDER999’ can be imported into Chargebee

Recommendation: Set a different prefix at the Order Configuration, than the ones that are imported. If your Order Configuration has a Prefix of ‘NEW’, with Starting number as ‘1’, i.e. ‘NEW1’, then, set Prefix for imported orders to be as ‘OLD’, with Starting number as ‘1’, i.e, ‘OLD1’ .
invoice_id[]
required, string, max chars=50
The invoice number which acts as an identifier for invoice and is generated sequentially.
status[]
required, enumerated string
The status of this order.
Possible values are
cancelledOrder has been cancelled. Applicable only if you are using Chargebee's legacy order management systemqueuedOrder is yet to be processed by any system, these are scheduled orders created by Chargebeeawaiting_shipmentThe order has been picked up by an integration system, and synced to a shipping management platformon_holdThe order is paused from being processed.
Show all values[+]
subscription_id[]
optional, string, max chars=50
The subscription for which the order is created.
customer_id[]
optional, string, max chars=50
The customer for which the order is created.
created_at[]
required, timestamp(UTC) in seconds
The time at which the order was created.
order_date[]
required, timestamp(UTC) in seconds
The date on which the order will start getting processed.
shipping_date[]
required, timestamp(UTC) in seconds
This is the date on which the order has to be shipped to the customer.
reference_id[]
optional, string, max chars=50
Reference id can be used to map the orders in the shipping/order management application to the orders in ChargeBee. The reference_id generally is the same as the order id in the third party application.

Recommendation:
If this order is in any of these statuses, awaiting_shipment, on_hold, delivered, shipped, partially_delivered, returned, and has already been processed, through a 3rd party system, and you have a reference id of the entity in the 3rd party tool, pass in the entity id to this field. If not, set the same prefix and the serial number that is used for the Document number, which will make this into a string.


If this order hasn’t been processed and is in ‘queued’ status, do not pass any value to this field. Chargebee, when it syncs your Orders through the fulfilment integrations such as Shipstation or Shopify, would auto assign the reference id from the connected system..
fulfillment_status[]
optional, string, max chars=50
The fulfillment status of an order as reflected in the shipping/order management application. Typical statuses include Shipped,Awaiting Shipment,Not fulfilled etc;.

If this order is in any of these statuses, awaiting_shipment, on_hold, delivered, shipped, partially_delivered, returned, and has already been processed, through a 3rd party system, and you have a corresponding status from the 3rd party tool, pass in the status to this field.

If this order hasn’t been processed and is in ‘queued’ status, do not pass any value to this field. Chargebee, when it syncs your Orders through the fulfilment integrations such as Shipstation or Shopify, would auto assign the fulfilment status from the connected system.
.
note[]
optional, string, max chars=600
The custom note for the order.
tracking_id[]
optional, string, max chars=50
The tracking id of the order.
tracking_url[]
optional, string, max chars=255
The tracking url of the order.
batch_id[]
optional, string, max chars=50
Unique id to identify a group of orders.
shipment_carrier[]
optional, string, max chars=50
Shipment carrier.
shipping_cut_off_date[]
optional, timestamp(UTC) in seconds
The time after which an order becomes unservicable.
delivered_at[]
optional, timestamp(UTC) in seconds
The time at which the order was delivered.
shipped_at[]
optional, timestamp(UTC) in seconds
The time at which the order was shipped.
cancelled_at[]
optional, timestamp(UTC) in seconds
The time at which the order was cancelled.
cancellation_reason[]
optional, enumerated string
Cancellation reason.
Possible values are
shipping_cut_off_passedThe invoice has been paid late and Chargebee cancel's the first order for the invoice.product_unsatisfactoryProduct unsatisfactory.third_party_cancellationThird party cancellation.product_not_requiredProduct not required.
Show all values[+]
refundable_credits_issued[]
optional, in cents, min=0
If there are any credits that were issued at the order level, you can make use of the field, refundable_credits_issued. This will lead to Chargebee creating a Refundable Credit note against the order. When the next invoice is raised against the customer, this credit note will be utilised.
shipping_address[first_name]
optional, string, max chars=150
shipping_address[last_name]
optional, string, max chars=150
shipping_address[email]
optional, string, max chars=70
shipping_address[company]
optional, string, max chars=250
shipping_address[phone]
optional, string, max chars=50
shipping_address[line1]
optional, string, max chars=150
shipping_address[line2]
optional, string, max chars=150
shipping_address[line3]
optional, string, max chars=150
shipping_address[city]
optional, string, max chars=50
shipping_address[state_code]
optional, string, max chars=50
shipping_address[state]
optional, string, max chars=50
shipping_address[zip]
optional, string, max chars=20
shipping_address[country]
optional, string, max chars=50
shipping_address[validation_status]
optional, enumerated string, default=not_validated
Possible values are
not_validatedAddress is not yet validated.validAddress was validated successfully.partially_validThe address is valid for taxability but has not been validated for shipping.invalidAddress is invalid.
Show all values[+]
billing_address[first_name]
optional, string, max chars=150
billing_address[last_name]
optional, string, max chars=150
billing_address[email]
optional, string, max chars=70
billing_address[company]
optional, string, max chars=250
billing_address[phone]
optional, string, max chars=50
billing_address[line1]
optional, string, max chars=150
billing_address[line2]
optional, string, max chars=150
billing_address[line3]
optional, string, max chars=150
billing_address[city]
optional, string, max chars=50
billing_address[state_code]
optional, string, max chars=50
billing_address[state]
optional, string, max chars=50
billing_address[zip]
optional, string, max chars=20
billing_address[country]
optional, string, max chars=50
billing_address[validation_status]
optional, enumerated string, default=not_validated
Possible values are
not_validatedAddress is not yet validated.validAddress was validated successfully.partially_validThe address is valid for taxability but has not been validated for shipping.invalidAddress is invalid.
Show all values[+]
order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
Assigns order number to the order based on the settings, if not already assigned

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/1/assign_order_number \
     -X POST  \
     -u {site_api_key}:
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 40000,
        "base_currency_code": "USD",
        "created_at": 1517505883,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__KyVnHhSBWlkX22lL",
        "deleted": false,
        "discount": 0,
        "document_number": "1",
        "exchange_rate": 1,
        "id": "1",
        "invoice_id": "__demo_inv__1",
        "is_gifted": false,
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1517505882,
        "order_line_items": [
            {
                "amount": 40000,
                "amount_adjusted": 0,
                "amount_paid": 40000,
                "description": "MB1S1P",
                "discount_amount": 0,
                "entity_id": "MB1S1P",
                "entity_type": "plan",
                "fulfillment_amount": 40000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__KyVnGlSBWlkkr25u",
                "invoice_id": "__demo_inv__1",
                "invoice_line_item_id": "li___test__KyVnHhSBWlkYO2lN",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 40000,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 40000
            },
            {..}
        ],
        "order_type": "system_generated",
        "paid_on": 1517505882,
        "payment_status": "paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 40000,
        "refundable_credits_issued": 0,
        "resource_version": 1517678681000,
        "rounding_adjustement": 0,
        "shipping_date": 1517505882,
        "status": "queued",
        "sub_total": 40000,
        "subscription_id": "__test__KyVnHhSBWlkX22lL",
        "tax": 0,
        "total": 40000,
        "updated_at": 1517678681
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/{order-id}/assign_order_number

Method

order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
Cancel order and create a refundable credit note for the order

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/1/cancel \
     -u {site_api_key}:\
     -d cancellation_reason="PRODUCT_UNSATISFACTORY" \
     -d customer_notes="Products were defective"
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 40000,
        "base_currency_code": "USD",
        "cancellation_reason": "product_unsatisfactory",
        "cancelled_at": 1517678683,
        "created_at": 1517505885,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__KyVnHhSBWll5K2lX",
        "deleted": false,
        "discount": 0,
        "document_number": "1",
        "exchange_rate": 1,
        "id": "1",
        "invoice_id": "__demo_inv__1",
        "is_gifted": false,
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1517505884,
        "order_line_items": [
            {
                "amount": 40000,
                "amount_adjusted": 0,
                "amount_paid": 40000,
                "description": "MB1S1P",
                "discount_amount": 0,
                "entity_id": "MB1S1P",
                "entity_type": "plan",
                "fulfillment_amount": 40000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__KyVnGlSBWllJc264",
                "invoice_id": "__demo_inv__1",
                "invoice_line_item_id": "li___test__KyVnHhSBWll852lZ",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 40000,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 40000
            },
            {..}
        ],
        "order_type": "system_generated",
        "paid_on": 1517505884,
        "payment_status": "paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 40000,
        "refundable_credits_issued": 0,
        "resource_version": 1517678683000,
        "rounding_adjustement": 0,
        "shipping_date": 1517505884,
        "status": "cancelled",
        "status_update_at": 1517678683,
        "sub_total": 40000,
        "subscription_id": "__test__KyVnHhSBWll5K2lX",
        "tax": 0,
        "total": 40000,
        "updated_at": 1517678683
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/{order-id}/cancel

Method

cancellation_reason[]
required, enumerated string
Cancellation reason.
Possible values are
shipping_cut_off_passedThe invoice has been paid late and Chargebee cancel's the first order for the invoice.product_unsatisfactoryProduct unsatisfactory.third_party_cancellationThird party cancellation.product_not_requiredProduct not required.
Show all values[+]
customer_notes[]
optional, string, max chars=2000
The Customer Notes to be filled in the Credit Notes created to capture this refund detail.
comment[]
optional, string, max chars=300
Comment, if any, on the refund.
cancelled_at[]
optional, timestamp(UTC) in seconds
The time at which the order was cancelled.
credit_note[total]
optional, in cents, default=0, min=0
order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
This API is used to create a refundable credit note for the order

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/1/create_refundable_credit_note \
     -u {site_api_key}:\
     -d credit_note[reason_code]="PRODUCT_UNSATISFACTORY" \
     -d credit_note[total]=100
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 40000,
        "base_currency_code": "USD",
        "created_at": 1517505903,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__KyVnHhSBWlpZx2nQ",
        "deleted": false,
        "discount": 0,
        "document_number": "1",
        "exchange_rate": 1,
        "id": "1",
        "invoice_id": "__demo_inv__1",
        "is_gifted": false,
        "linked_credit_notes": [
            {
                "amount": 100,
                "id": "__demo_cn__1",
                "object": "order_line_item_linked_credit",
                "status": "refund_due",
                "type": "refundable"
            },
            {..}
        ],
        "object": "order",
        "order_date": 1517505902,
        "order_line_items": [
            {
                "amount": 40000,
                "amount_adjusted": 0,
                "amount_paid": 40000,
                "description": "MB1S1P",
                "discount_amount": 0,
                "entity_id": "MB1S1P",
                "entity_type": "plan",
                "fulfillment_amount": 40000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__KyVnGlSBWlpkB272",
                "invoice_id": "__demo_inv__1",
                "invoice_line_item_id": "li___test__KyVnHhSBWlpbC2nS",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 39900,
                "refundable_credits_issued": 100,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 40000
            },
            {..}
        ],
        "order_type": "system_generated",
        "paid_on": 1517505902,
        "payment_status": "paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 39900,
        "refundable_credits_issued": 100,
        "resource_version": 1517678701000,
        "rounding_adjustement": 0,
        "shipping_date": 1517505902,
        "status": "queued",
        "sub_total": 40000,
        "subscription_id": "__test__KyVnHhSBWlpZx2nQ",
        "tax": 0,
        "total": 40000,
        "updated_at": 1517678701
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/{order-id}/create_refundable_credit_note

Method

customer_notes[]
optional, string, max chars=2000
The Customer Notes to be filled in the Credit Notes created to capture this refund detail.
comment[]
optional, string, max chars=300
Comment, if any, on the refund.
credit_note[reason_code]
required, enumerated string
Possible values are
write_offThis reason will be set automatically for the Credit Notes created during invoice Write Off operation.subscription_changeThis reason will be set automatically for Credit Notes created during Change Subscription operation when proration is enabledsubscription_cancellationThis reason will be set automatically for Credit Notes created during cancel subscription operationsubscription_pauseThis reason will be automatically set to credit notes created during pause/resume subscription operation.
Show all values[+]
credit_note[total]
required, in cents, default=0, min=0
order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
This API is used to re-open a cancelled order

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/1/reopen \
     -X POST  \
     -u {site_api_key}:
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 40000,
        "base_currency_code": "USD",
        "cancelled_at": 1517678702,
        "created_at": 1517505905,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__KyVnHhSBWlq8E2ni",
        "deleted": false,
        "discount": 0,
        "document_number": "1",
        "exchange_rate": 1,
        "id": "1",
        "invoice_id": "__demo_inv__1",
        "is_gifted": false,
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1517505904,
        "order_line_items": [
            {
                "amount": 40000,
                "amount_adjusted": 0,
                "amount_paid": 40000,
                "description": "MB1S1P",
                "discount_amount": 0,
                "entity_id": "MB1S1P",
                "entity_type": "plan",
                "fulfillment_amount": 40000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__KyVnGlSBWlqJO27C",
                "invoice_id": "__demo_inv__1",
                "invoice_line_item_id": "li___test__KyVnHhSBWlq9K2nk",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 40000,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 40000
            },
            {..}
        ],
        "order_type": "system_generated",
        "paid_on": 1517505904,
        "payment_status": "paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 40000,
        "refundable_credits_issued": 0,
        "resource_version": 1517678702000,
        "rounding_adjustement": 0,
        "shipping_date": 1517505904,
        "status": "queued",
        "status_update_at": 1517678702,
        "sub_total": 40000,
        "subscription_id": "__test__KyVnHhSBWlq8E2ni",
        "tax": 0,
        "total": 40000,
        "updated_at": 1517678702
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/{order-id}/reopen

Method

void_cancellation_credit_notes[]
optional, boolean
Flag to void credit notes created for cancellation if they are unused.
order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
Retrieves an order corresponding to the order id passed.

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/1 \
     -u {site_api_key}:
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 40000,
        "base_currency_code": "USD",
        "created_at": 1517505907,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__KyVnHhSBWlqc32nw",
        "deleted": false,
        "discount": 0,
        "document_number": "1",
        "exchange_rate": 1,
        "id": "1",
        "invoice_id": "__demo_inv__1",
        "is_gifted": false,
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1517505906,
        "order_line_items": [
            {
                "amount": 40000,
                "amount_adjusted": 0,
                "amount_paid": 40000,
                "description": "MB1S1P",
                "discount_amount": 0,
                "entity_id": "MB1S1P",
                "entity_type": "plan",
                "fulfillment_amount": 40000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__KyVnGlSBWlqm327M",
                "invoice_id": "__demo_inv__1",
                "invoice_line_item_id": "li___test__KyVnHhSBWlqdG2ny",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 40000,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 40000
            },
            {..}
        ],
        "order_type": "system_generated",
        "paid_on": 1517505906,
        "payment_status": "paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 40000,
        "refundable_credits_issued": 0,
        "resource_version": 1517505907000,
        "rounding_adjustement": 0,
        "shipping_date": 1517505906,
        "status": "queued",
        "sub_total": 40000,
        "subscription_id": "__test__KyVnHhSBWlqc32nw",
        "tax": 0,
        "total": 40000,
        "updated_at": 1517505907
    }
}

URL Format GET

https://{site}.chargebee.com/api/v2/orders/{order-id}

Method

order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
Deletes only Imported Order .Delete does not happen if the order was refunded. It goes through if order refund was initiated and is in “refund_due” state.
This API is not enabled for live sites by default. Please contact support to get this enabled.

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/2/delete \
     -X POST  \
     -u {site_api_key}:
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 0,
        "base_currency_code": "USD",
        "created_at": 1517460010,
        "created_by": "Auto generated by system",
        "currency_code": "USD",
        "customer_id": "__test__sZEDgk5GSLmfR357m",
        "deleted": true,
        "discount": 0,
        "exchange_rate": 1,
        "id": "2",
        "invoice_id": "ship_inv_delete",
        "is_gifted": false,
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1519879210,
        "order_line_items": [
            {
                "amount": 2000,
                "amount_adjusted": 0,
                "amount_paid": 0,
                "description": "shippable plan",
                "discount_amount": 0,
                "entity_id": "shippable",
                "entity_type": "plan",
                "fulfillment_amount": 2000,
                "fulfillment_quantity": 1,
                "id": "o_li__test__sZEDgk5GSLmfR9y7x",
                "invoice_id": "ship_inv_delete",
                "invoice_line_item_id": "li___test__sZEDgk5GSLmfR7a7u",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 0,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 2000
            },
            {..}
        ],
        "order_type": "system_generated",
        "payment_status": "not_paid",
        "price_type": "tax_exclusive",
        "refundable_credits": 0,
        "refundable_credits_issued": 0,
        "resource_version": 1517657325813,
        "rounding_adjustement": 0,
        "shipping_date": 1522557610,
        "status": "queued",
        "sub_total": 2000,
        "subscription_id": "__test__sZEDgk5GSLmfR357m",
        "tax": 0,
        "total": 2000,
        "updated_at": 1517657325
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/{order-id}/delete

Method

order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
This API is used to retrieve a list of all the available orders.

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders \
     -G  \
     -u {site_api_key}:\
     --data-urlencode limit=3 \
     --data-urlencode status[is]="queued"
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "list": [
        {
            "order": {
                "amount_adjusted": 0,
                "amount_paid": 40000,
                "base_currency_code": "USD",
                "created_at": 1517505898,
                "created_by": "Auto generated by system",
                "currency_code": "USD",
                "customer_id": "__test__KyVnHhSBWloVR2mr",
                "deleted": false,
                "discount": 0,
                "document_number": "1",
                "exchange_rate": 1,
                "id": "1",
                "invoice_id": "__demo_inv__1",
                "is_gifted": false,
                "linked_credit_notes": [],
                "object": "order",
                "order_date": 1517505897,
                "order_line_items": [
                    {
                        "amount": 40000,
                        "amount_adjusted": 0,
                        "amount_paid": 40000,
                        "description": "MB1S1P",
                        "discount_amount": 0,
                        "entity_id": "MB1S1P",
                        "entity_type": "plan",
                        "fulfillment_amount": 40000,
                        "fulfillment_quantity": 1,
                        "id": "o_li__test__KyVnGlSBWloic26i",
                        "invoice_id": "__demo_inv__1",
                        "invoice_line_item_id": "li___test__KyVnHhSBWloWi2mt",
                        "is_shippable": true,
                        "item_level_discount_amount": 0,
                        "object": "order_line_item",
                        "refundable_credits": 40000,
                        "refundable_credits_issued": 0,
                        "status": "queued",
                        "tax_amount": 0,
                        "unit_price": 40000
                    },
                    {..}
                ],
                "order_type": "system_generated",
                "paid_on": 1517505897,
                "payment_status": "paid",
                "price_type": "tax_exclusive",
                "refundable_credits": 40000,
                "refundable_credits_issued": 0,
                "resource_version": 1517505898000,
                "rounding_adjustement": 0,
                "shipping_date": 1517505897,
                "status": "queued",
                "sub_total": 40000,
                "subscription_id": "__test__KyVnHhSBWloVR2mr",
                "tax": 0,
                "total": 40000,
                "updated_at": 1517505898
            }
        },
        {..}
    ]
}

URL Format GET

https://{site}.chargebee.com/api/v2/orders

Method

limit[]
optional, integer, default=10, min=1, max=100
The number of resources to be returned.
offset[]
optional, string, max chars=1000
Determines your position in the list for pagination. To ensure that the next page is retrieved correctly, always set offset to the value of next_offset obtained in the previous iteration of the API call.
include_deleted[]
optional, boolean, default=false
If set to true, includes the deleted resources in the response. For the deleted resources in the response, the 'deleted' attribute will be 'true'.
exclude_deleted_credit_notes[]
optional, boolean
Flag to indicate whether deleted credit notes should be passed or not.
sort_by[<sort-order>]
optional, string filter
Sorts based on the specified attribute.
Supported attributes : created_at, updated_at
Supported sort-orders : asc, desc

Example sort_by[asc] = "created_at"
This will sort the result based on the 'created_at' attribute in ascending(earliest first) order.
Filter Params
For operator usages, see the Pagination and Filtering section.
id[<operator>]
optional, string filter
Uniquely identifies the order. It is the api identifier for the order. Possible values are :
Supported operators : is, is_not, starts_with, in, not_in

Example id[is] = "890"
id[is][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
id[is_not][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
id[starts_with][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
id[in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
id[not_in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
invoice_id[<operator>]
optional, string filter
The invoice number which acts as an identifier for invoice and is generated sequentially. Possible values are :
Supported operators : is, is_not, starts_with, in, not_in

Example invoice_id[is] = "INVOICE_982"
invoice_id[is][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
invoice_id[is_not][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
invoice_id[starts_with][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
invoice_id[in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
invoice_id[not_in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
subscription_id[<operator>]
optional, string filter
The subscription for which the order is created. Possible values are :
Supported operators : is, is_not, starts_with

Example subscription_id[is] = "null"
subscription_id[is][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
subscription_id[is_not][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
subscription_id[starts_with][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
status[<operator>]
optional, enumerated string filter
The status of this order. Possible values are : new, processing, complete, cancelled, voided, queued, awaiting_shipment, on_hold, delivered, shipped, partially_delivered, returned
Supported operators : is, is_not, in, not_in

Example status[is] = "queued"
status[is][operator]
optional, enumerated string filter
Possible values are : new, processing, complete, cancelled, voided, queued, awaiting_shipment, on_hold, delivered, shipped, partially_delivered, returned
Supported operators :

Example
status[is_not][operator]
optional, enumerated string filter
Possible values are : new, processing, complete, cancelled, voided, queued, awaiting_shipment, on_hold, delivered, shipped, partially_delivered, returned
Supported operators :

Example
status[in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
status[not_in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
shipping_date[<operator>]
optional, timestamp(UTC) in seconds filter
This is the date on which the order will be delivered to the customer. Possible values are :
Supported operators : after, before, on, between

Example shipping_date[after] = "1435054328"
shipping_date[after][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
shipping_date[before][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
shipping_date[on][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
shipping_date[between][operator]
optional, string filter
Possible values are :
Supported operators :

Example
shipped_at[<operator>]
optional, timestamp(UTC) in seconds filter
The time at which the order was shipped. Possible values are :
Supported operators : after, before, on, between

Example shipped_at[after] = "1435054328"
shipped_at[after][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
shipped_at[before][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
shipped_at[on][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
shipped_at[between][operator]
optional, string filter
Possible values are :
Supported operators :

Example
order_type[<operator>]
optional, enumerated string filter
Order type. Possible values are : manual, system_generated
Supported operators : is, is_not, in, not_in

Example order_type[is] = "system_generated"
order_type[is][operator]
optional, enumerated string filter
Possible values are : manual, system_generated
Supported operators :

Example
order_type[is_not][operator]
optional, enumerated string filter
Possible values are : manual, system_generated
Supported operators :

Example
order_type[in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
order_type[not_in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
order_date[<operator>]
optional, timestamp(UTC) in seconds filter
The date on which the order will start getting processed. Possible values are :
Supported operators : after, before, on, between

Example order_date[after] = "1435054328"
order_date[after][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
order_date[before][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
order_date[on][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
order_date[between][operator]
optional, string filter
Possible values are :
Supported operators :

Example
paid_on[<operator>]
optional, timestamp(UTC) in seconds filter
The timestamp indicating the date & time the order's invoice got paid. Possible values are :
Supported operators : after, before, on, between

Example paid_on[after] = "1435054328"
paid_on[after][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
paid_on[before][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
paid_on[on][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
paid_on[between][operator]
optional, string filter
Possible values are :
Supported operators :

Example
updated_at[<operator>]
optional, timestamp(UTC) in seconds filter
To filter based on updated at . Possible values are :
Supported operators : after, before, on, between

Example updated_at[after] = "1243545465"
updated_at[after][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
updated_at[before][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
updated_at[on][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
updated_at[between][operator]
optional, string filter
Possible values are :
Supported operators :

Example
created_at[<operator>]
optional, timestamp(UTC) in seconds filter
The time at which the order was created. Possible values are :
Supported operators : after, before, on, between

Example created_at[after] = "1435054328"
created_at[after][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
created_at[before][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
created_at[on][operator]
optional, timestamp(UTC) in seconds filter
Possible values are :
Supported operators :

Example
created_at[between][operator]
optional, string filter
Possible values are :
Supported operators :

Example
resent_status[<operator>]
optional, enumerated string filter
Resent order status. Possible values are : fully_resent, partially_resent
Supported operators : is, is_not, in, not_in

Example resent_status[is] = "fully_resent"
resent_status[is][operator]
optional, enumerated string filter
Possible values are : fully_resent, partially_resent
Supported operators :

Example
resent_status[is_not][operator]
optional, enumerated string filter
Possible values are : fully_resent, partially_resent
Supported operators :

Example
resent_status[in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
resent_status[not_in][operator]
optional, string filter
Possible values are :
Supported operators :

Example
is_resent[<operator>]
optional, enumerated string filter
Order is resent order or not. Possible values are : true, false
Supported operators : is

Example is_resent[is] = "false"
is_resent[is][operator]
optional, enumerated string filter
Possible values are : true, false
Supported operators :

Example
original_order_id[<operator>]
optional, string filter
If resent order what is the parent order id. Possible values are :
Supported operators : is, is_not, starts_with

Example original_order_id[is] = "1xRt6ifdr"
original_order_id[is][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
original_order_id[is_not][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
original_order_id[starts_with][operator]
optional, string, min chars=1 filter
Possible values are :
Supported operators :

Example
order order
always returned
Resource object representing order
next_offset next_offset
optional, string, max chars=1000
This attribute is returned only if more resources are present. To fetch the next set of resources use this value for the input parameter `offset`.

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x
Resend an existing order. This will help in resending an existing order in full or partial. Upto 5 resend operations are allowed per . When resent fully, the original order is canceled.

Notes

Sample Request
curl  https://{site}.chargebee.com/api/v2/orders/1/resend \
     -u {site_api_key}:\
     -d shipping_date=1517675618 \
     -d resend_reason="Damaged"
curl  https://{site}.chargebee.com/api/v2/orders/1/resend \
     -X POST  \
     -u {site_api_key}:\
     -d shipping_date=1517675620 \
     -d resend_reason="Damaged" \
     -d order_line_items[id][0]="o_li__test__5SK1MsCBSJFzUUE39" \
     -d order_line_items[fulfillment_quantity][0]=1 
copy
Click to Copy

Sample Response [ JSON ]

Show more...
{
    "order": {
        "amount_adjusted": 0,
        "amount_paid": 0,
        "base_currency_code": "USD",
        "created_at": 1517675018,
        "created_by": "Manually generated by user",
        "currency_code": "USD",
        "customer_id": "__test__sZEDgk7tSJFzTSYZ",
        "deleted": false,
        "discount": 40000,
        "document_number": "2",
        "exchange_rate": 1,
        "id": "2",
        "invoice_id": "__demo_inv__1",
        "is_gifted": false,
        "is_resent": true,
        "line_item_discounts": [
            {
                "discount_amount": 40000,
                "discount_type": "custom_discount",
                "line_item_id": "li___test__sZEDgk7tSJFzTUsb",
                "object": "line_item_discount"
            },
            {..}
        ],
        "linked_credit_notes": [],
        "object": "order",
        "order_date": 1517675018,
        "order_line_items": [
            {
                "amount": 40000,
                "amount_adjusted": 0,
                "amount_paid": 0,
                "description": "MB1S1P",
                "discount_amount": 40000,
                "entity_id": "MB1S1P",
                "entity_type": "plan",
                "fulfillment_amount": 0,
                "fulfillment_quantity": 1,
                "id": "o_li__test__sZEDgk7tSJFzU5to",
                "invoice_id": "__demo_inv__1",
                "invoice_line_item_id": "li___test__sZEDgk7tSJFzTUsb",
                "is_shippable": true,
                "item_level_discount_amount": 0,
                "object": "order_line_item",
                "refundable_credits": 0,
                "refundable_credits_issued": 0,
                "status": "queued",
                "tax_amount": 0,
                "unit_price": 40000
            },
            {..}
        ],
        "order_type": "system_generated",
        "original_order_id": 464000000004,
        "price_type": "tax_exclusive",
        "refundable_credits": 0,
        "refundable_credits_issued": 0,
        "resend_reason": "Damaged",
        "resource_version": 1517675019129,
        "rounding_adjustement": 0,
        "shipping_date": 1517675618,
        "status": "queued",
        "sub_total": 0,
        "subscription_id": "__test__sZEDgk7tSJFzTSYZ",
        "tax": 0,
        "total": 0,
        "updated_at": 1517675019
    }
}

URL Format POST

https://{site}.chargebee.com/api/v2/orders/{order-id}/resend

Method

shipping_date[]
optional, timestamp(UTC) in seconds
The date on which the order should be shipped to the customer.
resend_reason[]
optional, string, max chars=100
Reason code for resending the order. Must be one from a list of reason codes set in the Chargebee app in Settings > Configure Chargebee > Reason Codes > Orders > Order Resend. Must be passed if set as mandatory in the app. The codes are case-sensitive.
order_line_items[id][0..n]
optional, string, max chars=40
order_line_items[fulfillment_quantity][0..n]
optional, integer, min=0
order order
always returned
Resource object representing order

Sample admin console URL

https://{site}.chargebee.com/admin-console/orders/123x