POST/Orders
Creates an empty Draft order on the event and returns its id. Source (Internal or External) is optional and
defaults to External; vendorCollaboratorRecordId (one of the organization's collaborator records) is optional. Add
lines with Orders_AddLineItems, rename it with Orders_UpdateOrder, or use Orders_CreateOrderFromProcurement to
pre-fill from a procurement.
With an org token (resource inventory edit) it creates an organization-level order instead: vendorCollaboratorRecordId
(a collaborator record) is required, defaultDisposition (Pool or OrgUse) defaults to Pool,
and requestingDepartmentId is optional.
Either scope takes an optional orderTypeId (an active type from OrderTypes_GetOrderTypes), values for attributes that
type places and intakeAnswers to its intake form. roleOccupants fills the roles the type places (one entry per role, the list
matching the role as in Orders_SetOrderRoleOccupants, checked the same way). A crew member or collaborator filling a role is an
organization record: it never adds them to the event. A role named with occupants skips its fill-from default, one left out or named empty keeps it.
The candidates come from Orders_GetEventOrderRoleCandidates and Orders_GetOrganizationOrderRoleCandidates. The order is created
Draft and never refused for missing required values; the type's template runs and its effects, tracking and AI fill start.
Request Body
| Field | Type | Required | Description |
|---|
| name | string | Optional | |
| source | string | Optional | |
| vendorCollaboratorRecordId | uuid | Optional | |
| defaultDisposition | string | Optional | |
| requestingDepartmentId | uuid | Optional | |
| orderTypeId | uuid | Optional | |
| values | CreateOrderRequestAttributeValueInput[] | Optional | |
| intakeAnswers | CreateOrderRequestIntakeAnswerInput[] | Optional | |
| roleOccupants | CreateOrderRequestRoleOccupantsInput[] | Optional | |
| Field | Type | Description |
|---|
| attributeId | uuid | |
| value | JsonElement| null | |
| expiresOn | JsonElement| null | |
| itemExpiries | JsonElement| null | |
| Field | Type | Description |
|---|
| questionId | uuid | |
| value | JsonElement| null | |
| Field | Type | Description |
|---|
| roleDefinitionId | uuid | |
| crewIds | uuid[]| null | |
| collaboratorRecordIds | uuid[]| null | |
| resourceIds | uuid[]| null | |
| procurementResourceIds | uuid[]| null | |
Response
Type: uuid