Create order

POST/api/v1/orders

Create a new draft order with per-line billing rules.

Operation ID: create_order_api_v1_orders_post·View as markdown·OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Request body

customer_idstringrequired

Customer the order is for.

project_idstring

Project / job (optional).

order_descriptionstring

Order description.

order_start_datestring

Order start (YYYY-MM-DD).

first_invoice_datestring

First invoice date (YYYY-MM-DD); anchors the term clock.

term_monthsinteger

Term length in months.

discount_centsinteger

Contract-level discount (cents).

tax_treatmentstring

Tax treatment label.

currencystring

Currency code.

linesarray · OrderLineInputOrderLineInput

Order-form lines.

7 fields
catalog_item_idstring

Catalog item this line is based on (optional).

descriptionstring

Line description.

qtynumber | stringrequired

Ordered quantity / hours.

unit_price_centsintegerrequired

Unit price in cents.

billing_rulestring

flat, per_unit, recurring, usage_metered, or prepaid_block.

billing_timingstring

Recurring only: each_period, first_upfront, all_upfront.

ramp_scheduleobject

Pre-agreed step qty/price schedule (frozen at signing).

Responses

201Successful Response

successboolean
messagestring
codestring
dataapp__api__v1__schemas__orders__OrderResponse

400Bad Request - Invalid input

401Unauthorized - Authentication required

403Forbidden - Insufficient permissions

404Not Found - Resource does not exist

422Validation Error

detailarray · ValidationErrorValidationError
5 fields
locarray · string | integerrequired
msgstringrequired
typestringrequired
inputobject
ctxobject