1 /**
2 * @schema AdminOrder
3 * type: object
4 * description: The order's details.
5 * x-schemaName: AdminOrder
6 * required:
7 * - payment_collections
8 * - items
9 * - shipping_methods
10 * - id
11 * - version
12 * - region_id
13 * - customer_id
14 * - sales_channel_id
15 * - email
16 * - currency_code
17 * - status
18 * - payment_status
19 * - fulfillment_status
20 * - summary
21 * - created_at
22 * - updated_at
23 * - original_item_total
24 * - original_item_subtotal
25 * - original_item_tax_total
26 * - item_total
27 * - item_subtotal
28 * - item_tax_total
29 * - item_discount_total
30 * - original_total
31 * - original_subtotal
32 * - original_tax_total
33 * - total
34 * - subtotal
35 * - tax_total
36 * - discount_total
37 * - discount_tax_total
38 * - gift_card_total
39 * - gift_card_tax_total
40 * - shipping_total
41 * - shipping_subtotal
42 * - shipping_tax_total
43 * - shipping_discount_total
44 * - original_shipping_total
45 * - original_shipping_subtotal
46 * - original_shipping_tax_total
47 * - credit_line_total
48 * properties:
49 * payment_collections:
50 * type: array
51 * description: The order's payment collections.
52 * items:
53 * $ref: "#/components/schemas/AdminPaymentCollection"
54 * fulfillments:
55 * type: array
56 * description: The order's fulfillments.
57 * items:
58 * $ref: "#/components/schemas/AdminOrderFulfillment"
59 * sales_channel:
60 * $ref: "#/components/schemas/AdminSalesChannel"
61 * customer:
62 * $ref: "#/components/schemas/AdminCustomer"
63 * shipping_address:
64 * $ref: "#/components/schemas/AdminOrderAddress"
65 * billing_address:
66 * $ref: "#/components/schemas/AdminOrderAddress"
67 * id:
68 * type: string
69 * title: id
70 * description: The order's ID.
71 * version:
72 * type: number
73 * title: version
74 * description: The order's version.
75 * region_id:
76 * type: string
77 * title: region_id
78 * description: The ID of the region associated with the order.
79 * customer_id:
80 * type: string
81 * title: customer_id
82 * description: The ID of the customer that placed the order.
83 * sales_channel_id:
84 * type: string
85 * title: sales_channel_id
86 * description: The ID of the sales channel the order is placed in.
87 * email:
88 * type: string
89 * title: email
90 * description: The email of the customer that placed the order.
91 * format: email
92 * currency_code:
93 * type: string
94 * title: currency_code
95 * description: The order's currency code.
96 * display_id:
97 * type: number
98 * title: display_id
99 * description: The order's display ID.
100 * items:
101 * type: array
102 * description: The order's items.
103 * items:
104 * $ref: "#/components/schemas/AdminOrderLineItem"
105 * shipping_methods:
106 * type: array
107 * description: The order's shipping methods.
108 * items:
109 * $ref: "#/components/schemas/AdminOrderShippingMethod"
110 * payment_status:
111 * type: string
112 * description: The order's payment status.
113 * enum:
114 * - canceled
115 * - not_paid
116 * - awaiting
117 * - authorized
118 * - partially_authorized
119 * - captured
120 * - partially_captured
121 * - partially_refunded
122 * - refunded
123 * - requires_action
124 * fulfillment_status:
125 * type: string
126 * description: The order's fulfillment status.
127 * enum:
128 * - canceled
129 * - not_fulfilled
130 * - partially_fulfilled
131 * - fulfilled
132 * - partially_shipped
133 * - shipped
134 * - partially_delivered
135 * - delivered
136 * transactions:
137 * type: array
138 * description: The order's transactions.
139 * items:
140 * $ref: "#/components/schemas/BaseOrderTransaction"
141 * summary:
142 * $ref: "#/components/schemas/BaseOrderSummary"
143 * metadata:
144 * type: object
145 * description: The order's metadata, can hold custom key-value pairs.
146 * externalDocs:
147 * url: https://docs.medusajs.com/api/admin#manage-metadata
148 * description: Learn how to manage metadata
149 * created_at:
150 * type: string
151 * format: date-time
152 * title: created_at
153 * description: The date the order was created.
154 * updated_at:
155 * type: string
156 * format: date-time
157 * title: updated_at
158 * description: The date the order was updated.
159 * original_item_total:
160 * type: number
161 * title: original_item_total
162 * description: The total of the order's items including taxes, excluding promotions.
163 * original_item_subtotal:
164 * type: number
165 * title: original_item_subtotal
166 * description: The total of the order's items excluding taxes, including promotions.
167 * original_item_tax_total:
168 * type: number
169 * title: original_item_tax_total
170 * description: The tax total of the order's items excluding promotions.
171 * item_total:
172 * type: number
173 * title: item_total
174 * description: The total of the order's items including taxes and promotions.
175 * item_subtotal:
176 * type: number
177 * title: item_subtotal
178 * description: The total of the order's items excluding taxes, including promotions.
179 * item_tax_total:
180 * type: number
181 * title: item_tax_total
182 * description: The tax total of the order's items including promotions.
183 * original_total:
184 * type: number
185 * title: original_total
186 * description: The order's total excluding promotions, including taxes.
187 * original_subtotal:
188 * type: number
189 * title: original_subtotal
190 * description: The order's total excluding taxes, including promotions.
191 * original_tax_total:
192 * type: number
193 * title: original_tax_total
194 * description: The order's tax total, excluding promotions.
195 * total:
196 * type: number
197 * title: total
198 * description: The order's total including taxes and promotions.
199 * subtotal:
200 * type: number
201 * title: subtotal
202 * description: The order's total excluding taxes, including promotions.
203 * tax_total:
204 * type: number
205 * title: tax_total
206 * description: The order's tax total including promotions.
207 * discount_total:
208 * type: number
209 * title: discount_total
210 * description: The order's discount or promotions total.
211 * discount_tax_total:
212 * type: number
213 * title: discount_tax_total
214 * description: The tax total of order's discount or promotion.
215 * gift_card_total:
216 * type: number
217 * title: gift_card_total
218 * description: The order's gift card total.
219 * gift_card_tax_total:
220 * type: number
221 * title: gift_card_tax_total
222 * description: The tax total of the order's gift card.
223 * shipping_total:
224 * type: number
225 * title: shipping_total
226 * description: The order's shipping total including taxes and promotions.
227 * shipping_subtotal:
228 * type: number
229 * title: shipping_subtotal
230 * description: The order's shipping total excluding taxes, including promotions.
231 * shipping_tax_total:
232 * type: number
233 * title: shipping_tax_total
234 * description: The tax total of the order's shipping.
235 * original_shipping_total:
236 * type: number
237 * title: original_shipping_total
238 * description: The order's shipping total including taxes, excluding promotions.
239 * original_shipping_subtotal:
240 * type: number
241 * title: original_shipping_subtotal
242 * description: The order's shipping total excluding taxes, including promotions.
243 * original_shipping_tax_total:
244 * type: number
245 * title: original_shipping_tax_total
246 * description: The tax total of the order's shipping excluding promotions.
247 * status:
248 * type: string
249 * title: status
250 * description: The order's status.
251 * region:
252 * $ref: "#/components/schemas/AdminRegion"
253 * credit_lines:
254 * type: array
255 * description: The order's credit lines.
256 * items:
257 * $ref: "#/components/schemas/OrderCreditLine"
258 * credit_line_total:
259 * type: number
260 * title: credit_line_total
261 * description: The order's credit line total.
262 * item_discount_total:
263 * type: number
264 * title: item_discount_total
265 * description: The total discount amount applied on the order's items.
266 * shipping_discount_total:
267 * type: number
268 * title: shipping_discount_total
269 * description: The total discount amount applied on the order's shipping.
270 * custom_display_id:
271 * type: string
272 * title: custom_display_id
273 * description: The custom display ID of the order.
274 * externalDocs:
275 * url: https://docs.medusajs.com/resources/commerce-modules/order/custom-display-id
276 *
277 */
278