diff --git a/www/apps/api-reference/specs/admin/code_samples/Shell/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered/post.sh b/www/apps/api-reference/specs/admin/code_samples/Shell/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered/post.sh new file mode 100644 index 0000000000000..7f597b2ef3ecc --- /dev/null +++ b/www/apps/api-reference/specs/admin/code_samples/Shell/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered/post.sh @@ -0,0 +1,2 @@ +curl -X POST '{backend_url}/admin/orders/{id}/fulfillments/{fulfillment_id}/mark-as-delivered' \ +-H 'Authorization: Bearer {access_token}' \ No newline at end of file diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminApplicationMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminApplicationMethod.yaml new file mode 100644 index 0000000000000..1849ad17e6a03 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminApplicationMethod.yaml @@ -0,0 +1,113 @@ +type: object +description: The promotion's application method. +x-schemaName: AdminApplicationMethod +required: + - id +properties: + promotion: + type: object + description: The application method's promotion. + x-schemaName: AdminPromotion + required: + - id + properties: + application_method: + type: object + description: The promotion's application method. + x-schemaName: AdminApplicationMethod + rules: + type: array + description: The promotion's rules. + items: + type: object + description: The rule's rules. + x-schemaName: AdminPromotionRule + id: + type: string + title: id + description: The promotion's ID. + code: + type: string + title: code + description: The promotion's code. + type: + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. + is_automatic: + type: boolean + title: is_automatic + description: The promotion's is automatic. + campaign_id: + type: string + title: campaign_id + description: The promotion's campaign id. + campaign: + type: object + description: The promotion's campaign. + x-schemaName: AdminCampaign + target_rules: + type: array + description: The application method's target rules. + items: + $ref: ./AdminPromotionRule.yaml + buy_rules: + type: array + description: The application method's buy rules. + items: + $ref: ./AdminPromotionRule.yaml + id: + type: string + title: id + description: The application method's ID. + type: + oneOf: + - type: string + title: type + description: The application method's type. + - type: string + title: type + description: The application method's type. + target_type: + oneOf: + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + allocation: + oneOf: + - type: string + title: allocation + description: The application method's allocation. + - type: string + title: allocation + description: The application method's allocation. + value: + type: number + title: value + description: The application method's value. + currency_code: + type: string + title: currency_code + description: The application method's currency code. + max_quantity: + type: number + title: max_quantity + description: The application method's max quantity. + buy_rules_min_quantity: + type: number + title: buy_rules_min_quantity + description: The application method's buy rules min quantity. + apply_to_quantity: + type: number + title: apply_to_quantity + description: The application method's apply to quantity. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminArchiveOrder.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminArchiveOrder.yaml deleted file mode 100644 index 72b7d36198259..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminArchiveOrder.yaml +++ /dev/null @@ -1,10 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: AdminArchiveOrder -required: - - order_id -properties: - order_id: - type: string - title: order_id - description: The order's order id. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminClaim.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminClaim.yaml index 21f60500a4924..89c8b61111f25 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminClaim.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminClaim.yaml @@ -2,44 +2,18 @@ type: object description: The claim's details. x-schemaName: AdminClaim required: - - order_id - - claim_items - - additional_items - - currency_code + - order + - return - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - type + - order_id + - display_id + - order_version - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - additional_items + - claim_items properties: id: type: string @@ -60,7 +34,7 @@ properties: items: $ref: ./BaseClaimItem.yaml return: - $ref: ./Return.yaml + $ref: ./AdminReturn.yaml return_id: type: string title: return_id @@ -73,76 +47,15 @@ properties: type: number title: refund_amount description: The amount to be refunded. - currency_code: - type: string - title: currency_code - description: The claim's currency code. - region_id: - type: string - title: region_id - description: The ID of the region associated with the claim. - customer_id: - type: string - title: customer_id - description: The ID of the customer associated with the claim's order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the claim's order is created in. - email: - type: string - title: email - description: The email associated with the claim's order. - format: email display_id: type: number title: display_id description: The claim's display ID. - shipping_address: - $ref: ./BaseOrderAddress.yaml - billing_address: - $ref: ./BaseOrderAddress.yaml shipping_methods: type: array description: The claim's shipping methods. items: - $ref: ./BaseOrderShippingMethod.yaml - payment_collections: - type: array - description: The claim's payment collections. - items: - $ref: ./BasePaymentCollection.yaml - payment_status: - type: string - description: The claim's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The claim's fulfillments. - items: - $ref: ./BaseOrderFulfillment.yaml - fulfillment_status: - type: string - description: The claim's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered + $ref: ./AdminOrderShippingMethod.yaml transactions: type: array description: The claim's transactions. @@ -152,8 +65,6 @@ properties: description: Learn more about transactions of orders and associated models. items: $ref: ./BaseOrderTransaction.yaml - summary: - $ref: ./BaseOrderSummary.yaml metadata: type: object description: The claim's metadata, used to store custom key-value pairs. @@ -167,91 +78,33 @@ properties: format: date-time title: updated_at description: The claim's update date. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the associated order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the associated order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The tax total of the original items in the associated order. - item_total: - type: number - title: item_total - description: The total of the claim's items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the claim's items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the claim's items. - original_total: - type: number - title: original_total - description: The associated order's original total. - original_subtotal: - type: number - title: original_subtotal - description: The associated order's original subtotal. - original_tax_total: - type: number - title: original_tax_total - description: The associated order's original tax total. - total: - type: number - title: total - description: The associated order's total. - subtotal: - type: number - title: subtotal - description: The claim's subtotal. - tax_total: - type: number - title: tax_total - description: The claim's tax total. - discount_total: - type: number - title: discount_total - description: The claim's discount total. - discount_tax_total: - type: number - title: discount_tax_total - description: The claim's discount tax total. - gift_card_total: - type: number - title: gift_card_total - description: The claim's gift card total. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The claim's gift card tax total. - shipping_total: - type: number - title: shipping_total - description: The claim's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The claim's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The claim's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The associated order's original shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The associated order's original shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The associated order's original shipping tax total. + order: + type: string + title: order + description: >- + The field to sort the data by. By default, the sort order is ascending. To + change the order to descending, prefix the field name with `-`. + type: + type: string + description: The claim's type. + enum: + - replace + - refund + order_version: + type: string + title: order_version + description: The claim's order version. + created_by: + type: string + title: created_by + description: The claim's created by. + canceled_at: + type: string + title: canceled_at + description: The claim's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The claim's deleted at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimOrderResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimOrderResponse.yaml index ea206926d5654..94991816b3ebc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimOrderResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimOrderResponse.yaml @@ -6,6 +6,8 @@ required: - claim properties: order: - $ref: ./Order.yaml + type: string + title: order + description: The order change's order. claim: $ref: ./AdminClaim.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimPreviewResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimPreviewResponse.yaml index d3d5cf085c60e..8fdefc68186a7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimPreviewResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimPreviewResponse.yaml @@ -8,6 +8,6 @@ required: - claim properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml claim: $ref: ./AdminClaim.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimRequestResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimRequestResponse.yaml index eb463459db71e..c49a9d5d9e284 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimRequestResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimRequestResponse.yaml @@ -11,6 +11,6 @@ properties: return: $ref: ./AdminReturn.yaml order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml claim: $ref: ./AdminClaim.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimReturnPreviewResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimReturnPreviewResponse.yaml index f91f77fa23062..9688761b29659 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminClaimReturnPreviewResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminClaimReturnPreviewResponse.yaml @@ -8,6 +8,6 @@ required: - return properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml return: $ref: ./AdminReturn.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateApplicationMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateApplicationMethod.yaml deleted file mode 100644 index 5cbb99276e849..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateApplicationMethod.yaml +++ /dev/null @@ -1,78 +0,0 @@ -type: object -description: The application method's details. -x-schemaName: AdminCreateApplicationMethod -required: - - value - - type - - target_type -properties: - description: - type: string - title: description - description: The application method's description. - value: - type: number - title: value - description: >- - The discounted amount applied by the associated promotion based on the - `type`. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: >- - The max quantity allowed in the cart for the associated promotion to be - applied. - type: - type: string - description: >- - The type of the application method indicating how the associated promotion - is applied. - enum: - - fixed - - percentage - target_type: - type: string - description: >- - The target type of the application method indicating whether the - associated promotion is applied to the cart's items, shipping methods, or - the whole order. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: >- - The allocation value that indicates whether the associated promotion is - applied on each item in a cart or split between the items in the cart. - enum: - - each - - across - target_rules: - type: array - description: The application method's target rules. - items: - $ref: ./AdminCreatePromotionRule.yaml - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: ./AdminCreatePromotionRule.yaml - apply_to_quantity: - type: number - title: apply_to_quantity - description: >- - The quantity that results from matching the `buyget` promotion's - condition. For example, if the promotion is a "Buy 2 shirts get 1 free", - the value f this attribute is `1`. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: >- - The minimum quantity required for a `buyget` promotion to be applied. For - example, if the promotion is a "Buy 2 shirts get 1 free", the value of - this attribute is `2`. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateFulfillment.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateFulfillment.yaml index 0dd456e29b17e..79e31f7d86e6c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateFulfillment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateFulfillment.yaml @@ -2,15 +2,14 @@ type: object description: The filfillment's details. x-schemaName: AdminCreateFulfillment required: + - data + - order_id + - metadata + - items - location_id - provider_id - delivery_address - - items - labels - - order - - order_id - - data - - metadata properties: location_id: type: string @@ -75,8 +74,8 @@ properties: description: An item to fulfill. required: - title - - sku - quantity + - sku - barcode properties: title: diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreatePriceList.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreatePriceList.yaml index ff78bb5483e55..4e048abb66759 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreatePriceList.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreatePriceList.yaml @@ -24,17 +24,27 @@ properties: description: The date and time the price list ends at. format: date-time status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. @@ -48,8 +58,8 @@ properties: description: A price's details. required: - currency_code - - amount - variant_id + - amount properties: currency_code: type: string diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProduct.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProduct.yaml index d4cece0e332de..362b8eae6e1fc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProduct.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProduct.yaml @@ -46,13 +46,20 @@ properties: title: handle description: The product's handle. status: - type: string + oneOf: + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. description: The product's status. - enum: - - draft - - proposed - - published - - rejected type_id: type: string title: type_id diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductType.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductType.yaml new file mode 100644 index 0000000000000..fa411cf780dfa --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductType.yaml @@ -0,0 +1,13 @@ +type: object +description: The product's details. +x-schemaName: AdminCreateProductType +required: + - value +properties: + metadata: + type: object + description: The product's metadata, used to store custom key-value pairs. + value: + type: string + title: value + description: The product type's value. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariant.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariant.yaml index 874a1015bb353..f4ac3e13c2bb0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariant.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariant.yaml @@ -86,3 +86,8 @@ properties: the option's value. example: Color: Black + inventory_items: + type: array + description: The variant's inventory items. + items: + $ref: ./AdminCreateProductVariantInventoryKit.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariantInventoryKit.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariantInventoryKit.yaml new file mode 100644 index 0000000000000..51d9f00f560c5 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariantInventoryKit.yaml @@ -0,0 +1,14 @@ +type: object +description: The inventory item's inventory items. +x-schemaName: AdminCreateProductVariantInventoryKit +required: + - inventory_item_id +properties: + inventory_item_id: + type: string + title: inventory_item_id + description: The inventory item's inventory item id. + required_quantity: + type: number + title: required_quantity + description: The inventory item's required quantity. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariantPrice.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariantPrice.yaml index e543b4f377602..c876e32e65ca4 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariantPrice.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateProductVariantPrice.yaml @@ -30,3 +30,10 @@ properties: description: The price's rules. example: region_id: reg_123 + properties: + region_id: + type: string + title: region_id + description: The rule's region id. + required: + - region_id diff --git a/www/apps/api-reference/specs/store/components/schemas/CreateOrderReturnReason.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateReturnReason.yaml similarity index 93% rename from www/apps/api-reference/specs/store/components/schemas/CreateOrderReturnReason.yaml rename to www/apps/api-reference/specs/admin/components/schemas/AdminCreateReturnReason.yaml index efbb641c2ff68..851e8e9f48d2d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/CreateOrderReturnReason.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateReturnReason.yaml @@ -1,6 +1,6 @@ type: object description: SUMMARY -x-schemaName: CreateOrderReturnReason +x-schemaName: AdminCreateReturnReason required: - value - label diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateShippingOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateShippingOption.yaml index ea6b78201e029..76e37a2dd8036 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateShippingOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateShippingOption.yaml @@ -1,92 +1,20 @@ type: object -description: The shipping option's details. +description: The shipping option's type. x-schemaName: AdminCreateShippingOption required: - - name - - service_zone_id - - shipping_profile_id - - price_type - - provider_id - - type - - prices + - label + - description + - code properties: - name: + label: type: string - title: name - description: The shipping option's name. - service_zone_id: + title: label + description: The type's label. + description: type: string - title: service_zone_id - description: The ID of the service zone this shipping option belongs to. - shipping_profile_id: + title: description + description: The type's description. + code: type: string - title: shipping_profile_id - description: The ID of the shipping profile this shipping option belongs to. - data: - type: object - description: >- - Any data necessary for fulfillment providers to handle shipping methods - and fulfillments of this shipping option. - externalDocs: - url: >- - https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property - description: Learn more about the data property. - price_type: - type: string - description: > - The shipping option price's type. If `flat`, it means the option has a - fixed price set in the `prices` property. `calculated` means that the - shipping option's price is calculated during checkout. - enum: - - flat - - calculated - provider_id: - type: string - title: provider_id - description: >- - The ID of the fulfillment provider used to handle this shipping option and - its associated methods and fulfillments. - type: - type: object - prices: - type: array - description: >- - The shipping option's prices. If `price_type` is `calculated`, pass an - empty array for this property. - items: - oneOf: - - type: object - description: The price for a currency code. - x-schemaName: AdminCreateShippingOptionPriceWithCurrency - required: - - currency_code - - amount - properties: - currency_code: - type: string - title: currency_code - description: The price's currency code. - amount: - type: number - title: amount - description: The price's amount. - - type: object - description: The price in a region. - x-schemaName: AdminCreateShippingOptionPriceWithRegion - required: - - region_id - - amount - properties: - region_id: - type: string - title: region_id - description: The ID of the region this price is used in. - amount: - type: number - title: amount - description: The price's amount. - rules: - type: array - description: The shipping option's rules. - items: - $ref: ./AdminCreateShippingOptionRule.yaml + title: code + description: The type's code. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateShippingOptionRule.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateShippingOptionRule.yaml deleted file mode 100644 index 05df606241c91..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateShippingOptionRule.yaml +++ /dev/null @@ -1,38 +0,0 @@ -type: object -description: The details of the shipping option rule. -x-schemaName: AdminCreateShippingOptionRule -required: - - operator - - attribute - - value -properties: - operator: - type: string - description: The operator used to check whether a rule applies. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte - - nin - attribute: - type: string - title: attribute - description: The name of a property or table that the rule applies to. - example: customer_group - value: - oneOf: - - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 - - type: array - description: Values of the attribute that enable this rule. - items: - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateVariantInventoryItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateVariantInventoryItem.yaml index 23e84a8328b64..2de3fc7b23be7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateVariantInventoryItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateVariantInventoryItem.yaml @@ -2,8 +2,8 @@ type: object description: The details of the variant-inventory item association. x-schemaName: AdminCreateVariantInventoryItem required: - - required_quantity - inventory_item_id + - required_quantity properties: required_quantity: type: number diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml index f7539f38b9e8f..d11dc80830f8c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml @@ -18,8 +18,13 @@ properties: compensate_input: description: Sets the compensation function's input. It accepts any response. action: - type: string + oneOf: + - type: string + description: The workflows execution's action. + enum: + - INVOKE + - type: string + description: The workflows execution's action. + enum: + - COMPENSATE description: Whether to invoke or compensate the step. - enum: - - invoke - - compensate diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminCurrency.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminCurrency.yaml index 984e1d51cf090..887204ea4dcf7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminCurrency.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminCurrency.yaml @@ -8,7 +8,6 @@ required: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminExchange.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminExchange.yaml index e66c9d6ec8124..1d24996743a2a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminExchange.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminExchange.yaml @@ -2,44 +2,14 @@ type: object description: The exchange's details. x-schemaName: AdminExchange required: - - order_id - - return_items - - additional_items - - currency_code - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - order_id - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - deleted_at + - additional_items + - return_items properties: order_id: type: string @@ -67,88 +37,24 @@ properties: be refunded. If positive, additional payment is required from the customer. return: - description: the return associated with the exchange. $ref: ./AdminReturn.yaml return_id: type: string title: return_id description: The ID of the associated exchange. - currency_code: - type: string - title: currency_code - description: The exchange's currency code. id: type: string title: id description: The exchange's ID. - region_id: - type: string - title: region_id - description: The ID of the associated order's region. - customer_id: - type: string - title: customer_id - description: The ID of the customer that placed the order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the associated order belongs to. - email: - type: string - title: email - description: The email used when placing the order. - format: email display_id: - type: number + type: string title: display_id description: The exchange's display ID. - shipping_address: - description: The shipping address to send new items to. - $ref: ./BaseOrderAddress.yaml - billing_address: - description: The customer's billing address. - $ref: ./BaseOrderAddress.yaml shipping_methods: type: array description: The shipping methods used to send the new (outbound) items. items: $ref: ./BaseOrderShippingMethod.yaml - payment_collections: - type: array - description: The exchange's payment collections. - items: - $ref: ./BasePaymentCollection.yaml - payment_status: - type: string - description: The exchange's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The exchange's fulfillments of new (outbound) items. - items: - $ref: ./BaseOrderFulfillment.yaml - fulfillment_status: - type: string - description: The exchange's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered transactions: type: array description: The exchange's transactions. @@ -157,9 +63,6 @@ properties: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions items: $ref: ./BaseOrderTransaction.yaml - summary: - description: The totals summary of the exchange. - $ref: ./BaseOrderSummary.yaml metadata: type: object description: The exchange's metadata, can hold custom key-value pairs. @@ -173,91 +76,31 @@ properties: format: date-time title: updated_at description: The date that the exchange was updated. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The total tax of the original items in the order. - item_total: - type: number - title: item_total - description: The total of the exchange's new items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the exchange's new items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the exchange's new items. - original_total: - type: number - title: original_total - description: The total of the order. - original_subtotal: - type: number - title: original_subtotal - description: The subtotal of the order. - original_tax_total: - type: number - title: original_tax_total - description: The tax total of the order. - total: - type: number - title: total - description: The total of the exchange. - subtotal: - type: number - title: subtotal - description: The subtotal of the exchange. - tax_total: - type: number - title: tax_total - description: The tax total of the exchange. - discount_total: - type: number - title: discount_total - description: The discount total of the exchange. - discount_tax_total: - type: number - title: discount_tax_total - description: The total taxes on discount of the exchange. - gift_card_total: - type: number - title: gift_card_total - description: The gift cards total of the exchange. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The total taxes on the gift card of the exchange. - shipping_total: - type: number - title: shipping_total - description: The exchange's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The exchange's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The exchange's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The order's shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The order's shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The order's shipping tax total. + order_version: + type: string + title: order_version + description: The exchange's order version. + created_by: + type: string + title: created_by + description: The exchange's created by. + canceled_at: + type: string + title: canceled_at + description: The exchange's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The exchange's deleted at. + order: + type: string + title: order + description: >- + The field to sort the data by. By default, the sort order is ascending. To + change the order to descending, prefix the field name with `-`. + allow_backorder: + type: boolean + title: allow_backorder + description: The exchange's allow backorder. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeOrderResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeOrderResponse.yaml index 03bc03d999ba2..6fff213887d58 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeOrderResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeOrderResponse.yaml @@ -6,7 +6,8 @@ required: - exchange properties: order: - description: The details of the associated order. - $ref: ./Order.yaml + type: string + title: order + description: The order change's order. exchange: $ref: ./AdminExchange.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangePreviewResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangePreviewResponse.yaml index 43b16c64383de..2ada4ad0d5849 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangePreviewResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangePreviewResponse.yaml @@ -6,6 +6,6 @@ required: - exchange properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml exchange: $ref: ./AdminExchange.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeRequestResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeRequestResponse.yaml index 8c908c82e0c7c..285bbc8842a6f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeRequestResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeRequestResponse.yaml @@ -7,10 +7,8 @@ required: - exchange properties: return: - description: The associated return's details. $ref: ./AdminReturn.yaml order_preview: - description: A preview of the order once the exchange is applied. - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml exchange: $ref: ./AdminExchange.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeReturnResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeReturnResponse.yaml index abe845366fc88..d8ab001ca031d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeReturnResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminExchangeReturnResponse.yaml @@ -6,6 +6,6 @@ required: - return properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml return: $ref: ./AdminReturn.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminExportProductRequest.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminExportProductRequest.yaml new file mode 100644 index 0000000000000..aa3490570bfc1 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminExportProductRequest.yaml @@ -0,0 +1,3 @@ +type: object +description: SUMMARY +x-schemaName: AdminExportProductRequest diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillment.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillment.yaml index 80430cd6adf85..a459be7817a01 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillment.yaml @@ -37,10 +37,8 @@ properties: title: shipping_option_id description: The ID of the shipping option this fulfillment is created for. provider: - description: The details of the fulfillment provider using to handle this fulfillment. $ref: ./AdminFulfillmentProvider.yaml delivery_address: - description: The address to deliver the item to. $ref: ./AdminFulfillmentAddress.yaml items: type: array diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentProvider.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentProvider.yaml index 9d7d2c4f6a843..a60a87734e0ba 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentProvider.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentProvider.yaml @@ -1,3 +1,15 @@ type: object -description: The shipping option's provider. +description: The fulfillment provider's details. x-schemaName: AdminFulfillmentProvider +required: + - id + - is_enabled +properties: + id: + type: string + title: id + description: The provider's ID. + is_enabled: + type: boolean + title: is_enabled + description: The provider's is enabled. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentSet.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentSet.yaml index e9131c3f4aa8e..47858b02ccd26 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentSet.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminFulfillmentSet.yaml @@ -1,5 +1,5 @@ type: object -description: The fulfillment set's parent. +description: The service zone's fulfillment set. x-schemaName: AdminFulfillmentSet required: - id @@ -14,34 +14,36 @@ properties: id: type: string title: id - description: The parent's ID. + description: The fulfillment set's ID. name: type: string title: name - description: The parent's name. + description: The fulfillment set's name. type: type: string title: type - description: The parent's type. + description: The fulfillment set's type. location: - $ref: ./AdminStockLocation.yaml + type: object + description: The stock location's details. + x-schemaName: AdminStockLocation service_zones: type: array - description: The parent's service zones. + description: The fulfillment set's service zones. items: $ref: ./AdminServiceZone.yaml created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The fulfillment set's created at. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The fulfillment set's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The fulfillment set's deleted at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminGeoZone.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminGeoZone.yaml index fcdcef3406b53..c7d0be5d77dc5 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminGeoZone.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminGeoZone.yaml @@ -1,5 +1,5 @@ type: object -description: The geo zone's details. +description: The geo zone's geo zones. x-schemaName: AdminGeoZone required: - id @@ -43,14 +43,14 @@ properties: type: string format: date-time title: created_at - description: The date the geo zone was created. + description: The geo zone's created at. updated_at: type: string format: date-time title: updated_at - description: The date the geo zone was update. + description: The geo zone's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The date the geo zone was deleted. + description: The geo zone's deleted at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminImportProductRequest.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminImportProductRequest.yaml index 94efb6c2bde43..8aac0f128a862 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminImportProductRequest.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminImportProductRequest.yaml @@ -5,4 +5,9 @@ required: - file properties: file: - $ref: ./File.yaml + type: object + description: A File to upload. + externalDocs: + url: https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: file diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryItem.yaml index c2c758a65cd2f..287a08bd992ca 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryItem.yaml @@ -1,5 +1,5 @@ type: object -description: The inventory item's details. +description: The reservation's inventory item. x-schemaName: AdminInventoryItem required: - id @@ -12,7 +12,7 @@ properties: sku: type: string title: sku - description: The inventory item's SKU. + description: The inventory item's sku. origin_country: type: string title: origin_country @@ -20,15 +20,15 @@ properties: hs_code: type: string title: hs_code - description: The inventory item's HS code. + description: The inventory item's hs code. requires_shipping: type: boolean title: requires_shipping - description: Whether the inventory item requires shipping. + description: The inventory item's requires shipping. mid_code: type: string title: mid_code - description: The inventory item's MID code. + description: The inventory item's mid code. material: type: string title: material @@ -60,12 +60,12 @@ properties: thumbnail: type: string title: thumbnail - description: The URL of the inventory item's thumbnail. + description: The inventory item's thumbnail. metadata: type: object - description: The inventory item's metadata, can hold custom key-value pairs. + description: The inventory item's metadata. location_levels: type: array - description: The inventory item's associated inventory levels. + description: The inventory item's location levels. items: $ref: ./AdminInventoryLevel.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryLevel.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryLevel.yaml index 28850cf68c1cf..d7802818c2b7b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryLevel.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminInventoryLevel.yaml @@ -1,5 +1,5 @@ type: object -description: The inventory level's details. +description: The location level's location levels. x-schemaName: AdminInventoryLevel required: - id @@ -9,67 +9,56 @@ required: - inventory_item_id - location_id - stocked_quantity - - raw_stocked_quantity - reserved_quantity - - raw_reserved_quantity - incoming_quantity - - raw_incoming_quantity - metadata - available_quantity properties: id: type: string title: id - description: The inventory level's ID. + description: The location level's ID. + created_at: + type: string + format: date-time + title: created_at + description: The location level's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The location level's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The location level's deleted at. inventory_item_id: type: string title: inventory_item_id - description: The ID of the inventory item this level belongs to. + description: The location level's inventory item id. location_id: type: string title: location_id - description: The ID of the stock location this level belongs to. + description: The location level's location id. stocked_quantity: type: number title: stocked_quantity - description: >- - The quantity of the associated inventory item stocked in the associated - stock location. + description: The location level's stocked quantity. reserved_quantity: type: number title: reserved_quantity - description: >- - The reserved quantity of the associated inventory item stocked in the - associated stock location. + description: The location level's reserved quantity. incoming_quantity: type: number title: incoming_quantity - description: >- - The incoming quantity of the associated inventory item stocked in the - associated stock location. + description: The location level's incoming quantity. metadata: type: object - description: The location level's metadata, can hold custom key-value pairs. + description: The location level's metadata. inventory_item: type: object available_quantity: type: number title: available_quantity - description: >- - The quantity available for order of the associated inventory item in the - associated stock location. - created_at: - type: string - format: date-time - title: created_at - description: The date the inventory level was created. - updated_at: - type: string - format: date-time - title: updated_at - description: The date the inventory level was updated. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The date the inventory level was deleted. + description: The location level's available quantity. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminMarkOrderFulfillmentDelivered.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminMarkOrderFulfillmentDelivered.yaml new file mode 100644 index 0000000000000..94ea98ca76ce0 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminMarkOrderFulfillmentDelivered.yaml @@ -0,0 +1,3 @@ +type: object +description: SUMMARY +x-schemaName: AdminMarkOrderFulfillmentDelivered diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrder.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrder.yaml index 4d56258b6ed1d..e90b9b2d8fadc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrder.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrder.yaml @@ -3,21 +3,20 @@ description: The order's details. x-schemaName: AdminOrder required: - payment_collections + - items + - shipping_methods + - currency_code - id + - created_at + - updated_at + - email - version - region_id - customer_id - sales_channel_id - - email - - currency_code - - items - - shipping_methods - payment_status - fulfillment_status - summary - - metadata - - created_at - - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -50,7 +49,7 @@ properties: type: array description: The order's fulfillments. items: - $ref: ./BaseOrderFulfillment.yaml + $ref: ./AdminOrderFulfillment.yaml sales_channel: $ref: ./AdminSalesChannel.yaml customer: @@ -96,12 +95,12 @@ properties: type: array description: The order's items. items: - $ref: ./BaseOrderLineItem.yaml + $ref: ./AdminOrderLineItem.yaml shipping_methods: type: array description: The order's shipping methods. items: - $ref: ./BaseOrderShippingMethod.yaml + $ref: ./AdminOrderShippingMethod.yaml payment_status: type: string description: The order's payment status. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChange.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChange.yaml new file mode 100644 index 0000000000000..da495b3dd1759 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChange.yaml @@ -0,0 +1,150 @@ +type: object +description: The order change's details. +x-schemaName: AdminOrderChange +required: + - order + - claim + - return_order + - exchange + - actions + - status + - order_id + - metadata + - id + - created_at + - updated_at + - version + - canceled_at + - return_id + - exchange_id + - claim_id + - requested_by + - requested_at + - confirmed_by + - confirmed_at + - declined_by + - declined_reason + - declined_at + - canceled_by +properties: + id: + type: string + title: id + description: The order change's ID. + version: + type: number + title: version + description: >- + The order change's version. This will be the order's version when the + change is applied. + change_type: + oneOf: + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + description: The order change's type. + order_id: + type: string + title: order_id + description: The ID of the order this change applies on. + return_id: + type: string + title: return_id + description: The ID of the associated return. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + order: + type: string + title: order + description: The order change's order. + return_order: + $ref: ./AdminReturn.yaml + exchange: + $ref: ./AdminExchange.yaml + claim: + $ref: ./AdminClaim.yaml + actions: + type: array + description: The order change's actions. + items: + $ref: ./AdminOrderChangeAction.yaml + status: + type: string + description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined + requested_by: + type: string + title: requested_by + description: The ID of the user that requested the change. + requested_at: + type: string + title: requested_at + description: The date the order change was requested. + format: date-time + confirmed_by: + type: string + title: confirmed_by + description: The ID of the user that confirmed the order change. + confirmed_at: + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time + declined_by: + type: string + title: declined_by + description: The ID of the user that declined the order change. + declined_reason: + type: string + title: declined_reason + description: The reason the order change was declined. + metadata: + type: object + description: The order change's metadata, can hold custom key-value pairs. + declined_at: + type: string + title: declined_at + description: The date the order change was declined. + format: date-time + canceled_by: + type: string + title: canceled_by + description: The ID of the user that canceled the order change. + canceled_at: + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time + created_at: + type: string + format: date-time + title: created_at + description: The date the order change was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChangeAction.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChangeAction.yaml new file mode 100644 index 0000000000000..1b229efd173b9 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChangeAction.yaml @@ -0,0 +1,102 @@ +type: object +description: The order change action's details. +x-schemaName: AdminOrderChangeAction +required: + - order_change + - order + - order_id + - internal_note + - id + - created_at + - updated_at + - return_id + - exchange_id + - claim_id + - order_change_id + - reference + - reference_id + - action + - details +properties: + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change that the action belongs to. + order_change: + type: object + order_id: + type: string + title: order_id + description: The ID of the order the associated change is for. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + type: string + title: order + description: The order change's order. + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + description: The applied action. + enum: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the action was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChangesResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChangesResponse.yaml index 0126a1ad99ad3..7e5bb2a7d5fd7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChangesResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderChangesResponse.yaml @@ -8,4 +8,4 @@ properties: type: array description: An order's changes. items: - $ref: ./BaseOrderChange.yaml + $ref: ./AdminOrderChange.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditPreviewResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditPreviewResponse.yaml index ec43c247ffb39..02858b85ad852 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditPreviewResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditPreviewResponse.yaml @@ -5,4 +5,4 @@ required: - order_preview properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditResponse.yaml index db40b31387db3..9cbc0f6528de3 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderEditResponse.yaml @@ -5,4 +5,4 @@ required: - order_change properties: order_change: - $ref: ./OrderChange.yaml + $ref: ./AdminOrderChange.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderFulfillment.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderFulfillment.yaml new file mode 100644 index 0000000000000..a9cd50d83f317 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderFulfillment.yaml @@ -0,0 +1,79 @@ +type: object +description: The fulfillment's fulfillments. +x-schemaName: AdminOrderFulfillment +required: + - id + - location_id + - packed_at + - shipped_at + - delivered_at + - canceled_at + - requires_shipping + - data + - provider_id + - shipping_option_id + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The fulfillment's ID. + location_id: + type: string + title: location_id + description: The ID of the location the items are fulfilled from. + packed_at: + type: string + title: packed_at + description: The date the items were packed. + format: date-time + shipped_at: + type: string + title: shipped_at + description: The date the items were shipped. + format: date-time + delivered_at: + type: string + title: delivered_at + description: The date the items were delivered. + format: date-time + canceled_at: + type: string + title: canceled_at + description: The date the items were canceled. + format: date-time + data: + type: object + description: >- + Data useful for the fulfillment provider handling it. This is taken from + the associated shipping option. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + provider_id: + type: string + title: provider_id + description: The ID of the fulfillment provider used to handle the fulfillment. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the associated shipping option. + metadata: + type: object + description: The fulfillment's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the fulfillment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the fulfillment was updated. + requires_shipping: + type: boolean + title: requires_shipping + description: The fulfillment's requires shipping. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderLineItem.yaml new file mode 100644 index 0000000000000..d06397d72543e --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderLineItem.yaml @@ -0,0 +1,213 @@ +type: object +description: The item's items. +x-schemaName: AdminOrderLineItem +required: + - title + - metadata + - id + - subtitle + - thumbnail + - created_at + - updated_at + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - variant_id + - product_id + - product_title + - product_description + - product_subtitle + - product_type + - product_collection + - product_handle + - variant_sku + - variant_barcode + - variant_title + - variant_option_values + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - detail + - refundable_total + - refundable_total_per_unit +properties: + id: + type: string + title: id + description: The item's ID. + title: + type: string + title: title + description: The item's title. + subtitle: + type: string + title: subtitle + description: The item's subtitle. + thumbnail: + type: string + title: thumbnail + description: The URL of the item's thumbnail. + variant: + $ref: ./AdminProductVariant.yaml + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product: + $ref: ./AdminProduct.yaml + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The item's product type. + product_collection: + type: string + title: product_collection + description: The ID of the collection the item's product belongs to. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: + type: string + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The values of the item variant's options. + example: + Color: Blue + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item is tax inclusive. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + unit_price: + type: number + title: unit_price + description: The item's unit price. + quantity: + type: number + title: quantity + description: The item's quantity. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: ./BaseOrderLineItemTaxLine.yaml + adjustments: + type: array + description: The item's adjustments. + items: + $ref: ./BaseOrderLineItemAdjustment.yaml + detail: + $ref: ./BaseOrderItemDetail.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + original_total: + type: number + title: original_total + description: The item's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the item, excluding promotions. + item_total: + type: number + title: item_total + description: The total taxes of the item, including promotions. + item_subtotal: + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of the item, including promotions. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the item including promotions. + discount_total: + type: number + title: discount_total + description: The total discount amount of the item. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total refundable amount of the item's total. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total refundable amount of the item's total for a single quantity. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreview.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreview.yaml index 1d24582bdff15..a20367738c36a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreview.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreview.yaml @@ -7,19 +7,18 @@ required: - return_requested_total - order_change - currency_code - - version - id + - created_at + - updated_at + - email + - version - region_id - customer_id - sales_channel_id - - email - payment_collections - payment_status - fulfillment_status - summary - - metadata - - created_at - - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -48,7 +47,7 @@ properties: title: return_requested_total description: The total of the requested return. order_change: - $ref: ./BaseOrderChange.yaml + $ref: ./AdminOrderChange.yaml items: type: array description: The order's items. @@ -120,7 +119,7 @@ properties: title: variant_id description: The ID of the associated variant. product: - $ref: ./BaseProduct.yaml + $ref: ./AdminProduct.yaml product_id: type: string title: product_id @@ -519,7 +518,7 @@ properties: type: array description: The order's fulfillments. items: - $ref: ./BaseOrderFulfillment.yaml + $ref: ./AdminOrderFulfillment.yaml fulfillment_status: type: string description: The order's fulfillment status. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreviewResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreviewResponse.yaml index f94371d50e7ba..a6f69a820862a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreviewResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderPreviewResponse.yaml @@ -5,4 +5,8 @@ required: - order properties: order: - $ref: ./AdminOrderPreview.yaml + type: string + title: order + description: >- + A preview of an order if a change, such as exchange, return, edit, or + claim is applied on it. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderResponse.yaml index 7dbac7fa46222..0ed25784cf05b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderResponse.yaml @@ -5,4 +5,6 @@ required: - order properties: order: - $ref: ./AdminOrder.yaml + type: string + title: order + description: The order's details. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderReturnResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderReturnResponse.yaml index ccc9891c960af..c7f107ab52a4d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderReturnResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderReturnResponse.yaml @@ -6,6 +6,8 @@ required: - return properties: order: - $ref: ./Order.yaml + type: string + title: order + description: The order change's order. return: $ref: ./AdminReturn.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminOrderShippingMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderShippingMethod.yaml new file mode 100644 index 0000000000000..ab93242120a98 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminOrderShippingMethod.yaml @@ -0,0 +1,116 @@ +type: object +description: The shipping method's details. +x-schemaName: AdminOrderShippingMethod +required: + - id + - order_id + - name + - amount + - is_tax_inclusive + - shipping_option_id + - data + - metadata + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes applied taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: >- + The shipping method's data, useful for fulfillment provider handling its + fulfillment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: ./BaseOrderShippingMethodTaxLine.yaml + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: ./BaseOrderShippingMethodAdjustment.yaml + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The shipping method's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The total discounts applied on the shipping method. + discount_tax_total: + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + detail: + $ref: ./BaseOrderShippingDetail.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPayment.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPayment.yaml index c03bcea935824..2549b218cbf91 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminPayment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPayment.yaml @@ -86,8 +86,8 @@ properties: type: array description: The details of payment refunds. items: - $ref: ./BaseRefund.yaml + $ref: ./AdminRefund.yaml payment_collection: - $ref: ./BasePaymentCollection.yaml + type: object payment_session: - $ref: ./BasePaymentSession.yaml + $ref: ./AdminPaymentSession.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentCollection.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentCollection.yaml index c6fa1d3cac15a..75d1731804f97 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentCollection.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentCollection.yaml @@ -2,12 +2,12 @@ type: object description: The payment collection's details. x-schemaName: AdminPaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -70,14 +70,14 @@ properties: The payment provider used to process the collection's payments and sessions. items: - $ref: ./BasePaymentProvider.yaml + $ref: ./AdminPaymentProvider.yaml payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: ./BasePaymentSession.yaml + $ref: ./AdminPaymentSession.yaml payments: type: array description: The payment collection's payments. items: - $ref: ./BasePayment.yaml + $ref: ./AdminPayment.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentProvider.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentProvider.yaml index c9d275092e887..3ef9489c8d15b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentProvider.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentProvider.yaml @@ -1,5 +1,5 @@ type: object -description: The payment provider's details. +description: The payment provider's payment providers. x-schemaName: AdminPaymentProvider required: - is_enabled diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentSession.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentSession.yaml new file mode 100644 index 0000000000000..b87f3a855cefc --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPaymentSession.yaml @@ -0,0 +1,61 @@ +type: object +description: The payment session's details. +x-schemaName: AdminPaymentSession +properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: >- + The payment session's data, useful for the payment provider processing the + payment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: ./BasePayment.yaml +required: + - id + - amount + - currency_code + - provider_id + - data + - status diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPostClaimItemsReqSchema.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPostClaimItemsReqSchema.yaml index d1dfd8929fe09..ffa8aca2704ce 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminPostClaimItemsReqSchema.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPostClaimItemsReqSchema.yaml @@ -21,13 +21,24 @@ properties: title: quantity description: The quantity of the order's item to add to the claim. reason: - type: string + oneOf: + - type: string + description: The item's reason. + enum: + - MISSING_ITEM + - type: string + description: The item's reason. + enum: + - WRONG_ITEM + - type: string + description: The item's reason. + enum: + - PRODUCTION_FAILURE + - type: string + description: The item's reason. + enum: + - OTHER description: The reason the item is claimed. - enum: - - missing_item - - wrong_item - - production_failure - - other description: type: string title: description diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProduct.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProduct.yaml index f8bf5ad600df3..e197602dfacaf 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProduct.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProduct.yaml @@ -2,15 +2,15 @@ type: object description: The product's details. x-schemaName: AdminProduct required: + - variants - type + - options + - images - length - title - status - - options - description - id - - created_at - - updated_at - handle - subtitle - is_giftcard @@ -24,9 +24,10 @@ required: - material - collection_id - type_id - - images - discountable - external_id + - created_at + - updated_at - deleted_at properties: collection: @@ -73,7 +74,7 @@ properties: type: array description: The product's options. items: - $ref: ./BaseProductOption.yaml + $ref: ./AdminProductOption.yaml description: type: string title: description @@ -151,7 +152,7 @@ properties: type: array description: The product's images. items: - $ref: ./BaseProductImage.yaml + $ref: ./AdminProductImage.yaml discountable: type: boolean title: discountable diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductImage.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductImage.yaml new file mode 100644 index 0000000000000..050650545a5da --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductImage.yaml @@ -0,0 +1,33 @@ +type: object +description: The image's details. +x-schemaName: AdminProductImage +properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's URL. + created_at: + type: string + format: date-time + title: created_at + description: The date the image was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. +required: + - id + - url diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOption.yaml index bb9c3717aed96..381807c2e8fd0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOption.yaml @@ -1,44 +1,44 @@ type: object -description: The product's product option. +description: The product option's details. x-schemaName: AdminProductOption -required: - - id - - title properties: id: type: string title: id - description: The product option's ID. + description: The option's ID. title: type: string title: title - description: The product option's title. + description: The option's title. product: - $ref: ./BaseProduct.yaml + type: object product_id: type: string title: product_id - description: The product option's product id. + description: The option's product id. values: type: array - description: The product option's values. + description: The option's values. items: - $ref: ./BaseProductOptionValue.yaml + type: object metadata: type: object - description: The product option's metadata. + description: The option's metadata. created_at: type: string format: date-time title: created_at - description: The product option's created at. + description: The option's created at. updated_at: type: string format: date-time title: updated_at - description: The product option's updated at. + description: The option's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The product option's deleted at. + description: The option's deleted at. +required: + - id + - title diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionDeleteResponse.yaml index 0873a46f9a0bd..0069070c06dd6 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product option deletion. x-schemaName: AdminProductOptionDeleteResponse required: - id @@ -9,14 +9,15 @@ properties: id: type: string title: id - description: The product's ID. + description: The product option's ID. object: type: string title: object description: The name of the deleted object. + default: product_option deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the product option was deleted. parent: $ref: ./AdminProduct.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionResponse.yaml index c609e7d1d8ca3..79d305a5d33b9 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product option's details. x-schemaName: AdminProductOptionResponse required: - product_option diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionValue.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionValue.yaml new file mode 100644 index 0000000000000..88175464a4be2 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductOptionValue.yaml @@ -0,0 +1,39 @@ +type: object +description: The product option value's details. +x-schemaName: AdminProductOptionValue +required: + - id + - value +properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + $ref: ./AdminProductOption.yaml + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductResponse.yaml index 1c3d489857a54..5b4cd3889b6fd 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product's details. x-schemaName: AdminProductResponse required: - product diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTag.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTag.yaml index c9dfaff0fbc0e..7fc320de89716 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTag.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTag.yaml @@ -1,5 +1,5 @@ type: object -description: The tag's tags. +description: The product tag's details. x-schemaName: AdminProductTag required: - id @@ -19,17 +19,17 @@ properties: type: string format: date-time title: created_at - description: The tag's created at. + description: The date the tag was created. updated_at: type: string format: date-time title: updated_at - description: The tag's updated at. + description: The date the tag was updated. deleted_at: type: string format: date-time title: deleted_at - description: The tag's deleted at. + description: The date the tag was deleted. metadata: type: object - description: The tag's metadata. + description: The tag's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagDeleteResponse.yaml index 33697dcfd246b..b09f96dd0fc0b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product tag deletion. x-schemaName: AdminProductTagDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Product Tag was deleted. + description: Whether the product tag was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagListResponse.yaml index 40accb66922fe..72220d70411f2 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of product tags. x-schemaName: AdminProductTagListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The product tag's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product tag's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product tag's count. + description: The total number of items. product_tags: type: array - description: The product tag's product tags. + description: The list of product tags. items: $ref: ./AdminProductTag.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagResponse.yaml index 47fe1ad408627..4ae92f3bef80e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTagResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product tag's details. x-schemaName: AdminProductTagResponse required: - product_tag diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductType.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductType.yaml index a8d58344eafdb..ef5f2ece56c12 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductType.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductType.yaml @@ -1,5 +1,5 @@ type: object -description: The parent's type. +description: The product type's details. x-schemaName: AdminProductType required: - id @@ -19,17 +19,17 @@ properties: type: string format: date-time title: created_at - description: The type's created at. + description: The date the type was created. updated_at: type: string format: date-time title: updated_at - description: The type's updated at. + description: The date the type was updated. deleted_at: type: string format: date-time title: deleted_at - description: The type's deleted at. + description: The date the type was deleted. metadata: type: object - description: The type's metadata. + description: The type's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeDeleteResponse.yaml index 797b5fd754ef8..4526de1ff6f63 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product type deletion. x-schemaName: AdminProductTypeDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Product Type was deleted. + description: Whether the product type was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeListResponse.yaml index 9bf9f9159f3d0..19fa220fe971c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of product types. x-schemaName: AdminProductTypeListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The product type's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product type's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product type's count. + description: The total number of items. product_types: type: array - description: The product type's product types. + description: The list of product types. items: $ref: ./AdminProductType.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeResponse.yaml index 8daf16a292c90..d0907f2d65402 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductTypeResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product type's details. x-schemaName: AdminProductTypeResponse required: - product_type diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariant.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariant.yaml index 8e82d12e9dba5..702673830d415 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariant.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariant.yaml @@ -1,8 +1,9 @@ type: object -description: The product's parent. +description: The product variant's details. x-schemaName: AdminProductVariant required: - prices + - options - id - title - sku @@ -19,116 +20,119 @@ required: - length - height - width - - options - created_at - updated_at - deleted_at properties: prices: type: array - description: The parent's prices. + description: The variant's prices. items: $ref: ./AdminPrice.yaml id: type: string title: id - description: The parent's ID. + description: The variant's ID. title: type: string title: title - description: The parent's title. + description: The variant's title. sku: type: string title: sku - description: The parent's sku. + description: The variant's SKU. barcode: type: string title: barcode - description: The parent's barcode. + description: The variant's barcode. ean: type: string title: ean - description: The parent's ean. + description: The variant's EAN code. upc: type: string title: upc - description: The parent's upc. + description: The variant's UPC. allow_backorder: type: boolean title: allow_backorder - description: The parent's allow backorder. + description: Whether the variant can be ordered even if it's out of stock. manage_inventory: type: boolean title: manage_inventory - description: The parent's manage inventory. + description: >- + Whether the Medusa application manages the variant's inventory quantity + and availablility. If disabled, the variant is always considered in stock. inventory_quantity: type: number title: inventory_quantity - description: The parent's inventory quantity. + description: >- + The variant's inventory quantity. This is only included if you pass in the + `fields` query parameter a `+variants.inventory_quantity` parameter. hs_code: type: string title: hs_code - description: The parent's hs code. + description: The variant's HS code. origin_country: type: string title: origin_country - description: The parent's origin country. + description: The variant's origin country. mid_code: type: string title: mid_code - description: The parent's mid code. + description: The variant's MID code. material: type: string title: material - description: The parent's material. + description: The variant's material. weight: type: number title: weight - description: The parent's weight. + description: The variant's weight. length: type: number title: length - description: The parent's length. + description: The variant's length. height: type: number title: height - description: The parent's height. + description: The variant's height. width: type: number title: width - description: The parent's width. + description: The variant's width. variant_rank: type: number title: variant_rank - description: The parent's variant rank. + description: The variant's rank among its sibling variants. options: type: array - description: The parent's options. + description: The variant's option values. items: - $ref: ./BaseProductOptionValue.yaml + $ref: ./AdminProductOptionValue.yaml product: - $ref: ./BaseProduct.yaml + type: object product_id: type: string title: product_id - description: The parent's product id. + description: The ID of the product that the variant belongs to. calculated_price: $ref: ./BaseCalculatedPriceSet.yaml created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the variant was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the variant was updated. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The date the variant was deleted. metadata: type: object - description: The parent's metadata. + description: The variant's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantDeleteResponse.yaml index 52094f9db215d..01b28d3e6561f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product variant's deletion. x-schemaName: AdminProductVariantDeleteResponse required: - id @@ -9,7 +9,7 @@ properties: id: type: string title: id - description: The product's ID. + description: The product variant's ID. object: type: string title: object @@ -17,6 +17,7 @@ properties: deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the product variant was deleted. + default: variant parent: $ref: ./AdminProduct.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryBatchResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryBatchResponse.yaml index 9cf2e1c985e10..bf33c4a7083e9 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryBatchResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryBatchResponse.yaml @@ -1,5 +1,7 @@ type: object -description: SUMMARY +description: >- + The created, updated, and deleted associations between variants and inventory + items. x-schemaName: AdminProductVariantInventoryBatchResponse required: - created @@ -10,10 +12,12 @@ properties: oneOf: - $ref: ./AdminProductVariantInventoryLink.yaml - type: array - description: The product's created. + description: The created associations between product variants and inventory items. items: type: object - description: The created's details. + description: >- + A created association between a product variant and an inventory + item. x-schemaName: AdminProductVariantInventoryLink required: - productService @@ -21,32 +25,34 @@ properties: properties: productService: type: object - description: The created's productservice. + description: The product variant's details. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. + description: The ID of the product variant. inventoryService: type: object - description: The created's inventoryservice. + description: The inventory item's details. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The ID of the inventory item. updated: oneOf: - $ref: ./AdminProductVariantInventoryLink.yaml - type: array - description: The product's updated. + description: The updated associations between product variants and inventory items. items: type: object - description: The updated's details. + description: >- + An updated association between a product variant and an inventory + item. x-schemaName: AdminProductVariantInventoryLink required: - productService @@ -54,32 +60,34 @@ properties: properties: productService: type: object - description: The updated's productservice. + description: The product variant's details. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. + description: The ID of the product variant. inventoryService: type: object - description: The updated's inventoryservice. + description: The inventory item's details. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The ID of the inventory item. deleted: oneOf: - $ref: ./AdminProductVariantInventoryLink.yaml - type: array - description: SUMMARY + description: The deleted associations between product variants and inventory items. items: type: object - description: SUMMARY + description: >- + An deleted association between a product variant and an inventory + item. x-schemaName: AdminProductVariantInventoryLink required: - productService @@ -87,21 +95,21 @@ properties: properties: productService: type: object - description: The deleted's productservice. + description: The product variant's details. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. + description: The ID of the product variant. inventoryService: type: object - description: The deleted's inventoryservice. + description: The inventory item's details. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The ID of the inventory item. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLink.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLink.yaml index e5938e984d6ab..e93cb9a9fe654 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLink.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLink.yaml @@ -1,27 +1,27 @@ type: object -description: The product's ID. +description: The details of an association between a product variant and an inventory item. x-schemaName: AdminProductVariantInventoryLink required: - - productService - - inventoryService + - Product + - Inventory properties: - productService: + Product: type: object - description: The id's productservice. + description: The id's product. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. - inventoryService: + description: The product's variant id. + Inventory: type: object - description: The id's inventoryservice. + description: The id's inventory. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The inventory's inventory item id. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml index ba2ab976f9c8f..377a954ac4d3b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml @@ -1,5 +1,7 @@ type: object -description: SUMMARY +description: >- + The details of the deleted associated between a product variant and an + inventory item. x-schemaName: AdminProductVariantInventoryLinkDeleteResponse required: - id @@ -13,9 +15,10 @@ properties: type: string title: object description: The name of the deleted object. + default: variant-inventory-item-link deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the association was deleted. parent: $ref: ./AdminProductVariant.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantParams.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantParams.yaml deleted file mode 100644 index 6ea415b06d846..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantParams.yaml +++ /dev/null @@ -1,872 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: AdminProductVariantParams -properties: - q: - type: string - title: q - description: The product's q. - id: - oneOf: - - type: string - title: id - description: The product's ID. - - type: array - description: The product's ID. - items: - type: string - title: id - description: The id's ID. - manage_inventory: - type: boolean - title: manage_inventory - description: The product's manage inventory. - allow_backorder: - type: boolean - title: allow_backorder - description: The product's allow backorder. - created_at: - type: object - description: The product's created at. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - - type: object - description: >- - Filter by values not matching the conditions in this - parameter. - - type: array - description: >- - Filter by values not matching the conditions in this - parameter. - items: - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for - numbers and dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. - Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers - and dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful - for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: >- - Apply a case-insensitive `like` filter. Useful for strings - only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: >- - Filter arrays that have overlapping values with this - parameter. - items: - type: string - title: $overlap - description: >- - Filter arrays that have overlapping values with this - parameter. - $contains: - type: array - description: >- - Filter arrays that contain some of the values of this - parameter. - items: - type: string - title: $contains - description: >- - Filter arrays that contain some of the values of this - parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: >- - Filter by whether a value for this parameter exists (not - `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for numbers and - dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. Useful for - numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers and - dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful for - numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - updated_at: - type: object - description: The product's updated at. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - - type: object - description: >- - Filter by values not matching the conditions in this - parameter. - - type: array - description: >- - Filter by values not matching the conditions in this - parameter. - items: - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for - numbers and dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. - Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers - and dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful - for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: >- - Apply a case-insensitive `like` filter. Useful for strings - only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: >- - Filter arrays that have overlapping values with this - parameter. - items: - type: string - title: $overlap - description: >- - Filter arrays that have overlapping values with this - parameter. - $contains: - type: array - description: >- - Filter arrays that contain some of the values of this - parameter. - items: - type: string - title: $contains - description: >- - Filter arrays that contain some of the values of this - parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: >- - Filter by whether a value for this parameter exists (not - `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for numbers and - dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. Useful for - numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers and - dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful for - numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - deleted_at: - type: object - description: The product's deleted at. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - - type: object - description: >- - Filter by values not matching the conditions in this - parameter. - - type: array - description: >- - Filter by values not matching the conditions in this - parameter. - items: - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for - numbers and dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. - Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers - and dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful - for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: >- - Apply a case-insensitive `like` filter. Useful for strings - only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: >- - Filter arrays that have overlapping values with this - parameter. - items: - type: string - title: $overlap - description: >- - Filter arrays that have overlapping values with this - parameter. - $contains: - type: array - description: >- - Filter arrays that contain some of the values of this - parameter. - items: - type: string - title: $contains - description: >- - Filter arrays that contain some of the values of this - parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: >- - Filter by whether a value for this parameter exists (not - `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for numbers and - dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. Useful for - numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers and - dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful for - numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - limit: - type: number - title: limit - description: The product's limit. - offset: - type: number - title: offset - description: The product's offset. - order: - type: string - title: order - description: The product's order. - fields: - type: string - title: fields - description: The product's fields. - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $or diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantResponse.yaml index cb5298721d273..8bd93d75bc8ab 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminProductVariantResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product variant's details. x-schemaName: AdminProductVariantResponse required: - variant diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPromotion.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPromotion.yaml index 2a31b4ded7704..641c56a02054b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminPromotion.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPromotion.yaml @@ -1,9 +1,14 @@ type: object -description: The promotion's details. +description: The application method's promotion. x-schemaName: AdminPromotion -required: - - id properties: + application_method: + $ref: ./AdminApplicationMethod.yaml + rules: + type: array + description: The promotion's rules. + items: + $ref: ./AdminPromotionRule.yaml id: type: string title: id @@ -13,25 +18,22 @@ properties: title: code description: The promotion's code. type: - type: string - description: The promotion's type. - enum: - - standard - - buyget + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. is_automatic: type: boolean title: is_automatic description: The promotion's is automatic. - application_method: - $ref: ./BaseApplicationMethod.yaml - rules: - type: array - description: The promotion's rules. - items: - $ref: ./BasePromotionRule.yaml campaign_id: type: string title: campaign_id description: The promotion's campaign id. campaign: $ref: ./AdminCampaign.yaml +required: + - id diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionResponse.yaml index 3a4255fe94ccb..76ea15b558505 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The promotion's details. x-schemaName: AdminPromotionResponse required: - promotion diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionRule.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionRule.yaml index 010bb3dc39cff..d791840b7b9be 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionRule.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminPromotionRule.yaml @@ -1,5 +1,5 @@ type: object -description: The updated's details. +description: The target rule's target rules. x-schemaName: AdminPromotionRule required: - id @@ -8,28 +8,40 @@ properties: id: type: string title: id - description: The updated's ID. + description: The target rule's ID. description: type: string title: description - description: The updated's description. + description: The target rule's description. attribute: type: string title: attribute - description: The updated's attribute. + description: The target rule's attribute. operator: - type: string - description: The updated's operator. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte + oneOf: + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. values: type: array - description: The updated's values. + description: The target rule's values. items: $ref: ./BasePromotionRuleValue.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRefund.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRefund.yaml new file mode 100644 index 0000000000000..229fb7729c5f3 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRefund.yaml @@ -0,0 +1,38 @@ +type: object +description: The refund's details. +x-schemaName: AdminRefund +required: + - id + - amount + - created_at + - payment +properties: + id: + type: string + title: id + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: + type: string + title: refund_reason_id + description: The ID of the refund reason. + note: + type: string + title: note + description: More details about the refund. + created_at: + type: string + format: date-time + title: created_at + description: The date the refund was created. + created_by: + type: string + title: created_by + description: The ID of the user that created the refund. + payment: + $ref: ./BasePayment.yaml + refund_reason: + $ref: ./RefundReason.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRefundReason.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRefundReason.yaml index 3110520654402..919bb56bfa28d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminRefundReason.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRefundReason.yaml @@ -22,14 +22,14 @@ properties: description: The refund reason's description. metadata: type: object - description: The refund reason's metadata. + description: The refund reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The refund reason's created at. + description: The date the refund reason was created. updated_at: type: string format: date-time title: updated_at - description: The refund reason's updated at. + description: The date the refund reason was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRegion.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRegion.yaml index 0ad92660d5479..96b6ff979c1fb 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminRegion.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRegion.yaml @@ -2,9 +2,9 @@ type: object description: The region's details. x-schemaName: AdminRegion required: - - id - name - currency_code + - id properties: id: type: string @@ -18,15 +18,16 @@ properties: type: string title: currency_code description: The region's currency code. + example: usd automatic_taxes: type: boolean title: automatic_taxes - description: The region's automatic taxes. + description: Whether taxes are applied automatically during checkout. countries: type: array description: The region's countries. items: - $ref: ./BaseRegionCountry.yaml + $ref: ./AdminRegionCountry.yaml payment_providers: type: array description: The region's payment providers. @@ -34,14 +35,14 @@ properties: $ref: ./AdminPaymentProvider.yaml metadata: type: object - description: The region's metadata. + description: The region's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The region's created at. + description: The date the region was created. updated_at: type: string format: date-time title: updated_at - description: The region's updated at. + description: The date the region was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRegionCountry.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRegionCountry.yaml index 04938da440014..88ca70090bc4a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminRegionCountry.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRegionCountry.yaml @@ -1,3 +1,33 @@ type: object -description: The billing address's country. +description: The country's details. x-schemaName: AdminRegionCountry +required: + - id +properties: + id: + type: string + title: id + description: The country's ID. + iso_2: + type: string + title: iso_2 + description: The country's iso 2. + example: us + iso_3: + type: string + title: iso_3 + description: The country's iso 3. + example: usa + num_code: + type: string + title: num_code + description: The country's num code. + example: 840 + name: + type: string + title: name + description: The country's name. + display_name: + type: string + title: display_name + description: The country's display name. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRegionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRegionResponse.yaml index fc2373ff7772d..390c84603e3cd 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminRegionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRegionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The region's details. x-schemaName: AdminRegionResponse required: - region diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReservation.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReservation.yaml index df021b64bdabe..2b75d1102d26b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReservation.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReservation.yaml @@ -9,7 +9,6 @@ required: - external_id - description - inventory_item_id - - inventory_item properties: id: type: string @@ -18,11 +17,11 @@ properties: line_item_id: type: string title: line_item_id - description: The reservation's line item id. + description: The ID of the line item this reservation is for. location_id: type: string title: location_id - description: The reservation's location id. + description: The ID of the location the quantity is reserved from. quantity: type: number title: quantity @@ -30,7 +29,7 @@ properties: external_id: type: string title: external_id - description: The reservation's external id. + description: An ID in an external system description: type: string title: description @@ -38,29 +37,28 @@ properties: inventory_item_id: type: string title: inventory_item_id - description: The reservation's inventory item id. + description: The ID of the inventory item this reservation is associated with. inventory_item: - type: object - description: The reservation's inventory item. + $ref: ./AdminInventoryItem.yaml metadata: type: object - description: The reservation's metadata. + description: The reservation's metadata, can hold custom key-value pairs. created_by: type: string title: created_by - description: The reservation's created by. + description: The ID of the user that created this reservation. deleted_at: type: string format: date-time title: deleted_at - description: The reservation's deleted at. + description: The date this reservation was deleted. created_at: type: string format: date-time title: created_at - description: The reservation's created at. + description: The date this reservation was created. updated_at: type: string format: date-time title: updated_at - description: The reservation's updated at. + description: The date this reservation was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReservationResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReservationResponse.yaml index 42075fd8acb40..4db926c72b924 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReservationResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReservationResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The reservation's details. x-schemaName: AdminReservationResponse required: - reservation diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturn.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturn.yaml index 0ef197d0f7301..ca7fb1ababe63 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturn.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturn.yaml @@ -1,12 +1,12 @@ type: object -description: The exchange's return. +description: The return's details. x-schemaName: AdminReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -15,14 +15,47 @@ properties: type: string title: id description: The return's ID. + status: + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + description: The return's status. + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. order_id: type: string title: order_id - description: The return's order id. - status: + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: ./AdminReturnItem.yaml + created_at: type: string - title: status - description: The return's status. + format: date-time + title: created_at + description: The date the return was created. + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time exchange_id: type: string title: exchange_id @@ -47,25 +80,7 @@ properties: type: boolean title: no_notification description: The return's no notification. - refund_amount: - type: number - title: refund_amount - description: The return's refund amount. - items: - type: array - description: The return's items. - items: - $ref: ./BaseReturnItem.yaml received_at: type: string title: received_at description: The return's received at. - created_at: - type: string - format: date-time - title: created_at - description: The return's created at. - canceled_at: - type: string - title: canceled_at - description: The return's canceled at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnItem.yaml index 47cbe93e16f7f..f9f5bb9346c85 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnItem.yaml @@ -1,5 +1,5 @@ type: object -description: The return item's return items. +description: The item's items. x-schemaName: AdminReturnItem required: - id @@ -20,27 +20,31 @@ properties: received_quantity: type: number title: received_quantity - description: The return item's received quantity. + description: >- + The received quantity of the item. This quantity is added to the stocked + inventory quantity of the item. damaged_quantity: type: number title: damaged_quantity - description: The return item's damaged quantity. + description: >- + The received damaged quantity of the item, which isn't added to the + stocked inventory quantity of the item. reason_id: type: string title: reason_id - description: The return item's reason id. + description: The ID of the return reason associated with the item. note: type: string title: note - description: The return item's note. + description: A note about why the item was returned. item_id: type: string title: item_id - description: The return item's item id. + description: The ID of the associated order item. return_id: type: string title: return_id - description: The return item's return id. + description: The ID of the return this return item belongs to. metadata: type: object - description: The return item's metadata. + description: The return item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnPreviewResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnPreviewResponse.yaml index 8b8734b2fec9f..a7958ba7deaf4 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnPreviewResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnPreviewResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of a return and a preview of the order once the return is applied. x-schemaName: AdminReturnPreviewResponse required: - order_preview diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReason.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReason.yaml index 3046e2a2544f0..7de3166b718f4 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReason.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReason.yaml @@ -26,14 +26,14 @@ properties: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonDeleteResponse.yaml index 37435266107f8..7d69be5a278e2 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the return reason deletion. x-schemaName: AdminReturnReasonDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Return Reason was deleted. + description: Whether the return reason was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonListResponse.yaml index 0fa69fc5170aa..4f931ef219226 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of return reasons. x-schemaName: AdminReturnReasonListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The return reason's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The return reason's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The return reason's count. + description: The total number of items. return_reasons: type: array - description: The return reason's return reasons. + description: The list of return reasons. items: $ref: ./AdminReturnReason.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonResponse.yaml index 9b3ad0f9a4daa..513915d0c32b5 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnReasonResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return reason's details. x-schemaName: AdminReturnReasonResponse required: - return_reason diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnResponse.yaml index 8ce9535394aa6..3e0fe4d159b32 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminReturnResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminReturnResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return's details. x-schemaName: AdminReturnResponse required: - return diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRevokeApiKey.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRevokeApiKey.yaml index 7e99903e5bdc1..af00ccb2fefc7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminRevokeApiKey.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRevokeApiKey.yaml @@ -1,8 +1,10 @@ type: object -description: SUMMARY +description: The details of revoking the API key. x-schemaName: AdminRevokeApiKey properties: revoke_in: type: number title: revoke_in - description: The api key's revoke in. + description: >- + The time in seconds to revoke the API key after. If not set, the API key + is revoked immediately. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRuleAttributeOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRuleAttributeOption.yaml index 8ca5eaabf397a..53359ab0b48c0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminRuleAttributeOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRuleAttributeOption.yaml @@ -1,39 +1,27 @@ type: object -description: The attribute's attributes. +description: The details of a potential rule attribute. x-schemaName: AdminRuleAttributeOption required: - id - value - label - - field_type - - required - - disguised - operators properties: id: type: string title: id - description: The attribute's ID. + description: The rule attribute's ID, which is a rule's `attribute` it refers to. + example: customer_group value: type: string title: value - description: The attribute's value. + description: The rule attribute's value. + example: customer.groups.id label: type: string title: label - description: The attribute's label. - field_type: - type: string - title: field_type - description: The attribute's field type. - required: - type: boolean - title: required - description: The attribute's required. - disguised: - type: boolean - title: disguised - description: The attribute's disguised. + description: The rule attribute option's label. + example: Customer Group operators: type: array description: The attribute's operators. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminRuleValueOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminRuleValueOption.yaml index cb8776ea83d6a..fbfa2d15c8019 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminRuleValueOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminRuleValueOption.yaml @@ -1,20 +1,17 @@ type: object -description: The value's values. +description: The details of a potential rule value. x-schemaName: AdminRuleValueOption required: - - id - value - label properties: - id: - type: string - title: id - description: The value's ID. value: type: string title: value - description: The value's details. + description: The rule value's value. + example: reg_123 label: type: string title: label - description: The value's label. + description: The rule value's label. + example: Europe Region diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannel.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannel.yaml index 9b497e936cc5a..2311a9b68784f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannel.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannel.yaml @@ -1,5 +1,5 @@ type: object -description: The order's sales channel. +description: The sales channel's details. x-schemaName: AdminSalesChannel required: - id @@ -26,22 +26,22 @@ properties: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The sales channel's created at. + description: The date the sales channel was created. updated_at: type: string format: date-time title: updated_at - description: The sales channel's updated at. + description: The date the sales channel was updated. deleted_at: type: string format: date-time title: deleted_at - description: The sales channel's deleted at. + description: The date the sales channel was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelDeleteResponse.yaml index fc933220020fc..0c2d3161a8fdb 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of deleting a sales channel. x-schemaName: AdminSalesChannelDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Sales Channel was deleted. + description: Whether the sales channel was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelResponse.yaml index baeb779f03e8c..bd930a26a7707 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminSalesChannelResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The sales channel's details. x-schemaName: AdminSalesChannelResponse required: - sales_channel diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZone.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZone.yaml index d0dff34efce40..425c15722a3bc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZone.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZone.yaml @@ -1,5 +1,5 @@ type: object -description: The service zone's service zones. +description: The shipping option's service zone. x-schemaName: AdminServiceZone required: - id diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneDeleteResponse.yaml index 488b2b6081228..7f3224a4326c8 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the service zone deletion. x-schemaName: AdminServiceZoneDeleteResponse required: - id @@ -9,14 +9,15 @@ properties: id: type: string title: id - description: The fulfillment set's ID. + description: The service zone's ID. object: type: string title: object description: The name of the deleted object. + default: service_zone deleted: type: boolean title: deleted - description: Whether the Fulfillment Set was deleted. + description: Whether the service zone was deleted. parent: $ref: ./AdminFulfillmentSet.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneResponse.yaml index dd8ff8c8d163b..32685446d39e1 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminServiceZoneResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The service zone's details. x-schemaName: AdminServiceZoneResponse required: - service_zone diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOption.yaml index 219dac6bdc583..9129f3bec1db6 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOption.yaml @@ -1,3 +1,105 @@ type: object -description: The shipping option's shipping options. +description: The shipping option's details. x-schemaName: AdminShippingOption +required: + - id + - name + - price_type + - service_zone_id + - service_zone + - provider_id + - provider + - shipping_option_type_id + - type + - shipping_profile_id + - shipping_profile + - rules + - prices + - data + - metadata + - created_at + - updated_at + - deleted_at +properties: + id: + type: string + title: id + description: The shipping option's ID. + name: + type: string + title: name + description: The shipping option's name. + price_type: + type: string + description: >- + The shipping option's price type. If it's `flat`, the price is fixed and + is set in the `prices` property. If it's `calculated`, the price is + calculated on checkout by the associated fulfillment provider. + enum: + - calculated + - flat + service_zone_id: + type: string + title: service_zone_id + description: The ID of the service zone this option belongs to. + service_zone: + type: object + provider_id: + type: string + title: provider_id + description: >- + The ID of the provider handling fulfillments created from this shipping + option. + provider: + $ref: ./AdminFulfillmentProvider.yaml + shipping_option_type_id: + type: string + title: shipping_option_type_id + description: The ID of the associated shipping option type. + type: + type: object + shipping_profile_id: + type: string + title: shipping_profile_id + description: The ID of the associated shipping profile. + shipping_profile: + $ref: ./AdminShippingProfile.yaml + rules: + type: array + description: The shipping option's rules. + items: + $ref: ./AdminShippingOptionRule.yaml + prices: + type: array + description: >- + The shipping option's prices. If the `price_type` is `calculated`, this + array will be empty since the price is calculated by the fulfillment + provider during checkout. + items: + $ref: ./AdminShippingOptionPrice.yaml + data: + type: object + description: >- + The shipping option's data, useful for the fulfillment provider handling + fulfillments created from this option. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping option's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping option was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping option was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping option was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionDeleteResponse.yaml index 141ba6526b478..459667c5ec1af 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the shipping option's deletion. x-schemaName: AdminShippingOptionDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Shipping Option was deleted. + description: Whether the shipping option was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionPrice.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionPrice.yaml new file mode 100644 index 0000000000000..95f76292c0a8d --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionPrice.yaml @@ -0,0 +1,76 @@ +type: object +description: The details of the shipping option's price. +x-schemaName: AdminShippingOptionPrice +required: + - price_rules + - rules_count + - id + - title + - currency_code + - amount + - raw_amount + - min_quantity + - max_quantity + - price_set_id + - created_at + - updated_at + - deleted_at +properties: + price_rules: + type: array + description: The price's rules. + items: + $ref: ./AdminShippingOptionPriceRule.yaml + rules_count: + type: number + title: rules_count + description: The number of rules the price has. + id: + type: string + title: id + description: The price's ID. + title: + type: string + title: title + description: The price's title. + currency_code: + type: string + title: currency_code + description: The price's currency code. + example: usd + amount: + type: number + title: amount + description: The price's amount. + raw_amount: + type: object + description: The price's raw amount. + min_quantity: + type: number + title: min_quantity + description: The minimum quantity required in the cart for this price to apply. + max_quantity: + type: number + title: max_quantity + description: >- + The maximum quantity that the cart's items must not surpass for this price + to apply. + price_set_id: + type: string + title: price_set_id + description: The ID of the price set this price belongs to. + created_at: + type: string + format: date-time + title: created_at + description: The date the price was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the price was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the price was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionPriceRule.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionPriceRule.yaml new file mode 100644 index 0000000000000..a705731a4197d --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionPriceRule.yaml @@ -0,0 +1,15 @@ +type: object +description: The details of a shipping option price's rule. +x-schemaName: AdminShippingOptionPriceRule +required: + - id + - value +properties: + id: + type: string + title: id + description: The price rule's ID. + value: + type: string + title: value + description: The price rule's value. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionResponse.yaml index dba509d7fdc79..b0b01a94abe0d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The shipping option's details. x-schemaName: AdminShippingOptionResponse required: - shipping_option diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionRule.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionRule.yaml index ed10fb27e4cb2..26069d9a56e62 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionRule.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingOptionRule.yaml @@ -1,5 +1,5 @@ type: object -description: The updated's details. +description: The shipping option rule's details. x-schemaName: AdminShippingOptionRule required: - id @@ -14,42 +14,46 @@ properties: id: type: string title: id - description: The updated's ID. + description: The shipping option rule's ID. attribute: type: string title: attribute - description: The updated's attribute. + description: The shipping option rule's attribute. + example: is_return operator: type: string title: operator - description: The updated's operator. + description: The shipping option rule's operator. + example: eq value: oneOf: - type: string title: value - description: The updated's value. + description: The rule's value. + example: '"true"' - type: array - description: The updated's value. + description: The rule's values. items: type: string title: value - description: The value's details. + description: A rule's value + example: '"true"' shipping_option_id: type: string title: shipping_option_id - description: The updated's shipping option id. + description: The ID of the shipping option this rule is for. created_at: type: string format: date-time title: created_at - description: The updated's created at. + description: The date the shipping option rule was created. updated_at: type: string format: date-time title: updated_at - description: The updated's updated at. + description: The date the shipping option rule was updated. deleted_at: type: string format: date-time title: deleted_at - description: The updated's deleted at. + description: The date the shipping option rule was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfile.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfile.yaml index 29549d5ff2633..1dc31c1b5b70d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfile.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfile.yaml @@ -1,3 +1,42 @@ type: object -description: The shipping option's shipping profile. +description: The shipping profile's details.. x-schemaName: AdminShippingProfile +properties: + id: + type: string + title: id + description: The shipping profile's ID. + name: + type: string + title: name + description: The shipping profile's name. + type: + type: string + title: type + description: The shipping profile's type. + metadata: + type: object + description: The shipping profile's metadata, holds custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping profile was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping profile was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping profile was deleted. +required: + - id + - name + - type + - metadata + - created_at + - updated_at + - deleted_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileDeleteResponse.yaml index bca17d5e8b882..ed0e931fd6bd0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the shipping profile's deletion. x-schemaName: AdminShippingProfileDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Shipping Profile was deleted. + description: Whether the shipping profile was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileResponse.yaml index ce83a083726fc..00fa3dc1ab3a9 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminShippingProfileResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The shipping profile's details. x-schemaName: AdminShippingProfileResponse required: - shipping_profile diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocation.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocation.yaml index 76f80ec99cb78..238431cd5415c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocation.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocation.yaml @@ -1,5 +1,5 @@ type: object -description: The parent's location. +description: The stock location's details. x-schemaName: AdminStockLocation required: - id @@ -17,21 +17,71 @@ properties: address_id: type: string title: address_id - description: The location's address id. + description: The ID of the associated address. address: - $ref: ./AdminStockLocationAddress.yaml + type: object + description: The details of the stock location address. + x-schemaName: AdminStockLocationAddress + properties: + id: + type: string + title: id + description: The address's ID. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + company: + type: string + title: company + description: The address's company. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + city: + type: string + title: city + description: The address's city. + phone: + type: string + title: phone + description: The address's phone. + postal_code: + type: string + title: postal_code + description: The address's postal code. + province: + type: string + title: province + description: The address's province. + required: + - id + - address_1 + - address_2 + - company + - country_code + - city + - phone + - postal_code + - province sales_channels: type: array - description: The location's sales channels. + description: The sales channels associated with the location. items: $ref: ./AdminSalesChannel.yaml fulfillment_providers: type: array - description: The location's fulfillment providers. + description: The fulfillment providers associated with the location. items: $ref: ./AdminFulfillmentProvider.yaml fulfillment_sets: type: array - description: The location's fulfillment sets. + description: The fulfillment sets associated with the location. items: type: object diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationAddress.yaml deleted file mode 100644 index 03be8aa3dde15..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationAddress.yaml +++ /dev/null @@ -1,3 +0,0 @@ -type: object -description: The location's address. -x-schemaName: AdminStockLocationAddress diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationDeleteResponse.yaml index 7d1160157d94b..cb05f2704ae3f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the stock location's deletion. x-schemaName: AdminStockLocationDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Stock Location was deleted. + description: Whether the stock location was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationListResponse.yaml index f8181758b16a2..9f23c060601a1 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of stock locations. x-schemaName: AdminStockLocationListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The stock location's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The stock location's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The stock location's count. + description: The total number of items. stock_locations: type: array - description: The stock location's stock locations. + description: The list of stock locations. items: $ref: ./AdminStockLocation.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationResponse.yaml index 68d6a4db180db..19f1d66a39eac 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStockLocationResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The stock location's details. x-schemaName: AdminStockLocationResponse required: - stock_location diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStore.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStore.yaml index a56500fc7b544..32f483dc82209 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStore.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStore.yaml @@ -28,25 +28,25 @@ properties: default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the sales channel used by default in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the region used by default in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the stock location used by default in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The store's created at. + description: The date the store was created. updated_at: type: string format: date-time title: updated_at - description: The store's updated at. + description: The date the store was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStoreCurrency.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStoreCurrency.yaml index 5014c7b7bce22..a0e2ccb92dd8d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStoreCurrency.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStoreCurrency.yaml @@ -1,5 +1,5 @@ type: object -description: The supported currency's supported currencies. +description: The details of a store's currency. x-schemaName: AdminStoreCurrency required: - id @@ -14,33 +14,34 @@ properties: id: type: string title: id - description: The supported currency's ID. + description: The currency's ID. currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd store_id: type: string title: store_id - description: The supported currency's store id. + description: The ID of the store this currency belongs to. is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether this currency is the default in the store. currency: $ref: ./AdminCurrency.yaml created_at: type: string format: date-time title: created_at - description: The supported currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The supported currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The supported currency's deleted at. + description: The date the currency was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStoreListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStoreListResponse.yaml index 33099c28f179f..639f93778b8d0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStoreListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStoreListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of stores. x-schemaName: AdminStoreListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The store's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The store's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The store's count. + description: The total number of items. stores: type: array - description: The store's stores. + description: The list of stores. items: $ref: ./AdminStore.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminStoreResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminStoreResponse.yaml index c24cc35690d2f..d335ebde9825e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminStoreResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminStoreResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The store's details. x-schemaName: AdminStoreResponse required: - store diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRate.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRate.yaml index f0321f56518be..7972123ffef44 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRate.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRate.yaml @@ -1,5 +1,5 @@ type: object -description: The tax rate's parent. +description: The tax rate's details. x-schemaName: AdminTaxRate required: - id @@ -20,57 +20,61 @@ properties: id: type: string title: id - description: The parent's ID. + description: The tax rate's ID. rate: type: number title: rate - description: The parent's rate. + description: The rate to charge. + example: 10 code: type: string title: code - description: The parent's code. + description: The code the tax rate is identified by. name: type: string title: name - description: The parent's name. + description: The tax rate's name. metadata: type: object - description: The parent's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. tax_region_id: type: string title: tax_region_id - description: The parent's tax region id. + description: The ID of the tax region this rate belongs to. is_combinable: type: boolean title: is_combinable - description: The parent's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates is_default: type: boolean title: is_default - description: The parent's is default. + description: Whether this tax rate is the default in the tax region. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the tax rate was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the tax rate was updated. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The date the tax rate was deleted. created_by: type: string title: created_by - description: The parent's created by. + description: The ID of the user that created the tax rate. tax_region: $ref: ./AdminTaxRegion.yaml rules: type: array - description: The parent's rules. + description: The tax rate's rules. items: $ref: ./AdminTaxRateRule.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateDeleteResponse.yaml index 6c284786d9db4..88c4b0ebb1d6f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the tax rate deletion. x-schemaName: AdminTaxRateDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Tax Rate was deleted. + description: Whether the tax rate was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateResponse.yaml index 2dd828e446d57..e4888f9c3a00a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The tax rate's details. x-schemaName: AdminTaxRateResponse required: - tax_rate diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateRule.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateRule.yaml index 8e0ff14b5d49a..2d88ad2ed823a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateRule.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRateRule.yaml @@ -1,5 +1,5 @@ type: object -description: The rule's rules. +description: The tax rate rule's details. x-schemaName: AdminTaxRateRule required: - reference @@ -8,8 +8,10 @@ properties: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of a record in the table that this rule references. + example: ptyp_1 diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegion.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegion.yaml index 5ee5e6b8e004a..0c5867f445ed9 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegion.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegion.yaml @@ -1,17 +1,11 @@ type: object -description: The parent's tax region. +description: The tax region's details. x-schemaName: AdminTaxRegion required: - id - - rate - - code - country_code - province_code - - name - metadata - - tax_region_id - - is_combinable - - is_default - parent_id - created_at - updated_at @@ -25,67 +19,44 @@ properties: type: string title: id description: The tax region's ID. - rate: - type: number - title: rate - description: The tax region's rate. - code: - type: string - title: code - description: The tax region's code. country_code: type: string title: country_code description: The tax region's country code. + example: us province_code: type: string title: province_code description: The tax region's province code. - name: - type: string - title: name - description: The tax region's name. metadata: type: object - description: The tax region's metadata. - tax_region_id: - type: string - title: tax_region_id - description: The tax region's tax region id. - is_combinable: - type: boolean - title: is_combinable - description: The tax region's is combinable. - is_default: - type: boolean - title: is_default - description: The tax region's is default. + description: The tax region's metadata, can hold custom key-value pairs. parent_id: type: string title: parent_id - description: The tax region's parent id. + description: The ID of the parent tax region. created_at: type: string format: date-time title: created_at - description: The tax region's created at. + description: The date the tax region was created. updated_at: type: string format: date-time title: updated_at - description: The tax region's updated at. + description: The date the tax region was updated. deleted_at: type: string format: date-time title: deleted_at - description: The tax region's deleted at. + description: The date the tax region was deleted. created_by: type: string title: created_by - description: The tax region's created by. + description: The ID of the user that created the tax region. tax_rates: type: array - description: The tax region's tax rates. + description: The tax region's rates. items: type: object parent: diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionDeleteResponse.yaml index 235dd86a80390..be8ab35c7c3fe 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the tax region deletion. x-schemaName: AdminTaxRegionDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Tax Region was deleted. + description: Whether the tax region was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionResponse.yaml index 0c200e26d0597..b1cfcf7062d15 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminTaxRegionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The tax region's details. x-schemaName: AdminTaxRegionResponse required: - tax_region diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateApiKey.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateApiKey.yaml index 1858893589b52..2f9911872eda1 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateApiKey.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateApiKey.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in an API key. x-schemaName: AdminUpdateApiKey required: - title @@ -7,4 +7,4 @@ properties: title: type: string title: title - description: The api key's title. + description: The API key's title. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCollection.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCollection.yaml index 22a9be4f57e8c..63cfe987d02d7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCollection.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCollection.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in a collection. x-schemaName: AdminUpdateCollection properties: title: @@ -12,4 +12,4 @@ properties: description: The collection's handle. metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCustomerGroup.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCustomerGroup.yaml index acb0253445aa2..57fb90e7151e6 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCustomerGroup.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateCustomerGroup.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in a customer group. x-schemaName: AdminUpdateCustomerGroup properties: name: @@ -8,4 +8,4 @@ properties: description: The customer group's name. metadata: type: object - description: The customer group's metadata. + description: The customer group's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePriceList.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePriceList.yaml index 97688d7c5f612..50737f5decd5b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePriceList.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePriceList.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: the details to update in a price list. x-schemaName: AdminUpdatePriceList properties: title: @@ -13,23 +13,36 @@ properties: starts_at: type: string title: starts_at - description: The price list's starts at. + description: The date the price list starts. ends_at: type: string title: ends_at - description: The price list's ends at. + description: The date the price list ends. status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. + example: + customer_group_id: + - cusgrp_123 diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePricePreference.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePricePreference.yaml index 0c5f879d8fba9..cc04155d197cd 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePricePreference.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdatePricePreference.yaml @@ -1,16 +1,18 @@ type: object -description: SUMMARY +description: The details to update in the price preference. x-schemaName: AdminUpdatePricePreference properties: attribute: type: string title: attribute description: The price preference's attribute. + example: region_id value: type: string title: value description: The price preference's value. + example: reg_123 is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The price preference's is tax inclusive. + description: Whether prices are tax inclusive for this price preference. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProduct.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProduct.yaml index 844455161e607..23a5ed5cc947b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProduct.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProduct.yaml @@ -1,70 +1,77 @@ type: object -description: The update's details. +description: The product's details. x-schemaName: AdminUpdateProduct properties: title: type: string title: title - description: The update's title. + description: The product's title. subtitle: type: string title: subtitle - description: The update's subtitle. + description: The product's subtitle. description: type: string title: description - description: The update's description. + description: The product's description. is_giftcard: type: boolean title: is_giftcard - description: The update's is giftcard. + description: Whether the product is a gift card. discountable: type: boolean title: discountable - description: The update's discountable. + description: Whether discounts can be applied on the product. images: type: array - description: The update's images. + description: The product's images. items: type: object - description: The image's images. + description: The image's details. required: - url properties: url: type: string title: url - description: The image's url. + description: The image's URL. thumbnail: type: string title: thumbnail - description: The update's thumbnail. + description: The product's thumbnail URL. handle: type: string title: handle - description: The update's handle. + description: The product's unique handle. status: - type: string - description: The update's status. - enum: - - draft - - proposed - - published - - rejected + oneOf: + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + description: The product's status. type_id: type: string title: type_id - description: The update's type id. + description: The ID of the product's type. collection_id: type: string title: collection_id - description: The update's collection id. + description: The ID of the product's collection. categories: type: array - description: The update's categories. + description: The product's categories. items: type: object - description: The category's categories. + description: The product's category. required: - id properties: @@ -74,10 +81,10 @@ properties: description: The category's ID. tags: type: array - description: The update's tags. + description: The product's tags. items: type: object - description: The tag's tags. + description: The product's tag. required: - id properties: @@ -87,181 +94,24 @@ properties: description: The tag's ID. options: type: array - description: The update's options. + description: The product's options. items: $ref: ./AdminUpdateProductOption.yaml variants: type: array - description: The update's variants. + description: >- + The product's variants. You can add new variants or update existing ones, + passing their IDs in the object. items: oneOf: - - type: object - description: The variant's variants. - x-schemaName: AdminCreateProductVariant - required: - - title - - prices - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: ./AdminCreateProductVariantPrice.yaml - options: - type: object - description: The variant's options. - - type: object - description: The variant's variants. - x-schemaName: AdminUpdateProductVariant - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: ./AdminCreateProductVariantPrice.yaml - options: - type: object - description: The variant's options. + - $ref: ./AdminCreateProductVariant.yaml + - $ref: ./AdminUpdateProductVariant.yaml sales_channels: type: array - description: The update's sales channels. + description: The sales channels that the product is available in. items: type: object - description: The sales channel's sales channels. + description: The sales channel's details. required: - id properties: @@ -272,35 +122,35 @@ properties: weight: type: number title: weight - description: The update's weight. + description: The product's weight. length: type: number title: length - description: The update's length. + description: The product's length. height: type: number title: height - description: The update's height. + description: The product's height. width: type: number title: width - description: The update's width. + description: The product's width. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product's MID code. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product's origin country. material: type: string title: material - description: The update's material. + description: The product's material. metadata: type: object - description: The update's metadata. + description: The product's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductOption.yaml index bfdca1a5cba73..046aa998154fc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductOption.yaml @@ -1,15 +1,15 @@ type: object -description: SUMMARY +description: The details to update in a product option. x-schemaName: AdminUpdateProductOption properties: title: type: string title: title - description: The product's title. + description: The option's title. values: type: array - description: The product's values. + description: The option's values. items: type: string title: values - description: The value's values. + description: An option value. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductVariant.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductVariant.yaml index c0429b85e9364..59f99cff83c1d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductVariant.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateProductVariant.yaml @@ -1,79 +1,81 @@ type: object -description: The update's details. +description: The properties to update of a product variant. x-schemaName: AdminUpdateProductVariant properties: title: type: string title: title - description: The update's title. + description: The product variant's title. sku: type: string title: sku - description: The update's sku. + description: The product variant's SKU. ean: type: string title: ean - description: The update's ean. + description: The product variant's EAN. upc: type: string title: upc - description: The update's upc. + description: The product variant's UPC. barcode: type: string title: barcode - description: The update's barcode. + description: The product variant's barcode. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product variant's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product variant's MID code. allow_backorder: type: boolean title: allow_backorder - description: The update's allow backorder. + description: Whether customers can order the variant even if it's not in stock. manage_inventory: type: boolean title: manage_inventory - description: The update's manage inventory. + description: >- + Whether the Medusa application manages the variant's inventory. If + disabled, the product variant is always considered in stock. variant_rank: type: number title: variant_rank - description: The update's variant rank. + description: The product variant's rank among its siblings. weight: type: number title: weight - description: The update's weight. + description: The product variant's weight. length: type: number title: length - description: The update's length. + description: The product variant's length. height: type: number title: height - description: The update's height. + description: The product variant's height. width: type: number title: width - description: The update's width. + description: The product variant's width. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product variant's origin country. material: type: string title: material - description: The update's material. + description: The product variant's material. metadata: type: object - description: The update's metadata. + description: The product variant's metadata, can hold custom key-value pairs. prices: type: array - description: The update's prices. + description: The product variant's prices. items: $ref: ./AdminCreateProductVariantPrice.yaml options: type: object - description: The update's options. + description: The product variant's options. diff --git a/www/apps/api-reference/specs/admin/components/schemas/UpdateOrderReturnReason.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateReturnReason.yaml similarity index 62% rename from www/apps/api-reference/specs/admin/components/schemas/UpdateOrderReturnReason.yaml rename to www/apps/api-reference/specs/admin/components/schemas/AdminUpdateReturnReason.yaml index 581ad731dc89d..3299988196d04 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/UpdateOrderReturnReason.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateReturnReason.yaml @@ -1,11 +1,7 @@ type: object -description: SUMMARY -x-schemaName: UpdateOrderReturnReason +description: The details to update in a return reason. +x-schemaName: AdminUpdateReturnReason properties: - id: - type: string - title: id - description: The return reason's ID. label: type: string title: label @@ -20,4 +16,7 @@ properties: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. +required: + - value + - label diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateSalesChannel.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateSalesChannel.yaml index 8f30103306950..db5e76e560aa0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateSalesChannel.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateSalesChannel.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in the sales channel. x-schemaName: AdminUpdateSalesChannel properties: name: @@ -13,7 +13,7 @@ properties: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStockLocation.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStockLocation.yaml index 2312fd5e3c4cd..936fe6f522958 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStockLocation.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStockLocation.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in a stock location. x-schemaName: AdminUpdateStockLocation properties: name: @@ -8,7 +8,9 @@ properties: description: The stock location's name. address: type: object - description: The stock location's address. + description: >- + The stock location's address. Pass this property if you're creating a new + address to associate with the location. required: - address_1 - country_code @@ -16,11 +18,11 @@ properties: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -33,6 +35,7 @@ properties: type: string title: country_code description: The address's country code. + example: us phone: type: string title: phone @@ -48,7 +51,9 @@ properties: address_id: type: string title: address_id - description: The stock location's address id. + description: >- + The ID of an existing stock location address to associate the stock + location with. metadata: type: object - description: The stock location's metadata. + description: The stock location's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStore.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStore.yaml index 7df88b6bc0fb4..e8c4463b52cdc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStore.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateStore.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in a store. x-schemaName: AdminUpdateStore properties: name: @@ -11,34 +11,35 @@ properties: description: The store's supported currencies. items: type: object - description: The supported currency's supported currencies. + description: A store currency. required: - currency_code properties: currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether the currency is the default in the store. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The supported currency's is tax inclusive. + description: Whether prices using this currency are tax inclusive. default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the default sales channel in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the default region in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the default stock location in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateTaxRate.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateTaxRate.yaml index 5580cc1ef659f..8000de42a91c3 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateTaxRate.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateTaxRate.yaml @@ -1,21 +1,21 @@ type: object -description: SUMMARY +description: The properties to update in the tax rate. x-schemaName: AdminUpdateTaxRate properties: rate: type: number title: rate - description: The tax rate's rate. + description: The rate to charge. code: type: string title: code - description: The tax rate's code. + description: The code that the tax rate is identified by. rules: type: array description: The tax rate's rules. items: type: object - description: The rule's rules. + description: A tax rate rule. required: - reference - reference_id @@ -23,11 +23,13 @@ properties: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of the record in the table that the rule references. + example: ptyp_123 name: type: string title: name @@ -35,11 +37,14 @@ properties: is_default: type: boolean title: is_default - description: The tax rate's is default. + description: Whether the tax rate is the default in the store. is_combinable: type: boolean title: is_combinable - description: The tax rate's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates metadata: type: object - description: The tax rate's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateUser.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateUser.yaml index 1d1bd54d5aba2..2fc8ed46f581e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateUser.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateUser.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in a user. x-schemaName: AdminUpdateUser properties: first_name: @@ -13,4 +13,4 @@ properties: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateVariantInventoryItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateVariantInventoryItem.yaml index 8db01d8c4c5cd..b61c9d020f124 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateVariantInventoryItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpdateVariantInventoryItem.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update of the variant's inventory item association. x-schemaName: AdminUpdateVariantInventoryItem required: - required_quantity @@ -7,4 +7,10 @@ properties: required_quantity: type: number title: required_quantity - description: The product's required quantity. + description: >- + The number of units a single quantity is equivalent to. For example, if a + customer orders one quantity of the variant, Medusa checks the + availability of the quantity multiplied by the value set for + `required_quantity`. When the customer orders the quantity, Medusa + reserves the ordered quantity multiplied by the value set for + `required_quantity`. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUpsertStockLocationAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUpsertStockLocationAddress.yaml index b0e8d7c0332b6..5c265c5e0e898 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUpsertStockLocationAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUpsertStockLocationAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The stock location's address. +description: The details of the stock location address to create. x-schemaName: AdminUpsertStockLocationAddress required: - address_1 @@ -8,11 +8,11 @@ properties: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -21,6 +21,7 @@ properties: type: string title: country_code description: The address's country code. + example: usd city: type: string title: city diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUser.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUser.yaml index 6fb258123e254..c3bca505cb895 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUser.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUser.yaml @@ -32,22 +32,22 @@ properties: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. metadata: type: object - description: The user's metadata. + description: The user's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The user's created at. + description: The date the user was created. updated_at: type: string format: date-time title: updated_at - description: The user's updated at. + description: The date the user was updated. deleted_at: type: string format: date-time title: deleted_at - description: The user's deleted at. + description: The date the user was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUserDeleteResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUserDeleteResponse.yaml index fb9888ff23788..72ede85811657 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUserDeleteResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUserDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the deleted user. x-schemaName: AdminUserDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the User was deleted. + description: Whether the user was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUserListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUserListResponse.yaml index 7aac88724afa2..e595dad0cd6f0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUserListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUserListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of users. x-schemaName: AdminUserListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The user's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The user's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The user's count. + description: The total number of items. users: type: array - description: The user's users. + description: The list of users. items: $ref: ./AdminUser.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUserResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUserResponse.yaml index dfc78e1bc996d..ed4678e0a0cac 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUserResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUserResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The user's details. x-schemaName: AdminUserResponse required: - user diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecution.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecution.yaml index 1c803655b9926..c71f1c4364f3b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecution.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecution.yaml @@ -1,5 +1,5 @@ type: object -description: The workflows execution's workflow execution. +description: The workflows execution's details. x-schemaName: AdminWorkflowExecution required: - id @@ -18,11 +18,11 @@ properties: workflow_id: type: string title: workflow_id - description: The workflow execution's workflow id. + description: The ID of the workflow. transaction_id: type: string title: transaction_id - description: The workflow execution's transaction id. + description: The workflow execution's transaction ID. execution: $ref: ./AdminWorkflowExecutionExecution.yaml context: @@ -42,14 +42,14 @@ properties: type: string format: date-time title: created_at - description: The workflow execution's created at. + description: The date the workflow execution was created. updated_at: type: string format: date-time title: updated_at - description: The workflow execution's updated at. + description: The date the workflow execution was updated. deleted_at: type: string format: date-time title: deleted_at - description: The workflow execution's deleted at. + description: The date the workflow execution was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionExecution.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionExecution.yaml index e589756af2294..6b780c9e0abab 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionExecution.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionExecution.yaml @@ -1,9 +1,152 @@ type: object -description: The workflow execution's execution. +description: The workflow execution's steps details. x-schemaName: AdminWorkflowExecutionExecution required: - steps properties: steps: type: object - description: The execution's steps. + description: >- + The execution's steps. Each object key is a step ID, and the value is the + object whose properties are shown below. + required: + - id + - invoke + - definition + - compensate + - depth + - startedAt + additionalProperties: + type: object + properties: + id: + type: string + title: id + description: The step's ID. + invoke: + type: object + description: The state of the step's invokation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The invokation step's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The invokation step's state. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + definition: + type: object + description: The step's definition details. + x-schemaName: WorkflowExecutionDefinition + properties: + async: + type: boolean + title: async + description: Whether the step is async. + compensateAsync: + type: boolean + title: compensateAsync + description: Whether the compensation function of the step is async. + noCompensation: + type: boolean + title: noCompensation + description: Whether the step doesn't have a compensation function. + continueOnPermanentFailure: + type: boolean + title: continueOnPermanentFailure + description: >- + Whether the step continues executing even if its status is + changed to failed. + maxRetries: + type: number + title: maxRetries + description: The maximum number of times to retry the step. + noWait: + type: boolean + title: noWait + description: >- + Whether the workflow shouldn't wait for the step to finish + before moving to the next step. + default: false + retryInterval: + type: number + title: retryInterval + description: >- + The interval in seconds between retry attempts when the step + fails. + retryIntervalAwaiting: + type: number + title: retryIntervalAwaiting + description: >- + The interval in seconds to retry a step even if its status is + `waiting_response`. + saveResponse: + type: boolean + title: saveResponse + description: Whether the step's response is stored. + timeout: + type: number + title: timeout + description: >- + The maximum time in seconds to wait for this step to complete. + If the step exceeds this time, the step's state is changed to + `timeout`, but the step continues executing. + compensate: + type: object + description: The state of the step's compensation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The compensation function's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The compensation function's status. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + depth: + type: number + title: depth + description: The step's depth in the workflow's execution. + startedAt: + type: number + title: startedAt + description: The timestamp the step started executing. diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionResponse.yaml index 2c21bd3e4e1ac..c57cb857d135a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminWorkflowExecutionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The workflow execution's details. x-schemaName: AdminWorkflowExecutionResponse required: - workflow_execution diff --git a/www/apps/api-reference/specs/admin/components/schemas/ApiKeyResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/ApiKeyResponse.yaml index df83ca78ffa72..f5de0a21507a8 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/ApiKeyResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/ApiKeyResponse.yaml @@ -1,5 +1,5 @@ type: object -description: The api key's details. +description: The API key's details. x-schemaName: ApiKeyResponse required: - id @@ -16,44 +16,50 @@ properties: id: type: string title: id - description: The api key's ID. + description: The API key's ID. token: type: string title: token - description: The api key's token. + description: The API key's token. redacted: type: string title: redacted - description: The api key's redacted. + description: >- + The redacted form of the API key's token. This is useful when showing + portion of the token. For example `sk_...123`. title: type: string title: title - description: The api key's title. + description: The API key's title. type: type: string + description: >- + The API key's type. `secret` API keys are used for authenticating admin + users, and `publishable` API key are used for storefronts and similar + clients to scope requests to sales channels. enum: - secret - publishable last_used_at: type: string title: last_used_at - description: The api key's last used at. + description: The date the API key was last used. format: date-time created_by: type: string title: created_by - description: The api key's created by. + description: The ID of the user that created the API key. created_at: type: string title: created_at - description: The api key's created at. + description: The date the API key was created. format: date-time revoked_by: type: string title: revoked_by - description: The api key's revoked by. + description: The ID of the user that revoked the API key. revoked_at: type: string title: revoked_at - description: The api key's revoked at. + description: The date the API key was revoked. format: date-time diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseApplicationMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseApplicationMethod.yaml deleted file mode 100644 index 4e1e727e4aa27..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseApplicationMethod.yaml +++ /dev/null @@ -1,61 +0,0 @@ -type: object -description: The promotion's application method. -x-schemaName: BaseApplicationMethod -required: - - id -properties: - id: - type: string - title: id - description: The application method's ID. - type: - type: string - description: The application method's type. - enum: - - fixed - - percentage - target_type: - type: string - description: The application method's target type. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: The application method's allocation. - enum: - - each - - across - value: - type: number - title: value - description: The application method's value. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: The application method's max quantity. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: The application method's buy rules min quantity. - apply_to_quantity: - type: number - title: apply_to_quantity - description: The application method's apply to quantity. - promotion: - $ref: ./BasePromotion.yaml - target_rules: - type: array - description: The application method's target rules. - items: - $ref: ./BasePromotionRule.yaml - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: ./BasePromotionRule.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCalculatedPriceSet.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCalculatedPriceSet.yaml index 70dd7bf660f95..b4fea699491a1 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCalculatedPriceSet.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCalculatedPriceSet.yaml @@ -50,6 +50,60 @@ properties: calculated_price: type: object description: The calculated price's details. + properties: + id: + type: string + title: id + description: The calculated price's ID. + price_list_id: + type: string + title: price_list_id + description: The calculated price's price list id. + price_list_type: + type: string + title: price_list_type + description: The calculated price's price list type. + min_quantity: + type: number + title: min_quantity + description: The calculated price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The calculated price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity original_price: type: object description: The calculated price's original price. + properties: + id: + type: string + title: id + description: The original price's ID. + price_list_id: + type: string + title: price_list_id + description: The original price's price list id. + price_list_type: + type: string + title: price_list_type + description: The original price's price list type. + min_quantity: + type: number + title: min_quantity + description: The original price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The original price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCapture.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCapture.yaml index 59baa7033c5fc..a4456a306cf53 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCapture.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCapture.yaml @@ -1,3 +1,28 @@ type: object -description: The capture's captures. +description: The details of a captured payment. x-schemaName: BaseCapture +required: + - id + - amount + - created_at + - payment +properties: + id: + type: string + title: id + description: The payment capture's ID. + amount: + type: number + title: amount + description: The captured amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the capture was created. + created_by: + type: string + title: created_by + description: The ID of the user that captured the payment. + payment: + type: object diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCart.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCart.yaml index 5cc50d1e73587..5ba46f61aa6af 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCart.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCart.yaml @@ -1,3 +1,173 @@ type: object description: The item's cart. x-schemaName: BaseCart +required: + - id + - currency_code + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + id: + type: string + title: id + description: The cart's ID. + region: + $ref: ./BaseRegion.yaml + region_id: + type: string + title: region_id + description: The cart's region id. + customer_id: + type: string + title: customer_id + description: The cart's customer id. + sales_channel_id: + type: string + title: sales_channel_id + description: The cart's sales channel id. + email: + type: string + title: email + description: The cart's email. + format: email + currency_code: + type: string + title: currency_code + description: The cart's currency code. + shipping_address: + $ref: ./BaseCartAddress.yaml + billing_address: + $ref: ./BaseCartAddress.yaml + items: + type: array + description: The cart's items. + items: + type: object + shipping_methods: + type: array + description: The cart's shipping methods. + items: + $ref: ./BaseCartShippingMethod.yaml + payment_collection: + $ref: ./BasePaymentCollection.yaml + metadata: + type: object + description: The cart's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The cart's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The cart's updated at. + original_item_total: + type: number + title: original_item_total + description: The cart's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The cart's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The cart's original item tax total. + item_total: + type: number + title: item_total + description: The cart's item total. + item_subtotal: + type: number + title: item_subtotal + description: The cart's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The cart's item tax total. + original_total: + type: number + title: original_total + description: The cart's original total. + original_subtotal: + type: number + title: original_subtotal + description: The cart's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The cart's original tax total. + total: + type: number + title: total + description: The cart's total. + subtotal: + type: number + title: subtotal + description: The cart's subtotal. + tax_total: + type: number + title: tax_total + description: The cart's tax total. + discount_total: + type: number + title: discount_total + description: The cart's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The cart's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The cart's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The cart's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The cart's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The cart's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The cart's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The cart's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The cart's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The cart's original shipping tax total. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCartAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCartAddress.yaml index 0cc3faf4c1611..e85cfd8a57da6 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCartAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCartAddress.yaml @@ -1,69 +1,3 @@ type: object -description: The parent's billing address. +description: The cart's shipping address. x-schemaName: BaseCartAddress -required: - - id - - created_at - - updated_at -properties: - id: - type: string - title: id - description: The billing address's ID. - customer_id: - type: string - title: customer_id - description: The billing address's customer id. - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: - type: string - title: last_name - description: The billing address's last name. - phone: - type: string - title: phone - description: The billing address's phone. - company: - type: string - title: company - description: The billing address's company. - address_1: - type: string - title: address_1 - description: The billing address's address 1. - address_2: - type: string - title: address_2 - description: The billing address's address 2. - city: - type: string - title: city - description: The billing address's city. - country_code: - type: string - title: country_code - description: The billing address's country code. - province: - type: string - title: province - description: The billing address's province. - postal_code: - type: string - title: postal_code - description: The billing address's postal code. - metadata: - type: object - description: The billing address's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The billing address's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The billing address's updated at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCartLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCartLineItem.yaml index 01d92160309eb..b2e59d962110c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCartLineItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCartLineItem.yaml @@ -1,5 +1,5 @@ type: object -description: The item's items. +description: The tax line's item. x-schemaName: BaseCartLineItem required: - id @@ -40,17 +40,9 @@ properties: title: thumbnail description: The item's thumbnail. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: ./IBigNumber.yaml + type: number + title: quantity + description: The item's quantity. product: $ref: ./BaseProduct.yaml product_id: @@ -115,34 +107,18 @@ properties: title: is_tax_inclusive description: The item's is tax inclusive. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: ./IBigNumber.yaml + type: number + title: compare_at_unit_price + description: The item's compare at unit price. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: ./IBigNumber.yaml + type: number + title: unit_price + description: The item's unit price. tax_lines: type: array description: The item's tax lines. items: - $ref: ./BaseLineItemTaxLine.yaml + type: object adjustments: type: array description: The item's adjustments. @@ -173,134 +149,46 @@ properties: title: deleted_at description: The item's deleted at. original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The item's original total. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The item's original subtotal. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The item's original tax total. item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: ./IBigNumber.yaml + type: number + title: item_total + description: The item's item total. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: item_subtotal + description: The item's item subtotal. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: item_tax_total + description: The item's item tax total. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The item's total. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The item's subtotal. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The item's tax total. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The item's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The item's discount tax total. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCartShippingMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCartShippingMethod.yaml index 6f613ecf88bd6..95520cd96fe0c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCartShippingMethod.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCartShippingMethod.yaml @@ -1,5 +1,5 @@ type: object -description: The shipping method's shipping methods. +description: A cart's shipping method. x-schemaName: BaseCartShippingMethod required: - id @@ -25,7 +25,7 @@ properties: cart_id: type: string title: cart_id - description: The shipping method's cart id. + description: The ID of the cart this shipping method belongs to. name: type: string title: name @@ -35,31 +35,28 @@ properties: title: description description: The shipping method's description. amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: ./IBigNumber.yaml + type: number + title: amount + description: The shipping method's amount. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount is tax inclusive. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: >- + The shipping method's data, useful for fulfillment handling by third-party + services. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -67,112 +64,52 @@ properties: $ref: ./BaseShippingMethodTaxLine.yaml adjustments: type: array - description: The shipping method's adjustments. + description: The shipping method's adjustments, such as applied promotions. items: $ref: ./BaseShippingMethodAdjustment.yaml created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The shipping method's total amount including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The total amount discounted. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseClaim.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseClaim.yaml deleted file mode 100644 index 85d6a02519dbd..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseClaim.yaml +++ /dev/null @@ -1,3 +0,0 @@ -type: object -description: The order change's claim. -x-schemaName: BaseClaim diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseClaimItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseClaimItem.yaml index 27c9efe9968e9..fe407754bed6c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseClaimItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseClaimItem.yaml @@ -1,5 +1,5 @@ type: object -description: The claim item's claim items. +description: The claim item's details. x-schemaName: BaseClaimItem required: - id @@ -17,22 +17,22 @@ properties: claim_id: type: string title: claim_id - description: The claim item's claim id. + description: The ID of the claim this item belongs to. order_id: type: string title: order_id - description: The claim item's order id. + description: The ID of the order this item belongs to. item_id: type: string title: item_id - description: The claim item's item id. + description: The ID of the item in the order. quantity: type: number title: quantity - description: The claim item's quantity. + description: The quantity claimed. reason: type: string - description: The claim item's reason. + description: The claim's reason. enum: - missing_item - wrong_item @@ -40,17 +40,28 @@ properties: - other raw_quantity: type: object - description: The claim item's raw quantity. + description: The quantity claimed. + properties: + value: + oneOf: + - type: string + title: value + description: The raw quantity's value. + - type: number + title: value + description: The raw quantity's value. + required: + - value metadata: type: object - description: The claim item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The claim item's created at. + description: The date the claim was created. updated_at: type: string format: date-time title: updated_at - description: The claim item's updated at. + description: The date the claim was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCollection.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCollection.yaml index 19efac7da22bb..6b7390021c631 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCollection.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCollection.yaml @@ -1,3 +1,3 @@ type: object -description: The product's collection. +description: The collection's details. x-schemaName: BaseCollection diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseCustomerAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseCustomerAddress.yaml index 906bc9231dd22..c894dbf6d0cbb 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseCustomerAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseCustomerAddress.yaml @@ -1,3 +1,97 @@ type: object -description: The address's addresses. +description: The customer's address. x-schemaName: BaseCustomerAddress +required: + - id + - address_name + - is_default_shipping + - is_default_billing + - customer_id + - company + - first_name + - last_name + - address_1 + - address_2 + - city + - country_code + - province + - postal_code + - phone + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The address's ID. + address_name: + type: string + title: address_name + description: The address's name. + is_default_shipping: + type: boolean + title: is_default_shipping + description: Whether the address is the default shipping address. + is_default_billing: + type: boolean + title: is_default_billing + description: Whether the address is the default billing address. + customer_id: + type: string + title: customer_id + description: The ID of the customer that this address belongs to. + company: + type: string + title: company + description: The customer's company. + first_name: + type: string + title: first_name + description: The customer's first name. + last_name: + type: string + title: last_name + description: The customer's last name. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + city: + type: string + title: city + description: The address's city. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + province: + type: string + title: province + description: The address's province. + postal_code: + type: string + title: postal_code + description: The address's postal code. + phone: + type: string + title: phone + description: The address's phone. + metadata: + type: object + description: The address's metadata, used to store custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The address's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The address's update date. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseExchangeItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseExchangeItem.yaml index 852b2e0a94599..82c98c6dbf2f4 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseExchangeItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseExchangeItem.yaml @@ -1,5 +1,5 @@ type: object -description: The additional item's additional items. +description: The item's details. x-schemaName: BaseExchangeItem required: - id @@ -13,33 +13,33 @@ properties: id: type: string title: id - description: The additional item's ID. + description: The item's ID. exchange_id: type: string title: exchange_id - description: The additional item's exchange id. + description: The ID of the exchange this item belongs to. order_id: type: string title: order_id - description: The additional item's order id. + description: The ID of the order this item belongs to. item_id: type: string title: item_id - description: The additional item's item id. + description: The ID of the item in the order. quantity: type: number title: quantity - description: The additional item's quantity. + description: The item's quantity. metadata: type: object - description: The additional item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The additional item's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The additional item's updated at. + description: The date the item was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseFulfillmentProvider.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseFulfillmentProvider.yaml deleted file mode 100644 index 5cddd56a8992b..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseFulfillmentProvider.yaml +++ /dev/null @@ -1,15 +0,0 @@ -type: object -description: The shipping option's provider. -x-schemaName: BaseFulfillmentProvider -required: - - id - - is_enabled -properties: - id: - type: string - title: id - description: The provider's ID. - is_enabled: - type: boolean - title: is_enabled - description: The provider's is enabled. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemAdjustment.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemAdjustment.yaml index 5b5a104b310a6..af9b884de8cdf 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemAdjustment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The adjustment's details. x-schemaName: BaseLineItemAdjustment +properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: + type: string + title: cart_id + description: The ID of the cart this adjustment belongs to. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. +required: + - item + - item_id + - id + - amount + - cart_id + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemTaxLine.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemTaxLine.yaml index 1fdd8bf379ec7..63946d4c1ff10 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemTaxLine.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseLineItemTaxLine.yaml @@ -1,3 +1,62 @@ type: object -description: The tax line's tax lines. +description: The tax line's details x-schemaName: BaseLineItemTaxLine +properties: + item: + $ref: ./BaseCartLineItem.yaml + item_id: + type: string + title: item_id + description: The ID of the item the tax line applies on. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the associated tax rate. + code: + type: string + title: code + description: The code the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. +required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrder.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrder.yaml index 09579fa8dd9dc..2b2d4962a6d59 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrder.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrder.yaml @@ -1,3 +1,238 @@ type: object -description: The order change's order. +description: The order's details. x-schemaName: BaseOrder +required: + - payment_collections + - id + - version + - region_id + - customer_id + - sales_channel_id + - email + - currency_code + - items + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + payment_collections: + type: array + description: The order's payment collections. + items: + $ref: ./AdminPaymentCollection.yaml + fulfillments: + type: array + description: The order's fulfillments. + items: + $ref: ./BaseOrderFulfillment.yaml + sales_channel: + $ref: ./AdminSalesChannel.yaml + customer: + $ref: ./AdminCustomer.yaml + shipping_address: + $ref: ./AdminOrderAddress.yaml + billing_address: + $ref: ./AdminOrderAddress.yaml + id: + type: string + title: id + description: The order's ID. + version: + type: number + title: version + description: The order's version. + region_id: + type: string + title: region_id + description: The ID of the region associated with the order. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the order is placed in. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The order's currency code. + display_id: + type: number + title: display_id + description: The order's display ID. + items: + type: array + description: The order's items. + items: + $ref: ./BaseOrderLineItem.yaml + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: ./BaseOrderShippingMethod.yaml + payment_status: + type: string + description: The order's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillment_status: + type: string + description: The order's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The order's transactions. + items: + $ref: ./BaseOrderTransaction.yaml + summary: + $ref: ./BaseOrderSummary.yaml + metadata: + type: object + description: The order's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the order was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the order's items including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The total of the order's items excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the order's items excluding promotions. + item_total: + type: number + title: item_total + description: The total of the order's items including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The total of the order's items excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order's items including promotions. + original_total: + type: number + title: original_total + description: The order's total excluding promotions, including taxes. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The order's tax total, excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The order's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The order's discount or promotions total. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total of order's discount or promotion. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The tax total of the order's gift card. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The tax total of the order's shipping. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The tax total of the order's shipping excluding promotions. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderAddress.yaml index f1896707cdb35..ffdb3358489ac 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The exchange's billing address. +description: An order address x-schemaName: BaseOrderAddress required: - id @@ -10,61 +10,64 @@ properties: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer this address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us + country: + $ref: ./AdminRegionCountry.yaml province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. + description: The date the address was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderChange.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderChange.yaml deleted file mode 100644 index dc086f2f8e5bf..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderChange.yaml +++ /dev/null @@ -1,146 +0,0 @@ -type: object -description: The order preview's order change. -x-schemaName: BaseOrderChange -required: - - id - - order_id - - actions - - status - - requested_by - - requested_at - - confirmed_by - - confirmed_at - - declined_by - - declined_reason - - metadata - - declined_at - - canceled_by - - canceled_at - - created_at - - updated_at - - version - - return_id - - exchange_id - - claim_id - - order - - return_order - - exchange - - claim -properties: - id: - type: string - title: id - description: The order change's ID. - order_id: - type: string - title: order_id - description: The order change's order id. - actions: - type: array - description: The order change's actions. - items: - $ref: ./BaseOrderChangeAction.yaml - status: - type: string - title: status - description: The order change's status. - requested_by: - type: string - title: requested_by - description: The order change's requested by. - requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time - confirmed_by: - type: string - title: confirmed_by - description: The order change's confirmed by. - confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time - declined_by: - type: string - title: declined_by - description: The order change's declined by. - declined_reason: - type: string - title: declined_reason - description: The order change's declined reason. - metadata: - type: object - description: The order change's metadata. - declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time - canceled_by: - type: string - title: canceled_by - description: The order change's canceled by. - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time - created_at: - type: string - format: date-time - title: created_at - description: The order change's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The order change's updated at. - version: - type: number - title: version - description: The order change's version. - change_type: - type: string - description: The order change's change type. - enum: - - return - - exchange - - claim - - edit - - return_request - return_id: - type: string - title: return_id - description: The order change's return id. - exchange_id: - type: string - title: exchange_id - description: The order change's exchange id. - claim_id: - type: string - title: claim_id - description: The order change's claim id. - order: - $ref: ./BaseOrder.yaml - return_order: {} - exchange: {} - claim: - $ref: ./BaseClaim.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderChangeAction.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderChangeAction.yaml index 91725525beead..a38543eec2523 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderChangeAction.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderChangeAction.yaml @@ -1,3 +1,85 @@ type: object description: The action's actions. x-schemaName: BaseOrderChangeAction +properties: + order_change: + $ref: ./AdminOrderChange.yaml + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change this action belongs to. + order_id: + type: string + title: order_id + description: The ID of the associated order. + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + title: action + description: The applied action. + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the order change action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change action was updated. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + $ref: ./BaseOrder.yaml +required: + - order_change + - id + - order_change_id + - order_id + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at + - return_id + - claim_id + - exchange_id + - order diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderFulfillment.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderFulfillment.yaml index 513f2f9f6a8e8..12970b6fe2310 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderFulfillment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderFulfillment.yaml @@ -22,48 +22,53 @@ properties: location_id: type: string title: location_id - description: The fulfillment's location id. + description: The ID of the location the items are fulfilled from. packed_at: type: string title: packed_at - description: The fulfillment's packed at. + description: The date the items were packed. format: date-time shipped_at: type: string title: shipped_at - description: The fulfillment's shipped at. + description: The date the items were shipped. format: date-time delivered_at: type: string title: delivered_at - description: The fulfillment's delivered at. + description: The date the items were delivered. format: date-time canceled_at: type: string title: canceled_at - description: The fulfillment's canceled at. + description: The date the items were canceled. format: date-time data: type: object - description: The fulfillment's data. + description: >- + Data useful for the fulfillment provider handling it. This is taken from + the associated shipping option. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property provider_id: type: string title: provider_id - description: The fulfillment's provider id. + description: The ID of the fulfillment provider used to handle the fulfillment. shipping_option_id: type: string title: shipping_option_id - description: The fulfillment's shipping option id. + description: The ID of the associated shipping option. metadata: type: object - description: The fulfillment's metadata. + description: The fulfillment's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The fulfillment's created at. + description: The date the fulfillment was created. updated_at: type: string format: date-time title: updated_at - description: The fulfillment's updated at. + description: The date the fulfillment was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderItemDetail.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderItemDetail.yaml index 0a1f9eb14ddaf..fe8730e0bdaa2 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderItemDetail.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderItemDetail.yaml @@ -1,3 +1,79 @@ type: object description: The item's detail. x-schemaName: BaseOrderItemDetail +required: + - id + - item_id + - item + - quantity + - fulfilled_quantity + - delivered_quantity + - shipped_quantity + - return_requested_quantity + - return_received_quantity + - return_dismissed_quantity + - written_off_quantity + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: the detail's ID. + item_id: + type: string + title: id + description: the ID of the associated line item. + item: + $ref: ./BaseOrderLineItem.yaml + quantity: + type: number + title: quantity + description: The item's quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + delivered_quantity: + type: number + title: fulfilled_quantity + description: The item's delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + return_received_quantity: + type: number + title: return_received_quantity + description: >- + The item's quantity that's returned and added to the underlying variant's + stocked quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: >- + The item's quantity that's returned but damaged. So, it's not added to the + underlying variant's stocked quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed from the order. + metadata: + type: object + title: metadata + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the detail was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the detail was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItem.yaml index ecf54b1785d60..f69a00e2163c5 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItem.yaml @@ -56,19 +56,19 @@ properties: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The URL of the item's thumbnail. variant: $ref: ./BaseProductVariant.yaml variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated variant. product: $ref: ./BaseProduct.yaml product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -88,7 +88,7 @@ properties: product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the collection the item's product belongs to. product_handle: type: string title: product_handle @@ -96,7 +96,7 @@ properties: variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -107,23 +107,25 @@ properties: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The values of the item variant's options. + example: + Color: Blue requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item is tax inclusive. compare_at_unit_price: type: number title: compare_at_unit_price - description: The item's compare at unit price. + description: The original price of the item before a promotion or sale. unit_price: type: number title: unit_price @@ -148,64 +150,64 @@ properties: type: string format: date-time title: created_at - description: The item's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The item's updated at. + description: The date the item was updated. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. original_total: type: number title: original_total - description: The item's original total. + description: The item's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The item's original subtotal. + description: The item's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The item's original tax total. + description: The total taxes of the item, excluding promotions. item_total: type: number title: item_total - description: The item's item total. + description: The total taxes of the item, including promotions. item_subtotal: type: number title: item_subtotal - description: The item's item subtotal. + description: The item's total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The item's item tax total. + description: The total taxes of the item, including promotions. total: type: number title: total - description: The item's total. + description: The item's total, including taxes and promotions. subtotal: type: number title: subtotal - description: The item's subtotal. + description: The item's subtotal excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The item's tax total. + description: The tax total of the item including promotions. discount_total: type: number title: discount_total - description: The item's discount total. + description: The total discount amount of the item. discount_tax_total: type: number title: discount_tax_total - description: The item's discount tax total. + description: The total taxes applied on the discounted amount. refundable_total: type: number title: refundable_total - description: The item's refundable total. + description: The total refundable amount of the item's total. refundable_total_per_unit: type: number title: refundable_total_per_unit - description: The item's refundable total per unit. + description: The total refundable amount of the item's total for a single quantity. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemAdjustment.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemAdjustment.yaml index a4f81ce94f20a..8bc04e5fdd718 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemAdjustment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The adjustment's details. x-schemaName: BaseOrderLineItemAdjustment +properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies to. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion that this applies on the order's item. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. +required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemTaxLine.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemTaxLine.yaml index 213da9382db4f..b9bf8070c077e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemTaxLine.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderLineItemTaxLine.yaml @@ -1,3 +1,62 @@ type: object description: The tax line's tax lines. x-schemaName: BaseOrderLineItemTaxLine +properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the associated line item. + total: + type: number + title: total + description: The tax line's total including promotions. + subtotal: + type: number + title: subtotal + description: The tax line's subtotal excluding promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax line. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. +required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingDetail.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingDetail.yaml new file mode 100644 index 0000000000000..372c5ed40dae7 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingDetail.yaml @@ -0,0 +1,42 @@ +type: object +description: The shipping method's detail. +x-schemaName: BaseOrderShippingDetail +required: + - id + - shipping_method_id + - shipping_method + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The detail's ID. + shipping_method_id: + type: string + title: shipping_method_id + description: The detail's shipping method id. + shipping_method: + $ref: ./BaseOrderShippingMethod.yaml + claim_id: + type: string + title: claim_id + description: The detail's claim id. + exchange_id: + type: string + title: exchange_id + description: The detail's exchange id. + return_id: + type: string + title: return_id + description: The detail's return id. + created_at: + type: string + format: date-time + title: created_at + description: The detail's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The detail's updated at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethod.yaml index 4357db37d7414..930352a943340 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethod.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethod.yaml @@ -1,5 +1,5 @@ type: object -description: The shipping method's shipping methods. +description: The shipping method's details. x-schemaName: BaseOrderShippingMethod required: - id @@ -28,7 +28,7 @@ properties: order_id: type: string title: order_id - description: The shipping method's order id. + description: The ID of the order the shipping method belongs to. name: type: string title: name @@ -44,17 +44,22 @@ properties: is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount includes applied taxes. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: >- + The shipping method's data, useful for fulfillment provider handling its + fulfillment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -66,108 +71,46 @@ properties: items: $ref: ./BaseOrderShippingMethodAdjustment.yaml original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The shipping method's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The shipping method's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The total discounts applied on the shipping method. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. + detail: + $ref: ./BaseOrderShippingDetail.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodAdjustment.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodAdjustment.yaml index 0d458f73fadbd..59eec5e5eb1de 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodAdjustment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodAdjustment.yaml @@ -1,3 +1,56 @@ type: object description: The adjustment's adjustments. x-schemaName: BaseOrderShippingMethodAdjustment +properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment applies on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. +required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodTaxLine.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodTaxLine.yaml index 3cce6d21b0c04..96102bb4add21 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodTaxLine.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderShippingMethodTaxLine.yaml @@ -1,3 +1,62 @@ type: object -description: The tax line's tax lines. +description: The tax line's details. x-schemaName: BaseOrderShippingMethodTaxLine +properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this tax line belongs to. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider handling the tax calculation. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. +required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderSummary.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderSummary.yaml index 395346dc23ecd..26db0db078bdd 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderSummary.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderSummary.yaml @@ -1,5 +1,5 @@ type: object -description: The order's summary. +description: The order's summary details. x-schemaName: BaseOrderSummary required: - total @@ -10,71 +10,46 @@ required: - returned_total - return_request_total - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - paid_total - refunded_total properties: total: type: number title: total - description: The summary's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The summary's subtotal. + description: The order's total excluding taxes, including promotions. total_tax: type: number title: total_tax - description: The summary's total tax. + description: The order's total taxes. ordered_total: type: number title: ordered_total - description: The summary's ordered total. + description: The order's total when it was placed. fulfilled_total: type: number title: fulfilled_total - description: The summary's fulfilled total. + description: The total of the fulfilled items of the order. returned_total: type: number title: returned_total - description: The summary's returned total. + description: The total of the order's returned items. return_request_total: type: number title: return_request_total - description: The summary's return request total. + description: The total of the items requested to be returned. write_off_total: type: number title: write_off_total - description: The summary's write off total. - projected_total: - type: number - title: projected_total - description: The summary's projected total. - net_total: - type: number - title: net_total - description: The summary's net total. - net_subtotal: - type: number - title: net_subtotal - description: The summary's net subtotal. - net_total_tax: - type: number - title: net_total_tax - description: The summary's net total tax. - balance: - type: number - title: balance - description: The summary's balance. + description: The total of the items removed from the order. paid_total: type: number title: paid_total - description: The summary's paid total. + description: The total amount paid. refunded_total: type: number title: refunded_total - description: The summary's refunded total. + description: The total amount refunded. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderTransaction.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderTransaction.yaml index 8abf8cfd58a68..f822566df95f8 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseOrderTransaction.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseOrderTransaction.yaml @@ -1,5 +1,5 @@ type: object -description: The transaction's transactions. +description: An order transaction's details. x-schemaName: BaseOrderTransaction required: - id @@ -19,7 +19,7 @@ properties: order_id: type: string title: order_id - description: The transaction's order id. + description: The ID of the order this transaction belongs to. amount: type: number title: amount @@ -28,24 +28,31 @@ properties: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: >- + The name of a table that this transaction references. If this transaction + is for captured payment, its value is `capture`. If this transaction is + for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. metadata: type: object - description: The transaction's metadata. + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. + description: The date that the transaction was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BasePayment.yaml b/www/apps/api-reference/specs/admin/components/schemas/BasePayment.yaml index 6171436ba768d..86305baabf688 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BasePayment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BasePayment.yaml @@ -1,3 +1,93 @@ type: object -description: The payment's payments. +description: The payment's details. x-schemaName: BasePayment +required: + - id + - amount + - currency_code + - provider_id +properties: + id: + type: string + title: id + description: The payment's ID. + amount: + type: number + title: amount + description: The payment's amount. + authorized_amount: + type: number + title: authorized_amount + description: The amount authorized of the payment. + currency_code: + type: string + title: currency_code + description: The payment's currency code. + provider_id: + type: string + title: provider_id + description: The ID of the payment provider used to process this payment. + cart_id: + type: string + title: cart_id + description: The ID of the associated cart. + order_id: + type: string + title: order_id + description: The ID of the associated order. + order_edit_id: + type: string + title: order_edit_id + description: The ID of the associated order edit. + customer_id: + type: string + title: customer_id + description: ID of the associated customer. + data: + type: object + description: The payment's data, useful for processing by the payment provider. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment#whats-a-payment + created_at: + type: string + format: date-time + title: created_at + description: The date the payment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the payment was updated. + captured_at: + type: string + format: date-time + title: captured_at + description: The date the payment was captured. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the payment was canceled. + captured_amount: + type: number + title: captured_amount + description: The captured amount of the payment. + refunded_amount: + type: number + title: captured_amount + description: The refunded amount of the payment. + captures: + type: array + description: The details of payment captures. + items: + $ref: ./BaseCapture.yaml + refunds: + type: array + description: The details of payment refunds. + items: + $ref: ./BaseRefund.yaml + payment_collection: + type: object + payment_session: + type: object diff --git a/www/apps/api-reference/specs/admin/components/schemas/BasePaymentCollection.yaml b/www/apps/api-reference/specs/admin/components/schemas/BasePaymentCollection.yaml index 309583af20943..8ee4e76804fa9 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BasePaymentCollection.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BasePaymentCollection.yaml @@ -1,5 +1,5 @@ type: object -description: The payment collection's payment collections. +description: The payment collection's details. x-schemaName: BasePaymentCollection required: - id @@ -20,77 +20,41 @@ properties: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: ./IBigNumber.yaml + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: ./IBigNumber.yaml + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: ./IBigNumber.yaml + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: ./IBigNumber.yaml + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -102,7 +66,9 @@ properties: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: >- + The payment provider used to process the collection's payments and + sessions. items: $ref: ./BasePaymentProvider.yaml payment_sessions: diff --git a/www/apps/api-reference/specs/admin/components/schemas/BasePaymentProvider.yaml b/www/apps/api-reference/specs/admin/components/schemas/BasePaymentProvider.yaml index 2266f0a8ea987..2b73a963fbe9a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BasePaymentProvider.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BasePaymentProvider.yaml @@ -1,3 +1,10 @@ type: object description: The payment provider's payment providers. x-schemaName: BasePaymentProvider +required: + - id +properties: + id: + type: string + title: id + description: The payment provider's ID. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BasePaymentSession.yaml b/www/apps/api-reference/specs/admin/components/schemas/BasePaymentSession.yaml index f0c1e2603ad1f..33533c274e3c9 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BasePaymentSession.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BasePaymentSession.yaml @@ -1,3 +1,61 @@ type: object -description: The payment session's payment sessions. +description: The payment session's details. x-schemaName: BasePaymentSession +properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: >- + The payment session's data, useful for the payment provider processing the + payment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: ./BasePayment.yaml +required: + - id + - amount + - currency_code + - provider_id + - data + - status diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseProductImage.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseProductImage.yaml index cbabec460947e..f1e59ad937a5e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseProductImage.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseProductImage.yaml @@ -1,3 +1,33 @@ type: object -description: The image's images. +description: The image's details. x-schemaName: BaseProductImage +properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's URL. + created_at: + type: string + format: date-time + title: created_at + description: The date the image was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. +required: + - id + - url diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseProductOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseProductOption.yaml index 91105a54c2c06..152999bb1ca54 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseProductOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseProductOption.yaml @@ -1,3 +1,44 @@ type: object -description: The option's options. +description: The product option's details. x-schemaName: BaseProductOption +properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + type: object + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: ./BaseProductOptionValue.yaml + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. +required: + - id + - title diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseProductOptionValue.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseProductOptionValue.yaml index a607fba792761..0fe30515bbf4e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseProductOptionValue.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseProductOptionValue.yaml @@ -1,39 +1,3 @@ type: object -description: The option's options. +description: The product option value's details. x-schemaName: BaseProductOptionValue -required: - - id - - value -properties: - id: - type: string - title: id - description: The option's ID. - value: - type: string - title: value - description: The option's value. - option: - $ref: ./BaseProductOption.yaml - option_id: - type: string - title: option_id - description: The option's option id. - metadata: - type: object - description: The option's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The option's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The option's updated at. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The option's deleted at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseProductVariant.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseProductVariant.yaml index 559318d70ea04..28af9e6fe9ddb 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseProductVariant.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseProductVariant.yaml @@ -1,3 +1,132 @@ type: object -description: The variant's variants. +description: The product variant's details. x-schemaName: BaseProductVariant +required: + - id + - title + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory + - hs_code + - origin_country + - mid_code + - material + - weight + - length + - height + - width + - options + - created_at + - updated_at + - deleted_at +properties: + id: + type: string + title: id + description: The variant's ID. + title: + type: string + title: title + description: The variant's title. + sku: + type: string + title: sku + description: The variant's SKU. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's EAN code. + upc: + type: string + title: upc + description: The variant's UPC. + allow_backorder: + type: boolean + title: allow_backorder + description: Whether the variant can be ordered even if it's out of stock. + manage_inventory: + type: boolean + title: manage_inventory + description: >- + Whether the Medusa application manages the variant's inventory quantity + and availablility. If disabled, the variant is always considered in stock. + inventory_quantity: + type: number + title: inventory_quantity + description: >- + The variant's inventory quantity. This is only included if you pass in the + `fields` query parameter a `+variants.inventory_quantity` parameter. + hs_code: + type: string + title: hs_code + description: The variant's HS code. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + mid_code: + type: string + title: mid_code + description: The variant's MID code. + material: + type: string + title: material + description: The variant's material. + weight: + type: number + title: weight + description: The variant's weight. + length: + type: number + title: length + description: The variant's length. + height: + type: number + title: height + description: The variant's height. + width: + type: number + title: width + description: The variant's width. + variant_rank: + type: number + title: variant_rank + description: The variant's rank among its sibling variants. + options: + type: array + description: The variant's option values. + items: + $ref: ./BaseProductOptionValue.yaml + product: + type: object + product_id: + type: string + title: product_id + description: The ID of the product that the variant belongs to. + calculated_price: + $ref: ./BaseCalculatedPriceSet.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the variant was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the variant was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the variant was deleted. + metadata: + type: object + description: The variant's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseRefund.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseRefund.yaml index 50d12fb0f9e74..9a8cf9183925e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseRefund.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseRefund.yaml @@ -1,3 +1,38 @@ type: object -description: The refund's refunds. +description: The refund's details. x-schemaName: BaseRefund +required: + - id + - amount + - created_at + - payment +properties: + id: + type: string + title: id + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: + type: string + title: refund_reason_id + description: The ID of the refund reason. + note: + type: string + title: note + description: More details about the refund. + created_at: + type: string + format: date-time + title: created_at + description: The date the refund was created. + created_by: + type: string + title: created_by + description: The ID of the user that created the refund. + payment: + type: object + refund_reason: + $ref: ./RefundReason.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseRegion.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseRegion.yaml index 778b10a689f9b..370a7c2f9fa93 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseRegion.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseRegion.yaml @@ -1,47 +1,3 @@ type: object description: The parent's region. x-schemaName: BaseRegion -required: - - id - - name - - currency_code -properties: - id: - type: string - title: id - description: The region's ID. - name: - type: string - title: name - description: The region's name. - currency_code: - type: string - title: currency_code - description: The region's currency code. - automatic_taxes: - type: boolean - title: automatic_taxes - description: The region's automatic taxes. - countries: - type: array - description: The region's countries. - items: - $ref: ./BaseRegionCountry.yaml - payment_providers: - type: array - description: The region's payment providers. - items: - $ref: ./AdminPaymentProvider.yaml - metadata: - type: object - description: The region's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The region's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The region's updated at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseRegionCountry.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseRegionCountry.yaml index ee76c5c787ed6..5fd0a02708b5d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseRegionCountry.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseRegionCountry.yaml @@ -1,3 +1,33 @@ type: object -description: The country's countries. +description: The country's details. x-schemaName: BaseRegionCountry +properties: + id: + type: string + title: id + description: The country's ID. + iso_2: + type: string + title: iso_2 + description: The country's iso 2. + example: us + iso_3: + type: string + title: iso_3 + description: The country's iso 3. + example: usa + num_code: + type: string + title: num_code + description: The country's num code. + example: 840 + name: + type: string + title: name + description: The country's name. + display_name: + type: string + title: display_name + description: The country's display name. +required: + - id diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseReturnItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseReturnItem.yaml deleted file mode 100644 index 3f0906bd54e7e..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseReturnItem.yaml +++ /dev/null @@ -1,3 +0,0 @@ -type: object -description: The item's items. -x-schemaName: BaseReturnItem diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseRuleOperatorOptions.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseRuleOperatorOptions.yaml index b5c88a34d8dd5..d46a97718a0cc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseRuleOperatorOptions.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseRuleOperatorOptions.yaml @@ -1,5 +1,5 @@ type: object -description: The operator's operators. +description: The operator's details. x-schemaName: BaseRuleOperatorOptions required: - id @@ -10,11 +10,14 @@ properties: type: string title: id description: The operator's ID. + example: in value: type: string title: value description: The operator's value. + example: in label: type: string title: label description: The operator's label. + example: In diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodAdjustment.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodAdjustment.yaml index e20885775e594..53869e4f408ce 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodAdjustment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The adjustment's details. x-schemaName: BaseShippingMethodAdjustment +required: + - shipping_method + - shipping_method_id + - id + - amount + - cart_id + - created_at + - updated_at +properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method the adjustment is applied on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: + type: string + title: cart_id + description: The ID of the associated cart. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodTaxLine.yaml b/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodTaxLine.yaml index e7e494dae548d..50c5ff23eff49 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodTaxLine.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/BaseShippingMethodTaxLine.yaml @@ -1,3 +1,62 @@ type: object -description: The tax line's tax lines. +description: The tax line's details. x-schemaName: BaseShippingMethodTaxLine +required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at +properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of this shipping method the tax line belongs to. + total: + type: number + title: total + description: The method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The method's total excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider that calculated the taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/CreateAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/CreateAddress.yaml index 5217a9aa3bdd9..14de28c42ef4b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/CreateAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/CreateAddress.yaml @@ -1,51 +1,52 @@ type: object -description: The cart's shipping address. +description: The address to create. x-schemaName: CreateAddress properties: customer_id: type: string title: customer_id - description: The shipping address's customer id. + description: The ID of the customer this address belongs to. company: type: string title: company - description: The shipping address's company. + description: The address's company. first_name: type: string title: first_name - description: The shipping address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The shipping address's last name. + description: The address's last name. address_1: type: string title: address_1 - description: The shipping address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The shipping address's address 2. + description: The address's second line. city: type: string title: city - description: The shipping address's city. + description: The address's city. country_code: type: string title: country_code - description: The shipping address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The shipping address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The shipping address's postal code. + description: The address's postal code. phone: type: string title: phone - description: The shipping address's phone. + description: The address's phone. metadata: type: object - description: The shipping address's metadata. + description: The address's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/CreateCartAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/CreateCartAddress.yaml deleted file mode 100644 index ea5d127dd24f5..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/CreateCartAddress.yaml +++ /dev/null @@ -1,47 +0,0 @@ -type: object -description: The cart's billing address. -x-schemaName: CreateCartAddress -properties: - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: - type: string - title: last_name - description: The billing address's last name. - phone: - type: string - title: phone - description: The billing address's phone. - company: - type: string - title: company - description: The billing address's company. - address_1: - type: string - title: address_1 - description: The billing address's address 1. - address_2: - type: string - title: address_2 - description: The billing address's address 2. - city: - type: string - title: city - description: The billing address's city. - country_code: - type: string - title: country_code - description: The billing address's country code. - province: - type: string - title: province - description: The billing address's province. - postal_code: - type: string - title: postal_code - description: The billing address's postal code. - metadata: - type: object - description: The billing address's metadata. diff --git a/www/apps/api-reference/specs/admin/components/schemas/CreateCartCreateLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/CreateCartCreateLineItem.yaml deleted file mode 100644 index fc4ffc2354673..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/CreateCartCreateLineItem.yaml +++ /dev/null @@ -1,97 +0,0 @@ -type: object -description: The item's items. -x-schemaName: CreateCartCreateLineItem -required: - - quantity - - variant_id -properties: - quantity: - type: string - title: quantity - description: The item's quantity. - variant_id: - type: string - title: variant_id - description: The item's variant id. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The item's thumbnail. - product_id: - type: string - title: product_id - description: The item's product id. - product_title: - type: string - title: product_title - description: The item's product title. - product_description: - type: string - title: product_description - description: The item's product description. - product_subtitle: - type: string - title: product_subtitle - description: The item's product subtitle. - product_type: - type: string - title: product_type - description: The item's product type. - product_collection: - type: string - title: product_collection - description: The item's product collection. - product_handle: - type: string - title: product_handle - description: The item's product handle. - variant_sku: - type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: - type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: - type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - is_giftcard: - type: boolean - title: is_giftcard - description: The item's is giftcard. - compare_at_unit_price: - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - unit_price: - type: string - title: unit_price - description: The item's unit price. - metadata: - type: object - description: The item's metadata. diff --git a/www/apps/api-reference/specs/admin/components/schemas/CreateCartWorkflowInput.yaml b/www/apps/api-reference/specs/admin/components/schemas/CreateCartWorkflowInput.yaml deleted file mode 100644 index 369ef9b3a1aeb..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/CreateCartWorkflowInput.yaml +++ /dev/null @@ -1,60 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: CreateCartWorkflowInput -properties: - region_id: - type: string - title: region_id - description: The cart's region id. - customer_id: - type: string - title: customer_id - description: The cart's customer id. - sales_channel_id: - type: string - title: sales_channel_id - description: The cart's sales channel id. - email: - type: string - title: email - description: The cart's email. - format: email - currency_code: - type: string - title: currency_code - description: The cart's currency code. - shipping_address_id: - type: string - title: shipping_address_id - description: The cart's shipping address id. - billing_address_id: - type: string - title: billing_address_id - description: The cart's billing address id. - shipping_address: - oneOf: - - type: string - title: shipping_address - description: The cart's shipping address. - - $ref: ./CreateCartAddress.yaml - billing_address: - oneOf: - - type: string - title: billing_address - description: The cart's billing address. - - $ref: ./CreateCartAddress.yaml - metadata: - type: object - description: The cart's metadata. - items: - type: array - description: The cart's items. - items: - $ref: ./CreateCartCreateLineItem.yaml - promo_codes: - type: array - description: The cart's promo codes. - items: - type: string - title: promo_codes - description: The promo code's promo codes. diff --git a/www/apps/api-reference/specs/admin/components/schemas/CustomerGroupInCustomerFilters.yaml b/www/apps/api-reference/specs/admin/components/schemas/CustomerGroupInCustomerFilters.yaml index fcc67cf89c974..e16fde8c9ba2a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/CustomerGroupInCustomerFilters.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/CustomerGroupInCustomerFilters.yaml @@ -1,5 +1,5 @@ type: object -description: The customer's groups. +description: Filter by customer groups to get their associated customers. x-schemaName: CustomerGroupInCustomerFilters required: - id @@ -12,27 +12,27 @@ properties: oneOf: - type: string title: id - description: The group's ID. + description: Filter by a group's ID. - type: array - description: The group's ID. + description: Filter by group IDs. items: type: string title: id - description: The id's ID. + description: A group's ID. name: oneOf: - type: string title: name - description: The group's name. + description: Filter by a group's name. - type: array - description: The group's name. + description: Filter by group names. items: type: string title: name - description: The name's details. + description: A group's name. created_at: type: object - description: The group's created at. + description: Filter by the group's creation date. properties: $and: type: array @@ -56,7 +56,7 @@ properties: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -159,7 +159,7 @@ properties: description: Filter by whether a value for this parameter exists (not `null`). updated_at: type: object - description: The group's updated at. + description: Filter by the group's update date. properties: $and: type: array @@ -183,7 +183,7 @@ properties: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -286,7 +286,7 @@ properties: description: Filter by whether a value for this parameter exists (not `null`). deleted_at: type: object - description: The group's deleted at. + description: Filter by the group's deletion date. properties: $and: type: array @@ -310,7 +310,7 @@ properties: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq diff --git a/www/apps/api-reference/specs/admin/components/schemas/File.yaml b/www/apps/api-reference/specs/admin/components/schemas/File.yaml deleted file mode 100644 index 20c6a466afdcd..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/File.yaml +++ /dev/null @@ -1,45 +0,0 @@ -type: object -description: The product's file. -x-schemaName: File -required: - - lastModified - - name - - webkitRelativePath - - size - - type - - arrayBuffer - - stream - - text -properties: - lastModified: - type: number - title: lastModified - description: The file's lastmodified. - name: - type: string - title: name - description: The file's name. - webkitRelativePath: - type: string - title: webkitRelativePath - description: The file's webkitrelativepath. - size: - type: number - title: size - description: The file's size. - type: - type: string - title: type - description: The file's type. - arrayBuffer: - type: object - description: The file's arraybuffer. - slice: - type: object - description: The file's slice. - stream: - type: object - description: The file's stream. - text: - type: object - description: The file's text. diff --git a/www/apps/api-reference/specs/admin/components/schemas/FileList.yaml b/www/apps/api-reference/specs/admin/components/schemas/FileList.yaml deleted file mode 100644 index 2bc70ab8fb36e..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/FileList.yaml +++ /dev/null @@ -1,18 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: FileList -required: - - length - - item - - __@iterator@258 -properties: - length: - type: number - title: length - description: The upload's length. - item: - type: object - description: The upload's item. - __@iterator@258: - type: object - description: The upload's @iterator@258. diff --git a/www/apps/api-reference/specs/admin/components/schemas/InventoryLevel.yaml b/www/apps/api-reference/specs/admin/components/schemas/InventoryLevel.yaml index ff883a1a28975..aa13bb7243bb5 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/InventoryLevel.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/InventoryLevel.yaml @@ -1,5 +1,5 @@ type: object -description: The inventory level's inventory levels. +description: The inventory level's details x-schemaName: InventoryLevel required: - id @@ -17,11 +17,11 @@ properties: inventory_item_id: type: string title: inventory_item_id - description: The inventory level's inventory item id. + description: The ID of the associated inventory item. location_id: type: string title: location_id - description: The inventory level's location id. + description: The ID of the associated location. stocked_quantity: type: number title: stocked_quantity @@ -40,4 +40,4 @@ properties: description: The inventory level's incoming quantity. metadata: type: object - description: The inventory level's metadata. + description: The inventory level's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/Order.yaml b/www/apps/api-reference/specs/admin/components/schemas/Order.yaml index 8c90e11018044..89f4b17f5c177 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/Order.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/Order.yaml @@ -1,3 +1,296 @@ type: object -description: The transaction's order. +description: The order change's order. x-schemaName: Order +required: + - id + - version + - status + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_subtotal + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total +properties: + id: + type: string + title: id + description: The order's ID. + version: + type: number + title: version + description: The order's version. + order_change: + $ref: ./OrderChange.yaml + status: + type: string + description: The order's status. + enum: + - canceled + - requires_action + - pending + - completed + - draft + - archived + region_id: + type: string + title: region_id + description: The ID of the region the order belongs to. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the order was placed in. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The order's currency code. + example: usd + shipping_address: + $ref: ./OrderAddress.yaml + billing_address: + $ref: ./OrderAddress.yaml + items: + type: array + description: The order's items. + items: + $ref: ./OrderLineItem.yaml + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: ./OrderShippingMethod.yaml + transactions: + type: array + description: The order's transactions. + items: + $ref: ./OrderTransaction.yaml + summary: + type: object + description: The order's summary. + metadata: + type: object + description: The order's metadata, can hold custom key-value pairs. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the order was canceled. + created_at: + type: string + format: date-time + title: created_at + description: The date the order was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The order items' total including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The order items' total excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The taxes total for order items, excluding promotions. + item_total: + type: number + title: item_total + description: The order items' total including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The order items' total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order items including promotions. + original_total: + type: number + title: original_total + description: The order's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the order including promotions. + discount_subtotal: + type: number + title: discount_subtotal + description: The total discount excluding taxes. + discount_total: + type: number + title: discount_total + description: The total discount including taxes. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total applied on the discount. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The order's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The total taxes of the order's shipping including taxes. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The total taxes of the order's shipping excluding promotions. + raw_original_item_total: + type: object + description: The order's raw original item total. + raw_original_item_subtotal: + type: object + description: The order's raw original item subtotal. + raw_original_item_tax_total: + type: object + description: The order's raw original item tax total. + raw_item_total: + type: object + description: The order's raw item total. + raw_item_subtotal: + type: object + description: The order's raw item subtotal. + raw_item_tax_total: + type: object + description: The order's raw item tax total. + raw_original_total: + type: object + description: The order's raw original total. + raw_original_subtotal: + type: object + description: The order's raw original subtotal. + raw_original_tax_total: + type: object + description: The order's raw original tax total. + raw_total: + type: object + description: The order's raw total. + raw_subtotal: + type: object + description: The order's raw subtotal. + raw_tax_total: + type: object + description: The order's raw tax total. + raw_discount_total: + type: object + description: The order's raw discount total. + raw_discount_tax_total: + type: object + description: The order's raw discount tax total. + raw_gift_card_total: + type: object + description: The order's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The order's raw gift card tax total. + raw_shipping_total: + type: object + description: The order's raw shipping total. + raw_shipping_subtotal: + type: object + description: The order's raw shipping subtotal. + raw_shipping_tax_total: + type: object + description: The order's raw shipping tax total. + raw_original_shipping_total: + type: object + description: The order's raw original shipping total. + raw_original_shipping_subtotal: + type: object + description: The order's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The order's raw original shipping tax total. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderAddress.yaml index 20065360554ed..31087870262e7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The order preview's billing address. +description: The address's details. x-schemaName: OrderAddress required: - id @@ -9,61 +9,62 @@ properties: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer the address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. + description: The date the address was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderChange.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderChange.yaml index e4b9f03dabd9c..d200d8a0d246e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderChange.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderChange.yaml @@ -1,5 +1,5 @@ type: object -description: The order preview's order change. +description: The order change's details. x-schemaName: OrderChange required: - id @@ -34,10 +34,12 @@ properties: version: type: number title: version - description: The order change's version. + description: >- + The order change's version. This will be the order's version when the + change is applied. change_type: type: string - description: The order change's change type. + description: The order change's type. enum: - return - exchange @@ -46,19 +48,19 @@ properties: order_id: type: string title: order_id - description: The order change's order id. + description: The ID of the order this change applies on. return_id: type: string title: return_id - description: The order change's return id. + description: The ID of the associated return. exchange_id: type: string title: exchange_id - description: The order change's exchange id. + description: The ID of the associated exchange. claim_id: type: string title: claim_id - description: The order change's claim id. + description: The ID of the associated claim. order: type: object return_order: @@ -74,74 +76,63 @@ properties: $ref: ./OrderChangeAction.yaml status: type: string - title: status description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined requested_by: type: string title: requested_by - description: The order change's requested by. + description: The ID of the user that requested the change. requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time + type: string + title: requested_at + description: The date the order change was requested. + format: date-time confirmed_by: type: string title: confirmed_by - description: The order change's confirmed by. + description: The ID of the user that confirmed the order change. confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time declined_by: type: string title: declined_by - description: The order change's declined by. + description: The ID of the user that declined the order change. declined_reason: type: string title: declined_reason - description: The order change's declined reason. + description: The reason the order change was declined. metadata: type: object - description: The order change's metadata. + description: The order change's metadata, can hold custom key-value pairs. declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time + type: string + title: declined_at + description: The date the order change was declined. + format: date-time canceled_by: type: string title: canceled_by - description: The order change's canceled by. + description: The ID of the user that canceled the order change. canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time created_at: type: string format: date-time title: created_at - description: The order change's created at. + description: The date the order change was created. updated_at: type: string format: date-time title: updated_at - description: The order change's updated at. + description: The date the order change was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderChangeAction.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderChangeAction.yaml index 13a80ba7673fc..f7c1498878949 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderChangeAction.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderChangeAction.yaml @@ -1,3 +1,100 @@ type: object -description: The action's actions. +description: The order change action's details. x-schemaName: OrderChangeAction +required: + - id + - order_change_id + - order_change + - order_id + - return_id + - claim_id + - exchange_id + - order + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change that the action belongs to. + order_change: + type: object + order_id: + type: string + title: order_id + description: The ID of the order the associated change is for. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + type: object + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + description: The applied action. + enum: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the action was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderClaim.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderClaim.yaml index 7d1a9d336660d..924727045d5cb 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderClaim.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderClaim.yaml @@ -1,3 +1,257 @@ type: object description: The order change's claim. x-schemaName: OrderClaim +required: + - order_id + - claim_items + - additional_items + - currency_code + - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + id: + type: string + title: id + description: The claim's ID. + order_id: + type: string + title: order_id + description: The ID of the order associated with the claim. + claim_items: + type: array + description: The order items targetted by the claim. + items: + $ref: ./BaseClaimItem.yaml + additional_items: + type: array + description: The outbound or new items of the claim. + items: + $ref: ./BaseClaimItem.yaml + return: + $ref: ./Return.yaml + return_id: + type: string + title: return_id + description: The ID of the associated return. + no_notification: + type: boolean + title: no_notification + description: Whether the customer should be notified about changes in the claim. + refund_amount: + type: number + title: refund_amount + description: The amount to be refunded. + currency_code: + type: string + title: currency_code + description: The claim's currency code. + region_id: + type: string + title: region_id + description: The ID of the region associated with the claim. + customer_id: + type: string + title: customer_id + description: The ID of the customer associated with the claim's order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the claim's order is created in. + email: + type: string + title: email + description: The email associated with the claim's order. + format: email + display_id: + type: number + title: display_id + description: The claim's display ID. + shipping_address: + $ref: ./BaseOrderAddress.yaml + billing_address: + $ref: ./BaseOrderAddress.yaml + shipping_methods: + type: array + description: The claim's shipping methods. + items: + $ref: ./BaseOrderShippingMethod.yaml + payment_collections: + type: array + description: The claim's payment collections. + items: + $ref: ./BasePaymentCollection.yaml + payment_status: + type: string + description: The claim's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The claim's fulfillments. + items: + $ref: ./BaseOrderFulfillment.yaml + fulfillment_status: + type: string + description: The claim's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The claim's transactions. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + description: Learn more about transactions of orders and associated models. + items: + $ref: ./BaseOrderTransaction.yaml + summary: + $ref: ./BaseOrderSummary.yaml + metadata: + type: object + description: The claim's metadata, used to store custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The claim's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The claim's update date. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the associated order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the associated order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the original items in the associated order. + item_total: + type: number + title: item_total + description: The total of the claim's items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the claim's items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the claim's items. + original_total: + type: number + title: original_total + description: The associated order's original total. + original_subtotal: + type: number + title: original_subtotal + description: The associated order's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The associated order's original tax total. + total: + type: number + title: total + description: The associated order's total. + subtotal: + type: number + title: subtotal + description: The claim's subtotal. + tax_total: + type: number + title: tax_total + description: The claim's tax total. + discount_total: + type: number + title: discount_total + description: The claim's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The claim's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The claim's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The claim's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The claim's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The claim's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The claim's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The associated order's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The associated order's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The associated order's original shipping tax total. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderExchange.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderExchange.yaml index 0c83b9bb1b4b6..c0ba54357bb31 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderExchange.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderExchange.yaml @@ -1,3 +1,263 @@ type: object description: The order change's exchange. x-schemaName: OrderExchange +required: + - order_id + - return_items + - additional_items + - currency_code + - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + order_id: + type: string + title: order_id + description: The ID of the order the exchange is created for. + return_items: + type: array + description: The items returned (inbound) by the exchange. + items: + $ref: ./AdminReturnItem.yaml + additional_items: + type: array + description: The new items (outbound) sent by the exchange. + items: + $ref: ./BaseExchangeItem.yaml + no_notification: + type: boolean + title: no_notification + description: Whether to send the customer notifications when the exchange is updated. + difference_due: + type: number + title: difference_due + description: >- + The amount to be exchanged or refunded. If the amount is negative, it must + be refunded. If positive, additional payment is required from the + customer. + return: + description: the return associated with the exchange. + $ref: ./AdminReturn.yaml + return_id: + type: string + title: return_id + description: The ID of the associated exchange. + currency_code: + type: string + title: currency_code + description: The exchange's currency code. + id: + type: string + title: id + description: The exchange's ID. + region_id: + type: string + title: region_id + description: The ID of the associated order's region. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the associated order belongs to. + email: + type: string + title: email + description: The email used when placing the order. + format: email + display_id: + type: number + title: display_id + description: The exchange's display ID. + shipping_address: + description: The shipping address to send new items to. + $ref: ./BaseOrderAddress.yaml + billing_address: + description: The customer's billing address. + $ref: ./BaseOrderAddress.yaml + shipping_methods: + type: array + description: The shipping methods used to send the new (outbound) items. + items: + $ref: ./BaseOrderShippingMethod.yaml + payment_collections: + type: array + description: The exchange's payment collections. + items: + $ref: ./BasePaymentCollection.yaml + payment_status: + type: string + description: The exchange's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The exchange's fulfillments of new (outbound) items. + items: + $ref: ./BaseOrderFulfillment.yaml + fulfillment_status: + type: string + description: The exchange's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The exchange's transactions. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + items: + $ref: ./BaseOrderTransaction.yaml + summary: + description: The totals summary of the exchange. + $ref: ./BaseOrderSummary.yaml + metadata: + type: object + description: The exchange's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date that the exchange was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date that the exchange was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The total tax of the original items in the order. + item_total: + type: number + title: item_total + description: The total of the exchange's new items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the exchange's new items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the exchange's new items. + original_total: + type: number + title: original_total + description: The total of the order. + original_subtotal: + type: number + title: original_subtotal + description: The subtotal of the order. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order. + total: + type: number + title: total + description: The total of the exchange. + subtotal: + type: number + title: subtotal + description: The subtotal of the exchange. + tax_total: + type: number + title: tax_total + description: The tax total of the exchange. + discount_total: + type: number + title: discount_total + description: The discount total of the exchange. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes on discount of the exchange. + gift_card_total: + type: number + title: gift_card_total + description: The gift cards total of the exchange. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The total taxes on the gift card of the exchange. + shipping_total: + type: number + title: shipping_total + description: The exchange's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The exchange's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The exchange's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The order's shipping tax total. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderItem.yaml index d7584d2fbebe9..057773eb108ec 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderItem.yaml @@ -1,3 +1,106 @@ type: object -description: The item's detail. +description: The order item's detail. x-schemaName: OrderItem +required: + - id + - item_id + - item + - quantity + - raw_quantity + - fulfilled_quantity + - raw_fulfilled_quantity + - delivered_quantity + - raw_delivered_quantity + - shipped_quantity + - raw_shipped_quantity + - return_requested_quantity + - raw_return_requested_quantity + - return_received_quantity + - raw_return_received_quantity + - return_dismissed_quantity + - raw_return_dismissed_quantity + - written_off_quantity + - raw_written_off_quantity + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The item's ID. + item_id: + type: string + title: item_id + description: The ID of the associated line item. + item: + $ref: ./OrderLineItem.yaml + quantity: + type: number + title: quantity + description: The item's quantity. + raw_quantity: + type: object + description: The item's raw quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + raw_fulfilled_quantity: + type: object + description: The item's raw fulfilled quantity. + delivered_quantity: + type: number + title: delivered_quantity + description: The item's delivered quantity. + raw_delivered_quantity: + type: object + description: The item's raw delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + raw_shipped_quantity: + type: object + description: The item's raw shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + raw_return_requested_quantity: + type: object + description: The item's raw return requested quantity. + return_received_quantity: + type: number + title: return_received_quantity + description: The item's quantity that's received through a return. + raw_return_received_quantity: + type: object + description: The item's raw return received quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: The item's quantity that's returned but dismissed because it's damaged. + raw_return_dismissed_quantity: + type: object + description: The item's raw return dismissed quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed due to an order change. + raw_written_off_quantity: + type: object + description: The item's raw written off quantity. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderLineItem.yaml new file mode 100644 index 0000000000000..7872ecc8f15ad --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderLineItem.yaml @@ -0,0 +1,435 @@ +type: object +description: The order line item's details. +x-schemaName: OrderLineItem +required: + - id + - title + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - raw_unit_price + - quantity + - raw_quantity + - detail + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - item_total + - item_subtotal + - item_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - refundable_total + - refundable_total_per_unit + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_refundable_total + - raw_refundable_total_per_unit +properties: + id: + type: string + title: id + description: The item's ID. + title: + type: string + title: title + description: The item's title. + subtitle: + type: string + title: subtitle + description: The item's subtitle. + thumbnail: + type: string + title: thumbnail + description: The item's thumbnail URL. + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The ID of the associated product's type. + product_collection: + type: string + title: product_collection + description: The ID of the associated product's collection. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: + type: string + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The associated variant's values for the associated product's options. + example: + Color: Red + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item's price includes taxes. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + raw_compare_at_unit_price: + type: object + description: The item's raw compare at unit price. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw compare at unit price's value. + - type: number + title: value + description: The raw compare at unit price's value. + unit_price: + type: number + title: unit_price + description: The item's price for a single quantity. + raw_unit_price: + type: object + description: The item's raw unit price. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw unit price's value. + - type: number + title: value + description: The raw unit price's value. + quantity: + type: number + title: quantity + description: The item's quantity. + raw_quantity: + type: object + description: The item's raw quantity. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw quantity's value. + - type: number + title: value + description: The raw quantity's value. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: ./OrderLineItemTaxLine.yaml + adjustments: + type: array + description: The item's adjustments. + items: + $ref: ./OrderLineItemAdjustment.yaml + detail: + $ref: ./OrderItem.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + original_total: + type: number + title: original_total + description: The item's total including taxes and promotions. + original_subtotal: + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. + item_total: + type: number + title: item_total + description: The item's total for a single quantity, including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: >- + The item's total for a single quantity, excluding taxes and including + promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of a single quantity of the item, including promotions. + total: + type: number + title: total + description: The item's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes of the item, including promotions. + discount_total: + type: number + title: discount_total + description: The item's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total amount of the item that can be refunded. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total amount that can be refunded of a single quantity of the item. + raw_original_total: + type: object + description: The item's raw original total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original total's value. + - type: number + title: value + description: The raw original total's value. + raw_original_subtotal: + type: object + description: The item's raw original subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original subtotal's value. + - type: number + title: value + description: The raw original subtotal's value. + raw_original_tax_total: + type: object + description: The item's raw original tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original tax total's value. + - type: number + title: value + description: The raw original tax total's value. + raw_item_total: + type: object + description: The item's raw item total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw item total's value. + - type: number + title: value + description: The raw item total's value. + raw_item_subtotal: + type: object + description: The item's raw item subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw item subtotal's value. + - type: number + title: value + description: The raw item subtotal's value. + raw_item_tax_total: + type: object + description: The item's raw item tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw item tax total's value. + - type: number + title: value + description: The raw item tax total's value. + raw_total: + type: object + description: The item's raw total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw total's value. + - type: number + title: value + description: The raw total's value. + raw_subtotal: + type: object + description: The item's raw subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw subtotal's value. + - type: number + title: value + description: The raw subtotal's value. + raw_tax_total: + type: object + description: The item's raw tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw tax total's value. + - type: number + title: value + description: The raw tax total's value. + raw_discount_total: + type: object + description: The item's raw discount total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount total's value. + - type: number + title: value + description: The raw discount total's value. + raw_discount_tax_total: + type: object + description: The item's raw discount tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount tax total's value. + - type: number + title: value + description: The raw discount tax total's value. + raw_refundable_total: + type: object + description: The item's raw refundable total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw refundable total's value. + - type: number + title: value + description: The raw refundable total's value. + raw_refundable_total_per_unit: + type: object + description: The item's raw refundable total per unit. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw refundable total per unit's value. + - type: number + title: value + description: The raw refundable total per unit's value. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemAdjustment.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemAdjustment.yaml index 18f5e20824943..caeb06aecfc5f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemAdjustment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The line item adjustment's details. x-schemaName: OrderLineItemAdjustment +required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at +properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the item this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemTaxLine.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemTaxLine.yaml index 0b002d0419eb4..90d590d62b07a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemTaxLine.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderLineItemTaxLine.yaml @@ -1,3 +1,70 @@ type: object -description: The tax line's tax lines. +description: The line item tax line's details. x-schemaName: OrderLineItemTaxLine +required: + - item + - item_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at +properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the line item that the tax line belongs to. + total: + type: number + title: total + description: The item's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax lines. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderPreview.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderPreview.yaml deleted file mode 100644 index 56edabcde0970..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderPreview.yaml +++ /dev/null @@ -1,1550 +0,0 @@ -type: object -description: The order edit's order preview. -x-schemaName: OrderPreview -required: - - order_change - - status - - currency_code - - version - - id - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total - - raw_original_item_total - - raw_original_item_subtotal - - raw_original_item_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - - raw_gift_card_total - - raw_gift_card_tax_total - - raw_shipping_total - - raw_shipping_subtotal - - raw_shipping_tax_total - - raw_original_shipping_total - - raw_original_shipping_subtotal - - raw_original_shipping_tax_total -properties: - order_change: - $ref: ./OrderChange.yaml - items: - type: array - description: The order preview's items. - items: - allOf: - - type: object - description: The item's items. - x-schemaName: OrderLineItem - required: - - id - - title - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - - raw_unit_price - - quantity - - raw_quantity - - detail - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - item_total - - item_subtotal - - item_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - refundable_total - - refundable_total_per_unit - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - - raw_refundable_total - - raw_refundable_total_per_unit - properties: - id: - type: string - title: id - description: The item's ID. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The item's thumbnail. - variant_id: - type: string - title: variant_id - description: The item's variant id. - product_id: - type: string - title: product_id - description: The item's product id. - product_title: - type: string - title: product_title - description: The item's product title. - product_description: - type: string - title: product_description - description: The item's product description. - product_subtitle: - type: string - title: product_subtitle - description: The item's product subtitle. - product_type: - type: string - title: product_type - description: The item's product type. - product_collection: - type: string - title: product_collection - description: The item's product collection. - product_handle: - type: string - title: product_handle - description: The item's product handle. - variant_sku: - type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: - type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: - type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - compare_at_unit_price: - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - raw_compare_at_unit_price: - type: object - description: The item's raw compare at unit price. - unit_price: - type: number - title: unit_price - description: The item's unit price. - raw_unit_price: - type: object - description: The item's raw unit price. - quantity: - type: number - title: quantity - description: The item's quantity. - raw_quantity: - type: object - description: The item's raw quantity. - tax_lines: - type: array - description: The item's tax lines. - items: - $ref: ./OrderLineItemTaxLine.yaml - adjustments: - type: array - description: The item's adjustments. - items: - $ref: ./OrderLineItemAdjustment.yaml - detail: - $ref: ./OrderItem.yaml - created_at: - type: string - format: date-time - title: created_at - description: The item's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The item's updated at. - metadata: - type: object - description: The item's metadata. - original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: ./IBigNumber.yaml - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: ./IBigNumber.yaml - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: ./IBigNumber.yaml - item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: ./IBigNumber.yaml - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: ./IBigNumber.yaml - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: ./IBigNumber.yaml - total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: ./IBigNumber.yaml - subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: ./IBigNumber.yaml - tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: ./IBigNumber.yaml - discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: ./IBigNumber.yaml - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: ./IBigNumber.yaml - refundable_total: - oneOf: - - type: string - title: refundable_total - description: The item's refundable total. - - type: number - title: refundable_total - description: The item's refundable total. - - type: string - title: refundable_total - description: The item's refundable total. - - $ref: ./IBigNumber.yaml - refundable_total_per_unit: - oneOf: - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: number - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - $ref: ./IBigNumber.yaml - raw_original_total: - type: object - description: The item's raw original total. - raw_original_subtotal: - type: object - description: The item's raw original subtotal. - raw_original_tax_total: - type: object - description: The item's raw original tax total. - raw_item_total: - type: object - description: The item's raw item total. - raw_item_subtotal: - type: object - description: The item's raw item subtotal. - raw_item_tax_total: - type: object - description: The item's raw item tax total. - raw_total: - type: object - description: The item's raw total. - raw_subtotal: - type: object - description: The item's raw subtotal. - raw_tax_total: - type: object - description: The item's raw tax total. - raw_discount_total: - type: object - description: The item's raw discount total. - raw_discount_tax_total: - type: object - description: The item's raw discount tax total. - raw_refundable_total: - type: object - description: The item's raw refundable total. - raw_refundable_total_per_unit: - type: object - description: The item's raw refundable total per unit. - - type: object - description: The item's items. - properties: - actions: - type: array - description: The item's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - shipping_methods: - type: array - description: The order preview's shipping methods. - items: - allOf: - - type: object - description: The shipping method's shipping methods. - x-schemaName: OrderShippingMethod - required: - - id - - order_id - - name - - amount - - raw_amount - - is_tax_inclusive - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - properties: - id: - type: string - title: id - description: The shipping method's ID. - order_id: - type: string - title: order_id - description: The shipping method's order id. - name: - type: string - title: name - description: The shipping method's name. - description: - type: string - title: description - description: The shipping method's description. - amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: ./IBigNumber.yaml - raw_amount: - type: object - description: The shipping method's raw amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping method's is tax inclusive. - shipping_option_id: - type: string - title: shipping_option_id - description: The shipping method's shipping option id. - data: - type: object - description: The shipping method's data. - metadata: - type: object - description: The shipping method's metadata. - tax_lines: - type: array - description: The shipping method's tax lines. - items: - $ref: ./OrderShippingMethodTaxLine.yaml - adjustments: - type: array - description: The shipping method's adjustments. - items: - $ref: ./OrderShippingMethodAdjustment.yaml - created_at: - type: string - format: date-time - title: created_at - description: The shipping method's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The shipping method's updated at. - original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: ./IBigNumber.yaml - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: ./IBigNumber.yaml - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: ./IBigNumber.yaml - total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: ./IBigNumber.yaml - subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: ./IBigNumber.yaml - tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: ./IBigNumber.yaml - discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: ./IBigNumber.yaml - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: ./IBigNumber.yaml - raw_original_total: - type: object - description: The shipping method's raw original total. - raw_original_subtotal: - type: object - description: The shipping method's raw original subtotal. - raw_original_tax_total: - type: object - description: The shipping method's raw original tax total. - raw_total: - type: object - description: The shipping method's raw total. - raw_subtotal: - type: object - description: The shipping method's raw subtotal. - raw_tax_total: - type: object - description: The shipping method's raw tax total. - raw_discount_total: - type: object - description: The shipping method's raw discount total. - raw_discount_tax_total: - type: object - description: The shipping method's raw discount tax total. - - type: object - description: The shipping method's shipping methods. - properties: - actions: - type: array - description: The shipping method's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - status: - type: string - description: The order preview's status. - enum: - - canceled - - requires_action - - pending - - completed - - draft - - archived - currency_code: - type: string - title: currency_code - description: The order preview's currency code. - version: - type: number - title: version - description: The order preview's version. - id: - type: string - title: id - description: The order preview's ID. - region_id: - type: string - title: region_id - description: The order preview's region id. - customer_id: - type: string - title: customer_id - description: The order preview's customer id. - sales_channel_id: - type: string - title: sales_channel_id - description: The order preview's sales channel id. - email: - type: string - title: email - description: The order preview's email. - format: email - shipping_address: - $ref: ./OrderAddress.yaml - billing_address: - $ref: ./OrderAddress.yaml - transactions: - type: array - description: The order preview's transactions. - items: - $ref: ./OrderTransaction.yaml - summary: - type: object - description: The order preview's summary. - required: - - total - - subtotal - - total_tax - - ordered_total - - fulfilled_total - - returned_total - - return_request_total - - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - - paid_total - - refunded_total - - pending_difference - - raw_pending_difference - properties: - total: - oneOf: - - type: string - title: total - description: The summary's total. - - type: number - title: total - description: The summary's total. - - type: string - title: total - description: The summary's total. - - type: object - description: The summary's total. - x-schemaName: IBigNumber - subtotal: - oneOf: - - type: string - title: subtotal - description: The summary's subtotal. - - type: number - title: subtotal - description: The summary's subtotal. - - type: string - title: subtotal - description: The summary's subtotal. - - type: object - description: The summary's subtotal. - x-schemaName: IBigNumber - total_tax: - oneOf: - - type: string - title: total_tax - description: The summary's total tax. - - type: number - title: total_tax - description: The summary's total tax. - - type: string - title: total_tax - description: The summary's total tax. - - type: object - description: The summary's total tax. - x-schemaName: IBigNumber - ordered_total: - oneOf: - - type: string - title: ordered_total - description: The summary's ordered total. - - type: number - title: ordered_total - description: The summary's ordered total. - - type: string - title: ordered_total - description: The summary's ordered total. - - type: object - description: The summary's ordered total. - x-schemaName: IBigNumber - fulfilled_total: - oneOf: - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: number - title: fulfilled_total - description: The summary's fulfilled total. - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: object - description: The summary's fulfilled total. - x-schemaName: IBigNumber - returned_total: - oneOf: - - type: string - title: returned_total - description: The summary's returned total. - - type: number - title: returned_total - description: The summary's returned total. - - type: string - title: returned_total - description: The summary's returned total. - - type: object - description: The summary's returned total. - x-schemaName: IBigNumber - return_request_total: - oneOf: - - type: string - title: return_request_total - description: The summary's return request total. - - type: number - title: return_request_total - description: The summary's return request total. - - type: string - title: return_request_total - description: The summary's return request total. - - type: object - description: The summary's return request total. - x-schemaName: IBigNumber - write_off_total: - oneOf: - - type: string - title: write_off_total - description: The summary's write off total. - - type: number - title: write_off_total - description: The summary's write off total. - - type: string - title: write_off_total - description: The summary's write off total. - - type: object - description: The summary's write off total. - x-schemaName: IBigNumber - projected_total: - oneOf: - - type: string - title: projected_total - description: The summary's projected total. - - type: number - title: projected_total - description: The summary's projected total. - - type: string - title: projected_total - description: The summary's projected total. - - type: object - description: The summary's projected total. - x-schemaName: IBigNumber - net_total: - oneOf: - - type: string - title: net_total - description: The summary's net total. - - type: number - title: net_total - description: The summary's net total. - - type: string - title: net_total - description: The summary's net total. - - type: object - description: The summary's net total. - x-schemaName: IBigNumber - net_subtotal: - oneOf: - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: number - title: net_subtotal - description: The summary's net subtotal. - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: object - description: The summary's net subtotal. - x-schemaName: IBigNumber - net_total_tax: - oneOf: - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: number - title: net_total_tax - description: The summary's net total tax. - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: object - description: The summary's net total tax. - x-schemaName: IBigNumber - balance: - oneOf: - - type: string - title: balance - description: The summary's balance. - - type: number - title: balance - description: The summary's balance. - - type: string - title: balance - description: The summary's balance. - - type: object - description: The summary's balance. - x-schemaName: IBigNumber - paid_total: - oneOf: - - type: string - title: paid_total - description: The summary's paid total. - - type: number - title: paid_total - description: The summary's paid total. - - type: string - title: paid_total - description: The summary's paid total. - - type: object - description: The summary's paid total. - x-schemaName: IBigNumber - refunded_total: - oneOf: - - type: string - title: refunded_total - description: The summary's refunded total. - - type: number - title: refunded_total - description: The summary's refunded total. - - type: string - title: refunded_total - description: The summary's refunded total. - - type: object - description: The summary's refunded total. - x-schemaName: IBigNumber - pending_difference: - oneOf: - - type: string - title: pending_difference - description: The summary's pending difference. - - type: number - title: pending_difference - description: The summary's pending difference. - - type: string - title: pending_difference - description: The summary's pending difference. - - type: object - description: The summary's pending difference. - x-schemaName: IBigNumber - raw_pending_difference: - type: object - description: The summary's raw pending difference. - metadata: - type: object - description: The order preview's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The order preview's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The order preview's updated at. - original_item_total: - oneOf: - - type: string - title: original_item_total - description: The order preview's original item total. - - type: number - title: original_item_total - description: The order preview's original item total. - - type: string - title: original_item_total - description: The order preview's original item total. - - $ref: ./IBigNumber.yaml - original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: number - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - $ref: ./IBigNumber.yaml - original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - type: number - title: original_item_tax_total - description: The order preview's original item tax total. - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - $ref: ./IBigNumber.yaml - item_total: - oneOf: - - type: string - title: item_total - description: The order preview's item total. - - type: number - title: item_total - description: The order preview's item total. - - type: string - title: item_total - description: The order preview's item total. - - $ref: ./IBigNumber.yaml - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - type: number - title: item_subtotal - description: The order preview's item subtotal. - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - $ref: ./IBigNumber.yaml - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The order preview's item tax total. - - type: number - title: item_tax_total - description: The order preview's item tax total. - - type: string - title: item_tax_total - description: The order preview's item tax total. - - $ref: ./IBigNumber.yaml - original_total: - oneOf: - - type: string - title: original_total - description: The order preview's original total. - - type: number - title: original_total - description: The order preview's original total. - - type: string - title: original_total - description: The order preview's original total. - - $ref: ./IBigNumber.yaml - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - type: number - title: original_subtotal - description: The order preview's original subtotal. - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - $ref: ./IBigNumber.yaml - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The order preview's original tax total. - - type: number - title: original_tax_total - description: The order preview's original tax total. - - type: string - title: original_tax_total - description: The order preview's original tax total. - - $ref: ./IBigNumber.yaml - total: - oneOf: - - type: string - title: total - description: The order preview's total. - - type: number - title: total - description: The order preview's total. - - type: string - title: total - description: The order preview's total. - - $ref: ./IBigNumber.yaml - subtotal: - oneOf: - - type: string - title: subtotal - description: The order preview's subtotal. - - type: number - title: subtotal - description: The order preview's subtotal. - - type: string - title: subtotal - description: The order preview's subtotal. - - $ref: ./IBigNumber.yaml - tax_total: - oneOf: - - type: string - title: tax_total - description: The order preview's tax total. - - type: number - title: tax_total - description: The order preview's tax total. - - type: string - title: tax_total - description: The order preview's tax total. - - $ref: ./IBigNumber.yaml - discount_total: - oneOf: - - type: string - title: discount_total - description: The order preview's discount total. - - type: number - title: discount_total - description: The order preview's discount total. - - type: string - title: discount_total - description: The order preview's discount total. - - $ref: ./IBigNumber.yaml - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - type: number - title: discount_tax_total - description: The order preview's discount tax total. - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - $ref: ./IBigNumber.yaml - gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The order preview's gift card total. - - type: number - title: gift_card_total - description: The order preview's gift card total. - - type: string - title: gift_card_total - description: The order preview's gift card total. - - $ref: ./IBigNumber.yaml - gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: number - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - $ref: ./IBigNumber.yaml - shipping_total: - oneOf: - - type: string - title: shipping_total - description: The order preview's shipping total. - - type: number - title: shipping_total - description: The order preview's shipping total. - - type: string - title: shipping_total - description: The order preview's shipping total. - - $ref: ./IBigNumber.yaml - shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: number - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - $ref: ./IBigNumber.yaml - shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: number - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - $ref: ./IBigNumber.yaml - original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - type: number - title: original_shipping_total - description: The order preview's original shipping total. - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - $ref: ./IBigNumber.yaml - original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - $ref: ./IBigNumber.yaml - original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - $ref: ./IBigNumber.yaml - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order preview's canceled at. - - type: string - title: canceled_at - description: The order preview's canceled at. - format: date-time - raw_original_item_total: - type: object - description: The order preview's raw original item total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original item total's value. - - type: number - title: value - description: The raw original item total's value. - raw_original_item_subtotal: - type: object - description: The order preview's raw original item subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original item subtotal's value. - - type: number - title: value - description: The raw original item subtotal's value. - raw_original_item_tax_total: - type: object - description: The order preview's raw original item tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original item tax total's value. - - type: number - title: value - description: The raw original item tax total's value. - raw_item_total: - type: object - description: The order preview's raw item total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw item total's value. - - type: number - title: value - description: The raw item total's value. - raw_item_subtotal: - type: object - description: The order preview's raw item subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw item subtotal's value. - - type: number - title: value - description: The raw item subtotal's value. - raw_item_tax_total: - type: object - description: The order preview's raw item tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw item tax total's value. - - type: number - title: value - description: The raw item tax total's value. - raw_original_total: - type: object - description: The order preview's raw original total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original total's value. - - type: number - title: value - description: The raw original total's value. - raw_original_subtotal: - type: object - description: The order preview's raw original subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original subtotal's value. - - type: number - title: value - description: The raw original subtotal's value. - raw_original_tax_total: - type: object - description: The order preview's raw original tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original tax total's value. - - type: number - title: value - description: The raw original tax total's value. - raw_total: - type: object - description: The order preview's raw total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw total's value. - - type: number - title: value - description: The raw total's value. - raw_subtotal: - type: object - description: The order preview's raw subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw subtotal's value. - - type: number - title: value - description: The raw subtotal's value. - raw_tax_total: - type: object - description: The order preview's raw tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw tax total's value. - - type: number - title: value - description: The raw tax total's value. - raw_discount_total: - type: object - description: The order preview's raw discount total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw discount total's value. - - type: number - title: value - description: The raw discount total's value. - raw_discount_tax_total: - type: object - description: The order preview's raw discount tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw discount tax total's value. - - type: number - title: value - description: The raw discount tax total's value. - raw_gift_card_total: - type: object - description: The order preview's raw gift card total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw gift card total's value. - - type: number - title: value - description: The raw gift card total's value. - raw_gift_card_tax_total: - type: object - description: The order preview's raw gift card tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw gift card tax total's value. - - type: number - title: value - description: The raw gift card tax total's value. - raw_shipping_total: - type: object - description: The order preview's raw shipping total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw shipping total's value. - - type: number - title: value - description: The raw shipping total's value. - raw_shipping_subtotal: - type: object - description: The order preview's raw shipping subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw shipping subtotal's value. - - type: number - title: value - description: The raw shipping subtotal's value. - raw_shipping_tax_total: - type: object - description: The order preview's raw shipping tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw shipping tax total's value. - - type: number - title: value - description: The raw shipping tax total's value. - raw_original_shipping_total: - type: object - description: The order preview's raw original shipping total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original shipping total's value. - - type: number - title: value - description: The raw original shipping total's value. - raw_original_shipping_subtotal: - type: object - description: The order preview's raw original shipping subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original shipping subtotal's value. - - type: number - title: value - description: The raw original shipping subtotal's value. - raw_original_shipping_tax_total: - type: object - description: The order preview's raw original shipping tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original shipping tax total's value. - - type: number - title: value - description: The raw original shipping tax total's value. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderReturnItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderReturnItem.yaml new file mode 100644 index 0000000000000..2b2fa31a3833b --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderReturnItem.yaml @@ -0,0 +1,50 @@ +type: object +description: The item's items. +x-schemaName: OrderReturnItem +required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id +properties: + id: + type: string + title: id + description: The return item's ID. + quantity: + type: number + title: quantity + description: The return item's quantity. + received_quantity: + type: number + title: received_quantity + description: >- + The received quantity of the item. This quantity is added to the stocked + inventory quantity of the item. + damaged_quantity: + type: number + title: damaged_quantity + description: >- + The received damaged quantity of the item, which isn't added to the + stocked inventory quantity of the item. + reason_id: + type: string + title: reason_id + description: The ID of the return reason associated with the item. + note: + type: string + title: note + description: A note about why the item was returned. + item_id: + type: string + title: item_id + description: The ID of the associated order item. + return_id: + type: string + title: return_id + description: The ID of the return this return item belongs to. + metadata: + type: object + description: The return item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethod.yaml new file mode 100644 index 0000000000000..892005eea081c --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethod.yaml @@ -0,0 +1,246 @@ +type: object +description: The shipping method's details. +x-schemaName: OrderShippingMethod +required: + - id + - order_id + - name + - amount + - raw_amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total +properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order that the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + raw_amount: + type: object + description: The shipping method's raw amount. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw amount's value. + - type: number + title: value + description: The raw amount's value. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: >- + The shipping method's data, useful for the fulfillment provider handling + the fulfillment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/order/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: ./OrderShippingMethodTaxLine.yaml + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: ./OrderShippingMethodAdjustment.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's subtotal excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the shipping method excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes of the shipping method, including promotions. + discount_total: + type: number + title: discount_total + description: The shipping method's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes of the discount amount. + raw_original_total: + type: object + description: The shipping method's raw original total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original total's value. + - type: number + title: value + description: The raw original total's value. + raw_original_subtotal: + type: object + description: The shipping method's raw original subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original subtotal's value. + - type: number + title: value + description: The raw original subtotal's value. + raw_original_tax_total: + type: object + description: The shipping method's raw original tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original tax total's value. + - type: number + title: value + description: The raw original tax total's value. + raw_total: + type: object + description: The shipping method's raw total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw total's value. + - type: number + title: value + description: The raw total's value. + raw_subtotal: + type: object + description: The shipping method's raw subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw subtotal's value. + - type: number + title: value + description: The raw subtotal's value. + raw_tax_total: + type: object + description: The shipping method's raw tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw tax total's value. + - type: number + title: value + description: The raw tax total's value. + raw_discount_total: + type: object + description: The shipping method's raw discount total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount total's value. + - type: number + title: value + description: The raw discount total's value. + raw_discount_tax_total: + type: object + description: The shipping method's raw discount tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount tax total's value. + - type: number + title: value + description: The raw discount tax total's value. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodAdjustment.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodAdjustment.yaml index a05be82f6280a..c63afb13c0e09 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodAdjustment.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The shipping method adjustment's details. x-schemaName: OrderShippingMethodAdjustment +required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at +properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion this adjustment applies. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodTaxLine.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodTaxLine.yaml index 89976e41b4931..d49d3e1414822 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodTaxLine.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderShippingMethodTaxLine.yaml @@ -1,3 +1,70 @@ type: object -description: The tax line's tax lines. +description: The shipping method tax line's details. x-schemaName: OrderShippingMethodTaxLine +required: + - shipping_method + - shipping_method_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at +properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method that this tax line is for. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/OrderTransaction.yaml b/www/apps/api-reference/specs/admin/components/schemas/OrderTransaction.yaml index fe6226719f601..100e873e64f4b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/OrderTransaction.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/OrderTransaction.yaml @@ -1,18 +1,16 @@ type: object -description: The transaction's transactions. +description: The transaction's details. x-schemaName: OrderTransaction required: - id - order_id - - order - amount - - raw_amount - currency_code - reference - reference_id + - metadata - created_at - updated_at - - metadata properties: id: type: string @@ -21,46 +19,40 @@ properties: order_id: type: string title: order_id - description: The transaction's order id. - order: - type: object + description: The ID of the order this transaction belongs to. amount: - oneOf: - - type: string - title: amount - description: The transaction's amount. - - type: number - title: amount - description: The transaction's amount. - - type: string - title: amount - description: The transaction's amount. - - $ref: ./IBigNumber.yaml - raw_amount: - type: object - description: The transaction's raw amount. + type: number + title: amount + description: The transaction's amount. currency_code: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: >- + The name of a table that this transaction references. If this transaction + is for captured payment, its value is `capture`. If this transaction is + for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. + metadata: + type: object + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. - metadata: - type: object - description: The transaction's metadata. + description: The date that the transaction was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/RefundReason.yaml b/www/apps/api-reference/specs/admin/components/schemas/RefundReason.yaml new file mode 100644 index 0000000000000..46c54887802c2 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/RefundReason.yaml @@ -0,0 +1,35 @@ +type: object +description: The refund's refund reason. +x-schemaName: RefundReason +required: + - id + - label + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The refund reason's ID. + label: + type: string + title: label + description: The refund reason's label. + description: + type: string + title: description + description: The refund reason's description. + metadata: + type: object + description: The refund reason's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The refund reason's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The refund reason's updated at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/RefundReasonResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/RefundReasonResponse.yaml index 2ccee98673d1d..e3f9c36587bd9 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/RefundReasonResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/RefundReasonResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The refund reason's details. x-schemaName: RefundReasonResponse required: - refund_reason diff --git a/www/apps/api-reference/specs/admin/components/schemas/ReservationResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/ReservationResponse.yaml deleted file mode 100644 index d66cc74750e04..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/ReservationResponse.yaml +++ /dev/null @@ -1,66 +0,0 @@ -type: object -description: The reservation's details. -x-schemaName: ReservationResponse -required: - - id - - line_item_id - - location_id - - quantity - - external_id - - description - - inventory_item_id - - inventory_item -properties: - id: - type: string - title: id - description: The reservation's ID. - line_item_id: - type: string - title: line_item_id - description: The reservation's line item id. - location_id: - type: string - title: location_id - description: The reservation's location id. - quantity: - type: string - title: quantity - description: The reservation's quantity. - external_id: - type: string - title: external_id - description: The reservation's external id. - description: - type: string - title: description - description: The reservation's description. - inventory_item_id: - type: string - title: inventory_item_id - description: The reservation's inventory item id. - inventory_item: - type: object - description: The reservation's inventory item. - metadata: - type: object - description: The reservation's metadata. - created_by: - type: string - title: created_by - description: The reservation's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The reservation's deleted at. - created_at: - type: string - format: date-time - title: created_at - description: The reservation's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The reservation's updated at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/Return.yaml b/www/apps/api-reference/specs/admin/components/schemas/Return.yaml index 529ada57ca7f1..c3be6afa992d1 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/Return.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/Return.yaml @@ -1,3 +1,299 @@ type: object -description: The order change's return order. +description: The return's details. x-schemaName: Return +required: + - id + - status + - order_id + - items + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - discount_subtotal + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total +properties: + id: + type: string + title: id + description: The return's ID. + status: + type: string + description: The return's status. + enum: + - canceled + - requested + - received + - partially_received + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. + order_id: + type: string + title: order_id + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: ./OrderReturnItem.yaml + region_id: + type: string + title: region_id + description: The ID of the region this return belongs to. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the associated order's sales channel. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The return's currency code. + example: usd + shipping_address: + $ref: ./OrderAddress.yaml + billing_address: + $ref: ./OrderAddress.yaml + shipping_methods: + type: array + description: The return's shipping methods. + items: + $ref: ./OrderShippingMethod.yaml + transactions: + type: array + description: The return's transactions. + items: + $ref: ./OrderTransaction.yaml + summary: + type: object + description: The return's summary. + metadata: + type: object + description: The return's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the return was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the return was updated. + original_item_total: + type: number + title: original_item_total + description: The return's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The return's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The return's original item tax total. + item_total: + type: number + title: item_total + description: The return's item total. + item_subtotal: + type: number + title: item_subtotal + description: The return's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The return's item tax total. + original_total: + type: number + title: original_total + description: The return's original total. + original_subtotal: + type: number + title: original_subtotal + description: The return's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The return's original tax total. + total: + type: number + title: total + description: The return's total. + subtotal: + type: number + title: subtotal + description: The return's subtotal. + tax_total: + type: number + title: tax_total + description: The return's tax total. + discount_total: + type: number + title: discount_total + description: The return's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The return's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The return's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The return's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The return's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The return's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The return's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The return's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The return's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The return's original shipping tax total. + order_change: + type: object + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time + discount_subtotal: + type: number + title: discount_subtotal + description: The return's discount subtotal. + raw_original_item_total: + type: object + description: The return's raw original item total. + raw_original_item_subtotal: + type: object + description: The return's raw original item subtotal. + raw_original_item_tax_total: + type: object + description: The return's raw original item tax total. + raw_item_total: + type: object + description: The return's raw item total. + raw_item_subtotal: + type: object + description: The return's raw item subtotal. + raw_item_tax_total: + type: object + description: The return's raw item tax total. + raw_original_total: + type: object + description: The return's raw original total. + raw_original_subtotal: + type: object + description: The return's raw original subtotal. + raw_original_tax_total: + type: object + description: The return's raw original tax total. + raw_total: + type: object + description: The return's raw total. + raw_subtotal: + type: object + description: The return's raw subtotal. + raw_tax_total: + type: object + description: The return's raw tax total. + raw_discount_total: + type: object + description: The return's raw discount total. + raw_discount_tax_total: + type: object + description: The return's raw discount tax total. + raw_gift_card_total: + type: object + description: The return's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The return's raw gift card tax total. + raw_shipping_total: + type: object + description: The return's raw shipping total. + raw_shipping_subtotal: + type: object + description: The return's raw shipping subtotal. + raw_shipping_tax_total: + type: object + description: The return's raw shipping tax total. + raw_original_shipping_total: + type: object + description: The return's raw original shipping total. + raw_original_shipping_subtotal: + type: object + description: The return's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The return's raw original shipping tax total. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreAddCartLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreAddCartLineItem.yaml index c791cbd824f56..8ce18622d407c 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreAddCartLineItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreAddCartLineItem.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the line item to add. x-schemaName: StoreAddCartLineItem required: - variant_id @@ -8,11 +8,11 @@ properties: variant_id: type: string title: variant_id - description: The cart's variant id. + description: The ID of the product variant to add to the cart. quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. + description: The item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCalculateCartTaxes.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCalculateCartTaxes.yaml deleted file mode 100644 index 729f1b95bd669..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCalculateCartTaxes.yaml +++ /dev/null @@ -1,8 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: StoreCalculateCartTaxes -properties: - fields: - type: string - title: fields - description: The cart's fields. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCart.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCart.yaml index 73037779afb15..9ec4dc1c9fa13 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCart.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCart.yaml @@ -1,9 +1,9 @@ type: object -description: The cart's parent. +description: The cart's details. x-schemaName: StoreCart required: - - id - currency_code + - id - original_item_total - original_item_subtotal - original_item_tax_total @@ -30,320 +30,148 @@ properties: id: type: string title: id - description: The parent's ID. + description: The cart's ID. region: - $ref: ./BaseRegion.yaml + $ref: ./StoreRegion.yaml region_id: type: string title: region_id - description: The parent's region id. + description: The ID of the region the cart belongs to. customer_id: type: string title: customer_id - description: The parent's customer id. + description: The ID of the customer the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The parent's sales channel id. + description: >- + The ID of the cart's sales channel. Only products that belong to the same + sales channel can be added to the cart. The created order will be + associated with the same sales channel. email: type: string title: email - description: The parent's email. + description: The email of the customer the cart belongs to. format: email currency_code: type: string title: currency_code - description: The parent's currency code. + description: The cart's currency code. + example: usd shipping_address: - $ref: ./BaseCartAddress.yaml + $ref: ./StoreCartAddress.yaml billing_address: - $ref: ./BaseCartAddress.yaml + $ref: ./StoreCartAddress.yaml items: type: array - description: The parent's items. + description: The cart's items. items: - $ref: ./BaseCartLineItem.yaml + $ref: ./StoreCartLineItem.yaml shipping_methods: type: array - description: The parent's shipping methods. + description: The cart's shipping methods. items: - $ref: ./BaseCartShippingMethod.yaml + $ref: ./StoreCartShippingMethod.yaml payment_collection: - $ref: ./BasePaymentCollection.yaml + $ref: ./StorePaymentCollection.yaml metadata: type: object - description: The parent's metadata. + description: The cart's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the cart was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the cart was updated. original_item_total: - oneOf: - - type: string - title: original_item_total - description: The parent's original item total. - - type: number - title: original_item_total - description: The parent's original item total. - - type: string - title: original_item_total - description: The parent's original item total. - - $ref: ./IBigNumber.yaml + type: number + title: original_item_total + description: The cart items' total including taxes, excluding promotions. original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - type: number - title: original_item_subtotal - description: The parent's original item subtotal. - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_item_subtotal + description: The cart items' total excluding taxes, including promotions. original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - type: number - title: original_item_tax_total - description: The parent's original item tax total. - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_item_tax_total + description: The cart items' tax total excluding promotions. item_total: - oneOf: - - type: string - title: item_total - description: The parent's item total. - - type: number - title: item_total - description: The parent's item total. - - type: string - title: item_total - description: The parent's item total. - - $ref: ./IBigNumber.yaml + type: number + title: item_total + description: The cart items' total including taxes and promotions. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The parent's item subtotal. - - type: number - title: item_subtotal - description: The parent's item subtotal. - - type: string - title: item_subtotal - description: The parent's item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: item_subtotal + description: The cart items' total excluding taxes, including promotions. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The parent's item tax total. - - type: number - title: item_tax_total - description: The parent's item tax total. - - type: string - title: item_tax_total - description: The parent's item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: item_tax_total + description: The cart items' tax total including promotions. original_total: - oneOf: - - type: string - title: original_total - description: The parent's original total. - - type: number - title: original_total - description: The parent's original total. - - type: string - title: original_total - description: The parent's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The cart's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The parent's original subtotal. - - type: number - title: original_subtotal - description: The parent's original subtotal. - - type: string - title: original_subtotal - description: The parent's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The cart's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The parent's original tax total. - - type: number - title: original_tax_total - description: The parent's original tax total. - - type: string - title: original_tax_total - description: The parent's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The cart's tax total excluding promotions. total: - oneOf: - - type: string - title: total - description: The parent's total. - - type: number - title: total - description: The parent's total. - - type: string - title: total - description: The parent's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The cart's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The parent's subtotal. - - type: number - title: subtotal - description: The parent's subtotal. - - type: string - title: subtotal - description: The parent's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The cart's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The parent's tax total. - - type: number - title: tax_total - description: The parent's tax total. - - type: string - title: tax_total - description: The parent's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The cart's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The parent's discount total. - - type: number - title: discount_total - description: The parent's discount total. - - type: string - title: discount_total - description: The parent's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The cart's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - type: number - title: discount_tax_total - description: The parent's discount tax total. - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The tax total applied on the discounted amount. gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The parent's gift card total. - - type: number - title: gift_card_total - description: The parent's gift card total. - - type: string - title: gift_card_total - description: The parent's gift card total. - - $ref: ./IBigNumber.yaml + type: number + title: gift_card_total + description: The total gift card amount applied on the cart. gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: number - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - $ref: ./IBigNumber.yaml + type: number + title: gift_card_tax_total + description: The total taxes applied on the gift card amount. shipping_total: - oneOf: - - type: string - title: shipping_total - description: The parent's shipping total. - - type: number - title: shipping_total - description: The parent's shipping total. - - type: string - title: shipping_total - description: The parent's shipping total. - - $ref: ./IBigNumber.yaml + type: number + title: shipping_total + description: The cart's shipping total including taxes and promotions. shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: number - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - type: number - title: shipping_tax_total - description: The parent's shipping tax total. - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - $ref: ./IBigNumber.yaml + type: number + title: shipping_tax_total + description: The total taxes applied on the cart's shipping amount. original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - type: number - title: original_shipping_total - description: The parent's original shipping total. - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - $ref: ./IBigNumber.yaml + type: number + title: original_shipping_total + description: The cart's shipping total including taxes, excluding promotions. original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_shipping_tax_total + description: The total taxes applied on the cart's shipping amount. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCartAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCartAddress.yaml index af376781b2e4c..15aa12c9eb2e1 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCartAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCartAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The cart's billing address. +description: The address's details. x-schemaName: StoreCartAddress required: - id @@ -9,69 +9,62 @@ properties: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer the address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: - oneOf: - - type: string - title: created_at - description: The billing address's created at. - - type: string - title: created_at - description: The billing address's created at. - format: date-time + type: string + title: created_at + description: The date the address was created. + format: date-time updated_at: - oneOf: - - type: string - title: updated_at - description: The billing address's updated at. - - type: string - title: updated_at - description: The billing address's updated at. - format: date-time + type: string + title: updated_at + description: The date the address was updated. + format: date-time diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCartLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCartLineItem.yaml index 1b92e40ec6128..7eb43c9a74b3a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCartLineItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCartLineItem.yaml @@ -1,27 +1,27 @@ type: object -description: The item's items. +description: The item's details. x-schemaName: StoreCartLineItem required: - - id - - title - - quantity - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - cart - - cart_id - - original_total - - original_subtotal - - original_tax_total + - title + - id - item_total - item_subtotal - item_tax_total + - original_total + - original_subtotal + - original_tax_total - total - subtotal - tax_total - discount_total - discount_tax_total + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - cart_id properties: id: type: string @@ -38,25 +38,17 @@ properties: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The item's thumbnail URL. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: ./IBigNumber.yaml + type: number + title: quantity + description: The item's quantity. product: - $ref: ./BaseProduct.yaml + $ref: ./StoreProduct.yaml product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -72,25 +64,25 @@ properties: product_type: type: string title: product_type - description: The item's product type. + description: The ID of the associated product's type. product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the associated product's collection. product_handle: type: string title: product_handle description: The item's product handle. variant: - $ref: ./BaseProductVariant.yaml + $ref: ./StoreProductVariant.yaml variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated product variant. variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -101,43 +93,29 @@ properties: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The associated variant's value for the product's options. + example: + Color: Red requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item's price includes taxes. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: ./IBigNumber.yaml + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: ./IBigNumber.yaml + type: number + title: unit_price + description: The price of a single quantity of the item. tax_lines: type: array description: The item's tax lines. @@ -149,158 +127,70 @@ properties: items: $ref: ./BaseLineItemAdjustment.yaml cart: - $ref: ./BaseCart.yaml + type: object cart_id: type: string title: cart_id - description: The item's cart id. + description: The ID of the cart that the line item belongs to. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string title: created_at - description: The item's created at. + description: The date the item was created. format: date-time updated_at: type: string title: updated_at - description: The item's updated at. + description: The date the item was updated. format: date-time deleted_at: type: string title: deleted_at - description: The item's deleted at. + description: The date the item was deleted. format: date-time original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The item's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The item's total including taxes and promotions. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: item_tax_total + description: The total taxes of the item including promotions. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The item's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The total taxes of the item including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The total discount of the item. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCartResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCartResponse.yaml index 2bfa43f956320..43ad8c70350b7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCartResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCartResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The cart's details. x-schemaName: StoreCartResponse required: - cart diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCartShippingMethod.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCartShippingMethod.yaml new file mode 100644 index 0000000000000..504b272d77b84 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCartShippingMethod.yaml @@ -0,0 +1,115 @@ +type: object +description: A cart's shipping method. +x-schemaName: StoreCartShippingMethod +required: + - id + - cart_id + - name + - amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total +properties: + id: + type: string + title: id + description: The shipping method's ID. + cart_id: + type: string + title: cart_id + description: The ID of the cart this shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount is tax inclusive. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: >- + The shipping method's data, useful for fulfillment handling by third-party + services. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: ./BaseShippingMethodTaxLine.yaml + adjustments: + type: array + description: The shipping method's adjustments, such as applied promotions. + items: + $ref: ./BaseShippingMethodAdjustment.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. + total: + type: number + title: total + description: The shipping method's total amount including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. + discount_total: + type: number + title: discount_total + description: The total amount discounted. + discount_tax_total: + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCollection.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCollection.yaml index a336103bb6af8..b98685c0809eb 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCollection.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCollection.yaml @@ -26,17 +26,17 @@ properties: type: string format: date-time title: created_at - description: The collection's created at. + description: The date the collection was created. updated_at: type: string format: date-time title: updated_at - description: The collection's updated at. + description: The date the collection was updated. deleted_at: type: string format: date-time title: deleted_at - description: The collection's deleted at. + description: The date the collection was deleted. products: type: array description: The collection's products. @@ -44,4 +44,4 @@ properties: $ref: ./AdminProduct.yaml metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCollectionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCollectionResponse.yaml index ad095a583e75b..ee547bec166b1 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCollectionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCollectionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The collection's details. x-schemaName: StoreCollectionResponse required: - collection diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCart.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCart.yaml index 41c5888a13851..69fb5ff088f3a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCart.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCart.yaml @@ -1,11 +1,13 @@ type: object -description: SUMMARY +description: The details of the cart to be created. x-schemaName: StoreCreateCart properties: region_id: type: string title: region_id - description: The cart's region id. + description: >- + The ID of the cart's region. This affects the prices and currency of the + cart. shipping_address: $ref: ./StoreCartAddress.yaml billing_address: @@ -13,12 +15,15 @@ properties: email: type: string title: email - description: The cart's email. + description: The email of the cart's customer. format: email currency_code: type: string title: currency_code - description: The cart's currency code. + description: >- + The cart's currency code. If not provided, the region's currency is used. + This affects prices in the cart, as well. + example: usd items: type: array description: The cart's items. @@ -27,7 +32,10 @@ properties: sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: >- + The ID of the sales channel that cart is created in. Only products + available in that sales channel can be added to the cart. If not provided, + the store's default sales channel is associated with the cart instead. metadata: type: object - description: The cart's metadata. + description: The cart's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCustomer.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCustomer.yaml index f8f116c0fa889..6821b053399fc 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCustomer.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateCustomer.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the customer to create. x-schemaName: StoreCreateCustomer required: - email @@ -27,4 +27,4 @@ properties: description: The customer's phone. metadata: type: object - description: The customer's metadata. + description: The customer's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCreatePaymentCollection.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCreatePaymentCollection.yaml index c88dbe20d2a73..d93623368f5a7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCreatePaymentCollection.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCreatePaymentCollection.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the payment collection to create. x-schemaName: StoreCreatePaymentCollection required: - cart_id @@ -7,4 +7,4 @@ properties: cart_id: type: string title: cart_id - description: The payment collection's cart id. + description: The ID of the cart this payment collection is for. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturn.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturn.yaml index 60c6dc1fd5961..bd5befc29b7c6 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturn.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturn.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the return to create. x-schemaName: StoreCreateReturn required: - order_id @@ -9,7 +9,7 @@ properties: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. items: type: array description: The return's items. @@ -20,12 +20,12 @@ properties: note: type: string title: note - description: The return's note. + description: A note with more details about the return. receive_now: type: boolean title: receive_now - description: The return's receive now. + description: Whether to mark the return as received. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location that items are returned to. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnItem.yaml index 021192cc25bd7..ecdbeb0c2dad0 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnItem.yaml @@ -1,5 +1,5 @@ type: object -description: The item's items. +description: The details of the line item to create. x-schemaName: StoreCreateReturnItem required: - id @@ -16,8 +16,8 @@ properties: reason_id: type: string title: reason_id - description: The item's reason id. + description: The ID of the associated return reason. note: type: string title: note - description: The item's note. + description: A note with more details about the returned item. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnShipping.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnShipping.yaml index ff842a71750be..ee60d6374b1a3 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnShipping.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCreateReturnShipping.yaml @@ -1,5 +1,5 @@ type: object -description: The return's return shipping. +description: The return's shipping details. x-schemaName: StoreCreateReturnShipping required: - option_id @@ -7,8 +7,8 @@ properties: option_id: type: string title: option_id - description: The return shipping's option id. + description: The ID of the shipping option to use. price: type: number title: price - description: The return shipping's price. + description: The shipping's price. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCurrency.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCurrency.yaml index 05eec9f84db00..70e56aa4eb3f2 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCurrency.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCurrency.yaml @@ -8,7 +8,6 @@ required: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at @@ -17,6 +16,7 @@ properties: type: string title: code description: The currency's code. + example: usd symbol: type: string title: symbol @@ -37,33 +37,18 @@ properties: type: number title: rounding description: The currency's rounding. - raw_rounding: - type: object - description: The currency's raw rounding. - required: - - value - - precision - properties: - value: - type: string - title: value - description: The raw rounding's value. - precision: - type: number - title: precision - description: The raw rounding's precision. created_at: type: string format: date-time title: created_at - description: The currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The currency's deleted at. + description: The date the currency was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyListResponse.yaml index cb51836b4b798..349a669091da5 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of currencies. x-schemaName: StoreCurrencyListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The currency's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The currency's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The currency's count. + description: The total count of items. currencies: type: array - description: The currency's currencies. + description: The list of currencies. items: $ref: ./StoreCurrency.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyResponse.yaml index 18fffcdeeb70c..2bb1a6b68ae81 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCurrencyResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The currency's details. x-schemaName: StoreCurrencyResponse required: - currency diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomer.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomer.yaml index c6626ecc9c314..f3028c75589e4 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomer.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomer.yaml @@ -1,5 +1,5 @@ type: object -description: The customer's parent. +description: The customer's details. x-schemaName: StoreCustomer required: - id @@ -14,60 +14,60 @@ properties: id: type: string title: id - description: The parent's ID. + description: The customer's ID. email: type: string title: email - description: The parent's email. + description: The customer's email. format: email default_billing_address_id: type: string title: default_billing_address_id - description: The parent's default billing address id. + description: The ID of the address used for billing by default. default_shipping_address_id: type: string title: default_shipping_address_id - description: The parent's default shipping address id. + description: The ID of the address used for shipping by default. company_name: type: string title: company_name - description: The parent's company name. + description: The customer's company name. first_name: type: string title: first_name - description: The parent's first name. + description: The customer's first name. last_name: type: string title: last_name - description: The parent's last name. + description: The customer's last name. addresses: type: array - description: The parent's addresses. + description: The customer's addresses. items: $ref: ./BaseCustomerAddress.yaml phone: type: string title: phone - description: The parent's phone. + description: The customer's phone. metadata: type: object - description: The parent's metadata. - created_by: - type: string - title: created_by - description: The parent's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The parent's deleted at. + description: The customer's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the customer was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the customer was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the customer was deleted. + created_by: + type: string + title: created_by + description: The customer's created by. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddress.yaml index 8bc8942adb986..4d3108e25f58e 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The customer's address. +description: The customer address's details x-schemaName: StoreCustomerAddress required: - id @@ -28,19 +28,19 @@ properties: address_name: type: string title: address_name - description: The address's address name. + description: The address's name. is_default_shipping: type: boolean title: is_default_shipping - description: The address's is default shipping. + description: Whether the address is used for shipping by default. is_default_billing: type: boolean title: is_default_billing - description: The address's is default billing. + description: Whether the address is used for billing by default. customer_id: type: string title: customer_id - description: The address's customer id. + description: The ID of the customer the address belongs to. company: type: string title: company @@ -56,11 +56,11 @@ properties: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. city: type: string title: city @@ -69,6 +69,7 @@ properties: type: string title: country_code description: The address's country code. + example: usd province: type: string title: province @@ -83,14 +84,14 @@ properties: description: The address's phone. metadata: type: object - description: The address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The address's updated at. + description: The date the address was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressListResponse.yaml index ae6cf1559e412..e04348e7e3694 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of customer addresses. x-schemaName: StoreCustomerAddressListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The customer's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The customer's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The customer's count. + description: The total number of items. addresses: type: array - description: The customer's addresses. + description: The list of addresses. items: $ref: ./StoreCustomerAddress.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressResponse.yaml index a665e19eb1bc4..515fa48b0900f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerAddressResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The address's details. x-schemaName: StoreCustomerAddressResponse required: - address diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerResponse.yaml index c121ca1d700a4..f64fdf1657e95 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreCustomerResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The customer's details. x-schemaName: StoreCustomerResponse required: - customer diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreOrder.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreOrder.yaml index 188ac9c5e53b3..58ff75075f90a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreOrder.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreOrder.yaml @@ -1,5 +1,5 @@ type: object -description: The cart's order. +description: The order's details. x-schemaName: StoreOrder required: - id @@ -51,28 +51,29 @@ properties: region_id: type: string title: region_id - description: The order's region id. + description: The ID of the associated region. customer_id: type: string title: customer_id - description: The order's customer id. + description: The ID of the customer that placed the order. sales_channel_id: type: string title: sales_channel_id - description: The order's sales channel id. + description: The ID of the sales channel the order was placed in. email: type: string title: email - description: The order's email. + description: The email of the customer that placed the order. format: email currency_code: type: string title: currency_code description: The order's currency code. + example: usd display_id: type: number title: display_id - description: The order's display id. + description: The order's display ID. shipping_address: $ref: ./BaseOrderAddress.yaml billing_address: @@ -123,74 +124,69 @@ properties: - shipped - partially_delivered - delivered - transactions: - type: array - description: The order's transactions. - items: - $ref: ./BaseOrderTransaction.yaml summary: $ref: ./BaseOrderSummary.yaml metadata: type: object - description: The order's metadata. + description: The order's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The order's created at. + description: The date the order was created. updated_at: type: string format: date-time title: updated_at - description: The order's updated at. + description: The date the order was updated. original_item_total: type: number title: original_item_total - description: The order's original item total. + description: The order items' total including taxes, excluding promotions. original_item_subtotal: type: number title: original_item_subtotal - description: The order's original item subtotal. + description: The order items' total excluding taxes, including promotions. original_item_tax_total: type: number title: original_item_tax_total - description: The order's original item tax total. + description: The total taxes applied on the order items, excluding promotions. item_total: type: number title: item_total - description: The order's item total. + description: The order items' total including taxes and promotions. item_subtotal: type: number title: item_subtotal - description: The order's item subtotal. + description: The order items' total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The order's item tax total. + description: The total taxes applied on the order's items, including promotions. original_total: type: number title: original_total - description: The order's original total. + description: The order's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The order's original subtotal. + description: The order's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The order's original tax total. + description: The total taxes of the order excluding promotions. total: type: number title: total - description: The order's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The order's subtotal. + description: The order's total excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The order's tax total. + description: The tax totals of the order including promotions. discount_total: type: number title: discount_total @@ -198,7 +194,7 @@ properties: discount_tax_total: type: number title: discount_tax_total - description: The order's discount tax total. + description: The total taxes applied on the discounted amount. gift_card_total: type: number title: gift_card_total @@ -206,28 +202,28 @@ properties: gift_card_tax_total: type: number title: gift_card_tax_total - description: The order's gift card tax total. + description: The total taxes applied on the gift card's amount. shipping_total: type: number title: shipping_total - description: The order's shipping total. + description: The order's shipping total including taxes and promotions. shipping_subtotal: type: number title: shipping_subtotal - description: The order's shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. shipping_tax_total: type: number title: shipping_tax_total - description: The order's shipping tax total. + description: The total taxes of the order's shipping including promotions. original_shipping_total: type: number title: original_shipping_total - description: The order's original shipping total. + description: The order's shipping total including taxes, excluding promotions. original_shipping_subtotal: type: number title: original_shipping_subtotal - description: The order's original shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. original_shipping_tax_total: type: number title: original_shipping_tax_total - description: The order's original shipping tax total. + description: The total taxes of the order's shipping excluding promotions. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreOrderResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreOrderResponse.yaml index c0ce37224487f..a02ddf96b8c1f 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreOrderResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreOrderResponse.yaml @@ -1,8 +1,10 @@ type: object -description: SUMMARY +description: The order's details. x-schemaName: StoreOrderResponse required: - order properties: order: - $ref: ./StoreOrder.yaml + type: string + title: order + description: The order's details. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollection.yaml b/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollection.yaml index 94658ceb27853..01509e2578056 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollection.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollection.yaml @@ -2,12 +2,12 @@ type: object description: The payment collection's details. x-schemaName: StorePaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -20,77 +20,41 @@ properties: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: ./IBigNumber.yaml + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: ./IBigNumber.yaml + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: ./IBigNumber.yaml + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: ./IBigNumber.yaml + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -102,14 +66,16 @@ properties: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: >- + The payment provider used to process the collection's payments and + sessions. items: - $ref: ./BasePaymentProvider.yaml + $ref: ./StorePaymentProvider.yaml payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: ./BasePaymentSession.yaml + $ref: ./StorePaymentSession.yaml payments: type: array description: The payment collection's payments. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollectionResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollectionResponse.yaml index 3f4dd244b05dd..dd6dbcee76b28 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollectionResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StorePaymentCollectionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The payment collection's details. x-schemaName: StorePaymentCollectionResponse required: - payment_collection diff --git a/www/apps/api-reference/specs/admin/components/schemas/StorePaymentSession.yaml b/www/apps/api-reference/specs/admin/components/schemas/StorePaymentSession.yaml new file mode 100644 index 0000000000000..7d6195667e686 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StorePaymentSession.yaml @@ -0,0 +1,61 @@ +type: object +description: The payment session's details. +x-schemaName: StorePaymentSession +properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: >- + The payment session's data, useful for the payment provider processing the + payment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: ./BasePayment.yaml +required: + - id + - amount + - currency_code + - provider_id + - data + - status diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProduct.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProduct.yaml index 7062d98f47e5a..044867e21f250 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreProduct.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProduct.yaml @@ -2,15 +2,14 @@ type: object description: The product's details. x-schemaName: StoreProduct required: + - variants + - options + - images - length - title - status - - options - description - id - - created_at - - updated_at - - variants - handle - subtitle - is_giftcard @@ -24,9 +23,10 @@ required: - material - collection_id - type_id - - images - discountable - external_id + - created_at + - updated_at - deleted_at properties: categories: @@ -56,7 +56,7 @@ properties: type: array description: The product's options. items: - $ref: ./BaseProductOption.yaml + $ref: ./StoreProductOption.yaml description: type: string title: description @@ -67,22 +67,22 @@ properties: description: The product's ID. metadata: type: object - description: The product's metadata. + description: The product's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The product's created at. + description: The date the product was created. updated_at: type: string format: date-time title: updated_at - description: The product's updated at. + description: The date the product was updated. variants: type: array description: The product's variants. items: - $ref: ./BaseProductVariant.yaml + $ref: ./StoreProductVariant.yaml handle: type: string title: handle @@ -94,11 +94,11 @@ properties: is_giftcard: type: boolean title: is_giftcard - description: The product's is giftcard. + description: Whether the product is a gift card. thumbnail: type: string title: thumbnail - description: The product's thumbnail. + description: The product's thumbnail URL. width: type: number title: width @@ -118,45 +118,45 @@ properties: hs_code: type: string title: hs_code - description: The product's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The product's mid code. + description: The product's MID code. material: type: string title: material description: The product's material. collection: - $ref: ./BaseCollection.yaml + $ref: ./StoreCollection.yaml collection_id: type: string title: collection_id - description: The product's collection id. + description: The ID of the collection that the product belongs to. type_id: type: string title: type_id - description: The product's type id. + description: The ID of the product's type. tags: type: array description: The product's tags. items: - $ref: ./BaseProductTag.yaml + $ref: ./StoreProductTag.yaml images: type: array description: The product's images. items: - $ref: ./BaseProductImage.yaml + $ref: ./StoreProductImage.yaml discountable: type: boolean title: discountable - description: The product's discountable. + description: Whether the product can be discounted. external_id: type: string title: external_id - description: The product's external id. + description: The ID of the product in an external service or system. deleted_at: type: string format: date-time title: deleted_at - description: The product's deleted at. + description: The date the product was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategory.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategory.yaml index d164aa2e9c1a2..cea963e49cf72 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategory.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategory.yaml @@ -1,13 +1,11 @@ type: object -description: The category's categories. +description: The category's details. x-schemaName: StoreProductCategory required: - id - name - description - handle - - is_active - - is_internal - rank - parent_category_id - parent_category @@ -37,14 +35,6 @@ properties: type: string title: handle description: The category's handle. - is_active: - type: boolean - title: is_active - description: The category's is active. - is_internal: - type: boolean - title: is_internal - description: The category's is internal. rank: type: number title: rank @@ -52,29 +42,29 @@ properties: parent_category_id: type: string title: parent_category_id - description: The category's parent category id. + description: The ID of the category's parent. parent_category: - $ref: ./BaseProductCategory.yaml + type: object category_children: type: array - description: The category's category children. + description: The category's children. items: - $ref: ./BaseProductCategory.yaml + type: object metadata: type: object - description: The category's metadata. + description: The category's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The category's created at. + description: The date the category was created. updated_at: type: string format: date-time title: updated_at - description: The category's updated at. + description: The date the category was updated. deleted_at: type: string format: date-time title: deleted_at - description: The category's deleted at. + description: The date the category was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryListResponse.yaml index 0b9eedfe4ff7e..124035ab925df 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of product categories. x-schemaName: StoreProductCategoryListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The product category's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product category's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product category's count. + description: The total number of items. product_categories: type: array - description: The product category's product categories. + description: The list of product categories. items: $ref: ./StoreProductCategory.yaml diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryResponse.yaml index 05dc39f8246b9..7530c17d570f7 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductCategoryResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product category's details. x-schemaName: StoreProductCategoryResponse required: - product_category diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductImage.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductImage.yaml new file mode 100644 index 0000000000000..1ad523677df25 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductImage.yaml @@ -0,0 +1,33 @@ +type: object +description: The image's images. +x-schemaName: StoreProductImage +required: + - id + - url +properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's url. + created_at: + type: string + format: date-time + title: created_at + description: The image's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The image's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The image's deleted at. + metadata: + type: object + description: The image's metadata. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductOption.yaml new file mode 100644 index 0000000000000..c256332782f40 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductOption.yaml @@ -0,0 +1,44 @@ +type: object +description: The product option's details. +x-schemaName: StoreProductOption +properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + type: object + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: ./StoreProductOptionValue.yaml + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. +required: + - title + - id diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductOptionValue.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductOptionValue.yaml new file mode 100644 index 0000000000000..9a754c37c21b0 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductOptionValue.yaml @@ -0,0 +1,39 @@ +type: object +description: The product option value's details. +x-schemaName: StoreProductOptionValue +required: + - value + - id +properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + type: object + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductResponse.yaml index ac22f2a56f57c..aab52a7a1d4cf 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreProductResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product's details. x-schemaName: StoreProductResponse required: - product diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductTag.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductTag.yaml new file mode 100644 index 0000000000000..1e31fdb2fbde8 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductTag.yaml @@ -0,0 +1,35 @@ +type: object +description: The tag's details. +x-schemaName: StoreProductTag +properties: + id: + type: string + title: id + description: The tag's ID. + value: + type: string + title: value + description: The tag's value. + created_at: + type: string + format: date-time + title: created_at + description: The date the tag was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tag was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the tag was deleted. + metadata: + type: object + description: The tag's metadata, can hold custom key-value pairs. +required: + - id + - value + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductVariant.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductVariant.yaml new file mode 100644 index 0000000000000..b23029ba471c2 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreProductVariant.yaml @@ -0,0 +1,128 @@ +type: object +description: The variant's variants. +x-schemaName: StoreProductVariant +properties: + options: + type: array + description: The variant's options. + items: + $ref: ./StoreProductOptionValue.yaml + product: + type: object + length: + type: number + title: length + description: The variant's length. + title: + type: string + title: title + description: The variant's title. + metadata: + type: object + description: The variant's metadata. + id: + type: string + title: id + description: The variant's ID. + width: + type: number + title: width + description: The variant's width. + weight: + type: number + title: weight + description: The variant's weight. + height: + type: number + title: height + description: The variant's height. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + hs_code: + type: string + title: hs_code + description: The variant's hs code. + mid_code: + type: string + title: mid_code + description: The variant's mid code. + material: + type: string + title: material + description: The variant's material. + created_at: + type: string + format: date-time + title: created_at + description: The variant's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The variant's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The variant's deleted at. + product_id: + type: string + title: product_id + description: The variant's product id. + sku: + type: string + title: sku + description: The variant's sku. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's ean. + upc: + type: string + title: upc + description: The variant's upc. + allow_backorder: + type: boolean + title: allow_backorder + description: The variant's allow backorder. + manage_inventory: + type: boolean + title: manage_inventory + description: The variant's manage inventory. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. + variant_rank: + type: number + title: variant_rank + description: The variant's variant rank. + calculated_price: + $ref: ./BaseCalculatedPriceSet.yaml +required: + - options + - length + - title + - id + - width + - weight + - height + - origin_country + - hs_code + - mid_code + - material + - created_at + - updated_at + - deleted_at + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreProductVariantParams.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreProductVariantParams.yaml deleted file mode 100644 index 295b3c1fdd4ba..0000000000000 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreProductVariantParams.yaml +++ /dev/null @@ -1,76 +0,0 @@ -type: object -description: The product's variants. -x-schemaName: StoreProductVariantParams -properties: - q: - type: string - title: q - description: The variant's q. - id: - oneOf: - - type: string - title: id - description: The variant's ID. - - type: array - description: The variant's ID. - items: - type: string - title: id - description: The id's ID. - sku: - oneOf: - - type: string - title: sku - description: The variant's sku. - - type: array - description: The variant's sku. - items: - type: string - title: sku - description: The sku's details. - product_id: - oneOf: - - type: string - title: product_id - description: The variant's product id. - - type: array - description: The variant's product id. - items: - type: string - title: product_id - description: The product id's details. - options: - type: object - description: The variant's options. - limit: - type: number - title: limit - description: The variant's limit. - offset: - type: number - title: offset - description: The variant's offset. - order: - type: string - title: order - description: The variant's order. - fields: - type: string - title: fields - description: The variant's fields. - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $or diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreRegion.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreRegion.yaml index d07d5098a6885..8a7250fc7af8d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreRegion.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreRegion.yaml @@ -1,5 +1,5 @@ type: object -description: The region's details. +description: The parent's region. x-schemaName: StoreRegion required: - id diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreReturn.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreReturn.yaml index 4f35c16688439..afdc2d750a994 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreReturn.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreReturn.yaml @@ -2,11 +2,11 @@ type: object description: The return's details. x-schemaName: StoreReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -18,54 +18,68 @@ properties: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. status: - type: string - title: status + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. description: The return's status. exchange_id: type: string title: exchange_id - description: The return's exchange id. + description: The ID of the associated exchange. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location the items are returned to. claim_id: type: string title: claim_id - description: The return's claim id. + description: The ID of the associated claim. order_version: type: number title: order_version - description: The return's order version. + description: The version of the order when the return is applied. display_id: type: number title: display_id - description: The return's display id. + description: The return's display ID. no_notification: type: boolean title: no_notification - description: The return's no notification. + description: Whether the customer should receive updates about changes in the return. refund_amount: type: number title: refund_amount - description: The return's refund amount. + description: The return's refunded amount. items: type: array description: The return's items. items: - $ref: ./BaseReturnItem.yaml + $ref: ./StoreReturnItem.yaml received_at: type: string title: received_at - description: The return's received at. + description: The date the return was received. created_at: type: string format: date-time title: created_at - description: The return's created at. + description: The date the return was created. canceled_at: type: string title: canceled_at - description: The return's canceled at. + description: The date the return was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreReturnItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnItem.yaml new file mode 100644 index 0000000000000..ed855a643f027 --- /dev/null +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnItem.yaml @@ -0,0 +1,46 @@ +type: object +description: The item's items. +x-schemaName: StoreReturnItem +properties: + id: + type: string + title: id + description: The item's ID. + quantity: + type: number + title: quantity + description: The item's quantity. + received_quantity: + type: number + title: received_quantity + description: The item's received quantity. + damaged_quantity: + type: number + title: damaged_quantity + description: The item's damaged quantity. + reason_id: + type: string + title: reason_id + description: The item's reason id. + note: + type: string + title: note + description: The item's note. + item_id: + type: string + title: item_id + description: The item's item id. + return_id: + type: string + title: return_id + description: The item's return id. + metadata: + type: object + description: The item's metadata. +required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReason.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReason.yaml index 0b2be3c0f31ee..b08051fb32484 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReason.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReason.yaml @@ -26,14 +26,14 @@ properties: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReasonResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReasonResponse.yaml index 19edb6a5210c1..b3071e44278bf 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReasonResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnReasonResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return reason's details. x-schemaName: StoreReturnReasonResponse required: - return_reason diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreReturnResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnResponse.yaml index bac852445971e..6dc083e1d5a0b 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreReturnResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreReturnResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return's details. x-schemaName: StoreReturnResponse required: - return diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOption.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOption.yaml index 13a1160363e26..1c4c7d291903d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOption.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOption.yaml @@ -1,66 +1,48 @@ type: object -description: The shipping option's shipping options. +description: The shipping option's details. x-schemaName: StoreShippingOption required: - id - - name - - price_type - - service_zone_id - - provider_id - - provider - - shipping_option_type_id - - type - - shipping_profile_id - - amount - - is_tax_inclusive - - data - - metadata + - label + - description + - code + - shipping_option_id + - created_at + - updated_at + - deleted_at properties: id: type: string title: id description: The shipping option's ID. - name: + label: type: string - title: name - description: The shipping option's name. - price_type: + title: label + description: The type's label. + description: type: string - description: The shipping option's price type. - enum: - - flat - - calculated - service_zone_id: + title: description + description: The type's description. + code: type: string - title: service_zone_id - description: The shipping option's service zone id. - provider_id: + title: code + description: The type's code. + shipping_option_id: type: string - title: provider_id - description: The shipping option's provider id. - provider: - $ref: ./BaseFulfillmentProvider.yaml - shipping_option_type_id: + title: shipping_option_id + description: The type's shipping option id. + created_at: type: string - title: shipping_option_type_id - description: The shipping option's shipping option type id. - type: - type: object - shipping_profile_id: + format: date-time + title: created_at + description: The type's created at. + updated_at: type: string - title: shipping_profile_id - description: The shipping option's shipping profile id. - amount: - type: number - title: amount - description: The shipping option's amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping option's is tax inclusive. - data: - type: object - description: The shipping option's data. - metadata: - type: object - description: The shipping option's metadata. + format: date-time + title: updated_at + description: The type's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The type's deleted at. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOptionListResponse.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOptionListResponse.yaml index 8001c7a8c53d0..695f2175b173a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOptionListResponse.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreShippingOptionListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The shipping option's details. x-schemaName: StoreShippingOptionListResponse required: - shipping_options diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCartLineItem.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCartLineItem.yaml index a6468aab56d5f..844c2958cea64 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCartLineItem.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCartLineItem.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in the line item. x-schemaName: StoreUpdateCartLineItem required: - quantity @@ -7,7 +7,7 @@ properties: quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. + description: The item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCustomer.yaml b/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCustomer.yaml index f3f14b1f5e81a..0eaa5dda8bc1a 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCustomer.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/StoreUpdateCustomer.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in the customer. x-schemaName: StoreUpdateCustomer properties: company_name: diff --git a/www/apps/api-reference/specs/admin/components/schemas/UpdateAddress.yaml b/www/apps/api-reference/specs/admin/components/schemas/UpdateAddress.yaml index 0338cc6658643..22025cb22d6df 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/UpdateAddress.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/UpdateAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The cart's shipping address. +description: The details to update in the address. x-schemaName: UpdateAddress required: - id @@ -7,51 +7,52 @@ properties: id: type: string title: id - description: The shipping address's ID. + description: The ID of an existing address to update. customer_id: type: string title: customer_id - description: The shipping address's customer id. + description: The ID of the customer that this address belongs to. company: type: string title: company - description: The shipping address's company. + description: The address's company. first_name: type: string title: first_name - description: The shipping address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The shipping address's last name. + description: The address's last name. address_1: type: string title: address_1 - description: The shipping address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The shipping address's address 2. + description: The address's second line. city: type: string title: city - description: The shipping address's city. + description: The address's city. country_code: type: string title: country_code - description: The shipping address's country code. + description: The address's country code. + example: usd province: type: string title: province - description: The shipping address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The shipping address's postal code. + description: The address's postal code. phone: type: string title: phone - description: The shipping address's phone. + description: The address's phone. metadata: type: object - description: The shipping address's metadata. + description: The address's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/UpdateCartData.yaml b/www/apps/api-reference/specs/admin/components/schemas/UpdateCartData.yaml index 0b29d94268647..32376f2c2f892 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/UpdateCartData.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/UpdateCartData.yaml @@ -1,36 +1,41 @@ type: object -description: SUMMARY +description: The details to update in a cart. x-schemaName: UpdateCartData properties: region_id: type: string title: region_id - description: The cart's region id. + description: >- + The ID of the associated region. This can affect the prices and currency + code of the cart. customer_id: type: string title: customer_id - description: The cart's customer id. + description: The ID of the customer that the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: >- + The ID of the associated sales channel. Only products available in this + channel can be added to the cart. email: type: string title: email - description: The cart's email. + description: The email of the customer that the cart belongs to. format: email currency_code: type: string title: currency_code description: The cart's currency code. + example: usd shipping_address_id: type: string title: shipping_address_id - description: The cart's shipping address id. + description: The ID of the cart's shipping address. billing_address_id: type: string title: billing_address_id - description: The cart's billing address id. + description: The ID of the cart's billing address. billing_address: oneOf: - $ref: ./CreateAddress.yaml @@ -41,4 +46,4 @@ properties: - $ref: ./UpdateAddress.yaml metadata: type: object - description: The cart's metadata. + description: The cart's metadata, ca hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/admin/components/schemas/WorkflowExecutionContext.yaml b/www/apps/api-reference/specs/admin/components/schemas/WorkflowExecutionContext.yaml index 2d20174121a20..2f04930503487 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/WorkflowExecutionContext.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/WorkflowExecutionContext.yaml @@ -8,6 +8,30 @@ properties: data: type: object description: The context's data. + properties: + invoke: + type: object + description: The step's invokation details. + required: + - output + additionalProperties: + type: object + properties: + output: + type: object + description: The invokation's details. + required: + - output + - compensateInput + properties: + output: + description: the step's output + compensateInput: + description: the compensation function's input. + payload: + description: the payload of the transaction. + required: + - invoke compensate: type: object description: The context's compensate. @@ -16,4 +40,20 @@ properties: description: The context's errors. items: type: object - description: The error's errors. + description: The error's details. + properties: + error: + type: object + description: The error's details. + action: + type: string + title: action + description: The error's action. + handlerType: + type: string + title: handlerType + description: The error's handler type. + required: + - error + - action + - handlerType diff --git a/www/apps/api-reference/specs/admin/openapi.full.yaml b/www/apps/api-reference/specs/admin/openapi.full.yaml index 765940c10009c..dc76d6ab53ff6 100644 --- a/www/apps/api-reference/specs/admin/openapi.full.yaml +++ b/www/apps/api-reference/specs/admin/openapi.full.yaml @@ -573,10 +573,13 @@ paths: description: Filter by the API key's type. required: false schema: - type: string - enum: - - secret - - publishable + oneOf: + - type: string + title: type + description: The api key's type. + - type: string + title: type + description: The api key's type. - name: created_at in: query description: Filter by the API key's creation date. @@ -10973,7 +10976,7 @@ paths: $ref: '#/components/responses/invalid_request_error' '500': $ref: '#/components/responses/500_error' - x-workflow: deleteCustomersWorkflow + x-workflow: removeCustomerAccountWorkflow /admin/customers/{id}/addresses: get: operationId: GetCustomersIdAddresses @@ -14749,22 +14752,6 @@ paths: required: true schema: type: string - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields - in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - required: false - schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. security: - api_token: [] - cookie_auth: [] @@ -20196,7 +20183,8 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/AdminArchiveOrder' + type: object + description: SUMMARY x-codeSamples: - lang: Shell label: cURL @@ -20654,12 +20642,11 @@ paths: '500': $ref: '#/components/responses/500_error' x-workflow: cancelOrderFulfillmentWorkflow - /admin/orders/{id}/fulfillments/{fulfillment_id}/shipments: + /admin/orders/{id}/fulfillments/{fulfillment_id}/mark-as-delivered: post: - operationId: PostOrdersIdFulfillmentsFulfillment_idShipments - summary: Create Shipment for an Order's Fulfillment - x-sidebar-summary: Create Shipment - description: Create a shipment for an order's fulfillment. + operationId: PostOrdersIdFulfillmentsFulfillment_idMarkAsDelivered + summary: Add Mark As Delivered to Order + description: Add a Mark As Delivered to a order x-authenticated: true parameters: - name: id @@ -20670,7 +20657,7 @@ paths: type: string - name: fulfillment_id in: path - description: The fulfillment's ID. + description: The order's fulfillment id. required: true schema: type: string @@ -20684,7 +20671,10 @@ paths: description: Comma-separated relations that should be expanded in the returned data. - name: fields in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + description: |- + Comma-separated fields that should be included in the returned data. + * if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. + * without prefix it will replace the entire default fields. required: false schema: type: string @@ -20698,128 +20688,12 @@ paths: content: application/json: schema: - allOf: - - type: object - description: The shipment's details. - required: - - items - - metadata - properties: - items: - type: array - description: The items to create shipment for. - items: - type: object - description: The details of the item to create shipment for. - required: - - id - - quantity - properties: - id: - type: string - title: id - description: The item's ID. - quantity: - type: number - title: quantity - description: The item's quantity to ship. - labels: - type: array - description: The labels to create for the shipment. - items: - type: object - description: The label's labels. - required: - - tracking_number - - tracking_url - - label_url - properties: - tracking_number: - type: string - title: tracking_number - description: The label's tracking number. - tracking_url: - type: string - title: tracking_url - description: The label's tracking url. - label_url: - type: string - title: label_url - description: The label's url. - no_notification: - type: boolean - title: no_notification - description: Whether to send the customer a notification about the created shipment. - metadata: - type: object - description: The shipment's metadata. Can hold custom key-value pairs. - - type: object - description: The shipment's details. - properties: - additional_data: - type: object - description: Pass additional custom data to the API route. This data is passed to the underlying workflow under the `additional_data` parameter. - description: The shipment's details. + $ref: '#/components/schemas/AdminMarkOrderFulfillmentDelivered' x-codeSamples: - lang: Shell label: cURL source: |- - curl -X POST '{backend_url}/admin/orders/{id}/fulfillments/{fulfillment_id}/shipments' \ - -H 'Authorization: Bearer {access_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ - "items": [ - { - "id": "id_3QQtl2VvE73c", - "quantity": 6772917941567488 - } - ], - "metadata": {} - }' - tags: - - Orders - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminOrderResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: createOrderShipmentWorkflow - /admin/orders/{id}/preview: - get: - operationId: GetOrdersIdPreview - summary: Get Preview - description: Retrieve a preview of an order using its associated change, such as an edit. - x-authenticated: true - parameters: - - name: id - in: path - description: The order's ID. - required: true - schema: - type: string - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl '{backend_url}/admin/orders/{id}/preview' \ + curl -X POST '{backend_url}/admin/orders/{id}/fulfillments/{fulfillment_id}/mark-as-delivered' \ -H 'Authorization: Bearer {access_token}' tags: - Orders @@ -20829,7 +20703,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/AdminOrderPreviewResponse' + $ref: '#/components/schemas/AdminOrderResponse' '400': $ref: '#/components/responses/400_error' '401': @@ -20842,139 +20716,328 @@ paths: $ref: '#/components/responses/invalid_request_error' '500': $ref: '#/components/responses/500_error' - /admin/payment-collections: + x-workflow: markOrderFulfillmentAsDeliveredWorkflow + /admin/orders/{id}/fulfillments/{fulfillment_id}/shipments: post: - operationId: PostPaymentCollections - summary: Create Payment Collection - description: Create a payment collection. - x-authenticated: true - parameters: - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields - in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - required: false - schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - requestBody: - content: - application/json: - schema: - type: object - description: The payment collection's details. - required: - - order_id - - amount - properties: - order_id: - type: string - title: order_id - description: The ID of the associated order. - amount: - type: number - title: amount - description: The amount to be paid. - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/payment-collections' \ - -H 'Authorization: Bearer {access_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ - "order_id": "{value}" - }' - tags: - - Payment Collections - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminPaymentCollectionResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: createOrderPaymentCollectionWorkflow - /admin/payment-collections/{id}: - delete: - operationId: DeletePaymentCollectionsId - summary: Delete a Payment Collection - description: Delete a payment collection. + operationId: PostOrdersIdFulfillmentsFulfillment_idShipments + summary: Create Shipment for an Order's Fulfillment + x-sidebar-summary: Create Shipment + description: Create a shipment for an order's fulfillment. x-authenticated: true parameters: - name: id in: path - description: The payment collection's ID. + description: The order's ID. required: true schema: type: string - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X DELETE '{backend_url}/admin/payment-collections/{id}' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Payment Collections - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminDeletePaymentCollectionResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: deleteOrderPaymentCollections - /admin/payment-collections/{id}/mark-as-paid: - post: - operationId: PostPaymentCollectionsIdMarkAsPaid - summary: Mark a Payment Collection as Paid - x-sidebar-summary: Mark as Paid - description: Mark a payment collection as paid. This creates and authorizes a payment session, then capture its payment, using the manual payment provider. - x-authenticated: true - parameters: - - name: id + - name: fulfillment_id in: path - description: The payment collection's ID. + description: The fulfillment's ID. + required: true + schema: + type: string + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + allOf: + - type: object + description: The shipment's details. + required: + - items + - metadata + properties: + items: + type: array + description: The items to create shipment for. + items: + type: object + description: The details of the item to create shipment for. + required: + - id + - quantity + properties: + id: + type: string + title: id + description: The item's ID. + quantity: + type: number + title: quantity + description: The item's quantity to ship. + labels: + type: array + description: The labels to create for the shipment. + items: + type: object + description: The label's labels. + required: + - tracking_number + - tracking_url + - label_url + properties: + tracking_number: + type: string + title: tracking_number + description: The label's tracking number. + tracking_url: + type: string + title: tracking_url + description: The label's tracking url. + label_url: + type: string + title: label_url + description: The label's url. + no_notification: + type: boolean + title: no_notification + description: Whether to send the customer a notification about the created shipment. + metadata: + type: object + description: The shipment's metadata. Can hold custom key-value pairs. + - type: object + description: The shipment's details. + properties: + additional_data: + type: object + description: Pass additional custom data to the API route. This data is passed to the underlying workflow under the `additional_data` parameter. + description: The shipment's details. + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/orders/{id}/fulfillments/{fulfillment_id}/shipments' \ + -H 'Authorization: Bearer {access_token}' \ + -H 'Content-Type: application/json' \ + --data-raw '{ + "items": [ + { + "id": "id_3QQtl2VvE73c", + "quantity": 6772917941567488 + } + ], + "metadata": {} + }' + tags: + - Orders + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminOrderResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: createOrderShipmentWorkflow + /admin/orders/{id}/preview: + get: + operationId: GetOrdersIdPreview + summary: Get Preview + description: Retrieve a preview of an order using its associated change, such as an edit. + x-authenticated: true + parameters: + - name: id + in: path + description: The order's ID. + required: true + schema: + type: string + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl '{backend_url}/admin/orders/{id}/preview' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Orders + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminOrderPreviewResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + /admin/payment-collections: + post: + operationId: PostPaymentCollections + summary: Create Payment Collection + description: Create a payment collection. + x-authenticated: true + parameters: + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + type: object + description: The payment collection's details. + required: + - order_id + - amount + properties: + order_id: + type: string + title: order_id + description: The ID of the associated order. + amount: + type: number + title: amount + description: The amount to be paid. + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/payment-collections' \ + -H 'Authorization: Bearer {access_token}' \ + -H 'Content-Type: application/json' \ + --data-raw '{ + "order_id": "{value}" + }' + tags: + - Payment Collections + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminPaymentCollectionResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: createOrderPaymentCollectionWorkflow + /admin/payment-collections/{id}: + delete: + operationId: DeletePaymentCollectionsId + summary: Delete a Payment Collection + description: Delete a payment collection. + x-authenticated: true + parameters: + - name: id + in: path + description: The payment collection's ID. + required: true + schema: + type: string + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X DELETE '{backend_url}/admin/payment-collections/{id}' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Payment Collections + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminDeletePaymentCollectionResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: deleteOrderPaymentCollections + /admin/payment-collections/{id}/mark-as-paid: + post: + operationId: PostPaymentCollectionsIdMarkAsPaid + summary: Mark a Payment Collection as Paid + x-sidebar-summary: Mark as Paid + description: Mark a payment collection as paid. This creates and authorizes a payment session, then capture its payment, using the manual payment provider. + x-authenticated: true + parameters: + - name: id + in: path + description: The payment collection's ID. required: true schema: type: string @@ -22576,8 +22639,8 @@ paths: description: A price's details. required: - currency_code - - amount - variant_id + - amount properties: currency_code: type: string @@ -25308,7 +25371,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/AdminCreateProduct' + $ref: '#/components/schemas/AdminCreateProductType' x-codeSamples: - lang: Shell label: cURL @@ -26629,495 +26692,2705 @@ paths: type: string title: collection_id description: A product collection's ID. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl '{backend_url}/admin/products' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products - responses: - '200': - description: OK - content: - application/json: - schema: - allOf: - - type: object - description: The paginated list of products. - required: - - limit - - offset - - count - properties: - limit: - type: number - title: limit - description: The maximum number of items returned. - offset: - type: number - title: offset - description: The number of items skipped before retrieving the returned items. - count: - type: number - title: count - description: The total number of items. - - type: object - description: The paginated list of products. - required: - - products - properties: - products: - type: array - description: The list of products. - items: - type: object - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - post: - operationId: PostProducts - summary: Create Product - description: Create a product. - x-authenticated: true - parameters: - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields + - name: variants in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + description: The product's variants. required: false schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - requestBody: - content: - application/json: - schema: - allOf: - - $ref: '#/components/schemas/AdminCreateProduct' - - type: object - description: The product's details. - properties: - additional_data: + type: object + description: The product's variants. + x-schemaName: AdminProductVariantParams + properties: + q: + type: string + title: q + description: The variant's q. + id: + oneOf: + - type: string + title: id + description: The variant's ID. + - type: array + description: The variant's ID. + items: + type: string + title: id + description: The id's ID. + manage_inventory: + type: boolean + title: manage_inventory + description: The variant's manage inventory. + allow_backorder: + type: boolean + title: allow_backorder + description: The variant's allow backorder. + created_at: + type: object + description: The variant's created at. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: type: object - description: Pass additional custom data to the API route. This data is passed to the underlying workflow under the `additional_data` parameter. - description: The product's details. - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/products' \ - -H 'Authorization: Bearer {access_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ - "title": "{value}" - }' - tags: - - Products - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminProductResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: createProductsWorkflow - /admin/products/batch: - post: - operationId: PostProductsBatch - summary: Manage Products - description: Manage products to create, update, or delete them. - x-authenticated: true - parameters: - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields - in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - required: false - schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/AdminBatchProductRequest' - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/products/batch' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminBatchProductResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: batchProductsWorkflow - /admin/products/export: - post: - operationId: PostProductsExport - summary: Export Products - description: | - Start a product export process to retrieve a CSV of exported products. - - You'll receive in the response the transaction ID of the workflow generating the CSV file. To check the status of the execution, send a GET request to `/admin/workflows-executions/export-products/:transaction-id`. - Once the execution finishes successfully, a notification is created for the export. You can retrieve the notifications using the `/admin/notification` API route to retrieve the file's download URL. - x-authenticated: true - parameters: - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields - in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - required: false - schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/products/export' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products - responses: - '202': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminExportProductResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: exportProductsWorkflow - /admin/products/import: - post: - operationId: PostProductsImport - summary: Create Product Import - description: Create a new product import process. The products aren't imported until the import is confirmed with the `/admin/products/:transaction-id/import` API route. - x-authenticated: true - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/AdminImportProductRequest' - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/products/import' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products - responses: - '202': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminImportProductResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: importProductsWorkflow - /admin/products/import/{transaction_id}/confirm: - post: - operationId: PostProductsImportTransaction_idConfirm - summary: Confirm Product Import - description: Confirm that a created product import should start importing the products into Medusa. - x-authenticated: true - parameters: - - name: transaction_id - in: path - description: The ID of the transaction returned when the product import was created. - required: true - schema: - type: string - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/products/import/{transaction_id}/confirm' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products - responses: - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: importProductsWorkflowId - /admin/products/{id}: - get: - operationId: GetProductsId - summary: Get a Product - description: Retrieve a product by its ID. You can expand the product's relations or select the fields that should be returned. - x-authenticated: true - parameters: - - name: id - in: path - description: The product's ID. - required: true - schema: - type: string - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields - in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - required: false - schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl '{backend_url}/admin/products/{id}' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminProductResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - post: - operationId: PostProductsId - summary: Update a Product - description: Update a product's details. - x-authenticated: true - parameters: - - name: id - in: path - description: The product's ID. - required: true - schema: - type: string - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields - in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - required: false - schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - requestBody: - content: - application/json: - schema: - allOf: - - $ref: '#/components/schemas/AdminUpdateProduct' - - type: object - description: The properties to update in a product. - properties: - additional_data: + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: type: object - description: Pass additional custom data to the API route. This data is passed to the underlying workflow under the `additional_data` parameter. - description: The properties to update in a product. - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/products/{id}' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/AdminProductResponse' - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: updateProductsWorkflow - delete: - operationId: DeleteProductsId - summary: Delete a Product - description: Delete a product. - x-authenticated: true - parameters: - - name: id - in: path - description: The product's ID. - required: true - schema: - type: string - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X DELETE '{backend_url}/admin/products/{id}' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Products + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + updated_at: + type: object + description: The variant's updated at. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + deleted_at: + type: object + description: The variant's deleted at. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + limit: + type: number + title: limit + description: Limit the number of items returned in the list. + offset: + type: number + title: offset + description: The number of items to skip when retrieving a list. + order: + type: string + title: order + description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + fields: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl '{backend_url}/admin/products' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products + responses: + '200': + description: OK + content: + application/json: + schema: + allOf: + - type: object + description: The paginated list of products. + required: + - limit + - offset + - count + properties: + limit: + type: number + title: limit + description: The maximum number of items returned. + offset: + type: number + title: offset + description: The number of items skipped before retrieving the returned items. + count: + type: number + title: count + description: The total number of items. + - type: object + description: The paginated list of products. + required: + - products + properties: + products: + type: array + description: The list of products. + items: + type: object + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + post: + operationId: PostProducts + summary: Create Product + description: Create a product. + x-authenticated: true + parameters: + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + allOf: + - $ref: '#/components/schemas/AdminCreateProduct' + - type: object + description: The product's details. + properties: + additional_data: + type: object + description: Pass additional custom data to the API route. This data is passed to the underlying workflow under the `additional_data` parameter. + description: The product's details. + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/products' \ + -H 'Authorization: Bearer {access_token}' \ + -H 'Content-Type: application/json' \ + --data-raw '{ + "title": "{value}" + }' + tags: + - Products + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminProductResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: createProductsWorkflow + /admin/products/batch: + post: + operationId: PostProductsBatch + summary: Manage Products + description: Manage products to create, update, or delete them. + x-authenticated: true + parameters: + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AdminBatchProductRequest' + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/products/batch' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminBatchProductResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: batchProductsWorkflow + /admin/products/export: + post: + operationId: PostProductsExport + summary: Export Products + description: | + Start a product export process to retrieve a CSV of exported products. + + You'll receive in the response the transaction ID of the workflow generating the CSV file. To check the status of the execution, send a GET request to `/admin/workflows-executions/export-products/:transaction-id`. + Once the execution finishes successfully, a notification is created for the export. You can retrieve the notifications using the `/admin/notification` API route to retrieve the file's download URL. + x-authenticated: true + parameters: + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/products/export' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products + responses: + '202': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminExportProductResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: exportProductsWorkflow + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AdminExportProductRequest' + /admin/products/import: + post: + operationId: PostProductsImport + summary: Create Product Import + description: Create a new product import process. The products aren't imported until the import is confirmed with the `/admin/products/:transaction-id/import` API route. + x-authenticated: true + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AdminImportProductRequest' + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/products/import' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products + responses: + '202': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminImportProductResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: importProductsWorkflow + /admin/products/import/{transaction_id}/confirm: + post: + operationId: PostProductsImportTransaction_idConfirm + summary: Confirm Product Import + description: Confirm that a created product import should start importing the products into Medusa. + x-authenticated: true + parameters: + - name: transaction_id + in: path + description: The ID of the transaction returned when the product import was created. + required: true + schema: + type: string + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/products/import/{transaction_id}/confirm' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products + responses: + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: importProductsWorkflowId + /admin/products/{id}: + get: + operationId: GetProductsId + summary: Get a Product + description: Retrieve a product by its ID. You can expand the product's relations or select the fields that should be returned. + x-authenticated: true + parameters: + - name: id + in: path + description: The product's ID. + required: true + schema: + type: string + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl '{backend_url}/admin/products/{id}' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminProductResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + post: + operationId: PostProductsId + summary: Update a Product + description: Update a product's details. + x-authenticated: true + parameters: + - name: id + in: path + description: The product's ID. + required: true + schema: + type: string + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + allOf: + - $ref: '#/components/schemas/AdminUpdateProduct' + - type: object + description: The properties to update in a product. + properties: + additional_data: + type: object + description: Pass additional custom data to the API route. This data is passed to the underlying workflow under the `additional_data` parameter. + description: The properties to update in a product. + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/products/{id}' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/AdminProductResponse' + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: updateProductsWorkflow + delete: + operationId: DeleteProductsId + summary: Delete a Product + description: Delete a product. + x-authenticated: true + parameters: + - name: id + in: path + description: The product's ID. + required: true + schema: + type: string + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X DELETE '{backend_url}/admin/products/{id}' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Products responses: '200': description: OK @@ -28313,9 +30586,9 @@ paths: type: object description: The associations to create between a product variant and an inventory item. required: - - required_quantity - - inventory_item_id - variant_id + - inventory_item_id + - required_quantity properties: required_quantity: type: number @@ -28336,9 +30609,9 @@ paths: type: object description: Update a product variant's association with an inventory item. required: - - required_quantity - - inventory_item_id - variant_id + - inventory_item_id + - required_quantity properties: required_quantity: type: number @@ -28359,8 +30632,8 @@ paths: type: object description: Delete a product variant's association with an inventory item. required: - - inventory_item_id - variant_id + - inventory_item_id properties: inventory_item_id: type: string @@ -29747,13 +32020,15 @@ paths: get: operationId: GetPromotionsRuleAttributeOptionsRule_type summary: List Rule Attribute Options of a Rule Type - x-sidebar-summary: List Rule Attribute Options + x-sidebar-summary: List Potential Rule Attributes description: | - Retrieve a list of attributes for the promotion and application method types specified in the query parameters. + Retrieve a list of potential rule attributes for the promotion and application method types specified in the query parameters. Only the attributes of the rule type specified in the path parameter are retrieved: - If `rule_type` is `rules`, the attributes of the promotion's type are retrieved. - - If `rule_type` is `target-rules`, the target rules' attributes of the application method's type are retrieved. - If `rule_type` is `buy-rules`, the buy rules' attributes of the application method's type are retrieved. + - If `rule_type` is `target-rules`, the target rules' attributes of the application method's type are retrieved. + + - If `rule_type` is `buy-rules`, the buy rules' attributes of the application method's type are retrieved. x-authenticated: true parameters: - name: rule_type @@ -30270,9 +32545,9 @@ paths: type: object description: A buy rule's details. required: + - values - operator - attribute - - values properties: operator: type: string @@ -30298,15 +32573,33 @@ paths: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The create's values. - type: array - description: The allowed attribute values. + description: The create's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The create's values. + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The create's values. update: type: array description: The buy rules to update. @@ -30314,24 +32607,44 @@ paths: type: object description: The properties to update in a buy rule. required: - - id - values + - id properties: id: type: string title: id description: The buy rule's ID. operator: - type: string + oneOf: + - type: string + description: The update's operator. + enum: + - GTE + - type: string + description: The update's operator. + enum: + - LTE + - type: string + description: The update's operator. + enum: + - GT + - type: string + description: The update's operator. + enum: + - LT + - type: string + description: The update's operator. + enum: + - EQ + - type: string + description: The update's operator. + enum: + - NE + - type: string + description: The update's operator. + enum: + - IN description: The operator used to check whether the buy rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - enum: - - gte - - lte - - gt - - lt - - eq - - ne - - in description: type: string title: description @@ -30345,15 +32658,33 @@ paths: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The update's values. - type: array - description: The allowed attribute values. + description: The update's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The update's values. delete: type: array description: The buy rules to delete. @@ -30468,229 +32799,22 @@ paths: application/json: schema: type: object - description: The rules to create, update, or delete. - properties: - create: - type: array - description: The rules to create. - items: - type: object - description: A rule's details. - required: - - operator - - attribute - - values - properties: - operator: - type: string - description: The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - enum: - - gte - - lte - - gt - - lt - - eq - - ne - - in - description: - type: string - title: description - description: The rule's description. - attribute: - type: string - title: attribute - description: The attribute to compare against when checking whether a promotion can be applied on a cart. - example: items.product.id - values: - oneOf: - - type: string - title: values - description: The attribute's value. - example: prod_123 - - type: array - description: The allowed attribute values. - items: - type: string - title: values - description: An attribute value. - example: prod_123 - update: - type: array - description: The rules to update. - items: - type: object - description: The properties to update in a rule. - required: - - id - - values - properties: - id: - type: string - title: id - description: The rule's ID. - operator: - type: string - description: The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - enum: - - gte - - lte - - gt - - lt - - eq - - ne - - in - description: - type: string - title: description - description: The rule's description. - attribute: - type: string - title: attribute - description: The attribute to compare against when checking whether a promotion can be applied on a cart. - example: items.product.id - values: - oneOf: - - type: string - title: values - description: The attribute's value. - example: prod_123 - - type: array - description: The allowed attribute values. - items: - type: string - title: values - description: An attribute value. - example: prod_123 - delete: - type: array - description: The rules to delete. - items: - type: string - title: delete - description: A rule's ID. - x-codeSamples: - - lang: Shell - label: cURL - source: |- - curl -X POST '{backend_url}/admin/promotions/{id}/rules/batch' \ - -H 'Authorization: Bearer {access_token}' - tags: - - Promotions - responses: - '200': - description: OK - content: - application/json: - schema: - type: object - description: The result of the batch operations. - required: - - created - - updated - - deleted - properties: - created: - type: array - description: The created rules. - items: - $ref: '#/components/schemas/AdminPromotionRule' - updated: - type: array - description: The updated rules. - items: - $ref: '#/components/schemas/AdminPromotionRule' - deleted: - type: object - description: The details of the deleted buy rules. - required: - - ids - - object - - deleted - properties: - ids: - type: array - description: The IDs of the deleted rules. - items: - type: string - title: ids - description: A rule's ID. - object: - type: string - title: object - description: The name of the object that was deleted. - default: promotion-rule - deleted: - type: boolean - title: deleted - description: Whether the rules were deleted. - '400': - $ref: '#/components/responses/400_error' - '401': - $ref: '#/components/responses/unauthorized' - '404': - $ref: '#/components/responses/not_found_error' - '409': - $ref: '#/components/responses/invalid_state_error' - '422': - $ref: '#/components/responses/invalid_request_error' - '500': - $ref: '#/components/responses/500_error' - x-workflow: batchPromotionRulesWorkflow - /admin/promotions/{id}/target-rules/batch: - post: - operationId: PostPromotionsIdTargetRulesBatch - summary: Manage Target Rules of a Promotion - x-sidebar-summary: Manage Target Rules - description: Manage the target rules of a promotion to create, update, or delete them. - x-authenticated: true - parameters: - - name: id - in: path - description: The promotion's ID. - required: true - schema: - type: string - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: Comma-separated relations that should be expanded in the returned data. - - name: fields - in: query - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - required: false - schema: - type: string - title: fields - description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - security: - - api_token: [] - - cookie_auth: [] - - jwt_token: [] - requestBody: - content: - application/json: - schema: - type: object - description: The target rules to create, update, or delete. + description: The rules to create, update, or delete. properties: create: type: array - description: The target rules to create. + description: The rules to create. items: type: object - description: A target rule's details. + description: A rule's details. required: + - values - operator - attribute - - values properties: operator: type: string - description: The operator used to check whether the target rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. + description: The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. enum: - gte - lte @@ -30702,7 +32826,7 @@ paths: description: type: string title: description - description: The target rule's description. + description: The rule's description. attribute: type: string title: attribute @@ -30712,29 +32836,245 @@ paths: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The create's values. - type: array - description: The allowed attribute values. + description: The create's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The create's values. + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The create's values. update: type: array - description: The target rules to update. + description: The rules to update. items: type: object - description: The properties to update in a target rule. + description: The properties to update in a rule. required: - - id - values + - id properties: id: type: string title: id - description: The target rule's ID. + description: The rule's ID. + operator: + oneOf: + - type: string + description: The update's operator. + enum: + - GTE + - type: string + description: The update's operator. + enum: + - LTE + - type: string + description: The update's operator. + enum: + - GT + - type: string + description: The update's operator. + enum: + - LT + - type: string + description: The update's operator. + enum: + - EQ + - type: string + description: The update's operator. + enum: + - NE + - type: string + description: The update's operator. + enum: + - IN + description: The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. + description: + type: string + title: description + description: The rule's description. + attribute: + type: string + title: attribute + description: The attribute to compare against when checking whether a promotion can be applied on a cart. + example: items.product.id + values: + oneOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The update's values. + delete: + type: array + description: The rules to delete. + items: + type: string + title: delete + description: A rule's ID. + x-codeSamples: + - lang: Shell + label: cURL + source: |- + curl -X POST '{backend_url}/admin/promotions/{id}/rules/batch' \ + -H 'Authorization: Bearer {access_token}' + tags: + - Promotions + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + description: The result of the batch operations. + required: + - created + - updated + - deleted + properties: + created: + type: array + description: The created rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' + updated: + type: array + description: The updated rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' + deleted: + type: object + description: The details of the deleted buy rules. + required: + - ids + - object + - deleted + properties: + ids: + type: array + description: The IDs of the deleted rules. + items: + type: string + title: ids + description: A rule's ID. + object: + type: string + title: object + description: The name of the object that was deleted. + default: promotion-rule + deleted: + type: boolean + title: deleted + description: Whether the rules were deleted. + '400': + $ref: '#/components/responses/400_error' + '401': + $ref: '#/components/responses/unauthorized' + '404': + $ref: '#/components/responses/not_found_error' + '409': + $ref: '#/components/responses/invalid_state_error' + '422': + $ref: '#/components/responses/invalid_request_error' + '500': + $ref: '#/components/responses/500_error' + x-workflow: batchPromotionRulesWorkflow + /admin/promotions/{id}/target-rules/batch: + post: + operationId: PostPromotionsIdTargetRulesBatch + summary: Manage Target Rules of a Promotion + x-sidebar-summary: Manage Target Rules + description: Manage the target rules of a promotion to create, update, or delete them. + x-authenticated: true + parameters: + - name: id + in: path + description: The promotion's ID. + required: true + schema: + type: string + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: Comma-separated relations that should be expanded in the returned data. + - name: fields + in: query + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + type: object + description: The target rules to create, update, or delete. + properties: + create: + type: array + description: The target rules to create. + items: + type: object + description: A target rule's details. + required: + - values + - operator + - attribute + properties: operator: type: string description: The operator used to check whether the target rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. @@ -30759,15 +33099,118 @@ paths: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The create's values. - type: array - description: The allowed attribute values. + description: The create's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The create's values. + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The create's values. + update: + type: array + description: The target rules to update. + items: + type: object + description: The properties to update in a target rule. + required: + - values + - id + properties: + id: + type: string + title: id + description: The target rule's ID. + operator: + oneOf: + - type: string + description: The update's operator. + enum: + - GTE + - type: string + description: The update's operator. + enum: + - LTE + - type: string + description: The update's operator. + enum: + - GT + - type: string + description: The update's operator. + enum: + - LT + - type: string + description: The update's operator. + enum: + - EQ + - type: string + description: The update's operator. + enum: + - NE + - type: string + description: The update's operator. + enum: + - IN + description: The operator used to check whether the target rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. + description: + type: string + title: description + description: The target rule's description. + attribute: + type: string + title: attribute + description: The attribute to compare against when checking whether a promotion can be applied on a cart. + example: items.product.id + values: + oneOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The update's values. delete: type: array description: The target rules to delete. @@ -32724,9 +35167,9 @@ paths: properties: reservations: type: array - description: The list of reservations`. + description: The list of reservations. items: - $ref: '#/components/schemas/ReservationResponse' + $ref: '#/components/schemas/AdminReservation' '400': $ref: '#/components/responses/400_error' '401': @@ -33580,7 +36023,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/CreateOrderReturnReason' + $ref: '#/components/schemas/AdminCreateReturnReason' x-codeSamples: - lang: Shell label: cURL @@ -33710,7 +36153,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/UpdateOrderReturnReason' + $ref: '#/components/schemas/AdminUpdateReturnReason' x-codeSamples: - lang: Shell label: cURL @@ -37407,7 +39850,7 @@ paths: content: application/json: schema: - type: object + $ref: '#/components/schemas/AdminCreateShippingOption' x-codeSamples: - lang: Shell label: cURL @@ -37500,12 +39943,17 @@ paths: externalDocs: url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property price_type: - type: string + oneOf: + - type: string + description: The shipping option's price type. + enum: + - CALCULATED + - type: string + description: The shipping option's price type. + enum: + - FLAT description: | The type of the shipping option's price. If `calculated`, its price is retrieved by the associated fulfillment provider during checkout. If `flat`, its price is set in the `prices` property. - enum: - - calculated - - flat provider_id: type: string title: provider_id @@ -37518,9 +39966,9 @@ paths: type: object description: The shipping option's type. required: - - label - - description - code + - description + - label properties: label: type: string @@ -37773,9 +40221,9 @@ paths: type: object description: A shipping option's details. required: + - value - operator - attribute - - value properties: operator: type: string @@ -37798,15 +40246,33 @@ paths: oneOf: - type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The create's value. - type: array - description: Values of the attribute that enable this rule. + description: The create's value. items: type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The value's details. + - allOf: + - type: string + title: value + description: The create's value. + - type: array + description: The create's value. + items: + type: string + title: value + description: The value's details. + - allOf: + - type: array + description: The create's value. + items: + type: string + title: value + description: The value's details. + - type: string + title: value + description: The create's value. update: type: array description: The shipping option rules to update. @@ -37814,10 +40280,10 @@ paths: type: object description: The properties to update in the shipping option rule. required: + - value - id - operator - attribute - - value properties: id: type: string @@ -37844,15 +40310,33 @@ paths: oneOf: - type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The update's value. - type: array - description: Values of the attribute that enable this rule. + description: The update's value. items: type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The value's details. + - allOf: + - type: string + title: value + description: The update's value. + - type: array + description: The update's value. + items: + type: string + title: value + description: The value's details. + - allOf: + - type: array + description: The update's value. + items: + type: string + title: value + description: The value's details. + - type: string + title: value + description: The update's value. delete: type: array description: The shipping option rules to delete. @@ -39579,8 +42063,8 @@ paths: type: object description: The fulfillment set to create. required: - - name - type + - name properties: name: type: string @@ -40090,10 +42574,13 @@ paths: required: false description: Filter by whether the tax rate is a default in its tax region. schema: - type: string - enum: - - 'true' - - 'false' + oneOf: + - type: string + title: is_default + description: The tax rate's is default. + - type: string + title: is_default + description: The tax rate's is default. - name: created_at in: query description: Filter by a tax rate's creation date. @@ -42193,17 +44680,17 @@ paths: schema: oneOf: - type: object - description: The files to upload. + description: SUMMARY required: - files properties: files: type: array - description: The files to upload. + description: The upload's files. items: oneOf: - type: object - description: A file's details. + description: The file's files. required: - name - content @@ -42215,9 +44702,22 @@ paths: content: type: string title: content - description: The file's base64 content. - - $ref: '#/components/schemas/File' - - $ref: '#/components/schemas/FileList' + description: The file's content. + - type: object + description: A File to upload. + externalDocs: + url: https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: files + - type: array + description: list of files to upload. + items: + type: object + description: A File to upload. + externalDocs: + url: https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: FileList description: The files to upload. x-codeSamples: - lang: Shell @@ -43051,7 +45551,7 @@ paths: $ref: '#/components/responses/invalid_request_error' '500': $ref: '#/components/responses/500_error' - x-workflow: deleteUsersWorkflow + x-workflow: removeUserAccountWorkflow /admin/workflows-executions: get: operationId: GetWorkflowsExecutions @@ -43294,6 +45794,8 @@ paths: required: - workflowId - transactionId + - hasFinished + - hasFailed properties: workflowId: type: string @@ -43303,6 +45805,18 @@ paths: type: string description: The ID of the workflow exection's transaction. Use this later to track the workflow execution's progress or succeed / fail its steps. title: transactionId + parentStepIdempotencyKey: + type: string + title: parentStepIdempotencyKey + description: The acknowledgement's parentstepidempotencykey. + hasFinished: + type: boolean + title: hasFinished + description: The acknowledgement's hasfinished. + hasFailed: + type: boolean + title: hasFailed + description: The acknowledgement's hasfailed. '400': $ref: '#/components/responses/400_error' '401': @@ -43975,17 +46489,120 @@ components: properties: api_key: $ref: '#/components/schemas/AdminApiKey' - AdminArchiveOrder: + AdminApplicationMethod: type: object - description: SUMMARY - x-schemaName: AdminArchiveOrder + description: The promotion's application method. + x-schemaName: AdminApplicationMethod required: - - order_id + - id properties: - order_id: + promotion: + type: object + description: The application method's promotion. + x-schemaName: AdminPromotion + required: + - id + properties: + application_method: + type: object + description: The promotion's application method. + x-schemaName: AdminApplicationMethod + rules: + type: array + description: The promotion's rules. + items: + type: object + description: The rule's rules. + x-schemaName: AdminPromotionRule + id: + type: string + title: id + description: The promotion's ID. + code: + type: string + title: code + description: The promotion's code. + type: + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. + is_automatic: + type: boolean + title: is_automatic + description: The promotion's is automatic. + campaign_id: + type: string + title: campaign_id + description: The promotion's campaign id. + campaign: + type: object + description: The promotion's campaign. + x-schemaName: AdminCampaign + target_rules: + type: array + description: The application method's target rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' + buy_rules: + type: array + description: The application method's buy rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' + id: type: string - title: order_id - description: The order's order id. + title: id + description: The application method's ID. + type: + oneOf: + - type: string + title: type + description: The application method's type. + - type: string + title: type + description: The application method's type. + target_type: + oneOf: + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + allocation: + oneOf: + - type: string + title: allocation + description: The application method's allocation. + - type: string + title: allocation + description: The application method's allocation. + value: + type: number + title: value + description: The application method's value. + currency_code: + type: string + title: currency_code + description: The application method's currency code. + max_quantity: + type: number + title: max_quantity + description: The application method's max quantity. + buy_rules_min_quantity: + type: number + title: buy_rules_min_quantity + description: The application method's buy rules min quantity. + apply_to_quantity: + type: number + title: apply_to_quantity + description: The application method's apply to quantity. AdminBatchProductRequest: type: object description: The products to create, update, or delete. @@ -44206,44 +46823,18 @@ components: description: The claim's details. x-schemaName: AdminClaim required: - - order_id - - claim_items - - additional_items - - currency_code + - order + - return - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - type + - order_id + - display_id + - order_version - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - additional_items + - claim_items properties: id: type: string @@ -44264,7 +46855,7 @@ components: items: $ref: '#/components/schemas/BaseClaimItem' return: - $ref: '#/components/schemas/Return' + $ref: '#/components/schemas/AdminReturn' return_id: type: string title: return_id @@ -44277,76 +46868,15 @@ components: type: number title: refund_amount description: The amount to be refunded. - currency_code: - type: string - title: currency_code - description: The claim's currency code. - region_id: - type: string - title: region_id - description: The ID of the region associated with the claim. - customer_id: - type: string - title: customer_id - description: The ID of the customer associated with the claim's order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the claim's order is created in. - email: - type: string - title: email - description: The email associated with the claim's order. - format: email display_id: type: number title: display_id description: The claim's display ID. - shipping_address: - $ref: '#/components/schemas/BaseOrderAddress' - billing_address: - $ref: '#/components/schemas/BaseOrderAddress' shipping_methods: type: array description: The claim's shipping methods. items: - $ref: '#/components/schemas/BaseOrderShippingMethod' - payment_collections: - type: array - description: The claim's payment collections. - items: - $ref: '#/components/schemas/BasePaymentCollection' - payment_status: - type: string - description: The claim's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The claim's fulfillments. - items: - $ref: '#/components/schemas/BaseOrderFulfillment' - fulfillment_status: - type: string - description: The claim's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered + $ref: '#/components/schemas/AdminOrderShippingMethod' transactions: type: array description: The claim's transactions. @@ -44355,8 +46885,6 @@ components: description: Learn more about transactions of orders and associated models. items: $ref: '#/components/schemas/BaseOrderTransaction' - summary: - $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object description: The claim's metadata, used to store custom key-value pairs. @@ -44370,94 +46898,34 @@ components: format: date-time title: updated_at description: The claim's update date. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the associated order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the associated order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The tax total of the original items in the associated order. - item_total: - type: number - title: item_total - description: The total of the claim's items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the claim's items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the claim's items. - original_total: - type: number - title: original_total - description: The associated order's original total. - original_subtotal: - type: number - title: original_subtotal - description: The associated order's original subtotal. - original_tax_total: - type: number - title: original_tax_total - description: The associated order's original tax total. - total: - type: number - title: total - description: The associated order's total. - subtotal: - type: number - title: subtotal - description: The claim's subtotal. - tax_total: - type: number - title: tax_total - description: The claim's tax total. - discount_total: - type: number - title: discount_total - description: The claim's discount total. - discount_tax_total: - type: number - title: discount_tax_total - description: The claim's discount tax total. - gift_card_total: - type: number - title: gift_card_total - description: The claim's gift card total. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The claim's gift card tax total. - shipping_total: - type: number - title: shipping_total - description: The claim's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The claim's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The claim's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The associated order's original shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The associated order's original shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The associated order's original shipping tax total. + order: + type: string + title: order + description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + type: + type: string + description: The claim's type. + enum: + - replace + - refund + order_version: + type: string + title: order_version + description: The claim's order version. + created_by: + type: string + title: created_by + description: The claim's created by. + canceled_at: + type: string + title: canceled_at + description: The claim's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The claim's deleted at. AdminClaimDeleteResponse: type: object description: The details of the deleted claim. @@ -44516,7 +46984,9 @@ components: - claim properties: order: - $ref: '#/components/schemas/Order' + type: string + title: order + description: The order change's order. claim: $ref: '#/components/schemas/AdminClaim' AdminClaimPreviewResponse: @@ -44528,7 +46998,7 @@ components: - claim properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' claim: $ref: '#/components/schemas/AdminClaim' AdminClaimRequestResponse: @@ -44543,7 +47013,7 @@ components: return: $ref: '#/components/schemas/AdminReturn' order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' claim: $ref: '#/components/schemas/AdminClaim' AdminClaimResponse: @@ -44564,7 +47034,7 @@ components: - return properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' return: $ref: '#/components/schemas/AdminReturn' AdminCollection: @@ -44691,68 +47161,6 @@ components: enum: - publishable - secret - AdminCreateApplicationMethod: - type: object - description: The application method's details. - x-schemaName: AdminCreateApplicationMethod - required: - - value - - type - - target_type - properties: - description: - type: string - title: description - description: The application method's description. - value: - type: number - title: value - description: The discounted amount applied by the associated promotion based on the `type`. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: The max quantity allowed in the cart for the associated promotion to be applied. - type: - type: string - description: The type of the application method indicating how the associated promotion is applied. - enum: - - fixed - - percentage - target_type: - type: string - description: The target type of the application method indicating whether the associated promotion is applied to the cart's items, shipping methods, or the whole order. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: The allocation value that indicates whether the associated promotion is applied on each item in a cart or split between the items in the cart. - enum: - - each - - across - target_rules: - type: array - description: The application method's target rules. - items: - $ref: '#/components/schemas/AdminCreatePromotionRule' - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: '#/components/schemas/AdminCreatePromotionRule' - apply_to_quantity: - type: number - title: apply_to_quantity - description: The quantity that results from matching the `buyget` promotion's condition. For example, if the promotion is a "Buy 2 shirts get 1 free", the value f this attribute is `1`. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: The minimum quantity required for a `buyget` promotion to be applied. For example, if the promotion is a "Buy 2 shirts get 1 free", the value of this attribute is `2`. AdminCreateCollection: type: object description: the product collection's details. @@ -44790,15 +47198,14 @@ components: description: The filfillment's details. x-schemaName: AdminCreateFulfillment required: + - data + - order_id + - metadata + - items - location_id - provider_id - delivery_address - - items - labels - - order - - order_id - - data - - metadata properties: location_id: type: string @@ -44863,8 +47270,8 @@ components: description: An item to fulfill. required: - title - - sku - quantity + - sku - barcode properties: title: @@ -45038,17 +47445,27 @@ components: description: The date and time the price list ends at. format: date-time status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. @@ -45062,8 +47479,8 @@ components: description: A price's details. required: - currency_code - - amount - variant_id + - amount properties: currency_code: type: string @@ -45158,13 +47575,20 @@ components: title: handle description: The product's handle. status: - type: string + oneOf: + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. description: The product's status. - enum: - - draft - - proposed - - published - - rejected type_id: type: string title: type_id @@ -45328,6 +47752,20 @@ components: metadata: type: object description: The product tag's metadata, used to store custom key-value pairs. + AdminCreateProductType: + type: object + description: The product's details. + x-schemaName: AdminCreateProductType + required: + - value + properties: + metadata: + type: object + description: The product's metadata, used to store custom key-value pairs. + value: + type: string + title: value + description: The product type's value. AdminCreateProductVariant: type: object description: The product variant's details. @@ -45413,6 +47851,26 @@ components: description: The variant's options, where the key is an option's name, and the value is the option's value. example: Color: Black + inventory_items: + type: array + description: The variant's inventory items. + items: + $ref: '#/components/schemas/AdminCreateProductVariantInventoryKit' + AdminCreateProductVariantInventoryKit: + type: object + description: The inventory item's inventory items. + x-schemaName: AdminCreateProductVariantInventoryKit + required: + - inventory_item_id + properties: + inventory_item_id: + type: string + title: inventory_item_id + description: The inventory item's inventory item id. + required_quantity: + type: number + title: required_quantity + description: The inventory item's required quantity. AdminCreateProductVariantPrice: type: object description: The details of a variant's price. @@ -45442,6 +47900,13 @@ components: description: The price's rules. example: region_id: reg_123 + properties: + region_id: + type: string + title: region_id + description: The rule's region id. + required: + - region_id AdminCreatePromotionRule: type: object description: The promotion rule's details. @@ -45575,6 +48040,33 @@ components: metadata: type: object description: The reservation's metadata, used to store custom key-value pairs. + AdminCreateReturnReason: + type: object + description: SUMMARY + x-schemaName: AdminCreateReturnReason + required: + - value + - label + properties: + value: + type: string + title: value + description: The return reason's value. + label: + type: string + title: label + description: The return reason's label. + description: + type: string + title: description + description: The return reason's description. + parent_return_reason_id: + type: string + title: parent_return_reason_id + description: The return reason's parent return reason id. + metadata: + type: object + description: The return reason's metadata. AdminCreateSalesChannel: type: object description: The sales channel's details. @@ -45629,127 +48121,25 @@ components: description: The label's URL. AdminCreateShippingOption: type: object - description: The shipping option's details. + description: The shipping option's type. x-schemaName: AdminCreateShippingOption required: - - name - - service_zone_id - - shipping_profile_id - - price_type - - provider_id - - type - - prices + - label + - description + - code properties: - name: - type: string - title: name - description: The shipping option's name. - service_zone_id: - type: string - title: service_zone_id - description: The ID of the service zone this shipping option belongs to. - shipping_profile_id: - type: string - title: shipping_profile_id - description: The ID of the shipping profile this shipping option belongs to. - data: - type: object - description: Any data necessary for fulfillment providers to handle shipping methods and fulfillments of this shipping option. - externalDocs: - url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property - description: Learn more about the data property. - price_type: - type: string - description: | - The shipping option price's type. If `flat`, it means the option has a fixed price set in the `prices` property. `calculated` means that the shipping option's price is calculated during checkout. - enum: - - flat - - calculated - provider_id: + label: type: string - title: provider_id - description: The ID of the fulfillment provider used to handle this shipping option and its associated methods and fulfillments. - type: - type: object - prices: - type: array - description: The shipping option's prices. If `price_type` is `calculated`, pass an empty array for this property. - items: - oneOf: - - type: object - description: The price for a currency code. - x-schemaName: AdminCreateShippingOptionPriceWithCurrency - required: - - currency_code - - amount - properties: - currency_code: - type: string - title: currency_code - description: The price's currency code. - amount: - type: number - title: amount - description: The price's amount. - - type: object - description: The price in a region. - x-schemaName: AdminCreateShippingOptionPriceWithRegion - required: - - region_id - - amount - properties: - region_id: - type: string - title: region_id - description: The ID of the region this price is used in. - amount: - type: number - title: amount - description: The price's amount. - rules: - type: array - description: The shipping option's rules. - items: - $ref: '#/components/schemas/AdminCreateShippingOptionRule' - AdminCreateShippingOptionRule: - type: object - description: The details of the shipping option rule. - x-schemaName: AdminCreateShippingOptionRule - required: - - operator - - attribute - - value - properties: - operator: + title: label + description: The type's label. + description: type: string - description: The operator used to check whether a rule applies. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte - - nin - attribute: + title: description + description: The type's description. + code: type: string - title: attribute - description: The name of a property or table that the rule applies to. - example: customer_group - value: - oneOf: - - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 - - type: array - description: Values of the attribute that enable this rule. - items: - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + title: code + description: The type's code. AdminCreateShippingProfile: type: object description: The shipping profile's details. @@ -45907,8 +48297,8 @@ components: description: The details of the variant-inventory item association. x-schemaName: AdminCreateVariantInventoryItem required: - - required_quantity - inventory_item_id + - required_quantity properties: required_quantity: type: number @@ -45939,11 +48329,16 @@ components: compensate_input: description: Sets the compensation function's input. It accepts any response. action: - type: string + oneOf: + - type: string + description: The workflows execution's action. + enum: + - INVOKE + - type: string + description: The workflows execution's action. + enum: + - COMPENSATE description: Whether to invoke or compensate the step. - enum: - - invoke - - compensate AdminCreateWorkflowsRun: type: object description: The details of the workflow to execute. @@ -45966,7 +48361,6 @@ components: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at @@ -46886,44 +49280,14 @@ components: description: The exchange's details. x-schemaName: AdminExchange required: - - order_id - - return_items - - additional_items - - currency_code - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - order_id - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - deleted_at + - additional_items + - return_items properties: order_id: type: string @@ -46948,88 +49312,24 @@ components: title: difference_due description: The amount to be exchanged or refunded. If the amount is negative, it must be refunded. If positive, additional payment is required from the customer. return: - description: the return associated with the exchange. $ref: '#/components/schemas/AdminReturn' return_id: type: string title: return_id description: The ID of the associated exchange. - currency_code: - type: string - title: currency_code - description: The exchange's currency code. id: type: string title: id description: The exchange's ID. - region_id: - type: string - title: region_id - description: The ID of the associated order's region. - customer_id: - type: string - title: customer_id - description: The ID of the customer that placed the order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the associated order belongs to. - email: - type: string - title: email - description: The email used when placing the order. - format: email display_id: - type: number + type: string title: display_id description: The exchange's display ID. - shipping_address: - description: The shipping address to send new items to. - $ref: '#/components/schemas/BaseOrderAddress' - billing_address: - description: The customer's billing address. - $ref: '#/components/schemas/BaseOrderAddress' shipping_methods: type: array description: The shipping methods used to send the new (outbound) items. items: $ref: '#/components/schemas/BaseOrderShippingMethod' - payment_collections: - type: array - description: The exchange's payment collections. - items: - $ref: '#/components/schemas/BasePaymentCollection' - payment_status: - type: string - description: The exchange's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The exchange's fulfillments of new (outbound) items. - items: - $ref: '#/components/schemas/BaseOrderFulfillment' - fulfillment_status: - type: string - description: The exchange's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered transactions: type: array description: The exchange's transactions. @@ -47037,9 +49337,6 @@ components: url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions items: $ref: '#/components/schemas/BaseOrderTransaction' - summary: - description: The totals summary of the exchange. - $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object description: The exchange's metadata, can hold custom key-value pairs. @@ -47053,94 +49350,32 @@ components: format: date-time title: updated_at description: The date that the exchange was updated. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The total tax of the original items in the order. - item_total: - type: number - title: item_total - description: The total of the exchange's new items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the exchange's new items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the exchange's new items. - original_total: - type: number - title: original_total - description: The total of the order. - original_subtotal: - type: number - title: original_subtotal - description: The subtotal of the order. - original_tax_total: - type: number - title: original_tax_total - description: The tax total of the order. - total: - type: number - title: total - description: The total of the exchange. - subtotal: - type: number - title: subtotal - description: The subtotal of the exchange. - tax_total: - type: number - title: tax_total - description: The tax total of the exchange. - discount_total: - type: number - title: discount_total - description: The discount total of the exchange. - discount_tax_total: - type: number - title: discount_tax_total - description: The total taxes on discount of the exchange. - gift_card_total: - type: number - title: gift_card_total - description: The gift cards total of the exchange. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The total taxes on the gift card of the exchange. - shipping_total: - type: number - title: shipping_total - description: The exchange's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The exchange's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The exchange's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The order's shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The order's shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The order's shipping tax total. + order_version: + type: string + title: order_version + description: The exchange's order version. + created_by: + type: string + title: created_by + description: The exchange's created by. + canceled_at: + type: string + title: canceled_at + description: The exchange's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The exchange's deleted at. + order: + type: string + title: order + description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + allow_backorder: + type: boolean + title: allow_backorder + description: The exchange's allow backorder. AdminExchangeDeleteResponse: type: object description: The details of deleting an exchange. @@ -47172,8 +49407,9 @@ components: - exchange properties: order: - description: The details of the associated order. - $ref: '#/components/schemas/Order' + type: string + title: order + description: The order change's order. exchange: $ref: '#/components/schemas/AdminExchange' AdminExchangePreviewResponse: @@ -47185,7 +49421,7 @@ components: - exchange properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' exchange: $ref: '#/components/schemas/AdminExchange' AdminExchangeRequestResponse: @@ -47198,11 +49434,9 @@ components: - exchange properties: return: - description: The associated return's details. $ref: '#/components/schemas/AdminReturn' order_preview: - description: A preview of the order once the exchange is applied. - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' exchange: $ref: '#/components/schemas/AdminExchange' AdminExchangeResponse: @@ -47223,9 +49457,13 @@ components: - return properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' return: $ref: '#/components/schemas/AdminReturn' + AdminExportProductRequest: + type: object + description: SUMMARY + x-schemaName: AdminExportProductRequest AdminExportProductResponse: type: object description: The details of the product export. @@ -47314,10 +49552,8 @@ components: title: shipping_option_id description: The ID of the shipping option this fulfillment is created for. provider: - description: The details of the fulfillment provider using to handle this fulfillment. $ref: '#/components/schemas/AdminFulfillmentProvider' delivery_address: - description: The address to deliver the item to. $ref: '#/components/schemas/AdminFulfillmentAddress' items: type: array @@ -47571,8 +49807,20 @@ components: description: The date the label was deleted. AdminFulfillmentProvider: type: object - description: The shipping option's provider. + description: The fulfillment provider's details. x-schemaName: AdminFulfillmentProvider + required: + - id + - is_enabled + properties: + id: + type: string + title: id + description: The provider's ID. + is_enabled: + type: boolean + title: is_enabled + description: The provider's is enabled. AdminFulfillmentProviderListResponse: type: object description: The paginated list of fulfillment providers. @@ -47611,7 +49859,7 @@ components: $ref: '#/components/schemas/AdminFulfillment' AdminFulfillmentSet: type: object - description: The fulfillment set's parent. + description: The service zone's fulfillment set. x-schemaName: AdminFulfillmentSet required: - id @@ -47626,37 +49874,39 @@ components: id: type: string title: id - description: The parent's ID. + description: The fulfillment set's ID. name: type: string title: name - description: The parent's name. + description: The fulfillment set's name. type: type: string title: type - description: The parent's type. + description: The fulfillment set's type. location: - $ref: '#/components/schemas/AdminStockLocation' + type: object + description: The stock location's details. + x-schemaName: AdminStockLocation service_zones: type: array - description: The parent's service zones. + description: The fulfillment set's service zones. items: $ref: '#/components/schemas/AdminServiceZone' created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The fulfillment set's created at. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The fulfillment set's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The fulfillment set's deleted at. AdminFulfillmentSetDeleteResponse: type: object description: The deletion details. @@ -47690,7 +49940,7 @@ components: $ref: '#/components/schemas/AdminFulfillmentSet' AdminGeoZone: type: object - description: The geo zone's details. + description: The geo zone's geo zones. x-schemaName: AdminGeoZone required: - id @@ -47734,17 +49984,17 @@ components: type: string format: date-time title: created_at - description: The date the geo zone was created. + description: The geo zone's created at. updated_at: type: string format: date-time title: updated_at - description: The date the geo zone was update. + description: The geo zone's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The date the geo zone was deleted. + description: The geo zone's deleted at. AdminImportProductRequest: type: object description: The import's details. @@ -47753,7 +50003,12 @@ components: - file properties: file: - $ref: '#/components/schemas/File' + type: object + description: A File to upload. + externalDocs: + url: https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: file AdminImportProductResponse: type: object description: The import process's details. @@ -47783,7 +50038,7 @@ components: description: The number of products that will be updated by this import. AdminInventoryItem: type: object - description: The inventory item's details. + description: The reservation's inventory item. x-schemaName: AdminInventoryItem required: - id @@ -47796,7 +50051,7 @@ components: sku: type: string title: sku - description: The inventory item's SKU. + description: The inventory item's sku. origin_country: type: string title: origin_country @@ -47804,15 +50059,15 @@ components: hs_code: type: string title: hs_code - description: The inventory item's HS code. + description: The inventory item's hs code. requires_shipping: type: boolean title: requires_shipping - description: Whether the inventory item requires shipping. + description: The inventory item's requires shipping. mid_code: type: string title: mid_code - description: The inventory item's MID code. + description: The inventory item's mid code. material: type: string title: material @@ -47844,13 +50099,13 @@ components: thumbnail: type: string title: thumbnail - description: The URL of the inventory item's thumbnail. + description: The inventory item's thumbnail. metadata: type: object - description: The inventory item's metadata, can hold custom key-value pairs. + description: The inventory item's metadata. location_levels: type: array - description: The inventory item's associated inventory levels. + description: The inventory item's location levels. items: $ref: '#/components/schemas/AdminInventoryLevel' AdminInventoryItemResponse: @@ -47864,7 +50119,7 @@ components: $ref: '#/components/schemas/AdminInventoryItem' AdminInventoryLevel: type: object - description: The inventory level's details. + description: The location level's location levels. x-schemaName: AdminInventoryLevel required: - id @@ -47874,62 +50129,59 @@ components: - inventory_item_id - location_id - stocked_quantity - - raw_stocked_quantity - reserved_quantity - - raw_reserved_quantity - incoming_quantity - - raw_incoming_quantity - metadata - available_quantity properties: id: type: string title: id - description: The inventory level's ID. + description: The location level's ID. + created_at: + type: string + format: date-time + title: created_at + description: The location level's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The location level's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The location level's deleted at. inventory_item_id: type: string title: inventory_item_id - description: The ID of the inventory item this level belongs to. + description: The location level's inventory item id. location_id: type: string title: location_id - description: The ID of the stock location this level belongs to. + description: The location level's location id. stocked_quantity: type: number title: stocked_quantity - description: The quantity of the associated inventory item stocked in the associated stock location. + description: The location level's stocked quantity. reserved_quantity: type: number title: reserved_quantity - description: The reserved quantity of the associated inventory item stocked in the associated stock location. + description: The location level's reserved quantity. incoming_quantity: type: number title: incoming_quantity - description: The incoming quantity of the associated inventory item stocked in the associated stock location. + description: The location level's incoming quantity. metadata: type: object - description: The location level's metadata, can hold custom key-value pairs. + description: The location level's metadata. inventory_item: type: object available_quantity: type: number title: available_quantity - description: The quantity available for order of the associated inventory item in the associated stock location. - created_at: - type: string - format: date-time - title: created_at - description: The date the inventory level was created. - updated_at: - type: string - format: date-time - title: updated_at - description: The date the inventory level was updated. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The date the inventory level was deleted. + description: The location level's available quantity. AdminInvite: type: object description: The invite's details. @@ -47996,6 +50248,10 @@ components: title: remove description: The ID of a product. x-schemaName: AdminLinkPriceListProducts + AdminMarkOrderFulfillmentDelivered: + type: object + description: SUMMARY + x-schemaName: AdminMarkOrderFulfillmentDelivered AdminNotification: type: object description: The notification's details. @@ -48105,21 +50361,20 @@ components: x-schemaName: AdminOrder required: - payment_collections + - items + - shipping_methods + - currency_code - id + - created_at + - updated_at + - email - version - region_id - customer_id - sales_channel_id - - email - - currency_code - - items - - shipping_methods - payment_status - fulfillment_status - summary - - metadata - - created_at - - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -48152,7 +50407,7 @@ components: type: array description: The order's fulfillments. items: - $ref: '#/components/schemas/BaseOrderFulfillment' + $ref: '#/components/schemas/AdminOrderFulfillment' sales_channel: $ref: '#/components/schemas/AdminSalesChannel' customer: @@ -48198,12 +50453,12 @@ components: type: array description: The order's items. items: - $ref: '#/components/schemas/BaseOrderLineItem' + $ref: '#/components/schemas/AdminOrderLineItem' shipping_methods: type: array description: The order's shipping methods. items: - $ref: '#/components/schemas/BaseOrderShippingMethod' + $ref: '#/components/schemas/AdminOrderShippingMethod' payment_status: type: string description: The order's payment status. @@ -48340,78 +50595,330 @@ components: description: The tax total of the order's shipping excluding promotions. AdminOrderAddress: type: object - description: An order address. - x-schemaName: AdminOrderAddress + description: An order address. + x-schemaName: AdminOrderAddress + required: + - id + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The address's ID. + customer_id: + type: string + title: customer_id + description: The ID of the customer this address belongs to. + first_name: + type: string + title: first_name + description: The address's first name. + last_name: + type: string + title: last_name + description: The address's last name. + phone: + type: string + title: phone + description: The address's phone. + company: + type: string + title: company + description: The address's company. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + city: + type: string + title: city + description: The address's city. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + country: + $ref: '#/components/schemas/AdminRegionCountry' + province: + type: string + title: province + description: The address's province. + postal_code: + type: string + title: postal_code + description: The address's postal code. + metadata: + type: object + description: The address's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the address was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the address was updated. + AdminOrderChange: + type: object + description: The order change's details. + x-schemaName: AdminOrderChange + required: + - order + - claim + - return_order + - exchange + - actions + - status + - order_id + - metadata + - id + - created_at + - updated_at + - version + - canceled_at + - return_id + - exchange_id + - claim_id + - requested_by + - requested_at + - confirmed_by + - confirmed_at + - declined_by + - declined_reason + - declined_at + - canceled_by + properties: + id: + type: string + title: id + description: The order change's ID. + version: + type: number + title: version + description: The order change's version. This will be the order's version when the change is applied. + change_type: + oneOf: + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + description: The order change's type. + order_id: + type: string + title: order_id + description: The ID of the order this change applies on. + return_id: + type: string + title: return_id + description: The ID of the associated return. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + order: + type: string + title: order + description: The order change's order. + return_order: + $ref: '#/components/schemas/AdminReturn' + exchange: + $ref: '#/components/schemas/AdminExchange' + claim: + $ref: '#/components/schemas/AdminClaim' + actions: + type: array + description: The order change's actions. + items: + $ref: '#/components/schemas/AdminOrderChangeAction' + status: + type: string + description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined + requested_by: + type: string + title: requested_by + description: The ID of the user that requested the change. + requested_at: + type: string + title: requested_at + description: The date the order change was requested. + format: date-time + confirmed_by: + type: string + title: confirmed_by + description: The ID of the user that confirmed the order change. + confirmed_at: + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time + declined_by: + type: string + title: declined_by + description: The ID of the user that declined the order change. + declined_reason: + type: string + title: declined_reason + description: The reason the order change was declined. + metadata: + type: object + description: The order change's metadata, can hold custom key-value pairs. + declined_at: + type: string + title: declined_at + description: The date the order change was declined. + format: date-time + canceled_by: + type: string + title: canceled_by + description: The ID of the user that canceled the order change. + canceled_at: + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time + created_at: + type: string + format: date-time + title: created_at + description: The date the order change was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change was updated. + AdminOrderChangeAction: + type: object + description: The order change action's details. + x-schemaName: AdminOrderChangeAction required: + - order_change + - order + - order_id + - internal_note - id - - metadata - created_at - updated_at + - return_id + - exchange_id + - claim_id + - order_change_id + - reference + - reference_id + - action + - details properties: id: type: string title: id - description: The address's ID. - customer_id: + description: The action's ID. + order_change_id: type: string - title: customer_id - description: The ID of the customer this address belongs to. - first_name: - type: string - title: first_name - description: The address's first name. - last_name: - type: string - title: last_name - description: The address's last name. - phone: + title: order_change_id + description: The ID of the order change that the action belongs to. + order_change: + type: object + order_id: type: string - title: phone - description: The address's phone. - company: + title: order_id + description: The ID of the order the associated change is for. + return_id: type: string - title: company - description: The address's company. - address_1: + title: return_id + description: The ID of the associated return. + claim_id: type: string - title: address_1 - description: The address's first line. - address_2: + title: claim_id + description: The ID of the associated claim. + exchange_id: type: string - title: address_2 - description: The address's second line. - city: + title: exchange_id + description: The ID of the associated exchange. + order: type: string - title: city - description: The address's city. - country_code: + title: order + description: The order change's order. + reference: type: string - title: country_code - description: The address's country code. - example: us - country: - $ref: '#/components/schemas/AdminRegionCountry' - province: + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: type: string - title: province - description: The address's province. - postal_code: + title: reference_id + description: The ID of the record in the referenced table. + action: type: string - title: postal_code - description: The address's postal code. - metadata: + description: The applied action. + enum: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: type: object - description: The address's metadata, can hold custom key-value pairs. + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. created_at: type: string format: date-time title: created_at - description: The date the address was created. + description: The date the action was created. updated_at: type: string format: date-time title: updated_at - description: The date the address was updated. + description: The date the action was updated. AdminOrderChangesResponse: type: object description: The details of an order's changes. @@ -48423,7 +50930,7 @@ components: type: array description: An order's changes. items: - $ref: '#/components/schemas/BaseOrderChange' + $ref: '#/components/schemas/AdminOrderChange' AdminOrderEditPreviewResponse: type: object description: The preview of an order edit. @@ -48432,7 +50939,7 @@ components: - order_preview properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' AdminOrderEditResponse: type: object description: An order edit's details. @@ -48441,7 +50948,298 @@ components: - order_change properties: order_change: - $ref: '#/components/schemas/OrderChange' + $ref: '#/components/schemas/AdminOrderChange' + AdminOrderFulfillment: + type: object + description: The fulfillment's fulfillments. + x-schemaName: AdminOrderFulfillment + required: + - id + - location_id + - packed_at + - shipped_at + - delivered_at + - canceled_at + - requires_shipping + - data + - provider_id + - shipping_option_id + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The fulfillment's ID. + location_id: + type: string + title: location_id + description: The ID of the location the items are fulfilled from. + packed_at: + type: string + title: packed_at + description: The date the items were packed. + format: date-time + shipped_at: + type: string + title: shipped_at + description: The date the items were shipped. + format: date-time + delivered_at: + type: string + title: delivered_at + description: The date the items were delivered. + format: date-time + canceled_at: + type: string + title: canceled_at + description: The date the items were canceled. + format: date-time + data: + type: object + description: Data useful for the fulfillment provider handling it. This is taken from the associated shipping option. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + provider_id: + type: string + title: provider_id + description: The ID of the fulfillment provider used to handle the fulfillment. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the associated shipping option. + metadata: + type: object + description: The fulfillment's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the fulfillment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the fulfillment was updated. + requires_shipping: + type: boolean + title: requires_shipping + description: The fulfillment's requires shipping. + AdminOrderLineItem: + type: object + description: The item's items. + x-schemaName: AdminOrderLineItem + required: + - title + - metadata + - id + - subtitle + - thumbnail + - created_at + - updated_at + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - variant_id + - product_id + - product_title + - product_description + - product_subtitle + - product_type + - product_collection + - product_handle + - variant_sku + - variant_barcode + - variant_title + - variant_option_values + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - detail + - refundable_total + - refundable_total_per_unit + properties: + id: + type: string + title: id + description: The item's ID. + title: + type: string + title: title + description: The item's title. + subtitle: + type: string + title: subtitle + description: The item's subtitle. + thumbnail: + type: string + title: thumbnail + description: The URL of the item's thumbnail. + variant: + $ref: '#/components/schemas/AdminProductVariant' + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product: + $ref: '#/components/schemas/AdminProduct' + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The item's product type. + product_collection: + type: string + title: product_collection + description: The ID of the collection the item's product belongs to. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: + type: string + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The values of the item variant's options. + example: + Color: Blue + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item is tax inclusive. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + unit_price: + type: number + title: unit_price + description: The item's unit price. + quantity: + type: number + title: quantity + description: The item's quantity. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: '#/components/schemas/BaseOrderLineItemTaxLine' + adjustments: + type: array + description: The item's adjustments. + items: + $ref: '#/components/schemas/BaseOrderLineItemAdjustment' + detail: + $ref: '#/components/schemas/BaseOrderItemDetail' + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + original_total: + type: number + title: original_total + description: The item's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the item, excluding promotions. + item_total: + type: number + title: item_total + description: The total taxes of the item, including promotions. + item_subtotal: + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of the item, including promotions. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the item including promotions. + discount_total: + type: number + title: discount_total + description: The total discount amount of the item. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total refundable amount of the item's total. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total refundable amount of the item's total for a single quantity. AdminOrderPreview: type: object description: A preview of an order if a change, such as exchange, return, edit, or claim is applied on it. @@ -48450,19 +51248,18 @@ components: - return_requested_total - order_change - currency_code - - version - id + - created_at + - updated_at + - email + - version - region_id - customer_id - sales_channel_id - - email - payment_collections - payment_status - fulfillment_status - summary - - metadata - - created_at - - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -48491,7 +51288,7 @@ components: title: return_requested_total description: The total of the requested return. order_change: - $ref: '#/components/schemas/BaseOrderChange' + $ref: '#/components/schemas/AdminOrderChange' items: type: array description: The order's items. @@ -48563,7 +51360,7 @@ components: title: variant_id description: The ID of the associated variant. product: - $ref: '#/components/schemas/BaseProduct' + $ref: '#/components/schemas/AdminProduct' product_id: type: string title: product_id @@ -48936,7 +51733,7 @@ components: type: array description: The order's fulfillments. items: - $ref: '#/components/schemas/BaseOrderFulfillment' + $ref: '#/components/schemas/AdminOrderFulfillment' fulfillment_status: type: string description: The order's fulfillment status. @@ -49069,7 +51866,9 @@ components: - order properties: order: - $ref: '#/components/schemas/AdminOrderPreview' + type: string + title: order + description: A preview of an order if a change, such as exchange, return, edit, or claim is applied on it. AdminOrderResponse: type: object description: An order's details. @@ -49078,7 +51877,9 @@ components: - order properties: order: - $ref: '#/components/schemas/AdminOrder' + type: string + title: order + description: The order's details. AdminOrderReturnResponse: type: object description: The order return details. @@ -49088,9 +51889,125 @@ components: - return properties: order: - $ref: '#/components/schemas/Order' + type: string + title: order + description: The order change's order. return: $ref: '#/components/schemas/AdminReturn' + AdminOrderShippingMethod: + type: object + description: The shipping method's details. + x-schemaName: AdminOrderShippingMethod + required: + - id + - order_id + - name + - amount + - is_tax_inclusive + - shipping_option_id + - data + - metadata + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes applied taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: The shipping method's data, useful for fulfillment provider handling its fulfillment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: '#/components/schemas/BaseOrderShippingMethodTaxLine' + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: '#/components/schemas/BaseOrderShippingMethodAdjustment' + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The shipping method's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The total discounts applied on the shipping method. + discount_tax_total: + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + detail: + $ref: '#/components/schemas/BaseOrderShippingDetail' AdminPayment: type: object description: The payment's details. @@ -49179,22 +52096,22 @@ components: type: array description: The details of payment refunds. items: - $ref: '#/components/schemas/BaseRefund' + $ref: '#/components/schemas/AdminRefund' payment_collection: - $ref: '#/components/schemas/BasePaymentCollection' + type: object payment_session: - $ref: '#/components/schemas/BasePaymentSession' + $ref: '#/components/schemas/AdminPaymentSession' AdminPaymentCollection: type: object description: The payment collection's details. x-schemaName: AdminPaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -49255,17 +52172,17 @@ components: type: array description: The payment provider used to process the collection's payments and sessions. items: - $ref: '#/components/schemas/BasePaymentProvider' + $ref: '#/components/schemas/AdminPaymentProvider' payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: '#/components/schemas/BasePaymentSession' + $ref: '#/components/schemas/AdminPaymentSession' payments: type: array description: The payment collection's payments. items: - $ref: '#/components/schemas/BasePayment' + $ref: '#/components/schemas/AdminPayment' AdminPaymentCollectionResponse: type: object description: The payment collection's details. @@ -49277,7 +52194,7 @@ components: $ref: '#/components/schemas/AdminPaymentCollection' AdminPaymentProvider: type: object - description: The payment provider's details. + description: The payment provider's payment providers. x-schemaName: AdminPaymentProvider required: - is_enabled @@ -49300,6 +52217,65 @@ components: properties: payment: $ref: '#/components/schemas/AdminPayment' + AdminPaymentSession: + type: object + description: The payment session's details. + x-schemaName: AdminPaymentSession + properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: The payment session's data, useful for the payment provider processing the payment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: '#/components/schemas/BasePayment' + required: + - id + - amount + - currency_code + - provider_id + - data + - status AdminPostCancelClaimReqSchema: type: object description: The details of canceling a claim. @@ -49351,13 +52327,24 @@ components: title: quantity description: The quantity of the order's item to add to the claim. reason: - type: string + oneOf: + - type: string + description: The item's reason. + enum: + - MISSING_ITEM + - type: string + description: The item's reason. + enum: + - WRONG_ITEM + - type: string + description: The item's reason. + enum: + - PRODUCTION_FAILURE + - type: string + description: The item's reason. + enum: + - OTHER description: The reason the item is claimed. - enum: - - missing_item - - wrong_item - - production_failure - - other description: type: string title: description @@ -50443,15 +53430,15 @@ components: description: The product's details. x-schemaName: AdminProduct required: + - variants - type + - options + - images - length - title - status - - options - description - id - - created_at - - updated_at - handle - subtitle - is_giftcard @@ -50465,9 +53452,10 @@ components: - material - collection_id - type_id - - images - discountable - external_id + - created_at + - updated_at - deleted_at properties: collection: @@ -50514,7 +53502,7 @@ components: type: array description: The product's options. items: - $ref: '#/components/schemas/BaseProductOption' + $ref: '#/components/schemas/AdminProductOption' description: type: string title: description @@ -50592,7 +53580,7 @@ components: type: array description: The product's images. items: - $ref: '#/components/schemas/BaseProductImage' + $ref: '#/components/schemas/AdminProductImage' discountable: type: boolean title: discountable @@ -50767,54 +53755,88 @@ components: type: boolean title: deleted description: Whether the product was deleted. - AdminProductOption: + AdminProductImage: type: object - description: The product's product option. - x-schemaName: AdminProductOption + description: The image's details. + x-schemaName: AdminProductImage + properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's URL. + created_at: + type: string + format: date-time + title: created_at + description: The date the image was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. required: - id - - title + - url + AdminProductOption: + type: object + description: The product option's details. + x-schemaName: AdminProductOption properties: id: type: string title: id - description: The product option's ID. + description: The option's ID. title: type: string title: title - description: The product option's title. + description: The option's title. product: - $ref: '#/components/schemas/BaseProduct' + type: object product_id: type: string title: product_id - description: The product option's product id. + description: The option's product id. values: type: array - description: The product option's values. + description: The option's values. items: - $ref: '#/components/schemas/BaseProductOptionValue' + type: object metadata: type: object - description: The product option's metadata. + description: The option's metadata. created_at: type: string format: date-time title: created_at - description: The product option's created at. + description: The option's created at. updated_at: type: string format: date-time title: updated_at - description: The product option's updated at. + description: The option's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The product option's deleted at. + description: The option's deleted at. + required: + - id + - title AdminProductOptionDeleteResponse: type: object - description: SUMMARY + description: The details of the product option deletion. x-schemaName: AdminProductOptionDeleteResponse required: - id @@ -50824,29 +53846,70 @@ components: id: type: string title: id - description: The product's ID. + description: The product option's ID. object: type: string title: object description: The name of the deleted object. + default: product_option deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the product option was deleted. parent: $ref: '#/components/schemas/AdminProduct' AdminProductOptionResponse: type: object - description: SUMMARY + description: The product option's details. x-schemaName: AdminProductOptionResponse required: - product_option properties: product_option: $ref: '#/components/schemas/AdminProductOption' + AdminProductOptionValue: + type: object + description: The product option value's details. + x-schemaName: AdminProductOptionValue + required: + - id + - value + properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + $ref: '#/components/schemas/AdminProductOption' + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. AdminProductResponse: type: object - description: SUMMARY + description: The product's details. x-schemaName: AdminProductResponse required: - product @@ -50855,7 +53918,7 @@ components: $ref: '#/components/schemas/AdminProduct' AdminProductTag: type: object - description: The tag's tags. + description: The product tag's details. x-schemaName: AdminProductTag required: - id @@ -50875,23 +53938,23 @@ components: type: string format: date-time title: created_at - description: The tag's created at. + description: The date the tag was created. updated_at: type: string format: date-time title: updated_at - description: The tag's updated at. + description: The date the tag was updated. deleted_at: type: string format: date-time title: deleted_at - description: The tag's deleted at. + description: The date the tag was deleted. metadata: type: object - description: The tag's metadata. + description: The tag's metadata, can hold custom key-value pairs. AdminProductTagDeleteResponse: type: object - description: SUMMARY + description: The details of the product tag deletion. x-schemaName: AdminProductTagDeleteResponse required: - id @@ -50910,10 +53973,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Product Tag was deleted. + description: Whether the product tag was deleted. AdminProductTagListResponse: type: object - description: SUMMARY + description: The paginated list of product tags. x-schemaName: AdminProductTagListResponse required: - limit @@ -50924,23 +53987,23 @@ components: limit: type: number title: limit - description: The product tag's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product tag's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product tag's count. + description: The total number of items. product_tags: type: array - description: The product tag's product tags. + description: The list of product tags. items: $ref: '#/components/schemas/AdminProductTag' AdminProductTagResponse: type: object - description: SUMMARY + description: The product tag's details. x-schemaName: AdminProductTagResponse required: - product_tag @@ -50949,7 +54012,7 @@ components: $ref: '#/components/schemas/AdminProductTag' AdminProductType: type: object - description: The parent's type. + description: The product type's details. x-schemaName: AdminProductType required: - id @@ -50969,1134 +54032,399 @@ components: type: string format: date-time title: created_at - description: The type's created at. + description: The date the type was created. updated_at: type: string format: date-time title: updated_at - description: The type's updated at. + description: The date the type was updated. deleted_at: type: string format: date-time title: deleted_at - description: The type's deleted at. - metadata: - type: object - description: The type's metadata. - AdminProductTypeDeleteResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductTypeDeleteResponse - required: - - id - - object - - deleted - properties: - id: - type: string - title: id - description: The product type's ID. - object: - type: string - title: object - description: The name of the deleted object. - default: product_type - deleted: - type: boolean - title: deleted - description: Whether the Product Type was deleted. - AdminProductTypeListResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductTypeListResponse - required: - - limit - - offset - - count - - product_types - properties: - limit: - type: number - title: limit - description: The product type's limit. - offset: - type: number - title: offset - description: The product type's offset. - count: - type: number - title: count - description: The product type's count. - product_types: - type: array - description: The product type's product types. - items: - $ref: '#/components/schemas/AdminProductType' - AdminProductTypeResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductTypeResponse - required: - - product_type - properties: - product_type: - $ref: '#/components/schemas/AdminProductType' - AdminProductVariant: - type: object - description: The product's parent. - x-schemaName: AdminProductVariant - required: - - prices - - id - - title - - sku - - barcode - - ean - - upc - - allow_backorder - - manage_inventory - - hs_code - - origin_country - - mid_code - - material - - weight - - length - - height - - width - - options - - created_at - - updated_at - - deleted_at - properties: - prices: - type: array - description: The parent's prices. - items: - $ref: '#/components/schemas/AdminPrice' - id: - type: string - title: id - description: The parent's ID. - title: - type: string - title: title - description: The parent's title. - sku: - type: string - title: sku - description: The parent's sku. - barcode: - type: string - title: barcode - description: The parent's barcode. - ean: - type: string - title: ean - description: The parent's ean. - upc: - type: string - title: upc - description: The parent's upc. - allow_backorder: - type: boolean - title: allow_backorder - description: The parent's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The parent's manage inventory. - inventory_quantity: - type: number - title: inventory_quantity - description: The parent's inventory quantity. - hs_code: - type: string - title: hs_code - description: The parent's hs code. - origin_country: - type: string - title: origin_country - description: The parent's origin country. - mid_code: - type: string - title: mid_code - description: The parent's mid code. - material: - type: string - title: material - description: The parent's material. - weight: - type: number - title: weight - description: The parent's weight. - length: - type: number - title: length - description: The parent's length. - height: - type: number - title: height - description: The parent's height. - width: - type: number - title: width - description: The parent's width. - variant_rank: - type: number - title: variant_rank - description: The parent's variant rank. - options: - type: array - description: The parent's options. - items: - $ref: '#/components/schemas/BaseProductOptionValue' - product: - $ref: '#/components/schemas/BaseProduct' - product_id: - type: string - title: product_id - description: The parent's product id. - calculated_price: - $ref: '#/components/schemas/BaseCalculatedPriceSet' - created_at: - type: string - format: date-time - title: created_at - description: The parent's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The parent's updated at. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The parent's deleted at. - metadata: - type: object - description: The parent's metadata. - AdminProductVariantDeleteResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductVariantDeleteResponse - required: - - id - - object - - deleted - properties: - id: - type: string - title: id - description: The product's ID. - object: - type: string - title: object - description: The name of the deleted object. - deleted: - type: boolean - title: deleted - description: Whether the Product was deleted. - parent: - $ref: '#/components/schemas/AdminProduct' - AdminProductVariantInventoryBatchResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductVariantInventoryBatchResponse - required: - - created - - updated - - deleted - properties: - created: - oneOf: - - $ref: '#/components/schemas/AdminProductVariantInventoryLink' - - type: array - description: The product's created. - items: - type: object - description: The created's details. - x-schemaName: AdminProductVariantInventoryLink - required: - - productService - - inventoryService - properties: - productService: - type: object - description: The created's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: - type: object - description: The created's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - updated: - oneOf: - - $ref: '#/components/schemas/AdminProductVariantInventoryLink' - - type: array - description: The product's updated. - items: - type: object - description: The updated's details. - x-schemaName: AdminProductVariantInventoryLink - required: - - productService - - inventoryService - properties: - productService: - type: object - description: The updated's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: - type: object - description: The updated's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - deleted: - oneOf: - - $ref: '#/components/schemas/AdminProductVariantInventoryLink' - - type: array - description: SUMMARY - items: - type: object - description: SUMMARY - x-schemaName: AdminProductVariantInventoryLink - required: - - productService - - inventoryService - properties: - productService: - type: object - description: The deleted's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: - type: object - description: The deleted's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - AdminProductVariantInventoryLink: - type: object - description: The product's ID. - x-schemaName: AdminProductVariantInventoryLink - required: - - productService - - inventoryService - properties: - productService: - type: object - description: The id's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: - type: object - description: The id's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - AdminProductVariantInventoryLinkDeleteResponse: + description: The date the type was deleted. + metadata: + type: object + description: The type's metadata, can hold custom key-value pairs. + AdminProductTypeDeleteResponse: type: object - description: SUMMARY - x-schemaName: AdminProductVariantInventoryLinkDeleteResponse + description: The details of the product type deletion. + x-schemaName: AdminProductTypeDeleteResponse required: - id - object - deleted - - parent properties: id: - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + type: string + title: id + description: The product type's ID. object: type: string title: object description: The name of the deleted object. + default: product_type deleted: type: boolean title: deleted - description: Whether the Product was deleted. - parent: - $ref: '#/components/schemas/AdminProductVariant' - AdminProductVariantParams: + description: Whether the product type was deleted. + AdminProductTypeListResponse: type: object - description: SUMMARY - x-schemaName: AdminProductVariantParams + description: The paginated list of product types. + x-schemaName: AdminProductTypeListResponse + required: + - limit + - offset + - count + - product_types properties: - q: - type: string - title: q - description: The product's q. + limit: + type: number + title: limit + description: The maximum number of items returned. + offset: + type: number + title: offset + description: The number of items skipped before retrieving the returned items. + count: + type: number + title: count + description: The total number of items. + product_types: + type: array + description: The list of product types. + items: + $ref: '#/components/schemas/AdminProductType' + AdminProductTypeResponse: + type: object + description: The product type's details. + x-schemaName: AdminProductTypeResponse + required: + - product_type + properties: + product_type: + $ref: '#/components/schemas/AdminProductType' + AdminProductVariant: + type: object + description: The product variant's details. + x-schemaName: AdminProductVariant + required: + - prices + - options + - id + - title + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory + - hs_code + - origin_country + - mid_code + - material + - weight + - length + - height + - width + - created_at + - updated_at + - deleted_at + properties: + prices: + type: array + description: The variant's prices. + items: + $ref: '#/components/schemas/AdminPrice' id: - oneOf: - - type: string - title: id - description: The product's ID. - - type: array - description: The product's ID. - items: - type: string - title: id - description: The id's ID. - manage_inventory: - type: boolean - title: manage_inventory - description: The product's manage inventory. + type: string + title: id + description: The variant's ID. + title: + type: string + title: title + description: The variant's title. + sku: + type: string + title: sku + description: The variant's SKU. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's EAN code. + upc: + type: string + title: upc + description: The variant's UPC. allow_backorder: type: boolean title: allow_backorder - description: The product's allow backorder. - created_at: - type: object - description: The product's created at. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - updated_at: + description: Whether the variant can be ordered even if it's out of stock. + manage_inventory: + type: boolean + title: manage_inventory + description: Whether the Medusa application manages the variant's inventory quantity and availablility. If disabled, the variant is always considered in stock. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. This is only included if you pass in the `fields` query parameter a `+variants.inventory_quantity` parameter. + hs_code: + type: string + title: hs_code + description: The variant's HS code. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + mid_code: + type: string + title: mid_code + description: The variant's MID code. + material: + type: string + title: material + description: The variant's material. + weight: + type: number + title: weight + description: The variant's weight. + length: + type: number + title: length + description: The variant's length. + height: + type: number + title: height + description: The variant's height. + width: + type: number + title: width + description: The variant's width. + variant_rank: + type: number + title: variant_rank + description: The variant's rank among its sibling variants. + options: + type: array + description: The variant's option values. + items: + $ref: '#/components/schemas/AdminProductOptionValue' + product: type: object - description: The product's updated at. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). + product_id: + type: string + title: product_id + description: The ID of the product that the variant belongs to. + calculated_price: + $ref: '#/components/schemas/BaseCalculatedPriceSet' + created_at: + type: string + format: date-time + title: created_at + description: The date the variant was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the variant was updated. deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the variant was deleted. + metadata: type: object - description: The product's deleted at. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + description: The variant's metadata, can hold custom key-value pairs. + AdminProductVariantDeleteResponse: + type: object + description: The details of the product variant's deletion. + x-schemaName: AdminProductVariantDeleteResponse + required: + - id + - object + - deleted + properties: + id: + type: string + title: id + description: The product variant's ID. + object: + type: string + title: object + description: The name of the deleted object. + deleted: + type: boolean + title: deleted + description: Whether the product variant was deleted. + default: variant + parent: + $ref: '#/components/schemas/AdminProduct' + AdminProductVariantInventoryBatchResponse: + type: object + description: The created, updated, and deleted associations between variants and inventory items. + x-schemaName: AdminProductVariantInventoryBatchResponse + required: + - created + - updated + - deleted + properties: + created: + oneOf: + - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + - type: array + description: The created associations between product variants and inventory items. items: type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + description: A created association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - productService + - inventoryService + properties: + productService: + type: object + description: The product variant's details. + required: + - variant_id + properties: + variant_id: + type: string + title: variant_id + description: The ID of the product variant. + inventoryService: + type: object + description: The inventory item's details. + required: + - inventory_item_id + properties: + inventory_item_id: + type: string + title: inventory_item_id + description: The ID of the inventory item. + updated: + oneOf: + - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + - type: array + description: The updated associations between product variants and inventory items. items: type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: + description: An updated association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - productService + - inventoryService + properties: + productService: + type: object + description: The product variant's details. + required: + - variant_id + properties: + variant_id: type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: + title: variant_id + description: The ID of the product variant. + inventoryService: + type: object + description: The inventory item's details. + required: + - inventory_item_id + properties: + inventory_item_id: type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: + title: inventory_item_id + description: The ID of the inventory item. + deleted: + oneOf: + - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + - type: array + description: The deleted associations between product variants and inventory items. + items: + type: object + description: An deleted association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - productService + - inventoryService + properties: + productService: + type: object + description: The product variant's details. + required: + - variant_id + properties: + variant_id: type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: + title: variant_id + description: The ID of the product variant. + inventoryService: + type: object + description: The inventory item's details. + required: + - inventory_item_id + properties: + inventory_item_id: type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: + title: inventory_item_id + description: The ID of the inventory item. + AdminProductVariantInventoryLink: + type: object + description: The details of an association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - Product + - Inventory + properties: + Product: + type: object + description: The id's product. + required: + - variant_id + properties: + variant_id: type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: + title: variant_id + description: The product's variant id. + Inventory: + type: object + description: The id's inventory. + required: + - inventory_item_id + properties: + inventory_item_id: type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - limit: - type: number - title: limit - description: The product's limit. - offset: - type: number - title: offset - description: The product's offset. - order: - type: string - title: order - description: The product's order. - fields: + title: inventory_item_id + description: The inventory's inventory item id. + AdminProductVariantInventoryLinkDeleteResponse: + type: object + description: The details of the deleted associated between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLinkDeleteResponse + required: + - id + - object + - deleted + - parent + properties: + id: + $ref: '#/components/schemas/AdminProductVariantInventoryLink' + object: type: string - title: fields - description: The product's fields. - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or + title: object + description: The name of the deleted object. + default: variant-inventory-item-link + deleted: + type: boolean + title: deleted + description: Whether the association was deleted. + parent: + $ref: '#/components/schemas/AdminProductVariant' AdminProductVariantResponse: type: object - description: SUMMARY + description: The product variant's details. x-schemaName: AdminProductVariantResponse required: - variant @@ -52105,11 +54433,16 @@ components: $ref: '#/components/schemas/AdminProductVariant' AdminPromotion: type: object - description: The promotion's details. + description: The application method's promotion. x-schemaName: AdminPromotion - required: - - id properties: + application_method: + $ref: '#/components/schemas/AdminApplicationMethod' + rules: + type: array + description: The promotion's rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' id: type: string title: id @@ -52119,31 +54452,28 @@ components: title: code description: The promotion's code. type: - type: string - description: The promotion's type. - enum: - - standard - - buyget + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. is_automatic: type: boolean title: is_automatic description: The promotion's is automatic. - application_method: - $ref: '#/components/schemas/BaseApplicationMethod' - rules: - type: array - description: The promotion's rules. - items: - $ref: '#/components/schemas/BasePromotionRule' campaign_id: type: string title: campaign_id description: The promotion's campaign id. campaign: $ref: '#/components/schemas/AdminCampaign' + required: + - id AdminPromotionResponse: type: object - description: SUMMARY + description: The promotion's details. x-schemaName: AdminPromotionResponse required: - promotion @@ -52152,7 +54482,7 @@ components: $ref: '#/components/schemas/AdminPromotion' AdminPromotionRule: type: object - description: The updated's details. + description: The target rule's target rules. x-schemaName: AdminPromotionRule required: - id @@ -52161,31 +54491,82 @@ components: id: type: string title: id - description: The updated's ID. + description: The target rule's ID. description: type: string title: description - description: The updated's description. + description: The target rule's description. attribute: type: string title: attribute - description: The updated's attribute. + description: The target rule's attribute. operator: - type: string - description: The updated's operator. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte + oneOf: + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. values: type: array - description: The updated's values. + description: The target rule's values. items: $ref: '#/components/schemas/BasePromotionRuleValue' + AdminRefund: + type: object + description: The refund's details. + x-schemaName: AdminRefund + required: + - id + - amount + - created_at + - payment + properties: + id: + type: string + title: id + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: + type: string + title: refund_reason_id + description: The ID of the refund reason. + note: + type: string + title: note + description: More details about the refund. + created_at: + type: string + format: date-time + title: created_at + description: The date the refund was created. + created_by: + type: string + title: created_by + description: The ID of the user that created the refund. + payment: + $ref: '#/components/schemas/BasePayment' + refund_reason: + $ref: '#/components/schemas/RefundReason' AdminRefundReason: type: object description: The refund reason's details. @@ -52211,25 +54592,25 @@ components: description: The refund reason's description. metadata: type: object - description: The refund reason's metadata. + description: The refund reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The refund reason's created at. + description: The date the refund reason was created. updated_at: type: string format: date-time title: updated_at - description: The refund reason's updated at. + description: The date the refund reason was updated. AdminRegion: type: object description: The region's details. x-schemaName: AdminRegion required: - - id - name - currency_code + - id properties: id: type: string @@ -52243,15 +54624,16 @@ components: type: string title: currency_code description: The region's currency code. + example: usd automatic_taxes: type: boolean title: automatic_taxes - description: The region's automatic taxes. + description: Whether taxes are applied automatically during checkout. countries: type: array description: The region's countries. items: - $ref: '#/components/schemas/BaseRegionCountry' + $ref: '#/components/schemas/AdminRegionCountry' payment_providers: type: array description: The region's payment providers. @@ -52259,24 +54641,54 @@ components: $ref: '#/components/schemas/AdminPaymentProvider' metadata: type: object - description: The region's metadata. + description: The region's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The region's created at. + description: The date the region was created. updated_at: type: string format: date-time title: updated_at - description: The region's updated at. + description: The date the region was updated. AdminRegionCountry: type: object - description: The billing address's country. + description: The country's details. x-schemaName: AdminRegionCountry + required: + - id + properties: + id: + type: string + title: id + description: The country's ID. + iso_2: + type: string + title: iso_2 + description: The country's iso 2. + example: us + iso_3: + type: string + title: iso_3 + description: The country's iso 3. + example: usa + num_code: + type: string + title: num_code + description: The country's num code. + example: 840 + name: + type: string + title: name + description: The country's name. + display_name: + type: string + title: display_name + description: The country's display name. AdminRegionResponse: type: object - description: SUMMARY + description: The region's details. x-schemaName: AdminRegionResponse required: - region @@ -52295,7 +54707,6 @@ components: - external_id - description - inventory_item_id - - inventory_item properties: id: type: string @@ -52304,11 +54715,11 @@ components: line_item_id: type: string title: line_item_id - description: The reservation's line item id. + description: The ID of the line item this reservation is for. location_id: type: string title: location_id - description: The reservation's location id. + description: The ID of the location the quantity is reserved from. quantity: type: number title: quantity @@ -52316,7 +54727,7 @@ components: external_id: type: string title: external_id - description: The reservation's external id. + description: An ID in an external system description: type: string title: description @@ -52324,35 +54735,34 @@ components: inventory_item_id: type: string title: inventory_item_id - description: The reservation's inventory item id. + description: The ID of the inventory item this reservation is associated with. inventory_item: - type: object - description: The reservation's inventory item. + $ref: '#/components/schemas/AdminInventoryItem' metadata: type: object - description: The reservation's metadata. + description: The reservation's metadata, can hold custom key-value pairs. created_by: type: string title: created_by - description: The reservation's created by. + description: The ID of the user that created this reservation. deleted_at: type: string format: date-time title: deleted_at - description: The reservation's deleted at. + description: The date this reservation was deleted. created_at: type: string format: date-time title: created_at - description: The reservation's created at. + description: The date this reservation was created. updated_at: type: string format: date-time title: updated_at - description: The reservation's updated at. + description: The date this reservation was updated. AdminReservationResponse: type: object - description: SUMMARY + description: The reservation's details. x-schemaName: AdminReservationResponse required: - reservation @@ -52361,14 +54771,14 @@ components: $ref: '#/components/schemas/AdminReservation' AdminReturn: type: object - description: The exchange's return. + description: The return's details. x-schemaName: AdminReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -52377,14 +54787,47 @@ components: type: string title: id description: The return's ID. + status: + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + description: The return's status. + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. order_id: type: string title: order_id - description: The return's order id. - status: + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: '#/components/schemas/AdminReturnItem' + created_at: type: string - title: status - description: The return's status. + format: date-time + title: created_at + description: The date the return was created. + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time exchange_id: type: string title: exchange_id @@ -52409,31 +54852,13 @@ components: type: boolean title: no_notification description: The return's no notification. - refund_amount: - type: number - title: refund_amount - description: The return's refund amount. - items: - type: array - description: The return's items. - items: - $ref: '#/components/schemas/BaseReturnItem' received_at: type: string title: received_at description: The return's received at. - created_at: - type: string - format: date-time - title: created_at - description: The return's created at. - canceled_at: - type: string - title: canceled_at - description: The return's canceled at. AdminReturnItem: type: object - description: The return item's return items. + description: The item's items. x-schemaName: AdminReturnItem required: - id @@ -52454,33 +54879,33 @@ components: received_quantity: type: number title: received_quantity - description: The return item's received quantity. + description: The received quantity of the item. This quantity is added to the stocked inventory quantity of the item. damaged_quantity: type: number title: damaged_quantity - description: The return item's damaged quantity. + description: The received damaged quantity of the item, which isn't added to the stocked inventory quantity of the item. reason_id: type: string title: reason_id - description: The return item's reason id. + description: The ID of the return reason associated with the item. note: type: string title: note - description: The return item's note. + description: A note about why the item was returned. item_id: type: string title: item_id - description: The return item's item id. + description: The ID of the associated order item. return_id: type: string title: return_id - description: The return item's return id. + description: The ID of the return this return item belongs to. metadata: type: object - description: The return item's metadata. + description: The return item's metadata, can hold custom key-value pairs. AdminReturnPreviewResponse: type: object - description: SUMMARY + description: The details of a return and a preview of the order once the return is applied. x-schemaName: AdminReturnPreviewResponse required: - order_preview @@ -52519,20 +54944,20 @@ components: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. AdminReturnReasonDeleteResponse: type: object - description: SUMMARY + description: The details of the return reason deletion. x-schemaName: AdminReturnReasonDeleteResponse required: - id @@ -52551,10 +54976,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Return Reason was deleted. + description: Whether the return reason was deleted. AdminReturnReasonListResponse: type: object - description: SUMMARY + description: The paginated list of return reasons. x-schemaName: AdminReturnReasonListResponse required: - limit @@ -52565,23 +54990,23 @@ components: limit: type: number title: limit - description: The return reason's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The return reason's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The return reason's count. + description: The total number of items. return_reasons: type: array - description: The return reason's return reasons. + description: The list of return reasons. items: $ref: '#/components/schemas/AdminReturnReason' AdminReturnReasonResponse: type: object - description: SUMMARY + description: The return reason's details. x-schemaName: AdminReturnReasonResponse required: - return_reason @@ -52590,7 +55015,7 @@ components: $ref: '#/components/schemas/AdminReturnReason' AdminReturnResponse: type: object - description: SUMMARY + description: The return's details. x-schemaName: AdminReturnResponse required: - return @@ -52599,50 +55024,38 @@ components: $ref: '#/components/schemas/AdminReturn' AdminRevokeApiKey: type: object - description: SUMMARY + description: The details of revoking the API key. x-schemaName: AdminRevokeApiKey properties: revoke_in: type: number title: revoke_in - description: The api key's revoke in. + description: The time in seconds to revoke the API key after. If not set, the API key is revoked immediately. AdminRuleAttributeOption: type: object - description: The attribute's attributes. + description: The details of a potential rule attribute. x-schemaName: AdminRuleAttributeOption required: - id - value - label - - field_type - - required - - disguised - operators properties: id: type: string title: id - description: The attribute's ID. + description: The rule attribute's ID, which is a rule's `attribute` it refers to. + example: customer_group value: type: string title: value - description: The attribute's value. + description: The rule attribute's value. + example: customer.groups.id label: type: string title: label - description: The attribute's label. - field_type: - type: string - title: field_type - description: The attribute's field type. - required: - type: boolean - title: required - description: The attribute's required. - disguised: - type: boolean - title: disguised - description: The attribute's disguised. + description: The rule attribute option's label. + example: Customer Group operators: type: array description: The attribute's operators. @@ -52650,28 +55063,25 @@ components: $ref: '#/components/schemas/BaseRuleOperatorOptions' AdminRuleValueOption: type: object - description: The value's values. + description: The details of a potential rule value. x-schemaName: AdminRuleValueOption required: - - id - value - label properties: - id: - type: string - title: id - description: The value's ID. value: type: string title: value - description: The value's details. + description: The rule value's value. + example: reg_123 label: type: string title: label - description: The value's label. + description: The rule value's label. + example: Europe Region AdminSalesChannel: type: object - description: The order's sales channel. + description: The sales channel's details. x-schemaName: AdminSalesChannel required: - id @@ -52698,28 +55108,28 @@ components: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The sales channel's created at. + description: The date the sales channel was created. updated_at: type: string format: date-time title: updated_at - description: The sales channel's updated at. + description: The date the sales channel was updated. deleted_at: type: string format: date-time title: deleted_at - description: The sales channel's deleted at. + description: The date the sales channel was deleted. AdminSalesChannelDeleteResponse: type: object - description: SUMMARY + description: The details of deleting a sales channel. x-schemaName: AdminSalesChannelDeleteResponse required: - id @@ -52738,10 +55148,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Sales Channel was deleted. + description: Whether the sales channel was deleted. AdminSalesChannelResponse: type: object - description: SUMMARY + description: The sales channel's details. x-schemaName: AdminSalesChannelResponse required: - sales_channel @@ -52750,7 +55160,7 @@ components: $ref: '#/components/schemas/AdminSalesChannel' AdminServiceZone: type: object - description: The service zone's service zones. + description: The shipping option's service zone. x-schemaName: AdminServiceZone required: - id @@ -52804,7 +55214,7 @@ components: description: The service zone's deleted at. AdminServiceZoneDeleteResponse: type: object - description: SUMMARY + description: The details of the service zone deletion. x-schemaName: AdminServiceZoneDeleteResponse required: - id @@ -52814,20 +55224,21 @@ components: id: type: string title: id - description: The fulfillment set's ID. + description: The service zone's ID. object: type: string title: object description: The name of the deleted object. + default: service_zone deleted: type: boolean title: deleted - description: Whether the Fulfillment Set was deleted. + description: Whether the service zone was deleted. parent: $ref: '#/components/schemas/AdminFulfillmentSet' AdminServiceZoneResponse: type: object - description: SUMMARY + description: The service zone's details. x-schemaName: AdminServiceZoneResponse required: - service_zone @@ -52836,11 +55247,102 @@ components: $ref: '#/components/schemas/AdminServiceZone' AdminShippingOption: type: object - description: The shipping option's shipping options. + description: The shipping option's details. x-schemaName: AdminShippingOption + required: + - id + - name + - price_type + - service_zone_id + - service_zone + - provider_id + - provider + - shipping_option_type_id + - type + - shipping_profile_id + - shipping_profile + - rules + - prices + - data + - metadata + - created_at + - updated_at + - deleted_at + properties: + id: + type: string + title: id + description: The shipping option's ID. + name: + type: string + title: name + description: The shipping option's name. + price_type: + type: string + description: The shipping option's price type. If it's `flat`, the price is fixed and is set in the `prices` property. If it's `calculated`, the price is calculated on checkout by the associated fulfillment provider. + enum: + - calculated + - flat + service_zone_id: + type: string + title: service_zone_id + description: The ID of the service zone this option belongs to. + service_zone: + type: object + provider_id: + type: string + title: provider_id + description: The ID of the provider handling fulfillments created from this shipping option. + provider: + $ref: '#/components/schemas/AdminFulfillmentProvider' + shipping_option_type_id: + type: string + title: shipping_option_type_id + description: The ID of the associated shipping option type. + type: + type: object + shipping_profile_id: + type: string + title: shipping_profile_id + description: The ID of the associated shipping profile. + shipping_profile: + $ref: '#/components/schemas/AdminShippingProfile' + rules: + type: array + description: The shipping option's rules. + items: + $ref: '#/components/schemas/AdminShippingOptionRule' + prices: + type: array + description: The shipping option's prices. If the `price_type` is `calculated`, this array will be empty since the price is calculated by the fulfillment provider during checkout. + items: + $ref: '#/components/schemas/AdminShippingOptionPrice' + data: + type: object + description: The shipping option's data, useful for the fulfillment provider handling fulfillments created from this option. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping option's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping option was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping option was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping option was deleted. AdminShippingOptionDeleteResponse: type: object - description: SUMMARY + description: The details of the shipping option's deletion. x-schemaName: AdminShippingOptionDeleteResponse required: - id @@ -52859,10 +55361,101 @@ components: deleted: type: boolean title: deleted - description: Whether the Shipping Option was deleted. + description: Whether the shipping option was deleted. + AdminShippingOptionPrice: + type: object + description: The details of the shipping option's price. + x-schemaName: AdminShippingOptionPrice + required: + - price_rules + - rules_count + - id + - title + - currency_code + - amount + - raw_amount + - min_quantity + - max_quantity + - price_set_id + - created_at + - updated_at + - deleted_at + properties: + price_rules: + type: array + description: The price's rules. + items: + $ref: '#/components/schemas/AdminShippingOptionPriceRule' + rules_count: + type: number + title: rules_count + description: The number of rules the price has. + id: + type: string + title: id + description: The price's ID. + title: + type: string + title: title + description: The price's title. + currency_code: + type: string + title: currency_code + description: The price's currency code. + example: usd + amount: + type: number + title: amount + description: The price's amount. + raw_amount: + type: object + description: The price's raw amount. + min_quantity: + type: number + title: min_quantity + description: The minimum quantity required in the cart for this price to apply. + max_quantity: + type: number + title: max_quantity + description: The maximum quantity that the cart's items must not surpass for this price to apply. + price_set_id: + type: string + title: price_set_id + description: The ID of the price set this price belongs to. + created_at: + type: string + format: date-time + title: created_at + description: The date the price was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the price was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the price was deleted. + AdminShippingOptionPriceRule: + type: object + description: The details of a shipping option price's rule. + x-schemaName: AdminShippingOptionPriceRule + required: + - id + - value + properties: + id: + type: string + title: id + description: The price rule's ID. + value: + type: string + title: value + description: The price rule's value. AdminShippingOptionResponse: type: object - description: SUMMARY + description: The shipping option's details. x-schemaName: AdminShippingOptionResponse required: - shipping_option @@ -52871,7 +55464,7 @@ components: $ref: '#/components/schemas/AdminShippingOption' AdminShippingOptionRule: type: object - description: The updated's details. + description: The shipping option rule's details. x-schemaName: AdminShippingOptionRule required: - id @@ -52886,52 +55479,95 @@ components: id: type: string title: id - description: The updated's ID. + description: The shipping option rule's ID. attribute: type: string title: attribute - description: The updated's attribute. + description: The shipping option rule's attribute. + example: is_return operator: type: string title: operator - description: The updated's operator. + description: The shipping option rule's operator. + example: eq value: oneOf: - type: string title: value - description: The updated's value. + description: The rule's value. + example: '"true"' - type: array - description: The updated's value. + description: The rule's values. items: type: string title: value - description: The value's details. + description: A rule's value + example: '"true"' shipping_option_id: type: string title: shipping_option_id - description: The updated's shipping option id. + description: The ID of the shipping option this rule is for. created_at: type: string format: date-time title: created_at - description: The updated's created at. + description: The date the shipping option rule was created. updated_at: type: string format: date-time title: updated_at - description: The updated's updated at. + description: The date the shipping option rule was updated. deleted_at: type: string format: date-time title: deleted_at - description: The updated's deleted at. + description: The date the shipping option rule was deleted. AdminShippingProfile: type: object - description: The shipping option's shipping profile. + description: The shipping profile's details.. x-schemaName: AdminShippingProfile + properties: + id: + type: string + title: id + description: The shipping profile's ID. + name: + type: string + title: name + description: The shipping profile's name. + type: + type: string + title: type + description: The shipping profile's type. + metadata: + type: object + description: The shipping profile's metadata, holds custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping profile was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping profile was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping profile was deleted. + required: + - id + - name + - type + - metadata + - created_at + - updated_at + - deleted_at AdminShippingProfileDeleteResponse: type: object - description: SUMMARY + description: The details of the shipping profile's deletion. x-schemaName: AdminShippingProfileDeleteResponse required: - id @@ -52950,10 +55586,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Shipping Profile was deleted. + description: Whether the shipping profile was deleted. AdminShippingProfileResponse: type: object - description: SUMMARY + description: The shipping profile's details. x-schemaName: AdminShippingProfileResponse required: - shipping_profile @@ -52962,7 +55598,7 @@ components: $ref: '#/components/schemas/AdminShippingProfile' AdminStockLocation: type: object - description: The parent's location. + description: The stock location's details. x-schemaName: AdminStockLocation required: - id @@ -52980,31 +55616,77 @@ components: address_id: type: string title: address_id - description: The location's address id. + description: The ID of the associated address. address: - $ref: '#/components/schemas/AdminStockLocationAddress' + type: object + description: The details of the stock location address. + x-schemaName: AdminStockLocationAddress + properties: + id: + type: string + title: id + description: The address's ID. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + company: + type: string + title: company + description: The address's company. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + city: + type: string + title: city + description: The address's city. + phone: + type: string + title: phone + description: The address's phone. + postal_code: + type: string + title: postal_code + description: The address's postal code. + province: + type: string + title: province + description: The address's province. + required: + - id + - address_1 + - address_2 + - company + - country_code + - city + - phone + - postal_code + - province sales_channels: type: array - description: The location's sales channels. + description: The sales channels associated with the location. items: $ref: '#/components/schemas/AdminSalesChannel' fulfillment_providers: type: array - description: The location's fulfillment providers. + description: The fulfillment providers associated with the location. items: $ref: '#/components/schemas/AdminFulfillmentProvider' fulfillment_sets: type: array - description: The location's fulfillment sets. + description: The fulfillment sets associated with the location. items: type: object - AdminStockLocationAddress: - type: object - description: The location's address. - x-schemaName: AdminStockLocationAddress AdminStockLocationDeleteResponse: type: object - description: SUMMARY + description: The details of the stock location's deletion. x-schemaName: AdminStockLocationDeleteResponse required: - id @@ -53023,10 +55705,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Stock Location was deleted. + description: Whether the stock location was deleted. AdminStockLocationListResponse: type: object - description: SUMMARY + description: The paginated list of stock locations. x-schemaName: AdminStockLocationListResponse required: - limit @@ -53037,23 +55719,23 @@ components: limit: type: number title: limit - description: The stock location's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The stock location's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The stock location's count. + description: The total number of items. stock_locations: type: array - description: The stock location's stock locations. + description: The list of stock locations. items: $ref: '#/components/schemas/AdminStockLocation' AdminStockLocationResponse: type: object - description: SUMMARY + description: The stock location's details. x-schemaName: AdminStockLocationResponse required: - stock_location @@ -53091,31 +55773,31 @@ components: default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the sales channel used by default in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the region used by default in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the stock location used by default in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The store's created at. + description: The date the store was created. updated_at: type: string format: date-time title: updated_at - description: The store's updated at. + description: The date the store was updated. AdminStoreCurrency: type: object - description: The supported currency's supported currencies. + description: The details of a store's currency. x-schemaName: AdminStoreCurrency required: - id @@ -53130,39 +55812,40 @@ components: id: type: string title: id - description: The supported currency's ID. + description: The currency's ID. currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd store_id: type: string title: store_id - description: The supported currency's store id. + description: The ID of the store this currency belongs to. is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether this currency is the default in the store. currency: $ref: '#/components/schemas/AdminCurrency' created_at: type: string format: date-time title: created_at - description: The supported currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The supported currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The supported currency's deleted at. + description: The date the currency was deleted. AdminStoreListResponse: type: object - description: SUMMARY + description: The paginated list of stores. x-schemaName: AdminStoreListResponse required: - limit @@ -53173,23 +55856,23 @@ components: limit: type: number title: limit - description: The store's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The store's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The store's count. + description: The total number of items. stores: type: array - description: The store's stores. + description: The list of stores. items: $ref: '#/components/schemas/AdminStore' AdminStoreResponse: type: object - description: SUMMARY + description: The store's details. x-schemaName: AdminStoreResponse required: - store @@ -53198,7 +55881,7 @@ components: $ref: '#/components/schemas/AdminStore' AdminTaxRate: type: object - description: The tax rate's parent. + description: The tax rate's details. x-schemaName: AdminTaxRate required: - id @@ -53219,63 +55902,66 @@ components: id: type: string title: id - description: The parent's ID. + description: The tax rate's ID. rate: type: number title: rate - description: The parent's rate. + description: The rate to charge. + example: 10 code: type: string title: code - description: The parent's code. + description: The code the tax rate is identified by. name: type: string title: name - description: The parent's name. + description: The tax rate's name. metadata: type: object - description: The parent's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. tax_region_id: type: string title: tax_region_id - description: The parent's tax region id. + description: The ID of the tax region this rate belongs to. is_combinable: type: boolean title: is_combinable - description: The parent's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates is_default: type: boolean title: is_default - description: The parent's is default. + description: Whether this tax rate is the default in the tax region. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the tax rate was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the tax rate was updated. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The date the tax rate was deleted. created_by: type: string title: created_by - description: The parent's created by. + description: The ID of the user that created the tax rate. tax_region: $ref: '#/components/schemas/AdminTaxRegion' rules: type: array - description: The parent's rules. + description: The tax rate's rules. items: $ref: '#/components/schemas/AdminTaxRateRule' AdminTaxRateDeleteResponse: type: object - description: SUMMARY + description: The details of the tax rate deletion. x-schemaName: AdminTaxRateDeleteResponse required: - id @@ -53294,10 +55980,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Tax Rate was deleted. + description: Whether the tax rate was deleted. AdminTaxRateResponse: type: object - description: SUMMARY + description: The tax rate's details. x-schemaName: AdminTaxRateResponse required: - tax_rate @@ -53306,7 +55992,7 @@ components: $ref: '#/components/schemas/AdminTaxRate' AdminTaxRateRule: type: object - description: The rule's rules. + description: The tax rate rule's details. x-schemaName: AdminTaxRateRule required: - reference @@ -53315,26 +56001,22 @@ components: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of a record in the table that this rule references. + example: ptyp_1 AdminTaxRegion: type: object - description: The parent's tax region. + description: The tax region's details. x-schemaName: AdminTaxRegion required: - id - - rate - - code - country_code - province_code - - name - metadata - - tax_region_id - - is_combinable - - is_default - parent_id - created_at - updated_at @@ -53348,67 +56030,44 @@ components: type: string title: id description: The tax region's ID. - rate: - type: number - title: rate - description: The tax region's rate. - code: - type: string - title: code - description: The tax region's code. country_code: type: string title: country_code description: The tax region's country code. + example: us province_code: type: string title: province_code description: The tax region's province code. - name: - type: string - title: name - description: The tax region's name. metadata: type: object - description: The tax region's metadata. - tax_region_id: - type: string - title: tax_region_id - description: The tax region's tax region id. - is_combinable: - type: boolean - title: is_combinable - description: The tax region's is combinable. - is_default: - type: boolean - title: is_default - description: The tax region's is default. + description: The tax region's metadata, can hold custom key-value pairs. parent_id: type: string title: parent_id - description: The tax region's parent id. + description: The ID of the parent tax region. created_at: type: string format: date-time title: created_at - description: The tax region's created at. + description: The date the tax region was created. updated_at: type: string format: date-time title: updated_at - description: The tax region's updated at. + description: The date the tax region was updated. deleted_at: type: string format: date-time title: deleted_at - description: The tax region's deleted at. + description: The date the tax region was deleted. created_by: type: string title: created_by - description: The tax region's created by. + description: The ID of the user that created the tax region. tax_rates: type: array - description: The tax region's tax rates. + description: The tax region's rates. items: type: object parent: @@ -53420,7 +56079,7 @@ components: type: object AdminTaxRegionDeleteResponse: type: object - description: SUMMARY + description: The details of the tax region deletion. x-schemaName: AdminTaxRegionDeleteResponse required: - id @@ -53439,10 +56098,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Tax Region was deleted. + description: Whether the tax region was deleted. AdminTaxRegionResponse: type: object - description: SUMMARY + description: The tax region's details. x-schemaName: AdminTaxRegionResponse required: - tax_region @@ -53451,7 +56110,7 @@ components: $ref: '#/components/schemas/AdminTaxRegion' AdminUpdateApiKey: type: object - description: SUMMARY + description: The details to update in an API key. x-schemaName: AdminUpdateApiKey required: - title @@ -53459,10 +56118,10 @@ components: title: type: string title: title - description: The api key's title. + description: The API key's title. AdminUpdateCollection: type: object - description: SUMMARY + description: The details to update in a collection. x-schemaName: AdminUpdateCollection properties: title: @@ -53475,10 +56134,10 @@ components: description: The collection's handle. metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. AdminUpdateCustomerGroup: type: object - description: SUMMARY + description: The details to update in a customer group. x-schemaName: AdminUpdateCustomerGroup properties: name: @@ -53487,10 +56146,10 @@ components: description: The customer group's name. metadata: type: object - description: The customer group's metadata. + description: The customer group's metadata, can hold custom key-value pairs. AdminUpdatePriceList: type: object - description: SUMMARY + description: the details to update in a price list. x-schemaName: AdminUpdatePriceList properties: title: @@ -53504,111 +56163,133 @@ components: starts_at: type: string title: starts_at - description: The price list's starts at. + description: The date the price list starts. ends_at: type: string title: ends_at - description: The price list's ends at. + description: The date the price list ends. status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. + example: + customer_group_id: + - cusgrp_123 AdminUpdatePricePreference: type: object - description: SUMMARY + description: The details to update in the price preference. x-schemaName: AdminUpdatePricePreference properties: attribute: type: string title: attribute description: The price preference's attribute. + example: region_id value: type: string title: value description: The price preference's value. + example: reg_123 is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The price preference's is tax inclusive. + description: Whether prices are tax inclusive for this price preference. AdminUpdateProduct: type: object - description: The update's details. + description: The product's details. x-schemaName: AdminUpdateProduct properties: title: type: string title: title - description: The update's title. + description: The product's title. subtitle: type: string title: subtitle - description: The update's subtitle. + description: The product's subtitle. description: type: string title: description - description: The update's description. + description: The product's description. is_giftcard: type: boolean title: is_giftcard - description: The update's is giftcard. + description: Whether the product is a gift card. discountable: type: boolean title: discountable - description: The update's discountable. + description: Whether discounts can be applied on the product. images: type: array - description: The update's images. + description: The product's images. items: type: object - description: The image's images. + description: The image's details. required: - url properties: url: type: string title: url - description: The image's url. + description: The image's URL. thumbnail: type: string title: thumbnail - description: The update's thumbnail. + description: The product's thumbnail URL. handle: type: string title: handle - description: The update's handle. + description: The product's unique handle. status: - type: string - description: The update's status. - enum: - - draft - - proposed - - published - - rejected + oneOf: + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + description: The product's status. type_id: type: string title: type_id - description: The update's type id. + description: The ID of the product's type. collection_id: type: string title: collection_id - description: The update's collection id. + description: The ID of the product's collection. categories: type: array - description: The update's categories. + description: The product's categories. items: type: object - description: The category's categories. + description: The product's category. required: - id properties: @@ -53618,10 +56299,10 @@ components: description: The category's ID. tags: type: array - description: The update's tags. + description: The product's tags. items: type: object - description: The tag's tags. + description: The product's tag. required: - id properties: @@ -53631,181 +56312,22 @@ components: description: The tag's ID. options: type: array - description: The update's options. + description: The product's options. items: $ref: '#/components/schemas/AdminUpdateProductOption' variants: type: array - description: The update's variants. + description: The product's variants. You can add new variants or update existing ones, passing their IDs in the object. items: oneOf: - - type: object - description: The variant's variants. - x-schemaName: AdminCreateProductVariant - required: - - title - - prices - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: '#/components/schemas/AdminCreateProductVariantPrice' - options: - type: object - description: The variant's options. - - type: object - description: The variant's variants. - x-schemaName: AdminUpdateProductVariant - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: '#/components/schemas/AdminCreateProductVariantPrice' - options: - type: object - description: The variant's options. + - $ref: '#/components/schemas/AdminCreateProductVariant' + - $ref: '#/components/schemas/AdminUpdateProductVariant' sales_channels: type: array - description: The update's sales channels. + description: The sales channels that the product is available in. items: type: object - description: The sales channel's sales channels. + description: The sales channel's details. required: - id properties: @@ -53816,137 +56338,160 @@ components: weight: type: number title: weight - description: The update's weight. + description: The product's weight. length: type: number title: length - description: The update's length. + description: The product's length. height: type: number title: height - description: The update's height. + description: The product's height. width: type: number title: width - description: The update's width. + description: The product's width. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product's MID code. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product's origin country. material: type: string title: material - description: The update's material. + description: The product's material. metadata: type: object - description: The update's metadata. + description: The product's metadata, can hold custom key-value pairs. AdminUpdateProductOption: type: object - description: SUMMARY + description: The details to update in a product option. x-schemaName: AdminUpdateProductOption properties: title: type: string title: title - description: The product's title. + description: The option's title. values: type: array - description: The product's values. + description: The option's values. items: type: string title: values - description: The value's values. + description: An option value. AdminUpdateProductVariant: type: object - description: The update's details. + description: The properties to update of a product variant. x-schemaName: AdminUpdateProductVariant properties: title: type: string title: title - description: The update's title. + description: The product variant's title. sku: type: string title: sku - description: The update's sku. + description: The product variant's SKU. ean: type: string title: ean - description: The update's ean. + description: The product variant's EAN. upc: type: string title: upc - description: The update's upc. + description: The product variant's UPC. barcode: type: string title: barcode - description: The update's barcode. + description: The product variant's barcode. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product variant's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product variant's MID code. allow_backorder: type: boolean title: allow_backorder - description: The update's allow backorder. + description: Whether customers can order the variant even if it's not in stock. manage_inventory: type: boolean title: manage_inventory - description: The update's manage inventory. + description: Whether the Medusa application manages the variant's inventory. If disabled, the product variant is always considered in stock. variant_rank: type: number title: variant_rank - description: The update's variant rank. + description: The product variant's rank among its siblings. weight: type: number title: weight - description: The update's weight. + description: The product variant's weight. length: type: number title: length - description: The update's length. + description: The product variant's length. height: type: number title: height - description: The update's height. + description: The product variant's height. width: type: number title: width - description: The update's width. + description: The product variant's width. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product variant's origin country. material: type: string title: material - description: The update's material. + description: The product variant's material. metadata: type: object - description: The update's metadata. + description: The product variant's metadata, can hold custom key-value pairs. prices: type: array - description: The update's prices. + description: The product variant's prices. items: $ref: '#/components/schemas/AdminCreateProductVariantPrice' options: type: object - description: The update's options. + description: The product variant's options. + AdminUpdateReturnReason: + type: object + description: The details to update in a return reason. + x-schemaName: AdminUpdateReturnReason + properties: + label: + type: string + title: label + description: The return reason's label. + value: + type: string + title: value + description: The return reason's value. + description: + type: string + title: description + description: The return reason's description. + metadata: + type: object + description: The return reason's metadata, can hold custom key-value pairs. + required: + - value + - label AdminUpdateSalesChannel: type: object - description: SUMMARY + description: The properties to update in the sales channel. x-schemaName: AdminUpdateSalesChannel properties: name: @@ -53960,13 +56505,13 @@ components: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. AdminUpdateStockLocation: type: object - description: SUMMARY + description: The properties to update in a stock location. x-schemaName: AdminUpdateStockLocation properties: name: @@ -53975,7 +56520,7 @@ components: description: The stock location's name. address: type: object - description: The stock location's address. + description: The stock location's address. Pass this property if you're creating a new address to associate with the location. required: - address_1 - country_code @@ -53983,11 +56528,11 @@ components: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -54000,6 +56545,7 @@ components: type: string title: country_code description: The address's country code. + example: us phone: type: string title: phone @@ -54015,13 +56561,13 @@ components: address_id: type: string title: address_id - description: The stock location's address id. + description: The ID of an existing stock location address to associate the stock location with. metadata: type: object - description: The stock location's metadata. + description: The stock location's metadata, can hold custom key-value pairs. AdminUpdateStore: type: object - description: SUMMARY + description: The properties to update in a store. x-schemaName: AdminUpdateStore properties: name: @@ -54033,56 +56579,57 @@ components: description: The store's supported currencies. items: type: object - description: The supported currency's supported currencies. + description: A store currency. required: - currency_code properties: currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether the currency is the default in the store. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The supported currency's is tax inclusive. + description: Whether prices using this currency are tax inclusive. default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the default sales channel in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the default region in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the default stock location in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. AdminUpdateTaxRate: type: object - description: SUMMARY + description: The properties to update in the tax rate. x-schemaName: AdminUpdateTaxRate properties: rate: type: number title: rate - description: The tax rate's rate. + description: The rate to charge. code: type: string title: code - description: The tax rate's code. + description: The code that the tax rate is identified by. rules: type: array description: The tax rate's rules. items: type: object - description: The rule's rules. + description: A tax rate rule. required: - reference - reference_id @@ -54090,11 +56637,13 @@ components: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of the record in the table that the rule references. + example: ptyp_123 name: type: string title: name @@ -54102,17 +56651,19 @@ components: is_default: type: boolean title: is_default - description: The tax rate's is default. + description: Whether the tax rate is the default in the store. is_combinable: type: boolean title: is_combinable - description: The tax rate's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates metadata: type: object - description: The tax rate's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. AdminUpdateUser: type: object - description: SUMMARY + description: The properties to update in a user. x-schemaName: AdminUpdateUser properties: first_name: @@ -54126,10 +56677,10 @@ components: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. AdminUpdateVariantInventoryItem: type: object - description: SUMMARY + description: The properties to update of the variant's inventory item association. x-schemaName: AdminUpdateVariantInventoryItem required: - required_quantity @@ -54137,10 +56688,10 @@ components: required_quantity: type: number title: required_quantity - description: The product's required quantity. + description: The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the value set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`. AdminUpsertStockLocationAddress: type: object - description: The stock location's address. + description: The details of the stock location address to create. x-schemaName: AdminUpsertStockLocationAddress required: - address_1 @@ -54149,11 +56700,11 @@ components: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -54162,6 +56713,7 @@ components: type: string title: country_code description: The address's country code. + example: usd city: type: string title: city @@ -54213,28 +56765,28 @@ components: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. metadata: type: object - description: The user's metadata. + description: The user's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The user's created at. + description: The date the user was created. updated_at: type: string format: date-time title: updated_at - description: The user's updated at. + description: The date the user was updated. deleted_at: type: string format: date-time title: deleted_at - description: The user's deleted at. + description: The date the user was deleted. AdminUserDeleteResponse: type: object - description: SUMMARY + description: The details of the deleted user. x-schemaName: AdminUserDeleteResponse required: - id @@ -54253,10 +56805,10 @@ components: deleted: type: boolean title: deleted - description: Whether the User was deleted. + description: Whether the user was deleted. AdminUserListResponse: type: object - description: SUMMARY + description: The paginated list of users. x-schemaName: AdminUserListResponse required: - limit @@ -54267,23 +56819,23 @@ components: limit: type: number title: limit - description: The user's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The user's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The user's count. + description: The total number of items. users: type: array - description: The user's users. + description: The list of users. items: $ref: '#/components/schemas/AdminUser' AdminUserResponse: type: object - description: SUMMARY + description: The user's details. x-schemaName: AdminUserResponse required: - user @@ -54292,7 +56844,7 @@ components: $ref: '#/components/schemas/AdminUser' AdminWorkflowExecution: type: object - description: The workflows execution's workflow execution. + description: The workflows execution's details. x-schemaName: AdminWorkflowExecution required: - id @@ -54311,11 +56863,11 @@ components: workflow_id: type: string title: workflow_id - description: The workflow execution's workflow id. + description: The ID of the workflow. transaction_id: type: string title: transaction_id - description: The workflow execution's transaction id. + description: The workflow execution's transaction ID. execution: $ref: '#/components/schemas/AdminWorkflowExecutionExecution' context: @@ -54335,30 +56887,160 @@ components: type: string format: date-time title: created_at - description: The workflow execution's created at. + description: The date the workflow execution was created. updated_at: type: string format: date-time title: updated_at - description: The workflow execution's updated at. + description: The date the workflow execution was updated. deleted_at: type: string format: date-time title: deleted_at - description: The workflow execution's deleted at. + description: The date the workflow execution was deleted. AdminWorkflowExecutionExecution: type: object - description: The workflow execution's execution. + description: The workflow execution's steps details. x-schemaName: AdminWorkflowExecutionExecution required: - steps properties: steps: type: object - description: The execution's steps. + description: The execution's steps. Each object key is a step ID, and the value is the object whose properties are shown below. + required: + - id + - invoke + - definition + - compensate + - depth + - startedAt + additionalProperties: + type: object + properties: + id: + type: string + title: id + description: The step's ID. + invoke: + type: object + description: The state of the step's invokation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The invokation step's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The invokation step's state. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + definition: + type: object + description: The step's definition details. + x-schemaName: WorkflowExecutionDefinition + properties: + async: + type: boolean + title: async + description: Whether the step is async. + compensateAsync: + type: boolean + title: compensateAsync + description: Whether the compensation function of the step is async. + noCompensation: + type: boolean + title: noCompensation + description: Whether the step doesn't have a compensation function. + continueOnPermanentFailure: + type: boolean + title: continueOnPermanentFailure + description: Whether the step continues executing even if its status is changed to failed. + maxRetries: + type: number + title: maxRetries + description: The maximum number of times to retry the step. + noWait: + type: boolean + title: noWait + description: Whether the workflow shouldn't wait for the step to finish before moving to the next step. + default: false + retryInterval: + type: number + title: retryInterval + description: The interval in seconds between retry attempts when the step fails. + retryIntervalAwaiting: + type: number + title: retryIntervalAwaiting + description: The interval in seconds to retry a step even if its status is `waiting_response`. + saveResponse: + type: boolean + title: saveResponse + description: Whether the step's response is stored. + timeout: + type: number + title: timeout + description: The maximum time in seconds to wait for this step to complete. If the step exceeds this time, the step's state is changed to `timeout`, but the step continues executing. + compensate: + type: object + description: The state of the step's compensation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The compensation function's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The compensation function's status. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + depth: + type: number + title: depth + description: The step's depth in the workflow's execution. + startedAt: + type: number + title: startedAt + description: The timestamp the step started executing. AdminWorkflowExecutionResponse: type: object - description: SUMMARY + description: The workflow execution's details. x-schemaName: AdminWorkflowExecutionResponse required: - workflow_execution @@ -54367,7 +57049,7 @@ components: $ref: '#/components/schemas/AdminWorkflowExecution' ApiKeyResponse: type: object - description: The api key's details. + description: The API key's details. x-schemaName: ApiKeyResponse required: - id @@ -54384,46 +57066,47 @@ components: id: type: string title: id - description: The api key's ID. + description: The API key's ID. token: type: string title: token - description: The api key's token. + description: The API key's token. redacted: type: string title: redacted - description: The api key's redacted. + description: The redacted form of the API key's token. This is useful when showing portion of the token. For example `sk_...123`. title: type: string title: title - description: The api key's title. + description: The API key's title. type: type: string + description: The API key's type. `secret` API keys are used for authenticating admin users, and `publishable` API key are used for storefronts and similar clients to scope requests to sales channels. enum: - secret - publishable last_used_at: type: string title: last_used_at - description: The api key's last used at. + description: The date the API key was last used. format: date-time created_by: type: string title: created_by - description: The api key's created by. + description: The ID of the user that created the API key. created_at: type: string title: created_at - description: The api key's created at. + description: The date the API key was created. format: date-time revoked_by: type: string title: revoked_by - description: The api key's revoked by. + description: The ID of the user that revoked the API key. revoked_at: type: string title: revoked_at - description: The api key's revoked at. + description: The date the API key was revoked. format: date-time AuthAdminSessionResponse: type: object @@ -54469,68 +57152,6 @@ components: title: user description: The logged-in customer. $ref: '#/components/schemas/StoreCustomer' - BaseApplicationMethod: - type: object - description: The promotion's application method. - x-schemaName: BaseApplicationMethod - required: - - id - properties: - id: - type: string - title: id - description: The application method's ID. - type: - type: string - description: The application method's type. - enum: - - fixed - - percentage - target_type: - type: string - description: The application method's target type. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: The application method's allocation. - enum: - - each - - across - value: - type: number - title: value - description: The application method's value. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: The application method's max quantity. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: The application method's buy rules min quantity. - apply_to_quantity: - type: number - title: apply_to_quantity - description: The application method's apply to quantity. - promotion: - $ref: '#/components/schemas/BasePromotion' - target_rules: - type: array - description: The application method's target rules. - items: - $ref: '#/components/schemas/BasePromotionRule' - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: '#/components/schemas/BasePromotionRule' BaseCalculatedPriceSet: type: object description: The parent's calculated price. @@ -54584,90 +57205,273 @@ components: calculated_price: type: object description: The calculated price's details. + properties: + id: + type: string + title: id + description: The calculated price's ID. + price_list_id: + type: string + title: price_list_id + description: The calculated price's price list id. + price_list_type: + type: string + title: price_list_type + description: The calculated price's price list type. + min_quantity: + type: number + title: min_quantity + description: The calculated price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The calculated price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity original_price: type: object description: The calculated price's original price. + properties: + id: + type: string + title: id + description: The original price's ID. + price_list_id: + type: string + title: price_list_id + description: The original price's price list id. + price_list_type: + type: string + title: price_list_type + description: The original price's price list type. + min_quantity: + type: number + title: min_quantity + description: The original price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The original price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity BaseCapture: type: object - description: The capture's captures. + description: The details of a captured payment. x-schemaName: BaseCapture + required: + - id + - amount + - created_at + - payment + properties: + id: + type: string + title: id + description: The payment capture's ID. + amount: + type: number + title: amount + description: The captured amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the capture was created. + created_by: + type: string + title: created_by + description: The ID of the user that captured the payment. + payment: + type: object BaseCart: type: object description: The item's cart. x-schemaName: BaseCart - BaseCartAddress: - type: object - description: The parent's billing address. - x-schemaName: BaseCartAddress required: - id - - created_at - - updated_at + - currency_code + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total properties: id: type: string title: id - description: The billing address's ID. + description: The cart's ID. + region: + $ref: '#/components/schemas/BaseRegion' + region_id: + type: string + title: region_id + description: The cart's region id. customer_id: type: string title: customer_id - description: The billing address's customer id. - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: - type: string - title: last_name - description: The billing address's last name. - phone: - type: string - title: phone - description: The billing address's phone. - company: - type: string - title: company - description: The billing address's company. - address_1: - type: string - title: address_1 - description: The billing address's address 1. - address_2: - type: string - title: address_2 - description: The billing address's address 2. - city: - type: string - title: city - description: The billing address's city. - country_code: + description: The cart's customer id. + sales_channel_id: type: string - title: country_code - description: The billing address's country code. - province: + title: sales_channel_id + description: The cart's sales channel id. + email: type: string - title: province - description: The billing address's province. - postal_code: + title: email + description: The cart's email. + format: email + currency_code: type: string - title: postal_code - description: The billing address's postal code. + title: currency_code + description: The cart's currency code. + shipping_address: + $ref: '#/components/schemas/BaseCartAddress' + billing_address: + $ref: '#/components/schemas/BaseCartAddress' + items: + type: array + description: The cart's items. + items: + type: object + shipping_methods: + type: array + description: The cart's shipping methods. + items: + $ref: '#/components/schemas/BaseCartShippingMethod' + payment_collection: + $ref: '#/components/schemas/BasePaymentCollection' metadata: type: object - description: The billing address's metadata. + description: The cart's metadata. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The cart's created at. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. + description: The cart's updated at. + original_item_total: + type: number + title: original_item_total + description: The cart's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The cart's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The cart's original item tax total. + item_total: + type: number + title: item_total + description: The cart's item total. + item_subtotal: + type: number + title: item_subtotal + description: The cart's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The cart's item tax total. + original_total: + type: number + title: original_total + description: The cart's original total. + original_subtotal: + type: number + title: original_subtotal + description: The cart's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The cart's original tax total. + total: + type: number + title: total + description: The cart's total. + subtotal: + type: number + title: subtotal + description: The cart's subtotal. + tax_total: + type: number + title: tax_total + description: The cart's tax total. + discount_total: + type: number + title: discount_total + description: The cart's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The cart's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The cart's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The cart's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The cart's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The cart's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The cart's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The cart's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The cart's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The cart's original shipping tax total. + BaseCartAddress: + type: object + description: The cart's shipping address. + x-schemaName: BaseCartAddress BaseCartLineItem: type: object - description: The item's items. + description: The tax line's item. x-schemaName: BaseCartLineItem required: - id @@ -54708,17 +57512,9 @@ components: title: thumbnail description: The item's thumbnail. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: quantity + description: The item's quantity. product: $ref: '#/components/schemas/BaseProduct' product_id: @@ -54783,34 +57579,18 @@ components: title: is_tax_inclusive description: The item's is tax inclusive. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: compare_at_unit_price + description: The item's compare at unit price. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: unit_price + description: The item's unit price. tax_lines: type: array description: The item's tax lines. items: - $ref: '#/components/schemas/BaseLineItemTaxLine' + type: object adjustments: type: array description: The item's adjustments. @@ -54841,140 +57621,52 @@ components: title: deleted_at description: The item's deleted at. original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The item's original total. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The item's original subtotal. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The item's original tax total. item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_total + description: The item's item total. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_subtotal + description: The item's item subtotal. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_tax_total + description: The item's item tax total. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The item's total. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The item's subtotal. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The item's tax total. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The item's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_tax_total + description: The item's discount tax total. BaseCartShippingMethod: type: object - description: The shipping method's shipping methods. + description: A cart's shipping method. x-schemaName: BaseCartShippingMethod required: - id @@ -55000,7 +57692,7 @@ components: cart_id: type: string title: cart_id - description: The shipping method's cart id. + description: The ID of the cart this shipping method belongs to. name: type: string title: name @@ -55010,31 +57702,25 @@ components: title: description description: The shipping method's description. amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: amount + description: The shipping method's amount. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount is tax inclusive. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: The shipping method's data, useful for fulfillment handling by third-party services. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -55042,122 +57728,54 @@ components: $ref: '#/components/schemas/BaseShippingMethodTaxLine' adjustments: type: array - description: The shipping method's adjustments. + description: The shipping method's adjustments, such as applied promotions. items: $ref: '#/components/schemas/BaseShippingMethodAdjustment' created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The total taxes applied on the shipping method's amount including promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The shipping method's total amount including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The total taxes applied on the shipping method's amount including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The total amount discounted. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - BaseClaim: - type: object - description: The order change's claim. - x-schemaName: BaseClaim + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. BaseClaimItem: type: object - description: The claim item's claim items. + description: The claim item's details. x-schemaName: BaseClaimItem required: - id @@ -55175,22 +57793,22 @@ components: claim_id: type: string title: claim_id - description: The claim item's claim id. + description: The ID of the claim this item belongs to. order_id: type: string title: order_id - description: The claim item's order id. + description: The ID of the order this item belongs to. item_id: type: string title: item_id - description: The claim item's item id. + description: The ID of the item in the order. quantity: type: number title: quantity - description: The claim item's quantity. + description: The quantity claimed. reason: type: string - description: The claim item's reason. + description: The claim's reason. enum: - missing_item - wrong_item @@ -55198,23 +57816,34 @@ components: - other raw_quantity: type: object - description: The claim item's raw quantity. + description: The quantity claimed. + properties: + value: + oneOf: + - type: string + title: value + description: The raw quantity's value. + - type: number + title: value + description: The raw quantity's value. + required: + - value metadata: type: object - description: The claim item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The claim item's created at. + description: The date the claim was created. updated_at: type: string format: date-time title: updated_at - description: The claim item's updated at. + description: The date the claim was updated. BaseCollection: type: object - description: The product's collection. + description: The collection's details. x-schemaName: BaseCollection BaseCustomer: type: object @@ -55245,132 +57874,557 @@ components: description: The ID of the address used as the default billing address. default_shipping_address_id: type: string - title: default_shipping_address_id - description: The ID of the address used as the default shipping address. - company_name: + title: default_shipping_address_id + description: The ID of the address used as the default shipping address. + company_name: + type: string + title: company_name + description: The customer's company name. + first_name: + type: string + title: first_name + description: The customer's first name. + last_name: + type: string + title: last_name + description: The customer's last name. + addresses: + type: array + description: The customer's addresses. + items: + $ref: '#/components/schemas/BaseCustomerAddress' + phone: + type: string + title: phone + description: The customer's phone. + metadata: + type: object + description: The customer's metadata, used to store custom key-value pairs. + created_by: + type: string + title: created_by + description: The ID of the user that created this customer, if available. + created_at: + type: string + format: date-time + title: created_at + description: The customer's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The customer's update date. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The customer's deletion date. + BaseCustomerAddress: + type: object + description: The customer's address. + x-schemaName: BaseCustomerAddress + required: + - id + - address_name + - is_default_shipping + - is_default_billing + - customer_id + - company + - first_name + - last_name + - address_1 + - address_2 + - city + - country_code + - province + - postal_code + - phone + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The address's ID. + address_name: + type: string + title: address_name + description: The address's name. + is_default_shipping: + type: boolean + title: is_default_shipping + description: Whether the address is the default shipping address. + is_default_billing: + type: boolean + title: is_default_billing + description: Whether the address is the default billing address. + customer_id: + type: string + title: customer_id + description: The ID of the customer that this address belongs to. + company: + type: string + title: company + description: The customer's company. + first_name: + type: string + title: first_name + description: The customer's first name. + last_name: + type: string + title: last_name + description: The customer's last name. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + city: + type: string + title: city + description: The address's city. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + province: + type: string + title: province + description: The address's province. + postal_code: + type: string + title: postal_code + description: The address's postal code. + phone: + type: string + title: phone + description: The address's phone. + metadata: + type: object + description: The address's metadata, used to store custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The address's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The address's update date. + BaseExchangeItem: + type: object + description: The item's details. + x-schemaName: BaseExchangeItem + required: + - id + - exchange_id + - order_id + - item_id + - quantity + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The item's ID. + exchange_id: + type: string + title: exchange_id + description: The ID of the exchange this item belongs to. + order_id: + type: string + title: order_id + description: The ID of the order this item belongs to. + item_id: + type: string + title: item_id + description: The ID of the item in the order. + quantity: + type: number + title: quantity + description: The item's quantity. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + BaseLineItemAdjustment: + type: object + description: The adjustment's details. + x-schemaName: BaseLineItemAdjustment + properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: + type: string + title: cart_id + description: The ID of the cart this adjustment belongs to. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. + required: + - item + - item_id + - id + - amount + - cart_id + - created_at + - updated_at + BaseLineItemTaxLine: + type: object + description: The tax line's details + x-schemaName: BaseLineItemTaxLine + properties: + item: + $ref: '#/components/schemas/BaseCartLineItem' + item_id: + type: string + title: item_id + description: The ID of the item the tax line applies on. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + id: type: string - title: company_name - description: The customer's company name. - first_name: + title: id + description: The tax line's ID. + description: type: string - title: first_name - description: The customer's first name. - last_name: + title: description + description: The tax line's description. + tax_rate_id: type: string - title: last_name - description: The customer's last name. - addresses: - type: array - description: The customer's addresses. - items: - $ref: '#/components/schemas/BaseCustomerAddress' - phone: + title: tax_rate_id + description: The ID of the associated tax rate. + code: type: string - title: phone - description: The customer's phone. - metadata: - type: object - description: The customer's metadata, used to store custom key-value pairs. - created_by: + title: code + description: The code the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: type: string - title: created_by - description: The ID of the user that created this customer, if available. + title: provider_id + description: The ID of the tax provider. created_at: type: string format: date-time title: created_at - description: The customer's creation date. + description: The date the tax line was created. updated_at: type: string format: date-time title: updated_at - description: The customer's update date. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The customer's deletion date. - BaseCustomerAddress: - type: object - description: The address's addresses. - x-schemaName: BaseCustomerAddress - BaseExchangeItem: + description: The date the tax line was updated. + required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at + BaseOrder: type: object - description: The additional item's additional items. - x-schemaName: BaseExchangeItem + description: The order's details. + x-schemaName: BaseOrder required: + - payment_collections - id - - exchange_id - - order_id - - item_id - - quantity + - version + - region_id + - customer_id + - sales_channel_id + - email + - currency_code + - items + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata - created_at - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total properties: + payment_collections: + type: array + description: The order's payment collections. + items: + $ref: '#/components/schemas/AdminPaymentCollection' + fulfillments: + type: array + description: The order's fulfillments. + items: + $ref: '#/components/schemas/BaseOrderFulfillment' + sales_channel: + $ref: '#/components/schemas/AdminSalesChannel' + customer: + $ref: '#/components/schemas/AdminCustomer' + shipping_address: + $ref: '#/components/schemas/AdminOrderAddress' + billing_address: + $ref: '#/components/schemas/AdminOrderAddress' id: type: string title: id - description: The additional item's ID. - exchange_id: + description: The order's ID. + version: + type: number + title: version + description: The order's version. + region_id: type: string - title: exchange_id - description: The additional item's exchange id. - order_id: + title: region_id + description: The ID of the region associated with the order. + customer_id: type: string - title: order_id - description: The additional item's order id. - item_id: + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: type: string - title: item_id - description: The additional item's item id. - quantity: + title: sales_channel_id + description: The ID of the sales channel the order is placed in. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The order's currency code. + display_id: type: number - title: quantity - description: The additional item's quantity. + title: display_id + description: The order's display ID. + items: + type: array + description: The order's items. + items: + $ref: '#/components/schemas/BaseOrderLineItem' + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: '#/components/schemas/BaseOrderShippingMethod' + payment_status: + type: string + description: The order's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillment_status: + type: string + description: The order's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The order's transactions. + items: + $ref: '#/components/schemas/BaseOrderTransaction' + summary: + $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object - description: The additional item's metadata. + description: The order's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The additional item's created at. + description: The date the order was created. updated_at: type: string format: date-time title: updated_at - description: The additional item's updated at. - BaseFulfillmentProvider: - type: object - description: The shipping option's provider. - x-schemaName: BaseFulfillmentProvider - required: - - id - - is_enabled - properties: - id: - type: string - title: id - description: The provider's ID. - is_enabled: - type: boolean - title: is_enabled - description: The provider's is enabled. - BaseLineItemAdjustment: - type: object - description: The adjustment's adjustments. - x-schemaName: BaseLineItemAdjustment - BaseLineItemTaxLine: - type: object - description: The tax line's tax lines. - x-schemaName: BaseLineItemTaxLine - BaseOrder: - type: object - description: The order change's order. - x-schemaName: BaseOrder + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the order's items including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The total of the order's items excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the order's items excluding promotions. + item_total: + type: number + title: item_total + description: The total of the order's items including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The total of the order's items excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order's items including promotions. + original_total: + type: number + title: original_total + description: The order's total excluding promotions, including taxes. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The order's tax total, excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The order's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The order's discount or promotions total. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total of order's discount or promotion. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The tax total of the order's gift card. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The tax total of the order's shipping. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The tax total of the order's shipping excluding promotions. BaseOrderAddress: type: object - description: The exchange's billing address. + description: An order address x-schemaName: BaseOrderAddress required: - id @@ -55381,215 +58435,153 @@ components: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer this address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us + country: + $ref: '#/components/schemas/AdminRegionCountry' province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. - BaseOrderChange: + description: The date the address was updated. + BaseOrderChangeAction: type: object - description: The order preview's order change. - x-schemaName: BaseOrderChange - required: - - id - - order_id - - actions - - status - - requested_by - - requested_at - - confirmed_by - - confirmed_at - - declined_by - - declined_reason - - metadata - - declined_at - - canceled_by - - canceled_at - - created_at - - updated_at - - version - - return_id - - exchange_id - - claim_id - - order - - return_order - - exchange - - claim + description: The action's actions. + x-schemaName: BaseOrderChangeAction properties: + order_change: + $ref: '#/components/schemas/AdminOrderChange' id: type: string title: id - description: The order change's ID. + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change this action belongs to. order_id: type: string title: order_id - description: The order change's order id. - actions: - type: array - description: The order change's actions. - items: - $ref: '#/components/schemas/BaseOrderChangeAction' - status: - type: string - title: status - description: The order change's status. - requested_by: - type: string - title: requested_by - description: The order change's requested by. - requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time - confirmed_by: + description: The ID of the associated order. + reference: type: string - title: confirmed_by - description: The order change's confirmed by. - confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time - declined_by: + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: type: string - title: declined_by - description: The order change's declined by. - declined_reason: + title: reference_id + description: The ID of the record in the referenced table. + action: type: string - title: declined_reason - description: The order change's declined reason. - metadata: + title: action + description: The applied action. + details: type: object - description: The order change's metadata. - declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time - canceled_by: + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: type: string - title: canceled_by - description: The order change's canceled by. - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time + title: internal_note + description: A note viewed only by admin users. created_at: type: string format: date-time title: created_at - description: The order change's created at. + description: The date the order change action was created. updated_at: type: string format: date-time title: updated_at - description: The order change's updated at. - version: - type: number - title: version - description: The order change's version. - change_type: - type: string - description: The order change's change type. - enum: - - return - - exchange - - claim - - edit - - return_request + description: The date the order change action was updated. return_id: type: string title: return_id - description: The order change's return id. - exchange_id: - type: string - title: exchange_id - description: The order change's exchange id. + description: The ID of the associated return. claim_id: type: string title: claim_id - description: The order change's claim id. + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. order: $ref: '#/components/schemas/BaseOrder' - return_order: {} - exchange: {} - claim: - $ref: '#/components/schemas/BaseClaim' - BaseOrderChangeAction: - type: object - description: The action's actions. - x-schemaName: BaseOrderChangeAction + required: + - order_change + - id + - order_change_id + - order_id + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at + - return_id + - claim_id + - exchange_id + - order BaseOrderFulfillment: type: object description: The fulfillment's fulfillments. @@ -55615,55 +58607,129 @@ components: location_id: type: string title: location_id - description: The fulfillment's location id. + description: The ID of the location the items are fulfilled from. packed_at: type: string title: packed_at - description: The fulfillment's packed at. + description: The date the items were packed. format: date-time shipped_at: type: string title: shipped_at - description: The fulfillment's shipped at. + description: The date the items were shipped. format: date-time delivered_at: type: string title: delivered_at - description: The fulfillment's delivered at. + description: The date the items were delivered. format: date-time canceled_at: type: string title: canceled_at - description: The fulfillment's canceled at. + description: The date the items were canceled. format: date-time data: type: object - description: The fulfillment's data. + description: Data useful for the fulfillment provider handling it. This is taken from the associated shipping option. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property provider_id: type: string title: provider_id - description: The fulfillment's provider id. + description: The ID of the fulfillment provider used to handle the fulfillment. shipping_option_id: type: string title: shipping_option_id - description: The fulfillment's shipping option id. + description: The ID of the associated shipping option. metadata: type: object - description: The fulfillment's metadata. + description: The fulfillment's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The fulfillment's created at. + description: The date the fulfillment was created. updated_at: type: string format: date-time title: updated_at - description: The fulfillment's updated at. + description: The date the fulfillment was updated. BaseOrderItemDetail: type: object description: The item's detail. x-schemaName: BaseOrderItemDetail + required: + - id + - item_id + - item + - quantity + - fulfilled_quantity + - delivered_quantity + - shipped_quantity + - return_requested_quantity + - return_received_quantity + - return_dismissed_quantity + - written_off_quantity + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: the detail's ID. + item_id: + type: string + title: id + description: the ID of the associated line item. + item: + $ref: '#/components/schemas/BaseOrderLineItem' + quantity: + type: number + title: quantity + description: The item's quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + delivered_quantity: + type: number + title: fulfilled_quantity + description: The item's delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + return_received_quantity: + type: number + title: return_received_quantity + description: The item's quantity that's returned and added to the underlying variant's stocked quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: The item's quantity that's returned but damaged. So, it's not added to the underlying variant's stocked quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed from the order. + metadata: + type: object + title: metadata + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the detail was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the detail was updated. BaseOrderLineItem: type: object description: The item's items. @@ -55723,19 +58789,19 @@ components: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The URL of the item's thumbnail. variant: $ref: '#/components/schemas/BaseProductVariant' variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated variant. product: $ref: '#/components/schemas/BaseProduct' product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -55755,7 +58821,7 @@ components: product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the collection the item's product belongs to. product_handle: type: string title: product_handle @@ -55763,7 +58829,7 @@ components: variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -55774,23 +58840,25 @@ components: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The values of the item variant's options. + example: + Color: Blue requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item is tax inclusive. compare_at_unit_price: type: number title: compare_at_unit_price - description: The item's compare at unit price. + description: The original price of the item before a promotion or sale. unit_price: type: number title: unit_price @@ -55810,83 +58878,238 @@ components: items: $ref: '#/components/schemas/BaseOrderLineItemAdjustment' detail: - $ref: '#/components/schemas/BaseOrderItemDetail' + type: object created_at: type: string format: date-time title: created_at - description: The item's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The item's updated at. + description: The date the item was updated. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. original_total: type: number title: original_total - description: The item's original total. + description: The item's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The item's original subtotal. + description: The item's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The item's original tax total. + description: The total taxes of the item, excluding promotions. item_total: type: number title: item_total - description: The item's item total. + description: The total taxes of the item, including promotions. item_subtotal: type: number title: item_subtotal - description: The item's item subtotal. + description: The item's total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The item's item tax total. + description: The total taxes of the item, including promotions. total: type: number title: total - description: The item's total. + description: The item's total, including taxes and promotions. subtotal: type: number title: subtotal - description: The item's subtotal. + description: The item's subtotal excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The item's tax total. + description: The tax total of the item including promotions. discount_total: type: number title: discount_total - description: The item's discount total. + description: The total discount amount of the item. discount_tax_total: type: number title: discount_tax_total - description: The item's discount tax total. + description: The total taxes applied on the discounted amount. refundable_total: type: number title: refundable_total - description: The item's refundable total. + description: The total refundable amount of the item's total. refundable_total_per_unit: type: number title: refundable_total_per_unit - description: The item's refundable total per unit. + description: The total refundable amount of the item's total for a single quantity. BaseOrderLineItemAdjustment: type: object - description: The adjustment's adjustments. + description: The adjustment's details. x-schemaName: BaseOrderLineItemAdjustment + properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies to. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion that this applies on the order's item. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. + required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at BaseOrderLineItemTaxLine: type: object description: The tax line's tax lines. x-schemaName: BaseOrderLineItemTaxLine + properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the associated line item. + total: + type: number + title: total + description: The tax line's total including promotions. + subtotal: + type: number + title: subtotal + description: The tax line's subtotal excluding promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax line. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. + required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at + BaseOrderShippingDetail: + type: object + description: The shipping method's detail. + x-schemaName: BaseOrderShippingDetail + required: + - id + - shipping_method_id + - shipping_method + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The detail's ID. + shipping_method_id: + type: string + title: shipping_method_id + description: The detail's shipping method id. + shipping_method: + $ref: '#/components/schemas/BaseOrderShippingMethod' + claim_id: + type: string + title: claim_id + description: The detail's claim id. + exchange_id: + type: string + title: exchange_id + description: The detail's exchange id. + return_id: + type: string + title: return_id + description: The detail's return id. + created_at: + type: string + format: date-time + title: created_at + description: The detail's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The detail's updated at. BaseOrderShippingMethod: type: object - description: The shipping method's shipping methods. + description: The shipping method's details. x-schemaName: BaseOrderShippingMethod required: - id @@ -55915,7 +59138,7 @@ components: order_id: type: string title: order_id - description: The shipping method's order id. + description: The ID of the order the shipping method belongs to. name: type: string title: name @@ -55931,17 +59154,19 @@ components: is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount includes applied taxes. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: The shipping method's data, useful for fulfillment provider handling its fulfillment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -55953,122 +59178,172 @@ components: items: $ref: '#/components/schemas/BaseOrderShippingMethodAdjustment' original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The shipping method's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The shipping method's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The total discounts applied on the shipping method. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. + detail: + type: object BaseOrderShippingMethodAdjustment: type: object description: The adjustment's adjustments. x-schemaName: BaseOrderShippingMethodAdjustment + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment applies on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. + required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at BaseOrderShippingMethodTaxLine: type: object - description: The tax line's tax lines. + description: The tax line's details. x-schemaName: BaseOrderShippingMethodTaxLine + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this tax line belongs to. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider handling the tax calculation. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. + required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at BaseOrderSummary: type: object - description: The order's summary. + description: The order's summary details. x-schemaName: BaseOrderSummary required: - total @@ -56079,77 +59354,52 @@ components: - returned_total - return_request_total - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - paid_total - refunded_total properties: total: type: number title: total - description: The summary's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The summary's subtotal. + description: The order's total excluding taxes, including promotions. total_tax: type: number title: total_tax - description: The summary's total tax. + description: The order's total taxes. ordered_total: type: number title: ordered_total - description: The summary's ordered total. + description: The order's total when it was placed. fulfilled_total: type: number title: fulfilled_total - description: The summary's fulfilled total. + description: The total of the fulfilled items of the order. returned_total: type: number title: returned_total - description: The summary's returned total. + description: The total of the order's returned items. return_request_total: type: number title: return_request_total - description: The summary's return request total. + description: The total of the items requested to be returned. write_off_total: type: number title: write_off_total - description: The summary's write off total. - projected_total: - type: number - title: projected_total - description: The summary's projected total. - net_total: - type: number - title: net_total - description: The summary's net total. - net_subtotal: - type: number - title: net_subtotal - description: The summary's net subtotal. - net_total_tax: - type: number - title: net_total_tax - description: The summary's net total tax. - balance: - type: number - title: balance - description: The summary's balance. + description: The total of the items removed from the order. paid_total: type: number title: paid_total - description: The summary's paid total. + description: The total amount paid. refunded_total: type: number title: refunded_total - description: The summary's refunded total. + description: The total amount refunded. BaseOrderTransaction: type: object - description: The transaction's transactions. + description: An order transaction's details. x-schemaName: BaseOrderTransaction required: - id @@ -56169,7 +59419,7 @@ components: order_id: type: string title: order_id - description: The transaction's order id. + description: The ID of the order this transaction belongs to. amount: type: number title: amount @@ -56178,34 +59428,127 @@ components: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: The name of a table that this transaction references. If this transaction is for captured payment, its value is `capture`. If this transaction is for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. metadata: type: object - description: The transaction's metadata. + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. + description: The date that the transaction was updated. BasePayment: type: object - description: The payment's payments. + description: The payment's details. x-schemaName: BasePayment + required: + - id + - amount + - currency_code + - provider_id + properties: + id: + type: string + title: id + description: The payment's ID. + amount: + type: number + title: amount + description: The payment's amount. + authorized_amount: + type: number + title: authorized_amount + description: The amount authorized of the payment. + currency_code: + type: string + title: currency_code + description: The payment's currency code. + provider_id: + type: string + title: provider_id + description: The ID of the payment provider used to process this payment. + cart_id: + type: string + title: cart_id + description: The ID of the associated cart. + order_id: + type: string + title: order_id + description: The ID of the associated order. + order_edit_id: + type: string + title: order_edit_id + description: The ID of the associated order edit. + customer_id: + type: string + title: customer_id + description: ID of the associated customer. + data: + type: object + description: The payment's data, useful for processing by the payment provider. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment#whats-a-payment + created_at: + type: string + format: date-time + title: created_at + description: The date the payment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the payment was updated. + captured_at: + type: string + format: date-time + title: captured_at + description: The date the payment was captured. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the payment was canceled. + captured_amount: + type: number + title: captured_amount + description: The captured amount of the payment. + refunded_amount: + type: number + title: captured_amount + description: The refunded amount of the payment. + captures: + type: array + description: The details of payment captures. + items: + $ref: '#/components/schemas/BaseCapture' + refunds: + type: array + description: The details of payment refunds. + items: + $ref: '#/components/schemas/BaseRefund' + payment_collection: + type: object + payment_session: + type: object BasePaymentCollection: type: object - description: The payment collection's payment collections. + description: The payment collection's details. x-schemaName: BasePaymentCollection required: - id @@ -56226,77 +59569,41 @@ components: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -56308,7 +59615,7 @@ components: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: The payment provider used to process the collection's payments and sessions. items: $ref: '#/components/schemas/BasePaymentProvider' payment_sessions: @@ -56325,10 +59632,72 @@ components: type: object description: The payment provider's payment providers. x-schemaName: BasePaymentProvider + required: + - id + properties: + id: + type: string + title: id + description: The payment provider's ID. BasePaymentSession: type: object - description: The payment session's payment sessions. + description: The payment session's details. x-schemaName: BasePaymentSession + properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: The payment session's data, useful for the payment provider processing the payment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: '#/components/schemas/BasePayment' + required: + - id + - amount + - currency_code + - provider_id + - data + - status BaseProduct: type: object description: The parent's product. @@ -56498,60 +59867,220 @@ components: x-schemaName: BaseProductCategory BaseProductImage: type: object - description: The image's images. + description: The image's details. x-schemaName: BaseProductImage + properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's URL. + created_at: + type: string + format: date-time + title: created_at + description: The date the image was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. + required: + - id + - url BaseProductOption: type: object - description: The option's options. + description: The product option's details. x-schemaName: BaseProductOption + properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + type: object + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: '#/components/schemas/BaseProductOptionValue' + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. + required: + - id + - title BaseProductOptionValue: type: object - description: The option's options. - x-schemaName: BaseProductOptionValue + description: The product option value's details. + x-schemaName: BaseProductOptionValue + BaseProductTag: + type: object + description: The tag's tags. + x-schemaName: BaseProductTag + BaseProductVariant: + type: object + description: The product variant's details. + x-schemaName: BaseProductVariant required: - id - - value + - title + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory + - hs_code + - origin_country + - mid_code + - material + - weight + - length + - height + - width + - options + - created_at + - updated_at + - deleted_at properties: id: type: string title: id - description: The option's ID. - value: + description: The variant's ID. + title: type: string - title: value - description: The option's value. - option: - $ref: '#/components/schemas/BaseProductOption' - option_id: + title: title + description: The variant's title. + sku: type: string - title: option_id - description: The option's option id. - metadata: + title: sku + description: The variant's SKU. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's EAN code. + upc: + type: string + title: upc + description: The variant's UPC. + allow_backorder: + type: boolean + title: allow_backorder + description: Whether the variant can be ordered even if it's out of stock. + manage_inventory: + type: boolean + title: manage_inventory + description: Whether the Medusa application manages the variant's inventory quantity and availablility. If disabled, the variant is always considered in stock. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. This is only included if you pass in the `fields` query parameter a `+variants.inventory_quantity` parameter. + hs_code: + type: string + title: hs_code + description: The variant's HS code. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + mid_code: + type: string + title: mid_code + description: The variant's MID code. + material: + type: string + title: material + description: The variant's material. + weight: + type: number + title: weight + description: The variant's weight. + length: + type: number + title: length + description: The variant's length. + height: + type: number + title: height + description: The variant's height. + width: + type: number + title: width + description: The variant's width. + variant_rank: + type: number + title: variant_rank + description: The variant's rank among its sibling variants. + options: + type: array + description: The variant's option values. + items: + $ref: '#/components/schemas/BaseProductOptionValue' + product: type: object - description: The option's metadata. + product_id: + type: string + title: product_id + description: The ID of the product that the variant belongs to. + calculated_price: + $ref: '#/components/schemas/BaseCalculatedPriceSet' created_at: type: string format: date-time title: created_at - description: The option's created at. + description: The date the variant was created. updated_at: type: string format: date-time title: updated_at - description: The option's updated at. + description: The date the variant was updated. deleted_at: type: string format: date-time title: deleted_at - description: The option's deleted at. - BaseProductTag: - type: object - description: The tag's tags. - x-schemaName: BaseProductTag - BaseProductVariant: - type: object - description: The variant's variants. - x-schemaName: BaseProductVariant + description: The date the variant was deleted. + metadata: + type: object + description: The variant's metadata, can hold custom key-value pairs. BasePromotion: type: object description: The application method's promotion. @@ -56609,67 +60138,84 @@ components: description: The value's details. BaseRefund: type: object - description: The refund's refunds. + description: The refund's details. x-schemaName: BaseRefund - BaseRegion: - type: object - description: The parent's region. - x-schemaName: BaseRegion required: - id - - name - - currency_code + - amount + - created_at + - payment properties: id: type: string title: id - description: The region's ID. - name: + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: type: string - title: name - description: The region's name. - currency_code: + title: refund_reason_id + description: The ID of the refund reason. + note: type: string - title: currency_code - description: The region's currency code. - automatic_taxes: - type: boolean - title: automatic_taxes - description: The region's automatic taxes. - countries: - type: array - description: The region's countries. - items: - $ref: '#/components/schemas/BaseRegionCountry' - payment_providers: - type: array - description: The region's payment providers. - items: - $ref: '#/components/schemas/AdminPaymentProvider' - metadata: - type: object - description: The region's metadata. + title: note + description: More details about the refund. created_at: type: string format: date-time title: created_at - description: The region's created at. - updated_at: + description: The date the refund was created. + created_by: type: string - format: date-time - title: updated_at - description: The region's updated at. + title: created_by + description: The ID of the user that created the refund. + payment: + type: object + refund_reason: + $ref: '#/components/schemas/RefundReason' + BaseRegion: + type: object + description: The parent's region. + x-schemaName: BaseRegion BaseRegionCountry: type: object - description: The country's countries. + description: The country's details. x-schemaName: BaseRegionCountry - BaseReturnItem: - type: object - description: The item's items. - x-schemaName: BaseReturnItem + properties: + id: + type: string + title: id + description: The country's ID. + iso_2: + type: string + title: iso_2 + description: The country's iso 2. + example: us + iso_3: + type: string + title: iso_3 + description: The country's iso 3. + example: usa + num_code: + type: string + title: num_code + description: The country's num code. + example: 840 + name: + type: string + title: name + description: The country's name. + display_name: + type: string + title: display_name + description: The country's display name. + required: + - id BaseRuleOperatorOptions: type: object - description: The operator's operators. + description: The operator's details. x-schemaName: BaseRuleOperatorOptions required: - id @@ -56680,22 +60226,137 @@ components: type: string title: id description: The operator's ID. + example: in value: type: string title: value description: The operator's value. + example: in label: type: string title: label description: The operator's label. + example: In BaseShippingMethodAdjustment: type: object - description: The adjustment's adjustments. + description: The adjustment's details. x-schemaName: BaseShippingMethodAdjustment + required: + - shipping_method + - shipping_method_id + - id + - amount + - cart_id + - created_at + - updated_at + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method the adjustment is applied on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: + type: string + title: cart_id + description: The ID of the associated cart. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. BaseShippingMethodTaxLine: type: object - description: The tax line's tax lines. + description: The tax line's details. x-schemaName: BaseShippingMethodTaxLine + required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of this shipping method the tax line belongs to. + total: + type: number + title: total + description: The method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The method's total excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider that calculated the taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. CampaignResponse: type: object description: The campaign's details. @@ -56771,293 +60432,60 @@ components: description: The budget's used. CreateAddress: type: object - description: The cart's shipping address. + description: The address to create. x-schemaName: CreateAddress properties: customer_id: type: string title: customer_id - description: The shipping address's customer id. + description: The ID of the customer this address belongs to. company: type: string title: company - description: The shipping address's company. + description: The address's company. first_name: type: string title: first_name - description: The shipping address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The shipping address's last name. + description: The address's last name. address_1: type: string title: address_1 - description: The shipping address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The shipping address's address 2. + description: The address's second line. city: type: string title: city - description: The shipping address's city. + description: The address's city. country_code: type: string title: country_code - description: The shipping address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The shipping address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The shipping address's postal code. - phone: - type: string - title: phone - description: The shipping address's phone. - metadata: - type: object - description: The shipping address's metadata. - CreateCartAddress: - type: object - description: The cart's billing address. - x-schemaName: CreateCartAddress - properties: - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: - type: string - title: last_name - description: The billing address's last name. + description: The address's postal code. phone: type: string title: phone - description: The billing address's phone. - company: - type: string - title: company - description: The billing address's company. - address_1: - type: string - title: address_1 - description: The billing address's address 1. - address_2: - type: string - title: address_2 - description: The billing address's address 2. - city: - type: string - title: city - description: The billing address's city. - country_code: - type: string - title: country_code - description: The billing address's country code. - province: - type: string - title: province - description: The billing address's province. - postal_code: - type: string - title: postal_code - description: The billing address's postal code. - metadata: - type: object - description: The billing address's metadata. - CreateCartCreateLineItem: - type: object - description: The item's items. - x-schemaName: CreateCartCreateLineItem - required: - - quantity - - variant_id - properties: - quantity: - type: string - title: quantity - description: The item's quantity. - variant_id: - type: string - title: variant_id - description: The item's variant id. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The item's thumbnail. - product_id: - type: string - title: product_id - description: The item's product id. - product_title: - type: string - title: product_title - description: The item's product title. - product_description: - type: string - title: product_description - description: The item's product description. - product_subtitle: - type: string - title: product_subtitle - description: The item's product subtitle. - product_type: - type: string - title: product_type - description: The item's product type. - product_collection: - type: string - title: product_collection - description: The item's product collection. - product_handle: - type: string - title: product_handle - description: The item's product handle. - variant_sku: - type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: - type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: - type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - is_giftcard: - type: boolean - title: is_giftcard - description: The item's is giftcard. - compare_at_unit_price: - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - unit_price: - type: string - title: unit_price - description: The item's unit price. - metadata: - type: object - description: The item's metadata. - CreateCartWorkflowInput: - type: object - description: SUMMARY - x-schemaName: CreateCartWorkflowInput - properties: - region_id: - type: string - title: region_id - description: The cart's region id. - customer_id: - type: string - title: customer_id - description: The cart's customer id. - sales_channel_id: - type: string - title: sales_channel_id - description: The cart's sales channel id. - email: - type: string - title: email - description: The cart's email. - format: email - currency_code: - type: string - title: currency_code - description: The cart's currency code. - shipping_address_id: - type: string - title: shipping_address_id - description: The cart's shipping address id. - billing_address_id: - type: string - title: billing_address_id - description: The cart's billing address id. - shipping_address: - oneOf: - - type: string - title: shipping_address - description: The cart's shipping address. - - $ref: '#/components/schemas/CreateCartAddress' - billing_address: - oneOf: - - type: string - title: billing_address - description: The cart's billing address. - - $ref: '#/components/schemas/CreateCartAddress' - metadata: - type: object - description: The cart's metadata. - items: - type: array - description: The cart's items. - items: - $ref: '#/components/schemas/CreateCartCreateLineItem' - promo_codes: - type: array - description: The cart's promo codes. - items: - type: string - title: promo_codes - description: The promo code's promo codes. - CreateOrderReturnReason: - type: object - description: SUMMARY - x-schemaName: CreateOrderReturnReason - required: - - value - - label - properties: - value: - type: string - title: value - description: The return reason's value. - label: - type: string - title: label - description: The return reason's label. - description: - type: string - title: description - description: The return reason's description. - parent_return_reason_id: - type: string - title: parent_return_reason_id - description: The return reason's parent return reason id. + description: The address's phone. metadata: type: object - description: The return reason's metadata. + description: The address's metadata, can hold custom key-value pairs. CustomerGroupInCustomerFilters: type: object - description: The customer's groups. + description: Filter by customer groups to get their associated customers. x-schemaName: CustomerGroupInCustomerFilters required: - id @@ -57070,27 +60498,142 @@ components: oneOf: - type: string title: id - description: The group's ID. + description: Filter by a group's ID. + - type: array + description: Filter by group IDs. + items: + type: string + title: id + description: A group's ID. + name: + oneOf: + - type: string + title: name + description: Filter by a group's name. - type: array - description: The group's ID. + description: Filter by group names. + items: + type: string + title: name + description: A group's name. + created_at: + type: object + description: Filter by the group's creation date. + properties: + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by exact matches. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. items: type: string - title: id - description: The id's ID. - name: - oneOf: - - type: string - title: name - description: The group's name. - - type: array - description: The group's name. + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. items: type: string - title: name - description: The name's details. - created_at: + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + - type: object + description: Filter by values not matching the conditions in this parameter. + - type: array + description: Filter by values not matching the conditions in this parameter. + items: + type: string + title: $not + description: Filter by values not matching the conditions in this parameter. + $gt: + type: string + title: $gt + description: Filter by values greater than this parameter. Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: Filter by values less than this parameter. Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: Apply a case-insensitive `like` filter. Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: Filter arrays that have overlapping values with this parameter. + items: + type: string + title: $overlap + description: Filter arrays that have overlapping values with this parameter. + $contains: + type: array + description: Filter arrays that contain some of the values of this parameter. + items: + type: string + title: $contains + description: Filter arrays that contain some of the values of this parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: Filter by whether a value for this parameter exists (not `null`). + updated_at: type: object - description: The group's created at. + description: Filter by the group's update date. properties: $and: type: array @@ -57110,7 +60653,7 @@ components: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -57203,9 +60746,9 @@ components: type: boolean title: $exists description: Filter by whether a value for this parameter exists (not `null`). - updated_at: + deleted_at: type: object - description: The group's updated at. + description: Filter by the group's deletion date. properties: $and: type: array @@ -57225,7 +60768,7 @@ components: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -57318,1760 +60861,1573 @@ components: type: boolean title: $exists description: Filter by whether a value for this parameter exists (not `null`). - deleted_at: + Error: + title: Response Error + type: object + properties: + code: + type: string + description: A slug code to indicate the type of the error. + enum: + - invalid_state_error + - invalid_request_error + - api_error + - unknown_error + message: + type: string + description: Description of the error that occurred. + example: first_name must be a string + type: + type: string + description: A slug indicating the type of the error. + enum: + - QueryRunnerAlreadyReleasedError + - TransactionAlreadyStartedError + - TransactionNotStartedError + - conflict + - unauthorized + - payment_authorization_error + - duplicate_error + - not_allowed + - invalid_data + - not_found + - database_error + - unexpected_state + - invalid_argument + - unknown_error + IBigNumber: + type: object + description: The shipping method's discount tax total. + x-schemaName: IBigNumber + InventoryLevel: + type: object + description: The inventory level's details + x-schemaName: InventoryLevel + required: + - id + - inventory_item_id + - location_id + - stocked_quantity + - reserved_quantity + - available_quantity + - incoming_quantity + properties: + id: + type: string + title: id + description: The inventory level's ID. + inventory_item_id: + type: string + title: inventory_item_id + description: The ID of the associated inventory item. + location_id: + type: string + title: location_id + description: The ID of the associated location. + stocked_quantity: + type: number + title: stocked_quantity + description: The inventory level's stocked quantity. + reserved_quantity: + type: number + title: reserved_quantity + description: The inventory level's reserved quantity. + available_quantity: + type: number + title: available_quantity + description: The inventory level's available quantity. + incoming_quantity: + type: number + title: incoming_quantity + description: The inventory level's incoming quantity. + metadata: + type: object + description: The inventory level's metadata, can hold custom key-value pairs. + Order: + type: object + description: The order change's order. + x-schemaName: Order + required: + - id + - version + - status + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_subtotal + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total + properties: + id: + type: string + title: id + description: The order's ID. + version: + type: number + title: version + description: The order's version. + order_change: + $ref: '#/components/schemas/OrderChange' + status: + type: string + description: The order's status. + enum: + - canceled + - requires_action + - pending + - completed + - draft + - archived + region_id: + type: string + title: region_id + description: The ID of the region the order belongs to. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the order was placed in. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The order's currency code. + example: usd + shipping_address: + $ref: '#/components/schemas/OrderAddress' + billing_address: + $ref: '#/components/schemas/OrderAddress' + items: + type: array + description: The order's items. + items: + $ref: '#/components/schemas/OrderLineItem' + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: '#/components/schemas/OrderShippingMethod' + transactions: + type: array + description: The order's transactions. + items: + $ref: '#/components/schemas/OrderTransaction' + summary: + type: object + description: The order's summary. + metadata: + type: object + description: The order's metadata, can hold custom key-value pairs. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the order was canceled. + created_at: + type: string + format: date-time + title: created_at + description: The date the order was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The order items' total including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The order items' total excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The taxes total for order items, excluding promotions. + item_total: + type: number + title: item_total + description: The order items' total including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The order items' total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order items including promotions. + original_total: + type: number + title: original_total + description: The order's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the order including promotions. + discount_subtotal: + type: number + title: discount_subtotal + description: The total discount excluding taxes. + discount_total: + type: number + title: discount_total + description: The total discount including taxes. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total applied on the discount. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The order's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The total taxes of the order's shipping including taxes. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The total taxes of the order's shipping excluding promotions. + raw_original_item_total: + type: object + description: The order's raw original item total. + raw_original_item_subtotal: + type: object + description: The order's raw original item subtotal. + raw_original_item_tax_total: + type: object + description: The order's raw original item tax total. + raw_item_total: + type: object + description: The order's raw item total. + raw_item_subtotal: + type: object + description: The order's raw item subtotal. + raw_item_tax_total: + type: object + description: The order's raw item tax total. + raw_original_total: + type: object + description: The order's raw original total. + raw_original_subtotal: + type: object + description: The order's raw original subtotal. + raw_original_tax_total: + type: object + description: The order's raw original tax total. + raw_total: + type: object + description: The order's raw total. + raw_subtotal: + type: object + description: The order's raw subtotal. + raw_tax_total: + type: object + description: The order's raw tax total. + raw_discount_total: + type: object + description: The order's raw discount total. + raw_discount_tax_total: + type: object + description: The order's raw discount tax total. + raw_gift_card_total: + type: object + description: The order's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The order's raw gift card tax total. + raw_shipping_total: + type: object + description: The order's raw shipping total. + raw_shipping_subtotal: + type: object + description: The order's raw shipping subtotal. + raw_shipping_tax_total: + type: object + description: The order's raw shipping tax total. + raw_original_shipping_total: + type: object + description: The order's raw original shipping total. + raw_original_shipping_subtotal: + type: object + description: The order's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The order's raw original shipping tax total. + OrderAddress: + type: object + description: The address's details. + x-schemaName: OrderAddress + required: + - id + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The address's ID. + customer_id: + type: string + title: customer_id + description: The ID of the customer the address belongs to. + first_name: + type: string + title: first_name + description: The address's first name. + last_name: + type: string + title: last_name + description: The address's last name. + phone: + type: string + title: phone + description: The address's phone. + company: + type: string + title: company + description: The address's company. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + city: + type: string + title: city + description: The address's city. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + province: + type: string + title: province + description: The address's province. + postal_code: + type: string + title: postal_code + description: The address's postal code. + metadata: + type: object + description: The address's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the address was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the address was updated. + OrderChange: + type: object + description: The order change's details. + x-schemaName: OrderChange + required: + - id + - version + - order_id + - return_id + - exchange_id + - claim_id + - order + - return_order + - exchange + - claim + - actions + - status + - requested_by + - requested_at + - confirmed_by + - confirmed_at + - declined_by + - declined_reason + - metadata + - declined_at + - canceled_by + - canceled_at + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The order change's ID. + version: + type: number + title: version + description: The order change's version. This will be the order's version when the change is applied. + change_type: + type: string + description: The order change's type. + enum: + - return + - exchange + - claim + - edit + order_id: + type: string + title: order_id + description: The ID of the order this change applies on. + return_id: + type: string + title: return_id + description: The ID of the associated return. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + order: type: object - description: The group's deleted at. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - Error: - title: Response Error + return_order: + $ref: '#/components/schemas/Return' + exchange: + $ref: '#/components/schemas/OrderExchange' + claim: + $ref: '#/components/schemas/OrderClaim' + actions: + type: array + description: The order change's actions. + items: + $ref: '#/components/schemas/OrderChangeAction' + status: + type: string + description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined + requested_by: + type: string + title: requested_by + description: The ID of the user that requested the change. + requested_at: + type: string + title: requested_at + description: The date the order change was requested. + format: date-time + confirmed_by: + type: string + title: confirmed_by + description: The ID of the user that confirmed the order change. + confirmed_at: + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time + declined_by: + type: string + title: declined_by + description: The ID of the user that declined the order change. + declined_reason: + type: string + title: declined_reason + description: The reason the order change was declined. + metadata: + type: object + description: The order change's metadata, can hold custom key-value pairs. + declined_at: + type: string + title: declined_at + description: The date the order change was declined. + format: date-time + canceled_by: + type: string + title: canceled_by + description: The ID of the user that canceled the order change. + canceled_at: + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time + created_at: + type: string + format: date-time + title: created_at + description: The date the order change was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change was updated. + OrderChangeAction: type: object + description: The order change action's details. + x-schemaName: OrderChangeAction + required: + - id + - order_change_id + - order_change + - order_id + - return_id + - claim_id + - exchange_id + - order + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at properties: - code: + id: type: string - description: A slug code to indicate the type of the error. + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change that the action belongs to. + order_change: + type: object + order_id: + type: string + title: order_id + description: The ID of the order the associated change is for. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + type: object + reference: + type: string + title: reference + description: The name of the table this action applies on. enum: - - invalid_state_error - - invalid_request_error - - api_error - - unknown_error - message: + - claim + - exchange + - return + - order_shipping_method + reference_id: type: string - description: Description of the error that occurred. - example: first_name must be a string - type: + title: reference_id + description: The ID of the record in the referenced table. + action: type: string - description: A slug indicating the type of the error. + description: The applied action. enum: - - QueryRunnerAlreadyReleasedError - - TransactionAlreadyStartedError - - TransactionNotStartedError - - conflict - - unauthorized - - payment_authorization_error - - duplicate_error - - not_allowed - - invalid_data - - not_found - - database_error - - unexpected_state - - invalid_argument - - unknown_error - File: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the action was updated. + OrderClaim: type: object - description: The product's file. - x-schemaName: File + description: The order change's claim. + x-schemaName: OrderClaim required: - - lastModified - - name - - webkitRelativePath - - size - - type - - arrayBuffer - - stream - - text + - order_id + - claim_items + - additional_items + - currency_code + - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total properties: - lastModified: + id: + type: string + title: id + description: The claim's ID. + order_id: + type: string + title: order_id + description: The ID of the order associated with the claim. + claim_items: + type: array + description: The order items targetted by the claim. + items: + $ref: '#/components/schemas/BaseClaimItem' + additional_items: + type: array + description: The outbound or new items of the claim. + items: + $ref: '#/components/schemas/BaseClaimItem' + return: + $ref: '#/components/schemas/Return' + return_id: + type: string + title: return_id + description: The ID of the associated return. + no_notification: + type: boolean + title: no_notification + description: Whether the customer should be notified about changes in the claim. + refund_amount: + type: number + title: refund_amount + description: The amount to be refunded. + currency_code: + type: string + title: currency_code + description: The claim's currency code. + region_id: + type: string + title: region_id + description: The ID of the region associated with the claim. + customer_id: + type: string + title: customer_id + description: The ID of the customer associated with the claim's order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the claim's order is created in. + email: + type: string + title: email + description: The email associated with the claim's order. + format: email + display_id: + type: number + title: display_id + description: The claim's display ID. + shipping_address: + $ref: '#/components/schemas/BaseOrderAddress' + billing_address: + $ref: '#/components/schemas/BaseOrderAddress' + shipping_methods: + type: array + description: The claim's shipping methods. + items: + $ref: '#/components/schemas/BaseOrderShippingMethod' + payment_collections: + type: array + description: The claim's payment collections. + items: + $ref: '#/components/schemas/BasePaymentCollection' + payment_status: + type: string + description: The claim's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The claim's fulfillments. + items: + $ref: '#/components/schemas/BaseOrderFulfillment' + fulfillment_status: + type: string + description: The claim's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The claim's transactions. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + description: Learn more about transactions of orders and associated models. + items: + $ref: '#/components/schemas/BaseOrderTransaction' + summary: + $ref: '#/components/schemas/BaseOrderSummary' + metadata: + type: object + description: The claim's metadata, used to store custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The claim's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The claim's update date. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the associated order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the associated order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the original items in the associated order. + item_total: + type: number + title: item_total + description: The total of the claim's items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the claim's items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the claim's items. + original_total: + type: number + title: original_total + description: The associated order's original total. + original_subtotal: + type: number + title: original_subtotal + description: The associated order's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The associated order's original tax total. + total: + type: number + title: total + description: The associated order's total. + subtotal: + type: number + title: subtotal + description: The claim's subtotal. + tax_total: + type: number + title: tax_total + description: The claim's tax total. + discount_total: type: number - title: lastModified - description: The file's lastmodified. - name: - type: string - title: name - description: The file's name. - webkitRelativePath: - type: string - title: webkitRelativePath - description: The file's webkitrelativepath. - size: + title: discount_total + description: The claim's discount total. + discount_tax_total: type: number - title: size - description: The file's size. - type: - type: string - title: type - description: The file's type. - arrayBuffer: - type: object - description: The file's arraybuffer. - slice: - type: object - description: The file's slice. - stream: - type: object - description: The file's stream. - text: - type: object - description: The file's text. - FileList: - type: object - description: SUMMARY - x-schemaName: FileList - required: - - length - - item - - __@iterator@258 - properties: - length: + title: discount_tax_total + description: The claim's discount tax total. + gift_card_total: type: number - title: length - description: The upload's length. - item: - type: object - description: The upload's item. - __@iterator@258: - type: object - description: The upload's @iterator@258. - IBigNumber: - type: object - description: The shipping method's discount tax total. - x-schemaName: IBigNumber - InventoryLevel: - type: object - description: The inventory level's inventory levels. - x-schemaName: InventoryLevel - required: - - id - - inventory_item_id - - location_id - - stocked_quantity - - reserved_quantity - - available_quantity - - incoming_quantity - properties: - id: - type: string - title: id - description: The inventory level's ID. - inventory_item_id: - type: string - title: inventory_item_id - description: The inventory level's inventory item id. - location_id: - type: string - title: location_id - description: The inventory level's location id. - stocked_quantity: + title: gift_card_total + description: The claim's gift card total. + gift_card_tax_total: type: number - title: stocked_quantity - description: The inventory level's stocked quantity. - reserved_quantity: + title: gift_card_tax_total + description: The claim's gift card tax total. + shipping_total: type: number - title: reserved_quantity - description: The inventory level's reserved quantity. - available_quantity: + title: shipping_total + description: The claim's shipping total. + shipping_subtotal: type: number - title: available_quantity - description: The inventory level's available quantity. - incoming_quantity: + title: shipping_subtotal + description: The claim's shipping subtotal. + shipping_tax_total: type: number - title: incoming_quantity - description: The inventory level's incoming quantity. - metadata: - type: object - description: The inventory level's metadata. - Order: - type: object - description: The transaction's order. - x-schemaName: Order - OrderAddress: + title: shipping_tax_total + description: The claim's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The associated order's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The associated order's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The associated order's original shipping tax total. + OrderExchange: type: object - description: The order preview's billing address. - x-schemaName: OrderAddress + description: The order change's exchange. + x-schemaName: OrderExchange required: + - order_id + - return_items + - additional_items + - currency_code - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata - created_at - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total properties: - id: - type: string - title: id - description: The billing address's ID. - customer_id: - type: string - title: customer_id - description: The billing address's customer id. - first_name: + order_id: type: string - title: first_name - description: The billing address's first name. - last_name: + title: order_id + description: The ID of the order the exchange is created for. + return_items: + type: array + description: The items returned (inbound) by the exchange. + items: + $ref: '#/components/schemas/AdminReturnItem' + additional_items: + type: array + description: The new items (outbound) sent by the exchange. + items: + $ref: '#/components/schemas/BaseExchangeItem' + no_notification: + type: boolean + title: no_notification + description: Whether to send the customer notifications when the exchange is updated. + difference_due: + type: number + title: difference_due + description: The amount to be exchanged or refunded. If the amount is negative, it must be refunded. If positive, additional payment is required from the customer. + return: + description: the return associated with the exchange. + $ref: '#/components/schemas/AdminReturn' + return_id: type: string - title: last_name - description: The billing address's last name. - phone: + title: return_id + description: The ID of the associated exchange. + currency_code: type: string - title: phone - description: The billing address's phone. - company: + title: currency_code + description: The exchange's currency code. + id: type: string - title: company - description: The billing address's company. - address_1: + title: id + description: The exchange's ID. + region_id: type: string - title: address_1 - description: The billing address's address 1. - address_2: + title: region_id + description: The ID of the associated order's region. + customer_id: type: string - title: address_2 - description: The billing address's address 2. - city: + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: type: string - title: city - description: The billing address's city. - country_code: + title: sales_channel_id + description: The ID of the sales channel the associated order belongs to. + email: type: string - title: country_code - description: The billing address's country code. - province: + title: email + description: The email used when placing the order. + format: email + display_id: + type: number + title: display_id + description: The exchange's display ID. + shipping_address: + description: The shipping address to send new items to. + $ref: '#/components/schemas/BaseOrderAddress' + billing_address: + description: The customer's billing address. + $ref: '#/components/schemas/BaseOrderAddress' + shipping_methods: + type: array + description: The shipping methods used to send the new (outbound) items. + items: + $ref: '#/components/schemas/BaseOrderShippingMethod' + payment_collections: + type: array + description: The exchange's payment collections. + items: + $ref: '#/components/schemas/BasePaymentCollection' + payment_status: type: string - title: province - description: The billing address's province. - postal_code: + description: The exchange's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The exchange's fulfillments of new (outbound) items. + items: + $ref: '#/components/schemas/BaseOrderFulfillment' + fulfillment_status: type: string - title: postal_code - description: The billing address's postal code. + description: The exchange's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The exchange's transactions. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + items: + $ref: '#/components/schemas/BaseOrderTransaction' + summary: + description: The totals summary of the exchange. + $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object - description: The billing address's metadata. + description: The exchange's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date that the exchange was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. - OrderChange: + description: The date that the exchange was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The total tax of the original items in the order. + item_total: + type: number + title: item_total + description: The total of the exchange's new items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the exchange's new items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the exchange's new items. + original_total: + type: number + title: original_total + description: The total of the order. + original_subtotal: + type: number + title: original_subtotal + description: The subtotal of the order. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order. + total: + type: number + title: total + description: The total of the exchange. + subtotal: + type: number + title: subtotal + description: The subtotal of the exchange. + tax_total: + type: number + title: tax_total + description: The tax total of the exchange. + discount_total: + type: number + title: discount_total + description: The discount total of the exchange. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes on discount of the exchange. + gift_card_total: + type: number + title: gift_card_total + description: The gift cards total of the exchange. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The total taxes on the gift card of the exchange. + shipping_total: + type: number + title: shipping_total + description: The exchange's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The exchange's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The exchange's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The order's shipping tax total. + OrderItem: type: object - description: The order preview's order change. - x-schemaName: OrderChange + description: The order item's detail. + x-schemaName: OrderItem required: - id - - version - - order_id - - return_id - - exchange_id - - claim_id - - order - - return_order - - exchange - - claim - - actions - - status - - requested_by - - requested_at - - confirmed_by - - confirmed_at - - declined_by - - declined_reason + - item_id + - item + - quantity + - raw_quantity + - fulfilled_quantity + - raw_fulfilled_quantity + - delivered_quantity + - raw_delivered_quantity + - shipped_quantity + - raw_shipped_quantity + - return_requested_quantity + - raw_return_requested_quantity + - return_received_quantity + - raw_return_received_quantity + - return_dismissed_quantity + - raw_return_dismissed_quantity + - written_off_quantity + - raw_written_off_quantity - metadata - - declined_at - - canceled_by - - canceled_at - created_at - updated_at properties: id: type: string title: id - description: The order change's ID. - version: - type: number - title: version - description: The order change's version. - change_type: - type: string - description: The order change's change type. - enum: - - return - - exchange - - claim - - edit - order_id: - type: string - title: order_id - description: The order change's order id. - return_id: - type: string - title: return_id - description: The order change's return id. - exchange_id: - type: string - title: exchange_id - description: The order change's exchange id. - claim_id: + description: The item's ID. + item_id: type: string - title: claim_id - description: The order change's claim id. - order: + title: item_id + description: The ID of the associated line item. + item: type: object - return_order: - $ref: '#/components/schemas/Return' - exchange: - $ref: '#/components/schemas/OrderExchange' - claim: - $ref: '#/components/schemas/OrderClaim' - actions: - type: array - description: The order change's actions. - items: - $ref: '#/components/schemas/OrderChangeAction' - status: - type: string - title: status - description: The order change's status. - requested_by: - type: string - title: requested_by - description: The order change's requested by. - requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time - confirmed_by: - type: string - title: confirmed_by - description: The order change's confirmed by. - confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time - declined_by: - type: string - title: declined_by - description: The order change's declined by. - declined_reason: - type: string - title: declined_reason - description: The order change's declined reason. - metadata: + quantity: + type: number + title: quantity + description: The item's quantity. + raw_quantity: type: object - description: The order change's metadata. - declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time - canceled_by: - type: string - title: canceled_by - description: The order change's canceled by. - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time - created_at: - type: string - format: date-time - title: created_at - description: The order change's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The order change's updated at. - OrderChangeAction: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - OrderClaim: - type: object - description: The order change's claim. - x-schemaName: OrderClaim - OrderExchange: - type: object - description: The order change's exchange. - x-schemaName: OrderExchange - OrderItem: - type: object - description: The item's detail. - x-schemaName: OrderItem - OrderLineItemAdjustment: - type: object - description: The adjustment's adjustments. - x-schemaName: OrderLineItemAdjustment - OrderLineItemTaxLine: - type: object - description: The tax line's tax lines. - x-schemaName: OrderLineItemTaxLine - OrderPreview: + description: The item's raw quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + raw_fulfilled_quantity: + type: object + description: The item's raw fulfilled quantity. + delivered_quantity: + type: number + title: delivered_quantity + description: The item's delivered quantity. + raw_delivered_quantity: + type: object + description: The item's raw delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + raw_shipped_quantity: + type: object + description: The item's raw shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + raw_return_requested_quantity: + type: object + description: The item's raw return requested quantity. + return_received_quantity: + type: number + title: return_received_quantity + description: The item's quantity that's received through a return. + raw_return_received_quantity: + type: object + description: The item's raw return received quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: The item's quantity that's returned but dismissed because it's damaged. + raw_return_dismissed_quantity: + type: object + description: The item's raw return dismissed quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed due to an order change. + raw_written_off_quantity: + type: object + description: The item's raw written off quantity. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + OrderLineItem: type: object - description: The order edit's order preview. - x-schemaName: OrderPreview + description: The order line item's details. + x-schemaName: OrderLineItem required: - - order_change - - status - - currency_code - - version - id - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total + - title + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - raw_unit_price + - quantity + - raw_quantity + - detail + - created_at + - updated_at - original_total - original_subtotal - original_tax_total + - item_total + - item_subtotal + - item_tax_total - total - subtotal - tax_total - discount_total - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total - - raw_original_item_total - - raw_original_item_subtotal - - raw_original_item_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total + - refundable_total + - refundable_total_per_unit - raw_original_total - raw_original_subtotal - raw_original_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total - raw_total - raw_subtotal - raw_tax_total - raw_discount_total - raw_discount_tax_total - - raw_gift_card_total - - raw_gift_card_tax_total - - raw_shipping_total - - raw_shipping_subtotal - - raw_shipping_tax_total - - raw_original_shipping_total - - raw_original_shipping_subtotal - - raw_original_shipping_tax_total + - raw_refundable_total + - raw_refundable_total_per_unit properties: - order_change: - $ref: '#/components/schemas/OrderChange' - items: - type: array - description: The order preview's items. - items: - allOf: - - type: object - description: The item's items. - x-schemaName: OrderLineItem - required: - - id - - title - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - - raw_unit_price - - quantity - - raw_quantity - - detail - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - item_total - - item_subtotal - - item_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - refundable_total - - refundable_total_per_unit - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - - raw_refundable_total - - raw_refundable_total_per_unit - properties: - id: - type: string - title: id - description: The item's ID. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The item's thumbnail. - variant_id: - type: string - title: variant_id - description: The item's variant id. - product_id: - type: string - title: product_id - description: The item's product id. - product_title: - type: string - title: product_title - description: The item's product title. - product_description: - type: string - title: product_description - description: The item's product description. - product_subtitle: - type: string - title: product_subtitle - description: The item's product subtitle. - product_type: - type: string - title: product_type - description: The item's product type. - product_collection: - type: string - title: product_collection - description: The item's product collection. - product_handle: - type: string - title: product_handle - description: The item's product handle. - variant_sku: - type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: - type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: - type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - compare_at_unit_price: - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - raw_compare_at_unit_price: - type: object - description: The item's raw compare at unit price. - unit_price: - type: number - title: unit_price - description: The item's unit price. - raw_unit_price: - type: object - description: The item's raw unit price. - quantity: - type: number - title: quantity - description: The item's quantity. - raw_quantity: - type: object - description: The item's raw quantity. - tax_lines: - type: array - description: The item's tax lines. - items: - $ref: '#/components/schemas/OrderLineItemTaxLine' - adjustments: - type: array - description: The item's adjustments. - items: - $ref: '#/components/schemas/OrderLineItemAdjustment' - detail: - $ref: '#/components/schemas/OrderItem' - created_at: - type: string - format: date-time - title: created_at - description: The item's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The item's updated at. - metadata: - type: object - description: The item's metadata. - original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: '#/components/schemas/IBigNumber' - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: '#/components/schemas/IBigNumber' - item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: '#/components/schemas/IBigNumber' - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: '#/components/schemas/IBigNumber' - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: '#/components/schemas/IBigNumber' - total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: '#/components/schemas/IBigNumber' - subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: '#/components/schemas/IBigNumber' - tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: '#/components/schemas/IBigNumber' - discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: '#/components/schemas/IBigNumber' - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - refundable_total: - oneOf: - - type: string - title: refundable_total - description: The item's refundable total. - - type: number - title: refundable_total - description: The item's refundable total. - - type: string - title: refundable_total - description: The item's refundable total. - - $ref: '#/components/schemas/IBigNumber' - refundable_total_per_unit: - oneOf: - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: number - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - $ref: '#/components/schemas/IBigNumber' - raw_original_total: - type: object - description: The item's raw original total. - raw_original_subtotal: - type: object - description: The item's raw original subtotal. - raw_original_tax_total: - type: object - description: The item's raw original tax total. - raw_item_total: - type: object - description: The item's raw item total. - raw_item_subtotal: - type: object - description: The item's raw item subtotal. - raw_item_tax_total: - type: object - description: The item's raw item tax total. - raw_total: - type: object - description: The item's raw total. - raw_subtotal: - type: object - description: The item's raw subtotal. - raw_tax_total: - type: object - description: The item's raw tax total. - raw_discount_total: - type: object - description: The item's raw discount total. - raw_discount_tax_total: - type: object - description: The item's raw discount tax total. - raw_refundable_total: - type: object - description: The item's raw refundable total. - raw_refundable_total_per_unit: - type: object - description: The item's raw refundable total per unit. - - type: object - description: The item's items. - properties: - actions: - type: array - description: The item's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - shipping_methods: - type: array - description: The order preview's shipping methods. - items: - allOf: - - type: object - description: The shipping method's shipping methods. - x-schemaName: OrderShippingMethod - required: - - id - - order_id - - name - - amount - - raw_amount - - is_tax_inclusive - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - properties: - id: - type: string - title: id - description: The shipping method's ID. - order_id: - type: string - title: order_id - description: The shipping method's order id. - name: - type: string - title: name - description: The shipping method's name. - description: - type: string - title: description - description: The shipping method's description. - amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: '#/components/schemas/IBigNumber' - raw_amount: - type: object - description: The shipping method's raw amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping method's is tax inclusive. - shipping_option_id: - type: string - title: shipping_option_id - description: The shipping method's shipping option id. - data: - type: object - description: The shipping method's data. - metadata: - type: object - description: The shipping method's metadata. - tax_lines: - type: array - description: The shipping method's tax lines. - items: - $ref: '#/components/schemas/OrderShippingMethodTaxLine' - adjustments: - type: array - description: The shipping method's adjustments. - items: - $ref: '#/components/schemas/OrderShippingMethodAdjustment' - created_at: - type: string - format: date-time - title: created_at - description: The shipping method's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The shipping method's updated at. - original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: '#/components/schemas/IBigNumber' - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: '#/components/schemas/IBigNumber' - total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: '#/components/schemas/IBigNumber' - subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: '#/components/schemas/IBigNumber' - tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: '#/components/schemas/IBigNumber' - discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: '#/components/schemas/IBigNumber' - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - raw_original_total: - type: object - description: The shipping method's raw original total. - raw_original_subtotal: - type: object - description: The shipping method's raw original subtotal. - raw_original_tax_total: - type: object - description: The shipping method's raw original tax total. - raw_total: - type: object - description: The shipping method's raw total. - raw_subtotal: - type: object - description: The shipping method's raw subtotal. - raw_tax_total: - type: object - description: The shipping method's raw tax total. - raw_discount_total: - type: object - description: The shipping method's raw discount total. - raw_discount_tax_total: - type: object - description: The shipping method's raw discount tax total. - - type: object - description: The shipping method's shipping methods. - properties: - actions: - type: array - description: The shipping method's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - status: - type: string - description: The order preview's status. - enum: - - canceled - - requires_action - - pending - - completed - - draft - - archived - currency_code: - type: string - title: currency_code - description: The order preview's currency code. - version: - type: number - title: version - description: The order preview's version. id: type: string title: id - description: The order preview's ID. - region_id: + description: The item's ID. + title: type: string - title: region_id - description: The order preview's region id. - customer_id: + title: title + description: The item's title. + subtitle: type: string - title: customer_id - description: The order preview's customer id. - sales_channel_id: + title: subtitle + description: The item's subtitle. + thumbnail: type: string - title: sales_channel_id - description: The order preview's sales channel id. - email: + title: thumbnail + description: The item's thumbnail URL. + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The ID of the associated product's type. + product_collection: + type: string + title: product_collection + description: The ID of the associated product's collection. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: type: string - title: email - description: The order preview's email. - format: email - shipping_address: - $ref: '#/components/schemas/OrderAddress' - billing_address: - $ref: '#/components/schemas/OrderAddress' - transactions: - type: array - description: The order preview's transactions. - items: - $ref: '#/components/schemas/OrderTransaction' - summary: + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The associated variant's values for the associated product's options. + example: + Color: Red + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item's price includes taxes. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + raw_compare_at_unit_price: type: object - description: The order preview's summary. + description: The item's raw compare at unit price. required: - - total - - subtotal - - total_tax - - ordered_total - - fulfilled_total - - returned_total - - return_request_total - - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - - paid_total - - refunded_total - - pending_difference - - raw_pending_difference + - value properties: - total: - oneOf: - - type: string - title: total - description: The summary's total. - - type: number - title: total - description: The summary's total. - - type: string - title: total - description: The summary's total. - - type: object - description: The summary's total. - x-schemaName: IBigNumber - subtotal: - oneOf: - - type: string - title: subtotal - description: The summary's subtotal. - - type: number - title: subtotal - description: The summary's subtotal. - - type: string - title: subtotal - description: The summary's subtotal. - - type: object - description: The summary's subtotal. - x-schemaName: IBigNumber - total_tax: - oneOf: - - type: string - title: total_tax - description: The summary's total tax. - - type: number - title: total_tax - description: The summary's total tax. - - type: string - title: total_tax - description: The summary's total tax. - - type: object - description: The summary's total tax. - x-schemaName: IBigNumber - ordered_total: - oneOf: - - type: string - title: ordered_total - description: The summary's ordered total. - - type: number - title: ordered_total - description: The summary's ordered total. - - type: string - title: ordered_total - description: The summary's ordered total. - - type: object - description: The summary's ordered total. - x-schemaName: IBigNumber - fulfilled_total: - oneOf: - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: number - title: fulfilled_total - description: The summary's fulfilled total. - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: object - description: The summary's fulfilled total. - x-schemaName: IBigNumber - returned_total: - oneOf: - - type: string - title: returned_total - description: The summary's returned total. - - type: number - title: returned_total - description: The summary's returned total. - - type: string - title: returned_total - description: The summary's returned total. - - type: object - description: The summary's returned total. - x-schemaName: IBigNumber - return_request_total: - oneOf: - - type: string - title: return_request_total - description: The summary's return request total. - - type: number - title: return_request_total - description: The summary's return request total. - - type: string - title: return_request_total - description: The summary's return request total. - - type: object - description: The summary's return request total. - x-schemaName: IBigNumber - write_off_total: - oneOf: - - type: string - title: write_off_total - description: The summary's write off total. - - type: number - title: write_off_total - description: The summary's write off total. - - type: string - title: write_off_total - description: The summary's write off total. - - type: object - description: The summary's write off total. - x-schemaName: IBigNumber - projected_total: - oneOf: - - type: string - title: projected_total - description: The summary's projected total. - - type: number - title: projected_total - description: The summary's projected total. - - type: string - title: projected_total - description: The summary's projected total. - - type: object - description: The summary's projected total. - x-schemaName: IBigNumber - net_total: - oneOf: - - type: string - title: net_total - description: The summary's net total. - - type: number - title: net_total - description: The summary's net total. - - type: string - title: net_total - description: The summary's net total. - - type: object - description: The summary's net total. - x-schemaName: IBigNumber - net_subtotal: - oneOf: - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: number - title: net_subtotal - description: The summary's net subtotal. - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: object - description: The summary's net subtotal. - x-schemaName: IBigNumber - net_total_tax: - oneOf: - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: number - title: net_total_tax - description: The summary's net total tax. - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: object - description: The summary's net total tax. - x-schemaName: IBigNumber - balance: - oneOf: - - type: string - title: balance - description: The summary's balance. - - type: number - title: balance - description: The summary's balance. - - type: string - title: balance - description: The summary's balance. - - type: object - description: The summary's balance. - x-schemaName: IBigNumber - paid_total: + value: oneOf: - type: string - title: paid_total - description: The summary's paid total. + title: value + description: The raw compare at unit price's value. - type: number - title: paid_total - description: The summary's paid total. - - type: string - title: paid_total - description: The summary's paid total. - - type: object - description: The summary's paid total. - x-schemaName: IBigNumber - refunded_total: + title: value + description: The raw compare at unit price's value. + unit_price: + type: number + title: unit_price + description: The item's price for a single quantity. + raw_unit_price: + type: object + description: The item's raw unit price. + required: + - value + properties: + value: oneOf: - type: string - title: refunded_total - description: The summary's refunded total. + title: value + description: The raw unit price's value. - type: number - title: refunded_total - description: The summary's refunded total. - - type: string - title: refunded_total - description: The summary's refunded total. - - type: object - description: The summary's refunded total. - x-schemaName: IBigNumber - pending_difference: + title: value + description: The raw unit price's value. + quantity: + type: number + title: quantity + description: The item's quantity. + raw_quantity: + type: object + description: The item's raw quantity. + required: + - value + properties: + value: oneOf: - type: string - title: pending_difference - description: The summary's pending difference. + title: value + description: The raw quantity's value. - type: number - title: pending_difference - description: The summary's pending difference. - - type: string - title: pending_difference - description: The summary's pending difference. - - type: object - description: The summary's pending difference. - x-schemaName: IBigNumber - raw_pending_difference: - type: object - description: The summary's raw pending difference. - metadata: - type: object - description: The order preview's metadata. + title: value + description: The raw quantity's value. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: '#/components/schemas/OrderLineItemTaxLine' + adjustments: + type: array + description: The item's adjustments. + items: + $ref: '#/components/schemas/OrderLineItemAdjustment' + detail: + $ref: '#/components/schemas/OrderItem' created_at: type: string format: date-time title: created_at - description: The order preview's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The order preview's updated at. - original_item_total: - oneOf: - - type: string - title: original_item_total - description: The order preview's original item total. - - type: number - title: original_item_total - description: The order preview's original item total. - - type: string - title: original_item_total - description: The order preview's original item total. - - $ref: '#/components/schemas/IBigNumber' - original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: number - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - type: number - title: original_item_tax_total - description: The order preview's original item tax total. - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - $ref: '#/components/schemas/IBigNumber' - item_total: - oneOf: - - type: string - title: item_total - description: The order preview's item total. - - type: number - title: item_total - description: The order preview's item total. - - type: string - title: item_total - description: The order preview's item total. - - $ref: '#/components/schemas/IBigNumber' - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - type: number - title: item_subtotal - description: The order preview's item subtotal. - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - $ref: '#/components/schemas/IBigNumber' - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The order preview's item tax total. - - type: number - title: item_tax_total - description: The order preview's item tax total. - - type: string - title: item_tax_total - description: The order preview's item tax total. - - $ref: '#/components/schemas/IBigNumber' + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. original_total: - oneOf: - - type: string - title: original_total - description: The order preview's original total. - - type: number - title: original_total - description: The order preview's original total. - - type: string - title: original_total - description: The order preview's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The item's total including taxes and promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - type: number - title: original_subtotal - description: The order preview's original subtotal. - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The order preview's original tax total. - - type: number - title: original_tax_total - description: The order preview's original tax total. - - type: string - title: original_tax_total - description: The order preview's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. + item_total: + type: number + title: item_total + description: The item's total for a single quantity, including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The item's total for a single quantity, excluding taxes and including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of a single quantity of the item, including promotions. total: - oneOf: - - type: string - title: total - description: The order preview's total. - - type: number - title: total - description: The order preview's total. - - type: string - title: total - description: The order preview's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The item's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The order preview's subtotal. - - type: number - title: subtotal - description: The order preview's subtotal. - - type: string - title: subtotal - description: The order preview's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The order preview's tax total. - - type: number - title: tax_total - description: The order preview's tax total. - - type: string - title: tax_total - description: The order preview's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The total taxes of the item, including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The order preview's discount total. - - type: number - title: discount_total - description: The order preview's discount total. - - type: string - title: discount_total - description: The order preview's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The item's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - type: number - title: discount_tax_total - description: The order preview's discount tax total. - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The order preview's gift card total. - - type: number - title: gift_card_total - description: The order preview's gift card total. - - type: string - title: gift_card_total - description: The order preview's gift card total. - - $ref: '#/components/schemas/IBigNumber' - gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: number - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - $ref: '#/components/schemas/IBigNumber' - shipping_total: - oneOf: - - type: string - title: shipping_total - description: The order preview's shipping total. - - type: number - title: shipping_total - description: The order preview's shipping total. - - type: string - title: shipping_total - description: The order preview's shipping total. - - $ref: '#/components/schemas/IBigNumber' - shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: number - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' - shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: number - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - $ref: '#/components/schemas/IBigNumber' - original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - type: number - title: original_shipping_total - description: The order preview's original shipping total. - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - $ref: '#/components/schemas/IBigNumber' - original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - $ref: '#/components/schemas/IBigNumber' - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order preview's canceled at. - - type: string - title: canceled_at - description: The order preview's canceled at. - format: date-time - raw_original_item_total: + type: number + title: discount_tax_total + description: The total taxes on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total amount of the item that can be refunded. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total amount that can be refunded of a single quantity of the item. + raw_original_total: type: object - description: The order preview's raw original item total. + description: The item's raw original total. required: - value properties: @@ -59079,13 +62435,13 @@ components: oneOf: - type: string title: value - description: The raw original item total's value. + description: The raw original total's value. - type: number title: value - description: The raw original item total's value. - raw_original_item_subtotal: + description: The raw original total's value. + raw_original_subtotal: type: object - description: The order preview's raw original item subtotal. + description: The item's raw original subtotal. required: - value properties: @@ -59093,13 +62449,13 @@ components: oneOf: - type: string title: value - description: The raw original item subtotal's value. + description: The raw original subtotal's value. - type: number title: value - description: The raw original item subtotal's value. - raw_original_item_tax_total: + description: The raw original subtotal's value. + raw_original_tax_total: type: object - description: The order preview's raw original item tax total. + description: The item's raw original tax total. required: - value properties: @@ -59107,13 +62463,13 @@ components: oneOf: - type: string title: value - description: The raw original item tax total's value. + description: The raw original tax total's value. - type: number title: value - description: The raw original item tax total's value. + description: The raw original tax total's value. raw_item_total: type: object - description: The order preview's raw item total. + description: The item's raw item total. required: - value properties: @@ -59127,7 +62483,7 @@ components: description: The raw item total's value. raw_item_subtotal: type: object - description: The order preview's raw item subtotal. + description: The item's raw item subtotal. required: - value properties: @@ -59141,7 +62497,7 @@ components: description: The raw item subtotal's value. raw_item_tax_total: type: object - description: The order preview's raw item tax total. + description: The item's raw item tax total. required: - value properties: @@ -59153,9 +62509,9 @@ components: - type: number title: value description: The raw item tax total's value. - raw_original_total: + raw_total: type: object - description: The order preview's raw original total. + description: The item's raw total. required: - value properties: @@ -59163,13 +62519,13 @@ components: oneOf: - type: string title: value - description: The raw original total's value. + description: The raw total's value. - type: number title: value - description: The raw original total's value. - raw_original_subtotal: + description: The raw total's value. + raw_subtotal: type: object - description: The order preview's raw original subtotal. + description: The item's raw subtotal. required: - value properties: @@ -59177,13 +62533,13 @@ components: oneOf: - type: string title: value - description: The raw original subtotal's value. + description: The raw subtotal's value. - type: number title: value - description: The raw original subtotal's value. - raw_original_tax_total: + description: The raw subtotal's value. + raw_tax_total: type: object - description: The order preview's raw original tax total. + description: The item's raw tax total. required: - value properties: @@ -59191,13 +62547,13 @@ components: oneOf: - type: string title: value - description: The raw original tax total's value. + description: The raw tax total's value. - type: number title: value - description: The raw original tax total's value. - raw_total: + description: The raw tax total's value. + raw_discount_total: type: object - description: The order preview's raw total. + description: The item's raw discount total. required: - value properties: @@ -59205,13 +62561,13 @@ components: oneOf: - type: string title: value - description: The raw total's value. + description: The raw discount total's value. - type: number title: value - description: The raw total's value. - raw_subtotal: + description: The raw discount total's value. + raw_discount_tax_total: type: object - description: The order preview's raw subtotal. + description: The item's raw discount tax total. required: - value properties: @@ -59219,13 +62575,13 @@ components: oneOf: - type: string title: value - description: The raw subtotal's value. + description: The raw discount tax total's value. - type: number title: value - description: The raw subtotal's value. - raw_tax_total: + description: The raw discount tax total's value. + raw_refundable_total: type: object - description: The order preview's raw tax total. + description: The item's raw refundable total. required: - value properties: @@ -59233,13 +62589,13 @@ components: oneOf: - type: string title: value - description: The raw tax total's value. + description: The raw refundable total's value. - type: number title: value - description: The raw tax total's value. - raw_discount_total: + description: The raw refundable total's value. + raw_refundable_total_per_unit: type: object - description: The order preview's raw discount total. + description: The item's raw refundable total per unit. required: - value properties: @@ -59247,13 +62603,238 @@ components: oneOf: - type: string title: value - description: The raw discount total's value. + description: The raw refundable total per unit's value. - type: number title: value - description: The raw discount total's value. - raw_discount_tax_total: + description: The raw refundable total per unit's value. + OrderLineItemAdjustment: + type: object + description: The line item adjustment's details. + x-schemaName: OrderLineItemAdjustment + required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at + properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the item this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. + OrderLineItemTaxLine: + type: object + description: The line item tax line's details. + x-schemaName: OrderLineItemTaxLine + required: + - item + - item_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at + properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the line item that the tax line belongs to. + total: + type: number + title: total + description: The item's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax lines. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. + OrderReturnItem: + type: object + description: The item's items. + x-schemaName: OrderReturnItem + required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id + properties: + id: + type: string + title: id + description: The return item's ID. + quantity: + type: number + title: quantity + description: The return item's quantity. + received_quantity: + type: number + title: received_quantity + description: The received quantity of the item. This quantity is added to the stocked inventory quantity of the item. + damaged_quantity: + type: number + title: damaged_quantity + description: The received damaged quantity of the item, which isn't added to the stocked inventory quantity of the item. + reason_id: + type: string + title: reason_id + description: The ID of the return reason associated with the item. + note: + type: string + title: note + description: A note about why the item was returned. + item_id: + type: string + title: item_id + description: The ID of the associated order item. + return_id: + type: string + title: return_id + description: The ID of the return this return item belongs to. + metadata: + type: object + description: The return item's metadata, can hold custom key-value pairs. + OrderShippingMethod: + type: object + description: The shipping method's details. + x-schemaName: OrderShippingMethod + required: + - id + - order_id + - name + - amount + - raw_amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order that the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + raw_amount: type: object - description: The order preview's raw discount tax total. + description: The shipping method's raw amount. required: - value properties: @@ -59261,13 +62842,81 @@ components: oneOf: - type: string title: value - description: The raw discount tax total's value. + description: The raw amount's value. - type: number title: value - description: The raw discount tax total's value. - raw_gift_card_total: + description: The raw amount's value. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: The shipping method's data, useful for the fulfillment provider handling the fulfillment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/order/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: '#/components/schemas/OrderShippingMethodTaxLine' + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: '#/components/schemas/OrderShippingMethodAdjustment' + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's subtotal excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the shipping method excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes of the shipping method, including promotions. + discount_total: + type: number + title: discount_total + description: The shipping method's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes of the discount amount. + raw_original_total: type: object - description: The order preview's raw gift card total. + description: The shipping method's raw original total. required: - value properties: @@ -59275,13 +62924,13 @@ components: oneOf: - type: string title: value - description: The raw gift card total's value. + description: The raw original total's value. - type: number title: value - description: The raw gift card total's value. - raw_gift_card_tax_total: + description: The raw original total's value. + raw_original_subtotal: type: object - description: The order preview's raw gift card tax total. + description: The shipping method's raw original subtotal. required: - value properties: @@ -59289,13 +62938,13 @@ components: oneOf: - type: string title: value - description: The raw gift card tax total's value. + description: The raw original subtotal's value. - type: number title: value - description: The raw gift card tax total's value. - raw_shipping_total: + description: The raw original subtotal's value. + raw_original_tax_total: type: object - description: The order preview's raw shipping total. + description: The shipping method's raw original tax total. required: - value properties: @@ -59303,13 +62952,13 @@ components: oneOf: - type: string title: value - description: The raw shipping total's value. + description: The raw original tax total's value. - type: number title: value - description: The raw shipping total's value. - raw_shipping_subtotal: + description: The raw original tax total's value. + raw_total: type: object - description: The order preview's raw shipping subtotal. + description: The shipping method's raw total. required: - value properties: @@ -59317,13 +62966,13 @@ components: oneOf: - type: string title: value - description: The raw shipping subtotal's value. + description: The raw total's value. - type: number title: value - description: The raw shipping subtotal's value. - raw_shipping_tax_total: + description: The raw total's value. + raw_subtotal: type: object - description: The order preview's raw shipping tax total. + description: The shipping method's raw subtotal. required: - value properties: @@ -59331,13 +62980,13 @@ components: oneOf: - type: string title: value - description: The raw shipping tax total's value. + description: The raw subtotal's value. - type: number title: value - description: The raw shipping tax total's value. - raw_original_shipping_total: + description: The raw subtotal's value. + raw_tax_total: type: object - description: The order preview's raw original shipping total. + description: The shipping method's raw tax total. required: - value properties: @@ -59345,13 +62994,13 @@ components: oneOf: - type: string title: value - description: The raw original shipping total's value. + description: The raw tax total's value. - type: number title: value - description: The raw original shipping total's value. - raw_original_shipping_subtotal: + description: The raw tax total's value. + raw_discount_total: type: object - description: The order preview's raw original shipping subtotal. + description: The shipping method's raw discount total. required: - value properties: @@ -59359,13 +63008,13 @@ components: oneOf: - type: string title: value - description: The raw original shipping subtotal's value. + description: The raw discount total's value. - type: number title: value - description: The raw original shipping subtotal's value. - raw_original_shipping_tax_total: + description: The raw discount total's value. + raw_discount_tax_total: type: object - description: The order preview's raw original shipping tax total. + description: The shipping method's raw discount tax total. required: - value properties: @@ -59373,34 +63022,152 @@ components: oneOf: - type: string title: value - description: The raw original shipping tax total's value. + description: The raw discount tax total's value. - type: number title: value - description: The raw original shipping tax total's value. + description: The raw discount tax total's value. OrderShippingMethodAdjustment: type: object - description: The adjustment's adjustments. + description: The shipping method adjustment's details. x-schemaName: OrderShippingMethodAdjustment + required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion this adjustment applies. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. OrderShippingMethodTaxLine: type: object - description: The tax line's tax lines. + description: The shipping method tax line's details. x-schemaName: OrderShippingMethodTaxLine + required: + - shipping_method + - shipping_method_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method that this tax line is for. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. OrderTransaction: type: object - description: The transaction's transactions. + description: The transaction's details. x-schemaName: OrderTransaction required: - id - order_id - - order - amount - - raw_amount - currency_code - reference - reference_id + - metadata - created_at - updated_at - - metadata properties: id: type: string @@ -59409,132 +63176,388 @@ components: order_id: type: string title: order_id - description: The transaction's order id. - order: - type: object + description: The ID of the order this transaction belongs to. amount: - oneOf: - - type: string - title: amount - description: The transaction's amount. - - type: number - title: amount - description: The transaction's amount. - - type: string - title: amount - description: The transaction's amount. - - $ref: '#/components/schemas/IBigNumber' - raw_amount: - type: object - description: The transaction's raw amount. + type: number + title: amount + description: The transaction's amount. currency_code: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: The name of a table that this transaction references. If this transaction is for captured payment, its value is `capture`. If this transaction is for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. + metadata: + type: object + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. + description: The date that the transaction was updated. + RefundReason: + type: object + description: The refund's refund reason. + x-schemaName: RefundReason + required: + - id + - label + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The refund reason's ID. + label: + type: string + title: label + description: The refund reason's label. + description: + type: string + title: description + description: The refund reason's description. metadata: type: object - description: The transaction's metadata. + description: The refund reason's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The refund reason's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The refund reason's updated at. RefundReasonResponse: type: object - description: SUMMARY + description: The refund reason's details. x-schemaName: RefundReasonResponse required: - refund_reason properties: refund_reason: $ref: '#/components/schemas/AdminRefundReason' - ReservationResponse: + Return: type: object - description: The reservation's details. - x-schemaName: ReservationResponse + description: The return's details. + x-schemaName: Return required: - id - - line_item_id - - location_id - - quantity - - external_id - - description - - inventory_item_id - - inventory_item + - status + - order_id + - items + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - discount_subtotal + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total properties: id: type: string title: id - description: The reservation's ID. - line_item_id: + description: The return's ID. + status: type: string - title: line_item_id - description: The reservation's line item id. - location_id: + description: The return's status. + enum: + - canceled + - requested + - received + - partially_received + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. + order_id: type: string - title: location_id - description: The reservation's location id. - quantity: + title: order_id + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: '#/components/schemas/OrderReturnItem' + region_id: type: string - title: quantity - description: The reservation's quantity. - external_id: + title: region_id + description: The ID of the region this return belongs to. + customer_id: type: string - title: external_id - description: The reservation's external id. - description: + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: type: string - title: description - description: The reservation's description. - inventory_item_id: + title: sales_channel_id + description: The ID of the associated order's sales channel. + email: type: string - title: inventory_item_id - description: The reservation's inventory item id. - inventory_item: + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The return's currency code. + example: usd + shipping_address: + $ref: '#/components/schemas/OrderAddress' + billing_address: + $ref: '#/components/schemas/OrderAddress' + shipping_methods: + type: array + description: The return's shipping methods. + items: + $ref: '#/components/schemas/OrderShippingMethod' + transactions: + type: array + description: The return's transactions. + items: + $ref: '#/components/schemas/OrderTransaction' + summary: type: object - description: The reservation's inventory item. + description: The return's summary. metadata: type: object - description: The reservation's metadata. - created_by: - type: string - title: created_by - description: The reservation's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The reservation's deleted at. + description: The return's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The reservation's created at. + description: The date the return was created. updated_at: type: string format: date-time title: updated_at - description: The reservation's updated at. - Return: - type: object - description: The order change's return order. - x-schemaName: Return + description: The date the return was updated. + original_item_total: + type: number + title: original_item_total + description: The return's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The return's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The return's original item tax total. + item_total: + type: number + title: item_total + description: The return's item total. + item_subtotal: + type: number + title: item_subtotal + description: The return's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The return's item tax total. + original_total: + type: number + title: original_total + description: The return's original total. + original_subtotal: + type: number + title: original_subtotal + description: The return's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The return's original tax total. + total: + type: number + title: total + description: The return's total. + subtotal: + type: number + title: subtotal + description: The return's subtotal. + tax_total: + type: number + title: tax_total + description: The return's tax total. + discount_total: + type: number + title: discount_total + description: The return's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The return's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The return's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The return's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The return's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The return's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The return's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The return's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The return's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The return's original shipping tax total. + order_change: + type: object + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time + discount_subtotal: + type: number + title: discount_subtotal + description: The return's discount subtotal. + raw_original_item_total: + type: object + description: The return's raw original item total. + raw_original_item_subtotal: + type: object + description: The return's raw original item subtotal. + raw_original_item_tax_total: + type: object + description: The return's raw original item tax total. + raw_item_total: + type: object + description: The return's raw item total. + raw_item_subtotal: + type: object + description: The return's raw item subtotal. + raw_item_tax_total: + type: object + description: The return's raw item tax total. + raw_original_total: + type: object + description: The return's raw original total. + raw_original_subtotal: + type: object + description: The return's raw original subtotal. + raw_original_tax_total: + type: object + description: The return's raw original tax total. + raw_total: + type: object + description: The return's raw total. + raw_subtotal: + type: object + description: The return's raw subtotal. + raw_tax_total: + type: object + description: The return's raw tax total. + raw_discount_total: + type: object + description: The return's raw discount total. + raw_discount_tax_total: + type: object + description: The return's raw discount tax total. + raw_gift_card_total: + type: object + description: The return's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The return's raw gift card tax total. + raw_shipping_total: + type: object + description: The return's raw shipping total. + raw_shipping_subtotal: + type: object + description: The return's raw shipping subtotal. + raw_shipping_tax_total: + type: object + description: The return's raw shipping tax total. + raw_original_shipping_total: + type: object + description: The return's raw original shipping total. + raw_original_shipping_subtotal: + type: object + description: The return's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The return's raw original shipping tax total. StoreAddCartLineItem: type: object - description: SUMMARY + description: The details of the line item to add. x-schemaName: StoreAddCartLineItem required: - variant_id @@ -59543,30 +63566,21 @@ components: variant_id: type: string title: variant_id - description: The cart's variant id. + description: The ID of the product variant to add to the cart. quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. - StoreCalculateCartTaxes: - type: object - description: SUMMARY - x-schemaName: StoreCalculateCartTaxes - properties: - fields: - type: string - title: fields - description: The cart's fields. + description: The item's metadata, can hold custom key-value pairs. StoreCart: type: object - description: The cart's parent. + description: The cart's details. x-schemaName: StoreCart required: - - id - currency_code + - id - original_item_total - original_item_subtotal - original_item_tax_total @@ -59593,326 +63607,151 @@ components: id: type: string title: id - description: The parent's ID. + description: The cart's ID. region: - $ref: '#/components/schemas/BaseRegion' + $ref: '#/components/schemas/StoreRegion' region_id: type: string title: region_id - description: The parent's region id. + description: The ID of the region the cart belongs to. customer_id: type: string title: customer_id - description: The parent's customer id. + description: The ID of the customer the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The parent's sales channel id. + description: The ID of the cart's sales channel. Only products that belong to the same sales channel can be added to the cart. The created order will be associated with the same sales channel. email: type: string title: email - description: The parent's email. + description: The email of the customer the cart belongs to. format: email currency_code: type: string title: currency_code - description: The parent's currency code. + description: The cart's currency code. + example: usd shipping_address: - $ref: '#/components/schemas/BaseCartAddress' + $ref: '#/components/schemas/StoreCartAddress' billing_address: - $ref: '#/components/schemas/BaseCartAddress' + $ref: '#/components/schemas/StoreCartAddress' items: type: array - description: The parent's items. + description: The cart's items. items: - $ref: '#/components/schemas/BaseCartLineItem' + $ref: '#/components/schemas/StoreCartLineItem' shipping_methods: type: array - description: The parent's shipping methods. + description: The cart's shipping methods. items: - $ref: '#/components/schemas/BaseCartShippingMethod' + $ref: '#/components/schemas/StoreCartShippingMethod' payment_collection: - $ref: '#/components/schemas/BasePaymentCollection' + $ref: '#/components/schemas/StorePaymentCollection' metadata: type: object - description: The parent's metadata. + description: The cart's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the cart was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the cart was updated. original_item_total: - oneOf: - - type: string - title: original_item_total - description: The parent's original item total. - - type: number - title: original_item_total - description: The parent's original item total. - - type: string - title: original_item_total - description: The parent's original item total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_item_total + description: The cart items' total including taxes, excluding promotions. original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - type: number - title: original_item_subtotal - description: The parent's original item subtotal. - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_item_subtotal + description: The cart items' total excluding taxes, including promotions. original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - type: number - title: original_item_tax_total - description: The parent's original item tax total. - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_item_tax_total + description: The cart items' tax total excluding promotions. item_total: - oneOf: - - type: string - title: item_total - description: The parent's item total. - - type: number - title: item_total - description: The parent's item total. - - type: string - title: item_total - description: The parent's item total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_total + description: The cart items' total including taxes and promotions. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The parent's item subtotal. - - type: number - title: item_subtotal - description: The parent's item subtotal. - - type: string - title: item_subtotal - description: The parent's item subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_subtotal + description: The cart items' total excluding taxes, including promotions. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The parent's item tax total. - - type: number - title: item_tax_total - description: The parent's item tax total. - - type: string - title: item_tax_total - description: The parent's item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_tax_total + description: The cart items' tax total including promotions. original_total: - oneOf: - - type: string - title: original_total - description: The parent's original total. - - type: number - title: original_total - description: The parent's original total. - - type: string - title: original_total - description: The parent's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The cart's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The parent's original subtotal. - - type: number - title: original_subtotal - description: The parent's original subtotal. - - type: string - title: original_subtotal - description: The parent's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The cart's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The parent's original tax total. - - type: number - title: original_tax_total - description: The parent's original tax total. - - type: string - title: original_tax_total - description: The parent's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The cart's tax total excluding promotions. total: - oneOf: - - type: string - title: total - description: The parent's total. - - type: number - title: total - description: The parent's total. - - type: string - title: total - description: The parent's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The cart's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The parent's subtotal. - - type: number - title: subtotal - description: The parent's subtotal. - - type: string - title: subtotal - description: The parent's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The cart's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The parent's tax total. - - type: number - title: tax_total - description: The parent's tax total. - - type: string - title: tax_total - description: The parent's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The cart's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The parent's discount total. - - type: number - title: discount_total - description: The parent's discount total. - - type: string - title: discount_total - description: The parent's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The cart's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - type: number - title: discount_tax_total - description: The parent's discount tax total. - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_tax_total + description: The tax total applied on the discounted amount. gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The parent's gift card total. - - type: number - title: gift_card_total - description: The parent's gift card total. - - type: string - title: gift_card_total - description: The parent's gift card total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: gift_card_total + description: The total gift card amount applied on the cart. gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: number - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: gift_card_tax_total + description: The total taxes applied on the gift card amount. shipping_total: - oneOf: - - type: string - title: shipping_total - description: The parent's shipping total. - - type: number - title: shipping_total - description: The parent's shipping total. - - type: string - title: shipping_total - description: The parent's shipping total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: shipping_total + description: The cart's shipping total including taxes and promotions. shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: number - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - type: number - title: shipping_tax_total - description: The parent's shipping tax total. - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: shipping_tax_total + description: The total taxes applied on the cart's shipping amount. original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - type: number - title: original_shipping_total - description: The parent's original shipping total. - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_shipping_total + description: The cart's shipping total including taxes, excluding promotions. original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_shipping_tax_total + description: The total taxes applied on the cart's shipping amount. StoreCartAddress: type: object - description: The cart's billing address. + description: The address's details. x-schemaName: StoreCartAddress required: - id @@ -59922,97 +63761,90 @@ components: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer the address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: - oneOf: - - type: string - title: created_at - description: The billing address's created at. - - type: string - title: created_at - description: The billing address's created at. - format: date-time + type: string + title: created_at + description: The date the address was created. + format: date-time updated_at: - oneOf: - - type: string - title: updated_at - description: The billing address's updated at. - - type: string - title: updated_at - description: The billing address's updated at. - format: date-time + type: string + title: updated_at + description: The date the address was updated. + format: date-time StoreCartLineItem: type: object - description: The item's items. + description: The item's details. x-schemaName: StoreCartLineItem required: - - id - - title - - quantity - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - cart - - cart_id - - original_total - - original_subtotal - - original_tax_total + - title + - id - item_total - item_subtotal - item_tax_total + - original_total + - original_subtotal + - original_tax_total - total - subtotal - tax_total - discount_total - discount_tax_total + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - cart_id properties: id: type: string @@ -60029,25 +63861,17 @@ components: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The item's thumbnail URL. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: quantity + description: The item's quantity. product: - $ref: '#/components/schemas/BaseProduct' + $ref: '#/components/schemas/StoreProduct' product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -60063,25 +63887,25 @@ components: product_type: type: string title: product_type - description: The item's product type. + description: The ID of the associated product's type. product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the associated product's collection. product_handle: type: string title: product_handle description: The item's product handle. variant: - $ref: '#/components/schemas/BaseProductVariant' + $ref: '#/components/schemas/StoreProductVariant' variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated product variant. variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -60092,43 +63916,29 @@ components: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The associated variant's value for the product's options. + example: + Color: Red requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item's price includes taxes. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: unit_price + description: The price of a single quantity of the item. tax_lines: type: array description: The item's tax lines. @@ -60140,170 +63950,191 @@ components: items: $ref: '#/components/schemas/BaseLineItemAdjustment' cart: - $ref: '#/components/schemas/BaseCart' + type: object cart_id: type: string title: cart_id - description: The item's cart id. + description: The ID of the cart that the line item belongs to. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string title: created_at - description: The item's created at. + description: The date the item was created. format: date-time updated_at: type: string title: updated_at - description: The item's updated at. + description: The date the item was updated. format: date-time deleted_at: type: string title: deleted_at - description: The item's deleted at. + description: The date the item was deleted. format: date-time original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The item's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The item's total including taxes and promotions. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_tax_total + description: The total taxes of the item including promotions. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The item's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The total taxes of the item including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The total discount of the item. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. StoreCartResponse: type: object - description: SUMMARY + description: The cart's details. x-schemaName: StoreCartResponse required: - cart properties: cart: $ref: '#/components/schemas/StoreCart' + StoreCartShippingMethod: + type: object + description: A cart's shipping method. + x-schemaName: StoreCartShippingMethod + required: + - id + - cart_id + - name + - amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + properties: + id: + type: string + title: id + description: The shipping method's ID. + cart_id: + type: string + title: cart_id + description: The ID of the cart this shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount is tax inclusive. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: The shipping method's data, useful for fulfillment handling by third-party services. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: '#/components/schemas/BaseShippingMethodTaxLine' + adjustments: + type: array + description: The shipping method's adjustments, such as applied promotions. + items: + $ref: '#/components/schemas/BaseShippingMethodAdjustment' + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes applied on the shipping method's amount including promotions. + total: + type: number + title: total + description: The shipping method's total amount including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes applied on the shipping method's amount including promotions. + discount_total: + type: number + title: discount_total + description: The total amount discounted. + discount_tax_total: + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. StoreCollection: type: object description: The collection's details. @@ -60333,17 +64164,17 @@ components: type: string format: date-time title: created_at - description: The collection's created at. + description: The date the collection was created. updated_at: type: string format: date-time title: updated_at - description: The collection's updated at. + description: The date the collection was updated. deleted_at: type: string format: date-time title: deleted_at - description: The collection's deleted at. + description: The date the collection was deleted. products: type: array description: The collection's products. @@ -60351,10 +64182,10 @@ components: $ref: '#/components/schemas/AdminProduct' metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. StoreCollectionResponse: type: object - description: SUMMARY + description: The collection's details. x-schemaName: StoreCollectionResponse required: - collection @@ -60363,13 +64194,13 @@ components: $ref: '#/components/schemas/StoreCollection' StoreCreateCart: type: object - description: SUMMARY + description: The details of the cart to be created. x-schemaName: StoreCreateCart properties: region_id: type: string title: region_id - description: The cart's region id. + description: The ID of the cart's region. This affects the prices and currency of the cart. shipping_address: $ref: '#/components/schemas/StoreCartAddress' billing_address: @@ -60377,12 +64208,13 @@ components: email: type: string title: email - description: The cart's email. + description: The email of the cart's customer. format: email currency_code: type: string title: currency_code - description: The cart's currency code. + description: The cart's currency code. If not provided, the region's currency is used. This affects prices in the cart, as well. + example: usd items: type: array description: The cart's items. @@ -60391,13 +64223,13 @@ components: sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: The ID of the sales channel that cart is created in. Only products available in that sales channel can be added to the cart. If not provided, the store's default sales channel is associated with the cart instead. metadata: type: object - description: The cart's metadata. + description: The cart's metadata, can hold custom key-value pairs. StoreCreateCustomer: type: object - description: SUMMARY + description: The details of the customer to create. x-schemaName: StoreCreateCustomer required: - email @@ -60425,10 +64257,10 @@ components: description: The customer's phone. metadata: type: object - description: The customer's metadata. + description: The customer's metadata, can hold custom key-value pairs. StoreCreatePaymentCollection: type: object - description: SUMMARY + description: The details of the payment collection to create. x-schemaName: StoreCreatePaymentCollection required: - cart_id @@ -60436,10 +64268,10 @@ components: cart_id: type: string title: cart_id - description: The payment collection's cart id. + description: The ID of the cart this payment collection is for. StoreCreateReturn: type: object - description: SUMMARY + description: The details of the return to create. x-schemaName: StoreCreateReturn required: - order_id @@ -60449,7 +64281,7 @@ components: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. items: type: array description: The return's items. @@ -60460,18 +64292,18 @@ components: note: type: string title: note - description: The return's note. + description: A note with more details about the return. receive_now: type: boolean title: receive_now - description: The return's receive now. + description: Whether to mark the return as received. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location that items are returned to. StoreCreateReturnItem: type: object - description: The item's items. + description: The details of the line item to create. x-schemaName: StoreCreateReturnItem required: - id @@ -60488,14 +64320,14 @@ components: reason_id: type: string title: reason_id - description: The item's reason id. + description: The ID of the associated return reason. note: type: string title: note - description: The item's note. + description: A note with more details about the returned item. StoreCreateReturnShipping: type: object - description: The return's return shipping. + description: The return's shipping details. x-schemaName: StoreCreateReturnShipping required: - option_id @@ -60503,11 +64335,11 @@ components: option_id: type: string title: option_id - description: The return shipping's option id. + description: The ID of the shipping option to use. price: type: number title: price - description: The return shipping's price. + description: The shipping's price. StoreCurrency: type: object description: The currency's details. @@ -60519,7 +64351,6 @@ components: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at @@ -60528,6 +64359,7 @@ components: type: string title: code description: The currency's code. + example: usd symbol: type: string title: symbol @@ -60548,39 +64380,24 @@ components: type: number title: rounding description: The currency's rounding. - raw_rounding: - type: object - description: The currency's raw rounding. - required: - - value - - precision - properties: - value: - type: string - title: value - description: The raw rounding's value. - precision: - type: number - title: precision - description: The raw rounding's precision. created_at: type: string format: date-time title: created_at - description: The currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The currency's deleted at. + description: The date the currency was deleted. StoreCurrencyListResponse: type: object - description: SUMMARY + description: The paginated list of currencies. x-schemaName: StoreCurrencyListResponse required: - limit @@ -60591,23 +64408,23 @@ components: limit: type: number title: limit - description: The currency's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The currency's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The currency's count. + description: The total count of items. currencies: type: array - description: The currency's currencies. + description: The list of currencies. items: $ref: '#/components/schemas/StoreCurrency' StoreCurrencyResponse: type: object - description: SUMMARY + description: The currency's details. x-schemaName: StoreCurrencyResponse required: - currency @@ -60616,7 +64433,7 @@ components: $ref: '#/components/schemas/StoreCurrency' StoreCustomer: type: object - description: The customer's parent. + description: The customer's details. x-schemaName: StoreCustomer required: - id @@ -60631,66 +64448,66 @@ components: id: type: string title: id - description: The parent's ID. + description: The customer's ID. email: type: string title: email - description: The parent's email. + description: The customer's email. format: email default_billing_address_id: type: string title: default_billing_address_id - description: The parent's default billing address id. + description: The ID of the address used for billing by default. default_shipping_address_id: type: string title: default_shipping_address_id - description: The parent's default shipping address id. + description: The ID of the address used for shipping by default. company_name: type: string title: company_name - description: The parent's company name. + description: The customer's company name. first_name: type: string title: first_name - description: The parent's first name. + description: The customer's first name. last_name: type: string title: last_name - description: The parent's last name. + description: The customer's last name. addresses: type: array - description: The parent's addresses. + description: The customer's addresses. items: $ref: '#/components/schemas/BaseCustomerAddress' phone: type: string title: phone - description: The parent's phone. + description: The customer's phone. metadata: type: object - description: The parent's metadata. - created_by: - type: string - title: created_by - description: The parent's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The parent's deleted at. + description: The customer's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the customer was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the customer was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the customer was deleted. + created_by: + type: string + title: created_by + description: The customer's created by. StoreCustomerAddress: type: object - description: The customer's address. + description: The customer address's details x-schemaName: StoreCustomerAddress required: - id @@ -60719,19 +64536,19 @@ components: address_name: type: string title: address_name - description: The address's address name. + description: The address's name. is_default_shipping: type: boolean title: is_default_shipping - description: The address's is default shipping. + description: Whether the address is used for shipping by default. is_default_billing: type: boolean title: is_default_billing - description: The address's is default billing. + description: Whether the address is used for billing by default. customer_id: type: string title: customer_id - description: The address's customer id. + description: The ID of the customer the address belongs to. company: type: string title: company @@ -60747,11 +64564,11 @@ components: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. city: type: string title: city @@ -60760,6 +64577,7 @@ components: type: string title: country_code description: The address's country code. + example: usd province: type: string title: province @@ -60774,20 +64592,20 @@ components: description: The address's phone. metadata: type: object - description: The address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The address's updated at. + description: The date the address was updated. StoreCustomerAddressListResponse: type: object - description: SUMMARY + description: The paginated list of customer addresses. x-schemaName: StoreCustomerAddressListResponse required: - limit @@ -60798,23 +64616,23 @@ components: limit: type: number title: limit - description: The customer's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The customer's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The customer's count. + description: The total number of items. addresses: type: array - description: The customer's addresses. + description: The list of addresses. items: $ref: '#/components/schemas/StoreCustomerAddress' StoreCustomerAddressResponse: type: object - description: SUMMARY + description: The address's details. x-schemaName: StoreCustomerAddressResponse required: - address @@ -60823,7 +64641,7 @@ components: $ref: '#/components/schemas/StoreCustomerAddress' StoreCustomerResponse: type: object - description: SUMMARY + description: The customer's details. x-schemaName: StoreCustomerResponse required: - customer @@ -60832,7 +64650,7 @@ components: $ref: '#/components/schemas/StoreCustomer' StoreOrder: type: object - description: The cart's order. + description: The order's details. x-schemaName: StoreOrder required: - id @@ -60884,28 +64702,29 @@ components: region_id: type: string title: region_id - description: The order's region id. + description: The ID of the associated region. customer_id: type: string title: customer_id - description: The order's customer id. + description: The ID of the customer that placed the order. sales_channel_id: type: string title: sales_channel_id - description: The order's sales channel id. + description: The ID of the sales channel the order was placed in. email: type: string title: email - description: The order's email. + description: The email of the customer that placed the order. format: email currency_code: type: string title: currency_code description: The order's currency code. + example: usd display_id: type: number title: display_id - description: The order's display id. + description: The order's display ID. shipping_address: $ref: '#/components/schemas/BaseOrderAddress' billing_address: @@ -60956,74 +64775,69 @@ components: - shipped - partially_delivered - delivered - transactions: - type: array - description: The order's transactions. - items: - $ref: '#/components/schemas/BaseOrderTransaction' summary: $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object - description: The order's metadata. + description: The order's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The order's created at. + description: The date the order was created. updated_at: type: string format: date-time title: updated_at - description: The order's updated at. + description: The date the order was updated. original_item_total: type: number title: original_item_total - description: The order's original item total. + description: The order items' total including taxes, excluding promotions. original_item_subtotal: type: number title: original_item_subtotal - description: The order's original item subtotal. + description: The order items' total excluding taxes, including promotions. original_item_tax_total: type: number title: original_item_tax_total - description: The order's original item tax total. + description: The total taxes applied on the order items, excluding promotions. item_total: type: number title: item_total - description: The order's item total. + description: The order items' total including taxes and promotions. item_subtotal: type: number title: item_subtotal - description: The order's item subtotal. + description: The order items' total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The order's item tax total. + description: The total taxes applied on the order's items, including promotions. original_total: type: number title: original_total - description: The order's original total. + description: The order's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The order's original subtotal. + description: The order's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The order's original tax total. + description: The total taxes of the order excluding promotions. total: type: number title: total - description: The order's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The order's subtotal. + description: The order's total excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The order's tax total. + description: The tax totals of the order including promotions. discount_total: type: number title: discount_total @@ -61031,7 +64845,7 @@ components: discount_tax_total: type: number title: discount_tax_total - description: The order's discount tax total. + description: The total taxes applied on the discounted amount. gift_card_total: type: number title: gift_card_total @@ -61039,51 +64853,53 @@ components: gift_card_tax_total: type: number title: gift_card_tax_total - description: The order's gift card tax total. + description: The total taxes applied on the gift card's amount. shipping_total: type: number title: shipping_total - description: The order's shipping total. + description: The order's shipping total including taxes and promotions. shipping_subtotal: type: number title: shipping_subtotal - description: The order's shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. shipping_tax_total: type: number title: shipping_tax_total - description: The order's shipping tax total. + description: The total taxes of the order's shipping including promotions. original_shipping_total: type: number title: original_shipping_total - description: The order's original shipping total. + description: The order's shipping total including taxes, excluding promotions. original_shipping_subtotal: type: number title: original_shipping_subtotal - description: The order's original shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. original_shipping_tax_total: type: number title: original_shipping_tax_total - description: The order's original shipping tax total. + description: The total taxes of the order's shipping excluding promotions. StoreOrderResponse: type: object - description: SUMMARY + description: The order's details. x-schemaName: StoreOrderResponse required: - order properties: order: - $ref: '#/components/schemas/StoreOrder' + type: string + title: order + description: The order's details. StorePaymentCollection: type: object description: The payment collection's details. x-schemaName: StorePaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -61096,77 +64912,41 @@ components: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -61178,14 +64958,14 @@ components: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: The payment provider used to process the collection's payments and sessions. items: - $ref: '#/components/schemas/BasePaymentProvider' + $ref: '#/components/schemas/StorePaymentProvider' payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: '#/components/schemas/BasePaymentSession' + $ref: '#/components/schemas/StorePaymentSession' payments: type: array description: The payment collection's payments. @@ -61193,7 +64973,7 @@ components: $ref: '#/components/schemas/BasePayment' StorePaymentCollectionResponse: type: object - description: SUMMARY + description: The payment collection's details. x-schemaName: StorePaymentCollectionResponse required: - payment_collection @@ -61211,20 +64991,78 @@ components: type: string title: id description: The payment provider's ID. + StorePaymentSession: + type: object + description: The payment session's details. + x-schemaName: StorePaymentSession + properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: The payment session's data, useful for the payment provider processing the payment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: '#/components/schemas/BasePayment' + required: + - id + - amount + - currency_code + - provider_id + - data + - status StoreProduct: type: object description: The product's details. x-schemaName: StoreProduct required: + - variants + - options + - images - length - title - status - - options - description - id - - created_at - - updated_at - - variants - handle - subtitle - is_giftcard @@ -61238,9 +65076,10 @@ components: - material - collection_id - type_id - - images - discountable - external_id + - created_at + - updated_at - deleted_at properties: categories: @@ -61270,7 +65109,7 @@ components: type: array description: The product's options. items: - $ref: '#/components/schemas/BaseProductOption' + $ref: '#/components/schemas/StoreProductOption' description: type: string title: description @@ -61281,22 +65120,22 @@ components: description: The product's ID. metadata: type: object - description: The product's metadata. + description: The product's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The product's created at. + description: The date the product was created. updated_at: type: string format: date-time title: updated_at - description: The product's updated at. + description: The date the product was updated. variants: type: array description: The product's variants. items: - $ref: '#/components/schemas/BaseProductVariant' + $ref: '#/components/schemas/StoreProductVariant' handle: type: string title: handle @@ -61308,11 +65147,11 @@ components: is_giftcard: type: boolean title: is_giftcard - description: The product's is giftcard. + description: Whether the product is a gift card. thumbnail: type: string title: thumbnail - description: The product's thumbnail. + description: The product's thumbnail URL. width: type: number title: width @@ -61332,59 +65171,57 @@ components: hs_code: type: string title: hs_code - description: The product's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The product's mid code. + description: The product's MID code. material: type: string title: material description: The product's material. collection: - $ref: '#/components/schemas/BaseCollection' + $ref: '#/components/schemas/StoreCollection' collection_id: type: string title: collection_id - description: The product's collection id. + description: The ID of the collection that the product belongs to. type_id: type: string title: type_id - description: The product's type id. + description: The ID of the product's type. tags: type: array description: The product's tags. items: - $ref: '#/components/schemas/BaseProductTag' + $ref: '#/components/schemas/StoreProductTag' images: type: array description: The product's images. items: - $ref: '#/components/schemas/BaseProductImage' + $ref: '#/components/schemas/StoreProductImage' discountable: type: boolean title: discountable - description: The product's discountable. + description: Whether the product can be discounted. external_id: type: string title: external_id - description: The product's external id. + description: The ID of the product in an external service or system. deleted_at: type: string format: date-time title: deleted_at - description: The product's deleted at. + description: The date the product was deleted. StoreProductCategory: type: object - description: The category's categories. + description: The category's details. x-schemaName: StoreProductCategory required: - id - name - description - handle - - is_active - - is_internal - rank - parent_category_id - parent_category @@ -61414,14 +65251,6 @@ components: type: string title: handle description: The category's handle. - is_active: - type: boolean - title: is_active - description: The category's is active. - is_internal: - type: boolean - title: is_internal - description: The category's is internal. rank: type: number title: rank @@ -61429,35 +65258,35 @@ components: parent_category_id: type: string title: parent_category_id - description: The category's parent category id. + description: The ID of the category's parent. parent_category: - $ref: '#/components/schemas/BaseProductCategory' + type: object category_children: type: array - description: The category's category children. + description: The category's children. items: - $ref: '#/components/schemas/BaseProductCategory' + type: object metadata: type: object - description: The category's metadata. + description: The category's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The category's created at. + description: The date the category was created. updated_at: type: string format: date-time title: updated_at - description: The category's updated at. + description: The date the category was updated. deleted_at: type: string format: date-time title: deleted_at - description: The category's deleted at. + description: The date the category was deleted. StoreProductCategoryListResponse: type: object - description: SUMMARY + description: The paginated list of product categories. x-schemaName: StoreProductCategoryListResponse required: - limit @@ -61468,114 +65297,325 @@ components: limit: type: number title: limit - description: The product category's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product category's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product category's count. + description: The total number of items. product_categories: type: array - description: The product category's product categories. + description: The list of product categories. items: $ref: '#/components/schemas/StoreProductCategory' StoreProductCategoryResponse: type: object - description: SUMMARY + description: The product category's details. x-schemaName: StoreProductCategoryResponse required: - product_category properties: product_category: $ref: '#/components/schemas/StoreProductCategory' + StoreProductImage: + type: object + description: The image's images. + x-schemaName: StoreProductImage + required: + - id + - url + properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's url. + created_at: + type: string + format: date-time + title: created_at + description: The image's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The image's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The image's deleted at. + metadata: + type: object + description: The image's metadata. + StoreProductOption: + type: object + description: The product option's details. + x-schemaName: StoreProductOption + properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + type: object + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: '#/components/schemas/StoreProductOptionValue' + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. + required: + - title + - id + StoreProductOptionValue: + type: object + description: The product option value's details. + x-schemaName: StoreProductOptionValue + required: + - value + - id + properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + type: object + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. StoreProductResponse: type: object - description: SUMMARY + description: The product's details. x-schemaName: StoreProductResponse required: - product properties: product: $ref: '#/components/schemas/StoreProduct' - StoreProductVariantParams: + StoreProductTag: type: object - description: The product's variants. - x-schemaName: StoreProductVariantParams + description: The tag's details. + x-schemaName: StoreProductTag properties: - q: - type: string - title: q - description: The variant's q. id: - oneOf: - - type: string - title: id - description: The variant's ID. - - type: array - description: The variant's ID. - items: - type: string - title: id - description: The id's ID. - sku: - oneOf: - - type: string - title: sku - description: The variant's sku. - - type: array - description: The variant's sku. - items: - type: string - title: sku - description: The sku's details. - product_id: - oneOf: - - type: string - title: product_id - description: The variant's product id. - - type: array - description: The variant's product id. - items: - type: string - title: product_id - description: The product id's details. - options: + type: string + title: id + description: The tag's ID. + value: + type: string + title: value + description: The tag's value. + created_at: + type: string + format: date-time + title: created_at + description: The date the tag was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tag was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the tag was deleted. + metadata: type: object + description: The tag's metadata, can hold custom key-value pairs. + required: + - id + - value + - created_at + - updated_at + StoreProductVariant: + type: object + description: The variant's variants. + x-schemaName: StoreProductVariant + properties: + options: + type: array description: The variant's options. - limit: + items: + $ref: '#/components/schemas/StoreProductOptionValue' + product: + type: object + length: type: number - title: limit - description: The variant's limit. - offset: + title: length + description: The variant's length. + title: + type: string + title: title + description: The variant's title. + metadata: + type: object + description: The variant's metadata. + id: + type: string + title: id + description: The variant's ID. + width: type: number - title: offset - description: The variant's offset. - order: + title: width + description: The variant's width. + weight: + type: number + title: weight + description: The variant's weight. + height: + type: number + title: height + description: The variant's height. + origin_country: type: string - title: order - description: The variant's order. - fields: + title: origin_country + description: The variant's origin country. + hs_code: type: string - title: fields - description: The variant's fields. - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or + title: hs_code + description: The variant's hs code. + mid_code: + type: string + title: mid_code + description: The variant's mid code. + material: + type: string + title: material + description: The variant's material. + created_at: + type: string + format: date-time + title: created_at + description: The variant's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The variant's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The variant's deleted at. + product_id: + type: string + title: product_id + description: The variant's product id. + sku: + type: string + title: sku + description: The variant's sku. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's ean. + upc: + type: string + title: upc + description: The variant's upc. + allow_backorder: + type: boolean + title: allow_backorder + description: The variant's allow backorder. + manage_inventory: + type: boolean + title: manage_inventory + description: The variant's manage inventory. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. + variant_rank: + type: number + title: variant_rank + description: The variant's variant rank. + calculated_price: + $ref: '#/components/schemas/BaseCalculatedPriceSet' + required: + - options + - length + - title + - id + - width + - weight + - height + - origin_country + - hs_code + - mid_code + - material + - created_at + - updated_at + - deleted_at + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory StoreRegion: type: object - description: The region's details. + description: The parent's region. x-schemaName: StoreRegion required: - id @@ -61626,11 +65666,11 @@ components: description: The return's details. x-schemaName: StoreReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -61642,57 +65682,118 @@ components: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. status: - type: string - title: status + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. description: The return's status. exchange_id: type: string title: exchange_id - description: The return's exchange id. + description: The ID of the associated exchange. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location the items are returned to. claim_id: type: string title: claim_id - description: The return's claim id. + description: The ID of the associated claim. order_version: type: number title: order_version - description: The return's order version. + description: The version of the order when the return is applied. display_id: type: number title: display_id - description: The return's display id. + description: The return's display ID. no_notification: type: boolean title: no_notification - description: The return's no notification. + description: Whether the customer should receive updates about changes in the return. refund_amount: type: number title: refund_amount - description: The return's refund amount. + description: The return's refunded amount. items: type: array description: The return's items. items: - $ref: '#/components/schemas/BaseReturnItem' + $ref: '#/components/schemas/StoreReturnItem' received_at: type: string title: received_at - description: The return's received at. + description: The date the return was received. created_at: type: string format: date-time title: created_at - description: The return's created at. + description: The date the return was created. canceled_at: type: string title: canceled_at - description: The return's canceled at. + description: The date the return was updated. + StoreReturnItem: + type: object + description: The item's items. + x-schemaName: StoreReturnItem + properties: + id: + type: string + title: id + description: The item's ID. + quantity: + type: number + title: quantity + description: The item's quantity. + received_quantity: + type: number + title: received_quantity + description: The item's received quantity. + damaged_quantity: + type: number + title: damaged_quantity + description: The item's damaged quantity. + reason_id: + type: string + title: reason_id + description: The item's reason id. + note: + type: string + title: note + description: The item's note. + item_id: + type: string + title: item_id + description: The item's item id. + return_id: + type: string + title: return_id + description: The item's return id. + metadata: + type: object + description: The item's metadata. + required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id StoreReturnReason: type: object description: The return reason's details. @@ -61722,20 +65823,20 @@ components: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. StoreReturnReasonResponse: type: object - description: SUMMARY + description: The return reason's details. x-schemaName: StoreReturnReasonResponse required: - return_reason @@ -61744,7 +65845,7 @@ components: $ref: '#/components/schemas/StoreReturnReason' StoreReturnResponse: type: object - description: SUMMARY + description: The return's details. x-schemaName: StoreReturnResponse required: - return @@ -61753,74 +65854,56 @@ components: $ref: '#/components/schemas/StoreReturn' StoreShippingOption: type: object - description: The shipping option's shipping options. + description: The shipping option's details. x-schemaName: StoreShippingOption required: - id - - name - - price_type - - service_zone_id - - provider_id - - provider - - shipping_option_type_id - - type - - shipping_profile_id - - amount - - is_tax_inclusive - - data - - metadata + - label + - description + - code + - shipping_option_id + - created_at + - updated_at + - deleted_at properties: id: type: string title: id description: The shipping option's ID. - name: + label: type: string - title: name - description: The shipping option's name. - price_type: + title: label + description: The type's label. + description: type: string - description: The shipping option's price type. - enum: - - flat - - calculated - service_zone_id: + title: description + description: The type's description. + code: type: string - title: service_zone_id - description: The shipping option's service zone id. - provider_id: + title: code + description: The type's code. + shipping_option_id: type: string - title: provider_id - description: The shipping option's provider id. - provider: - $ref: '#/components/schemas/BaseFulfillmentProvider' - shipping_option_type_id: + title: shipping_option_id + description: The type's shipping option id. + created_at: type: string - title: shipping_option_type_id - description: The shipping option's shipping option type id. - type: - type: object - shipping_profile_id: + format: date-time + title: created_at + description: The type's created at. + updated_at: type: string - title: shipping_profile_id - description: The shipping option's shipping profile id. - amount: - type: number - title: amount - description: The shipping option's amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping option's is tax inclusive. - data: - type: object - description: The shipping option's data. - metadata: - type: object - description: The shipping option's metadata. + format: date-time + title: updated_at + description: The type's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The type's deleted at. StoreShippingOptionListResponse: type: object - description: SUMMARY + description: The shipping option's details. x-schemaName: StoreShippingOptionListResponse required: - shipping_options @@ -61832,7 +65915,7 @@ components: $ref: '#/components/schemas/StoreShippingOption' StoreUpdateCartLineItem: type: object - description: SUMMARY + description: The details to update in the line item. x-schemaName: StoreUpdateCartLineItem required: - quantity @@ -61840,13 +65923,13 @@ components: quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. + description: The item's metadata, can hold custom key-value pairs. StoreUpdateCustomer: type: object - description: SUMMARY + description: The details to update in the customer. x-schemaName: StoreUpdateCustomer properties: company_name: @@ -61867,7 +65950,7 @@ components: description: The customer's phone. UpdateAddress: type: object - description: The cart's shipping address. + description: The details to update in the address. x-schemaName: UpdateAddress required: - id @@ -61875,88 +65958,90 @@ components: id: type: string title: id - description: The shipping address's ID. + description: The ID of an existing address to update. customer_id: type: string title: customer_id - description: The shipping address's customer id. + description: The ID of the customer that this address belongs to. company: type: string title: company - description: The shipping address's company. + description: The address's company. first_name: type: string title: first_name - description: The shipping address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The shipping address's last name. + description: The address's last name. address_1: type: string title: address_1 - description: The shipping address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The shipping address's address 2. + description: The address's second line. city: type: string title: city - description: The shipping address's city. + description: The address's city. country_code: type: string title: country_code - description: The shipping address's country code. + description: The address's country code. + example: usd province: type: string title: province - description: The shipping address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The shipping address's postal code. + description: The address's postal code. phone: type: string title: phone - description: The shipping address's phone. + description: The address's phone. metadata: type: object - description: The shipping address's metadata. + description: The address's metadata, can hold custom key-value pairs. UpdateCartData: type: object - description: SUMMARY + description: The details to update in a cart. x-schemaName: UpdateCartData properties: region_id: type: string title: region_id - description: The cart's region id. + description: The ID of the associated region. This can affect the prices and currency code of the cart. customer_id: type: string title: customer_id - description: The cart's customer id. + description: The ID of the customer that the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: The ID of the associated sales channel. Only products available in this channel can be added to the cart. email: type: string title: email - description: The cart's email. + description: The email of the customer that the cart belongs to. format: email currency_code: type: string title: currency_code description: The cart's currency code. + example: usd shipping_address_id: type: string title: shipping_address_id - description: The cart's shipping address id. + description: The ID of the cart's shipping address. billing_address_id: type: string title: billing_address_id - description: The cart's billing address id. + description: The ID of the cart's billing address. billing_address: oneOf: - $ref: '#/components/schemas/CreateAddress' @@ -61967,31 +66052,7 @@ components: - $ref: '#/components/schemas/UpdateAddress' metadata: type: object - description: The cart's metadata. - UpdateOrderReturnReason: - type: object - description: SUMMARY - x-schemaName: UpdateOrderReturnReason - properties: - id: - type: string - title: id - description: The return reason's ID. - label: - type: string - title: label - description: The return reason's label. - value: - type: string - title: value - description: The return reason's value. - description: - type: string - title: description - description: The return reason's description. - metadata: - type: object - description: The return reason's metadata. + description: The cart's metadata, ca hold custom key-value pairs. WorkflowExecutionContext: type: object description: The workflow execution's context. @@ -62003,6 +66064,30 @@ components: data: type: object description: The context's data. + properties: + invoke: + type: object + description: The step's invokation details. + required: + - output + additionalProperties: + type: object + properties: + output: + type: object + description: The invokation's details. + required: + - output + - compensateInput + properties: + output: + description: the step's output + compensateInput: + description: the compensation function's input. + payload: + description: the payload of the transaction. + required: + - invoke compensate: type: object description: The context's compensate. @@ -62011,7 +66096,23 @@ components: description: The context's errors. items: type: object - description: The error's errors. + description: The error's details. + properties: + error: + type: object + description: The error's details. + action: + type: string + title: action + description: The error's action. + handlerType: + type: string + title: handlerType + description: The error's handler type. + required: + - error + - action + - handlerType responses: default_error: description: Default Error diff --git a/www/apps/api-reference/specs/admin/openapi.yaml b/www/apps/api-reference/specs/admin/openapi.yaml index 594d270e4279b..77b4b47175943 100644 --- a/www/apps/api-reference/specs/admin/openapi.yaml +++ b/www/apps/api-reference/specs/admin/openapi.yaml @@ -791,6 +791,9 @@ paths: $ref: paths/admin_orders_{id}_fulfillments.yaml /admin/orders/{id}/fulfillments/{fulfillment_id}/cancel: $ref: paths/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel.yaml + /admin/orders/{id}/fulfillments/{fulfillment_id}/mark-as-delivered: + $ref: >- + paths/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered.yaml /admin/orders/{id}/fulfillments/{fulfillment_id}/shipments: $ref: paths/admin_orders_{id}_fulfillments_{fulfillment_id}_shipments.yaml /admin/orders/{id}/preview: diff --git a/www/apps/api-reference/specs/admin/paths/admin_api-keys.yaml b/www/apps/api-reference/specs/admin/paths/admin_api-keys.yaml index dd867df70da3b..0d148cf0a60ec 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_api-keys.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_api-keys.yaml @@ -116,10 +116,13 @@ get: description: Filter by the API key's type. required: false schema: - type: string - enum: - - secret - - publishable + oneOf: + - type: string + title: type + description: The api key's type. + - type: string + title: type + description: The api key's type. - name: created_at in: query description: Filter by the API key's creation date. diff --git a/www/apps/api-reference/specs/admin/paths/admin_customers_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_customers_{id}.yaml index c24e0823fcee9..40881101b0dbe 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_customers_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_customers_{id}.yaml @@ -246,4 +246,4 @@ delete: $ref: ../components/responses/invalid_request_error.yaml '500': $ref: ../components/responses/500_error.yaml - x-workflow: deleteCustomersWorkflow + x-workflow: removeCustomerAccountWorkflow diff --git a/www/apps/api-reference/specs/admin/paths/admin_exchanges_{id}_inbound_items_{action_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_exchanges_{id}_inbound_items_{action_id}.yaml index c2032f38b49cc..02cc9541b4079 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_exchanges_{id}_inbound_items_{action_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_exchanges_{id}_inbound_items_{action_id}.yaml @@ -88,32 +88,6 @@ delete: required: true schema: type: string - - name: expand - in: query - description: Comma-separated relations that should be expanded in the returned data. - required: false - schema: - type: string - title: expand - description: >- - Comma-separated relations that should be expanded in the returned - data. - - name: fields - in: query - description: >- - Comma-separated fields that should be included in the returned data. if - a field is prefixed with `+` it will be added to the default fields, - using `-` will remove it from the default fields. without prefix it will - replace the entire default fields. - required: false - schema: - type: string - title: fields - description: >- - Comma-separated fields that should be included in the returned data. - if a field is prefixed with `+` it will be added to the default - fields, using `-` will remove it from the default fields. without - prefix it will replace the entire default fields. security: - api_token: [] - cookie_auth: [] diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_archive.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_archive.yaml index bb0909904cb6b..cc5d7e77d7ee5 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_archive.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_archive.yaml @@ -44,7 +44,8 @@ post: content: application/json: schema: - $ref: ../components/schemas/AdminArchiveOrder.yaml + type: object + description: SUMMARY x-codeSamples: - lang: Shell label: cURL diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered.yaml new file mode 100644 index 0000000000000..cc5fd7da40a89 --- /dev/null +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered.yaml @@ -0,0 +1,80 @@ +post: + operationId: PostOrdersIdFulfillmentsFulfillment_idMarkAsDelivered + summary: Add Mark As Delivered to Order + description: Add a Mark As Delivered to a order + x-authenticated: true + parameters: + - name: id + in: path + description: The order's ID. + required: true + schema: + type: string + - name: fulfillment_id + in: path + description: The order's fulfillment id. + required: true + schema: + type: string + - name: expand + in: query + description: Comma-separated relations that should be expanded in the returned data. + required: false + schema: + type: string + title: expand + description: >- + Comma-separated relations that should be expanded in the returned + data. + - name: fields + in: query + description: |- + Comma-separated fields that should be included in the returned data. + * if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. + * without prefix it will replace the entire default fields. + required: false + schema: + type: string + title: fields + description: >- + Comma-separated fields that should be included in the returned data. + if a field is prefixed with `+` it will be added to the default + fields, using `-` will remove it from the default fields. without + prefix it will replace the entire default fields. + security: + - api_token: [] + - cookie_auth: [] + - jwt_token: [] + requestBody: + content: + application/json: + schema: + $ref: ../components/schemas/AdminMarkOrderFulfillmentDelivered.yaml + x-codeSamples: + - lang: Shell + label: cURL + source: + $ref: >- + ../code_samples/Shell/admin_orders_{id}_fulfillments_{fulfillment_id}_mark-as-delivered/post.sh + tags: + - Orders + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: ../components/schemas/AdminOrderResponse.yaml + '400': + $ref: ../components/responses/400_error.yaml + '401': + $ref: ../components/responses/unauthorized.yaml + '404': + $ref: ../components/responses/not_found_error.yaml + '409': + $ref: ../components/responses/invalid_state_error.yaml + '422': + $ref: ../components/responses/invalid_request_error.yaml + '500': + $ref: ../components/responses/500_error.yaml + x-workflow: markOrderFulfillmentAsDeliveredWorkflow diff --git a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_prices_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_prices_batch.yaml index ef71b0b817f06..8291f9266dc22 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_prices_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_prices_batch.yaml @@ -30,8 +30,8 @@ post: description: A price's details. required: - currency_code - - amount - variant_id + - amount properties: currency_code: type: string diff --git a/www/apps/api-reference/specs/admin/paths/admin_product-types.yaml b/www/apps/api-reference/specs/admin/paths/admin_product-types.yaml index 381f310e1f030..a4cfae0093c3c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_product-types.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_product-types.yaml @@ -606,7 +606,7 @@ post: content: application/json: schema: - $ref: ../components/schemas/AdminCreateProduct.yaml + $ref: ../components/schemas/AdminCreateProductType.yaml x-codeSamples: - lang: Shell label: cURL diff --git a/www/apps/api-reference/specs/admin/paths/admin_products.yaml b/www/apps/api-reference/specs/admin/paths/admin_products.yaml index f0a098bb857d0..c612a1b87442c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products.yaml @@ -673,6 +673,3014 @@ get: type: string title: collection_id description: A product collection's ID. + - name: variants + in: query + description: The product's variants. + required: false + schema: + type: object + description: The product's variants. + x-schemaName: AdminProductVariantParams + properties: + q: + type: string + title: q + description: The variant's q. + id: + oneOf: + - type: string + title: id + description: The variant's ID. + - type: array + description: The variant's ID. + items: + type: string + title: id + description: The id's ID. + manage_inventory: + type: boolean + title: manage_inventory + description: The variant's manage inventory. + allow_backorder: + type: boolean + title: allow_backorder + description: The variant's allow backorder. + created_at: + type: object + description: The variant's created at. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. Each object's + content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each object's + content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the conditions in this + parameter. + - type: object + description: >- + Filter by values not matching the conditions in this + parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. Each + object's content is the same type as the expected + query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each + object's content is the same type as the expected + query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the conditions in + this parameter. + - type: object + description: >- + Filter by values not matching the conditions in + this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: >- + Filter by values not equal to this + parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this + parameter. Useful for numbers and dates + only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal + to this parameter. Useful for numbers + and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this + parameter. Useful for numbers and dates + only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to + this parameter. Useful for numbers and + dates only. + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. + Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this + parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. + Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this + parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for strings + only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful + for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values + with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values + with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values + of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter + exists (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in + this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the conditions in + this parameter. + - type: object + description: >- + Filter by values not matching the conditions in + this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for strings + only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful + for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values + with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values + with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values + of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter + exists (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in + this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. Useful + for numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this + parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. Useful for + numbers and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this parameter. + Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful for + strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values with this + parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values with this + parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values of this + parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the values of + this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of this + parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter exists + (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in this + parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the conditions in this + parameter. + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. Useful for + numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this parameter. + Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. Useful for numbers + and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this parameter. Useful + for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful for strings + only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values with this + parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values with this + parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values of this + parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the values of this + parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter exists (not + `null`). + updated_at: + type: object + description: The variant's updated at. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. Each object's + content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each object's + content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the conditions in this + parameter. + - type: object + description: >- + Filter by values not matching the conditions in this + parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. Each + object's content is the same type as the expected + query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each + object's content is the same type as the expected + query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the conditions in + this parameter. + - type: object + description: >- + Filter by values not matching the conditions in + this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: >- + Filter by values not equal to this + parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this + parameter. Useful for numbers and dates + only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal + to this parameter. Useful for numbers + and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this + parameter. Useful for numbers and dates + only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to + this parameter. Useful for numbers and + dates only. + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. + Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this + parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. + Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this + parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for strings + only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful + for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values + with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values + with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values + of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter + exists (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in + this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the conditions in + this parameter. + - type: object + description: >- + Filter by values not matching the conditions in + this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for strings + only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful + for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values + with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values + with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values + of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter + exists (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in + this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. Useful + for numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this + parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. Useful for + numbers and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this parameter. + Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful for + strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values with this + parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values with this + parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values of this + parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the values of + this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of this + parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter exists + (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in this + parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the conditions in this + parameter. + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. Useful for + numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this parameter. + Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. Useful for numbers + and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this parameter. Useful + for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful for strings + only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values with this + parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values with this + parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values of this + parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the values of this + parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter exists (not + `null`). + deleted_at: + type: object + description: The variant's deleted at. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. Each object's + content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each object's + content is the same type as the expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the conditions in this + parameter. + - type: object + description: >- + Filter by values not matching the conditions in this + parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. Each + object's content is the same type as the expected + query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each + object's content is the same type as the expected + query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the conditions in + this parameter. + - type: object + description: >- + Filter by values not matching the conditions in + this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: Filter by values not equal to this parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + oneOf: + - type: string + title: $eq + description: Filter by an exact match. + - type: array + description: Filter by an exact match. + items: + type: string + title: $eq + description: Filter by an exact match. + $ne: + type: string + title: $ne + description: >- + Filter by values not equal to this + parameter. + $in: + type: array + description: Filter by values in this array. + items: + type: string + title: $in + description: Filter by values in this array. + $nin: + type: array + description: Filter by values not in this array. + items: + type: string + title: $nin + description: Filter by values not in this array. + $not: + oneOf: + - type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this + parameter. Useful for numbers and dates + only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal + to this parameter. Useful for numbers + and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this + parameter. Useful for numbers and dates + only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to + this parameter. Useful for numbers and + dates only. + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the + conditions in this parameter. + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. + Useful for numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this + parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. + Useful for numbers and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this + parameter. Useful for numbers and dates only. + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for strings + only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful + for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values + with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values + with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values + of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter + exists (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in + this parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the conditions in + this parameter. + - type: object + description: >- + Filter by values not matching the conditions in + this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. + Each object's content is the same type as the + expected query parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + properties: + $and: + type: array + description: >- + Join query parameters with an AND + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR + condition. Each object's content is the + same type as the expected query + parameters. + items: + type: object + title: $or + $eq: + type: array + description: Filter by an exact match. + items: {} + $ne: + oneOf: [] + $in: + type: array + description: Filter by values in this array. + items: {} + $nin: + type: array + description: Filter by values not in this array. + items: {} + $not: + oneOf: + - type: object + description: >- + Filter by values not matching the + conditions in this parameter. + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for + strings only. + $re: + type: string + title: $re + description: >- + Apply a regex filter. Useful for strings + only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. + Useful for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping + values with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping + values with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the + values of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of + this parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this + parameter exists (not `null`). + - type: array + description: >- + Filter by values not matching the + conditions in this parameter. + items: {} + $gt: + oneOf: [] + $gte: + oneOf: [] + $lt: + oneOf: [] + $lte: + oneOf: [] + $like: + type: string + title: $like + description: >- + Apply a `like` filter. Useful for strings + only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful + for strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values + with this parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values + with this parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values + of this parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the + values of this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of + this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter + exists (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in + this parameter. + items: {} + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. Useful + for numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this + parameter. Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. Useful for + numbers and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this parameter. + Useful for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful for + strings only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values with this + parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values with this + parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values of this + parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the values of + this parameter. + $contained: + type: array + description: >- + Filter arrays that contain all values of this + parameter. + items: + type: string + title: $contained + description: >- + Filter arrays that contain all values of this + parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter exists + (not `null`). + - type: array + description: >- + Filter by values not matching the conditions in this + parameter. + items: + type: string + title: $not + description: >- + Filter by values not matching the conditions in this + parameter. + $gt: + type: string + title: $gt + description: >- + Filter by values greater than this parameter. Useful for + numbers and dates only. + $gte: + type: string + title: $gte + description: >- + Filter by values greater than or equal to this parameter. + Useful for numbers and dates only. + $lt: + type: string + title: $lt + description: >- + Filter by values less than this parameter. Useful for numbers + and dates only. + $lte: + type: string + title: $lte + description: >- + Filter by values less than or equal to this parameter. Useful + for numbers and dates only. + $like: + type: string + title: $like + description: Apply a `like` filter. Useful for strings only. + $re: + type: string + title: $re + description: Apply a regex filter. Useful for strings only. + $ilike: + type: string + title: $ilike + description: >- + Apply a case-insensitive `like` filter. Useful for strings + only. + $fulltext: + type: string + title: $fulltext + description: Filter to apply on full-text properties. + $overlap: + type: array + description: >- + Filter arrays that have overlapping values with this + parameter. + items: + type: string + title: $overlap + description: >- + Filter arrays that have overlapping values with this + parameter. + $contains: + type: array + description: >- + Filter arrays that contain some of the values of this + parameter. + items: + type: string + title: $contains + description: >- + Filter arrays that contain some of the values of this + parameter. + $contained: + type: array + description: Filter arrays that contain all values of this parameter. + items: + type: string + title: $contained + description: Filter arrays that contain all values of this parameter. + $exists: + type: boolean + title: $exists + description: >- + Filter by whether a value for this parameter exists (not + `null`). + limit: + type: number + title: limit + description: Limit the number of items returned in the list. + offset: + type: number + title: offset + description: The number of items to skip when retrieving a list. + order: + type: string + title: order + description: >- + The field to sort the data by. By default, the sort order is + ascending. To change the order to descending, prefix the field + name with `-`. + fields: + type: string + title: fields + description: >- + Comma-separated fields that should be included in the returned + data. if a field is prefixed with `+` it will be added to the + default fields, using `-` will remove it from the default fields. + without prefix it will replace the entire default fields. + $and: + type: array + description: >- + Join query parameters with an AND condition. Each object's content + is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each object's content + is the same type as the expected query parameters. + items: + type: object + title: $or security: - api_token: [] - cookie_auth: [] diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_export.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_export.yaml index f734a31486da6..2a69236dde26c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_export.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_export.yaml @@ -71,3 +71,8 @@ post: '500': $ref: ../components/responses/500_error.yaml x-workflow: exportProductsWorkflow + requestBody: + content: + application/json: + schema: + $ref: ../components/schemas/AdminExportProductRequest.yaml diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_inventory-items_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_inventory-items_batch.yaml index c989c00f32fef..1041e8b9a867a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_inventory-items_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_inventory-items_batch.yaml @@ -36,9 +36,9 @@ post: The associations to create between a product variant and an inventory item. required: - - required_quantity - - inventory_item_id - variant_id + - inventory_item_id + - required_quantity properties: required_quantity: type: number @@ -63,9 +63,9 @@ post: type: object description: Update a product variant's association with an inventory item. required: - - required_quantity - - inventory_item_id - variant_id + - inventory_item_id + - required_quantity properties: required_quantity: type: number @@ -90,8 +90,8 @@ post: type: object description: Delete a product variant's association with an inventory item. required: - - inventory_item_id - variant_id + - inventory_item_id properties: inventory_item_id: type: string diff --git a/www/apps/api-reference/specs/admin/paths/admin_promotions_rule-attribute-options_{rule_type}.yaml b/www/apps/api-reference/specs/admin/paths/admin_promotions_rule-attribute-options_{rule_type}.yaml index c89f2dd1325c4..c240da2171914 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_promotions_rule-attribute-options_{rule_type}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_promotions_rule-attribute-options_{rule_type}.yaml @@ -1,10 +1,10 @@ get: operationId: GetPromotionsRuleAttributeOptionsRule_type summary: List Rule Attribute Options of a Rule Type - x-sidebar-summary: List Rule Attribute Options + x-sidebar-summary: List Potential Rule Attributes description: > - Retrieve a list of attributes for the promotion and application method types - specified in the query parameters. + Retrieve a list of potential rule attributes for the promotion and + application method types specified in the query parameters. Only the attributes of the rule type specified in the path parameter are retrieved: @@ -14,8 +14,11 @@ get: - If `rule_type` is `target-rules`, the target rules' attributes of the - application method's type are retrieved. - If `rule_type` is `buy-rules`, - the buy rules' attributes of the application method's type are retrieved. + application method's type are retrieved. + + + - If `rule_type` is `buy-rules`, the buy rules' attributes of the + application method's type are retrieved. x-authenticated: true parameters: - name: rule_type diff --git a/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_buy-rules_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_buy-rules_batch.yaml index 6a69a1a091f08..450cc157943e0 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_buy-rules_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_buy-rules_batch.yaml @@ -57,9 +57,9 @@ post: type: object description: A buy rule's details. required: + - values - operator - attribute - - values properties: operator: type: string @@ -90,15 +90,33 @@ post: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The create's values. - type: array - description: The allowed attribute values. + description: The create's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The create's values. + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The create's values. update: type: array description: The buy rules to update. @@ -106,27 +124,47 @@ post: type: object description: The properties to update in a buy rule. required: - - id - values + - id properties: id: type: string title: id description: The buy rule's ID. operator: - type: string + oneOf: + - type: string + description: The update's operator. + enum: + - GTE + - type: string + description: The update's operator. + enum: + - LTE + - type: string + description: The update's operator. + enum: + - GT + - type: string + description: The update's operator. + enum: + - LT + - type: string + description: The update's operator. + enum: + - EQ + - type: string + description: The update's operator. + enum: + - NE + - type: string + description: The update's operator. + enum: + - IN description: >- The operator used to check whether the buy rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - enum: - - gte - - lte - - gt - - lt - - eq - - ne - - in description: type: string title: description @@ -142,15 +180,33 @@ post: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The update's values. - type: array - description: The allowed attribute values. + description: The update's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The update's values. delete: type: array description: The buy rules to delete. diff --git a/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_rules_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_rules_batch.yaml index d44381ccecf6e..8412ad09717e7 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_rules_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_rules_batch.yaml @@ -55,9 +55,9 @@ post: type: object description: A rule's details. required: + - values - operator - attribute - - values properties: operator: type: string @@ -88,15 +88,33 @@ post: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The create's values. - type: array - description: The allowed attribute values. + description: The create's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The create's values. + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The create's values. update: type: array description: The rules to update. @@ -104,27 +122,47 @@ post: type: object description: The properties to update in a rule. required: - - id - values + - id properties: id: type: string title: id description: The rule's ID. operator: - type: string + oneOf: + - type: string + description: The update's operator. + enum: + - GTE + - type: string + description: The update's operator. + enum: + - LTE + - type: string + description: The update's operator. + enum: + - GT + - type: string + description: The update's operator. + enum: + - LT + - type: string + description: The update's operator. + enum: + - EQ + - type: string + description: The update's operator. + enum: + - NE + - type: string + description: The update's operator. + enum: + - IN description: >- The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - enum: - - gte - - lte - - gt - - lt - - eq - - ne - - in description: type: string title: description @@ -140,15 +178,33 @@ post: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The update's values. - type: array - description: The allowed attribute values. + description: The update's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The update's values. delete: type: array description: The rules to delete. diff --git a/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_target-rules_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_target-rules_batch.yaml index 5b3ce4053d743..c51dfd7108182 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_target-rules_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_promotions_{id}_target-rules_batch.yaml @@ -55,9 +55,9 @@ post: type: object description: A target rule's details. required: + - values - operator - attribute - - values properties: operator: type: string @@ -89,15 +89,33 @@ post: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The create's values. - type: array - description: The allowed attribute values. + description: The create's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The create's values. + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The create's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The create's values. update: type: array description: The target rules to update. @@ -105,28 +123,48 @@ post: type: object description: The properties to update in a target rule. required: - - id - values + - id properties: id: type: string title: id description: The target rule's ID. operator: - type: string + oneOf: + - type: string + description: The update's operator. + enum: + - GTE + - type: string + description: The update's operator. + enum: + - LTE + - type: string + description: The update's operator. + enum: + - GT + - type: string + description: The update's operator. + enum: + - LT + - type: string + description: The update's operator. + enum: + - EQ + - type: string + description: The update's operator. + enum: + - NE + - type: string + description: The update's operator. + enum: + - IN description: >- The operator used to check whether the target rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - enum: - - gte - - lte - - gt - - lt - - eq - - ne - - in description: type: string title: description @@ -142,15 +180,33 @@ post: oneOf: - type: string title: values - description: The attribute's value. - example: prod_123 + description: The update's values. - type: array - description: The allowed attribute values. + description: The update's values. items: type: string title: values - description: An attribute value. - example: prod_123 + description: The value's values. + - allOf: + - type: string + title: values + description: The update's values. + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - allOf: + - type: array + description: The update's values. + items: + type: string + title: values + description: The value's values. + - type: string + title: values + description: The update's values. delete: type: array description: The target rules to delete. diff --git a/www/apps/api-reference/specs/admin/paths/admin_reservations.yaml b/www/apps/api-reference/specs/admin/paths/admin_reservations.yaml index b43eb4502a737..9dd209377327a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_reservations.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_reservations.yaml @@ -656,9 +656,9 @@ get: properties: reservations: type: array - description: The list of reservations`. + description: The list of reservations. items: - $ref: ../components/schemas/ReservationResponse.yaml + $ref: ../components/schemas/AdminReservation.yaml '400': $ref: ../components/responses/400_error.yaml '401': diff --git a/www/apps/api-reference/specs/admin/paths/admin_return-reasons.yaml b/www/apps/api-reference/specs/admin/paths/admin_return-reasons.yaml index d8a5bb3dc8324..f0cf9761aca1b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_return-reasons.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_return-reasons.yaml @@ -664,7 +664,7 @@ post: content: application/json: schema: - $ref: ../components/schemas/CreateOrderReturnReason.yaml + $ref: ../components/schemas/AdminCreateReturnReason.yaml x-codeSamples: - lang: Shell label: cURL diff --git a/www/apps/api-reference/specs/admin/paths/admin_return-reasons_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_return-reasons_{id}.yaml index f62004d79ebd6..33f8d1e238b00 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_return-reasons_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_return-reasons_{id}.yaml @@ -114,7 +114,7 @@ post: content: application/json: schema: - $ref: ../components/schemas/UpdateOrderReturnReason.yaml + $ref: ../components/schemas/AdminUpdateReturnReason.yaml x-codeSamples: - lang: Shell label: cURL diff --git a/www/apps/api-reference/specs/admin/paths/admin_shipping-options.yaml b/www/apps/api-reference/specs/admin/paths/admin_shipping-options.yaml index 5b8a8a51aca35..3cc3f65d3eb51 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_shipping-options.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_shipping-options.yaml @@ -707,7 +707,7 @@ post: content: application/json: schema: - type: object + $ref: ../components/schemas/AdminCreateShippingOption.yaml x-codeSamples: - lang: Shell label: cURL diff --git a/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}.yaml index 3405df4b55aed..d080af68bfae2 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}.yaml @@ -60,15 +60,20 @@ post: url: >- https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property price_type: - type: string + oneOf: + - type: string + description: The shipping option's price type. + enum: + - CALCULATED + - type: string + description: The shipping option's price type. + enum: + - FLAT description: > The type of the shipping option's price. If `calculated`, its price is retrieved by the associated fulfillment provider during checkout. If `flat`, its price is set in the `prices` property. - enum: - - calculated - - flat provider_id: type: string title: provider_id @@ -83,9 +88,9 @@ post: type: object description: The shipping option's type. required: - - label - - description - code + - description + - label properties: label: type: string diff --git a/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}_rules_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}_rules_batch.yaml index c1ac56daf29d5..9eff22aa133b8 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}_rules_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_shipping-options_{id}_rules_batch.yaml @@ -55,9 +55,9 @@ post: type: object description: A shipping option's details. required: + - value - operator - attribute - - value properties: operator: type: string @@ -80,15 +80,33 @@ post: oneOf: - type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The create's value. - type: array - description: Values of the attribute that enable this rule. + description: The create's value. items: type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The value's details. + - allOf: + - type: string + title: value + description: The create's value. + - type: array + description: The create's value. + items: + type: string + title: value + description: The value's details. + - allOf: + - type: array + description: The create's value. + items: + type: string + title: value + description: The value's details. + - type: string + title: value + description: The create's value. update: type: array description: The shipping option rules to update. @@ -96,10 +114,10 @@ post: type: object description: The properties to update in the shipping option rule. required: + - value - id - operator - attribute - - value properties: id: type: string @@ -126,15 +144,33 @@ post: oneOf: - type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The update's value. - type: array - description: Values of the attribute that enable this rule. + description: The update's value. items: type: string title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + description: The value's details. + - allOf: + - type: string + title: value + description: The update's value. + - type: array + description: The update's value. + items: + type: string + title: value + description: The value's details. + - allOf: + - type: array + description: The update's value. + items: + type: string + title: value + description: The value's details. + - type: string + title: value + description: The update's value. delete: type: array description: The shipping option rules to delete. diff --git a/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}_fulfillment-sets.yaml b/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}_fulfillment-sets.yaml index 06f52381f273f..8a82cf3947075 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}_fulfillment-sets.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}_fulfillment-sets.yaml @@ -48,8 +48,8 @@ post: type: object description: The fulfillment set to create. required: - - name - type + - name properties: name: type: string diff --git a/www/apps/api-reference/specs/admin/paths/admin_tax-rates.yaml b/www/apps/api-reference/specs/admin/paths/admin_tax-rates.yaml index ba36270fe5560..d024f8fc541e4 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_tax-rates.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_tax-rates.yaml @@ -147,10 +147,13 @@ get: required: false description: Filter by whether the tax rate is a default in its tax region. schema: - type: string - enum: - - 'true' - - 'false' + oneOf: + - type: string + title: is_default + description: The tax rate's is default. + - type: string + title: is_default + description: The tax rate's is default. - name: created_at in: query description: Filter by a tax rate's creation date. diff --git a/www/apps/api-reference/specs/admin/paths/admin_uploads.yaml b/www/apps/api-reference/specs/admin/paths/admin_uploads.yaml index 5b95840d16d9a..f8362960955da 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_uploads.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_uploads.yaml @@ -13,17 +13,17 @@ post: schema: oneOf: - type: object - description: The files to upload. + description: SUMMARY required: - files properties: files: type: array - description: The files to upload. + description: The upload's files. items: oneOf: - type: object - description: A file's details. + description: The file's files. required: - name - content @@ -35,9 +35,23 @@ post: content: type: string title: content - description: The file's base64 content. - - $ref: ../components/schemas/File.yaml - - $ref: ../components/schemas/FileList.yaml + description: The file's content. + - type: object + description: A File to upload. + externalDocs: + url: >- + https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: files + - type: array + description: list of files to upload. + items: + type: object + description: A File to upload. + externalDocs: + url: https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: FileList description: The files to upload. x-codeSamples: - lang: Shell diff --git a/www/apps/api-reference/specs/admin/paths/admin_users_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_users_{id}.yaml index b51d726fe0242..b61c0fbb13517 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_users_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_users_{id}.yaml @@ -172,4 +172,4 @@ delete: $ref: ../components/responses/invalid_request_error.yaml '500': $ref: ../components/responses/500_error.yaml - x-workflow: deleteUsersWorkflow + x-workflow: removeUserAccountWorkflow diff --git a/www/apps/api-reference/specs/admin/paths/admin_workflows-executions_{workflow_id}_run.yaml b/www/apps/api-reference/specs/admin/paths/admin_workflows-executions_{workflow_id}_run.yaml index a95e0cc9ba80a..2b9ced71972f7 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_workflows-executions_{workflow_id}_run.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_workflows-executions_{workflow_id}_run.yaml @@ -44,6 +44,8 @@ post: required: - workflowId - transactionId + - hasFinished + - hasFailed properties: workflowId: type: string @@ -56,6 +58,18 @@ post: later to track the workflow execution's progress or succeed / fail its steps. title: transactionId + parentStepIdempotencyKey: + type: string + title: parentStepIdempotencyKey + description: The acknowledgement's parentstepidempotencykey. + hasFinished: + type: boolean + title: hasFinished + description: The acknowledgement's hasfinished. + hasFailed: + type: boolean + title: hasFailed + description: The acknowledgement's hasfailed. '400': $ref: ../components/responses/400_error.yaml '401': diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminApplicationMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminApplicationMethod.yaml new file mode 100644 index 0000000000000..1849ad17e6a03 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminApplicationMethod.yaml @@ -0,0 +1,113 @@ +type: object +description: The promotion's application method. +x-schemaName: AdminApplicationMethod +required: + - id +properties: + promotion: + type: object + description: The application method's promotion. + x-schemaName: AdminPromotion + required: + - id + properties: + application_method: + type: object + description: The promotion's application method. + x-schemaName: AdminApplicationMethod + rules: + type: array + description: The promotion's rules. + items: + type: object + description: The rule's rules. + x-schemaName: AdminPromotionRule + id: + type: string + title: id + description: The promotion's ID. + code: + type: string + title: code + description: The promotion's code. + type: + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. + is_automatic: + type: boolean + title: is_automatic + description: The promotion's is automatic. + campaign_id: + type: string + title: campaign_id + description: The promotion's campaign id. + campaign: + type: object + description: The promotion's campaign. + x-schemaName: AdminCampaign + target_rules: + type: array + description: The application method's target rules. + items: + $ref: ./AdminPromotionRule.yaml + buy_rules: + type: array + description: The application method's buy rules. + items: + $ref: ./AdminPromotionRule.yaml + id: + type: string + title: id + description: The application method's ID. + type: + oneOf: + - type: string + title: type + description: The application method's type. + - type: string + title: type + description: The application method's type. + target_type: + oneOf: + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + allocation: + oneOf: + - type: string + title: allocation + description: The application method's allocation. + - type: string + title: allocation + description: The application method's allocation. + value: + type: number + title: value + description: The application method's value. + currency_code: + type: string + title: currency_code + description: The application method's currency code. + max_quantity: + type: number + title: max_quantity + description: The application method's max quantity. + buy_rules_min_quantity: + type: number + title: buy_rules_min_quantity + description: The application method's buy rules min quantity. + apply_to_quantity: + type: number + title: apply_to_quantity + description: The application method's apply to quantity. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminArchiveOrder.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminArchiveOrder.yaml deleted file mode 100644 index 72b7d36198259..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/AdminArchiveOrder.yaml +++ /dev/null @@ -1,10 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: AdminArchiveOrder -required: - - order_id -properties: - order_id: - type: string - title: order_id - description: The order's order id. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminClaim.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminClaim.yaml index 21f60500a4924..89c8b61111f25 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminClaim.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminClaim.yaml @@ -2,44 +2,18 @@ type: object description: The claim's details. x-schemaName: AdminClaim required: - - order_id - - claim_items - - additional_items - - currency_code + - order + - return - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - type + - order_id + - display_id + - order_version - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - additional_items + - claim_items properties: id: type: string @@ -60,7 +34,7 @@ properties: items: $ref: ./BaseClaimItem.yaml return: - $ref: ./Return.yaml + $ref: ./AdminReturn.yaml return_id: type: string title: return_id @@ -73,76 +47,15 @@ properties: type: number title: refund_amount description: The amount to be refunded. - currency_code: - type: string - title: currency_code - description: The claim's currency code. - region_id: - type: string - title: region_id - description: The ID of the region associated with the claim. - customer_id: - type: string - title: customer_id - description: The ID of the customer associated with the claim's order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the claim's order is created in. - email: - type: string - title: email - description: The email associated with the claim's order. - format: email display_id: type: number title: display_id description: The claim's display ID. - shipping_address: - $ref: ./BaseOrderAddress.yaml - billing_address: - $ref: ./BaseOrderAddress.yaml shipping_methods: type: array description: The claim's shipping methods. items: - $ref: ./BaseOrderShippingMethod.yaml - payment_collections: - type: array - description: The claim's payment collections. - items: - $ref: ./BasePaymentCollection.yaml - payment_status: - type: string - description: The claim's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The claim's fulfillments. - items: - $ref: ./BaseOrderFulfillment.yaml - fulfillment_status: - type: string - description: The claim's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered + $ref: ./AdminOrderShippingMethod.yaml transactions: type: array description: The claim's transactions. @@ -152,8 +65,6 @@ properties: description: Learn more about transactions of orders and associated models. items: $ref: ./BaseOrderTransaction.yaml - summary: - $ref: ./BaseOrderSummary.yaml metadata: type: object description: The claim's metadata, used to store custom key-value pairs. @@ -167,91 +78,33 @@ properties: format: date-time title: updated_at description: The claim's update date. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the associated order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the associated order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The tax total of the original items in the associated order. - item_total: - type: number - title: item_total - description: The total of the claim's items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the claim's items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the claim's items. - original_total: - type: number - title: original_total - description: The associated order's original total. - original_subtotal: - type: number - title: original_subtotal - description: The associated order's original subtotal. - original_tax_total: - type: number - title: original_tax_total - description: The associated order's original tax total. - total: - type: number - title: total - description: The associated order's total. - subtotal: - type: number - title: subtotal - description: The claim's subtotal. - tax_total: - type: number - title: tax_total - description: The claim's tax total. - discount_total: - type: number - title: discount_total - description: The claim's discount total. - discount_tax_total: - type: number - title: discount_tax_total - description: The claim's discount tax total. - gift_card_total: - type: number - title: gift_card_total - description: The claim's gift card total. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The claim's gift card tax total. - shipping_total: - type: number - title: shipping_total - description: The claim's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The claim's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The claim's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The associated order's original shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The associated order's original shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The associated order's original shipping tax total. + order: + type: string + title: order + description: >- + The field to sort the data by. By default, the sort order is ascending. To + change the order to descending, prefix the field name with `-`. + type: + type: string + description: The claim's type. + enum: + - replace + - refund + order_version: + type: string + title: order_version + description: The claim's order version. + created_by: + type: string + title: created_by + description: The claim's created by. + canceled_at: + type: string + title: canceled_at + description: The claim's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The claim's deleted at. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminClaimOrderResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminClaimOrderResponse.yaml index ea206926d5654..94991816b3ebc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminClaimOrderResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminClaimOrderResponse.yaml @@ -6,6 +6,8 @@ required: - claim properties: order: - $ref: ./Order.yaml + type: string + title: order + description: The order change's order. claim: $ref: ./AdminClaim.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminClaimPreviewResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminClaimPreviewResponse.yaml index d3d5cf085c60e..8fdefc68186a7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminClaimPreviewResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminClaimPreviewResponse.yaml @@ -8,6 +8,6 @@ required: - claim properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml claim: $ref: ./AdminClaim.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminClaimRequestResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminClaimRequestResponse.yaml index eb463459db71e..c49a9d5d9e284 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminClaimRequestResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminClaimRequestResponse.yaml @@ -11,6 +11,6 @@ properties: return: $ref: ./AdminReturn.yaml order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml claim: $ref: ./AdminClaim.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminClaimReturnPreviewResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminClaimReturnPreviewResponse.yaml index f91f77fa23062..9688761b29659 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminClaimReturnPreviewResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminClaimReturnPreviewResponse.yaml @@ -8,6 +8,6 @@ required: - return properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml return: $ref: ./AdminReturn.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateApplicationMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateApplicationMethod.yaml deleted file mode 100644 index 5cbb99276e849..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateApplicationMethod.yaml +++ /dev/null @@ -1,78 +0,0 @@ -type: object -description: The application method's details. -x-schemaName: AdminCreateApplicationMethod -required: - - value - - type - - target_type -properties: - description: - type: string - title: description - description: The application method's description. - value: - type: number - title: value - description: >- - The discounted amount applied by the associated promotion based on the - `type`. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: >- - The max quantity allowed in the cart for the associated promotion to be - applied. - type: - type: string - description: >- - The type of the application method indicating how the associated promotion - is applied. - enum: - - fixed - - percentage - target_type: - type: string - description: >- - The target type of the application method indicating whether the - associated promotion is applied to the cart's items, shipping methods, or - the whole order. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: >- - The allocation value that indicates whether the associated promotion is - applied on each item in a cart or split between the items in the cart. - enum: - - each - - across - target_rules: - type: array - description: The application method's target rules. - items: - $ref: ./AdminCreatePromotionRule.yaml - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: ./AdminCreatePromotionRule.yaml - apply_to_quantity: - type: number - title: apply_to_quantity - description: >- - The quantity that results from matching the `buyget` promotion's - condition. For example, if the promotion is a "Buy 2 shirts get 1 free", - the value f this attribute is `1`. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: >- - The minimum quantity required for a `buyget` promotion to be applied. For - example, if the promotion is a "Buy 2 shirts get 1 free", the value of - this attribute is `2`. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateFulfillment.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateFulfillment.yaml index 0dd456e29b17e..79e31f7d86e6c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateFulfillment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateFulfillment.yaml @@ -2,15 +2,14 @@ type: object description: The filfillment's details. x-schemaName: AdminCreateFulfillment required: + - data + - order_id + - metadata + - items - location_id - provider_id - delivery_address - - items - labels - - order - - order_id - - data - - metadata properties: location_id: type: string @@ -75,8 +74,8 @@ properties: description: An item to fulfill. required: - title - - sku - quantity + - sku - barcode properties: title: diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreatePriceList.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreatePriceList.yaml index ff78bb5483e55..4e048abb66759 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreatePriceList.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreatePriceList.yaml @@ -24,17 +24,27 @@ properties: description: The date and time the price list ends at. format: date-time status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. @@ -48,8 +58,8 @@ properties: description: A price's details. required: - currency_code - - amount - variant_id + - amount properties: currency_code: type: string diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProduct.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProduct.yaml index d4cece0e332de..362b8eae6e1fc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProduct.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProduct.yaml @@ -46,13 +46,20 @@ properties: title: handle description: The product's handle. status: - type: string + oneOf: + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. description: The product's status. - enum: - - draft - - proposed - - published - - rejected type_id: type: string title: type_id diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductType.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductType.yaml new file mode 100644 index 0000000000000..fa411cf780dfa --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductType.yaml @@ -0,0 +1,13 @@ +type: object +description: The product's details. +x-schemaName: AdminCreateProductType +required: + - value +properties: + metadata: + type: object + description: The product's metadata, used to store custom key-value pairs. + value: + type: string + title: value + description: The product type's value. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariant.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariant.yaml index 874a1015bb353..f4ac3e13c2bb0 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariant.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariant.yaml @@ -86,3 +86,8 @@ properties: the option's value. example: Color: Black + inventory_items: + type: array + description: The variant's inventory items. + items: + $ref: ./AdminCreateProductVariantInventoryKit.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariantInventoryKit.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariantInventoryKit.yaml new file mode 100644 index 0000000000000..51d9f00f560c5 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariantInventoryKit.yaml @@ -0,0 +1,14 @@ +type: object +description: The inventory item's inventory items. +x-schemaName: AdminCreateProductVariantInventoryKit +required: + - inventory_item_id +properties: + inventory_item_id: + type: string + title: inventory_item_id + description: The inventory item's inventory item id. + required_quantity: + type: number + title: required_quantity + description: The inventory item's required quantity. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariantPrice.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariantPrice.yaml index e543b4f377602..c876e32e65ca4 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariantPrice.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateProductVariantPrice.yaml @@ -30,3 +30,10 @@ properties: description: The price's rules. example: region_id: reg_123 + properties: + region_id: + type: string + title: region_id + description: The rule's region id. + required: + - region_id diff --git a/www/apps/api-reference/specs/admin/components/schemas/CreateOrderReturnReason.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateReturnReason.yaml similarity index 93% rename from www/apps/api-reference/specs/admin/components/schemas/CreateOrderReturnReason.yaml rename to www/apps/api-reference/specs/store/components/schemas/AdminCreateReturnReason.yaml index efbb641c2ff68..851e8e9f48d2d 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/CreateOrderReturnReason.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateReturnReason.yaml @@ -1,6 +1,6 @@ type: object description: SUMMARY -x-schemaName: CreateOrderReturnReason +x-schemaName: AdminCreateReturnReason required: - value - label diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateShippingOption.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateShippingOption.yaml index c3e9d1c9b2d8d..76e37a2dd8036 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateShippingOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateShippingOption.yaml @@ -1,92 +1,20 @@ type: object -description: The shipping option's details. +description: The shipping option's type. x-schemaName: AdminCreateShippingOption required: - - name - - service_zone_id - - shipping_profile_id - - price_type - - provider_id - - type - - prices + - label + - description + - code properties: - name: + label: type: string - title: name - description: The shipping option's name. - service_zone_id: + title: label + description: The type's label. + description: type: string - title: service_zone_id - description: The ID of the service zone this shipping option belongs to. - shipping_profile_id: + title: description + description: The type's description. + code: type: string - title: shipping_profile_id - description: The ID of the shipping profile this shipping option belongs to. - data: - type: object - description: >- - Any data necessary for fulfillment providers to handle shipping methods - and fulfillments of this shipping option. - externalDocs: - url: >- - https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property - description: Learn more about the data property. - price_type: - type: string - description: > - The shipping option price's type. If `flat`, it means the option has a - fixed price set in the `prices` property. `calculated` means that the - shipping option's price is calculated during checkout. - enum: - - flat - - calculated - provider_id: - type: string - title: provider_id - description: >- - The ID of the fulfillment provider used to handle this shipping option and - its associated methods and fulfillments. - type: - $ref: ./AdminCreateShippingOption.yaml - prices: - type: array - description: >- - The shipping option's prices. If `price_type` is `calculated`, pass an - empty array for this property. - items: - oneOf: - - type: object - description: The price for a currency code. - x-schemaName: AdminCreateShippingOptionPriceWithCurrency - required: - - currency_code - - amount - properties: - currency_code: - type: string - title: currency_code - description: The price's currency code. - amount: - type: number - title: amount - description: The price's amount. - - type: object - description: The price in a region. - x-schemaName: AdminCreateShippingOptionPriceWithRegion - required: - - region_id - - amount - properties: - region_id: - type: string - title: region_id - description: The ID of the region this price is used in. - amount: - type: number - title: amount - description: The price's amount. - rules: - type: array - description: The shipping option's rules. - items: - $ref: ./AdminCreateShippingOptionRule.yaml + title: code + description: The type's code. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateShippingOptionRule.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateShippingOptionRule.yaml deleted file mode 100644 index 05df606241c91..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateShippingOptionRule.yaml +++ /dev/null @@ -1,38 +0,0 @@ -type: object -description: The details of the shipping option rule. -x-schemaName: AdminCreateShippingOptionRule -required: - - operator - - attribute - - value -properties: - operator: - type: string - description: The operator used to check whether a rule applies. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte - - nin - attribute: - type: string - title: attribute - description: The name of a property or table that the rule applies to. - example: customer_group - value: - oneOf: - - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 - - type: array - description: Values of the attribute that enable this rule. - items: - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateVariantInventoryItem.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateVariantInventoryItem.yaml index 23e84a8328b64..2de3fc7b23be7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateVariantInventoryItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateVariantInventoryItem.yaml @@ -2,8 +2,8 @@ type: object description: The details of the variant-inventory item association. x-schemaName: AdminCreateVariantInventoryItem required: - - required_quantity - inventory_item_id + - required_quantity properties: required_quantity: type: number diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml index f7539f38b9e8f..d11dc80830f8c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCreateWorkflowsAsyncResponse.yaml @@ -18,8 +18,13 @@ properties: compensate_input: description: Sets the compensation function's input. It accepts any response. action: - type: string + oneOf: + - type: string + description: The workflows execution's action. + enum: + - INVOKE + - type: string + description: The workflows execution's action. + enum: + - COMPENSATE description: Whether to invoke or compensate the step. - enum: - - invoke - - compensate diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminCurrency.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminCurrency.yaml index 984e1d51cf090..887204ea4dcf7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminCurrency.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminCurrency.yaml @@ -8,7 +8,6 @@ required: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminExchange.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminExchange.yaml index e66c9d6ec8124..1d24996743a2a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminExchange.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminExchange.yaml @@ -2,44 +2,14 @@ type: object description: The exchange's details. x-schemaName: AdminExchange required: - - order_id - - return_items - - additional_items - - currency_code - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - order_id - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - deleted_at + - additional_items + - return_items properties: order_id: type: string @@ -67,88 +37,24 @@ properties: be refunded. If positive, additional payment is required from the customer. return: - description: the return associated with the exchange. $ref: ./AdminReturn.yaml return_id: type: string title: return_id description: The ID of the associated exchange. - currency_code: - type: string - title: currency_code - description: The exchange's currency code. id: type: string title: id description: The exchange's ID. - region_id: - type: string - title: region_id - description: The ID of the associated order's region. - customer_id: - type: string - title: customer_id - description: The ID of the customer that placed the order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the associated order belongs to. - email: - type: string - title: email - description: The email used when placing the order. - format: email display_id: - type: number + type: string title: display_id description: The exchange's display ID. - shipping_address: - description: The shipping address to send new items to. - $ref: ./BaseOrderAddress.yaml - billing_address: - description: The customer's billing address. - $ref: ./BaseOrderAddress.yaml shipping_methods: type: array description: The shipping methods used to send the new (outbound) items. items: $ref: ./BaseOrderShippingMethod.yaml - payment_collections: - type: array - description: The exchange's payment collections. - items: - $ref: ./BasePaymentCollection.yaml - payment_status: - type: string - description: The exchange's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The exchange's fulfillments of new (outbound) items. - items: - $ref: ./BaseOrderFulfillment.yaml - fulfillment_status: - type: string - description: The exchange's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered transactions: type: array description: The exchange's transactions. @@ -157,9 +63,6 @@ properties: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions items: $ref: ./BaseOrderTransaction.yaml - summary: - description: The totals summary of the exchange. - $ref: ./BaseOrderSummary.yaml metadata: type: object description: The exchange's metadata, can hold custom key-value pairs. @@ -173,91 +76,31 @@ properties: format: date-time title: updated_at description: The date that the exchange was updated. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The total tax of the original items in the order. - item_total: - type: number - title: item_total - description: The total of the exchange's new items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the exchange's new items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the exchange's new items. - original_total: - type: number - title: original_total - description: The total of the order. - original_subtotal: - type: number - title: original_subtotal - description: The subtotal of the order. - original_tax_total: - type: number - title: original_tax_total - description: The tax total of the order. - total: - type: number - title: total - description: The total of the exchange. - subtotal: - type: number - title: subtotal - description: The subtotal of the exchange. - tax_total: - type: number - title: tax_total - description: The tax total of the exchange. - discount_total: - type: number - title: discount_total - description: The discount total of the exchange. - discount_tax_total: - type: number - title: discount_tax_total - description: The total taxes on discount of the exchange. - gift_card_total: - type: number - title: gift_card_total - description: The gift cards total of the exchange. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The total taxes on the gift card of the exchange. - shipping_total: - type: number - title: shipping_total - description: The exchange's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The exchange's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The exchange's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The order's shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The order's shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The order's shipping tax total. + order_version: + type: string + title: order_version + description: The exchange's order version. + created_by: + type: string + title: created_by + description: The exchange's created by. + canceled_at: + type: string + title: canceled_at + description: The exchange's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The exchange's deleted at. + order: + type: string + title: order + description: >- + The field to sort the data by. By default, the sort order is ascending. To + change the order to descending, prefix the field name with `-`. + allow_backorder: + type: boolean + title: allow_backorder + description: The exchange's allow backorder. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminExchangeOrderResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminExchangeOrderResponse.yaml index 03bc03d999ba2..6fff213887d58 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminExchangeOrderResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminExchangeOrderResponse.yaml @@ -6,7 +6,8 @@ required: - exchange properties: order: - description: The details of the associated order. - $ref: ./Order.yaml + type: string + title: order + description: The order change's order. exchange: $ref: ./AdminExchange.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminExchangePreviewResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminExchangePreviewResponse.yaml index 43b16c64383de..2ada4ad0d5849 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminExchangePreviewResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminExchangePreviewResponse.yaml @@ -6,6 +6,6 @@ required: - exchange properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml exchange: $ref: ./AdminExchange.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminExchangeRequestResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminExchangeRequestResponse.yaml index 8c908c82e0c7c..285bbc8842a6f 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminExchangeRequestResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminExchangeRequestResponse.yaml @@ -7,10 +7,8 @@ required: - exchange properties: return: - description: The associated return's details. $ref: ./AdminReturn.yaml order_preview: - description: A preview of the order once the exchange is applied. - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml exchange: $ref: ./AdminExchange.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminExchangeReturnResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminExchangeReturnResponse.yaml index abe845366fc88..d8ab001ca031d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminExchangeReturnResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminExchangeReturnResponse.yaml @@ -6,6 +6,6 @@ required: - return properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml return: $ref: ./AdminReturn.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminExportProductRequest.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminExportProductRequest.yaml new file mode 100644 index 0000000000000..aa3490570bfc1 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminExportProductRequest.yaml @@ -0,0 +1,3 @@ +type: object +description: SUMMARY +x-schemaName: AdminExportProductRequest diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminFulfillment.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminFulfillment.yaml index 80430cd6adf85..a459be7817a01 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminFulfillment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminFulfillment.yaml @@ -37,10 +37,8 @@ properties: title: shipping_option_id description: The ID of the shipping option this fulfillment is created for. provider: - description: The details of the fulfillment provider using to handle this fulfillment. $ref: ./AdminFulfillmentProvider.yaml delivery_address: - description: The address to deliver the item to. $ref: ./AdminFulfillmentAddress.yaml items: type: array diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentProvider.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentProvider.yaml index 9d7d2c4f6a843..a60a87734e0ba 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentProvider.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentProvider.yaml @@ -1,3 +1,15 @@ type: object -description: The shipping option's provider. +description: The fulfillment provider's details. x-schemaName: AdminFulfillmentProvider +required: + - id + - is_enabled +properties: + id: + type: string + title: id + description: The provider's ID. + is_enabled: + type: boolean + title: is_enabled + description: The provider's is enabled. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentSet.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentSet.yaml index e9131c3f4aa8e..47858b02ccd26 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentSet.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminFulfillmentSet.yaml @@ -1,5 +1,5 @@ type: object -description: The fulfillment set's parent. +description: The service zone's fulfillment set. x-schemaName: AdminFulfillmentSet required: - id @@ -14,34 +14,36 @@ properties: id: type: string title: id - description: The parent's ID. + description: The fulfillment set's ID. name: type: string title: name - description: The parent's name. + description: The fulfillment set's name. type: type: string title: type - description: The parent's type. + description: The fulfillment set's type. location: - $ref: ./AdminStockLocation.yaml + type: object + description: The stock location's details. + x-schemaName: AdminStockLocation service_zones: type: array - description: The parent's service zones. + description: The fulfillment set's service zones. items: $ref: ./AdminServiceZone.yaml created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The fulfillment set's created at. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The fulfillment set's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The fulfillment set's deleted at. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminGeoZone.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminGeoZone.yaml index fcdcef3406b53..c7d0be5d77dc5 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminGeoZone.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminGeoZone.yaml @@ -1,5 +1,5 @@ type: object -description: The geo zone's details. +description: The geo zone's geo zones. x-schemaName: AdminGeoZone required: - id @@ -43,14 +43,14 @@ properties: type: string format: date-time title: created_at - description: The date the geo zone was created. + description: The geo zone's created at. updated_at: type: string format: date-time title: updated_at - description: The date the geo zone was update. + description: The geo zone's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The date the geo zone was deleted. + description: The geo zone's deleted at. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminImportProductRequest.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminImportProductRequest.yaml index 94efb6c2bde43..8aac0f128a862 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminImportProductRequest.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminImportProductRequest.yaml @@ -5,4 +5,9 @@ required: - file properties: file: - $ref: ./File.yaml + type: object + description: A File to upload. + externalDocs: + url: https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: file diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminInventoryItem.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminInventoryItem.yaml index c2c758a65cd2f..287a08bd992ca 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminInventoryItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminInventoryItem.yaml @@ -1,5 +1,5 @@ type: object -description: The inventory item's details. +description: The reservation's inventory item. x-schemaName: AdminInventoryItem required: - id @@ -12,7 +12,7 @@ properties: sku: type: string title: sku - description: The inventory item's SKU. + description: The inventory item's sku. origin_country: type: string title: origin_country @@ -20,15 +20,15 @@ properties: hs_code: type: string title: hs_code - description: The inventory item's HS code. + description: The inventory item's hs code. requires_shipping: type: boolean title: requires_shipping - description: Whether the inventory item requires shipping. + description: The inventory item's requires shipping. mid_code: type: string title: mid_code - description: The inventory item's MID code. + description: The inventory item's mid code. material: type: string title: material @@ -60,12 +60,12 @@ properties: thumbnail: type: string title: thumbnail - description: The URL of the inventory item's thumbnail. + description: The inventory item's thumbnail. metadata: type: object - description: The inventory item's metadata, can hold custom key-value pairs. + description: The inventory item's metadata. location_levels: type: array - description: The inventory item's associated inventory levels. + description: The inventory item's location levels. items: $ref: ./AdminInventoryLevel.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminInventoryLevel.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminInventoryLevel.yaml index 91bd9eaab4285..d7802818c2b7b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminInventoryLevel.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminInventoryLevel.yaml @@ -1,5 +1,5 @@ type: object -description: The inventory level's details. +description: The location level's location levels. x-schemaName: AdminInventoryLevel required: - id @@ -9,67 +9,56 @@ required: - inventory_item_id - location_id - stocked_quantity - - raw_stocked_quantity - reserved_quantity - - raw_reserved_quantity - incoming_quantity - - raw_incoming_quantity - metadata - available_quantity properties: id: type: string title: id - description: The inventory level's ID. + description: The location level's ID. + created_at: + type: string + format: date-time + title: created_at + description: The location level's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The location level's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The location level's deleted at. inventory_item_id: type: string title: inventory_item_id - description: The ID of the inventory item this level belongs to. + description: The location level's inventory item id. location_id: type: string title: location_id - description: The ID of the stock location this level belongs to. + description: The location level's location id. stocked_quantity: type: number title: stocked_quantity - description: >- - The quantity of the associated inventory item stocked in the associated - stock location. + description: The location level's stocked quantity. reserved_quantity: type: number title: reserved_quantity - description: >- - The reserved quantity of the associated inventory item stocked in the - associated stock location. + description: The location level's reserved quantity. incoming_quantity: type: number title: incoming_quantity - description: >- - The incoming quantity of the associated inventory item stocked in the - associated stock location. + description: The location level's incoming quantity. metadata: type: object - description: The location level's metadata, can hold custom key-value pairs. + description: The location level's metadata. inventory_item: - $ref: ./AdminInventoryItem.yaml + type: object available_quantity: type: number title: available_quantity - description: >- - The quantity available for order of the associated inventory item in the - associated stock location. - created_at: - type: string - format: date-time - title: created_at - description: The date the inventory level was created. - updated_at: - type: string - format: date-time - title: updated_at - description: The date the inventory level was updated. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The date the inventory level was deleted. + description: The location level's available quantity. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminMarkOrderFulfillmentDelivered.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminMarkOrderFulfillmentDelivered.yaml new file mode 100644 index 0000000000000..94ea98ca76ce0 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminMarkOrderFulfillmentDelivered.yaml @@ -0,0 +1,3 @@ +type: object +description: SUMMARY +x-schemaName: AdminMarkOrderFulfillmentDelivered diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrder.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrder.yaml index 4d56258b6ed1d..e90b9b2d8fadc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrder.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrder.yaml @@ -3,21 +3,20 @@ description: The order's details. x-schemaName: AdminOrder required: - payment_collections + - items + - shipping_methods + - currency_code - id + - created_at + - updated_at + - email - version - region_id - customer_id - sales_channel_id - - email - - currency_code - - items - - shipping_methods - payment_status - fulfillment_status - summary - - metadata - - created_at - - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -50,7 +49,7 @@ properties: type: array description: The order's fulfillments. items: - $ref: ./BaseOrderFulfillment.yaml + $ref: ./AdminOrderFulfillment.yaml sales_channel: $ref: ./AdminSalesChannel.yaml customer: @@ -96,12 +95,12 @@ properties: type: array description: The order's items. items: - $ref: ./BaseOrderLineItem.yaml + $ref: ./AdminOrderLineItem.yaml shipping_methods: type: array description: The order's shipping methods. items: - $ref: ./BaseOrderShippingMethod.yaml + $ref: ./AdminOrderShippingMethod.yaml payment_status: type: string description: The order's payment status. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderChange.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderChange.yaml new file mode 100644 index 0000000000000..da495b3dd1759 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderChange.yaml @@ -0,0 +1,150 @@ +type: object +description: The order change's details. +x-schemaName: AdminOrderChange +required: + - order + - claim + - return_order + - exchange + - actions + - status + - order_id + - metadata + - id + - created_at + - updated_at + - version + - canceled_at + - return_id + - exchange_id + - claim_id + - requested_by + - requested_at + - confirmed_by + - confirmed_at + - declined_by + - declined_reason + - declined_at + - canceled_by +properties: + id: + type: string + title: id + description: The order change's ID. + version: + type: number + title: version + description: >- + The order change's version. This will be the order's version when the + change is applied. + change_type: + oneOf: + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + description: The order change's type. + order_id: + type: string + title: order_id + description: The ID of the order this change applies on. + return_id: + type: string + title: return_id + description: The ID of the associated return. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + order: + type: string + title: order + description: The order change's order. + return_order: + $ref: ./AdminReturn.yaml + exchange: + $ref: ./AdminExchange.yaml + claim: + $ref: ./AdminClaim.yaml + actions: + type: array + description: The order change's actions. + items: + $ref: ./AdminOrderChangeAction.yaml + status: + type: string + description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined + requested_by: + type: string + title: requested_by + description: The ID of the user that requested the change. + requested_at: + type: string + title: requested_at + description: The date the order change was requested. + format: date-time + confirmed_by: + type: string + title: confirmed_by + description: The ID of the user that confirmed the order change. + confirmed_at: + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time + declined_by: + type: string + title: declined_by + description: The ID of the user that declined the order change. + declined_reason: + type: string + title: declined_reason + description: The reason the order change was declined. + metadata: + type: object + description: The order change's metadata, can hold custom key-value pairs. + declined_at: + type: string + title: declined_at + description: The date the order change was declined. + format: date-time + canceled_by: + type: string + title: canceled_by + description: The ID of the user that canceled the order change. + canceled_at: + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time + created_at: + type: string + format: date-time + title: created_at + description: The date the order change was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderChangeAction.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderChangeAction.yaml new file mode 100644 index 0000000000000..7e112e14d03d9 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderChangeAction.yaml @@ -0,0 +1,102 @@ +type: object +description: The order change action's details. +x-schemaName: AdminOrderChangeAction +required: + - order_change + - order + - order_id + - internal_note + - id + - created_at + - updated_at + - return_id + - exchange_id + - claim_id + - order_change_id + - reference + - reference_id + - action + - details +properties: + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change that the action belongs to. + order_change: + $ref: ./AdminOrderChange.yaml + order_id: + type: string + title: order_id + description: The ID of the order the associated change is for. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + type: string + title: order + description: The order change's order. + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + description: The applied action. + enum: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the action was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderChangesResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderChangesResponse.yaml index 0126a1ad99ad3..7e5bb2a7d5fd7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrderChangesResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderChangesResponse.yaml @@ -8,4 +8,4 @@ properties: type: array description: An order's changes. items: - $ref: ./BaseOrderChange.yaml + $ref: ./AdminOrderChange.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditPreviewResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditPreviewResponse.yaml index ec43c247ffb39..02858b85ad852 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditPreviewResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditPreviewResponse.yaml @@ -5,4 +5,4 @@ required: - order_preview properties: order_preview: - $ref: ./OrderPreview.yaml + $ref: ./AdminOrderPreview.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditResponse.yaml index db40b31387db3..9cbc0f6528de3 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderEditResponse.yaml @@ -5,4 +5,4 @@ required: - order_change properties: order_change: - $ref: ./OrderChange.yaml + $ref: ./AdminOrderChange.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderFulfillment.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderFulfillment.yaml new file mode 100644 index 0000000000000..a9cd50d83f317 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderFulfillment.yaml @@ -0,0 +1,79 @@ +type: object +description: The fulfillment's fulfillments. +x-schemaName: AdminOrderFulfillment +required: + - id + - location_id + - packed_at + - shipped_at + - delivered_at + - canceled_at + - requires_shipping + - data + - provider_id + - shipping_option_id + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The fulfillment's ID. + location_id: + type: string + title: location_id + description: The ID of the location the items are fulfilled from. + packed_at: + type: string + title: packed_at + description: The date the items were packed. + format: date-time + shipped_at: + type: string + title: shipped_at + description: The date the items were shipped. + format: date-time + delivered_at: + type: string + title: delivered_at + description: The date the items were delivered. + format: date-time + canceled_at: + type: string + title: canceled_at + description: The date the items were canceled. + format: date-time + data: + type: object + description: >- + Data useful for the fulfillment provider handling it. This is taken from + the associated shipping option. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + provider_id: + type: string + title: provider_id + description: The ID of the fulfillment provider used to handle the fulfillment. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the associated shipping option. + metadata: + type: object + description: The fulfillment's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the fulfillment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the fulfillment was updated. + requires_shipping: + type: boolean + title: requires_shipping + description: The fulfillment's requires shipping. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderLineItem.yaml new file mode 100644 index 0000000000000..d06397d72543e --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderLineItem.yaml @@ -0,0 +1,213 @@ +type: object +description: The item's items. +x-schemaName: AdminOrderLineItem +required: + - title + - metadata + - id + - subtitle + - thumbnail + - created_at + - updated_at + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - variant_id + - product_id + - product_title + - product_description + - product_subtitle + - product_type + - product_collection + - product_handle + - variant_sku + - variant_barcode + - variant_title + - variant_option_values + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - detail + - refundable_total + - refundable_total_per_unit +properties: + id: + type: string + title: id + description: The item's ID. + title: + type: string + title: title + description: The item's title. + subtitle: + type: string + title: subtitle + description: The item's subtitle. + thumbnail: + type: string + title: thumbnail + description: The URL of the item's thumbnail. + variant: + $ref: ./AdminProductVariant.yaml + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product: + $ref: ./AdminProduct.yaml + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The item's product type. + product_collection: + type: string + title: product_collection + description: The ID of the collection the item's product belongs to. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: + type: string + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The values of the item variant's options. + example: + Color: Blue + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item is tax inclusive. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + unit_price: + type: number + title: unit_price + description: The item's unit price. + quantity: + type: number + title: quantity + description: The item's quantity. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: ./BaseOrderLineItemTaxLine.yaml + adjustments: + type: array + description: The item's adjustments. + items: + $ref: ./BaseOrderLineItemAdjustment.yaml + detail: + $ref: ./BaseOrderItemDetail.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + original_total: + type: number + title: original_total + description: The item's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the item, excluding promotions. + item_total: + type: number + title: item_total + description: The total taxes of the item, including promotions. + item_subtotal: + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of the item, including promotions. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the item including promotions. + discount_total: + type: number + title: discount_total + description: The total discount amount of the item. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total refundable amount of the item's total. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total refundable amount of the item's total for a single quantity. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreview.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreview.yaml index 1d24582bdff15..a20367738c36a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreview.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreview.yaml @@ -7,19 +7,18 @@ required: - return_requested_total - order_change - currency_code - - version - id + - created_at + - updated_at + - email + - version - region_id - customer_id - sales_channel_id - - email - payment_collections - payment_status - fulfillment_status - summary - - metadata - - created_at - - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -48,7 +47,7 @@ properties: title: return_requested_total description: The total of the requested return. order_change: - $ref: ./BaseOrderChange.yaml + $ref: ./AdminOrderChange.yaml items: type: array description: The order's items. @@ -120,7 +119,7 @@ properties: title: variant_id description: The ID of the associated variant. product: - $ref: ./BaseProduct.yaml + $ref: ./AdminProduct.yaml product_id: type: string title: product_id @@ -519,7 +518,7 @@ properties: type: array description: The order's fulfillments. items: - $ref: ./BaseOrderFulfillment.yaml + $ref: ./AdminOrderFulfillment.yaml fulfillment_status: type: string description: The order's fulfillment status. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreviewResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreviewResponse.yaml index f94371d50e7ba..a6f69a820862a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreviewResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderPreviewResponse.yaml @@ -5,4 +5,8 @@ required: - order properties: order: - $ref: ./AdminOrderPreview.yaml + type: string + title: order + description: >- + A preview of an order if a change, such as exchange, return, edit, or + claim is applied on it. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderResponse.yaml index 7dbac7fa46222..0ed25784cf05b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrderResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderResponse.yaml @@ -5,4 +5,6 @@ required: - order properties: order: - $ref: ./AdminOrder.yaml + type: string + title: order + description: The order's details. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderReturnResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderReturnResponse.yaml index ccc9891c960af..c7f107ab52a4d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminOrderReturnResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderReturnResponse.yaml @@ -6,6 +6,8 @@ required: - return properties: order: - $ref: ./Order.yaml + type: string + title: order + description: The order change's order. return: $ref: ./AdminReturn.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminOrderShippingMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminOrderShippingMethod.yaml new file mode 100644 index 0000000000000..ab93242120a98 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminOrderShippingMethod.yaml @@ -0,0 +1,116 @@ +type: object +description: The shipping method's details. +x-schemaName: AdminOrderShippingMethod +required: + - id + - order_id + - name + - amount + - is_tax_inclusive + - shipping_option_id + - data + - metadata + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes applied taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: >- + The shipping method's data, useful for fulfillment provider handling its + fulfillment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: ./BaseOrderShippingMethodTaxLine.yaml + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: ./BaseOrderShippingMethodAdjustment.yaml + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The shipping method's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The total discounts applied on the shipping method. + discount_tax_total: + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + detail: + $ref: ./BaseOrderShippingDetail.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPayment.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPayment.yaml index c03bcea935824..7eccb02f9c928 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminPayment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPayment.yaml @@ -86,8 +86,8 @@ properties: type: array description: The details of payment refunds. items: - $ref: ./BaseRefund.yaml + $ref: ./AdminRefund.yaml payment_collection: - $ref: ./BasePaymentCollection.yaml + $ref: ./AdminPaymentCollection.yaml payment_session: - $ref: ./BasePaymentSession.yaml + $ref: ./AdminPaymentSession.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPaymentCollection.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPaymentCollection.yaml index c6fa1d3cac15a..75d1731804f97 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminPaymentCollection.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPaymentCollection.yaml @@ -2,12 +2,12 @@ type: object description: The payment collection's details. x-schemaName: AdminPaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -70,14 +70,14 @@ properties: The payment provider used to process the collection's payments and sessions. items: - $ref: ./BasePaymentProvider.yaml + $ref: ./AdminPaymentProvider.yaml payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: ./BasePaymentSession.yaml + $ref: ./AdminPaymentSession.yaml payments: type: array description: The payment collection's payments. items: - $ref: ./BasePayment.yaml + $ref: ./AdminPayment.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPaymentProvider.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPaymentProvider.yaml index c9d275092e887..3ef9489c8d15b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminPaymentProvider.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPaymentProvider.yaml @@ -1,5 +1,5 @@ type: object -description: The payment provider's details. +description: The payment provider's payment providers. x-schemaName: AdminPaymentProvider required: - is_enabled diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPaymentSession.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPaymentSession.yaml new file mode 100644 index 0000000000000..ad4acbc0bfa4e --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPaymentSession.yaml @@ -0,0 +1,61 @@ +type: object +description: The payment session's details. +x-schemaName: AdminPaymentSession +properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: >- + The payment session's data, useful for the payment provider processing the + payment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + $ref: ./AdminPaymentCollection.yaml + payment: + $ref: ./BasePayment.yaml +required: + - id + - amount + - currency_code + - provider_id + - data + - status diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPostClaimItemsReqSchema.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPostClaimItemsReqSchema.yaml index d1dfd8929fe09..ffa8aca2704ce 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminPostClaimItemsReqSchema.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPostClaimItemsReqSchema.yaml @@ -21,13 +21,24 @@ properties: title: quantity description: The quantity of the order's item to add to the claim. reason: - type: string + oneOf: + - type: string + description: The item's reason. + enum: + - MISSING_ITEM + - type: string + description: The item's reason. + enum: + - WRONG_ITEM + - type: string + description: The item's reason. + enum: + - PRODUCTION_FAILURE + - type: string + description: The item's reason. + enum: + - OTHER description: The reason the item is claimed. - enum: - - missing_item - - wrong_item - - production_failure - - other description: type: string title: description diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProduct.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProduct.yaml index f8bf5ad600df3..e197602dfacaf 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProduct.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProduct.yaml @@ -2,15 +2,15 @@ type: object description: The product's details. x-schemaName: AdminProduct required: + - variants - type + - options + - images - length - title - status - - options - description - id - - created_at - - updated_at - handle - subtitle - is_giftcard @@ -24,9 +24,10 @@ required: - material - collection_id - type_id - - images - discountable - external_id + - created_at + - updated_at - deleted_at properties: collection: @@ -73,7 +74,7 @@ properties: type: array description: The product's options. items: - $ref: ./BaseProductOption.yaml + $ref: ./AdminProductOption.yaml description: type: string title: description @@ -151,7 +152,7 @@ properties: type: array description: The product's images. items: - $ref: ./BaseProductImage.yaml + $ref: ./AdminProductImage.yaml discountable: type: boolean title: discountable diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductImage.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductImage.yaml new file mode 100644 index 0000000000000..050650545a5da --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductImage.yaml @@ -0,0 +1,33 @@ +type: object +description: The image's details. +x-schemaName: AdminProductImage +properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's URL. + created_at: + type: string + format: date-time + title: created_at + description: The date the image was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. +required: + - id + - url diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductOption.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductOption.yaml index bb9c3717aed96..ad95cdf7c7a13 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductOption.yaml @@ -1,44 +1,44 @@ type: object -description: The product's product option. +description: The product option's details. x-schemaName: AdminProductOption -required: - - id - - title properties: id: type: string title: id - description: The product option's ID. + description: The option's ID. title: type: string title: title - description: The product option's title. + description: The option's title. product: - $ref: ./BaseProduct.yaml + $ref: ./AdminProduct.yaml product_id: type: string title: product_id - description: The product option's product id. + description: The option's product id. values: type: array - description: The product option's values. + description: The option's values. items: - $ref: ./BaseProductOptionValue.yaml + $ref: ./AdminProductOptionValue.yaml metadata: type: object - description: The product option's metadata. + description: The option's metadata. created_at: type: string format: date-time title: created_at - description: The product option's created at. + description: The option's created at. updated_at: type: string format: date-time title: updated_at - description: The product option's updated at. + description: The option's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The product option's deleted at. + description: The option's deleted at. +required: + - id + - title diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionDeleteResponse.yaml index 0873a46f9a0bd..0069070c06dd6 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product option deletion. x-schemaName: AdminProductOptionDeleteResponse required: - id @@ -9,14 +9,15 @@ properties: id: type: string title: id - description: The product's ID. + description: The product option's ID. object: type: string title: object description: The name of the deleted object. + default: product_option deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the product option was deleted. parent: $ref: ./AdminProduct.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionResponse.yaml index c609e7d1d8ca3..79d305a5d33b9 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product option's details. x-schemaName: AdminProductOptionResponse required: - product_option diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionValue.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionValue.yaml new file mode 100644 index 0000000000000..88175464a4be2 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductOptionValue.yaml @@ -0,0 +1,39 @@ +type: object +description: The product option value's details. +x-schemaName: AdminProductOptionValue +required: + - id + - value +properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + $ref: ./AdminProductOption.yaml + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductResponse.yaml index 1c3d489857a54..5b4cd3889b6fd 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product's details. x-schemaName: AdminProductResponse required: - product diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductTag.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductTag.yaml index c9dfaff0fbc0e..7fc320de89716 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductTag.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductTag.yaml @@ -1,5 +1,5 @@ type: object -description: The tag's tags. +description: The product tag's details. x-schemaName: AdminProductTag required: - id @@ -19,17 +19,17 @@ properties: type: string format: date-time title: created_at - description: The tag's created at. + description: The date the tag was created. updated_at: type: string format: date-time title: updated_at - description: The tag's updated at. + description: The date the tag was updated. deleted_at: type: string format: date-time title: deleted_at - description: The tag's deleted at. + description: The date the tag was deleted. metadata: type: object - description: The tag's metadata. + description: The tag's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductTagDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductTagDeleteResponse.yaml index 33697dcfd246b..b09f96dd0fc0b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductTagDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductTagDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product tag deletion. x-schemaName: AdminProductTagDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Product Tag was deleted. + description: Whether the product tag was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductTagListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductTagListResponse.yaml index 40accb66922fe..72220d70411f2 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductTagListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductTagListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of product tags. x-schemaName: AdminProductTagListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The product tag's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product tag's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product tag's count. + description: The total number of items. product_tags: type: array - description: The product tag's product tags. + description: The list of product tags. items: $ref: ./AdminProductTag.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductTagResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductTagResponse.yaml index 47fe1ad408627..4ae92f3bef80e 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductTagResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductTagResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product tag's details. x-schemaName: AdminProductTagResponse required: - product_tag diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductType.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductType.yaml index a8d58344eafdb..ef5f2ece56c12 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductType.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductType.yaml @@ -1,5 +1,5 @@ type: object -description: The parent's type. +description: The product type's details. x-schemaName: AdminProductType required: - id @@ -19,17 +19,17 @@ properties: type: string format: date-time title: created_at - description: The type's created at. + description: The date the type was created. updated_at: type: string format: date-time title: updated_at - description: The type's updated at. + description: The date the type was updated. deleted_at: type: string format: date-time title: deleted_at - description: The type's deleted at. + description: The date the type was deleted. metadata: type: object - description: The type's metadata. + description: The type's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeDeleteResponse.yaml index 797b5fd754ef8..4526de1ff6f63 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product type deletion. x-schemaName: AdminProductTypeDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Product Type was deleted. + description: Whether the product type was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeListResponse.yaml index 9bf9f9159f3d0..19fa220fe971c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of product types. x-schemaName: AdminProductTypeListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The product type's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product type's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product type's count. + description: The total number of items. product_types: type: array - description: The product type's product types. + description: The list of product types. items: $ref: ./AdminProductType.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeResponse.yaml index 8daf16a292c90..d0907f2d65402 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductTypeResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product type's details. x-schemaName: AdminProductTypeResponse required: - product_type diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariant.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariant.yaml index 8e82d12e9dba5..687550c11b5b2 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariant.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariant.yaml @@ -1,8 +1,9 @@ type: object -description: The product's parent. +description: The product variant's details. x-schemaName: AdminProductVariant required: - prices + - options - id - title - sku @@ -19,116 +20,119 @@ required: - length - height - width - - options - created_at - updated_at - deleted_at properties: prices: type: array - description: The parent's prices. + description: The variant's prices. items: $ref: ./AdminPrice.yaml id: type: string title: id - description: The parent's ID. + description: The variant's ID. title: type: string title: title - description: The parent's title. + description: The variant's title. sku: type: string title: sku - description: The parent's sku. + description: The variant's SKU. barcode: type: string title: barcode - description: The parent's barcode. + description: The variant's barcode. ean: type: string title: ean - description: The parent's ean. + description: The variant's EAN code. upc: type: string title: upc - description: The parent's upc. + description: The variant's UPC. allow_backorder: type: boolean title: allow_backorder - description: The parent's allow backorder. + description: Whether the variant can be ordered even if it's out of stock. manage_inventory: type: boolean title: manage_inventory - description: The parent's manage inventory. + description: >- + Whether the Medusa application manages the variant's inventory quantity + and availablility. If disabled, the variant is always considered in stock. inventory_quantity: type: number title: inventory_quantity - description: The parent's inventory quantity. + description: >- + The variant's inventory quantity. This is only included if you pass in the + `fields` query parameter a `+variants.inventory_quantity` parameter. hs_code: type: string title: hs_code - description: The parent's hs code. + description: The variant's HS code. origin_country: type: string title: origin_country - description: The parent's origin country. + description: The variant's origin country. mid_code: type: string title: mid_code - description: The parent's mid code. + description: The variant's MID code. material: type: string title: material - description: The parent's material. + description: The variant's material. weight: type: number title: weight - description: The parent's weight. + description: The variant's weight. length: type: number title: length - description: The parent's length. + description: The variant's length. height: type: number title: height - description: The parent's height. + description: The variant's height. width: type: number title: width - description: The parent's width. + description: The variant's width. variant_rank: type: number title: variant_rank - description: The parent's variant rank. + description: The variant's rank among its sibling variants. options: type: array - description: The parent's options. + description: The variant's option values. items: - $ref: ./BaseProductOptionValue.yaml + $ref: ./AdminProductOptionValue.yaml product: - $ref: ./BaseProduct.yaml + $ref: ./AdminProduct.yaml product_id: type: string title: product_id - description: The parent's product id. + description: The ID of the product that the variant belongs to. calculated_price: $ref: ./BaseCalculatedPriceSet.yaml created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the variant was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the variant was updated. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The date the variant was deleted. metadata: type: object - description: The parent's metadata. + description: The variant's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantDeleteResponse.yaml index 52094f9db215d..01b28d3e6561f 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the product variant's deletion. x-schemaName: AdminProductVariantDeleteResponse required: - id @@ -9,7 +9,7 @@ properties: id: type: string title: id - description: The product's ID. + description: The product variant's ID. object: type: string title: object @@ -17,6 +17,7 @@ properties: deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the product variant was deleted. + default: variant parent: $ref: ./AdminProduct.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryBatchResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryBatchResponse.yaml index 9cf2e1c985e10..bf33c4a7083e9 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryBatchResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryBatchResponse.yaml @@ -1,5 +1,7 @@ type: object -description: SUMMARY +description: >- + The created, updated, and deleted associations between variants and inventory + items. x-schemaName: AdminProductVariantInventoryBatchResponse required: - created @@ -10,10 +12,12 @@ properties: oneOf: - $ref: ./AdminProductVariantInventoryLink.yaml - type: array - description: The product's created. + description: The created associations between product variants and inventory items. items: type: object - description: The created's details. + description: >- + A created association between a product variant and an inventory + item. x-schemaName: AdminProductVariantInventoryLink required: - productService @@ -21,32 +25,34 @@ properties: properties: productService: type: object - description: The created's productservice. + description: The product variant's details. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. + description: The ID of the product variant. inventoryService: type: object - description: The created's inventoryservice. + description: The inventory item's details. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The ID of the inventory item. updated: oneOf: - $ref: ./AdminProductVariantInventoryLink.yaml - type: array - description: The product's updated. + description: The updated associations between product variants and inventory items. items: type: object - description: The updated's details. + description: >- + An updated association between a product variant and an inventory + item. x-schemaName: AdminProductVariantInventoryLink required: - productService @@ -54,32 +60,34 @@ properties: properties: productService: type: object - description: The updated's productservice. + description: The product variant's details. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. + description: The ID of the product variant. inventoryService: type: object - description: The updated's inventoryservice. + description: The inventory item's details. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The ID of the inventory item. deleted: oneOf: - $ref: ./AdminProductVariantInventoryLink.yaml - type: array - description: SUMMARY + description: The deleted associations between product variants and inventory items. items: type: object - description: SUMMARY + description: >- + An deleted association between a product variant and an inventory + item. x-schemaName: AdminProductVariantInventoryLink required: - productService @@ -87,21 +95,21 @@ properties: properties: productService: type: object - description: The deleted's productservice. + description: The product variant's details. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. + description: The ID of the product variant. inventoryService: type: object - description: The deleted's inventoryservice. + description: The inventory item's details. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The ID of the inventory item. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLink.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLink.yaml index e5938e984d6ab..e93cb9a9fe654 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLink.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLink.yaml @@ -1,27 +1,27 @@ type: object -description: The product's ID. +description: The details of an association between a product variant and an inventory item. x-schemaName: AdminProductVariantInventoryLink required: - - productService - - inventoryService + - Product + - Inventory properties: - productService: + Product: type: object - description: The id's productservice. + description: The id's product. required: - variant_id properties: variant_id: type: string title: variant_id - description: The productservice's variant id. - inventoryService: + description: The product's variant id. + Inventory: type: object - description: The id's inventoryservice. + description: The id's inventory. required: - inventory_item_id properties: inventory_item_id: type: string title: inventory_item_id - description: The inventoryservice's inventory item id. + description: The inventory's inventory item id. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml index ba2ab976f9c8f..377a954ac4d3b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantInventoryLinkDeleteResponse.yaml @@ -1,5 +1,7 @@ type: object -description: SUMMARY +description: >- + The details of the deleted associated between a product variant and an + inventory item. x-schemaName: AdminProductVariantInventoryLinkDeleteResponse required: - id @@ -13,9 +15,10 @@ properties: type: string title: object description: The name of the deleted object. + default: variant-inventory-item-link deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the association was deleted. parent: $ref: ./AdminProductVariant.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantParams.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantParams.yaml deleted file mode 100644 index 6ea415b06d846..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantParams.yaml +++ /dev/null @@ -1,872 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: AdminProductVariantParams -properties: - q: - type: string - title: q - description: The product's q. - id: - oneOf: - - type: string - title: id - description: The product's ID. - - type: array - description: The product's ID. - items: - type: string - title: id - description: The id's ID. - manage_inventory: - type: boolean - title: manage_inventory - description: The product's manage inventory. - allow_backorder: - type: boolean - title: allow_backorder - description: The product's allow backorder. - created_at: - type: object - description: The product's created at. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - - type: object - description: >- - Filter by values not matching the conditions in this - parameter. - - type: array - description: >- - Filter by values not matching the conditions in this - parameter. - items: - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for - numbers and dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. - Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers - and dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful - for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: >- - Apply a case-insensitive `like` filter. Useful for strings - only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: >- - Filter arrays that have overlapping values with this - parameter. - items: - type: string - title: $overlap - description: >- - Filter arrays that have overlapping values with this - parameter. - $contains: - type: array - description: >- - Filter arrays that contain some of the values of this - parameter. - items: - type: string - title: $contains - description: >- - Filter arrays that contain some of the values of this - parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: >- - Filter by whether a value for this parameter exists (not - `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for numbers and - dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. Useful for - numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers and - dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful for - numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - updated_at: - type: object - description: The product's updated at. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - - type: object - description: >- - Filter by values not matching the conditions in this - parameter. - - type: array - description: >- - Filter by values not matching the conditions in this - parameter. - items: - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for - numbers and dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. - Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers - and dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful - for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: >- - Apply a case-insensitive `like` filter. Useful for strings - only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: >- - Filter arrays that have overlapping values with this - parameter. - items: - type: string - title: $overlap - description: >- - Filter arrays that have overlapping values with this - parameter. - $contains: - type: array - description: >- - Filter arrays that contain some of the values of this - parameter. - items: - type: string - title: $contains - description: >- - Filter arrays that contain some of the values of this - parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: >- - Filter by whether a value for this parameter exists (not - `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for numbers and - dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. Useful for - numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers and - dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful for - numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - deleted_at: - type: object - description: The product's deleted at. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is - the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's - content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - - type: object - description: >- - Filter by values not matching the conditions in this - parameter. - - type: array - description: >- - Filter by values not matching the conditions in this - parameter. - items: - type: string - title: $not - description: >- - Filter by values not matching the conditions in this - parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for - numbers and dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. - Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers - and dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful - for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: >- - Apply a case-insensitive `like` filter. Useful for strings - only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: >- - Filter arrays that have overlapping values with this - parameter. - items: - type: string - title: $overlap - description: >- - Filter arrays that have overlapping values with this - parameter. - $contains: - type: array - description: >- - Filter arrays that contain some of the values of this - parameter. - items: - type: string - title: $contains - description: >- - Filter arrays that contain some of the values of this - parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: >- - Filter by whether a value for this parameter exists (not - `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: >- - Filter by values greater than this parameter. Useful for numbers and - dates only. - $gte: - type: string - title: $gte - description: >- - Filter by values greater than or equal to this parameter. Useful for - numbers and dates only. - $lt: - type: string - title: $lt - description: >- - Filter by values less than this parameter. Useful for numbers and - dates only. - $lte: - type: string - title: $lte - description: >- - Filter by values less than or equal to this parameter. Useful for - numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - limit: - type: number - title: limit - description: The product's limit. - offset: - type: number - title: offset - description: The product's offset. - order: - type: string - title: order - description: The product's order. - fields: - type: string - title: fields - description: The product's fields. - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $or diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantResponse.yaml index cb5298721d273..8bd93d75bc8ab 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminProductVariantResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product variant's details. x-schemaName: AdminProductVariantResponse required: - variant diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPromotion.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPromotion.yaml index 2a31b4ded7704..641c56a02054b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminPromotion.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPromotion.yaml @@ -1,9 +1,14 @@ type: object -description: The promotion's details. +description: The application method's promotion. x-schemaName: AdminPromotion -required: - - id properties: + application_method: + $ref: ./AdminApplicationMethod.yaml + rules: + type: array + description: The promotion's rules. + items: + $ref: ./AdminPromotionRule.yaml id: type: string title: id @@ -13,25 +18,22 @@ properties: title: code description: The promotion's code. type: - type: string - description: The promotion's type. - enum: - - standard - - buyget + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. is_automatic: type: boolean title: is_automatic description: The promotion's is automatic. - application_method: - $ref: ./BaseApplicationMethod.yaml - rules: - type: array - description: The promotion's rules. - items: - $ref: ./BasePromotionRule.yaml campaign_id: type: string title: campaign_id description: The promotion's campaign id. campaign: $ref: ./AdminCampaign.yaml +required: + - id diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPromotionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPromotionResponse.yaml index 3a4255fe94ccb..76ea15b558505 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminPromotionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPromotionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The promotion's details. x-schemaName: AdminPromotionResponse required: - promotion diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminPromotionRule.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminPromotionRule.yaml index 010bb3dc39cff..d791840b7b9be 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminPromotionRule.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminPromotionRule.yaml @@ -1,5 +1,5 @@ type: object -description: The updated's details. +description: The target rule's target rules. x-schemaName: AdminPromotionRule required: - id @@ -8,28 +8,40 @@ properties: id: type: string title: id - description: The updated's ID. + description: The target rule's ID. description: type: string title: description - description: The updated's description. + description: The target rule's description. attribute: type: string title: attribute - description: The updated's attribute. + description: The target rule's attribute. operator: - type: string - description: The updated's operator. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte + oneOf: + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. values: type: array - description: The updated's values. + description: The target rule's values. items: $ref: ./BasePromotionRuleValue.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRefund.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRefund.yaml new file mode 100644 index 0000000000000..229fb7729c5f3 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRefund.yaml @@ -0,0 +1,38 @@ +type: object +description: The refund's details. +x-schemaName: AdminRefund +required: + - id + - amount + - created_at + - payment +properties: + id: + type: string + title: id + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: + type: string + title: refund_reason_id + description: The ID of the refund reason. + note: + type: string + title: note + description: More details about the refund. + created_at: + type: string + format: date-time + title: created_at + description: The date the refund was created. + created_by: + type: string + title: created_by + description: The ID of the user that created the refund. + payment: + $ref: ./BasePayment.yaml + refund_reason: + $ref: ./RefundReason.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRefundReason.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRefundReason.yaml index 3110520654402..919bb56bfa28d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminRefundReason.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRefundReason.yaml @@ -22,14 +22,14 @@ properties: description: The refund reason's description. metadata: type: object - description: The refund reason's metadata. + description: The refund reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The refund reason's created at. + description: The date the refund reason was created. updated_at: type: string format: date-time title: updated_at - description: The refund reason's updated at. + description: The date the refund reason was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRegion.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRegion.yaml index 0ad92660d5479..96b6ff979c1fb 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminRegion.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRegion.yaml @@ -2,9 +2,9 @@ type: object description: The region's details. x-schemaName: AdminRegion required: - - id - name - currency_code + - id properties: id: type: string @@ -18,15 +18,16 @@ properties: type: string title: currency_code description: The region's currency code. + example: usd automatic_taxes: type: boolean title: automatic_taxes - description: The region's automatic taxes. + description: Whether taxes are applied automatically during checkout. countries: type: array description: The region's countries. items: - $ref: ./BaseRegionCountry.yaml + $ref: ./AdminRegionCountry.yaml payment_providers: type: array description: The region's payment providers. @@ -34,14 +35,14 @@ properties: $ref: ./AdminPaymentProvider.yaml metadata: type: object - description: The region's metadata. + description: The region's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The region's created at. + description: The date the region was created. updated_at: type: string format: date-time title: updated_at - description: The region's updated at. + description: The date the region was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRegionCountry.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRegionCountry.yaml index 04938da440014..88ca70090bc4a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminRegionCountry.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRegionCountry.yaml @@ -1,3 +1,33 @@ type: object -description: The billing address's country. +description: The country's details. x-schemaName: AdminRegionCountry +required: + - id +properties: + id: + type: string + title: id + description: The country's ID. + iso_2: + type: string + title: iso_2 + description: The country's iso 2. + example: us + iso_3: + type: string + title: iso_3 + description: The country's iso 3. + example: usa + num_code: + type: string + title: num_code + description: The country's num code. + example: 840 + name: + type: string + title: name + description: The country's name. + display_name: + type: string + title: display_name + description: The country's display name. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRegionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRegionResponse.yaml index fc2373ff7772d..390c84603e3cd 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminRegionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRegionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The region's details. x-schemaName: AdminRegionResponse required: - region diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReservation.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReservation.yaml index df021b64bdabe..2b75d1102d26b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReservation.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReservation.yaml @@ -9,7 +9,6 @@ required: - external_id - description - inventory_item_id - - inventory_item properties: id: type: string @@ -18,11 +17,11 @@ properties: line_item_id: type: string title: line_item_id - description: The reservation's line item id. + description: The ID of the line item this reservation is for. location_id: type: string title: location_id - description: The reservation's location id. + description: The ID of the location the quantity is reserved from. quantity: type: number title: quantity @@ -30,7 +29,7 @@ properties: external_id: type: string title: external_id - description: The reservation's external id. + description: An ID in an external system description: type: string title: description @@ -38,29 +37,28 @@ properties: inventory_item_id: type: string title: inventory_item_id - description: The reservation's inventory item id. + description: The ID of the inventory item this reservation is associated with. inventory_item: - type: object - description: The reservation's inventory item. + $ref: ./AdminInventoryItem.yaml metadata: type: object - description: The reservation's metadata. + description: The reservation's metadata, can hold custom key-value pairs. created_by: type: string title: created_by - description: The reservation's created by. + description: The ID of the user that created this reservation. deleted_at: type: string format: date-time title: deleted_at - description: The reservation's deleted at. + description: The date this reservation was deleted. created_at: type: string format: date-time title: created_at - description: The reservation's created at. + description: The date this reservation was created. updated_at: type: string format: date-time title: updated_at - description: The reservation's updated at. + description: The date this reservation was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReservationResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReservationResponse.yaml index 42075fd8acb40..4db926c72b924 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReservationResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReservationResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The reservation's details. x-schemaName: AdminReservationResponse required: - reservation diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturn.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturn.yaml index 0ef197d0f7301..ca7fb1ababe63 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturn.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturn.yaml @@ -1,12 +1,12 @@ type: object -description: The exchange's return. +description: The return's details. x-schemaName: AdminReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -15,14 +15,47 @@ properties: type: string title: id description: The return's ID. + status: + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + description: The return's status. + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. order_id: type: string title: order_id - description: The return's order id. - status: + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: ./AdminReturnItem.yaml + created_at: type: string - title: status - description: The return's status. + format: date-time + title: created_at + description: The date the return was created. + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time exchange_id: type: string title: exchange_id @@ -47,25 +80,7 @@ properties: type: boolean title: no_notification description: The return's no notification. - refund_amount: - type: number - title: refund_amount - description: The return's refund amount. - items: - type: array - description: The return's items. - items: - $ref: ./BaseReturnItem.yaml received_at: type: string title: received_at description: The return's received at. - created_at: - type: string - format: date-time - title: created_at - description: The return's created at. - canceled_at: - type: string - title: canceled_at - description: The return's canceled at. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturnItem.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturnItem.yaml index 47cbe93e16f7f..f9f5bb9346c85 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturnItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturnItem.yaml @@ -1,5 +1,5 @@ type: object -description: The return item's return items. +description: The item's items. x-schemaName: AdminReturnItem required: - id @@ -20,27 +20,31 @@ properties: received_quantity: type: number title: received_quantity - description: The return item's received quantity. + description: >- + The received quantity of the item. This quantity is added to the stocked + inventory quantity of the item. damaged_quantity: type: number title: damaged_quantity - description: The return item's damaged quantity. + description: >- + The received damaged quantity of the item, which isn't added to the + stocked inventory quantity of the item. reason_id: type: string title: reason_id - description: The return item's reason id. + description: The ID of the return reason associated with the item. note: type: string title: note - description: The return item's note. + description: A note about why the item was returned. item_id: type: string title: item_id - description: The return item's item id. + description: The ID of the associated order item. return_id: type: string title: return_id - description: The return item's return id. + description: The ID of the return this return item belongs to. metadata: type: object - description: The return item's metadata. + description: The return item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturnPreviewResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturnPreviewResponse.yaml index 8b8734b2fec9f..a7958ba7deaf4 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturnPreviewResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturnPreviewResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of a return and a preview of the order once the return is applied. x-schemaName: AdminReturnPreviewResponse required: - order_preview diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReason.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReason.yaml index 3046e2a2544f0..7de3166b718f4 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReason.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReason.yaml @@ -26,14 +26,14 @@ properties: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonDeleteResponse.yaml index 37435266107f8..7d69be5a278e2 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the return reason deletion. x-schemaName: AdminReturnReasonDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Return Reason was deleted. + description: Whether the return reason was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonListResponse.yaml index 0fa69fc5170aa..4f931ef219226 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of return reasons. x-schemaName: AdminReturnReasonListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The return reason's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The return reason's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The return reason's count. + description: The total number of items. return_reasons: type: array - description: The return reason's return reasons. + description: The list of return reasons. items: $ref: ./AdminReturnReason.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonResponse.yaml index 9b3ad0f9a4daa..513915d0c32b5 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturnReasonResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return reason's details. x-schemaName: AdminReturnReasonResponse required: - return_reason diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminReturnResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminReturnResponse.yaml index 8ce9535394aa6..3e0fe4d159b32 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminReturnResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminReturnResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return's details. x-schemaName: AdminReturnResponse required: - return diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRevokeApiKey.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRevokeApiKey.yaml index 7e99903e5bdc1..af00ccb2fefc7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminRevokeApiKey.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRevokeApiKey.yaml @@ -1,8 +1,10 @@ type: object -description: SUMMARY +description: The details of revoking the API key. x-schemaName: AdminRevokeApiKey properties: revoke_in: type: number title: revoke_in - description: The api key's revoke in. + description: >- + The time in seconds to revoke the API key after. If not set, the API key + is revoked immediately. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRuleAttributeOption.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRuleAttributeOption.yaml index 8ca5eaabf397a..53359ab0b48c0 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminRuleAttributeOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRuleAttributeOption.yaml @@ -1,39 +1,27 @@ type: object -description: The attribute's attributes. +description: The details of a potential rule attribute. x-schemaName: AdminRuleAttributeOption required: - id - value - label - - field_type - - required - - disguised - operators properties: id: type: string title: id - description: The attribute's ID. + description: The rule attribute's ID, which is a rule's `attribute` it refers to. + example: customer_group value: type: string title: value - description: The attribute's value. + description: The rule attribute's value. + example: customer.groups.id label: type: string title: label - description: The attribute's label. - field_type: - type: string - title: field_type - description: The attribute's field type. - required: - type: boolean - title: required - description: The attribute's required. - disguised: - type: boolean - title: disguised - description: The attribute's disguised. + description: The rule attribute option's label. + example: Customer Group operators: type: array description: The attribute's operators. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminRuleValueOption.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminRuleValueOption.yaml index cb8776ea83d6a..fbfa2d15c8019 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminRuleValueOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminRuleValueOption.yaml @@ -1,20 +1,17 @@ type: object -description: The value's values. +description: The details of a potential rule value. x-schemaName: AdminRuleValueOption required: - - id - value - label properties: - id: - type: string - title: id - description: The value's ID. value: type: string title: value - description: The value's details. + description: The rule value's value. + example: reg_123 label: type: string title: label - description: The value's label. + description: The rule value's label. + example: Europe Region diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannel.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannel.yaml index 9b497e936cc5a..2311a9b68784f 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannel.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannel.yaml @@ -1,5 +1,5 @@ type: object -description: The order's sales channel. +description: The sales channel's details. x-schemaName: AdminSalesChannel required: - id @@ -26,22 +26,22 @@ properties: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The sales channel's created at. + description: The date the sales channel was created. updated_at: type: string format: date-time title: updated_at - description: The sales channel's updated at. + description: The date the sales channel was updated. deleted_at: type: string format: date-time title: deleted_at - description: The sales channel's deleted at. + description: The date the sales channel was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelDeleteResponse.yaml index fc933220020fc..0c2d3161a8fdb 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of deleting a sales channel. x-schemaName: AdminSalesChannelDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Sales Channel was deleted. + description: Whether the sales channel was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelResponse.yaml index baeb779f03e8c..bd930a26a7707 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminSalesChannelResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The sales channel's details. x-schemaName: AdminSalesChannelResponse required: - sales_channel diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminServiceZone.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminServiceZone.yaml index d0dff34efce40..425c15722a3bc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminServiceZone.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminServiceZone.yaml @@ -1,5 +1,5 @@ type: object -description: The service zone's service zones. +description: The shipping option's service zone. x-schemaName: AdminServiceZone required: - id diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneDeleteResponse.yaml index 488b2b6081228..7f3224a4326c8 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the service zone deletion. x-schemaName: AdminServiceZoneDeleteResponse required: - id @@ -9,14 +9,15 @@ properties: id: type: string title: id - description: The fulfillment set's ID. + description: The service zone's ID. object: type: string title: object description: The name of the deleted object. + default: service_zone deleted: type: boolean title: deleted - description: Whether the Fulfillment Set was deleted. + description: Whether the service zone was deleted. parent: $ref: ./AdminFulfillmentSet.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneResponse.yaml index dd8ff8c8d163b..32685446d39e1 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminServiceZoneResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The service zone's details. x-schemaName: AdminServiceZoneResponse required: - service_zone diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOption.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOption.yaml index 219dac6bdc583..9129f3bec1db6 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOption.yaml @@ -1,3 +1,105 @@ type: object -description: The shipping option's shipping options. +description: The shipping option's details. x-schemaName: AdminShippingOption +required: + - id + - name + - price_type + - service_zone_id + - service_zone + - provider_id + - provider + - shipping_option_type_id + - type + - shipping_profile_id + - shipping_profile + - rules + - prices + - data + - metadata + - created_at + - updated_at + - deleted_at +properties: + id: + type: string + title: id + description: The shipping option's ID. + name: + type: string + title: name + description: The shipping option's name. + price_type: + type: string + description: >- + The shipping option's price type. If it's `flat`, the price is fixed and + is set in the `prices` property. If it's `calculated`, the price is + calculated on checkout by the associated fulfillment provider. + enum: + - calculated + - flat + service_zone_id: + type: string + title: service_zone_id + description: The ID of the service zone this option belongs to. + service_zone: + type: object + provider_id: + type: string + title: provider_id + description: >- + The ID of the provider handling fulfillments created from this shipping + option. + provider: + $ref: ./AdminFulfillmentProvider.yaml + shipping_option_type_id: + type: string + title: shipping_option_type_id + description: The ID of the associated shipping option type. + type: + type: object + shipping_profile_id: + type: string + title: shipping_profile_id + description: The ID of the associated shipping profile. + shipping_profile: + $ref: ./AdminShippingProfile.yaml + rules: + type: array + description: The shipping option's rules. + items: + $ref: ./AdminShippingOptionRule.yaml + prices: + type: array + description: >- + The shipping option's prices. If the `price_type` is `calculated`, this + array will be empty since the price is calculated by the fulfillment + provider during checkout. + items: + $ref: ./AdminShippingOptionPrice.yaml + data: + type: object + description: >- + The shipping option's data, useful for the fulfillment provider handling + fulfillments created from this option. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping option's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping option was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping option was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping option was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionDeleteResponse.yaml index 141ba6526b478..459667c5ec1af 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the shipping option's deletion. x-schemaName: AdminShippingOptionDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Shipping Option was deleted. + description: Whether the shipping option was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionPrice.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionPrice.yaml new file mode 100644 index 0000000000000..95f76292c0a8d --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionPrice.yaml @@ -0,0 +1,76 @@ +type: object +description: The details of the shipping option's price. +x-schemaName: AdminShippingOptionPrice +required: + - price_rules + - rules_count + - id + - title + - currency_code + - amount + - raw_amount + - min_quantity + - max_quantity + - price_set_id + - created_at + - updated_at + - deleted_at +properties: + price_rules: + type: array + description: The price's rules. + items: + $ref: ./AdminShippingOptionPriceRule.yaml + rules_count: + type: number + title: rules_count + description: The number of rules the price has. + id: + type: string + title: id + description: The price's ID. + title: + type: string + title: title + description: The price's title. + currency_code: + type: string + title: currency_code + description: The price's currency code. + example: usd + amount: + type: number + title: amount + description: The price's amount. + raw_amount: + type: object + description: The price's raw amount. + min_quantity: + type: number + title: min_quantity + description: The minimum quantity required in the cart for this price to apply. + max_quantity: + type: number + title: max_quantity + description: >- + The maximum quantity that the cart's items must not surpass for this price + to apply. + price_set_id: + type: string + title: price_set_id + description: The ID of the price set this price belongs to. + created_at: + type: string + format: date-time + title: created_at + description: The date the price was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the price was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the price was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionPriceRule.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionPriceRule.yaml new file mode 100644 index 0000000000000..a705731a4197d --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionPriceRule.yaml @@ -0,0 +1,15 @@ +type: object +description: The details of a shipping option price's rule. +x-schemaName: AdminShippingOptionPriceRule +required: + - id + - value +properties: + id: + type: string + title: id + description: The price rule's ID. + value: + type: string + title: value + description: The price rule's value. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionResponse.yaml index dba509d7fdc79..b0b01a94abe0d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The shipping option's details. x-schemaName: AdminShippingOptionResponse required: - shipping_option diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionRule.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionRule.yaml index ed10fb27e4cb2..26069d9a56e62 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionRule.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingOptionRule.yaml @@ -1,5 +1,5 @@ type: object -description: The updated's details. +description: The shipping option rule's details. x-schemaName: AdminShippingOptionRule required: - id @@ -14,42 +14,46 @@ properties: id: type: string title: id - description: The updated's ID. + description: The shipping option rule's ID. attribute: type: string title: attribute - description: The updated's attribute. + description: The shipping option rule's attribute. + example: is_return operator: type: string title: operator - description: The updated's operator. + description: The shipping option rule's operator. + example: eq value: oneOf: - type: string title: value - description: The updated's value. + description: The rule's value. + example: '"true"' - type: array - description: The updated's value. + description: The rule's values. items: type: string title: value - description: The value's details. + description: A rule's value + example: '"true"' shipping_option_id: type: string title: shipping_option_id - description: The updated's shipping option id. + description: The ID of the shipping option this rule is for. created_at: type: string format: date-time title: created_at - description: The updated's created at. + description: The date the shipping option rule was created. updated_at: type: string format: date-time title: updated_at - description: The updated's updated at. + description: The date the shipping option rule was updated. deleted_at: type: string format: date-time title: deleted_at - description: The updated's deleted at. + description: The date the shipping option rule was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfile.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfile.yaml index 29549d5ff2633..1dc31c1b5b70d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfile.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfile.yaml @@ -1,3 +1,42 @@ type: object -description: The shipping option's shipping profile. +description: The shipping profile's details.. x-schemaName: AdminShippingProfile +properties: + id: + type: string + title: id + description: The shipping profile's ID. + name: + type: string + title: name + description: The shipping profile's name. + type: + type: string + title: type + description: The shipping profile's type. + metadata: + type: object + description: The shipping profile's metadata, holds custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping profile was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping profile was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping profile was deleted. +required: + - id + - name + - type + - metadata + - created_at + - updated_at + - deleted_at diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileDeleteResponse.yaml index bca17d5e8b882..ed0e931fd6bd0 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the shipping profile's deletion. x-schemaName: AdminShippingProfileDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Shipping Profile was deleted. + description: Whether the shipping profile was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileResponse.yaml index ce83a083726fc..00fa3dc1ab3a9 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminShippingProfileResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The shipping profile's details. x-schemaName: AdminShippingProfileResponse required: - shipping_profile diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocation.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocation.yaml index 76f80ec99cb78..238431cd5415c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocation.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocation.yaml @@ -1,5 +1,5 @@ type: object -description: The parent's location. +description: The stock location's details. x-schemaName: AdminStockLocation required: - id @@ -17,21 +17,71 @@ properties: address_id: type: string title: address_id - description: The location's address id. + description: The ID of the associated address. address: - $ref: ./AdminStockLocationAddress.yaml + type: object + description: The details of the stock location address. + x-schemaName: AdminStockLocationAddress + properties: + id: + type: string + title: id + description: The address's ID. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + company: + type: string + title: company + description: The address's company. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + city: + type: string + title: city + description: The address's city. + phone: + type: string + title: phone + description: The address's phone. + postal_code: + type: string + title: postal_code + description: The address's postal code. + province: + type: string + title: province + description: The address's province. + required: + - id + - address_1 + - address_2 + - company + - country_code + - city + - phone + - postal_code + - province sales_channels: type: array - description: The location's sales channels. + description: The sales channels associated with the location. items: $ref: ./AdminSalesChannel.yaml fulfillment_providers: type: array - description: The location's fulfillment providers. + description: The fulfillment providers associated with the location. items: $ref: ./AdminFulfillmentProvider.yaml fulfillment_sets: type: array - description: The location's fulfillment sets. + description: The fulfillment sets associated with the location. items: type: object diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationAddress.yaml deleted file mode 100644 index 03be8aa3dde15..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationAddress.yaml +++ /dev/null @@ -1,3 +0,0 @@ -type: object -description: The location's address. -x-schemaName: AdminStockLocationAddress diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationDeleteResponse.yaml index 7d1160157d94b..cb05f2704ae3f 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the stock location's deletion. x-schemaName: AdminStockLocationDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Stock Location was deleted. + description: Whether the stock location was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationListResponse.yaml index f8181758b16a2..9f23c060601a1 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of stock locations. x-schemaName: AdminStockLocationListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The stock location's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The stock location's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The stock location's count. + description: The total number of items. stock_locations: type: array - description: The stock location's stock locations. + description: The list of stock locations. items: $ref: ./AdminStockLocation.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationResponse.yaml index 68d6a4db180db..19f1d66a39eac 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStockLocationResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The stock location's details. x-schemaName: AdminStockLocationResponse required: - stock_location diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStore.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStore.yaml index a56500fc7b544..32f483dc82209 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStore.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStore.yaml @@ -28,25 +28,25 @@ properties: default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the sales channel used by default in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the region used by default in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the stock location used by default in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The store's created at. + description: The date the store was created. updated_at: type: string format: date-time title: updated_at - description: The store's updated at. + description: The date the store was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStoreCurrency.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStoreCurrency.yaml index 5014c7b7bce22..a0e2ccb92dd8d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStoreCurrency.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStoreCurrency.yaml @@ -1,5 +1,5 @@ type: object -description: The supported currency's supported currencies. +description: The details of a store's currency. x-schemaName: AdminStoreCurrency required: - id @@ -14,33 +14,34 @@ properties: id: type: string title: id - description: The supported currency's ID. + description: The currency's ID. currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd store_id: type: string title: store_id - description: The supported currency's store id. + description: The ID of the store this currency belongs to. is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether this currency is the default in the store. currency: $ref: ./AdminCurrency.yaml created_at: type: string format: date-time title: created_at - description: The supported currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The supported currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The supported currency's deleted at. + description: The date the currency was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStoreListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStoreListResponse.yaml index 33099c28f179f..639f93778b8d0 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStoreListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStoreListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of stores. x-schemaName: AdminStoreListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The store's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The store's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The store's count. + description: The total number of items. stores: type: array - description: The store's stores. + description: The list of stores. items: $ref: ./AdminStore.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminStoreResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminStoreResponse.yaml index c24cc35690d2f..d335ebde9825e 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminStoreResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminStoreResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The store's details. x-schemaName: AdminStoreResponse required: - store diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRate.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRate.yaml index f0321f56518be..7972123ffef44 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRate.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRate.yaml @@ -1,5 +1,5 @@ type: object -description: The tax rate's parent. +description: The tax rate's details. x-schemaName: AdminTaxRate required: - id @@ -20,57 +20,61 @@ properties: id: type: string title: id - description: The parent's ID. + description: The tax rate's ID. rate: type: number title: rate - description: The parent's rate. + description: The rate to charge. + example: 10 code: type: string title: code - description: The parent's code. + description: The code the tax rate is identified by. name: type: string title: name - description: The parent's name. + description: The tax rate's name. metadata: type: object - description: The parent's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. tax_region_id: type: string title: tax_region_id - description: The parent's tax region id. + description: The ID of the tax region this rate belongs to. is_combinable: type: boolean title: is_combinable - description: The parent's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates is_default: type: boolean title: is_default - description: The parent's is default. + description: Whether this tax rate is the default in the tax region. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the tax rate was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the tax rate was updated. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The date the tax rate was deleted. created_by: type: string title: created_by - description: The parent's created by. + description: The ID of the user that created the tax rate. tax_region: $ref: ./AdminTaxRegion.yaml rules: type: array - description: The parent's rules. + description: The tax rate's rules. items: $ref: ./AdminTaxRateRule.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateDeleteResponse.yaml index 6c284786d9db4..88c4b0ebb1d6f 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the tax rate deletion. x-schemaName: AdminTaxRateDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Tax Rate was deleted. + description: Whether the tax rate was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateResponse.yaml index 2dd828e446d57..e4888f9c3a00a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The tax rate's details. x-schemaName: AdminTaxRateResponse required: - tax_rate diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateRule.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateRule.yaml index 8e0ff14b5d49a..2d88ad2ed823a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateRule.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRateRule.yaml @@ -1,5 +1,5 @@ type: object -description: The rule's rules. +description: The tax rate rule's details. x-schemaName: AdminTaxRateRule required: - reference @@ -8,8 +8,10 @@ properties: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of a record in the table that this rule references. + example: ptyp_1 diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegion.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegion.yaml index 5ee5e6b8e004a..0c5867f445ed9 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegion.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegion.yaml @@ -1,17 +1,11 @@ type: object -description: The parent's tax region. +description: The tax region's details. x-schemaName: AdminTaxRegion required: - id - - rate - - code - country_code - province_code - - name - metadata - - tax_region_id - - is_combinable - - is_default - parent_id - created_at - updated_at @@ -25,67 +19,44 @@ properties: type: string title: id description: The tax region's ID. - rate: - type: number - title: rate - description: The tax region's rate. - code: - type: string - title: code - description: The tax region's code. country_code: type: string title: country_code description: The tax region's country code. + example: us province_code: type: string title: province_code description: The tax region's province code. - name: - type: string - title: name - description: The tax region's name. metadata: type: object - description: The tax region's metadata. - tax_region_id: - type: string - title: tax_region_id - description: The tax region's tax region id. - is_combinable: - type: boolean - title: is_combinable - description: The tax region's is combinable. - is_default: - type: boolean - title: is_default - description: The tax region's is default. + description: The tax region's metadata, can hold custom key-value pairs. parent_id: type: string title: parent_id - description: The tax region's parent id. + description: The ID of the parent tax region. created_at: type: string format: date-time title: created_at - description: The tax region's created at. + description: The date the tax region was created. updated_at: type: string format: date-time title: updated_at - description: The tax region's updated at. + description: The date the tax region was updated. deleted_at: type: string format: date-time title: deleted_at - description: The tax region's deleted at. + description: The date the tax region was deleted. created_by: type: string title: created_by - description: The tax region's created by. + description: The ID of the user that created the tax region. tax_rates: type: array - description: The tax region's tax rates. + description: The tax region's rates. items: type: object parent: diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionDeleteResponse.yaml index 235dd86a80390..be8ab35c7c3fe 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the tax region deletion. x-schemaName: AdminTaxRegionDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the Tax Region was deleted. + description: Whether the tax region was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionResponse.yaml index 0c200e26d0597..b1cfcf7062d15 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminTaxRegionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The tax region's details. x-schemaName: AdminTaxRegionResponse required: - tax_region diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateApiKey.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateApiKey.yaml index 1858893589b52..2f9911872eda1 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateApiKey.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateApiKey.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in an API key. x-schemaName: AdminUpdateApiKey required: - title @@ -7,4 +7,4 @@ properties: title: type: string title: title - description: The api key's title. + description: The API key's title. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCollection.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCollection.yaml index 22a9be4f57e8c..63cfe987d02d7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCollection.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCollection.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in a collection. x-schemaName: AdminUpdateCollection properties: title: @@ -12,4 +12,4 @@ properties: description: The collection's handle. metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCustomerGroup.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCustomerGroup.yaml index acb0253445aa2..57fb90e7151e6 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCustomerGroup.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateCustomerGroup.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in a customer group. x-schemaName: AdminUpdateCustomerGroup properties: name: @@ -8,4 +8,4 @@ properties: description: The customer group's name. metadata: type: object - description: The customer group's metadata. + description: The customer group's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePriceList.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePriceList.yaml index 97688d7c5f612..50737f5decd5b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePriceList.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePriceList.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: the details to update in a price list. x-schemaName: AdminUpdatePriceList properties: title: @@ -13,23 +13,36 @@ properties: starts_at: type: string title: starts_at - description: The price list's starts at. + description: The date the price list starts. ends_at: type: string title: ends_at - description: The price list's ends at. + description: The date the price list ends. status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. + example: + customer_group_id: + - cusgrp_123 diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePricePreference.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePricePreference.yaml index 0c5f879d8fba9..cc04155d197cd 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePricePreference.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdatePricePreference.yaml @@ -1,16 +1,18 @@ type: object -description: SUMMARY +description: The details to update in the price preference. x-schemaName: AdminUpdatePricePreference properties: attribute: type: string title: attribute description: The price preference's attribute. + example: region_id value: type: string title: value description: The price preference's value. + example: reg_123 is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The price preference's is tax inclusive. + description: Whether prices are tax inclusive for this price preference. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProduct.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProduct.yaml index 844455161e607..23a5ed5cc947b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProduct.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProduct.yaml @@ -1,70 +1,77 @@ type: object -description: The update's details. +description: The product's details. x-schemaName: AdminUpdateProduct properties: title: type: string title: title - description: The update's title. + description: The product's title. subtitle: type: string title: subtitle - description: The update's subtitle. + description: The product's subtitle. description: type: string title: description - description: The update's description. + description: The product's description. is_giftcard: type: boolean title: is_giftcard - description: The update's is giftcard. + description: Whether the product is a gift card. discountable: type: boolean title: discountable - description: The update's discountable. + description: Whether discounts can be applied on the product. images: type: array - description: The update's images. + description: The product's images. items: type: object - description: The image's images. + description: The image's details. required: - url properties: url: type: string title: url - description: The image's url. + description: The image's URL. thumbnail: type: string title: thumbnail - description: The update's thumbnail. + description: The product's thumbnail URL. handle: type: string title: handle - description: The update's handle. + description: The product's unique handle. status: - type: string - description: The update's status. - enum: - - draft - - proposed - - published - - rejected + oneOf: + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + description: The product's status. type_id: type: string title: type_id - description: The update's type id. + description: The ID of the product's type. collection_id: type: string title: collection_id - description: The update's collection id. + description: The ID of the product's collection. categories: type: array - description: The update's categories. + description: The product's categories. items: type: object - description: The category's categories. + description: The product's category. required: - id properties: @@ -74,10 +81,10 @@ properties: description: The category's ID. tags: type: array - description: The update's tags. + description: The product's tags. items: type: object - description: The tag's tags. + description: The product's tag. required: - id properties: @@ -87,181 +94,24 @@ properties: description: The tag's ID. options: type: array - description: The update's options. + description: The product's options. items: $ref: ./AdminUpdateProductOption.yaml variants: type: array - description: The update's variants. + description: >- + The product's variants. You can add new variants or update existing ones, + passing their IDs in the object. items: oneOf: - - type: object - description: The variant's variants. - x-schemaName: AdminCreateProductVariant - required: - - title - - prices - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: ./AdminCreateProductVariantPrice.yaml - options: - type: object - description: The variant's options. - - type: object - description: The variant's variants. - x-schemaName: AdminUpdateProductVariant - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: ./AdminCreateProductVariantPrice.yaml - options: - type: object - description: The variant's options. + - $ref: ./AdminCreateProductVariant.yaml + - $ref: ./AdminUpdateProductVariant.yaml sales_channels: type: array - description: The update's sales channels. + description: The sales channels that the product is available in. items: type: object - description: The sales channel's sales channels. + description: The sales channel's details. required: - id properties: @@ -272,35 +122,35 @@ properties: weight: type: number title: weight - description: The update's weight. + description: The product's weight. length: type: number title: length - description: The update's length. + description: The product's length. height: type: number title: height - description: The update's height. + description: The product's height. width: type: number title: width - description: The update's width. + description: The product's width. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product's MID code. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product's origin country. material: type: string title: material - description: The update's material. + description: The product's material. metadata: type: object - description: The update's metadata. + description: The product's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductOption.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductOption.yaml index bfdca1a5cba73..046aa998154fc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductOption.yaml @@ -1,15 +1,15 @@ type: object -description: SUMMARY +description: The details to update in a product option. x-schemaName: AdminUpdateProductOption properties: title: type: string title: title - description: The product's title. + description: The option's title. values: type: array - description: The product's values. + description: The option's values. items: type: string title: values - description: The value's values. + description: An option value. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductVariant.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductVariant.yaml index c0429b85e9364..59f99cff83c1d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductVariant.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateProductVariant.yaml @@ -1,79 +1,81 @@ type: object -description: The update's details. +description: The properties to update of a product variant. x-schemaName: AdminUpdateProductVariant properties: title: type: string title: title - description: The update's title. + description: The product variant's title. sku: type: string title: sku - description: The update's sku. + description: The product variant's SKU. ean: type: string title: ean - description: The update's ean. + description: The product variant's EAN. upc: type: string title: upc - description: The update's upc. + description: The product variant's UPC. barcode: type: string title: barcode - description: The update's barcode. + description: The product variant's barcode. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product variant's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product variant's MID code. allow_backorder: type: boolean title: allow_backorder - description: The update's allow backorder. + description: Whether customers can order the variant even if it's not in stock. manage_inventory: type: boolean title: manage_inventory - description: The update's manage inventory. + description: >- + Whether the Medusa application manages the variant's inventory. If + disabled, the product variant is always considered in stock. variant_rank: type: number title: variant_rank - description: The update's variant rank. + description: The product variant's rank among its siblings. weight: type: number title: weight - description: The update's weight. + description: The product variant's weight. length: type: number title: length - description: The update's length. + description: The product variant's length. height: type: number title: height - description: The update's height. + description: The product variant's height. width: type: number title: width - description: The update's width. + description: The product variant's width. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product variant's origin country. material: type: string title: material - description: The update's material. + description: The product variant's material. metadata: type: object - description: The update's metadata. + description: The product variant's metadata, can hold custom key-value pairs. prices: type: array - description: The update's prices. + description: The product variant's prices. items: $ref: ./AdminCreateProductVariantPrice.yaml options: type: object - description: The update's options. + description: The product variant's options. diff --git a/www/apps/api-reference/specs/store/components/schemas/UpdateOrderReturnReason.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateReturnReason.yaml similarity index 62% rename from www/apps/api-reference/specs/store/components/schemas/UpdateOrderReturnReason.yaml rename to www/apps/api-reference/specs/store/components/schemas/AdminUpdateReturnReason.yaml index 581ad731dc89d..3299988196d04 100644 --- a/www/apps/api-reference/specs/store/components/schemas/UpdateOrderReturnReason.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateReturnReason.yaml @@ -1,11 +1,7 @@ type: object -description: SUMMARY -x-schemaName: UpdateOrderReturnReason +description: The details to update in a return reason. +x-schemaName: AdminUpdateReturnReason properties: - id: - type: string - title: id - description: The return reason's ID. label: type: string title: label @@ -20,4 +16,7 @@ properties: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. +required: + - value + - label diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateSalesChannel.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateSalesChannel.yaml index 8f30103306950..db5e76e560aa0 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateSalesChannel.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateSalesChannel.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in the sales channel. x-schemaName: AdminUpdateSalesChannel properties: name: @@ -13,7 +13,7 @@ properties: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStockLocation.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStockLocation.yaml index 2312fd5e3c4cd..936fe6f522958 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStockLocation.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStockLocation.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in a stock location. x-schemaName: AdminUpdateStockLocation properties: name: @@ -8,7 +8,9 @@ properties: description: The stock location's name. address: type: object - description: The stock location's address. + description: >- + The stock location's address. Pass this property if you're creating a new + address to associate with the location. required: - address_1 - country_code @@ -16,11 +18,11 @@ properties: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -33,6 +35,7 @@ properties: type: string title: country_code description: The address's country code. + example: us phone: type: string title: phone @@ -48,7 +51,9 @@ properties: address_id: type: string title: address_id - description: The stock location's address id. + description: >- + The ID of an existing stock location address to associate the stock + location with. metadata: type: object - description: The stock location's metadata. + description: The stock location's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStore.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStore.yaml index 7df88b6bc0fb4..e8c4463b52cdc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStore.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateStore.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in a store. x-schemaName: AdminUpdateStore properties: name: @@ -11,34 +11,35 @@ properties: description: The store's supported currencies. items: type: object - description: The supported currency's supported currencies. + description: A store currency. required: - currency_code properties: currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether the currency is the default in the store. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The supported currency's is tax inclusive. + description: Whether prices using this currency are tax inclusive. default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the default sales channel in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the default region in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the default stock location in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateTaxRate.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateTaxRate.yaml index 5580cc1ef659f..8000de42a91c3 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateTaxRate.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateTaxRate.yaml @@ -1,21 +1,21 @@ type: object -description: SUMMARY +description: The properties to update in the tax rate. x-schemaName: AdminUpdateTaxRate properties: rate: type: number title: rate - description: The tax rate's rate. + description: The rate to charge. code: type: string title: code - description: The tax rate's code. + description: The code that the tax rate is identified by. rules: type: array description: The tax rate's rules. items: type: object - description: The rule's rules. + description: A tax rate rule. required: - reference - reference_id @@ -23,11 +23,13 @@ properties: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of the record in the table that the rule references. + example: ptyp_123 name: type: string title: name @@ -35,11 +37,14 @@ properties: is_default: type: boolean title: is_default - description: The tax rate's is default. + description: Whether the tax rate is the default in the store. is_combinable: type: boolean title: is_combinable - description: The tax rate's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates metadata: type: object - description: The tax rate's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateUser.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateUser.yaml index 1d1bd54d5aba2..2fc8ed46f581e 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateUser.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateUser.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update in a user. x-schemaName: AdminUpdateUser properties: first_name: @@ -13,4 +13,4 @@ properties: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateVariantInventoryItem.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateVariantInventoryItem.yaml index 8db01d8c4c5cd..b61c9d020f124 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpdateVariantInventoryItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpdateVariantInventoryItem.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The properties to update of the variant's inventory item association. x-schemaName: AdminUpdateVariantInventoryItem required: - required_quantity @@ -7,4 +7,10 @@ properties: required_quantity: type: number title: required_quantity - description: The product's required quantity. + description: >- + The number of units a single quantity is equivalent to. For example, if a + customer orders one quantity of the variant, Medusa checks the + availability of the quantity multiplied by the value set for + `required_quantity`. When the customer orders the quantity, Medusa + reserves the ordered quantity multiplied by the value set for + `required_quantity`. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUpsertStockLocationAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUpsertStockLocationAddress.yaml index b0e8d7c0332b6..5c265c5e0e898 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUpsertStockLocationAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUpsertStockLocationAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The stock location's address. +description: The details of the stock location address to create. x-schemaName: AdminUpsertStockLocationAddress required: - address_1 @@ -8,11 +8,11 @@ properties: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -21,6 +21,7 @@ properties: type: string title: country_code description: The address's country code. + example: usd city: type: string title: city diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUser.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUser.yaml index 6fb258123e254..c3bca505cb895 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUser.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUser.yaml @@ -32,22 +32,22 @@ properties: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. metadata: type: object - description: The user's metadata. + description: The user's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The user's created at. + description: The date the user was created. updated_at: type: string format: date-time title: updated_at - description: The user's updated at. + description: The date the user was updated. deleted_at: type: string format: date-time title: deleted_at - description: The user's deleted at. + description: The date the user was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUserDeleteResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUserDeleteResponse.yaml index fb9888ff23788..72ede85811657 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUserDeleteResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUserDeleteResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the deleted user. x-schemaName: AdminUserDeleteResponse required: - id @@ -18,4 +18,4 @@ properties: deleted: type: boolean title: deleted - description: Whether the User was deleted. + description: Whether the user was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUserListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUserListResponse.yaml index 7aac88724afa2..e595dad0cd6f0 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUserListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUserListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of users. x-schemaName: AdminUserListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The user's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The user's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The user's count. + description: The total number of items. users: type: array - description: The user's users. + description: The list of users. items: $ref: ./AdminUser.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminUserResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminUserResponse.yaml index dfc78e1bc996d..ed4678e0a0cac 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminUserResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminUserResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The user's details. x-schemaName: AdminUserResponse required: - user diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecution.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecution.yaml index 1c803655b9926..c71f1c4364f3b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecution.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecution.yaml @@ -1,5 +1,5 @@ type: object -description: The workflows execution's workflow execution. +description: The workflows execution's details. x-schemaName: AdminWorkflowExecution required: - id @@ -18,11 +18,11 @@ properties: workflow_id: type: string title: workflow_id - description: The workflow execution's workflow id. + description: The ID of the workflow. transaction_id: type: string title: transaction_id - description: The workflow execution's transaction id. + description: The workflow execution's transaction ID. execution: $ref: ./AdminWorkflowExecutionExecution.yaml context: @@ -42,14 +42,14 @@ properties: type: string format: date-time title: created_at - description: The workflow execution's created at. + description: The date the workflow execution was created. updated_at: type: string format: date-time title: updated_at - description: The workflow execution's updated at. + description: The date the workflow execution was updated. deleted_at: type: string format: date-time title: deleted_at - description: The workflow execution's deleted at. + description: The date the workflow execution was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionExecution.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionExecution.yaml index e589756af2294..6b780c9e0abab 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionExecution.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionExecution.yaml @@ -1,9 +1,152 @@ type: object -description: The workflow execution's execution. +description: The workflow execution's steps details. x-schemaName: AdminWorkflowExecutionExecution required: - steps properties: steps: type: object - description: The execution's steps. + description: >- + The execution's steps. Each object key is a step ID, and the value is the + object whose properties are shown below. + required: + - id + - invoke + - definition + - compensate + - depth + - startedAt + additionalProperties: + type: object + properties: + id: + type: string + title: id + description: The step's ID. + invoke: + type: object + description: The state of the step's invokation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The invokation step's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The invokation step's state. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + definition: + type: object + description: The step's definition details. + x-schemaName: WorkflowExecutionDefinition + properties: + async: + type: boolean + title: async + description: Whether the step is async. + compensateAsync: + type: boolean + title: compensateAsync + description: Whether the compensation function of the step is async. + noCompensation: + type: boolean + title: noCompensation + description: Whether the step doesn't have a compensation function. + continueOnPermanentFailure: + type: boolean + title: continueOnPermanentFailure + description: >- + Whether the step continues executing even if its status is + changed to failed. + maxRetries: + type: number + title: maxRetries + description: The maximum number of times to retry the step. + noWait: + type: boolean + title: noWait + description: >- + Whether the workflow shouldn't wait for the step to finish + before moving to the next step. + default: false + retryInterval: + type: number + title: retryInterval + description: >- + The interval in seconds between retry attempts when the step + fails. + retryIntervalAwaiting: + type: number + title: retryIntervalAwaiting + description: >- + The interval in seconds to retry a step even if its status is + `waiting_response`. + saveResponse: + type: boolean + title: saveResponse + description: Whether the step's response is stored. + timeout: + type: number + title: timeout + description: >- + The maximum time in seconds to wait for this step to complete. + If the step exceeds this time, the step's state is changed to + `timeout`, but the step continues executing. + compensate: + type: object + description: The state of the step's compensation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The compensation function's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The compensation function's status. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + depth: + type: number + title: depth + description: The step's depth in the workflow's execution. + startedAt: + type: number + title: startedAt + description: The timestamp the step started executing. diff --git a/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionResponse.yaml index 2c21bd3e4e1ac..c57cb857d135a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/AdminWorkflowExecutionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The workflow execution's details. x-schemaName: AdminWorkflowExecutionResponse required: - workflow_execution diff --git a/www/apps/api-reference/specs/store/components/schemas/ApiKeyResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/ApiKeyResponse.yaml index df83ca78ffa72..f5de0a21507a8 100644 --- a/www/apps/api-reference/specs/store/components/schemas/ApiKeyResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/ApiKeyResponse.yaml @@ -1,5 +1,5 @@ type: object -description: The api key's details. +description: The API key's details. x-schemaName: ApiKeyResponse required: - id @@ -16,44 +16,50 @@ properties: id: type: string title: id - description: The api key's ID. + description: The API key's ID. token: type: string title: token - description: The api key's token. + description: The API key's token. redacted: type: string title: redacted - description: The api key's redacted. + description: >- + The redacted form of the API key's token. This is useful when showing + portion of the token. For example `sk_...123`. title: type: string title: title - description: The api key's title. + description: The API key's title. type: type: string + description: >- + The API key's type. `secret` API keys are used for authenticating admin + users, and `publishable` API key are used for storefronts and similar + clients to scope requests to sales channels. enum: - secret - publishable last_used_at: type: string title: last_used_at - description: The api key's last used at. + description: The date the API key was last used. format: date-time created_by: type: string title: created_by - description: The api key's created by. + description: The ID of the user that created the API key. created_at: type: string title: created_at - description: The api key's created at. + description: The date the API key was created. format: date-time revoked_by: type: string title: revoked_by - description: The api key's revoked by. + description: The ID of the user that revoked the API key. revoked_at: type: string title: revoked_at - description: The api key's revoked at. + description: The date the API key was revoked. format: date-time diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseApplicationMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseApplicationMethod.yaml deleted file mode 100644 index 4e1e727e4aa27..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/BaseApplicationMethod.yaml +++ /dev/null @@ -1,61 +0,0 @@ -type: object -description: The promotion's application method. -x-schemaName: BaseApplicationMethod -required: - - id -properties: - id: - type: string - title: id - description: The application method's ID. - type: - type: string - description: The application method's type. - enum: - - fixed - - percentage - target_type: - type: string - description: The application method's target type. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: The application method's allocation. - enum: - - each - - across - value: - type: number - title: value - description: The application method's value. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: The application method's max quantity. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: The application method's buy rules min quantity. - apply_to_quantity: - type: number - title: apply_to_quantity - description: The application method's apply to quantity. - promotion: - $ref: ./BasePromotion.yaml - target_rules: - type: array - description: The application method's target rules. - items: - $ref: ./BasePromotionRule.yaml - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: ./BasePromotionRule.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCalculatedPriceSet.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCalculatedPriceSet.yaml index 70dd7bf660f95..b4fea699491a1 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCalculatedPriceSet.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCalculatedPriceSet.yaml @@ -50,6 +50,60 @@ properties: calculated_price: type: object description: The calculated price's details. + properties: + id: + type: string + title: id + description: The calculated price's ID. + price_list_id: + type: string + title: price_list_id + description: The calculated price's price list id. + price_list_type: + type: string + title: price_list_type + description: The calculated price's price list type. + min_quantity: + type: number + title: min_quantity + description: The calculated price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The calculated price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity original_price: type: object description: The calculated price's original price. + properties: + id: + type: string + title: id + description: The original price's ID. + price_list_id: + type: string + title: price_list_id + description: The original price's price list id. + price_list_type: + type: string + title: price_list_type + description: The original price's price list type. + min_quantity: + type: number + title: min_quantity + description: The original price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The original price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCapture.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCapture.yaml index 59baa7033c5fc..422f58f107958 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCapture.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCapture.yaml @@ -1,3 +1,28 @@ type: object -description: The capture's captures. +description: The details of a captured payment. x-schemaName: BaseCapture +required: + - id + - amount + - created_at + - payment +properties: + id: + type: string + title: id + description: The payment capture's ID. + amount: + type: number + title: amount + description: The captured amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the capture was created. + created_by: + type: string + title: created_by + description: The ID of the user that captured the payment. + payment: + $ref: ./BasePayment.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCart.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCart.yaml index 5cc50d1e73587..e2ad47617f47d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCart.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCart.yaml @@ -1,3 +1,173 @@ type: object description: The item's cart. x-schemaName: BaseCart +required: + - id + - currency_code + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + id: + type: string + title: id + description: The cart's ID. + region: + $ref: ./BaseRegion.yaml + region_id: + type: string + title: region_id + description: The cart's region id. + customer_id: + type: string + title: customer_id + description: The cart's customer id. + sales_channel_id: + type: string + title: sales_channel_id + description: The cart's sales channel id. + email: + type: string + title: email + description: The cart's email. + format: email + currency_code: + type: string + title: currency_code + description: The cart's currency code. + shipping_address: + $ref: ./BaseCartAddress.yaml + billing_address: + $ref: ./BaseCartAddress.yaml + items: + type: array + description: The cart's items. + items: + $ref: ./BaseCartLineItem.yaml + shipping_methods: + type: array + description: The cart's shipping methods. + items: + $ref: ./BaseCartShippingMethod.yaml + payment_collection: + $ref: ./BasePaymentCollection.yaml + metadata: + type: object + description: The cart's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The cart's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The cart's updated at. + original_item_total: + type: number + title: original_item_total + description: The cart's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The cart's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The cart's original item tax total. + item_total: + type: number + title: item_total + description: The cart's item total. + item_subtotal: + type: number + title: item_subtotal + description: The cart's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The cart's item tax total. + original_total: + type: number + title: original_total + description: The cart's original total. + original_subtotal: + type: number + title: original_subtotal + description: The cart's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The cart's original tax total. + total: + type: number + title: total + description: The cart's total. + subtotal: + type: number + title: subtotal + description: The cart's subtotal. + tax_total: + type: number + title: tax_total + description: The cart's tax total. + discount_total: + type: number + title: discount_total + description: The cart's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The cart's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The cart's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The cart's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The cart's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The cart's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The cart's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The cart's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The cart's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The cart's original shipping tax total. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCartAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCartAddress.yaml index 0cc3faf4c1611..e85cfd8a57da6 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCartAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCartAddress.yaml @@ -1,69 +1,3 @@ type: object -description: The parent's billing address. +description: The cart's shipping address. x-schemaName: BaseCartAddress -required: - - id - - created_at - - updated_at -properties: - id: - type: string - title: id - description: The billing address's ID. - customer_id: - type: string - title: customer_id - description: The billing address's customer id. - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: - type: string - title: last_name - description: The billing address's last name. - phone: - type: string - title: phone - description: The billing address's phone. - company: - type: string - title: company - description: The billing address's company. - address_1: - type: string - title: address_1 - description: The billing address's address 1. - address_2: - type: string - title: address_2 - description: The billing address's address 2. - city: - type: string - title: city - description: The billing address's city. - country_code: - type: string - title: country_code - description: The billing address's country code. - province: - type: string - title: province - description: The billing address's province. - postal_code: - type: string - title: postal_code - description: The billing address's postal code. - metadata: - type: object - description: The billing address's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The billing address's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The billing address's updated at. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCartLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCartLineItem.yaml index 01d92160309eb..df665559ec60a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCartLineItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCartLineItem.yaml @@ -1,5 +1,5 @@ type: object -description: The item's items. +description: The tax line's item. x-schemaName: BaseCartLineItem required: - id @@ -40,17 +40,9 @@ properties: title: thumbnail description: The item's thumbnail. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: ./IBigNumber.yaml + type: number + title: quantity + description: The item's quantity. product: $ref: ./BaseProduct.yaml product_id: @@ -115,29 +107,13 @@ properties: title: is_tax_inclusive description: The item's is tax inclusive. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: ./IBigNumber.yaml + type: number + title: compare_at_unit_price + description: The item's compare at unit price. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: ./IBigNumber.yaml + type: number + title: unit_price + description: The item's unit price. tax_lines: type: array description: The item's tax lines. @@ -173,134 +149,46 @@ properties: title: deleted_at description: The item's deleted at. original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The item's original total. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The item's original subtotal. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The item's original tax total. item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: ./IBigNumber.yaml + type: number + title: item_total + description: The item's item total. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: item_subtotal + description: The item's item subtotal. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: item_tax_total + description: The item's item tax total. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The item's total. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The item's subtotal. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The item's tax total. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The item's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The item's discount tax total. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCartShippingMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCartShippingMethod.yaml index 6f613ecf88bd6..95520cd96fe0c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCartShippingMethod.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCartShippingMethod.yaml @@ -1,5 +1,5 @@ type: object -description: The shipping method's shipping methods. +description: A cart's shipping method. x-schemaName: BaseCartShippingMethod required: - id @@ -25,7 +25,7 @@ properties: cart_id: type: string title: cart_id - description: The shipping method's cart id. + description: The ID of the cart this shipping method belongs to. name: type: string title: name @@ -35,31 +35,28 @@ properties: title: description description: The shipping method's description. amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: ./IBigNumber.yaml + type: number + title: amount + description: The shipping method's amount. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount is tax inclusive. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: >- + The shipping method's data, useful for fulfillment handling by third-party + services. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -67,112 +64,52 @@ properties: $ref: ./BaseShippingMethodTaxLine.yaml adjustments: type: array - description: The shipping method's adjustments. + description: The shipping method's adjustments, such as applied promotions. items: $ref: ./BaseShippingMethodAdjustment.yaml created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The shipping method's total amount including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The total amount discounted. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseClaim.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseClaim.yaml deleted file mode 100644 index 85d6a02519dbd..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/BaseClaim.yaml +++ /dev/null @@ -1,3 +0,0 @@ -type: object -description: The order change's claim. -x-schemaName: BaseClaim diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseClaimItem.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseClaimItem.yaml index 27c9efe9968e9..fe407754bed6c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseClaimItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseClaimItem.yaml @@ -1,5 +1,5 @@ type: object -description: The claim item's claim items. +description: The claim item's details. x-schemaName: BaseClaimItem required: - id @@ -17,22 +17,22 @@ properties: claim_id: type: string title: claim_id - description: The claim item's claim id. + description: The ID of the claim this item belongs to. order_id: type: string title: order_id - description: The claim item's order id. + description: The ID of the order this item belongs to. item_id: type: string title: item_id - description: The claim item's item id. + description: The ID of the item in the order. quantity: type: number title: quantity - description: The claim item's quantity. + description: The quantity claimed. reason: type: string - description: The claim item's reason. + description: The claim's reason. enum: - missing_item - wrong_item @@ -40,17 +40,28 @@ properties: - other raw_quantity: type: object - description: The claim item's raw quantity. + description: The quantity claimed. + properties: + value: + oneOf: + - type: string + title: value + description: The raw quantity's value. + - type: number + title: value + description: The raw quantity's value. + required: + - value metadata: type: object - description: The claim item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The claim item's created at. + description: The date the claim was created. updated_at: type: string format: date-time title: updated_at - description: The claim item's updated at. + description: The date the claim was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCollection.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCollection.yaml index 19efac7da22bb..6b7390021c631 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCollection.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCollection.yaml @@ -1,3 +1,3 @@ type: object -description: The product's collection. +description: The collection's details. x-schemaName: BaseCollection diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseCustomerAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseCustomerAddress.yaml index 906bc9231dd22..c894dbf6d0cbb 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseCustomerAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseCustomerAddress.yaml @@ -1,3 +1,97 @@ type: object -description: The address's addresses. +description: The customer's address. x-schemaName: BaseCustomerAddress +required: + - id + - address_name + - is_default_shipping + - is_default_billing + - customer_id + - company + - first_name + - last_name + - address_1 + - address_2 + - city + - country_code + - province + - postal_code + - phone + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The address's ID. + address_name: + type: string + title: address_name + description: The address's name. + is_default_shipping: + type: boolean + title: is_default_shipping + description: Whether the address is the default shipping address. + is_default_billing: + type: boolean + title: is_default_billing + description: Whether the address is the default billing address. + customer_id: + type: string + title: customer_id + description: The ID of the customer that this address belongs to. + company: + type: string + title: company + description: The customer's company. + first_name: + type: string + title: first_name + description: The customer's first name. + last_name: + type: string + title: last_name + description: The customer's last name. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + city: + type: string + title: city + description: The address's city. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + province: + type: string + title: province + description: The address's province. + postal_code: + type: string + title: postal_code + description: The address's postal code. + phone: + type: string + title: phone + description: The address's phone. + metadata: + type: object + description: The address's metadata, used to store custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The address's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The address's update date. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseExchangeItem.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseExchangeItem.yaml index 852b2e0a94599..82c98c6dbf2f4 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseExchangeItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseExchangeItem.yaml @@ -1,5 +1,5 @@ type: object -description: The additional item's additional items. +description: The item's details. x-schemaName: BaseExchangeItem required: - id @@ -13,33 +13,33 @@ properties: id: type: string title: id - description: The additional item's ID. + description: The item's ID. exchange_id: type: string title: exchange_id - description: The additional item's exchange id. + description: The ID of the exchange this item belongs to. order_id: type: string title: order_id - description: The additional item's order id. + description: The ID of the order this item belongs to. item_id: type: string title: item_id - description: The additional item's item id. + description: The ID of the item in the order. quantity: type: number title: quantity - description: The additional item's quantity. + description: The item's quantity. metadata: type: object - description: The additional item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The additional item's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The additional item's updated at. + description: The date the item was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseFulfillmentProvider.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseFulfillmentProvider.yaml deleted file mode 100644 index 5cddd56a8992b..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/BaseFulfillmentProvider.yaml +++ /dev/null @@ -1,15 +0,0 @@ -type: object -description: The shipping option's provider. -x-schemaName: BaseFulfillmentProvider -required: - - id - - is_enabled -properties: - id: - type: string - title: id - description: The provider's ID. - is_enabled: - type: boolean - title: is_enabled - description: The provider's is enabled. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseLineItemAdjustment.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseLineItemAdjustment.yaml index 5b5a104b310a6..70541ab5976fa 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseLineItemAdjustment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseLineItemAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The adjustment's details. x-schemaName: BaseLineItemAdjustment +properties: + item: + $ref: ./BaseCartLineItem.yaml + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: + type: string + title: cart_id + description: The ID of the cart this adjustment belongs to. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. +required: + - item + - item_id + - id + - amount + - cart_id + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseLineItemTaxLine.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseLineItemTaxLine.yaml index 1fdd8bf379ec7..63946d4c1ff10 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseLineItemTaxLine.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseLineItemTaxLine.yaml @@ -1,3 +1,62 @@ type: object -description: The tax line's tax lines. +description: The tax line's details x-schemaName: BaseLineItemTaxLine +properties: + item: + $ref: ./BaseCartLineItem.yaml + item_id: + type: string + title: item_id + description: The ID of the item the tax line applies on. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the associated tax rate. + code: + type: string + title: code + description: The code the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. +required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrder.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrder.yaml index 09579fa8dd9dc..2b2d4962a6d59 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrder.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrder.yaml @@ -1,3 +1,238 @@ type: object -description: The order change's order. +description: The order's details. x-schemaName: BaseOrder +required: + - payment_collections + - id + - version + - region_id + - customer_id + - sales_channel_id + - email + - currency_code + - items + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + payment_collections: + type: array + description: The order's payment collections. + items: + $ref: ./AdminPaymentCollection.yaml + fulfillments: + type: array + description: The order's fulfillments. + items: + $ref: ./BaseOrderFulfillment.yaml + sales_channel: + $ref: ./AdminSalesChannel.yaml + customer: + $ref: ./AdminCustomer.yaml + shipping_address: + $ref: ./AdminOrderAddress.yaml + billing_address: + $ref: ./AdminOrderAddress.yaml + id: + type: string + title: id + description: The order's ID. + version: + type: number + title: version + description: The order's version. + region_id: + type: string + title: region_id + description: The ID of the region associated with the order. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the order is placed in. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The order's currency code. + display_id: + type: number + title: display_id + description: The order's display ID. + items: + type: array + description: The order's items. + items: + $ref: ./BaseOrderLineItem.yaml + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: ./BaseOrderShippingMethod.yaml + payment_status: + type: string + description: The order's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillment_status: + type: string + description: The order's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The order's transactions. + items: + $ref: ./BaseOrderTransaction.yaml + summary: + $ref: ./BaseOrderSummary.yaml + metadata: + type: object + description: The order's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the order was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the order's items including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The total of the order's items excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the order's items excluding promotions. + item_total: + type: number + title: item_total + description: The total of the order's items including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The total of the order's items excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order's items including promotions. + original_total: + type: number + title: original_total + description: The order's total excluding promotions, including taxes. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The order's tax total, excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The order's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The order's discount or promotions total. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total of order's discount or promotion. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The tax total of the order's gift card. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The tax total of the order's shipping. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The tax total of the order's shipping excluding promotions. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderAddress.yaml index f1896707cdb35..ffdb3358489ac 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The exchange's billing address. +description: An order address x-schemaName: BaseOrderAddress required: - id @@ -10,61 +10,64 @@ properties: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer this address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us + country: + $ref: ./AdminRegionCountry.yaml province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. + description: The date the address was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderChange.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderChange.yaml deleted file mode 100644 index dc086f2f8e5bf..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderChange.yaml +++ /dev/null @@ -1,146 +0,0 @@ -type: object -description: The order preview's order change. -x-schemaName: BaseOrderChange -required: - - id - - order_id - - actions - - status - - requested_by - - requested_at - - confirmed_by - - confirmed_at - - declined_by - - declined_reason - - metadata - - declined_at - - canceled_by - - canceled_at - - created_at - - updated_at - - version - - return_id - - exchange_id - - claim_id - - order - - return_order - - exchange - - claim -properties: - id: - type: string - title: id - description: The order change's ID. - order_id: - type: string - title: order_id - description: The order change's order id. - actions: - type: array - description: The order change's actions. - items: - $ref: ./BaseOrderChangeAction.yaml - status: - type: string - title: status - description: The order change's status. - requested_by: - type: string - title: requested_by - description: The order change's requested by. - requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time - confirmed_by: - type: string - title: confirmed_by - description: The order change's confirmed by. - confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time - declined_by: - type: string - title: declined_by - description: The order change's declined by. - declined_reason: - type: string - title: declined_reason - description: The order change's declined reason. - metadata: - type: object - description: The order change's metadata. - declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time - canceled_by: - type: string - title: canceled_by - description: The order change's canceled by. - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time - created_at: - type: string - format: date-time - title: created_at - description: The order change's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The order change's updated at. - version: - type: number - title: version - description: The order change's version. - change_type: - type: string - description: The order change's change type. - enum: - - return - - exchange - - claim - - edit - - return_request - return_id: - type: string - title: return_id - description: The order change's return id. - exchange_id: - type: string - title: exchange_id - description: The order change's exchange id. - claim_id: - type: string - title: claim_id - description: The order change's claim id. - order: - $ref: ./BaseOrder.yaml - return_order: {} - exchange: {} - claim: - $ref: ./BaseClaim.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderChangeAction.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderChangeAction.yaml index 91725525beead..a38543eec2523 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderChangeAction.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderChangeAction.yaml @@ -1,3 +1,85 @@ type: object description: The action's actions. x-schemaName: BaseOrderChangeAction +properties: + order_change: + $ref: ./AdminOrderChange.yaml + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change this action belongs to. + order_id: + type: string + title: order_id + description: The ID of the associated order. + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + title: action + description: The applied action. + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the order change action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change action was updated. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + $ref: ./BaseOrder.yaml +required: + - order_change + - id + - order_change_id + - order_id + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at + - return_id + - claim_id + - exchange_id + - order diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderFulfillment.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderFulfillment.yaml index 513f2f9f6a8e8..12970b6fe2310 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderFulfillment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderFulfillment.yaml @@ -22,48 +22,53 @@ properties: location_id: type: string title: location_id - description: The fulfillment's location id. + description: The ID of the location the items are fulfilled from. packed_at: type: string title: packed_at - description: The fulfillment's packed at. + description: The date the items were packed. format: date-time shipped_at: type: string title: shipped_at - description: The fulfillment's shipped at. + description: The date the items were shipped. format: date-time delivered_at: type: string title: delivered_at - description: The fulfillment's delivered at. + description: The date the items were delivered. format: date-time canceled_at: type: string title: canceled_at - description: The fulfillment's canceled at. + description: The date the items were canceled. format: date-time data: type: object - description: The fulfillment's data. + description: >- + Data useful for the fulfillment provider handling it. This is taken from + the associated shipping option. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property provider_id: type: string title: provider_id - description: The fulfillment's provider id. + description: The ID of the fulfillment provider used to handle the fulfillment. shipping_option_id: type: string title: shipping_option_id - description: The fulfillment's shipping option id. + description: The ID of the associated shipping option. metadata: type: object - description: The fulfillment's metadata. + description: The fulfillment's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The fulfillment's created at. + description: The date the fulfillment was created. updated_at: type: string format: date-time title: updated_at - description: The fulfillment's updated at. + description: The date the fulfillment was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderItemDetail.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderItemDetail.yaml index 0a1f9eb14ddaf..fe8730e0bdaa2 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderItemDetail.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderItemDetail.yaml @@ -1,3 +1,79 @@ type: object description: The item's detail. x-schemaName: BaseOrderItemDetail +required: + - id + - item_id + - item + - quantity + - fulfilled_quantity + - delivered_quantity + - shipped_quantity + - return_requested_quantity + - return_received_quantity + - return_dismissed_quantity + - written_off_quantity + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: the detail's ID. + item_id: + type: string + title: id + description: the ID of the associated line item. + item: + $ref: ./BaseOrderLineItem.yaml + quantity: + type: number + title: quantity + description: The item's quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + delivered_quantity: + type: number + title: fulfilled_quantity + description: The item's delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + return_received_quantity: + type: number + title: return_received_quantity + description: >- + The item's quantity that's returned and added to the underlying variant's + stocked quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: >- + The item's quantity that's returned but damaged. So, it's not added to the + underlying variant's stocked quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed from the order. + metadata: + type: object + title: metadata + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the detail was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the detail was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItem.yaml index ecf54b1785d60..f69a00e2163c5 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItem.yaml @@ -56,19 +56,19 @@ properties: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The URL of the item's thumbnail. variant: $ref: ./BaseProductVariant.yaml variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated variant. product: $ref: ./BaseProduct.yaml product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -88,7 +88,7 @@ properties: product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the collection the item's product belongs to. product_handle: type: string title: product_handle @@ -96,7 +96,7 @@ properties: variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -107,23 +107,25 @@ properties: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The values of the item variant's options. + example: + Color: Blue requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item is tax inclusive. compare_at_unit_price: type: number title: compare_at_unit_price - description: The item's compare at unit price. + description: The original price of the item before a promotion or sale. unit_price: type: number title: unit_price @@ -148,64 +150,64 @@ properties: type: string format: date-time title: created_at - description: The item's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The item's updated at. + description: The date the item was updated. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. original_total: type: number title: original_total - description: The item's original total. + description: The item's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The item's original subtotal. + description: The item's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The item's original tax total. + description: The total taxes of the item, excluding promotions. item_total: type: number title: item_total - description: The item's item total. + description: The total taxes of the item, including promotions. item_subtotal: type: number title: item_subtotal - description: The item's item subtotal. + description: The item's total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The item's item tax total. + description: The total taxes of the item, including promotions. total: type: number title: total - description: The item's total. + description: The item's total, including taxes and promotions. subtotal: type: number title: subtotal - description: The item's subtotal. + description: The item's subtotal excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The item's tax total. + description: The tax total of the item including promotions. discount_total: type: number title: discount_total - description: The item's discount total. + description: The total discount amount of the item. discount_tax_total: type: number title: discount_tax_total - description: The item's discount tax total. + description: The total taxes applied on the discounted amount. refundable_total: type: number title: refundable_total - description: The item's refundable total. + description: The total refundable amount of the item's total. refundable_total_per_unit: type: number title: refundable_total_per_unit - description: The item's refundable total per unit. + description: The total refundable amount of the item's total for a single quantity. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemAdjustment.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemAdjustment.yaml index a4f81ce94f20a..d86a6733f6d24 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemAdjustment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The adjustment's details. x-schemaName: BaseOrderLineItemAdjustment +properties: + item: + $ref: ./BaseOrderLineItem.yaml + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies to. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion that this applies on the order's item. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. +required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemTaxLine.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemTaxLine.yaml index 213da9382db4f..bec573b620ee8 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemTaxLine.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderLineItemTaxLine.yaml @@ -1,3 +1,62 @@ type: object description: The tax line's tax lines. x-schemaName: BaseOrderLineItemTaxLine +properties: + item: + $ref: ./BaseOrderLineItem.yaml + item_id: + type: string + title: item_id + description: The ID of the associated line item. + total: + type: number + title: total + description: The tax line's total including promotions. + subtotal: + type: number + title: subtotal + description: The tax line's subtotal excluding promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax line. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. +required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingDetail.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingDetail.yaml new file mode 100644 index 0000000000000..372c5ed40dae7 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingDetail.yaml @@ -0,0 +1,42 @@ +type: object +description: The shipping method's detail. +x-schemaName: BaseOrderShippingDetail +required: + - id + - shipping_method_id + - shipping_method + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The detail's ID. + shipping_method_id: + type: string + title: shipping_method_id + description: The detail's shipping method id. + shipping_method: + $ref: ./BaseOrderShippingMethod.yaml + claim_id: + type: string + title: claim_id + description: The detail's claim id. + exchange_id: + type: string + title: exchange_id + description: The detail's exchange id. + return_id: + type: string + title: return_id + description: The detail's return id. + created_at: + type: string + format: date-time + title: created_at + description: The detail's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The detail's updated at. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethod.yaml index 4357db37d7414..930352a943340 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethod.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethod.yaml @@ -1,5 +1,5 @@ type: object -description: The shipping method's shipping methods. +description: The shipping method's details. x-schemaName: BaseOrderShippingMethod required: - id @@ -28,7 +28,7 @@ properties: order_id: type: string title: order_id - description: The shipping method's order id. + description: The ID of the order the shipping method belongs to. name: type: string title: name @@ -44,17 +44,22 @@ properties: is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount includes applied taxes. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: >- + The shipping method's data, useful for fulfillment provider handling its + fulfillment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -66,108 +71,46 @@ properties: items: $ref: ./BaseOrderShippingMethodAdjustment.yaml original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The shipping method's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The shipping method's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The total discounts applied on the shipping method. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. + detail: + $ref: ./BaseOrderShippingDetail.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodAdjustment.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodAdjustment.yaml index 0d458f73fadbd..3deab25145cad 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodAdjustment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodAdjustment.yaml @@ -1,3 +1,56 @@ type: object description: The adjustment's adjustments. x-schemaName: BaseOrderShippingMethodAdjustment +properties: + shipping_method: + $ref: ./BaseOrderShippingMethod.yaml + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment applies on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. +required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodTaxLine.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodTaxLine.yaml index 3cce6d21b0c04..f7af354c506ef 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodTaxLine.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderShippingMethodTaxLine.yaml @@ -1,3 +1,62 @@ type: object -description: The tax line's tax lines. +description: The tax line's details. x-schemaName: BaseOrderShippingMethodTaxLine +properties: + shipping_method: + $ref: ./BaseOrderShippingMethod.yaml + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this tax line belongs to. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider handling the tax calculation. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. +required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderSummary.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderSummary.yaml index 395346dc23ecd..26db0db078bdd 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderSummary.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderSummary.yaml @@ -1,5 +1,5 @@ type: object -description: The order's summary. +description: The order's summary details. x-schemaName: BaseOrderSummary required: - total @@ -10,71 +10,46 @@ required: - returned_total - return_request_total - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - paid_total - refunded_total properties: total: type: number title: total - description: The summary's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The summary's subtotal. + description: The order's total excluding taxes, including promotions. total_tax: type: number title: total_tax - description: The summary's total tax. + description: The order's total taxes. ordered_total: type: number title: ordered_total - description: The summary's ordered total. + description: The order's total when it was placed. fulfilled_total: type: number title: fulfilled_total - description: The summary's fulfilled total. + description: The total of the fulfilled items of the order. returned_total: type: number title: returned_total - description: The summary's returned total. + description: The total of the order's returned items. return_request_total: type: number title: return_request_total - description: The summary's return request total. + description: The total of the items requested to be returned. write_off_total: type: number title: write_off_total - description: The summary's write off total. - projected_total: - type: number - title: projected_total - description: The summary's projected total. - net_total: - type: number - title: net_total - description: The summary's net total. - net_subtotal: - type: number - title: net_subtotal - description: The summary's net subtotal. - net_total_tax: - type: number - title: net_total_tax - description: The summary's net total tax. - balance: - type: number - title: balance - description: The summary's balance. + description: The total of the items removed from the order. paid_total: type: number title: paid_total - description: The summary's paid total. + description: The total amount paid. refunded_total: type: number title: refunded_total - description: The summary's refunded total. + description: The total amount refunded. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseOrderTransaction.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseOrderTransaction.yaml index 8abf8cfd58a68..f822566df95f8 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseOrderTransaction.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseOrderTransaction.yaml @@ -1,5 +1,5 @@ type: object -description: The transaction's transactions. +description: An order transaction's details. x-schemaName: BaseOrderTransaction required: - id @@ -19,7 +19,7 @@ properties: order_id: type: string title: order_id - description: The transaction's order id. + description: The ID of the order this transaction belongs to. amount: type: number title: amount @@ -28,24 +28,31 @@ properties: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: >- + The name of a table that this transaction references. If this transaction + is for captured payment, its value is `capture`. If this transaction is + for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. metadata: type: object - description: The transaction's metadata. + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. + description: The date that the transaction was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/BasePayment.yaml b/www/apps/api-reference/specs/store/components/schemas/BasePayment.yaml index 6171436ba768d..d42b237789748 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BasePayment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BasePayment.yaml @@ -1,3 +1,93 @@ type: object -description: The payment's payments. +description: The payment's details. x-schemaName: BasePayment +required: + - id + - amount + - currency_code + - provider_id +properties: + id: + type: string + title: id + description: The payment's ID. + amount: + type: number + title: amount + description: The payment's amount. + authorized_amount: + type: number + title: authorized_amount + description: The amount authorized of the payment. + currency_code: + type: string + title: currency_code + description: The payment's currency code. + provider_id: + type: string + title: provider_id + description: The ID of the payment provider used to process this payment. + cart_id: + type: string + title: cart_id + description: The ID of the associated cart. + order_id: + type: string + title: order_id + description: The ID of the associated order. + order_edit_id: + type: string + title: order_edit_id + description: The ID of the associated order edit. + customer_id: + type: string + title: customer_id + description: ID of the associated customer. + data: + type: object + description: The payment's data, useful for processing by the payment provider. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment#whats-a-payment + created_at: + type: string + format: date-time + title: created_at + description: The date the payment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the payment was updated. + captured_at: + type: string + format: date-time + title: captured_at + description: The date the payment was captured. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the payment was canceled. + captured_amount: + type: number + title: captured_amount + description: The captured amount of the payment. + refunded_amount: + type: number + title: captured_amount + description: The refunded amount of the payment. + captures: + type: array + description: The details of payment captures. + items: + $ref: ./BaseCapture.yaml + refunds: + type: array + description: The details of payment refunds. + items: + $ref: ./BaseRefund.yaml + payment_collection: + $ref: ./BasePaymentCollection.yaml + payment_session: + $ref: ./BasePaymentSession.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/BasePaymentCollection.yaml b/www/apps/api-reference/specs/store/components/schemas/BasePaymentCollection.yaml index 309583af20943..8ee4e76804fa9 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BasePaymentCollection.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BasePaymentCollection.yaml @@ -1,5 +1,5 @@ type: object -description: The payment collection's payment collections. +description: The payment collection's details. x-schemaName: BasePaymentCollection required: - id @@ -20,77 +20,41 @@ properties: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: ./IBigNumber.yaml + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: ./IBigNumber.yaml + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: ./IBigNumber.yaml + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: ./IBigNumber.yaml + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -102,7 +66,9 @@ properties: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: >- + The payment provider used to process the collection's payments and + sessions. items: $ref: ./BasePaymentProvider.yaml payment_sessions: diff --git a/www/apps/api-reference/specs/store/components/schemas/BasePaymentProvider.yaml b/www/apps/api-reference/specs/store/components/schemas/BasePaymentProvider.yaml index 2266f0a8ea987..2b73a963fbe9a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BasePaymentProvider.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BasePaymentProvider.yaml @@ -1,3 +1,10 @@ type: object description: The payment provider's payment providers. x-schemaName: BasePaymentProvider +required: + - id +properties: + id: + type: string + title: id + description: The payment provider's ID. diff --git a/www/apps/api-reference/specs/store/components/schemas/BasePaymentSession.yaml b/www/apps/api-reference/specs/store/components/schemas/BasePaymentSession.yaml index f0c1e2603ad1f..81518bdaea905 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BasePaymentSession.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BasePaymentSession.yaml @@ -1,3 +1,61 @@ type: object -description: The payment session's payment sessions. +description: The payment session's details. x-schemaName: BasePaymentSession +properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: >- + The payment session's data, useful for the payment provider processing the + payment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + $ref: ./BasePaymentCollection.yaml + payment: + $ref: ./BasePayment.yaml +required: + - id + - amount + - currency_code + - provider_id + - data + - status diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseProductImage.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseProductImage.yaml index cbabec460947e..f1e59ad937a5e 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseProductImage.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseProductImage.yaml @@ -1,3 +1,33 @@ type: object -description: The image's images. +description: The image's details. x-schemaName: BaseProductImage +properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's URL. + created_at: + type: string + format: date-time + title: created_at + description: The date the image was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. +required: + - id + - url diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseProductOption.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseProductOption.yaml index 91105a54c2c06..3e389925515ff 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseProductOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseProductOption.yaml @@ -1,3 +1,44 @@ type: object -description: The option's options. +description: The product option's details. x-schemaName: BaseProductOption +properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + $ref: ./BaseProduct.yaml + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: ./BaseProductOptionValue.yaml + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. +required: + - id + - title diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseProductOptionValue.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseProductOptionValue.yaml index a607fba792761..0fe30515bbf4e 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseProductOptionValue.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseProductOptionValue.yaml @@ -1,39 +1,3 @@ type: object -description: The option's options. +description: The product option value's details. x-schemaName: BaseProductOptionValue -required: - - id - - value -properties: - id: - type: string - title: id - description: The option's ID. - value: - type: string - title: value - description: The option's value. - option: - $ref: ./BaseProductOption.yaml - option_id: - type: string - title: option_id - description: The option's option id. - metadata: - type: object - description: The option's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The option's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The option's updated at. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The option's deleted at. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseProductVariant.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseProductVariant.yaml index 559318d70ea04..e27ee0ea8c77c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseProductVariant.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseProductVariant.yaml @@ -1,3 +1,132 @@ type: object -description: The variant's variants. +description: The product variant's details. x-schemaName: BaseProductVariant +required: + - id + - title + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory + - hs_code + - origin_country + - mid_code + - material + - weight + - length + - height + - width + - options + - created_at + - updated_at + - deleted_at +properties: + id: + type: string + title: id + description: The variant's ID. + title: + type: string + title: title + description: The variant's title. + sku: + type: string + title: sku + description: The variant's SKU. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's EAN code. + upc: + type: string + title: upc + description: The variant's UPC. + allow_backorder: + type: boolean + title: allow_backorder + description: Whether the variant can be ordered even if it's out of stock. + manage_inventory: + type: boolean + title: manage_inventory + description: >- + Whether the Medusa application manages the variant's inventory quantity + and availablility. If disabled, the variant is always considered in stock. + inventory_quantity: + type: number + title: inventory_quantity + description: >- + The variant's inventory quantity. This is only included if you pass in the + `fields` query parameter a `+variants.inventory_quantity` parameter. + hs_code: + type: string + title: hs_code + description: The variant's HS code. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + mid_code: + type: string + title: mid_code + description: The variant's MID code. + material: + type: string + title: material + description: The variant's material. + weight: + type: number + title: weight + description: The variant's weight. + length: + type: number + title: length + description: The variant's length. + height: + type: number + title: height + description: The variant's height. + width: + type: number + title: width + description: The variant's width. + variant_rank: + type: number + title: variant_rank + description: The variant's rank among its sibling variants. + options: + type: array + description: The variant's option values. + items: + $ref: ./BaseProductOptionValue.yaml + product: + $ref: ./BaseProduct.yaml + product_id: + type: string + title: product_id + description: The ID of the product that the variant belongs to. + calculated_price: + $ref: ./BaseCalculatedPriceSet.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the variant was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the variant was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the variant was deleted. + metadata: + type: object + description: The variant's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseRefund.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseRefund.yaml index 50d12fb0f9e74..e9fb9e94a8359 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseRefund.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseRefund.yaml @@ -1,3 +1,38 @@ type: object -description: The refund's refunds. +description: The refund's details. x-schemaName: BaseRefund +required: + - id + - amount + - created_at + - payment +properties: + id: + type: string + title: id + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: + type: string + title: refund_reason_id + description: The ID of the refund reason. + note: + type: string + title: note + description: More details about the refund. + created_at: + type: string + format: date-time + title: created_at + description: The date the refund was created. + created_by: + type: string + title: created_by + description: The ID of the user that created the refund. + payment: + $ref: ./BasePayment.yaml + refund_reason: + $ref: ./RefundReason.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseRegion.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseRegion.yaml index 778b10a689f9b..370a7c2f9fa93 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseRegion.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseRegion.yaml @@ -1,47 +1,3 @@ type: object description: The parent's region. x-schemaName: BaseRegion -required: - - id - - name - - currency_code -properties: - id: - type: string - title: id - description: The region's ID. - name: - type: string - title: name - description: The region's name. - currency_code: - type: string - title: currency_code - description: The region's currency code. - automatic_taxes: - type: boolean - title: automatic_taxes - description: The region's automatic taxes. - countries: - type: array - description: The region's countries. - items: - $ref: ./BaseRegionCountry.yaml - payment_providers: - type: array - description: The region's payment providers. - items: - $ref: ./AdminPaymentProvider.yaml - metadata: - type: object - description: The region's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The region's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The region's updated at. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseRegionCountry.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseRegionCountry.yaml index ee76c5c787ed6..5fd0a02708b5d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseRegionCountry.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseRegionCountry.yaml @@ -1,3 +1,33 @@ type: object -description: The country's countries. +description: The country's details. x-schemaName: BaseRegionCountry +properties: + id: + type: string + title: id + description: The country's ID. + iso_2: + type: string + title: iso_2 + description: The country's iso 2. + example: us + iso_3: + type: string + title: iso_3 + description: The country's iso 3. + example: usa + num_code: + type: string + title: num_code + description: The country's num code. + example: 840 + name: + type: string + title: name + description: The country's name. + display_name: + type: string + title: display_name + description: The country's display name. +required: + - id diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseReturnItem.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseReturnItem.yaml deleted file mode 100644 index 3f0906bd54e7e..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/BaseReturnItem.yaml +++ /dev/null @@ -1,3 +0,0 @@ -type: object -description: The item's items. -x-schemaName: BaseReturnItem diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseRuleOperatorOptions.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseRuleOperatorOptions.yaml index b5c88a34d8dd5..d46a97718a0cc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseRuleOperatorOptions.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseRuleOperatorOptions.yaml @@ -1,5 +1,5 @@ type: object -description: The operator's operators. +description: The operator's details. x-schemaName: BaseRuleOperatorOptions required: - id @@ -10,11 +10,14 @@ properties: type: string title: id description: The operator's ID. + example: in value: type: string title: value description: The operator's value. + example: in label: type: string title: label description: The operator's label. + example: In diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodAdjustment.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodAdjustment.yaml index e20885775e594..31fe8e9922605 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodAdjustment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The adjustment's details. x-schemaName: BaseShippingMethodAdjustment +required: + - shipping_method + - shipping_method_id + - id + - amount + - cart_id + - created_at + - updated_at +properties: + shipping_method: + $ref: ./BaseCartShippingMethod.yaml + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method the adjustment is applied on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: + type: string + title: cart_id + description: The ID of the associated cart. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodTaxLine.yaml b/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodTaxLine.yaml index e7e494dae548d..1651b62c63dac 100644 --- a/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodTaxLine.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/BaseShippingMethodTaxLine.yaml @@ -1,3 +1,62 @@ type: object -description: The tax line's tax lines. +description: The tax line's details. x-schemaName: BaseShippingMethodTaxLine +required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at +properties: + shipping_method: + $ref: ./BaseCartShippingMethod.yaml + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of this shipping method the tax line belongs to. + total: + type: number + title: total + description: The method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The method's total excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider that calculated the taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/CreateAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/CreateAddress.yaml index 5217a9aa3bdd9..14de28c42ef4b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/CreateAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/CreateAddress.yaml @@ -1,51 +1,52 @@ type: object -description: The cart's shipping address. +description: The address to create. x-schemaName: CreateAddress properties: customer_id: type: string title: customer_id - description: The shipping address's customer id. + description: The ID of the customer this address belongs to. company: type: string title: company - description: The shipping address's company. + description: The address's company. first_name: type: string title: first_name - description: The shipping address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The shipping address's last name. + description: The address's last name. address_1: type: string title: address_1 - description: The shipping address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The shipping address's address 2. + description: The address's second line. city: type: string title: city - description: The shipping address's city. + description: The address's city. country_code: type: string title: country_code - description: The shipping address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The shipping address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The shipping address's postal code. + description: The address's postal code. phone: type: string title: phone - description: The shipping address's phone. + description: The address's phone. metadata: type: object - description: The shipping address's metadata. + description: The address's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/CreateCartAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/CreateCartAddress.yaml deleted file mode 100644 index ea5d127dd24f5..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/CreateCartAddress.yaml +++ /dev/null @@ -1,47 +0,0 @@ -type: object -description: The cart's billing address. -x-schemaName: CreateCartAddress -properties: - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: - type: string - title: last_name - description: The billing address's last name. - phone: - type: string - title: phone - description: The billing address's phone. - company: - type: string - title: company - description: The billing address's company. - address_1: - type: string - title: address_1 - description: The billing address's address 1. - address_2: - type: string - title: address_2 - description: The billing address's address 2. - city: - type: string - title: city - description: The billing address's city. - country_code: - type: string - title: country_code - description: The billing address's country code. - province: - type: string - title: province - description: The billing address's province. - postal_code: - type: string - title: postal_code - description: The billing address's postal code. - metadata: - type: object - description: The billing address's metadata. diff --git a/www/apps/api-reference/specs/store/components/schemas/CreateCartCreateLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/CreateCartCreateLineItem.yaml deleted file mode 100644 index fc4ffc2354673..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/CreateCartCreateLineItem.yaml +++ /dev/null @@ -1,97 +0,0 @@ -type: object -description: The item's items. -x-schemaName: CreateCartCreateLineItem -required: - - quantity - - variant_id -properties: - quantity: - type: string - title: quantity - description: The item's quantity. - variant_id: - type: string - title: variant_id - description: The item's variant id. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The item's thumbnail. - product_id: - type: string - title: product_id - description: The item's product id. - product_title: - type: string - title: product_title - description: The item's product title. - product_description: - type: string - title: product_description - description: The item's product description. - product_subtitle: - type: string - title: product_subtitle - description: The item's product subtitle. - product_type: - type: string - title: product_type - description: The item's product type. - product_collection: - type: string - title: product_collection - description: The item's product collection. - product_handle: - type: string - title: product_handle - description: The item's product handle. - variant_sku: - type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: - type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: - type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - is_giftcard: - type: boolean - title: is_giftcard - description: The item's is giftcard. - compare_at_unit_price: - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - unit_price: - type: string - title: unit_price - description: The item's unit price. - metadata: - type: object - description: The item's metadata. diff --git a/www/apps/api-reference/specs/store/components/schemas/CreateCartWorkflowInput.yaml b/www/apps/api-reference/specs/store/components/schemas/CreateCartWorkflowInput.yaml deleted file mode 100644 index 369ef9b3a1aeb..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/CreateCartWorkflowInput.yaml +++ /dev/null @@ -1,60 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: CreateCartWorkflowInput -properties: - region_id: - type: string - title: region_id - description: The cart's region id. - customer_id: - type: string - title: customer_id - description: The cart's customer id. - sales_channel_id: - type: string - title: sales_channel_id - description: The cart's sales channel id. - email: - type: string - title: email - description: The cart's email. - format: email - currency_code: - type: string - title: currency_code - description: The cart's currency code. - shipping_address_id: - type: string - title: shipping_address_id - description: The cart's shipping address id. - billing_address_id: - type: string - title: billing_address_id - description: The cart's billing address id. - shipping_address: - oneOf: - - type: string - title: shipping_address - description: The cart's shipping address. - - $ref: ./CreateCartAddress.yaml - billing_address: - oneOf: - - type: string - title: billing_address - description: The cart's billing address. - - $ref: ./CreateCartAddress.yaml - metadata: - type: object - description: The cart's metadata. - items: - type: array - description: The cart's items. - items: - $ref: ./CreateCartCreateLineItem.yaml - promo_codes: - type: array - description: The cart's promo codes. - items: - type: string - title: promo_codes - description: The promo code's promo codes. diff --git a/www/apps/api-reference/specs/store/components/schemas/CustomerGroupInCustomerFilters.yaml b/www/apps/api-reference/specs/store/components/schemas/CustomerGroupInCustomerFilters.yaml index fcc67cf89c974..e16fde8c9ba2a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/CustomerGroupInCustomerFilters.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/CustomerGroupInCustomerFilters.yaml @@ -1,5 +1,5 @@ type: object -description: The customer's groups. +description: Filter by customer groups to get their associated customers. x-schemaName: CustomerGroupInCustomerFilters required: - id @@ -12,27 +12,27 @@ properties: oneOf: - type: string title: id - description: The group's ID. + description: Filter by a group's ID. - type: array - description: The group's ID. + description: Filter by group IDs. items: type: string title: id - description: The id's ID. + description: A group's ID. name: oneOf: - type: string title: name - description: The group's name. + description: Filter by a group's name. - type: array - description: The group's name. + description: Filter by group names. items: type: string title: name - description: The name's details. + description: A group's name. created_at: type: object - description: The group's created at. + description: Filter by the group's creation date. properties: $and: type: array @@ -56,7 +56,7 @@ properties: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -159,7 +159,7 @@ properties: description: Filter by whether a value for this parameter exists (not `null`). updated_at: type: object - description: The group's updated at. + description: Filter by the group's update date. properties: $and: type: array @@ -183,7 +183,7 @@ properties: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -286,7 +286,7 @@ properties: description: Filter by whether a value for this parameter exists (not `null`). deleted_at: type: object - description: The group's deleted at. + description: Filter by the group's deletion date. properties: $and: type: array @@ -310,7 +310,7 @@ properties: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq diff --git a/www/apps/api-reference/specs/store/components/schemas/File.yaml b/www/apps/api-reference/specs/store/components/schemas/File.yaml deleted file mode 100644 index 20c6a466afdcd..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/File.yaml +++ /dev/null @@ -1,45 +0,0 @@ -type: object -description: The product's file. -x-schemaName: File -required: - - lastModified - - name - - webkitRelativePath - - size - - type - - arrayBuffer - - stream - - text -properties: - lastModified: - type: number - title: lastModified - description: The file's lastmodified. - name: - type: string - title: name - description: The file's name. - webkitRelativePath: - type: string - title: webkitRelativePath - description: The file's webkitrelativepath. - size: - type: number - title: size - description: The file's size. - type: - type: string - title: type - description: The file's type. - arrayBuffer: - type: object - description: The file's arraybuffer. - slice: - type: object - description: The file's slice. - stream: - type: object - description: The file's stream. - text: - type: object - description: The file's text. diff --git a/www/apps/api-reference/specs/store/components/schemas/FileList.yaml b/www/apps/api-reference/specs/store/components/schemas/FileList.yaml deleted file mode 100644 index 2bc70ab8fb36e..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/FileList.yaml +++ /dev/null @@ -1,18 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: FileList -required: - - length - - item - - __@iterator@258 -properties: - length: - type: number - title: length - description: The upload's length. - item: - type: object - description: The upload's item. - __@iterator@258: - type: object - description: The upload's @iterator@258. diff --git a/www/apps/api-reference/specs/store/components/schemas/InventoryLevel.yaml b/www/apps/api-reference/specs/store/components/schemas/InventoryLevel.yaml index ff883a1a28975..aa13bb7243bb5 100644 --- a/www/apps/api-reference/specs/store/components/schemas/InventoryLevel.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/InventoryLevel.yaml @@ -1,5 +1,5 @@ type: object -description: The inventory level's inventory levels. +description: The inventory level's details x-schemaName: InventoryLevel required: - id @@ -17,11 +17,11 @@ properties: inventory_item_id: type: string title: inventory_item_id - description: The inventory level's inventory item id. + description: The ID of the associated inventory item. location_id: type: string title: location_id - description: The inventory level's location id. + description: The ID of the associated location. stocked_quantity: type: number title: stocked_quantity @@ -40,4 +40,4 @@ properties: description: The inventory level's incoming quantity. metadata: type: object - description: The inventory level's metadata. + description: The inventory level's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/Order.yaml b/www/apps/api-reference/specs/store/components/schemas/Order.yaml index 8c90e11018044..89f4b17f5c177 100644 --- a/www/apps/api-reference/specs/store/components/schemas/Order.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/Order.yaml @@ -1,3 +1,296 @@ type: object -description: The transaction's order. +description: The order change's order. x-schemaName: Order +required: + - id + - version + - status + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_subtotal + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total +properties: + id: + type: string + title: id + description: The order's ID. + version: + type: number + title: version + description: The order's version. + order_change: + $ref: ./OrderChange.yaml + status: + type: string + description: The order's status. + enum: + - canceled + - requires_action + - pending + - completed + - draft + - archived + region_id: + type: string + title: region_id + description: The ID of the region the order belongs to. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the order was placed in. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The order's currency code. + example: usd + shipping_address: + $ref: ./OrderAddress.yaml + billing_address: + $ref: ./OrderAddress.yaml + items: + type: array + description: The order's items. + items: + $ref: ./OrderLineItem.yaml + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: ./OrderShippingMethod.yaml + transactions: + type: array + description: The order's transactions. + items: + $ref: ./OrderTransaction.yaml + summary: + type: object + description: The order's summary. + metadata: + type: object + description: The order's metadata, can hold custom key-value pairs. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the order was canceled. + created_at: + type: string + format: date-time + title: created_at + description: The date the order was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The order items' total including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The order items' total excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The taxes total for order items, excluding promotions. + item_total: + type: number + title: item_total + description: The order items' total including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The order items' total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order items including promotions. + original_total: + type: number + title: original_total + description: The order's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the order including promotions. + discount_subtotal: + type: number + title: discount_subtotal + description: The total discount excluding taxes. + discount_total: + type: number + title: discount_total + description: The total discount including taxes. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total applied on the discount. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The order's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The total taxes of the order's shipping including taxes. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The total taxes of the order's shipping excluding promotions. + raw_original_item_total: + type: object + description: The order's raw original item total. + raw_original_item_subtotal: + type: object + description: The order's raw original item subtotal. + raw_original_item_tax_total: + type: object + description: The order's raw original item tax total. + raw_item_total: + type: object + description: The order's raw item total. + raw_item_subtotal: + type: object + description: The order's raw item subtotal. + raw_item_tax_total: + type: object + description: The order's raw item tax total. + raw_original_total: + type: object + description: The order's raw original total. + raw_original_subtotal: + type: object + description: The order's raw original subtotal. + raw_original_tax_total: + type: object + description: The order's raw original tax total. + raw_total: + type: object + description: The order's raw total. + raw_subtotal: + type: object + description: The order's raw subtotal. + raw_tax_total: + type: object + description: The order's raw tax total. + raw_discount_total: + type: object + description: The order's raw discount total. + raw_discount_tax_total: + type: object + description: The order's raw discount tax total. + raw_gift_card_total: + type: object + description: The order's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The order's raw gift card tax total. + raw_shipping_total: + type: object + description: The order's raw shipping total. + raw_shipping_subtotal: + type: object + description: The order's raw shipping subtotal. + raw_shipping_tax_total: + type: object + description: The order's raw shipping tax total. + raw_original_shipping_total: + type: object + description: The order's raw original shipping total. + raw_original_shipping_subtotal: + type: object + description: The order's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The order's raw original shipping tax total. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderAddress.yaml index 20065360554ed..31087870262e7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The order preview's billing address. +description: The address's details. x-schemaName: OrderAddress required: - id @@ -9,61 +9,62 @@ properties: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer the address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. + description: The date the address was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderChange.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderChange.yaml index e4b9f03dabd9c..d200d8a0d246e 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderChange.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderChange.yaml @@ -1,5 +1,5 @@ type: object -description: The order preview's order change. +description: The order change's details. x-schemaName: OrderChange required: - id @@ -34,10 +34,12 @@ properties: version: type: number title: version - description: The order change's version. + description: >- + The order change's version. This will be the order's version when the + change is applied. change_type: type: string - description: The order change's change type. + description: The order change's type. enum: - return - exchange @@ -46,19 +48,19 @@ properties: order_id: type: string title: order_id - description: The order change's order id. + description: The ID of the order this change applies on. return_id: type: string title: return_id - description: The order change's return id. + description: The ID of the associated return. exchange_id: type: string title: exchange_id - description: The order change's exchange id. + description: The ID of the associated exchange. claim_id: type: string title: claim_id - description: The order change's claim id. + description: The ID of the associated claim. order: type: object return_order: @@ -74,74 +76,63 @@ properties: $ref: ./OrderChangeAction.yaml status: type: string - title: status description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined requested_by: type: string title: requested_by - description: The order change's requested by. + description: The ID of the user that requested the change. requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time + type: string + title: requested_at + description: The date the order change was requested. + format: date-time confirmed_by: type: string title: confirmed_by - description: The order change's confirmed by. + description: The ID of the user that confirmed the order change. confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time declined_by: type: string title: declined_by - description: The order change's declined by. + description: The ID of the user that declined the order change. declined_reason: type: string title: declined_reason - description: The order change's declined reason. + description: The reason the order change was declined. metadata: type: object - description: The order change's metadata. + description: The order change's metadata, can hold custom key-value pairs. declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time + type: string + title: declined_at + description: The date the order change was declined. + format: date-time canceled_by: type: string title: canceled_by - description: The order change's canceled by. + description: The ID of the user that canceled the order change. canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time created_at: type: string format: date-time title: created_at - description: The order change's created at. + description: The date the order change was created. updated_at: type: string format: date-time title: updated_at - description: The order change's updated at. + description: The date the order change was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderChangeAction.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderChangeAction.yaml index 13a80ba7673fc..a754aefad4395 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderChangeAction.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderChangeAction.yaml @@ -1,3 +1,100 @@ type: object -description: The action's actions. +description: The order change action's details. x-schemaName: OrderChangeAction +required: + - id + - order_change_id + - order_change + - order_id + - return_id + - claim_id + - exchange_id + - order + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change that the action belongs to. + order_change: + $ref: ./OrderChange.yaml + order_id: + type: string + title: order_id + description: The ID of the order the associated change is for. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + $ref: ./Order.yaml + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + description: The applied action. + enum: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the action was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderClaim.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderClaim.yaml index 7d1a9d336660d..924727045d5cb 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderClaim.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderClaim.yaml @@ -1,3 +1,257 @@ type: object description: The order change's claim. x-schemaName: OrderClaim +required: + - order_id + - claim_items + - additional_items + - currency_code + - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + id: + type: string + title: id + description: The claim's ID. + order_id: + type: string + title: order_id + description: The ID of the order associated with the claim. + claim_items: + type: array + description: The order items targetted by the claim. + items: + $ref: ./BaseClaimItem.yaml + additional_items: + type: array + description: The outbound or new items of the claim. + items: + $ref: ./BaseClaimItem.yaml + return: + $ref: ./Return.yaml + return_id: + type: string + title: return_id + description: The ID of the associated return. + no_notification: + type: boolean + title: no_notification + description: Whether the customer should be notified about changes in the claim. + refund_amount: + type: number + title: refund_amount + description: The amount to be refunded. + currency_code: + type: string + title: currency_code + description: The claim's currency code. + region_id: + type: string + title: region_id + description: The ID of the region associated with the claim. + customer_id: + type: string + title: customer_id + description: The ID of the customer associated with the claim's order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the claim's order is created in. + email: + type: string + title: email + description: The email associated with the claim's order. + format: email + display_id: + type: number + title: display_id + description: The claim's display ID. + shipping_address: + $ref: ./BaseOrderAddress.yaml + billing_address: + $ref: ./BaseOrderAddress.yaml + shipping_methods: + type: array + description: The claim's shipping methods. + items: + $ref: ./BaseOrderShippingMethod.yaml + payment_collections: + type: array + description: The claim's payment collections. + items: + $ref: ./BasePaymentCollection.yaml + payment_status: + type: string + description: The claim's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The claim's fulfillments. + items: + $ref: ./BaseOrderFulfillment.yaml + fulfillment_status: + type: string + description: The claim's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The claim's transactions. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + description: Learn more about transactions of orders and associated models. + items: + $ref: ./BaseOrderTransaction.yaml + summary: + $ref: ./BaseOrderSummary.yaml + metadata: + type: object + description: The claim's metadata, used to store custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The claim's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The claim's update date. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the associated order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the associated order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the original items in the associated order. + item_total: + type: number + title: item_total + description: The total of the claim's items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the claim's items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the claim's items. + original_total: + type: number + title: original_total + description: The associated order's original total. + original_subtotal: + type: number + title: original_subtotal + description: The associated order's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The associated order's original tax total. + total: + type: number + title: total + description: The associated order's total. + subtotal: + type: number + title: subtotal + description: The claim's subtotal. + tax_total: + type: number + title: tax_total + description: The claim's tax total. + discount_total: + type: number + title: discount_total + description: The claim's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The claim's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The claim's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The claim's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The claim's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The claim's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The claim's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The associated order's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The associated order's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The associated order's original shipping tax total. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderExchange.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderExchange.yaml index 0c83b9bb1b4b6..c0ba54357bb31 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderExchange.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderExchange.yaml @@ -1,3 +1,263 @@ type: object description: The order change's exchange. x-schemaName: OrderExchange +required: + - order_id + - return_items + - additional_items + - currency_code + - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total +properties: + order_id: + type: string + title: order_id + description: The ID of the order the exchange is created for. + return_items: + type: array + description: The items returned (inbound) by the exchange. + items: + $ref: ./AdminReturnItem.yaml + additional_items: + type: array + description: The new items (outbound) sent by the exchange. + items: + $ref: ./BaseExchangeItem.yaml + no_notification: + type: boolean + title: no_notification + description: Whether to send the customer notifications when the exchange is updated. + difference_due: + type: number + title: difference_due + description: >- + The amount to be exchanged or refunded. If the amount is negative, it must + be refunded. If positive, additional payment is required from the + customer. + return: + description: the return associated with the exchange. + $ref: ./AdminReturn.yaml + return_id: + type: string + title: return_id + description: The ID of the associated exchange. + currency_code: + type: string + title: currency_code + description: The exchange's currency code. + id: + type: string + title: id + description: The exchange's ID. + region_id: + type: string + title: region_id + description: The ID of the associated order's region. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the associated order belongs to. + email: + type: string + title: email + description: The email used when placing the order. + format: email + display_id: + type: number + title: display_id + description: The exchange's display ID. + shipping_address: + description: The shipping address to send new items to. + $ref: ./BaseOrderAddress.yaml + billing_address: + description: The customer's billing address. + $ref: ./BaseOrderAddress.yaml + shipping_methods: + type: array + description: The shipping methods used to send the new (outbound) items. + items: + $ref: ./BaseOrderShippingMethod.yaml + payment_collections: + type: array + description: The exchange's payment collections. + items: + $ref: ./BasePaymentCollection.yaml + payment_status: + type: string + description: The exchange's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The exchange's fulfillments of new (outbound) items. + items: + $ref: ./BaseOrderFulfillment.yaml + fulfillment_status: + type: string + description: The exchange's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The exchange's transactions. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + items: + $ref: ./BaseOrderTransaction.yaml + summary: + description: The totals summary of the exchange. + $ref: ./BaseOrderSummary.yaml + metadata: + type: object + description: The exchange's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date that the exchange was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date that the exchange was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The total tax of the original items in the order. + item_total: + type: number + title: item_total + description: The total of the exchange's new items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the exchange's new items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the exchange's new items. + original_total: + type: number + title: original_total + description: The total of the order. + original_subtotal: + type: number + title: original_subtotal + description: The subtotal of the order. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order. + total: + type: number + title: total + description: The total of the exchange. + subtotal: + type: number + title: subtotal + description: The subtotal of the exchange. + tax_total: + type: number + title: tax_total + description: The tax total of the exchange. + discount_total: + type: number + title: discount_total + description: The discount total of the exchange. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes on discount of the exchange. + gift_card_total: + type: number + title: gift_card_total + description: The gift cards total of the exchange. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The total taxes on the gift card of the exchange. + shipping_total: + type: number + title: shipping_total + description: The exchange's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The exchange's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The exchange's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The order's shipping tax total. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderItem.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderItem.yaml index d7584d2fbebe9..057773eb108ec 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderItem.yaml @@ -1,3 +1,106 @@ type: object -description: The item's detail. +description: The order item's detail. x-schemaName: OrderItem +required: + - id + - item_id + - item + - quantity + - raw_quantity + - fulfilled_quantity + - raw_fulfilled_quantity + - delivered_quantity + - raw_delivered_quantity + - shipped_quantity + - raw_shipped_quantity + - return_requested_quantity + - raw_return_requested_quantity + - return_received_quantity + - raw_return_received_quantity + - return_dismissed_quantity + - raw_return_dismissed_quantity + - written_off_quantity + - raw_written_off_quantity + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The item's ID. + item_id: + type: string + title: item_id + description: The ID of the associated line item. + item: + $ref: ./OrderLineItem.yaml + quantity: + type: number + title: quantity + description: The item's quantity. + raw_quantity: + type: object + description: The item's raw quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + raw_fulfilled_quantity: + type: object + description: The item's raw fulfilled quantity. + delivered_quantity: + type: number + title: delivered_quantity + description: The item's delivered quantity. + raw_delivered_quantity: + type: object + description: The item's raw delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + raw_shipped_quantity: + type: object + description: The item's raw shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + raw_return_requested_quantity: + type: object + description: The item's raw return requested quantity. + return_received_quantity: + type: number + title: return_received_quantity + description: The item's quantity that's received through a return. + raw_return_received_quantity: + type: object + description: The item's raw return received quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: The item's quantity that's returned but dismissed because it's damaged. + raw_return_dismissed_quantity: + type: object + description: The item's raw return dismissed quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed due to an order change. + raw_written_off_quantity: + type: object + description: The item's raw written off quantity. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderLineItem.yaml new file mode 100644 index 0000000000000..7872ecc8f15ad --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/OrderLineItem.yaml @@ -0,0 +1,435 @@ +type: object +description: The order line item's details. +x-schemaName: OrderLineItem +required: + - id + - title + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - raw_unit_price + - quantity + - raw_quantity + - detail + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - item_total + - item_subtotal + - item_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - refundable_total + - refundable_total_per_unit + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_refundable_total + - raw_refundable_total_per_unit +properties: + id: + type: string + title: id + description: The item's ID. + title: + type: string + title: title + description: The item's title. + subtitle: + type: string + title: subtitle + description: The item's subtitle. + thumbnail: + type: string + title: thumbnail + description: The item's thumbnail URL. + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The ID of the associated product's type. + product_collection: + type: string + title: product_collection + description: The ID of the associated product's collection. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: + type: string + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The associated variant's values for the associated product's options. + example: + Color: Red + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item's price includes taxes. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + raw_compare_at_unit_price: + type: object + description: The item's raw compare at unit price. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw compare at unit price's value. + - type: number + title: value + description: The raw compare at unit price's value. + unit_price: + type: number + title: unit_price + description: The item's price for a single quantity. + raw_unit_price: + type: object + description: The item's raw unit price. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw unit price's value. + - type: number + title: value + description: The raw unit price's value. + quantity: + type: number + title: quantity + description: The item's quantity. + raw_quantity: + type: object + description: The item's raw quantity. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw quantity's value. + - type: number + title: value + description: The raw quantity's value. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: ./OrderLineItemTaxLine.yaml + adjustments: + type: array + description: The item's adjustments. + items: + $ref: ./OrderLineItemAdjustment.yaml + detail: + $ref: ./OrderItem.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + original_total: + type: number + title: original_total + description: The item's total including taxes and promotions. + original_subtotal: + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. + item_total: + type: number + title: item_total + description: The item's total for a single quantity, including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: >- + The item's total for a single quantity, excluding taxes and including + promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of a single quantity of the item, including promotions. + total: + type: number + title: total + description: The item's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes of the item, including promotions. + discount_total: + type: number + title: discount_total + description: The item's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total amount of the item that can be refunded. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total amount that can be refunded of a single quantity of the item. + raw_original_total: + type: object + description: The item's raw original total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original total's value. + - type: number + title: value + description: The raw original total's value. + raw_original_subtotal: + type: object + description: The item's raw original subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original subtotal's value. + - type: number + title: value + description: The raw original subtotal's value. + raw_original_tax_total: + type: object + description: The item's raw original tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original tax total's value. + - type: number + title: value + description: The raw original tax total's value. + raw_item_total: + type: object + description: The item's raw item total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw item total's value. + - type: number + title: value + description: The raw item total's value. + raw_item_subtotal: + type: object + description: The item's raw item subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw item subtotal's value. + - type: number + title: value + description: The raw item subtotal's value. + raw_item_tax_total: + type: object + description: The item's raw item tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw item tax total's value. + - type: number + title: value + description: The raw item tax total's value. + raw_total: + type: object + description: The item's raw total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw total's value. + - type: number + title: value + description: The raw total's value. + raw_subtotal: + type: object + description: The item's raw subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw subtotal's value. + - type: number + title: value + description: The raw subtotal's value. + raw_tax_total: + type: object + description: The item's raw tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw tax total's value. + - type: number + title: value + description: The raw tax total's value. + raw_discount_total: + type: object + description: The item's raw discount total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount total's value. + - type: number + title: value + description: The raw discount total's value. + raw_discount_tax_total: + type: object + description: The item's raw discount tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount tax total's value. + - type: number + title: value + description: The raw discount tax total's value. + raw_refundable_total: + type: object + description: The item's raw refundable total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw refundable total's value. + - type: number + title: value + description: The raw refundable total's value. + raw_refundable_total_per_unit: + type: object + description: The item's raw refundable total per unit. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw refundable total per unit's value. + - type: number + title: value + description: The raw refundable total per unit's value. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderLineItemAdjustment.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderLineItemAdjustment.yaml index 18f5e20824943..66a2f0fdea24c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderLineItemAdjustment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderLineItemAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The line item adjustment's details. x-schemaName: OrderLineItemAdjustment +required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at +properties: + item: + $ref: ./OrderLineItem.yaml + item_id: + type: string + title: item_id + description: The ID of the item this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderLineItemTaxLine.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderLineItemTaxLine.yaml index 0b002d0419eb4..89d9660f58c43 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderLineItemTaxLine.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderLineItemTaxLine.yaml @@ -1,3 +1,70 @@ type: object -description: The tax line's tax lines. +description: The line item tax line's details. x-schemaName: OrderLineItemTaxLine +required: + - item + - item_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at +properties: + item: + $ref: ./OrderLineItem.yaml + item_id: + type: string + title: item_id + description: The ID of the line item that the tax line belongs to. + total: + type: number + title: total + description: The item's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax lines. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderPreview.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderPreview.yaml deleted file mode 100644 index 56edabcde0970..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/OrderPreview.yaml +++ /dev/null @@ -1,1550 +0,0 @@ -type: object -description: The order edit's order preview. -x-schemaName: OrderPreview -required: - - order_change - - status - - currency_code - - version - - id - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total - - raw_original_item_total - - raw_original_item_subtotal - - raw_original_item_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - - raw_gift_card_total - - raw_gift_card_tax_total - - raw_shipping_total - - raw_shipping_subtotal - - raw_shipping_tax_total - - raw_original_shipping_total - - raw_original_shipping_subtotal - - raw_original_shipping_tax_total -properties: - order_change: - $ref: ./OrderChange.yaml - items: - type: array - description: The order preview's items. - items: - allOf: - - type: object - description: The item's items. - x-schemaName: OrderLineItem - required: - - id - - title - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - - raw_unit_price - - quantity - - raw_quantity - - detail - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - item_total - - item_subtotal - - item_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - refundable_total - - refundable_total_per_unit - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - - raw_refundable_total - - raw_refundable_total_per_unit - properties: - id: - type: string - title: id - description: The item's ID. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The item's thumbnail. - variant_id: - type: string - title: variant_id - description: The item's variant id. - product_id: - type: string - title: product_id - description: The item's product id. - product_title: - type: string - title: product_title - description: The item's product title. - product_description: - type: string - title: product_description - description: The item's product description. - product_subtitle: - type: string - title: product_subtitle - description: The item's product subtitle. - product_type: - type: string - title: product_type - description: The item's product type. - product_collection: - type: string - title: product_collection - description: The item's product collection. - product_handle: - type: string - title: product_handle - description: The item's product handle. - variant_sku: - type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: - type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: - type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - compare_at_unit_price: - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - raw_compare_at_unit_price: - type: object - description: The item's raw compare at unit price. - unit_price: - type: number - title: unit_price - description: The item's unit price. - raw_unit_price: - type: object - description: The item's raw unit price. - quantity: - type: number - title: quantity - description: The item's quantity. - raw_quantity: - type: object - description: The item's raw quantity. - tax_lines: - type: array - description: The item's tax lines. - items: - $ref: ./OrderLineItemTaxLine.yaml - adjustments: - type: array - description: The item's adjustments. - items: - $ref: ./OrderLineItemAdjustment.yaml - detail: - $ref: ./OrderItem.yaml - created_at: - type: string - format: date-time - title: created_at - description: The item's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The item's updated at. - metadata: - type: object - description: The item's metadata. - original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: ./IBigNumber.yaml - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: ./IBigNumber.yaml - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: ./IBigNumber.yaml - item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: ./IBigNumber.yaml - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: ./IBigNumber.yaml - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: ./IBigNumber.yaml - total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: ./IBigNumber.yaml - subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: ./IBigNumber.yaml - tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: ./IBigNumber.yaml - discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: ./IBigNumber.yaml - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: ./IBigNumber.yaml - refundable_total: - oneOf: - - type: string - title: refundable_total - description: The item's refundable total. - - type: number - title: refundable_total - description: The item's refundable total. - - type: string - title: refundable_total - description: The item's refundable total. - - $ref: ./IBigNumber.yaml - refundable_total_per_unit: - oneOf: - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: number - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - $ref: ./IBigNumber.yaml - raw_original_total: - type: object - description: The item's raw original total. - raw_original_subtotal: - type: object - description: The item's raw original subtotal. - raw_original_tax_total: - type: object - description: The item's raw original tax total. - raw_item_total: - type: object - description: The item's raw item total. - raw_item_subtotal: - type: object - description: The item's raw item subtotal. - raw_item_tax_total: - type: object - description: The item's raw item tax total. - raw_total: - type: object - description: The item's raw total. - raw_subtotal: - type: object - description: The item's raw subtotal. - raw_tax_total: - type: object - description: The item's raw tax total. - raw_discount_total: - type: object - description: The item's raw discount total. - raw_discount_tax_total: - type: object - description: The item's raw discount tax total. - raw_refundable_total: - type: object - description: The item's raw refundable total. - raw_refundable_total_per_unit: - type: object - description: The item's raw refundable total per unit. - - type: object - description: The item's items. - properties: - actions: - type: array - description: The item's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - shipping_methods: - type: array - description: The order preview's shipping methods. - items: - allOf: - - type: object - description: The shipping method's shipping methods. - x-schemaName: OrderShippingMethod - required: - - id - - order_id - - name - - amount - - raw_amount - - is_tax_inclusive - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - properties: - id: - type: string - title: id - description: The shipping method's ID. - order_id: - type: string - title: order_id - description: The shipping method's order id. - name: - type: string - title: name - description: The shipping method's name. - description: - type: string - title: description - description: The shipping method's description. - amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: ./IBigNumber.yaml - raw_amount: - type: object - description: The shipping method's raw amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping method's is tax inclusive. - shipping_option_id: - type: string - title: shipping_option_id - description: The shipping method's shipping option id. - data: - type: object - description: The shipping method's data. - metadata: - type: object - description: The shipping method's metadata. - tax_lines: - type: array - description: The shipping method's tax lines. - items: - $ref: ./OrderShippingMethodTaxLine.yaml - adjustments: - type: array - description: The shipping method's adjustments. - items: - $ref: ./OrderShippingMethodAdjustment.yaml - created_at: - type: string - format: date-time - title: created_at - description: The shipping method's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The shipping method's updated at. - original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: ./IBigNumber.yaml - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: ./IBigNumber.yaml - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: ./IBigNumber.yaml - total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: ./IBigNumber.yaml - subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: ./IBigNumber.yaml - tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: ./IBigNumber.yaml - discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: ./IBigNumber.yaml - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: ./IBigNumber.yaml - raw_original_total: - type: object - description: The shipping method's raw original total. - raw_original_subtotal: - type: object - description: The shipping method's raw original subtotal. - raw_original_tax_total: - type: object - description: The shipping method's raw original tax total. - raw_total: - type: object - description: The shipping method's raw total. - raw_subtotal: - type: object - description: The shipping method's raw subtotal. - raw_tax_total: - type: object - description: The shipping method's raw tax total. - raw_discount_total: - type: object - description: The shipping method's raw discount total. - raw_discount_tax_total: - type: object - description: The shipping method's raw discount tax total. - - type: object - description: The shipping method's shipping methods. - properties: - actions: - type: array - description: The shipping method's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - status: - type: string - description: The order preview's status. - enum: - - canceled - - requires_action - - pending - - completed - - draft - - archived - currency_code: - type: string - title: currency_code - description: The order preview's currency code. - version: - type: number - title: version - description: The order preview's version. - id: - type: string - title: id - description: The order preview's ID. - region_id: - type: string - title: region_id - description: The order preview's region id. - customer_id: - type: string - title: customer_id - description: The order preview's customer id. - sales_channel_id: - type: string - title: sales_channel_id - description: The order preview's sales channel id. - email: - type: string - title: email - description: The order preview's email. - format: email - shipping_address: - $ref: ./OrderAddress.yaml - billing_address: - $ref: ./OrderAddress.yaml - transactions: - type: array - description: The order preview's transactions. - items: - $ref: ./OrderTransaction.yaml - summary: - type: object - description: The order preview's summary. - required: - - total - - subtotal - - total_tax - - ordered_total - - fulfilled_total - - returned_total - - return_request_total - - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - - paid_total - - refunded_total - - pending_difference - - raw_pending_difference - properties: - total: - oneOf: - - type: string - title: total - description: The summary's total. - - type: number - title: total - description: The summary's total. - - type: string - title: total - description: The summary's total. - - type: object - description: The summary's total. - x-schemaName: IBigNumber - subtotal: - oneOf: - - type: string - title: subtotal - description: The summary's subtotal. - - type: number - title: subtotal - description: The summary's subtotal. - - type: string - title: subtotal - description: The summary's subtotal. - - type: object - description: The summary's subtotal. - x-schemaName: IBigNumber - total_tax: - oneOf: - - type: string - title: total_tax - description: The summary's total tax. - - type: number - title: total_tax - description: The summary's total tax. - - type: string - title: total_tax - description: The summary's total tax. - - type: object - description: The summary's total tax. - x-schemaName: IBigNumber - ordered_total: - oneOf: - - type: string - title: ordered_total - description: The summary's ordered total. - - type: number - title: ordered_total - description: The summary's ordered total. - - type: string - title: ordered_total - description: The summary's ordered total. - - type: object - description: The summary's ordered total. - x-schemaName: IBigNumber - fulfilled_total: - oneOf: - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: number - title: fulfilled_total - description: The summary's fulfilled total. - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: object - description: The summary's fulfilled total. - x-schemaName: IBigNumber - returned_total: - oneOf: - - type: string - title: returned_total - description: The summary's returned total. - - type: number - title: returned_total - description: The summary's returned total. - - type: string - title: returned_total - description: The summary's returned total. - - type: object - description: The summary's returned total. - x-schemaName: IBigNumber - return_request_total: - oneOf: - - type: string - title: return_request_total - description: The summary's return request total. - - type: number - title: return_request_total - description: The summary's return request total. - - type: string - title: return_request_total - description: The summary's return request total. - - type: object - description: The summary's return request total. - x-schemaName: IBigNumber - write_off_total: - oneOf: - - type: string - title: write_off_total - description: The summary's write off total. - - type: number - title: write_off_total - description: The summary's write off total. - - type: string - title: write_off_total - description: The summary's write off total. - - type: object - description: The summary's write off total. - x-schemaName: IBigNumber - projected_total: - oneOf: - - type: string - title: projected_total - description: The summary's projected total. - - type: number - title: projected_total - description: The summary's projected total. - - type: string - title: projected_total - description: The summary's projected total. - - type: object - description: The summary's projected total. - x-schemaName: IBigNumber - net_total: - oneOf: - - type: string - title: net_total - description: The summary's net total. - - type: number - title: net_total - description: The summary's net total. - - type: string - title: net_total - description: The summary's net total. - - type: object - description: The summary's net total. - x-schemaName: IBigNumber - net_subtotal: - oneOf: - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: number - title: net_subtotal - description: The summary's net subtotal. - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: object - description: The summary's net subtotal. - x-schemaName: IBigNumber - net_total_tax: - oneOf: - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: number - title: net_total_tax - description: The summary's net total tax. - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: object - description: The summary's net total tax. - x-schemaName: IBigNumber - balance: - oneOf: - - type: string - title: balance - description: The summary's balance. - - type: number - title: balance - description: The summary's balance. - - type: string - title: balance - description: The summary's balance. - - type: object - description: The summary's balance. - x-schemaName: IBigNumber - paid_total: - oneOf: - - type: string - title: paid_total - description: The summary's paid total. - - type: number - title: paid_total - description: The summary's paid total. - - type: string - title: paid_total - description: The summary's paid total. - - type: object - description: The summary's paid total. - x-schemaName: IBigNumber - refunded_total: - oneOf: - - type: string - title: refunded_total - description: The summary's refunded total. - - type: number - title: refunded_total - description: The summary's refunded total. - - type: string - title: refunded_total - description: The summary's refunded total. - - type: object - description: The summary's refunded total. - x-schemaName: IBigNumber - pending_difference: - oneOf: - - type: string - title: pending_difference - description: The summary's pending difference. - - type: number - title: pending_difference - description: The summary's pending difference. - - type: string - title: pending_difference - description: The summary's pending difference. - - type: object - description: The summary's pending difference. - x-schemaName: IBigNumber - raw_pending_difference: - type: object - description: The summary's raw pending difference. - metadata: - type: object - description: The order preview's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The order preview's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The order preview's updated at. - original_item_total: - oneOf: - - type: string - title: original_item_total - description: The order preview's original item total. - - type: number - title: original_item_total - description: The order preview's original item total. - - type: string - title: original_item_total - description: The order preview's original item total. - - $ref: ./IBigNumber.yaml - original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: number - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - $ref: ./IBigNumber.yaml - original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - type: number - title: original_item_tax_total - description: The order preview's original item tax total. - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - $ref: ./IBigNumber.yaml - item_total: - oneOf: - - type: string - title: item_total - description: The order preview's item total. - - type: number - title: item_total - description: The order preview's item total. - - type: string - title: item_total - description: The order preview's item total. - - $ref: ./IBigNumber.yaml - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - type: number - title: item_subtotal - description: The order preview's item subtotal. - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - $ref: ./IBigNumber.yaml - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The order preview's item tax total. - - type: number - title: item_tax_total - description: The order preview's item tax total. - - type: string - title: item_tax_total - description: The order preview's item tax total. - - $ref: ./IBigNumber.yaml - original_total: - oneOf: - - type: string - title: original_total - description: The order preview's original total. - - type: number - title: original_total - description: The order preview's original total. - - type: string - title: original_total - description: The order preview's original total. - - $ref: ./IBigNumber.yaml - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - type: number - title: original_subtotal - description: The order preview's original subtotal. - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - $ref: ./IBigNumber.yaml - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The order preview's original tax total. - - type: number - title: original_tax_total - description: The order preview's original tax total. - - type: string - title: original_tax_total - description: The order preview's original tax total. - - $ref: ./IBigNumber.yaml - total: - oneOf: - - type: string - title: total - description: The order preview's total. - - type: number - title: total - description: The order preview's total. - - type: string - title: total - description: The order preview's total. - - $ref: ./IBigNumber.yaml - subtotal: - oneOf: - - type: string - title: subtotal - description: The order preview's subtotal. - - type: number - title: subtotal - description: The order preview's subtotal. - - type: string - title: subtotal - description: The order preview's subtotal. - - $ref: ./IBigNumber.yaml - tax_total: - oneOf: - - type: string - title: tax_total - description: The order preview's tax total. - - type: number - title: tax_total - description: The order preview's tax total. - - type: string - title: tax_total - description: The order preview's tax total. - - $ref: ./IBigNumber.yaml - discount_total: - oneOf: - - type: string - title: discount_total - description: The order preview's discount total. - - type: number - title: discount_total - description: The order preview's discount total. - - type: string - title: discount_total - description: The order preview's discount total. - - $ref: ./IBigNumber.yaml - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - type: number - title: discount_tax_total - description: The order preview's discount tax total. - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - $ref: ./IBigNumber.yaml - gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The order preview's gift card total. - - type: number - title: gift_card_total - description: The order preview's gift card total. - - type: string - title: gift_card_total - description: The order preview's gift card total. - - $ref: ./IBigNumber.yaml - gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: number - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - $ref: ./IBigNumber.yaml - shipping_total: - oneOf: - - type: string - title: shipping_total - description: The order preview's shipping total. - - type: number - title: shipping_total - description: The order preview's shipping total. - - type: string - title: shipping_total - description: The order preview's shipping total. - - $ref: ./IBigNumber.yaml - shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: number - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - $ref: ./IBigNumber.yaml - shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: number - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - $ref: ./IBigNumber.yaml - original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - type: number - title: original_shipping_total - description: The order preview's original shipping total. - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - $ref: ./IBigNumber.yaml - original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - $ref: ./IBigNumber.yaml - original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - $ref: ./IBigNumber.yaml - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order preview's canceled at. - - type: string - title: canceled_at - description: The order preview's canceled at. - format: date-time - raw_original_item_total: - type: object - description: The order preview's raw original item total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original item total's value. - - type: number - title: value - description: The raw original item total's value. - raw_original_item_subtotal: - type: object - description: The order preview's raw original item subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original item subtotal's value. - - type: number - title: value - description: The raw original item subtotal's value. - raw_original_item_tax_total: - type: object - description: The order preview's raw original item tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original item tax total's value. - - type: number - title: value - description: The raw original item tax total's value. - raw_item_total: - type: object - description: The order preview's raw item total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw item total's value. - - type: number - title: value - description: The raw item total's value. - raw_item_subtotal: - type: object - description: The order preview's raw item subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw item subtotal's value. - - type: number - title: value - description: The raw item subtotal's value. - raw_item_tax_total: - type: object - description: The order preview's raw item tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw item tax total's value. - - type: number - title: value - description: The raw item tax total's value. - raw_original_total: - type: object - description: The order preview's raw original total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original total's value. - - type: number - title: value - description: The raw original total's value. - raw_original_subtotal: - type: object - description: The order preview's raw original subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original subtotal's value. - - type: number - title: value - description: The raw original subtotal's value. - raw_original_tax_total: - type: object - description: The order preview's raw original tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original tax total's value. - - type: number - title: value - description: The raw original tax total's value. - raw_total: - type: object - description: The order preview's raw total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw total's value. - - type: number - title: value - description: The raw total's value. - raw_subtotal: - type: object - description: The order preview's raw subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw subtotal's value. - - type: number - title: value - description: The raw subtotal's value. - raw_tax_total: - type: object - description: The order preview's raw tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw tax total's value. - - type: number - title: value - description: The raw tax total's value. - raw_discount_total: - type: object - description: The order preview's raw discount total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw discount total's value. - - type: number - title: value - description: The raw discount total's value. - raw_discount_tax_total: - type: object - description: The order preview's raw discount tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw discount tax total's value. - - type: number - title: value - description: The raw discount tax total's value. - raw_gift_card_total: - type: object - description: The order preview's raw gift card total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw gift card total's value. - - type: number - title: value - description: The raw gift card total's value. - raw_gift_card_tax_total: - type: object - description: The order preview's raw gift card tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw gift card tax total's value. - - type: number - title: value - description: The raw gift card tax total's value. - raw_shipping_total: - type: object - description: The order preview's raw shipping total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw shipping total's value. - - type: number - title: value - description: The raw shipping total's value. - raw_shipping_subtotal: - type: object - description: The order preview's raw shipping subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw shipping subtotal's value. - - type: number - title: value - description: The raw shipping subtotal's value. - raw_shipping_tax_total: - type: object - description: The order preview's raw shipping tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw shipping tax total's value. - - type: number - title: value - description: The raw shipping tax total's value. - raw_original_shipping_total: - type: object - description: The order preview's raw original shipping total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original shipping total's value. - - type: number - title: value - description: The raw original shipping total's value. - raw_original_shipping_subtotal: - type: object - description: The order preview's raw original shipping subtotal. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original shipping subtotal's value. - - type: number - title: value - description: The raw original shipping subtotal's value. - raw_original_shipping_tax_total: - type: object - description: The order preview's raw original shipping tax total. - required: - - value - properties: - value: - oneOf: - - type: string - title: value - description: The raw original shipping tax total's value. - - type: number - title: value - description: The raw original shipping tax total's value. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderReturnItem.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderReturnItem.yaml new file mode 100644 index 0000000000000..2b2fa31a3833b --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/OrderReturnItem.yaml @@ -0,0 +1,50 @@ +type: object +description: The item's items. +x-schemaName: OrderReturnItem +required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id +properties: + id: + type: string + title: id + description: The return item's ID. + quantity: + type: number + title: quantity + description: The return item's quantity. + received_quantity: + type: number + title: received_quantity + description: >- + The received quantity of the item. This quantity is added to the stocked + inventory quantity of the item. + damaged_quantity: + type: number + title: damaged_quantity + description: >- + The received damaged quantity of the item, which isn't added to the + stocked inventory quantity of the item. + reason_id: + type: string + title: reason_id + description: The ID of the return reason associated with the item. + note: + type: string + title: note + description: A note about why the item was returned. + item_id: + type: string + title: item_id + description: The ID of the associated order item. + return_id: + type: string + title: return_id + description: The ID of the return this return item belongs to. + metadata: + type: object + description: The return item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethod.yaml new file mode 100644 index 0000000000000..892005eea081c --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethod.yaml @@ -0,0 +1,246 @@ +type: object +description: The shipping method's details. +x-schemaName: OrderShippingMethod +required: + - id + - order_id + - name + - amount + - raw_amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total +properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order that the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + raw_amount: + type: object + description: The shipping method's raw amount. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw amount's value. + - type: number + title: value + description: The raw amount's value. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: >- + The shipping method's data, useful for the fulfillment provider handling + the fulfillment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/order/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: ./OrderShippingMethodTaxLine.yaml + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: ./OrderShippingMethodAdjustment.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's subtotal excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the shipping method excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes of the shipping method, including promotions. + discount_total: + type: number + title: discount_total + description: The shipping method's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes of the discount amount. + raw_original_total: + type: object + description: The shipping method's raw original total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original total's value. + - type: number + title: value + description: The raw original total's value. + raw_original_subtotal: + type: object + description: The shipping method's raw original subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original subtotal's value. + - type: number + title: value + description: The raw original subtotal's value. + raw_original_tax_total: + type: object + description: The shipping method's raw original tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw original tax total's value. + - type: number + title: value + description: The raw original tax total's value. + raw_total: + type: object + description: The shipping method's raw total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw total's value. + - type: number + title: value + description: The raw total's value. + raw_subtotal: + type: object + description: The shipping method's raw subtotal. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw subtotal's value. + - type: number + title: value + description: The raw subtotal's value. + raw_tax_total: + type: object + description: The shipping method's raw tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw tax total's value. + - type: number + title: value + description: The raw tax total's value. + raw_discount_total: + type: object + description: The shipping method's raw discount total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount total's value. + - type: number + title: value + description: The raw discount total's value. + raw_discount_tax_total: + type: object + description: The shipping method's raw discount tax total. + required: + - value + properties: + value: + oneOf: + - type: string + title: value + description: The raw discount tax total's value. + - type: number + title: value + description: The raw discount tax total's value. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodAdjustment.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodAdjustment.yaml index a05be82f6280a..9f066b339ce92 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodAdjustment.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodAdjustment.yaml @@ -1,3 +1,56 @@ type: object -description: The adjustment's adjustments. +description: The shipping method adjustment's details. x-schemaName: OrderShippingMethodAdjustment +required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at +properties: + shipping_method: + $ref: ./OrderShippingMethod.yaml + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion this adjustment applies. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodTaxLine.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodTaxLine.yaml index 89976e41b4931..0a475fe7a9af3 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodTaxLine.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderShippingMethodTaxLine.yaml @@ -1,3 +1,70 @@ type: object -description: The tax line's tax lines. +description: The shipping method tax line's details. x-schemaName: OrderShippingMethodTaxLine +required: + - shipping_method + - shipping_method_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at +properties: + shipping_method: + $ref: ./OrderShippingMethod.yaml + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method that this tax line is for. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/OrderTransaction.yaml b/www/apps/api-reference/specs/store/components/schemas/OrderTransaction.yaml index fe6226719f601..100e873e64f4b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/OrderTransaction.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/OrderTransaction.yaml @@ -1,18 +1,16 @@ type: object -description: The transaction's transactions. +description: The transaction's details. x-schemaName: OrderTransaction required: - id - order_id - - order - amount - - raw_amount - currency_code - reference - reference_id + - metadata - created_at - updated_at - - metadata properties: id: type: string @@ -21,46 +19,40 @@ properties: order_id: type: string title: order_id - description: The transaction's order id. - order: - type: object + description: The ID of the order this transaction belongs to. amount: - oneOf: - - type: string - title: amount - description: The transaction's amount. - - type: number - title: amount - description: The transaction's amount. - - type: string - title: amount - description: The transaction's amount. - - $ref: ./IBigNumber.yaml - raw_amount: - type: object - description: The transaction's raw amount. + type: number + title: amount + description: The transaction's amount. currency_code: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: >- + The name of a table that this transaction references. If this transaction + is for captured payment, its value is `capture`. If this transaction is + for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. + metadata: + type: object + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. - metadata: - type: object - description: The transaction's metadata. + description: The date that the transaction was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/RefundReason.yaml b/www/apps/api-reference/specs/store/components/schemas/RefundReason.yaml new file mode 100644 index 0000000000000..46c54887802c2 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/RefundReason.yaml @@ -0,0 +1,35 @@ +type: object +description: The refund's refund reason. +x-schemaName: RefundReason +required: + - id + - label + - metadata + - created_at + - updated_at +properties: + id: + type: string + title: id + description: The refund reason's ID. + label: + type: string + title: label + description: The refund reason's label. + description: + type: string + title: description + description: The refund reason's description. + metadata: + type: object + description: The refund reason's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The refund reason's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The refund reason's updated at. diff --git a/www/apps/api-reference/specs/store/components/schemas/RefundReasonResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/RefundReasonResponse.yaml index 2ccee98673d1d..e3f9c36587bd9 100644 --- a/www/apps/api-reference/specs/store/components/schemas/RefundReasonResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/RefundReasonResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The refund reason's details. x-schemaName: RefundReasonResponse required: - refund_reason diff --git a/www/apps/api-reference/specs/store/components/schemas/ReservationResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/ReservationResponse.yaml deleted file mode 100644 index d66cc74750e04..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/ReservationResponse.yaml +++ /dev/null @@ -1,66 +0,0 @@ -type: object -description: The reservation's details. -x-schemaName: ReservationResponse -required: - - id - - line_item_id - - location_id - - quantity - - external_id - - description - - inventory_item_id - - inventory_item -properties: - id: - type: string - title: id - description: The reservation's ID. - line_item_id: - type: string - title: line_item_id - description: The reservation's line item id. - location_id: - type: string - title: location_id - description: The reservation's location id. - quantity: - type: string - title: quantity - description: The reservation's quantity. - external_id: - type: string - title: external_id - description: The reservation's external id. - description: - type: string - title: description - description: The reservation's description. - inventory_item_id: - type: string - title: inventory_item_id - description: The reservation's inventory item id. - inventory_item: - type: object - description: The reservation's inventory item. - metadata: - type: object - description: The reservation's metadata. - created_by: - type: string - title: created_by - description: The reservation's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The reservation's deleted at. - created_at: - type: string - format: date-time - title: created_at - description: The reservation's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The reservation's updated at. diff --git a/www/apps/api-reference/specs/store/components/schemas/Return.yaml b/www/apps/api-reference/specs/store/components/schemas/Return.yaml index 529ada57ca7f1..b16dbae793752 100644 --- a/www/apps/api-reference/specs/store/components/schemas/Return.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/Return.yaml @@ -1,3 +1,299 @@ type: object -description: The order change's return order. +description: The return's details. x-schemaName: Return +required: + - id + - status + - order_id + - items + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - discount_subtotal + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total +properties: + id: + type: string + title: id + description: The return's ID. + status: + type: string + description: The return's status. + enum: + - canceled + - requested + - received + - partially_received + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. + order_id: + type: string + title: order_id + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: ./OrderReturnItem.yaml + region_id: + type: string + title: region_id + description: The ID of the region this return belongs to. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the associated order's sales channel. + email: + type: string + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The return's currency code. + example: usd + shipping_address: + $ref: ./OrderAddress.yaml + billing_address: + $ref: ./OrderAddress.yaml + shipping_methods: + type: array + description: The return's shipping methods. + items: + $ref: ./OrderShippingMethod.yaml + transactions: + type: array + description: The return's transactions. + items: + $ref: ./OrderTransaction.yaml + summary: + type: object + description: The return's summary. + metadata: + type: object + description: The return's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the return was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the return was updated. + original_item_total: + type: number + title: original_item_total + description: The return's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The return's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The return's original item tax total. + item_total: + type: number + title: item_total + description: The return's item total. + item_subtotal: + type: number + title: item_subtotal + description: The return's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The return's item tax total. + original_total: + type: number + title: original_total + description: The return's original total. + original_subtotal: + type: number + title: original_subtotal + description: The return's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The return's original tax total. + total: + type: number + title: total + description: The return's total. + subtotal: + type: number + title: subtotal + description: The return's subtotal. + tax_total: + type: number + title: tax_total + description: The return's tax total. + discount_total: + type: number + title: discount_total + description: The return's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The return's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The return's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The return's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The return's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The return's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The return's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The return's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The return's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The return's original shipping tax total. + order_change: + $ref: ./OrderChange.yaml + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time + discount_subtotal: + type: number + title: discount_subtotal + description: The return's discount subtotal. + raw_original_item_total: + type: object + description: The return's raw original item total. + raw_original_item_subtotal: + type: object + description: The return's raw original item subtotal. + raw_original_item_tax_total: + type: object + description: The return's raw original item tax total. + raw_item_total: + type: object + description: The return's raw item total. + raw_item_subtotal: + type: object + description: The return's raw item subtotal. + raw_item_tax_total: + type: object + description: The return's raw item tax total. + raw_original_total: + type: object + description: The return's raw original total. + raw_original_subtotal: + type: object + description: The return's raw original subtotal. + raw_original_tax_total: + type: object + description: The return's raw original tax total. + raw_total: + type: object + description: The return's raw total. + raw_subtotal: + type: object + description: The return's raw subtotal. + raw_tax_total: + type: object + description: The return's raw tax total. + raw_discount_total: + type: object + description: The return's raw discount total. + raw_discount_tax_total: + type: object + description: The return's raw discount tax total. + raw_gift_card_total: + type: object + description: The return's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The return's raw gift card tax total. + raw_shipping_total: + type: object + description: The return's raw shipping total. + raw_shipping_subtotal: + type: object + description: The return's raw shipping subtotal. + raw_shipping_tax_total: + type: object + description: The return's raw shipping tax total. + raw_original_shipping_total: + type: object + description: The return's raw original shipping total. + raw_original_shipping_subtotal: + type: object + description: The return's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The return's raw original shipping tax total. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreAddCartLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreAddCartLineItem.yaml index c791cbd824f56..8ce18622d407c 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreAddCartLineItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreAddCartLineItem.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the line item to add. x-schemaName: StoreAddCartLineItem required: - variant_id @@ -8,11 +8,11 @@ properties: variant_id: type: string title: variant_id - description: The cart's variant id. + description: The ID of the product variant to add to the cart. quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. + description: The item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCalculateCartTaxes.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCalculateCartTaxes.yaml deleted file mode 100644 index 729f1b95bd669..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCalculateCartTaxes.yaml +++ /dev/null @@ -1,8 +0,0 @@ -type: object -description: SUMMARY -x-schemaName: StoreCalculateCartTaxes -properties: - fields: - type: string - title: fields - description: The cart's fields. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCart.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCart.yaml index 73037779afb15..9ec4dc1c9fa13 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCart.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCart.yaml @@ -1,9 +1,9 @@ type: object -description: The cart's parent. +description: The cart's details. x-schemaName: StoreCart required: - - id - currency_code + - id - original_item_total - original_item_subtotal - original_item_tax_total @@ -30,320 +30,148 @@ properties: id: type: string title: id - description: The parent's ID. + description: The cart's ID. region: - $ref: ./BaseRegion.yaml + $ref: ./StoreRegion.yaml region_id: type: string title: region_id - description: The parent's region id. + description: The ID of the region the cart belongs to. customer_id: type: string title: customer_id - description: The parent's customer id. + description: The ID of the customer the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The parent's sales channel id. + description: >- + The ID of the cart's sales channel. Only products that belong to the same + sales channel can be added to the cart. The created order will be + associated with the same sales channel. email: type: string title: email - description: The parent's email. + description: The email of the customer the cart belongs to. format: email currency_code: type: string title: currency_code - description: The parent's currency code. + description: The cart's currency code. + example: usd shipping_address: - $ref: ./BaseCartAddress.yaml + $ref: ./StoreCartAddress.yaml billing_address: - $ref: ./BaseCartAddress.yaml + $ref: ./StoreCartAddress.yaml items: type: array - description: The parent's items. + description: The cart's items. items: - $ref: ./BaseCartLineItem.yaml + $ref: ./StoreCartLineItem.yaml shipping_methods: type: array - description: The parent's shipping methods. + description: The cart's shipping methods. items: - $ref: ./BaseCartShippingMethod.yaml + $ref: ./StoreCartShippingMethod.yaml payment_collection: - $ref: ./BasePaymentCollection.yaml + $ref: ./StorePaymentCollection.yaml metadata: type: object - description: The parent's metadata. + description: The cart's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the cart was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the cart was updated. original_item_total: - oneOf: - - type: string - title: original_item_total - description: The parent's original item total. - - type: number - title: original_item_total - description: The parent's original item total. - - type: string - title: original_item_total - description: The parent's original item total. - - $ref: ./IBigNumber.yaml + type: number + title: original_item_total + description: The cart items' total including taxes, excluding promotions. original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - type: number - title: original_item_subtotal - description: The parent's original item subtotal. - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_item_subtotal + description: The cart items' total excluding taxes, including promotions. original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - type: number - title: original_item_tax_total - description: The parent's original item tax total. - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_item_tax_total + description: The cart items' tax total excluding promotions. item_total: - oneOf: - - type: string - title: item_total - description: The parent's item total. - - type: number - title: item_total - description: The parent's item total. - - type: string - title: item_total - description: The parent's item total. - - $ref: ./IBigNumber.yaml + type: number + title: item_total + description: The cart items' total including taxes and promotions. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The parent's item subtotal. - - type: number - title: item_subtotal - description: The parent's item subtotal. - - type: string - title: item_subtotal - description: The parent's item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: item_subtotal + description: The cart items' total excluding taxes, including promotions. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The parent's item tax total. - - type: number - title: item_tax_total - description: The parent's item tax total. - - type: string - title: item_tax_total - description: The parent's item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: item_tax_total + description: The cart items' tax total including promotions. original_total: - oneOf: - - type: string - title: original_total - description: The parent's original total. - - type: number - title: original_total - description: The parent's original total. - - type: string - title: original_total - description: The parent's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The cart's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The parent's original subtotal. - - type: number - title: original_subtotal - description: The parent's original subtotal. - - type: string - title: original_subtotal - description: The parent's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The cart's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The parent's original tax total. - - type: number - title: original_tax_total - description: The parent's original tax total. - - type: string - title: original_tax_total - description: The parent's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The cart's tax total excluding promotions. total: - oneOf: - - type: string - title: total - description: The parent's total. - - type: number - title: total - description: The parent's total. - - type: string - title: total - description: The parent's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The cart's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The parent's subtotal. - - type: number - title: subtotal - description: The parent's subtotal. - - type: string - title: subtotal - description: The parent's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The cart's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The parent's tax total. - - type: number - title: tax_total - description: The parent's tax total. - - type: string - title: tax_total - description: The parent's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The cart's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The parent's discount total. - - type: number - title: discount_total - description: The parent's discount total. - - type: string - title: discount_total - description: The parent's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The cart's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - type: number - title: discount_tax_total - description: The parent's discount tax total. - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The tax total applied on the discounted amount. gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The parent's gift card total. - - type: number - title: gift_card_total - description: The parent's gift card total. - - type: string - title: gift_card_total - description: The parent's gift card total. - - $ref: ./IBigNumber.yaml + type: number + title: gift_card_total + description: The total gift card amount applied on the cart. gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: number - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - $ref: ./IBigNumber.yaml + type: number + title: gift_card_tax_total + description: The total taxes applied on the gift card amount. shipping_total: - oneOf: - - type: string - title: shipping_total - description: The parent's shipping total. - - type: number - title: shipping_total - description: The parent's shipping total. - - type: string - title: shipping_total - description: The parent's shipping total. - - $ref: ./IBigNumber.yaml + type: number + title: shipping_total + description: The cart's shipping total including taxes and promotions. shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: number - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - type: number - title: shipping_tax_total - description: The parent's shipping tax total. - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - $ref: ./IBigNumber.yaml + type: number + title: shipping_tax_total + description: The total taxes applied on the cart's shipping amount. original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - type: number - title: original_shipping_total - description: The parent's original shipping total. - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - $ref: ./IBigNumber.yaml + type: number + title: original_shipping_total + description: The cart's shipping total including taxes, excluding promotions. original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_shipping_tax_total + description: The total taxes applied on the cart's shipping amount. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCartAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCartAddress.yaml index af376781b2e4c..15aa12c9eb2e1 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCartAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCartAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The cart's billing address. +description: The address's details. x-schemaName: StoreCartAddress required: - id @@ -9,69 +9,62 @@ properties: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer the address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: - oneOf: - - type: string - title: created_at - description: The billing address's created at. - - type: string - title: created_at - description: The billing address's created at. - format: date-time + type: string + title: created_at + description: The date the address was created. + format: date-time updated_at: - oneOf: - - type: string - title: updated_at - description: The billing address's updated at. - - type: string - title: updated_at - description: The billing address's updated at. - format: date-time + type: string + title: updated_at + description: The date the address was updated. + format: date-time diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCartLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCartLineItem.yaml index 1b92e40ec6128..ee8e43a4dfaac 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCartLineItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCartLineItem.yaml @@ -1,27 +1,27 @@ type: object -description: The item's items. +description: The item's details. x-schemaName: StoreCartLineItem required: - - id - - title - - quantity - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - cart - - cart_id - - original_total - - original_subtotal - - original_tax_total + - title + - id - item_total - item_subtotal - item_tax_total + - original_total + - original_subtotal + - original_tax_total - total - subtotal - tax_total - discount_total - discount_tax_total + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - cart_id properties: id: type: string @@ -38,25 +38,17 @@ properties: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The item's thumbnail URL. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: ./IBigNumber.yaml + type: number + title: quantity + description: The item's quantity. product: - $ref: ./BaseProduct.yaml + $ref: ./StoreProduct.yaml product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -72,25 +64,25 @@ properties: product_type: type: string title: product_type - description: The item's product type. + description: The ID of the associated product's type. product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the associated product's collection. product_handle: type: string title: product_handle description: The item's product handle. variant: - $ref: ./BaseProductVariant.yaml + $ref: ./StoreProductVariant.yaml variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated product variant. variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -101,43 +93,29 @@ properties: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The associated variant's value for the product's options. + example: + Color: Red requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item's price includes taxes. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: ./IBigNumber.yaml + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: ./IBigNumber.yaml + type: number + title: unit_price + description: The price of a single quantity of the item. tax_lines: type: array description: The item's tax lines. @@ -149,158 +127,70 @@ properties: items: $ref: ./BaseLineItemAdjustment.yaml cart: - $ref: ./BaseCart.yaml + $ref: ./StoreCart.yaml cart_id: type: string title: cart_id - description: The item's cart id. + description: The ID of the cart that the line item belongs to. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string title: created_at - description: The item's created at. + description: The date the item was created. format: date-time updated_at: type: string title: updated_at - description: The item's updated at. + description: The date the item was updated. format: date-time deleted_at: type: string title: deleted_at - description: The item's deleted at. + description: The date the item was deleted. format: date-time original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: ./IBigNumber.yaml + type: number + title: original_total + description: The item's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: ./IBigNumber.yaml + type: number + title: original_tax_total + description: The item's total including taxes and promotions. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: ./IBigNumber.yaml + type: number + title: item_tax_total + description: The total taxes of the item including promotions. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: ./IBigNumber.yaml + type: number + title: total + description: The item's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: ./IBigNumber.yaml + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: ./IBigNumber.yaml + type: number + title: tax_total + description: The total taxes of the item including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_total + description: The total discount of the item. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: ./IBigNumber.yaml + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCartResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCartResponse.yaml index 2bfa43f956320..43ad8c70350b7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCartResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCartResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The cart's details. x-schemaName: StoreCartResponse required: - cart diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCartShippingMethod.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCartShippingMethod.yaml new file mode 100644 index 0000000000000..504b272d77b84 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCartShippingMethod.yaml @@ -0,0 +1,115 @@ +type: object +description: A cart's shipping method. +x-schemaName: StoreCartShippingMethod +required: + - id + - cart_id + - name + - amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total +properties: + id: + type: string + title: id + description: The shipping method's ID. + cart_id: + type: string + title: cart_id + description: The ID of the cart this shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount is tax inclusive. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: >- + The shipping method's data, useful for fulfillment handling by third-party + services. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: ./BaseShippingMethodTaxLine.yaml + adjustments: + type: array + description: The shipping method's adjustments, such as applied promotions. + items: + $ref: ./BaseShippingMethodAdjustment.yaml + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. + total: + type: number + title: total + description: The shipping method's total amount including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: >- + The total taxes applied on the shipping method's amount including + promotions. + discount_total: + type: number + title: discount_total + description: The total amount discounted. + discount_tax_total: + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCollection.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCollection.yaml index a336103bb6af8..b98685c0809eb 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCollection.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCollection.yaml @@ -26,17 +26,17 @@ properties: type: string format: date-time title: created_at - description: The collection's created at. + description: The date the collection was created. updated_at: type: string format: date-time title: updated_at - description: The collection's updated at. + description: The date the collection was updated. deleted_at: type: string format: date-time title: deleted_at - description: The collection's deleted at. + description: The date the collection was deleted. products: type: array description: The collection's products. @@ -44,4 +44,4 @@ properties: $ref: ./AdminProduct.yaml metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCollectionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCollectionResponse.yaml index ad095a583e75b..ee547bec166b1 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCollectionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCollectionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The collection's details. x-schemaName: StoreCollectionResponse required: - collection diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCreateCart.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCreateCart.yaml index 41c5888a13851..69fb5ff088f3a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCreateCart.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCreateCart.yaml @@ -1,11 +1,13 @@ type: object -description: SUMMARY +description: The details of the cart to be created. x-schemaName: StoreCreateCart properties: region_id: type: string title: region_id - description: The cart's region id. + description: >- + The ID of the cart's region. This affects the prices and currency of the + cart. shipping_address: $ref: ./StoreCartAddress.yaml billing_address: @@ -13,12 +15,15 @@ properties: email: type: string title: email - description: The cart's email. + description: The email of the cart's customer. format: email currency_code: type: string title: currency_code - description: The cart's currency code. + description: >- + The cart's currency code. If not provided, the region's currency is used. + This affects prices in the cart, as well. + example: usd items: type: array description: The cart's items. @@ -27,7 +32,10 @@ properties: sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: >- + The ID of the sales channel that cart is created in. Only products + available in that sales channel can be added to the cart. If not provided, + the store's default sales channel is associated with the cart instead. metadata: type: object - description: The cart's metadata. + description: The cart's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCreateCustomer.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCreateCustomer.yaml index f8f116c0fa889..6821b053399fc 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCreateCustomer.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCreateCustomer.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the customer to create. x-schemaName: StoreCreateCustomer required: - email @@ -27,4 +27,4 @@ properties: description: The customer's phone. metadata: type: object - description: The customer's metadata. + description: The customer's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCreatePaymentCollection.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCreatePaymentCollection.yaml index c88dbe20d2a73..d93623368f5a7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCreatePaymentCollection.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCreatePaymentCollection.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the payment collection to create. x-schemaName: StoreCreatePaymentCollection required: - cart_id @@ -7,4 +7,4 @@ properties: cart_id: type: string title: cart_id - description: The payment collection's cart id. + description: The ID of the cart this payment collection is for. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturn.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturn.yaml index 60c6dc1fd5961..bd5befc29b7c6 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturn.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturn.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details of the return to create. x-schemaName: StoreCreateReturn required: - order_id @@ -9,7 +9,7 @@ properties: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. items: type: array description: The return's items. @@ -20,12 +20,12 @@ properties: note: type: string title: note - description: The return's note. + description: A note with more details about the return. receive_now: type: boolean title: receive_now - description: The return's receive now. + description: Whether to mark the return as received. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location that items are returned to. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnItem.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnItem.yaml index 021192cc25bd7..ecdbeb0c2dad0 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnItem.yaml @@ -1,5 +1,5 @@ type: object -description: The item's items. +description: The details of the line item to create. x-schemaName: StoreCreateReturnItem required: - id @@ -16,8 +16,8 @@ properties: reason_id: type: string title: reason_id - description: The item's reason id. + description: The ID of the associated return reason. note: type: string title: note - description: The item's note. + description: A note with more details about the returned item. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnShipping.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnShipping.yaml index ff842a71750be..ee60d6374b1a3 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnShipping.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCreateReturnShipping.yaml @@ -1,5 +1,5 @@ type: object -description: The return's return shipping. +description: The return's shipping details. x-schemaName: StoreCreateReturnShipping required: - option_id @@ -7,8 +7,8 @@ properties: option_id: type: string title: option_id - description: The return shipping's option id. + description: The ID of the shipping option to use. price: type: number title: price - description: The return shipping's price. + description: The shipping's price. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCurrency.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCurrency.yaml index 05eec9f84db00..70e56aa4eb3f2 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCurrency.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCurrency.yaml @@ -8,7 +8,6 @@ required: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at @@ -17,6 +16,7 @@ properties: type: string title: code description: The currency's code. + example: usd symbol: type: string title: symbol @@ -37,33 +37,18 @@ properties: type: number title: rounding description: The currency's rounding. - raw_rounding: - type: object - description: The currency's raw rounding. - required: - - value - - precision - properties: - value: - type: string - title: value - description: The raw rounding's value. - precision: - type: number - title: precision - description: The raw rounding's precision. created_at: type: string format: date-time title: created_at - description: The currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The currency's deleted at. + description: The date the currency was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyListResponse.yaml index cb51836b4b798..349a669091da5 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of currencies. x-schemaName: StoreCurrencyListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The currency's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The currency's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The currency's count. + description: The total count of items. currencies: type: array - description: The currency's currencies. + description: The list of currencies. items: $ref: ./StoreCurrency.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyResponse.yaml index 18fffcdeeb70c..2bb1a6b68ae81 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCurrencyResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The currency's details. x-schemaName: StoreCurrencyResponse required: - currency diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCustomer.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCustomer.yaml index c6626ecc9c314..f3028c75589e4 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCustomer.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCustomer.yaml @@ -1,5 +1,5 @@ type: object -description: The customer's parent. +description: The customer's details. x-schemaName: StoreCustomer required: - id @@ -14,60 +14,60 @@ properties: id: type: string title: id - description: The parent's ID. + description: The customer's ID. email: type: string title: email - description: The parent's email. + description: The customer's email. format: email default_billing_address_id: type: string title: default_billing_address_id - description: The parent's default billing address id. + description: The ID of the address used for billing by default. default_shipping_address_id: type: string title: default_shipping_address_id - description: The parent's default shipping address id. + description: The ID of the address used for shipping by default. company_name: type: string title: company_name - description: The parent's company name. + description: The customer's company name. first_name: type: string title: first_name - description: The parent's first name. + description: The customer's first name. last_name: type: string title: last_name - description: The parent's last name. + description: The customer's last name. addresses: type: array - description: The parent's addresses. + description: The customer's addresses. items: $ref: ./BaseCustomerAddress.yaml phone: type: string title: phone - description: The parent's phone. + description: The customer's phone. metadata: type: object - description: The parent's metadata. - created_by: - type: string - title: created_by - description: The parent's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The parent's deleted at. + description: The customer's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the customer was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the customer was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the customer was deleted. + created_by: + type: string + title: created_by + description: The customer's created by. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddress.yaml index 8bc8942adb986..4d3108e25f58e 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The customer's address. +description: The customer address's details x-schemaName: StoreCustomerAddress required: - id @@ -28,19 +28,19 @@ properties: address_name: type: string title: address_name - description: The address's address name. + description: The address's name. is_default_shipping: type: boolean title: is_default_shipping - description: The address's is default shipping. + description: Whether the address is used for shipping by default. is_default_billing: type: boolean title: is_default_billing - description: The address's is default billing. + description: Whether the address is used for billing by default. customer_id: type: string title: customer_id - description: The address's customer id. + description: The ID of the customer the address belongs to. company: type: string title: company @@ -56,11 +56,11 @@ properties: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. city: type: string title: city @@ -69,6 +69,7 @@ properties: type: string title: country_code description: The address's country code. + example: usd province: type: string title: province @@ -83,14 +84,14 @@ properties: description: The address's phone. metadata: type: object - description: The address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The address's updated at. + description: The date the address was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressListResponse.yaml index ae6cf1559e412..e04348e7e3694 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of customer addresses. x-schemaName: StoreCustomerAddressListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The customer's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The customer's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The customer's count. + description: The total number of items. addresses: type: array - description: The customer's addresses. + description: The list of addresses. items: $ref: ./StoreCustomerAddress.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressResponse.yaml index a665e19eb1bc4..515fa48b0900f 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerAddressResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The address's details. x-schemaName: StoreCustomerAddressResponse required: - address diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerResponse.yaml index c121ca1d700a4..f64fdf1657e95 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreCustomerResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreCustomerResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The customer's details. x-schemaName: StoreCustomerResponse required: - customer diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreOrder.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreOrder.yaml index 188ac9c5e53b3..58ff75075f90a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreOrder.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreOrder.yaml @@ -1,5 +1,5 @@ type: object -description: The cart's order. +description: The order's details. x-schemaName: StoreOrder required: - id @@ -51,28 +51,29 @@ properties: region_id: type: string title: region_id - description: The order's region id. + description: The ID of the associated region. customer_id: type: string title: customer_id - description: The order's customer id. + description: The ID of the customer that placed the order. sales_channel_id: type: string title: sales_channel_id - description: The order's sales channel id. + description: The ID of the sales channel the order was placed in. email: type: string title: email - description: The order's email. + description: The email of the customer that placed the order. format: email currency_code: type: string title: currency_code description: The order's currency code. + example: usd display_id: type: number title: display_id - description: The order's display id. + description: The order's display ID. shipping_address: $ref: ./BaseOrderAddress.yaml billing_address: @@ -123,74 +124,69 @@ properties: - shipped - partially_delivered - delivered - transactions: - type: array - description: The order's transactions. - items: - $ref: ./BaseOrderTransaction.yaml summary: $ref: ./BaseOrderSummary.yaml metadata: type: object - description: The order's metadata. + description: The order's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The order's created at. + description: The date the order was created. updated_at: type: string format: date-time title: updated_at - description: The order's updated at. + description: The date the order was updated. original_item_total: type: number title: original_item_total - description: The order's original item total. + description: The order items' total including taxes, excluding promotions. original_item_subtotal: type: number title: original_item_subtotal - description: The order's original item subtotal. + description: The order items' total excluding taxes, including promotions. original_item_tax_total: type: number title: original_item_tax_total - description: The order's original item tax total. + description: The total taxes applied on the order items, excluding promotions. item_total: type: number title: item_total - description: The order's item total. + description: The order items' total including taxes and promotions. item_subtotal: type: number title: item_subtotal - description: The order's item subtotal. + description: The order items' total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The order's item tax total. + description: The total taxes applied on the order's items, including promotions. original_total: type: number title: original_total - description: The order's original total. + description: The order's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The order's original subtotal. + description: The order's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The order's original tax total. + description: The total taxes of the order excluding promotions. total: type: number title: total - description: The order's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The order's subtotal. + description: The order's total excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The order's tax total. + description: The tax totals of the order including promotions. discount_total: type: number title: discount_total @@ -198,7 +194,7 @@ properties: discount_tax_total: type: number title: discount_tax_total - description: The order's discount tax total. + description: The total taxes applied on the discounted amount. gift_card_total: type: number title: gift_card_total @@ -206,28 +202,28 @@ properties: gift_card_tax_total: type: number title: gift_card_tax_total - description: The order's gift card tax total. + description: The total taxes applied on the gift card's amount. shipping_total: type: number title: shipping_total - description: The order's shipping total. + description: The order's shipping total including taxes and promotions. shipping_subtotal: type: number title: shipping_subtotal - description: The order's shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. shipping_tax_total: type: number title: shipping_tax_total - description: The order's shipping tax total. + description: The total taxes of the order's shipping including promotions. original_shipping_total: type: number title: original_shipping_total - description: The order's original shipping total. + description: The order's shipping total including taxes, excluding promotions. original_shipping_subtotal: type: number title: original_shipping_subtotal - description: The order's original shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. original_shipping_tax_total: type: number title: original_shipping_tax_total - description: The order's original shipping tax total. + description: The total taxes of the order's shipping excluding promotions. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreOrderResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreOrderResponse.yaml index c0ce37224487f..a02ddf96b8c1f 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreOrderResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreOrderResponse.yaml @@ -1,8 +1,10 @@ type: object -description: SUMMARY +description: The order's details. x-schemaName: StoreOrderResponse required: - order properties: order: - $ref: ./StoreOrder.yaml + type: string + title: order + description: The order's details. diff --git a/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollection.yaml b/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollection.yaml index 94658ceb27853..01509e2578056 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollection.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollection.yaml @@ -2,12 +2,12 @@ type: object description: The payment collection's details. x-schemaName: StorePaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -20,77 +20,41 @@ properties: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: ./IBigNumber.yaml + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: ./IBigNumber.yaml + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: ./IBigNumber.yaml + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: ./IBigNumber.yaml + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -102,14 +66,16 @@ properties: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: >- + The payment provider used to process the collection's payments and + sessions. items: - $ref: ./BasePaymentProvider.yaml + $ref: ./StorePaymentProvider.yaml payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: ./BasePaymentSession.yaml + $ref: ./StorePaymentSession.yaml payments: type: array description: The payment collection's payments. diff --git a/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollectionResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollectionResponse.yaml index 3f4dd244b05dd..dd6dbcee76b28 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollectionResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StorePaymentCollectionResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The payment collection's details. x-schemaName: StorePaymentCollectionResponse required: - payment_collection diff --git a/www/apps/api-reference/specs/store/components/schemas/StorePaymentSession.yaml b/www/apps/api-reference/specs/store/components/schemas/StorePaymentSession.yaml new file mode 100644 index 0000000000000..60126f183272a --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StorePaymentSession.yaml @@ -0,0 +1,61 @@ +type: object +description: The payment session's details. +x-schemaName: StorePaymentSession +properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: >- + The payment session's data, useful for the payment provider processing the + payment. + externalDocs: + url: >- + https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + $ref: ./StorePaymentCollection.yaml + payment: + $ref: ./BasePayment.yaml +required: + - id + - amount + - currency_code + - provider_id + - data + - status diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProduct.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProduct.yaml index 7062d98f47e5a..044867e21f250 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreProduct.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProduct.yaml @@ -2,15 +2,14 @@ type: object description: The product's details. x-schemaName: StoreProduct required: + - variants + - options + - images - length - title - status - - options - description - id - - created_at - - updated_at - - variants - handle - subtitle - is_giftcard @@ -24,9 +23,10 @@ required: - material - collection_id - type_id - - images - discountable - external_id + - created_at + - updated_at - deleted_at properties: categories: @@ -56,7 +56,7 @@ properties: type: array description: The product's options. items: - $ref: ./BaseProductOption.yaml + $ref: ./StoreProductOption.yaml description: type: string title: description @@ -67,22 +67,22 @@ properties: description: The product's ID. metadata: type: object - description: The product's metadata. + description: The product's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The product's created at. + description: The date the product was created. updated_at: type: string format: date-time title: updated_at - description: The product's updated at. + description: The date the product was updated. variants: type: array description: The product's variants. items: - $ref: ./BaseProductVariant.yaml + $ref: ./StoreProductVariant.yaml handle: type: string title: handle @@ -94,11 +94,11 @@ properties: is_giftcard: type: boolean title: is_giftcard - description: The product's is giftcard. + description: Whether the product is a gift card. thumbnail: type: string title: thumbnail - description: The product's thumbnail. + description: The product's thumbnail URL. width: type: number title: width @@ -118,45 +118,45 @@ properties: hs_code: type: string title: hs_code - description: The product's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The product's mid code. + description: The product's MID code. material: type: string title: material description: The product's material. collection: - $ref: ./BaseCollection.yaml + $ref: ./StoreCollection.yaml collection_id: type: string title: collection_id - description: The product's collection id. + description: The ID of the collection that the product belongs to. type_id: type: string title: type_id - description: The product's type id. + description: The ID of the product's type. tags: type: array description: The product's tags. items: - $ref: ./BaseProductTag.yaml + $ref: ./StoreProductTag.yaml images: type: array description: The product's images. items: - $ref: ./BaseProductImage.yaml + $ref: ./StoreProductImage.yaml discountable: type: boolean title: discountable - description: The product's discountable. + description: Whether the product can be discounted. external_id: type: string title: external_id - description: The product's external id. + description: The ID of the product in an external service or system. deleted_at: type: string format: date-time title: deleted_at - description: The product's deleted at. + description: The date the product was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductCategory.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductCategory.yaml index d164aa2e9c1a2..6e1c9ad428cf3 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreProductCategory.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductCategory.yaml @@ -1,13 +1,11 @@ type: object -description: The category's categories. +description: The category's details. x-schemaName: StoreProductCategory required: - id - name - description - handle - - is_active - - is_internal - rank - parent_category_id - parent_category @@ -37,14 +35,6 @@ properties: type: string title: handle description: The category's handle. - is_active: - type: boolean - title: is_active - description: The category's is active. - is_internal: - type: boolean - title: is_internal - description: The category's is internal. rank: type: number title: rank @@ -52,29 +42,29 @@ properties: parent_category_id: type: string title: parent_category_id - description: The category's parent category id. + description: The ID of the category's parent. parent_category: - $ref: ./BaseProductCategory.yaml + $ref: ./StoreProductCategory.yaml category_children: type: array - description: The category's category children. + description: The category's children. items: - $ref: ./BaseProductCategory.yaml + $ref: ./StoreProductCategory.yaml metadata: type: object - description: The category's metadata. + description: The category's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The category's created at. + description: The date the category was created. updated_at: type: string format: date-time title: updated_at - description: The category's updated at. + description: The date the category was updated. deleted_at: type: string format: date-time title: deleted_at - description: The category's deleted at. + description: The date the category was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryListResponse.yaml index 0b9eedfe4ff7e..124035ab925df 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The paginated list of product categories. x-schemaName: StoreProductCategoryListResponse required: - limit @@ -10,17 +10,17 @@ properties: limit: type: number title: limit - description: The product category's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product category's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product category's count. + description: The total number of items. product_categories: type: array - description: The product category's product categories. + description: The list of product categories. items: $ref: ./StoreProductCategory.yaml diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryResponse.yaml index 05dc39f8246b9..7530c17d570f7 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductCategoryResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product category's details. x-schemaName: StoreProductCategoryResponse required: - product_category diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductImage.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductImage.yaml new file mode 100644 index 0000000000000..1ad523677df25 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductImage.yaml @@ -0,0 +1,33 @@ +type: object +description: The image's images. +x-schemaName: StoreProductImage +required: + - id + - url +properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's url. + created_at: + type: string + format: date-time + title: created_at + description: The image's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The image's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The image's deleted at. + metadata: + type: object + description: The image's metadata. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductOption.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductOption.yaml new file mode 100644 index 0000000000000..2f16c55d4d7a2 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductOption.yaml @@ -0,0 +1,44 @@ +type: object +description: The product option's details. +x-schemaName: StoreProductOption +properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + $ref: ./StoreProduct.yaml + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: ./StoreProductOptionValue.yaml + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. +required: + - title + - id diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductOptionValue.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductOptionValue.yaml new file mode 100644 index 0000000000000..1500b11999e74 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductOptionValue.yaml @@ -0,0 +1,39 @@ +type: object +description: The product option value's details. +x-schemaName: StoreProductOptionValue +required: + - value + - id +properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + $ref: ./StoreProductOption.yaml + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductResponse.yaml index ac22f2a56f57c..aab52a7a1d4cf 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreProductResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The product's details. x-schemaName: StoreProductResponse required: - product diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductTag.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductTag.yaml new file mode 100644 index 0000000000000..1e31fdb2fbde8 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductTag.yaml @@ -0,0 +1,35 @@ +type: object +description: The tag's details. +x-schemaName: StoreProductTag +properties: + id: + type: string + title: id + description: The tag's ID. + value: + type: string + title: value + description: The tag's value. + created_at: + type: string + format: date-time + title: created_at + description: The date the tag was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tag was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the tag was deleted. + metadata: + type: object + description: The tag's metadata, can hold custom key-value pairs. +required: + - id + - value + - created_at + - updated_at diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductVariant.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductVariant.yaml new file mode 100644 index 0000000000000..03f57633c50ff --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StoreProductVariant.yaml @@ -0,0 +1,128 @@ +type: object +description: The variant's variants. +x-schemaName: StoreProductVariant +properties: + options: + type: array + description: The variant's options. + items: + $ref: ./StoreProductOptionValue.yaml + product: + $ref: ./StoreProduct.yaml + length: + type: number + title: length + description: The variant's length. + title: + type: string + title: title + description: The variant's title. + metadata: + type: object + description: The variant's metadata. + id: + type: string + title: id + description: The variant's ID. + width: + type: number + title: width + description: The variant's width. + weight: + type: number + title: weight + description: The variant's weight. + height: + type: number + title: height + description: The variant's height. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + hs_code: + type: string + title: hs_code + description: The variant's hs code. + mid_code: + type: string + title: mid_code + description: The variant's mid code. + material: + type: string + title: material + description: The variant's material. + created_at: + type: string + format: date-time + title: created_at + description: The variant's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The variant's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The variant's deleted at. + product_id: + type: string + title: product_id + description: The variant's product id. + sku: + type: string + title: sku + description: The variant's sku. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's ean. + upc: + type: string + title: upc + description: The variant's upc. + allow_backorder: + type: boolean + title: allow_backorder + description: The variant's allow backorder. + manage_inventory: + type: boolean + title: manage_inventory + description: The variant's manage inventory. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. + variant_rank: + type: number + title: variant_rank + description: The variant's variant rank. + calculated_price: + $ref: ./BaseCalculatedPriceSet.yaml +required: + - options + - length + - title + - id + - width + - weight + - height + - origin_country + - hs_code + - mid_code + - material + - created_at + - updated_at + - deleted_at + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreProductVariantParams.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreProductVariantParams.yaml deleted file mode 100644 index 295b3c1fdd4ba..0000000000000 --- a/www/apps/api-reference/specs/store/components/schemas/StoreProductVariantParams.yaml +++ /dev/null @@ -1,76 +0,0 @@ -type: object -description: The product's variants. -x-schemaName: StoreProductVariantParams -properties: - q: - type: string - title: q - description: The variant's q. - id: - oneOf: - - type: string - title: id - description: The variant's ID. - - type: array - description: The variant's ID. - items: - type: string - title: id - description: The id's ID. - sku: - oneOf: - - type: string - title: sku - description: The variant's sku. - - type: array - description: The variant's sku. - items: - type: string - title: sku - description: The sku's details. - product_id: - oneOf: - - type: string - title: product_id - description: The variant's product id. - - type: array - description: The variant's product id. - items: - type: string - title: product_id - description: The product id's details. - options: - type: object - description: The variant's options. - limit: - type: number - title: limit - description: The variant's limit. - offset: - type: number - title: offset - description: The variant's offset. - order: - type: string - title: order - description: The variant's order. - fields: - type: string - title: fields - description: The variant's fields. - $and: - type: array - description: >- - Join query parameters with an AND condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: >- - Join query parameters with an OR condition. Each object's content is the - same type as the expected query parameters. - items: - type: object - title: $or diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreRegion.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreRegion.yaml index d07d5098a6885..8a7250fc7af8d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreRegion.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreRegion.yaml @@ -1,5 +1,5 @@ type: object -description: The region's details. +description: The parent's region. x-schemaName: StoreRegion required: - id diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreReturn.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreReturn.yaml index 4f35c16688439..afdc2d750a994 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreReturn.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreReturn.yaml @@ -2,11 +2,11 @@ type: object description: The return's details. x-schemaName: StoreReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -18,54 +18,68 @@ properties: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. status: - type: string - title: status + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. description: The return's status. exchange_id: type: string title: exchange_id - description: The return's exchange id. + description: The ID of the associated exchange. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location the items are returned to. claim_id: type: string title: claim_id - description: The return's claim id. + description: The ID of the associated claim. order_version: type: number title: order_version - description: The return's order version. + description: The version of the order when the return is applied. display_id: type: number title: display_id - description: The return's display id. + description: The return's display ID. no_notification: type: boolean title: no_notification - description: The return's no notification. + description: Whether the customer should receive updates about changes in the return. refund_amount: type: number title: refund_amount - description: The return's refund amount. + description: The return's refunded amount. items: type: array description: The return's items. items: - $ref: ./BaseReturnItem.yaml + $ref: ./StoreReturnItem.yaml received_at: type: string title: received_at - description: The return's received at. + description: The date the return was received. created_at: type: string format: date-time title: created_at - description: The return's created at. + description: The date the return was created. canceled_at: type: string title: canceled_at - description: The return's canceled at. + description: The date the return was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreReturnItem.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreReturnItem.yaml new file mode 100644 index 0000000000000..ed855a643f027 --- /dev/null +++ b/www/apps/api-reference/specs/store/components/schemas/StoreReturnItem.yaml @@ -0,0 +1,46 @@ +type: object +description: The item's items. +x-schemaName: StoreReturnItem +properties: + id: + type: string + title: id + description: The item's ID. + quantity: + type: number + title: quantity + description: The item's quantity. + received_quantity: + type: number + title: received_quantity + description: The item's received quantity. + damaged_quantity: + type: number + title: damaged_quantity + description: The item's damaged quantity. + reason_id: + type: string + title: reason_id + description: The item's reason id. + note: + type: string + title: note + description: The item's note. + item_id: + type: string + title: item_id + description: The item's item id. + return_id: + type: string + title: return_id + description: The item's return id. + metadata: + type: object + description: The item's metadata. +required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreReturnReason.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreReturnReason.yaml index 0b2be3c0f31ee..b08051fb32484 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreReturnReason.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreReturnReason.yaml @@ -26,14 +26,14 @@ properties: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreReturnReasonResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreReturnReasonResponse.yaml index 19edb6a5210c1..b3071e44278bf 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreReturnReasonResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreReturnReasonResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return reason's details. x-schemaName: StoreReturnReasonResponse required: - return_reason diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreReturnResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreReturnResponse.yaml index bac852445971e..6dc083e1d5a0b 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreReturnResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreReturnResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The return's details. x-schemaName: StoreReturnResponse required: - return diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreShippingOption.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreShippingOption.yaml index 13a1160363e26..1c4c7d291903d 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreShippingOption.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreShippingOption.yaml @@ -1,66 +1,48 @@ type: object -description: The shipping option's shipping options. +description: The shipping option's details. x-schemaName: StoreShippingOption required: - id - - name - - price_type - - service_zone_id - - provider_id - - provider - - shipping_option_type_id - - type - - shipping_profile_id - - amount - - is_tax_inclusive - - data - - metadata + - label + - description + - code + - shipping_option_id + - created_at + - updated_at + - deleted_at properties: id: type: string title: id description: The shipping option's ID. - name: + label: type: string - title: name - description: The shipping option's name. - price_type: + title: label + description: The type's label. + description: type: string - description: The shipping option's price type. - enum: - - flat - - calculated - service_zone_id: + title: description + description: The type's description. + code: type: string - title: service_zone_id - description: The shipping option's service zone id. - provider_id: + title: code + description: The type's code. + shipping_option_id: type: string - title: provider_id - description: The shipping option's provider id. - provider: - $ref: ./BaseFulfillmentProvider.yaml - shipping_option_type_id: + title: shipping_option_id + description: The type's shipping option id. + created_at: type: string - title: shipping_option_type_id - description: The shipping option's shipping option type id. - type: - type: object - shipping_profile_id: + format: date-time + title: created_at + description: The type's created at. + updated_at: type: string - title: shipping_profile_id - description: The shipping option's shipping profile id. - amount: - type: number - title: amount - description: The shipping option's amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping option's is tax inclusive. - data: - type: object - description: The shipping option's data. - metadata: - type: object - description: The shipping option's metadata. + format: date-time + title: updated_at + description: The type's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The type's deleted at. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreShippingOptionListResponse.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreShippingOptionListResponse.yaml index 8001c7a8c53d0..695f2175b173a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreShippingOptionListResponse.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreShippingOptionListResponse.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The shipping option's details. x-schemaName: StoreShippingOptionListResponse required: - shipping_options diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCartLineItem.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCartLineItem.yaml index a6468aab56d5f..844c2958cea64 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCartLineItem.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCartLineItem.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in the line item. x-schemaName: StoreUpdateCartLineItem required: - quantity @@ -7,7 +7,7 @@ properties: quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. + description: The item's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCustomer.yaml b/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCustomer.yaml index f3f14b1f5e81a..0eaa5dda8bc1a 100644 --- a/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCustomer.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/StoreUpdateCustomer.yaml @@ -1,5 +1,5 @@ type: object -description: SUMMARY +description: The details to update in the customer. x-schemaName: StoreUpdateCustomer properties: company_name: diff --git a/www/apps/api-reference/specs/store/components/schemas/UpdateAddress.yaml b/www/apps/api-reference/specs/store/components/schemas/UpdateAddress.yaml index 0338cc6658643..22025cb22d6df 100644 --- a/www/apps/api-reference/specs/store/components/schemas/UpdateAddress.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/UpdateAddress.yaml @@ -1,5 +1,5 @@ type: object -description: The cart's shipping address. +description: The details to update in the address. x-schemaName: UpdateAddress required: - id @@ -7,51 +7,52 @@ properties: id: type: string title: id - description: The shipping address's ID. + description: The ID of an existing address to update. customer_id: type: string title: customer_id - description: The shipping address's customer id. + description: The ID of the customer that this address belongs to. company: type: string title: company - description: The shipping address's company. + description: The address's company. first_name: type: string title: first_name - description: The shipping address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The shipping address's last name. + description: The address's last name. address_1: type: string title: address_1 - description: The shipping address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The shipping address's address 2. + description: The address's second line. city: type: string title: city - description: The shipping address's city. + description: The address's city. country_code: type: string title: country_code - description: The shipping address's country code. + description: The address's country code. + example: usd province: type: string title: province - description: The shipping address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The shipping address's postal code. + description: The address's postal code. phone: type: string title: phone - description: The shipping address's phone. + description: The address's phone. metadata: type: object - description: The shipping address's metadata. + description: The address's metadata, can hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/UpdateCartData.yaml b/www/apps/api-reference/specs/store/components/schemas/UpdateCartData.yaml index 0b29d94268647..32376f2c2f892 100644 --- a/www/apps/api-reference/specs/store/components/schemas/UpdateCartData.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/UpdateCartData.yaml @@ -1,36 +1,41 @@ type: object -description: SUMMARY +description: The details to update in a cart. x-schemaName: UpdateCartData properties: region_id: type: string title: region_id - description: The cart's region id. + description: >- + The ID of the associated region. This can affect the prices and currency + code of the cart. customer_id: type: string title: customer_id - description: The cart's customer id. + description: The ID of the customer that the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: >- + The ID of the associated sales channel. Only products available in this + channel can be added to the cart. email: type: string title: email - description: The cart's email. + description: The email of the customer that the cart belongs to. format: email currency_code: type: string title: currency_code description: The cart's currency code. + example: usd shipping_address_id: type: string title: shipping_address_id - description: The cart's shipping address id. + description: The ID of the cart's shipping address. billing_address_id: type: string title: billing_address_id - description: The cart's billing address id. + description: The ID of the cart's billing address. billing_address: oneOf: - $ref: ./CreateAddress.yaml @@ -41,4 +46,4 @@ properties: - $ref: ./UpdateAddress.yaml metadata: type: object - description: The cart's metadata. + description: The cart's metadata, ca hold custom key-value pairs. diff --git a/www/apps/api-reference/specs/store/components/schemas/WorkflowExecutionContext.yaml b/www/apps/api-reference/specs/store/components/schemas/WorkflowExecutionContext.yaml index 2d20174121a20..2f04930503487 100644 --- a/www/apps/api-reference/specs/store/components/schemas/WorkflowExecutionContext.yaml +++ b/www/apps/api-reference/specs/store/components/schemas/WorkflowExecutionContext.yaml @@ -8,6 +8,30 @@ properties: data: type: object description: The context's data. + properties: + invoke: + type: object + description: The step's invokation details. + required: + - output + additionalProperties: + type: object + properties: + output: + type: object + description: The invokation's details. + required: + - output + - compensateInput + properties: + output: + description: the step's output + compensateInput: + description: the compensation function's input. + payload: + description: the payload of the transaction. + required: + - invoke compensate: type: object description: The context's compensate. @@ -16,4 +40,20 @@ properties: description: The context's errors. items: type: object - description: The error's errors. + description: The error's details. + properties: + error: + type: object + description: The error's details. + action: + type: string + title: action + description: The error's action. + handlerType: + type: string + title: handlerType + description: The error's handler type. + required: + - error + - action + - handlerType diff --git a/www/apps/api-reference/specs/store/openapi.full.yaml b/www/apps/api-reference/specs/store/openapi.full.yaml index 14d4c8a9f4398..e6450094acdf4 100644 --- a/www/apps/api-reference/specs/store/openapi.full.yaml +++ b/www/apps/api-reference/specs/store/openapi.full.yaml @@ -1229,11 +1229,6 @@ paths: type: string title: fields description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/StoreCalculateCartTaxes' x-codeSamples: - lang: Shell label: cURL @@ -2416,6 +2411,9 @@ paths: '500': $ref: '#/components/responses/500_error' x-workflow: createCustomerAccountWorkflow + security: + - cookie_auth: [] + - jwt_token: [] /store/customers/me: get: operationId: GetCustomersMe @@ -2597,31 +2595,52 @@ paths: - name: city in: query description: Filter by the address's city. - required: true + required: false schema: - type: string - title: city - description: Filter by the address's city. + oneOf: + - type: string + title: city + description: The customer's city. + - type: array + description: The customer's city. + items: + type: string + title: city + description: The city's details. - name: postal_code in: query description: Filter by the address's postal code. - required: true + required: false schema: - type: string - title: postal_code - description: Filter by the address's postal code. + oneOf: + - type: string + title: postal_code + description: The customer's postal code. + - type: array + description: The customer's postal code. + items: + type: string + title: postal_code + description: The postal code's details. - name: country_code in: query description: Filter by the address's country code. - required: true + required: false schema: - type: string - title: country_code - description: Filter by the address's country code. + oneOf: + - type: string + title: country_code + description: The customer's country code. + - type: array + description: The customer's country code. + items: + type: string + title: country_code + description: The country code's details. - name: q in: query description: Search term to filter the address's searchable properties. - required: true + required: false schema: type: string title: q @@ -5406,14 +5425,6 @@ paths: externalDocs: url: https://docs.medusajs.com/v2/resources/storefront-development/products/price/examples/tax-price description: 'Storefront guide: How to show product variants'' prices with taxes.' - - name: country_code - in: query - description: The country code the products are being viewed from. This is required if you're retrieving product variant prices with taxes. - required: false - schema: - type: string - title: country_code - description: The country code the products are being viewed from. This is required if you're retrieving product variant prices with taxes. - name: province in: query description: The province the products are being viewed from. This is useful to narrow down the tax context when calculating product variant prices with taxes. @@ -5422,14 +5433,6 @@ paths: type: string title: province description: The province the products are being viewed from. This is useful to narrow down the tax context when calculating product variant prices with taxes. - - name: cart_id - in: query - description: The ID of the customer's cart. If set, the cart's region and shipping address's country code and province are used instead of the `region_id`, `country_code`, and `province` properties. - required: false - schema: - type: string - title: cart_id - description: The ID of the customer's cart. If set, the cart's region and shipping address's country code and province are used instead of the `region_id`, `country_code`, and `province` properties. - name: sales_channel_id in: query required: false @@ -5458,6 +5461,91 @@ paths: type: string title: category_id description: A product category's ID. + - name: currency_code + in: query + description: The product's currency code. + required: false + schema: + type: string + title: currency_code + description: The product's currency code. + - name: variants + in: query + description: The product's variants. + required: false + schema: + type: object + description: The product's variants. + x-schemaName: StoreProductVariantParams + properties: + q: + type: string + title: q + description: The variant's q. + id: + oneOf: + - type: string + title: id + description: The variant's ID. + - type: array + description: The variant's ID. + items: + type: string + title: id + description: The id's ID. + sku: + oneOf: + - type: string + title: sku + description: The variant's sku. + - type: array + description: The variant's sku. + items: + type: string + title: sku + description: The sku's details. + product_id: + oneOf: + - type: string + title: product_id + description: The variant's product id. + - type: array + description: The variant's product id. + items: + type: string + title: product_id + description: The product id's details. + options: + type: object + description: The variant's options. + limit: + type: number + title: limit + description: Limit the number of items returned in the list. + offset: + type: number + title: offset + description: The number of items to skip when retrieving a list. + order: + type: string + title: order + description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + fields: + type: string + title: fields + description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. + $and: + type: array + description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + items: + type: object + title: $or x-codeSamples: - lang: Shell label: cURL @@ -6234,17 +6322,120 @@ components: properties: api_key: $ref: '#/components/schemas/AdminApiKey' - AdminArchiveOrder: + AdminApplicationMethod: type: object - description: SUMMARY - x-schemaName: AdminArchiveOrder + description: The promotion's application method. + x-schemaName: AdminApplicationMethod required: - - order_id + - id properties: - order_id: + promotion: + type: object + description: The application method's promotion. + x-schemaName: AdminPromotion + required: + - id + properties: + application_method: + type: object + description: The promotion's application method. + x-schemaName: AdminApplicationMethod + rules: + type: array + description: The promotion's rules. + items: + type: object + description: The rule's rules. + x-schemaName: AdminPromotionRule + id: + type: string + title: id + description: The promotion's ID. + code: + type: string + title: code + description: The promotion's code. + type: + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. + is_automatic: + type: boolean + title: is_automatic + description: The promotion's is automatic. + campaign_id: + type: string + title: campaign_id + description: The promotion's campaign id. + campaign: + type: object + description: The promotion's campaign. + x-schemaName: AdminCampaign + target_rules: + type: array + description: The application method's target rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' + buy_rules: + type: array + description: The application method's buy rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' + id: type: string - title: order_id - description: The order's order id. + title: id + description: The application method's ID. + type: + oneOf: + - type: string + title: type + description: The application method's type. + - type: string + title: type + description: The application method's type. + target_type: + oneOf: + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + - type: string + title: target_type + description: The application method's target type. + allocation: + oneOf: + - type: string + title: allocation + description: The application method's allocation. + - type: string + title: allocation + description: The application method's allocation. + value: + type: number + title: value + description: The application method's value. + currency_code: + type: string + title: currency_code + description: The application method's currency code. + max_quantity: + type: number + title: max_quantity + description: The application method's max quantity. + buy_rules_min_quantity: + type: number + title: buy_rules_min_quantity + description: The application method's buy rules min quantity. + apply_to_quantity: + type: number + title: apply_to_quantity + description: The application method's apply to quantity. AdminBatchProductRequest: type: object description: The products to create, update, or delete. @@ -6465,44 +6656,18 @@ components: description: The claim's details. x-schemaName: AdminClaim required: - - order_id - - claim_items - - additional_items - - currency_code + - order + - return - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - type + - order_id + - display_id + - order_version - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - additional_items + - claim_items properties: id: type: string @@ -6523,7 +6688,7 @@ components: items: $ref: '#/components/schemas/BaseClaimItem' return: - $ref: '#/components/schemas/Return' + $ref: '#/components/schemas/AdminReturn' return_id: type: string title: return_id @@ -6536,86 +6701,23 @@ components: type: number title: refund_amount description: The amount to be refunded. - currency_code: - type: string - title: currency_code - description: The claim's currency code. - region_id: - type: string - title: region_id - description: The ID of the region associated with the claim. - customer_id: - type: string - title: customer_id - description: The ID of the customer associated with the claim's order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the claim's order is created in. - email: - type: string - title: email - description: The email associated with the claim's order. - format: email display_id: type: number title: display_id description: The claim's display ID. - shipping_address: - $ref: '#/components/schemas/BaseOrderAddress' - billing_address: - $ref: '#/components/schemas/BaseOrderAddress' shipping_methods: type: array description: The claim's shipping methods. items: - $ref: '#/components/schemas/BaseOrderShippingMethod' - payment_collections: + $ref: '#/components/schemas/AdminOrderShippingMethod' + transactions: type: array - description: The claim's payment collections. - items: - $ref: '#/components/schemas/BasePaymentCollection' - payment_status: - type: string - description: The claim's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The claim's fulfillments. - items: - $ref: '#/components/schemas/BaseOrderFulfillment' - fulfillment_status: - type: string - description: The claim's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered - transactions: - type: array - description: The claim's transactions. - externalDocs: - url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions - description: Learn more about transactions of orders and associated models. + description: The claim's transactions. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + description: Learn more about transactions of orders and associated models. items: $ref: '#/components/schemas/BaseOrderTransaction' - summary: - $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object description: The claim's metadata, used to store custom key-value pairs. @@ -6629,94 +6731,34 @@ components: format: date-time title: updated_at description: The claim's update date. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the associated order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the associated order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The tax total of the original items in the associated order. - item_total: - type: number - title: item_total - description: The total of the claim's items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the claim's items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the claim's items. - original_total: - type: number - title: original_total - description: The associated order's original total. - original_subtotal: - type: number - title: original_subtotal - description: The associated order's original subtotal. - original_tax_total: - type: number - title: original_tax_total - description: The associated order's original tax total. - total: - type: number - title: total - description: The associated order's total. - subtotal: - type: number - title: subtotal - description: The claim's subtotal. - tax_total: - type: number - title: tax_total - description: The claim's tax total. - discount_total: - type: number - title: discount_total - description: The claim's discount total. - discount_tax_total: - type: number - title: discount_tax_total - description: The claim's discount tax total. - gift_card_total: - type: number - title: gift_card_total - description: The claim's gift card total. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The claim's gift card tax total. - shipping_total: - type: number - title: shipping_total - description: The claim's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The claim's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The claim's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The associated order's original shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The associated order's original shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The associated order's original shipping tax total. + order: + type: string + title: order + description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + type: + type: string + description: The claim's type. + enum: + - replace + - refund + order_version: + type: string + title: order_version + description: The claim's order version. + created_by: + type: string + title: created_by + description: The claim's created by. + canceled_at: + type: string + title: canceled_at + description: The claim's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The claim's deleted at. AdminClaimDeleteResponse: type: object description: The details of the deleted claim. @@ -6775,7 +6817,9 @@ components: - claim properties: order: - $ref: '#/components/schemas/Order' + type: string + title: order + description: The order change's order. claim: $ref: '#/components/schemas/AdminClaim' AdminClaimPreviewResponse: @@ -6787,7 +6831,7 @@ components: - claim properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' claim: $ref: '#/components/schemas/AdminClaim' AdminClaimRequestResponse: @@ -6802,7 +6846,7 @@ components: return: $ref: '#/components/schemas/AdminReturn' order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' claim: $ref: '#/components/schemas/AdminClaim' AdminClaimResponse: @@ -6823,7 +6867,7 @@ components: - return properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' return: $ref: '#/components/schemas/AdminReturn' AdminCollection: @@ -6950,68 +6994,6 @@ components: enum: - publishable - secret - AdminCreateApplicationMethod: - type: object - description: The application method's details. - x-schemaName: AdminCreateApplicationMethod - required: - - value - - type - - target_type - properties: - description: - type: string - title: description - description: The application method's description. - value: - type: number - title: value - description: The discounted amount applied by the associated promotion based on the `type`. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: The max quantity allowed in the cart for the associated promotion to be applied. - type: - type: string - description: The type of the application method indicating how the associated promotion is applied. - enum: - - fixed - - percentage - target_type: - type: string - description: The target type of the application method indicating whether the associated promotion is applied to the cart's items, shipping methods, or the whole order. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: The allocation value that indicates whether the associated promotion is applied on each item in a cart or split between the items in the cart. - enum: - - each - - across - target_rules: - type: array - description: The application method's target rules. - items: - $ref: '#/components/schemas/AdminCreatePromotionRule' - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: '#/components/schemas/AdminCreatePromotionRule' - apply_to_quantity: - type: number - title: apply_to_quantity - description: The quantity that results from matching the `buyget` promotion's condition. For example, if the promotion is a "Buy 2 shirts get 1 free", the value f this attribute is `1`. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: The minimum quantity required for a `buyget` promotion to be applied. For example, if the promotion is a "Buy 2 shirts get 1 free", the value of this attribute is `2`. AdminCreateCollection: type: object description: the product collection's details. @@ -7049,15 +7031,14 @@ components: description: The filfillment's details. x-schemaName: AdminCreateFulfillment required: + - data + - order_id + - metadata + - items - location_id - provider_id - delivery_address - - items - labels - - order - - order_id - - data - - metadata properties: location_id: type: string @@ -7122,8 +7103,8 @@ components: description: An item to fulfill. required: - title - - sku - quantity + - sku - barcode properties: title: @@ -7297,17 +7278,27 @@ components: description: The date and time the price list ends at. format: date-time status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. @@ -7321,8 +7312,8 @@ components: description: A price's details. required: - currency_code - - amount - variant_id + - amount properties: currency_code: type: string @@ -7417,13 +7408,20 @@ components: title: handle description: The product's handle. status: - type: string + oneOf: + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. + - type: string + title: status + description: The create's status. description: The product's status. - enum: - - draft - - proposed - - published - - rejected type_id: type: string title: type_id @@ -7587,6 +7585,20 @@ components: metadata: type: object description: The product tag's metadata, used to store custom key-value pairs. + AdminCreateProductType: + type: object + description: The product's details. + x-schemaName: AdminCreateProductType + required: + - value + properties: + metadata: + type: object + description: The product's metadata, used to store custom key-value pairs. + value: + type: string + title: value + description: The product type's value. AdminCreateProductVariant: type: object description: The product variant's details. @@ -7672,13 +7684,33 @@ components: description: The variant's options, where the key is an option's name, and the value is the option's value. example: Color: Black - AdminCreateProductVariantPrice: + inventory_items: + type: array + description: The variant's inventory items. + items: + $ref: '#/components/schemas/AdminCreateProductVariantInventoryKit' + AdminCreateProductVariantInventoryKit: type: object - description: The details of a variant's price. - x-schemaName: AdminCreateProductVariantPrice + description: The inventory item's inventory items. + x-schemaName: AdminCreateProductVariantInventoryKit required: - - currency_code - - amount + - inventory_item_id + properties: + inventory_item_id: + type: string + title: inventory_item_id + description: The inventory item's inventory item id. + required_quantity: + type: number + title: required_quantity + description: The inventory item's required quantity. + AdminCreateProductVariantPrice: + type: object + description: The details of a variant's price. + x-schemaName: AdminCreateProductVariantPrice + required: + - currency_code + - amount properties: currency_code: type: string @@ -7701,6 +7733,13 @@ components: description: The price's rules. example: region_id: reg_123 + properties: + region_id: + type: string + title: region_id + description: The rule's region id. + required: + - region_id AdminCreatePromotionRule: type: object description: The promotion rule's details. @@ -7834,6 +7873,33 @@ components: metadata: type: object description: The reservation's metadata, used to store custom key-value pairs. + AdminCreateReturnReason: + type: object + description: SUMMARY + x-schemaName: AdminCreateReturnReason + required: + - value + - label + properties: + value: + type: string + title: value + description: The return reason's value. + label: + type: string + title: label + description: The return reason's label. + description: + type: string + title: description + description: The return reason's description. + parent_return_reason_id: + type: string + title: parent_return_reason_id + description: The return reason's parent return reason id. + metadata: + type: object + description: The return reason's metadata. AdminCreateSalesChannel: type: object description: The sales channel's details. @@ -7888,127 +7954,25 @@ components: description: The label's URL. AdminCreateShippingOption: type: object - description: The shipping option's details. + description: The shipping option's type. x-schemaName: AdminCreateShippingOption required: - - name - - service_zone_id - - shipping_profile_id - - price_type - - provider_id - - type - - prices + - label + - description + - code properties: - name: - type: string - title: name - description: The shipping option's name. - service_zone_id: - type: string - title: service_zone_id - description: The ID of the service zone this shipping option belongs to. - shipping_profile_id: - type: string - title: shipping_profile_id - description: The ID of the shipping profile this shipping option belongs to. - data: - type: object - description: Any data necessary for fulfillment providers to handle shipping methods and fulfillments of this shipping option. - externalDocs: - url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property - description: Learn more about the data property. - price_type: - type: string - description: | - The shipping option price's type. If `flat`, it means the option has a fixed price set in the `prices` property. `calculated` means that the shipping option's price is calculated during checkout. - enum: - - flat - - calculated - provider_id: + label: type: string - title: provider_id - description: The ID of the fulfillment provider used to handle this shipping option and its associated methods and fulfillments. - type: - type: object - prices: - type: array - description: The shipping option's prices. If `price_type` is `calculated`, pass an empty array for this property. - items: - oneOf: - - type: object - description: The price for a currency code. - x-schemaName: AdminCreateShippingOptionPriceWithCurrency - required: - - currency_code - - amount - properties: - currency_code: - type: string - title: currency_code - description: The price's currency code. - amount: - type: number - title: amount - description: The price's amount. - - type: object - description: The price in a region. - x-schemaName: AdminCreateShippingOptionPriceWithRegion - required: - - region_id - - amount - properties: - region_id: - type: string - title: region_id - description: The ID of the region this price is used in. - amount: - type: number - title: amount - description: The price's amount. - rules: - type: array - description: The shipping option's rules. - items: - $ref: '#/components/schemas/AdminCreateShippingOptionRule' - AdminCreateShippingOptionRule: - type: object - description: The details of the shipping option rule. - x-schemaName: AdminCreateShippingOptionRule - required: - - operator - - attribute - - value - properties: - operator: + title: label + description: The type's label. + description: type: string - description: The operator used to check whether a rule applies. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte - - nin - attribute: + title: description + description: The type's description. + code: type: string - title: attribute - description: The name of a property or table that the rule applies to. - example: customer_group - value: - oneOf: - - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 - - type: array - description: Values of the attribute that enable this rule. - items: - type: string - title: value - description: A value of the attribute that enables this rule. - example: cusgroup_123 + title: code + description: The type's code. AdminCreateShippingProfile: type: object description: The shipping profile's details. @@ -8166,8 +8130,8 @@ components: description: The details of the variant-inventory item association. x-schemaName: AdminCreateVariantInventoryItem required: - - required_quantity - inventory_item_id + - required_quantity properties: required_quantity: type: number @@ -8198,11 +8162,16 @@ components: compensate_input: description: Sets the compensation function's input. It accepts any response. action: - type: string + oneOf: + - type: string + description: The workflows execution's action. + enum: + - INVOKE + - type: string + description: The workflows execution's action. + enum: + - COMPENSATE description: Whether to invoke or compensate the step. - enum: - - invoke - - compensate AdminCreateWorkflowsRun: type: object description: The details of the workflow to execute. @@ -8225,7 +8194,6 @@ components: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at @@ -9145,44 +9113,14 @@ components: description: The exchange's details. x-schemaName: AdminExchange required: - - order_id - - return_items - - additional_items - - currency_code - id - - region_id - - customer_id - - sales_channel_id - - email - - shipping_methods - - payment_status - - fulfillment_status - - summary - - metadata + - order_id - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total + - canceled_at + - deleted_at + - additional_items + - return_items properties: order_id: type: string @@ -9207,88 +9145,24 @@ components: title: difference_due description: The amount to be exchanged or refunded. If the amount is negative, it must be refunded. If positive, additional payment is required from the customer. return: - description: the return associated with the exchange. $ref: '#/components/schemas/AdminReturn' return_id: type: string title: return_id description: The ID of the associated exchange. - currency_code: - type: string - title: currency_code - description: The exchange's currency code. id: type: string title: id description: The exchange's ID. - region_id: - type: string - title: region_id - description: The ID of the associated order's region. - customer_id: - type: string - title: customer_id - description: The ID of the customer that placed the order. - sales_channel_id: - type: string - title: sales_channel_id - description: The ID of the sales channel the associated order belongs to. - email: - type: string - title: email - description: The email used when placing the order. - format: email display_id: - type: number + type: string title: display_id description: The exchange's display ID. - shipping_address: - description: The shipping address to send new items to. - $ref: '#/components/schemas/BaseOrderAddress' - billing_address: - description: The customer's billing address. - $ref: '#/components/schemas/BaseOrderAddress' shipping_methods: type: array description: The shipping methods used to send the new (outbound) items. items: $ref: '#/components/schemas/BaseOrderShippingMethod' - payment_collections: - type: array - description: The exchange's payment collections. - items: - $ref: '#/components/schemas/BasePaymentCollection' - payment_status: - type: string - description: The exchange's payment status. - enum: - - canceled - - not_paid - - awaiting - - authorized - - partially_authorized - - captured - - partially_captured - - partially_refunded - - refunded - - requires_action - fulfillments: - type: array - description: The exchange's fulfillments of new (outbound) items. - items: - $ref: '#/components/schemas/BaseOrderFulfillment' - fulfillment_status: - type: string - description: The exchange's fulfillment status. - enum: - - canceled - - not_fulfilled - - partially_fulfilled - - fulfilled - - partially_shipped - - shipped - - partially_delivered - - delivered transactions: type: array description: The exchange's transactions. @@ -9296,9 +9170,6 @@ components: url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions items: $ref: '#/components/schemas/BaseOrderTransaction' - summary: - description: The totals summary of the exchange. - $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object description: The exchange's metadata, can hold custom key-value pairs. @@ -9312,94 +9183,32 @@ components: format: date-time title: updated_at description: The date that the exchange was updated. - original_item_total: - type: number - title: original_item_total - description: The total of the original items in the order. - original_item_subtotal: - type: number - title: original_item_subtotal - description: The subtotal of the original items in the order. - original_item_tax_total: - type: number - title: original_item_tax_total - description: The total tax of the original items in the order. - item_total: - type: number - title: item_total - description: The total of the exchange's new items. - item_subtotal: - type: number - title: item_subtotal - description: The subtotal of the exchange's new items. - item_tax_total: - type: number - title: item_tax_total - description: The tax total of the exchange's new items. - original_total: - type: number - title: original_total - description: The total of the order. - original_subtotal: - type: number - title: original_subtotal - description: The subtotal of the order. - original_tax_total: - type: number - title: original_tax_total - description: The tax total of the order. - total: - type: number - title: total - description: The total of the exchange. - subtotal: - type: number - title: subtotal - description: The subtotal of the exchange. - tax_total: - type: number - title: tax_total - description: The tax total of the exchange. - discount_total: - type: number - title: discount_total - description: The discount total of the exchange. - discount_tax_total: - type: number - title: discount_tax_total - description: The total taxes on discount of the exchange. - gift_card_total: - type: number - title: gift_card_total - description: The gift cards total of the exchange. - gift_card_tax_total: - type: number - title: gift_card_tax_total - description: The total taxes on the gift card of the exchange. - shipping_total: - type: number - title: shipping_total - description: The exchange's shipping total. - shipping_subtotal: - type: number - title: shipping_subtotal - description: The exchange's shipping subtotal. - shipping_tax_total: - type: number - title: shipping_tax_total - description: The exchange's shipping tax total. - original_shipping_total: - type: number - title: original_shipping_total - description: The order's shipping total. - original_shipping_subtotal: - type: number - title: original_shipping_subtotal - description: The order's shipping subtotal. - original_shipping_tax_total: - type: number - title: original_shipping_tax_total - description: The order's shipping tax total. + order_version: + type: string + title: order_version + description: The exchange's order version. + created_by: + type: string + title: created_by + description: The exchange's created by. + canceled_at: + type: string + title: canceled_at + description: The exchange's canceled at. + format: date-time + deleted_at: + type: string + format: date-time + title: deleted_at + description: The exchange's deleted at. + order: + type: string + title: order + description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + allow_backorder: + type: boolean + title: allow_backorder + description: The exchange's allow backorder. AdminExchangeDeleteResponse: type: object description: The details of deleting an exchange. @@ -9431,8 +9240,9 @@ components: - exchange properties: order: - description: The details of the associated order. - $ref: '#/components/schemas/Order' + type: string + title: order + description: The order change's order. exchange: $ref: '#/components/schemas/AdminExchange' AdminExchangePreviewResponse: @@ -9444,7 +9254,7 @@ components: - exchange properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' exchange: $ref: '#/components/schemas/AdminExchange' AdminExchangeRequestResponse: @@ -9457,11 +9267,9 @@ components: - exchange properties: return: - description: The associated return's details. $ref: '#/components/schemas/AdminReturn' order_preview: - description: A preview of the order once the exchange is applied. - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' exchange: $ref: '#/components/schemas/AdminExchange' AdminExchangeResponse: @@ -9482,9 +9290,13 @@ components: - return properties: order_preview: - $ref: '#/components/schemas/OrderPreview' + $ref: '#/components/schemas/AdminOrderPreview' return: $ref: '#/components/schemas/AdminReturn' + AdminExportProductRequest: + type: object + description: SUMMARY + x-schemaName: AdminExportProductRequest AdminExportProductResponse: type: object description: The details of the product export. @@ -9573,10 +9385,8 @@ components: title: shipping_option_id description: The ID of the shipping option this fulfillment is created for. provider: - description: The details of the fulfillment provider using to handle this fulfillment. $ref: '#/components/schemas/AdminFulfillmentProvider' delivery_address: - description: The address to deliver the item to. $ref: '#/components/schemas/AdminFulfillmentAddress' items: type: array @@ -9830,8 +9640,20 @@ components: description: The date the label was deleted. AdminFulfillmentProvider: type: object - description: The shipping option's provider. + description: The fulfillment provider's details. x-schemaName: AdminFulfillmentProvider + required: + - id + - is_enabled + properties: + id: + type: string + title: id + description: The provider's ID. + is_enabled: + type: boolean + title: is_enabled + description: The provider's is enabled. AdminFulfillmentProviderListResponse: type: object description: The paginated list of fulfillment providers. @@ -9870,7 +9692,7 @@ components: $ref: '#/components/schemas/AdminFulfillment' AdminFulfillmentSet: type: object - description: The fulfillment set's parent. + description: The service zone's fulfillment set. x-schemaName: AdminFulfillmentSet required: - id @@ -9885,37 +9707,39 @@ components: id: type: string title: id - description: The parent's ID. + description: The fulfillment set's ID. name: type: string title: name - description: The parent's name. + description: The fulfillment set's name. type: type: string title: type - description: The parent's type. + description: The fulfillment set's type. location: - $ref: '#/components/schemas/AdminStockLocation' + type: object + description: The stock location's details. + x-schemaName: AdminStockLocation service_zones: type: array - description: The parent's service zones. + description: The fulfillment set's service zones. items: $ref: '#/components/schemas/AdminServiceZone' created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The fulfillment set's created at. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The fulfillment set's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The fulfillment set's deleted at. AdminFulfillmentSetDeleteResponse: type: object description: The deletion details. @@ -9949,7 +9773,7 @@ components: $ref: '#/components/schemas/AdminFulfillmentSet' AdminGeoZone: type: object - description: The geo zone's details. + description: The geo zone's geo zones. x-schemaName: AdminGeoZone required: - id @@ -9993,17 +9817,17 @@ components: type: string format: date-time title: created_at - description: The date the geo zone was created. + description: The geo zone's created at. updated_at: type: string format: date-time title: updated_at - description: The date the geo zone was update. + description: The geo zone's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The date the geo zone was deleted. + description: The geo zone's deleted at. AdminImportProductRequest: type: object description: The import's details. @@ -10012,7 +9836,12 @@ components: - file properties: file: - $ref: '#/components/schemas/File' + type: object + description: A File to upload. + externalDocs: + url: https://developer.mozilla.org/en-US/docs/Web/API/File + description: Learn more about the File API + title: file AdminImportProductResponse: type: object description: The import process's details. @@ -10042,7 +9871,7 @@ components: description: The number of products that will be updated by this import. AdminInventoryItem: type: object - description: The inventory item's details. + description: The reservation's inventory item. x-schemaName: AdminInventoryItem required: - id @@ -10055,7 +9884,7 @@ components: sku: type: string title: sku - description: The inventory item's SKU. + description: The inventory item's sku. origin_country: type: string title: origin_country @@ -10063,15 +9892,15 @@ components: hs_code: type: string title: hs_code - description: The inventory item's HS code. + description: The inventory item's hs code. requires_shipping: type: boolean title: requires_shipping - description: Whether the inventory item requires shipping. + description: The inventory item's requires shipping. mid_code: type: string title: mid_code - description: The inventory item's MID code. + description: The inventory item's mid code. material: type: string title: material @@ -10103,13 +9932,13 @@ components: thumbnail: type: string title: thumbnail - description: The URL of the inventory item's thumbnail. + description: The inventory item's thumbnail. metadata: type: object - description: The inventory item's metadata, can hold custom key-value pairs. + description: The inventory item's metadata. location_levels: type: array - description: The inventory item's associated inventory levels. + description: The inventory item's location levels. items: $ref: '#/components/schemas/AdminInventoryLevel' AdminInventoryItemResponse: @@ -10123,7 +9952,7 @@ components: $ref: '#/components/schemas/AdminInventoryItem' AdminInventoryLevel: type: object - description: The inventory level's details. + description: The location level's location levels. x-schemaName: AdminInventoryLevel required: - id @@ -10133,62 +9962,59 @@ components: - inventory_item_id - location_id - stocked_quantity - - raw_stocked_quantity - reserved_quantity - - raw_reserved_quantity - incoming_quantity - - raw_incoming_quantity - metadata - available_quantity properties: id: type: string title: id - description: The inventory level's ID. + description: The location level's ID. + created_at: + type: string + format: date-time + title: created_at + description: The location level's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The location level's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The location level's deleted at. inventory_item_id: type: string title: inventory_item_id - description: The ID of the inventory item this level belongs to. + description: The location level's inventory item id. location_id: type: string title: location_id - description: The ID of the stock location this level belongs to. + description: The location level's location id. stocked_quantity: type: number title: stocked_quantity - description: The quantity of the associated inventory item stocked in the associated stock location. + description: The location level's stocked quantity. reserved_quantity: type: number title: reserved_quantity - description: The reserved quantity of the associated inventory item stocked in the associated stock location. + description: The location level's reserved quantity. incoming_quantity: type: number title: incoming_quantity - description: The incoming quantity of the associated inventory item stocked in the associated stock location. + description: The location level's incoming quantity. metadata: type: object - description: The location level's metadata, can hold custom key-value pairs. + description: The location level's metadata. inventory_item: type: object available_quantity: type: number title: available_quantity - description: The quantity available for order of the associated inventory item in the associated stock location. - created_at: - type: string - format: date-time - title: created_at - description: The date the inventory level was created. - updated_at: - type: string - format: date-time - title: updated_at - description: The date the inventory level was updated. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The date the inventory level was deleted. + description: The location level's available quantity. AdminInvite: type: object description: The invite's details. @@ -10255,6 +10081,10 @@ components: title: remove description: The ID of a product. x-schemaName: AdminLinkPriceListProducts + AdminMarkOrderFulfillmentDelivered: + type: object + description: SUMMARY + x-schemaName: AdminMarkOrderFulfillmentDelivered AdminNotification: type: object description: The notification's details. @@ -10364,21 +10194,20 @@ components: x-schemaName: AdminOrder required: - payment_collections + - items + - shipping_methods + - currency_code - id + - created_at + - updated_at + - email - version - region_id - customer_id - sales_channel_id - - email - - currency_code - - items - - shipping_methods - payment_status - fulfillment_status - summary - - metadata - - created_at - - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -10411,7 +10240,7 @@ components: type: array description: The order's fulfillments. items: - $ref: '#/components/schemas/BaseOrderFulfillment' + $ref: '#/components/schemas/AdminOrderFulfillment' sales_channel: $ref: '#/components/schemas/AdminSalesChannel' customer: @@ -10457,12 +10286,12 @@ components: type: array description: The order's items. items: - $ref: '#/components/schemas/BaseOrderLineItem' + $ref: '#/components/schemas/AdminOrderLineItem' shipping_methods: type: array description: The order's shipping methods. items: - $ref: '#/components/schemas/BaseOrderShippingMethod' + $ref: '#/components/schemas/AdminOrderShippingMethod' payment_status: type: string description: The order's payment status. @@ -10671,173 +10500,715 @@ components: format: date-time title: updated_at description: The date the address was updated. - AdminOrderChangesResponse: - type: object - description: The details of an order's changes. - x-schemaName: AdminOrderChangesResponse - required: - - order_changes - properties: - order_changes: - type: array - description: An order's changes. - items: - $ref: '#/components/schemas/BaseOrderChange' - AdminOrderEditPreviewResponse: - type: object - description: The preview of an order edit. - x-schemaName: AdminOrderEditPreviewResponse - required: - - order_preview - properties: - order_preview: - $ref: '#/components/schemas/OrderPreview' - AdminOrderEditResponse: - type: object - description: An order edit's details. - x-schemaName: AdminOrderEditResponse - required: - - order_change - properties: - order_change: - $ref: '#/components/schemas/OrderChange' - AdminOrderPreview: + AdminOrderChange: type: object - description: A preview of an order if a change, such as exchange, return, edit, or claim is applied on it. - x-schemaName: AdminOrderPreview + description: The order change's details. + x-schemaName: AdminOrderChange required: - - return_requested_total - - order_change - - currency_code - - version - - id - - region_id - - customer_id - - sales_channel_id - - email - - payment_collections - - payment_status - - fulfillment_status - - summary + - order + - claim + - return_order + - exchange + - actions + - status + - order_id - metadata + - id - created_at - updated_at - - original_item_total - - original_item_subtotal - - original_item_tax_total - - item_total - - item_subtotal - - item_tax_total - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total - properties: - return_requested_total: - type: number - title: return_requested_total - description: The total of the requested return. + - version + - canceled_at + - return_id + - exchange_id + - claim_id + - requested_by + - requested_at + - confirmed_by + - confirmed_at + - declined_by + - declined_reason + - declined_at + - canceled_by + properties: + id: + type: string + title: id + description: The order change's ID. + version: + type: number + title: version + description: The order change's version. This will be the order's version when the change is applied. + change_type: + oneOf: + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + - type: string + title: change_type + description: The order change's change type. + description: The order change's type. + order_id: + type: string + title: order_id + description: The ID of the order this change applies on. + return_id: + type: string + title: return_id + description: The ID of the associated return. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + order: + type: string + title: order + description: The order change's order. + return_order: + $ref: '#/components/schemas/AdminReturn' + exchange: + $ref: '#/components/schemas/AdminExchange' + claim: + $ref: '#/components/schemas/AdminClaim' + actions: + type: array + description: The order change's actions. + items: + $ref: '#/components/schemas/AdminOrderChangeAction' + status: + type: string + description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined + requested_by: + type: string + title: requested_by + description: The ID of the user that requested the change. + requested_at: + type: string + title: requested_at + description: The date the order change was requested. + format: date-time + confirmed_by: + type: string + title: confirmed_by + description: The ID of the user that confirmed the order change. + confirmed_at: + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time + declined_by: + type: string + title: declined_by + description: The ID of the user that declined the order change. + declined_reason: + type: string + title: declined_reason + description: The reason the order change was declined. + metadata: + type: object + description: The order change's metadata, can hold custom key-value pairs. + declined_at: + type: string + title: declined_at + description: The date the order change was declined. + format: date-time + canceled_by: + type: string + title: canceled_by + description: The ID of the user that canceled the order change. + canceled_at: + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time + created_at: + type: string + format: date-time + title: created_at + description: The date the order change was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change was updated. + AdminOrderChangeAction: + type: object + description: The order change action's details. + x-schemaName: AdminOrderChangeAction + required: + - order_change + - order + - order_id + - internal_note + - id + - created_at + - updated_at + - return_id + - exchange_id + - claim_id + - order_change_id + - reference + - reference_id + - action + - details + properties: + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change that the action belongs to. order_change: - $ref: '#/components/schemas/BaseOrderChange' - items: + type: object + order_id: + type: string + title: order_id + description: The ID of the order the associated change is for. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + type: string + title: order + description: The order change's order. + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + description: The applied action. + enum: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the action was updated. + AdminOrderChangesResponse: + type: object + description: The details of an order's changes. + x-schemaName: AdminOrderChangesResponse + required: + - order_changes + properties: + order_changes: type: array - description: The order's items. + description: An order's changes. items: - allOf: - - type: object - description: An order's item. - x-schemaName: BaseOrderLineItem - required: - - id - - title - - subtitle - - thumbnail - - variant_id - - product_id - - product_title - - product_description - - product_subtitle - - product_type - - product_collection - - product_handle - - variant_sku - - variant_barcode - - variant_title - - variant_option_values - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - - quantity - - detail - - created_at - - updated_at - - metadata - - original_total - - original_subtotal - - original_tax_total - - item_total - - item_subtotal - - item_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - refundable_total - - refundable_total_per_unit - properties: - id: - type: string - title: id - description: The item's ID. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The URL of the item's thumbnail. - variant: - $ref: '#/components/schemas/BaseProductVariant' - variant_id: - type: string - title: variant_id - description: The ID of the associated variant. - product: - $ref: '#/components/schemas/BaseProduct' - product_id: - type: string - title: product_id - description: The ID of the associated product. - product_title: - type: string - title: product_title - description: The title of the item's product. - product_description: - type: string - title: product_description - description: The description of the item's product. - product_subtitle: - type: string - title: product_subtitle + $ref: '#/components/schemas/AdminOrderChange' + AdminOrderEditPreviewResponse: + type: object + description: The preview of an order edit. + x-schemaName: AdminOrderEditPreviewResponse + required: + - order_preview + properties: + order_preview: + $ref: '#/components/schemas/AdminOrderPreview' + AdminOrderEditResponse: + type: object + description: An order edit's details. + x-schemaName: AdminOrderEditResponse + required: + - order_change + properties: + order_change: + $ref: '#/components/schemas/AdminOrderChange' + AdminOrderFulfillment: + type: object + description: The fulfillment's fulfillments. + x-schemaName: AdminOrderFulfillment + required: + - id + - location_id + - packed_at + - shipped_at + - delivered_at + - canceled_at + - requires_shipping + - data + - provider_id + - shipping_option_id + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The fulfillment's ID. + location_id: + type: string + title: location_id + description: The ID of the location the items are fulfilled from. + packed_at: + type: string + title: packed_at + description: The date the items were packed. + format: date-time + shipped_at: + type: string + title: shipped_at + description: The date the items were shipped. + format: date-time + delivered_at: + type: string + title: delivered_at + description: The date the items were delivered. + format: date-time + canceled_at: + type: string + title: canceled_at + description: The date the items were canceled. + format: date-time + data: + type: object + description: Data useful for the fulfillment provider handling it. This is taken from the associated shipping option. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + provider_id: + type: string + title: provider_id + description: The ID of the fulfillment provider used to handle the fulfillment. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the associated shipping option. + metadata: + type: object + description: The fulfillment's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the fulfillment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the fulfillment was updated. + requires_shipping: + type: boolean + title: requires_shipping + description: The fulfillment's requires shipping. + AdminOrderLineItem: + type: object + description: The item's items. + x-schemaName: AdminOrderLineItem + required: + - title + - metadata + - id + - subtitle + - thumbnail + - created_at + - updated_at + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - variant_id + - product_id + - product_title + - product_description + - product_subtitle + - product_type + - product_collection + - product_handle + - variant_sku + - variant_barcode + - variant_title + - variant_option_values + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - detail + - refundable_total + - refundable_total_per_unit + properties: + id: + type: string + title: id + description: The item's ID. + title: + type: string + title: title + description: The item's title. + subtitle: + type: string + title: subtitle + description: The item's subtitle. + thumbnail: + type: string + title: thumbnail + description: The URL of the item's thumbnail. + variant: + $ref: '#/components/schemas/AdminProductVariant' + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product: + $ref: '#/components/schemas/AdminProduct' + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The item's product type. + product_collection: + type: string + title: product_collection + description: The ID of the collection the item's product belongs to. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: + type: string + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The values of the item variant's options. + example: + Color: Blue + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item is tax inclusive. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + unit_price: + type: number + title: unit_price + description: The item's unit price. + quantity: + type: number + title: quantity + description: The item's quantity. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: '#/components/schemas/BaseOrderLineItemTaxLine' + adjustments: + type: array + description: The item's adjustments. + items: + $ref: '#/components/schemas/BaseOrderLineItemAdjustment' + detail: + $ref: '#/components/schemas/BaseOrderItemDetail' + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + original_total: + type: number + title: original_total + description: The item's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the item, excluding promotions. + item_total: + type: number + title: item_total + description: The total taxes of the item, including promotions. + item_subtotal: + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of the item, including promotions. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the item including promotions. + discount_total: + type: number + title: discount_total + description: The total discount amount of the item. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total refundable amount of the item's total. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total refundable amount of the item's total for a single quantity. + AdminOrderPreview: + type: object + description: A preview of an order if a change, such as exchange, return, edit, or claim is applied on it. + x-schemaName: AdminOrderPreview + required: + - return_requested_total + - order_change + - currency_code + - id + - created_at + - updated_at + - email + - version + - region_id + - customer_id + - sales_channel_id + - payment_collections + - payment_status + - fulfillment_status + - summary + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + properties: + return_requested_total: + type: number + title: return_requested_total + description: The total of the requested return. + order_change: + $ref: '#/components/schemas/AdminOrderChange' + items: + type: array + description: The order's items. + items: + allOf: + - type: object + description: An order's item. + x-schemaName: BaseOrderLineItem + required: + - id + - title + - subtitle + - thumbnail + - variant_id + - product_id + - product_title + - product_description + - product_subtitle + - product_type + - product_collection + - product_handle + - variant_sku + - variant_barcode + - variant_title + - variant_option_values + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - detail + - created_at + - updated_at + - metadata + - original_total + - original_subtotal + - original_tax_total + - item_total + - item_subtotal + - item_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - refundable_total + - refundable_total_per_unit + properties: + id: + type: string + title: id + description: The item's ID. + title: + type: string + title: title + description: The item's title. + subtitle: + type: string + title: subtitle + description: The item's subtitle. + thumbnail: + type: string + title: thumbnail + description: The URL of the item's thumbnail. + variant: + $ref: '#/components/schemas/BaseProductVariant' + variant_id: + type: string + title: variant_id + description: The ID of the associated variant. + product: + $ref: '#/components/schemas/AdminProduct' + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The title of the item's product. + product_description: + type: string + title: product_description + description: The description of the item's product. + product_subtitle: + type: string + title: product_subtitle description: The subtitle of the item's product. product_type: type: string @@ -11195,7 +11566,7 @@ components: type: array description: The order's fulfillments. items: - $ref: '#/components/schemas/BaseOrderFulfillment' + $ref: '#/components/schemas/AdminOrderFulfillment' fulfillment_status: type: string description: The order's fulfillment status. @@ -11328,7 +11699,9 @@ components: - order properties: order: - $ref: '#/components/schemas/AdminOrderPreview' + type: string + title: order + description: A preview of an order if a change, such as exchange, return, edit, or claim is applied on it. AdminOrderResponse: type: object description: An order's details. @@ -11337,7 +11710,9 @@ components: - order properties: order: - $ref: '#/components/schemas/AdminOrder' + type: string + title: order + description: The order's details. AdminOrderReturnResponse: type: object description: The order return details. @@ -11347,9 +11722,125 @@ components: - return properties: order: - $ref: '#/components/schemas/Order' + type: string + title: order + description: The order change's order. return: $ref: '#/components/schemas/AdminReturn' + AdminOrderShippingMethod: + type: object + description: The shipping method's details. + x-schemaName: AdminOrderShippingMethod + required: + - id + - order_id + - name + - amount + - is_tax_inclusive + - shipping_option_id + - data + - metadata + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes applied taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: The shipping method's data, useful for fulfillment provider handling its fulfillment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: '#/components/schemas/BaseOrderShippingMethodTaxLine' + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: '#/components/schemas/BaseOrderShippingMethodAdjustment' + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The shipping method's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The total discounts applied on the shipping method. + discount_tax_total: + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + detail: + $ref: '#/components/schemas/BaseOrderShippingDetail' AdminPayment: type: object description: The payment's details. @@ -11438,22 +11929,22 @@ components: type: array description: The details of payment refunds. items: - $ref: '#/components/schemas/BaseRefund' + $ref: '#/components/schemas/AdminRefund' payment_collection: - $ref: '#/components/schemas/BasePaymentCollection' + $ref: '#/components/schemas/AdminPaymentCollection' payment_session: - $ref: '#/components/schemas/BasePaymentSession' + $ref: '#/components/schemas/AdminPaymentSession' AdminPaymentCollection: type: object description: The payment collection's details. x-schemaName: AdminPaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -11514,17 +12005,17 @@ components: type: array description: The payment provider used to process the collection's payments and sessions. items: - $ref: '#/components/schemas/BasePaymentProvider' + $ref: '#/components/schemas/AdminPaymentProvider' payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: '#/components/schemas/BasePaymentSession' + $ref: '#/components/schemas/AdminPaymentSession' payments: type: array description: The payment collection's payments. items: - $ref: '#/components/schemas/BasePayment' + $ref: '#/components/schemas/AdminPayment' AdminPaymentCollectionResponse: type: object description: The payment collection's details. @@ -11536,7 +12027,7 @@ components: $ref: '#/components/schemas/AdminPaymentCollection' AdminPaymentProvider: type: object - description: The payment provider's details. + description: The payment provider's payment providers. x-schemaName: AdminPaymentProvider required: - is_enabled @@ -11559,6 +12050,65 @@ components: properties: payment: $ref: '#/components/schemas/AdminPayment' + AdminPaymentSession: + type: object + description: The payment session's details. + x-schemaName: AdminPaymentSession + properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: The payment session's data, useful for the payment provider processing the payment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: '#/components/schemas/BasePayment' + required: + - id + - amount + - currency_code + - provider_id + - data + - status AdminPostCancelClaimReqSchema: type: object description: The details of canceling a claim. @@ -11610,13 +12160,24 @@ components: title: quantity description: The quantity of the order's item to add to the claim. reason: - type: string + oneOf: + - type: string + description: The item's reason. + enum: + - MISSING_ITEM + - type: string + description: The item's reason. + enum: + - WRONG_ITEM + - type: string + description: The item's reason. + enum: + - PRODUCTION_FAILURE + - type: string + description: The item's reason. + enum: + - OTHER description: The reason the item is claimed. - enum: - - missing_item - - wrong_item - - production_failure - - other description: type: string title: description @@ -12486,190 +13047,13 @@ components: description: Whether the price list was deleted. AdminPriceListListResponse: type: object - description: The paginated list of price lists. - x-schemaName: AdminPriceListListResponse - required: - - limit - - offset - - count - - price_lists - properties: - limit: - type: number - title: limit - description: The maximum number of items returned. - offset: - type: number - title: offset - description: The number of items skipped before retrieving the returned items. - count: - type: number - title: count - description: The total number of items. - price_lists: - type: array - description: The list of price lists. - items: - $ref: '#/components/schemas/AdminPriceList' - AdminPriceListPrice: - type: object - description: The details of a price list's price. - x-schemaName: AdminPriceListPrice - required: - - variant_id - - rules - - id - - title - - currency_code - - amount - - raw_amount - - min_quantity - - max_quantity - - price_set_id - - created_at - - updated_at - - deleted_at - properties: - variant_id: - type: string - title: variant_id - description: The ID of the product variant this price list is for. - rules: - type: object - description: The price's rules. - id: - type: string - title: id - description: The price's ID. - title: - type: string - title: title - description: The price's title. - currency_code: - type: string - title: currency_code - description: The price's currency code. - example: usd - amount: - type: number - title: amount - description: The price's amount. - raw_amount: - type: object - description: The price's raw amount. - min_quantity: - type: number - title: min_quantity - description: The minimum quantity that must be available in the cart for the price to be applied. - max_quantity: - type: number - title: max_quantity - description: The maximum quantity allowed to be available in the cart for the price to be applied. - price_set_id: - type: string - title: price_set_id - description: The ID of the price set this price belongs to. - created_at: - type: string - format: date-time - title: created_at - description: The date the price was created. - updated_at: - type: string - format: date-time - title: updated_at - description: The date the price was updated. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The date the price was deleted. - AdminPriceListResponse: - type: object - description: The price list's details. - x-schemaName: AdminPriceListResponse - required: - - price_list - properties: - price_list: - $ref: '#/components/schemas/AdminPriceList' - AdminPricePreference: - type: object - description: The price preference's details. - x-schemaName: AdminPricePreference - required: - - id - - attribute - - value - - is_tax_inclusive - - created_at - - updated_at - - deleted_at - properties: - id: - type: string - title: id - description: The price preference's ID. - attribute: - type: string - title: attribute - description: The price preference's attribute. - example: region_id - value: - type: string - title: value - description: The price preference's value. - example: reg_123 - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: Whether prices matching this preference include taxes. - created_at: - type: string - format: date-time - title: created_at - description: The date the price preference was created. - updated_at: - type: string - format: date-time - title: updated_at - description: The date the price preference was updated. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The date the price preference was deleted. - AdminPricePreferenceDeleteResponse: - type: object - description: The details of the deleted price preference. - x-schemaName: AdminPricePreferenceDeleteResponse - required: - - id - - object - - deleted - properties: - id: - type: string - title: id - description: The price preference's ID. - object: - type: string - title: object - description: The name of the deleted object. - default: price_preference - deleted: - type: boolean - title: deleted - description: Whether the price preference was deleted. - AdminPricePreferenceListResponse: - type: object - description: The paginated list of price preferences. - x-schemaName: AdminPricePreferenceListResponse + description: The paginated list of price lists. + x-schemaName: AdminPriceListListResponse required: - limit - offset - count - - price_preferences + - price_lists properties: limit: type: number @@ -12682,274 +13066,144 @@ components: count: type: number title: count - description: The total count of items. - price_preferences: + description: The total number of items. + price_lists: type: array - description: The list of price preferences. + description: The list of price lists. items: - $ref: '#/components/schemas/AdminPricePreference' - AdminPricePreferenceResponse: - type: object - description: The price preference's details. - x-schemaName: AdminPricePreferenceResponse - required: - - price_preference - properties: - price_preference: - $ref: '#/components/schemas/AdminPricePreference' - AdminProduct: + $ref: '#/components/schemas/AdminPriceList' + AdminPriceListPrice: type: object - description: The product's details. - x-schemaName: AdminProduct + description: The details of a price list's price. + x-schemaName: AdminPriceListPrice required: - - type - - length - - title - - status - - options - - description + - variant_id + - rules - id + - title + - currency_code + - amount + - raw_amount + - min_quantity + - max_quantity + - price_set_id - created_at - updated_at - - handle - - subtitle - - is_giftcard - - thumbnail - - width - - weight - - height - - origin_country - - hs_code - - mid_code - - material - - collection_id - - type_id - - images - - discountable - - external_id - deleted_at properties: - collection: - $ref: '#/components/schemas/AdminCollection' - categories: - type: array - description: The product's categories. - items: - $ref: '#/components/schemas/AdminProductCategory' - sales_channels: - type: array - description: The sales channels that the product is available in. - items: - $ref: '#/components/schemas/AdminSalesChannel' - variants: - type: array - description: The product's variants. - items: - $ref: '#/components/schemas/AdminProductVariant' - type: - $ref: '#/components/schemas/AdminProductType' - tags: - type: array - description: The product's tags. - items: - $ref: '#/components/schemas/AdminProductTag' - length: - type: number - title: length - description: The product's length. - title: - type: string - title: title - description: The product's title. - status: - type: string - description: The product's status. - enum: - - draft - - proposed - - published - - rejected - options: - type: array - description: The product's options. - items: - $ref: '#/components/schemas/BaseProductOption' - description: + variant_id: type: string - title: description - description: The product's description. + title: variant_id + description: The ID of the product variant this price list is for. + rules: + type: object + description: The price's rules. id: type: string title: id - description: The product's ID. - metadata: + description: The price's ID. + title: + type: string + title: title + description: The price's title. + currency_code: + type: string + title: currency_code + description: The price's currency code. + example: usd + amount: + type: number + title: amount + description: The price's amount. + raw_amount: type: object - description: The product's metadata, can hold custom key-value pairs. + description: The price's raw amount. + min_quantity: + type: number + title: min_quantity + description: The minimum quantity that must be available in the cart for the price to be applied. + max_quantity: + type: number + title: max_quantity + description: The maximum quantity allowed to be available in the cart for the price to be applied. + price_set_id: + type: string + title: price_set_id + description: The ID of the price set this price belongs to. created_at: type: string format: date-time title: created_at - description: The date the product was created. + description: The date the price was created. updated_at: type: string format: date-time title: updated_at - description: The date the product was updated. - handle: - type: string - title: handle - description: The product's unique handle. - subtitle: - type: string - title: subtitle - description: The product's subtitle. - is_giftcard: - type: boolean - title: is_giftcard - description: Whether the product is a gift card. - thumbnail: - type: string - title: thumbnail - description: The product's thumbnail. - width: - type: number - title: width - description: The product's width. - weight: - type: number - title: weight - description: The product's weight. - height: - type: number - title: height - description: The product's height. - origin_country: - type: string - title: origin_country - description: The product's origin country. - hs_code: - type: string - title: hs_code - description: The product's HS code. - mid_code: - type: string - title: mid_code - description: The product's MID code. - material: - type: string - title: material - description: The product's material. - collection_id: - type: string - title: collection_id - description: The ID of the collection that the product belongs to. - type_id: - type: string - title: type_id - description: The ID of the product's type. - images: - type: array - description: The product's images. - items: - $ref: '#/components/schemas/BaseProductImage' - discountable: - type: boolean - title: discountable - description: Whether discounts can be applied on the product. - external_id: - type: string - title: external_id - description: The ID of a product in an external system, such as an ERP or CMS. + description: The date the price was updated. deleted_at: type: string format: date-time title: deleted_at - description: The date the product was deleted. - AdminProductCategory: + description: The date the price was deleted. + AdminPriceListResponse: type: object - description: The product category's details. - x-schemaName: AdminProductCategory + description: The price list's details. + x-schemaName: AdminPriceListResponse required: - - category_children - - parent_category - - name - - description - - id - - created_at - - updated_at - - handle - - deleted_at - - is_active - - is_internal - - rank - - parent_category_id + - price_list + properties: + price_list: + $ref: '#/components/schemas/AdminPriceList' + AdminPricePreference: + type: object + description: The price preference's details. + x-schemaName: AdminPricePreference + required: + - id + - attribute + - value + - is_tax_inclusive + - created_at + - updated_at + - deleted_at properties: - category_children: - type: array - description: The category's children. - items: - type: object - parent_category: - type: object - products: - type: array - description: The category's products. - items: - type: object - name: - type: string - title: name - description: The category's name. - description: - type: string - title: description - description: The category's description. id: type: string title: id - description: The category's ID. - metadata: - type: object - description: The category's metadata, can hold custom key-value pairs. + description: The price preference's ID. + attribute: + type: string + title: attribute + description: The price preference's attribute. + example: region_id + value: + type: string + title: value + description: The price preference's value. + example: reg_123 + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether prices matching this preference include taxes. created_at: type: string format: date-time title: created_at - description: The date the category was created. + description: The date the price preference was created. updated_at: type: string format: date-time title: updated_at - description: The date the category was updated. - handle: - type: string - title: handle - description: The category's unique handle. + description: The date the price preference was updated. deleted_at: type: string format: date-time title: deleted_at - description: The date the category was deleted. - is_active: - type: boolean - title: is_active - description: Whether the category is active. If disabled, the category isn't shown in the storefront. - is_internal: - type: boolean - title: is_internal - description: Whether the category is internal. If enabled, the category is only seen by admin users. - rank: - type: number - title: rank - description: The category's rank among sibling categories. - parent_category_id: - type: string - title: parent_category_id - description: The ID of the category's parent. - AdminProductCategoryDeleteResponse: + description: The date the price preference was deleted. + AdminPricePreferenceDeleteResponse: type: object - description: The details of deleting the category. - x-schemaName: AdminProductCategoryDeleteResponse + description: The details of the deleted price preference. + x-schemaName: AdminPricePreferenceDeleteResponse required: - id - object @@ -12958,25 +13212,25 @@ components: id: type: string title: id - description: The product category's ID. + description: The price preference's ID. object: type: string title: object description: The name of the deleted object. - default: product_category + default: price_preference deleted: type: boolean title: deleted - description: Whether the product category was deleted. - AdminProductCategoryListResponse: + description: Whether the price preference was deleted. + AdminPricePreferenceListResponse: type: object - description: The paginated list of product categories. - x-schemaName: AdminProductCategoryListResponse + description: The paginated list of price preferences. + x-schemaName: AdminPricePreferenceListResponse required: - limit - offset - count - - product_categories + - price_preferences properties: limit: type: number @@ -12989,263 +13243,275 @@ components: count: type: number title: count - description: The total number of items. - product_categories: + description: The total count of items. + price_preferences: type: array - description: The list of product categories. + description: The list of price preferences. items: - $ref: '#/components/schemas/AdminProductCategory' - AdminProductCategoryResponse: - type: object - description: The product category's details. - x-schemaName: AdminProductCategoryResponse - required: - - product_category - properties: - product_category: - $ref: '#/components/schemas/AdminProductCategory' - AdminProductDeleteResponse: + $ref: '#/components/schemas/AdminPricePreference' + AdminPricePreferenceResponse: type: object - description: The details of the product deletion. - x-schemaName: AdminProductDeleteResponse + description: The price preference's details. + x-schemaName: AdminPricePreferenceResponse required: - - id - - object - - deleted + - price_preference properties: - id: - type: string - title: id - description: The product's ID. - object: - type: string - title: object - description: The name of the deleted object. - default: product - deleted: - type: boolean - title: deleted - description: Whether the product was deleted. - AdminProductOption: + price_preference: + $ref: '#/components/schemas/AdminPricePreference' + AdminProduct: type: object - description: The product's product option. - x-schemaName: AdminProductOption + description: The product's details. + x-schemaName: AdminProduct required: - - id + - variants + - type + - options + - images + - length - title - properties: - id: - type: string - title: id - description: The product option's ID. - title: - type: string - title: title - description: The product option's title. - product: - $ref: '#/components/schemas/BaseProduct' - product_id: - type: string - title: product_id - description: The product option's product id. - values: - type: array - description: The product option's values. - items: - $ref: '#/components/schemas/BaseProductOptionValue' - metadata: - type: object - description: The product option's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The product option's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The product option's updated at. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The product option's deleted at. - AdminProductOptionDeleteResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductOptionDeleteResponse - required: - - id - - object - - deleted - properties: - id: - type: string - title: id - description: The product's ID. - object: - type: string - title: object - description: The name of the deleted object. - deleted: - type: boolean - title: deleted - description: Whether the Product was deleted. - parent: - $ref: '#/components/schemas/AdminProduct' - AdminProductOptionResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductOptionResponse - required: - - product_option - properties: - product_option: - $ref: '#/components/schemas/AdminProductOption' - AdminProductResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductResponse - required: - - product - properties: - product: - $ref: '#/components/schemas/AdminProduct' - AdminProductTag: - type: object - description: The tag's tags. - x-schemaName: AdminProductTag - required: + - status + - description - id - - value + - handle + - subtitle + - is_giftcard + - thumbnail + - width + - weight + - height + - origin_country + - hs_code + - mid_code + - material + - collection_id + - type_id + - discountable + - external_id - created_at - updated_at + - deleted_at properties: + collection: + $ref: '#/components/schemas/AdminCollection' + categories: + type: array + description: The product's categories. + items: + $ref: '#/components/schemas/AdminProductCategory' + sales_channels: + type: array + description: The sales channels that the product is available in. + items: + $ref: '#/components/schemas/AdminSalesChannel' + variants: + type: array + description: The product's variants. + items: + $ref: '#/components/schemas/AdminProductVariant' + type: + $ref: '#/components/schemas/AdminProductType' + tags: + type: array + description: The product's tags. + items: + $ref: '#/components/schemas/AdminProductTag' + length: + type: number + title: length + description: The product's length. + title: + type: string + title: title + description: The product's title. + status: + type: string + description: The product's status. + enum: + - draft + - proposed + - published + - rejected + options: + type: array + description: The product's options. + items: + $ref: '#/components/schemas/AdminProductOption' + description: + type: string + title: description + description: The product's description. id: type: string title: id - description: The tag's ID. - value: - type: string - title: value - description: The tag's value. + description: The product's ID. + metadata: + type: object + description: The product's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The tag's created at. + description: The date the product was created. updated_at: type: string format: date-time title: updated_at - description: The tag's updated at. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The tag's deleted at. - metadata: - type: object - description: The tag's metadata. - AdminProductTagDeleteResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductTagDeleteResponse - required: - - id - - object - - deleted - properties: - id: + description: The date the product was updated. + handle: type: string - title: id - description: The product tag's ID. - object: + title: handle + description: The product's unique handle. + subtitle: type: string - title: object - description: The name of the deleted object. - default: product_tag - deleted: + title: subtitle + description: The product's subtitle. + is_giftcard: type: boolean - title: deleted - description: Whether the Product Tag was deleted. - AdminProductTagListResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductTagListResponse - required: - - limit - - offset - - count - - product_tags - properties: - limit: + title: is_giftcard + description: Whether the product is a gift card. + thumbnail: + type: string + title: thumbnail + description: The product's thumbnail. + width: type: number - title: limit - description: The product tag's limit. - offset: + title: width + description: The product's width. + weight: type: number - title: offset - description: The product tag's offset. - count: + title: weight + description: The product's weight. + height: type: number - title: count - description: The product tag's count. - product_tags: + title: height + description: The product's height. + origin_country: + type: string + title: origin_country + description: The product's origin country. + hs_code: + type: string + title: hs_code + description: The product's HS code. + mid_code: + type: string + title: mid_code + description: The product's MID code. + material: + type: string + title: material + description: The product's material. + collection_id: + type: string + title: collection_id + description: The ID of the collection that the product belongs to. + type_id: + type: string + title: type_id + description: The ID of the product's type. + images: type: array - description: The product tag's product tags. + description: The product's images. items: - $ref: '#/components/schemas/AdminProductTag' - AdminProductTagResponse: - type: object - description: SUMMARY - x-schemaName: AdminProductTagResponse - required: - - product_tag - properties: - product_tag: - $ref: '#/components/schemas/AdminProductTag' - AdminProductType: + $ref: '#/components/schemas/AdminProductImage' + discountable: + type: boolean + title: discountable + description: Whether discounts can be applied on the product. + external_id: + type: string + title: external_id + description: The ID of a product in an external system, such as an ERP or CMS. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the product was deleted. + AdminProductCategory: type: object - description: The parent's type. - x-schemaName: AdminProductType + description: The product category's details. + x-schemaName: AdminProductCategory required: + - category_children + - parent_category + - name + - description - id - - value - created_at - updated_at + - handle + - deleted_at + - is_active + - is_internal + - rank + - parent_category_id properties: + category_children: + type: array + description: The category's children. + items: + type: object + parent_category: + type: object + products: + type: array + description: The category's products. + items: + type: object + name: + type: string + title: name + description: The category's name. + description: + type: string + title: description + description: The category's description. id: type: string title: id - description: The type's ID. - value: - type: string - title: value - description: The type's value. + description: The category's ID. + metadata: + type: object + description: The category's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The type's created at. + description: The date the category was created. updated_at: type: string format: date-time title: updated_at - description: The type's updated at. + description: The date the category was updated. + handle: + type: string + title: handle + description: The category's unique handle. deleted_at: type: string format: date-time title: deleted_at - description: The type's deleted at. - metadata: - type: object - description: The type's metadata. - AdminProductTypeDeleteResponse: + description: The date the category was deleted. + is_active: + type: boolean + title: is_active + description: Whether the category is active. If disabled, the category isn't shown in the storefront. + is_internal: + type: boolean + title: is_internal + description: Whether the category is internal. If enabled, the category is only seen by admin users. + rank: + type: number + title: rank + description: The category's rank among sibling categories. + parent_category_id: + type: string + title: parent_category_id + description: The ID of the category's parent. + AdminProductCategoryDeleteResponse: type: object - description: SUMMARY - x-schemaName: AdminProductTypeDeleteResponse + description: The details of deleting the category. + x-schemaName: AdminProductCategoryDeleteResponse required: - id - object @@ -13254,191 +13520,157 @@ components: id: type: string title: id - description: The product type's ID. + description: The product category's ID. object: type: string title: object description: The name of the deleted object. - default: product_type + default: product_category deleted: type: boolean title: deleted - description: Whether the Product Type was deleted. - AdminProductTypeListResponse: + description: Whether the product category was deleted. + AdminProductCategoryListResponse: type: object - description: SUMMARY - x-schemaName: AdminProductTypeListResponse + description: The paginated list of product categories. + x-schemaName: AdminProductCategoryListResponse required: - limit - offset - count - - product_types + - product_categories properties: limit: type: number title: limit - description: The product type's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product type's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product type's count. - product_types: + description: The total number of items. + product_categories: type: array - description: The product type's product types. + description: The list of product categories. items: - $ref: '#/components/schemas/AdminProductType' - AdminProductTypeResponse: + $ref: '#/components/schemas/AdminProductCategory' + AdminProductCategoryResponse: type: object - description: SUMMARY - x-schemaName: AdminProductTypeResponse + description: The product category's details. + x-schemaName: AdminProductCategoryResponse required: - - product_type + - product_category properties: - product_type: - $ref: '#/components/schemas/AdminProductType' - AdminProductVariant: + product_category: + $ref: '#/components/schemas/AdminProductCategory' + AdminProductDeleteResponse: type: object - description: The product's parent. - x-schemaName: AdminProductVariant + description: The details of the product deletion. + x-schemaName: AdminProductDeleteResponse required: - - prices - id - - title - - sku - - barcode - - ean - - upc - - allow_backorder - - manage_inventory - - hs_code - - origin_country - - mid_code - - material - - weight - - length - - height - - width - - options - - created_at - - updated_at - - deleted_at + - object + - deleted properties: - prices: - type: array - description: The parent's prices. - items: - $ref: '#/components/schemas/AdminPrice' id: type: string title: id - description: The parent's ID. - title: - type: string - title: title - description: The parent's title. - sku: + description: The product's ID. + object: type: string - title: sku - description: The parent's sku. - barcode: + title: object + description: The name of the deleted object. + default: product + deleted: + type: boolean + title: deleted + description: Whether the product was deleted. + AdminProductImage: + type: object + description: The image's details. + x-schemaName: AdminProductImage + properties: + id: type: string - title: barcode - description: The parent's barcode. - ean: + title: id + description: The image's ID. + url: type: string - title: ean - description: The parent's ean. - upc: + title: url + description: The image's URL. + created_at: type: string - title: upc - description: The parent's upc. - allow_backorder: - type: boolean - title: allow_backorder - description: The parent's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The parent's manage inventory. - inventory_quantity: - type: number - title: inventory_quantity - description: The parent's inventory quantity. - hs_code: + format: date-time + title: created_at + description: The date the image was created. + updated_at: type: string - title: hs_code - description: The parent's hs code. - origin_country: + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: type: string - title: origin_country - description: The parent's origin country. - mid_code: + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. + required: + - id + - url + AdminProductOption: + type: object + description: The product option's details. + x-schemaName: AdminProductOption + properties: + id: type: string - title: mid_code - description: The parent's mid code. - material: + title: id + description: The option's ID. + title: type: string - title: material - description: The parent's material. - weight: - type: number - title: weight - description: The parent's weight. - length: - type: number - title: length - description: The parent's length. - height: - type: number - title: height - description: The parent's height. - width: - type: number - title: width - description: The parent's width. - variant_rank: - type: number - title: variant_rank - description: The parent's variant rank. - options: - type: array - description: The parent's options. - items: - $ref: '#/components/schemas/BaseProductOptionValue' + title: title + description: The option's title. product: - $ref: '#/components/schemas/BaseProduct' + type: object product_id: type: string title: product_id - description: The parent's product id. - calculated_price: - $ref: '#/components/schemas/BaseCalculatedPriceSet' + description: The option's product id. + values: + type: array + description: The option's values. + items: + type: object + metadata: + type: object + description: The option's metadata. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The option's created at. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The option's updated at. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. - metadata: - type: object - description: The parent's metadata. - AdminProductVariantDeleteResponse: + description: The option's deleted at. + required: + - id + - title + AdminProductOptionDeleteResponse: type: object - description: SUMMARY - x-schemaName: AdminProductVariantDeleteResponse + description: The details of the product option deletion. + x-schemaName: AdminProductOptionDeleteResponse required: - id - object @@ -13447,915 +13679,585 @@ components: id: type: string title: id - description: The product's ID. + description: The product option's ID. object: type: string title: object description: The name of the deleted object. + default: product_option deleted: type: boolean title: deleted - description: Whether the Product was deleted. + description: Whether the product option was deleted. parent: $ref: '#/components/schemas/AdminProduct' - AdminProductVariantInventoryBatchResponse: + AdminProductOptionResponse: type: object - description: SUMMARY - x-schemaName: AdminProductVariantInventoryBatchResponse + description: The product option's details. + x-schemaName: AdminProductOptionResponse required: - - created - - updated - - deleted + - product_option properties: - created: - oneOf: - - $ref: '#/components/schemas/AdminProductVariantInventoryLink' - - type: array - description: The product's created. - items: - type: object - description: The created's details. - x-schemaName: AdminProductVariantInventoryLink - required: - - productService - - inventoryService - properties: - productService: - type: object - description: The created's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: - type: object - description: The created's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - updated: - oneOf: - - $ref: '#/components/schemas/AdminProductVariantInventoryLink' - - type: array - description: The product's updated. - items: - type: object - description: The updated's details. - x-schemaName: AdminProductVariantInventoryLink - required: - - productService - - inventoryService - properties: - productService: - type: object - description: The updated's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: - type: object - description: The updated's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - deleted: - oneOf: - - $ref: '#/components/schemas/AdminProductVariantInventoryLink' - - type: array - description: SUMMARY - items: - type: object - description: SUMMARY - x-schemaName: AdminProductVariantInventoryLink - required: - - productService - - inventoryService - properties: - productService: - type: object - description: The deleted's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: - type: object - description: The deleted's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - AdminProductVariantInventoryLink: + product_option: + $ref: '#/components/schemas/AdminProductOption' + AdminProductOptionValue: + type: object + description: The product option value's details. + x-schemaName: AdminProductOptionValue + required: + - id + - value + properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + $ref: '#/components/schemas/AdminProductOption' + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. + AdminProductResponse: type: object - description: The product's ID. - x-schemaName: AdminProductVariantInventoryLink + description: The product's details. + x-schemaName: AdminProductResponse required: - - productService - - inventoryService + - product properties: - productService: - type: object - description: The id's productservice. - required: - - variant_id - properties: - variant_id: - type: string - title: variant_id - description: The productservice's variant id. - inventoryService: + product: + $ref: '#/components/schemas/AdminProduct' + AdminProductTag: + type: object + description: The product tag's details. + x-schemaName: AdminProductTag + required: + - id + - value + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The tag's ID. + value: + type: string + title: value + description: The tag's value. + created_at: + type: string + format: date-time + title: created_at + description: The date the tag was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tag was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the tag was deleted. + metadata: type: object - description: The id's inventoryservice. - required: - - inventory_item_id - properties: - inventory_item_id: - type: string - title: inventory_item_id - description: The inventoryservice's inventory item id. - AdminProductVariantInventoryLinkDeleteResponse: + description: The tag's metadata, can hold custom key-value pairs. + AdminProductTagDeleteResponse: type: object - description: SUMMARY - x-schemaName: AdminProductVariantInventoryLinkDeleteResponse + description: The details of the product tag deletion. + x-schemaName: AdminProductTagDeleteResponse required: - id - object - deleted - - parent properties: id: - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + type: string + title: id + description: The product tag's ID. object: type: string title: object description: The name of the deleted object. + default: product_tag deleted: type: boolean title: deleted - description: Whether the Product was deleted. - parent: - $ref: '#/components/schemas/AdminProductVariant' - AdminProductVariantParams: + description: Whether the product tag was deleted. + AdminProductTagListResponse: type: object - description: SUMMARY - x-schemaName: AdminProductVariantParams + description: The paginated list of product tags. + x-schemaName: AdminProductTagListResponse + required: + - limit + - offset + - count + - product_tags properties: - q: - type: string - title: q - description: The product's q. - id: - oneOf: - - type: string - title: id - description: The product's ID. - - type: array - description: The product's ID. - items: - type: string - title: id - description: The id's ID. - manage_inventory: - type: boolean - title: manage_inventory - description: The product's manage inventory. - allow_backorder: - type: boolean - title: allow_backorder - description: The product's allow backorder. - created_at: - type: object - description: The product's created at. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). + limit: + type: number + title: limit + description: The maximum number of items returned. + offset: + type: number + title: offset + description: The number of items skipped before retrieving the returned items. + count: + type: number + title: count + description: The total number of items. + product_tags: + type: array + description: The list of product tags. + items: + $ref: '#/components/schemas/AdminProductTag' + AdminProductTagResponse: + type: object + description: The product tag's details. + x-schemaName: AdminProductTagResponse + required: + - product_tag + properties: + product_tag: + $ref: '#/components/schemas/AdminProductTag' + AdminProductType: + type: object + description: The product type's details. + x-schemaName: AdminProductType + required: + - id + - value + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The type's ID. + value: + type: string + title: value + description: The type's value. + created_at: + type: string + format: date-time + title: created_at + description: The date the type was created. updated_at: + type: string + format: date-time + title: updated_at + description: The date the type was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the type was deleted. + metadata: type: object - description: The product's updated at. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). + description: The type's metadata, can hold custom key-value pairs. + AdminProductTypeDeleteResponse: + type: object + description: The details of the product type deletion. + x-schemaName: AdminProductTypeDeleteResponse + required: + - id + - object + - deleted + properties: + id: + type: string + title: id + description: The product type's ID. + object: + type: string + title: object + description: The name of the deleted object. + default: product_type + deleted: + type: boolean + title: deleted + description: Whether the product type was deleted. + AdminProductTypeListResponse: + type: object + description: The paginated list of product types. + x-schemaName: AdminProductTypeListResponse + required: + - limit + - offset + - count + - product_types + properties: + limit: + type: number + title: limit + description: The maximum number of items returned. + offset: + type: number + title: offset + description: The number of items skipped before retrieving the returned items. + count: + type: number + title: count + description: The total number of items. + product_types: + type: array + description: The list of product types. + items: + $ref: '#/components/schemas/AdminProductType' + AdminProductTypeResponse: + type: object + description: The product type's details. + x-schemaName: AdminProductTypeResponse + required: + - product_type + properties: + product_type: + $ref: '#/components/schemas/AdminProductType' + AdminProductVariant: + type: object + description: The product variant's details. + x-schemaName: AdminProductVariant + required: + - prices + - options + - id + - title + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory + - hs_code + - origin_country + - mid_code + - material + - weight + - length + - height + - width + - created_at + - updated_at + - deleted_at + properties: + prices: + type: array + description: The variant's prices. + items: + $ref: '#/components/schemas/AdminPrice' + id: + type: string + title: id + description: The variant's ID. + title: + type: string + title: title + description: The variant's title. + sku: + type: string + title: sku + description: The variant's SKU. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's EAN code. + upc: + type: string + title: upc + description: The variant's UPC. + allow_backorder: + type: boolean + title: allow_backorder + description: Whether the variant can be ordered even if it's out of stock. + manage_inventory: + type: boolean + title: manage_inventory + description: Whether the Medusa application manages the variant's inventory quantity and availablility. If disabled, the variant is always considered in stock. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. This is only included if you pass in the `fields` query parameter a `+variants.inventory_quantity` parameter. + hs_code: + type: string + title: hs_code + description: The variant's HS code. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + mid_code: + type: string + title: mid_code + description: The variant's MID code. + material: + type: string + title: material + description: The variant's material. + weight: + type: number + title: weight + description: The variant's weight. + length: + type: number + title: length + description: The variant's length. + height: + type: number + title: height + description: The variant's height. + width: + type: number + title: width + description: The variant's width. + variant_rank: + type: number + title: variant_rank + description: The variant's rank among its sibling variants. + options: + type: array + description: The variant's option values. + items: + $ref: '#/components/schemas/AdminProductOptionValue' + product: + $ref: '#/components/schemas/AdminProduct' + product_id: + type: string + title: product_id + description: The ID of the product that the variant belongs to. + calculated_price: + $ref: '#/components/schemas/BaseCalculatedPriceSet' + created_at: + type: string + format: date-time + title: created_at + description: The date the variant was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the variant was updated. deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the variant was deleted. + metadata: type: object - description: The product's deleted at. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + description: The variant's metadata, can hold custom key-value pairs. + AdminProductVariantDeleteResponse: + type: object + description: The details of the product variant's deletion. + x-schemaName: AdminProductVariantDeleteResponse + required: + - id + - object + - deleted + properties: + id: + type: string + title: id + description: The product variant's ID. + object: + type: string + title: object + description: The name of the deleted object. + deleted: + type: boolean + title: deleted + description: Whether the product variant was deleted. + default: variant + parent: + $ref: '#/components/schemas/AdminProduct' + AdminProductVariantInventoryBatchResponse: + type: object + description: The created, updated, and deleted associations between variants and inventory items. + x-schemaName: AdminProductVariantInventoryBatchResponse + required: + - created + - updated + - deleted + properties: + created: + oneOf: + - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + - type: array + description: The created associations between product variants and inventory items. items: type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + description: A created association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - productService + - inventoryService + properties: + productService: + type: object + description: The product variant's details. + required: + - variant_id + properties: + variant_id: + type: string + title: variant_id + description: The ID of the product variant. + inventoryService: + type: object + description: The inventory item's details. + required: + - inventory_item_id + properties: + inventory_item_id: + type: string + title: inventory_item_id + description: The ID of the inventory item. + updated: + oneOf: + - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + - type: array + description: The updated associations between product variants and inventory items. items: type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: - type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - properties: - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or - $eq: - oneOf: - - type: string - title: $eq - description: Filter by an exact match. - - type: array - description: Filter by an exact match. - items: - type: string - title: $eq - description: Filter by an exact match. - $ne: - type: string - title: $ne - description: Filter by values not equal to this parameter. - $in: - type: array - description: Filter by values in this array. - items: - type: string - title: $in - description: Filter by values in this array. - $nin: - type: array - description: Filter by values not in this array. - items: + description: An updated association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - productService + - inventoryService + properties: + productService: + type: object + description: The product variant's details. + required: + - variant_id + properties: + variant_id: type: string - title: $nin - description: Filter by values not in this array. - $not: - oneOf: - - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - - type: object - description: Filter by values not matching the conditions in this parameter. - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: - type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: - type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: + title: variant_id + description: The ID of the product variant. + inventoryService: + type: object + description: The inventory item's details. + required: + - inventory_item_id + properties: + inventory_item_id: type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: + title: inventory_item_id + description: The ID of the inventory item. + deleted: + oneOf: + - $ref: '#/components/schemas/AdminProductVariantInventoryLink' + - type: array + description: The deleted associations between product variants and inventory items. + items: + type: object + description: An deleted association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - productService + - inventoryService + properties: + productService: + type: object + description: The product variant's details. + required: + - variant_id + properties: + variant_id: type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: + title: variant_id + description: The ID of the product variant. + inventoryService: + type: object + description: The inventory item's details. + required: + - inventory_item_id + properties: + inventory_item_id: type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - - type: array - description: Filter by values not matching the conditions in this parameter. - items: - type: string - title: $not - description: Filter by values not matching the conditions in this parameter. - $gt: - type: string - title: $gt - description: Filter by values greater than this parameter. Useful for numbers and dates only. - $gte: - type: string - title: $gte - description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. - $lt: - type: string - title: $lt - description: Filter by values less than this parameter. Useful for numbers and dates only. - $lte: - type: string - title: $lte - description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. - $like: - type: string - title: $like - description: Apply a `like` filter. Useful for strings only. - $re: - type: string - title: $re - description: Apply a regex filter. Useful for strings only. - $ilike: + title: inventory_item_id + description: The ID of the inventory item. + AdminProductVariantInventoryLink: + type: object + description: The details of an association between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLink + required: + - Product + - Inventory + properties: + Product: + type: object + description: The id's product. + required: + - variant_id + properties: + variant_id: type: string - title: $ilike - description: Apply a case-insensitive `like` filter. Useful for strings only. - $fulltext: + title: variant_id + description: The product's variant id. + Inventory: + type: object + description: The id's inventory. + required: + - inventory_item_id + properties: + inventory_item_id: type: string - title: $fulltext - description: Filter to apply on full-text properties. - $overlap: - type: array - description: Filter arrays that have overlapping values with this parameter. - items: - type: string - title: $overlap - description: Filter arrays that have overlapping values with this parameter. - $contains: - type: array - description: Filter arrays that contain some of the values of this parameter. - items: - type: string - title: $contains - description: Filter arrays that contain some of the values of this parameter. - $contained: - type: array - description: Filter arrays that contain all values of this parameter. - items: - type: string - title: $contained - description: Filter arrays that contain all values of this parameter. - $exists: - type: boolean - title: $exists - description: Filter by whether a value for this parameter exists (not `null`). - limit: - type: number - title: limit - description: The product's limit. - offset: - type: number - title: offset - description: The product's offset. - order: - type: string - title: order - description: The product's order. - fields: + title: inventory_item_id + description: The inventory's inventory item id. + AdminProductVariantInventoryLinkDeleteResponse: + type: object + description: The details of the deleted associated between a product variant and an inventory item. + x-schemaName: AdminProductVariantInventoryLinkDeleteResponse + required: + - id + - object + - deleted + - parent + properties: + id: + $ref: '#/components/schemas/AdminProductVariantInventoryLink' + object: type: string - title: fields - description: The product's fields. - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or + title: object + description: The name of the deleted object. + default: variant-inventory-item-link + deleted: + type: boolean + title: deleted + description: Whether the association was deleted. + parent: + $ref: '#/components/schemas/AdminProductVariant' AdminProductVariantResponse: type: object - description: SUMMARY + description: The product variant's details. x-schemaName: AdminProductVariantResponse required: - variant @@ -14364,11 +14266,16 @@ components: $ref: '#/components/schemas/AdminProductVariant' AdminPromotion: type: object - description: The promotion's details. + description: The application method's promotion. x-schemaName: AdminPromotion - required: - - id properties: + application_method: + $ref: '#/components/schemas/AdminApplicationMethod' + rules: + type: array + description: The promotion's rules. + items: + $ref: '#/components/schemas/AdminPromotionRule' id: type: string title: id @@ -14378,31 +14285,28 @@ components: title: code description: The promotion's code. type: - type: string - description: The promotion's type. - enum: - - standard - - buyget + oneOf: + - type: string + title: type + description: The promotion's type. + - type: string + title: type + description: The promotion's type. is_automatic: type: boolean title: is_automatic description: The promotion's is automatic. - application_method: - $ref: '#/components/schemas/BaseApplicationMethod' - rules: - type: array - description: The promotion's rules. - items: - $ref: '#/components/schemas/BasePromotionRule' campaign_id: type: string title: campaign_id description: The promotion's campaign id. campaign: $ref: '#/components/schemas/AdminCampaign' + required: + - id AdminPromotionResponse: type: object - description: SUMMARY + description: The promotion's details. x-schemaName: AdminPromotionResponse required: - promotion @@ -14411,7 +14315,7 @@ components: $ref: '#/components/schemas/AdminPromotion' AdminPromotionRule: type: object - description: The updated's details. + description: The target rule's target rules. x-schemaName: AdminPromotionRule required: - id @@ -14420,31 +14324,82 @@ components: id: type: string title: id - description: The updated's ID. + description: The target rule's ID. description: type: string title: description - description: The updated's description. + description: The target rule's description. attribute: type: string title: attribute - description: The updated's attribute. + description: The target rule's attribute. operator: - type: string - description: The updated's operator. - enum: - - gt - - lt - - eq - - ne - - in - - lte - - gte + oneOf: + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. + - type: string + title: operator + description: The target rule's operator. values: type: array - description: The updated's values. + description: The target rule's values. items: $ref: '#/components/schemas/BasePromotionRuleValue' + AdminRefund: + type: object + description: The refund's details. + x-schemaName: AdminRefund + required: + - id + - amount + - created_at + - payment + properties: + id: + type: string + title: id + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: + type: string + title: refund_reason_id + description: The ID of the refund reason. + note: + type: string + title: note + description: More details about the refund. + created_at: + type: string + format: date-time + title: created_at + description: The date the refund was created. + created_by: + type: string + title: created_by + description: The ID of the user that created the refund. + payment: + $ref: '#/components/schemas/BasePayment' + refund_reason: + $ref: '#/components/schemas/RefundReason' AdminRefundReason: type: object description: The refund reason's details. @@ -14470,25 +14425,25 @@ components: description: The refund reason's description. metadata: type: object - description: The refund reason's metadata. + description: The refund reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The refund reason's created at. + description: The date the refund reason was created. updated_at: type: string format: date-time title: updated_at - description: The refund reason's updated at. + description: The date the refund reason was updated. AdminRegion: type: object description: The region's details. x-schemaName: AdminRegion required: - - id - name - currency_code + - id properties: id: type: string @@ -14502,15 +14457,16 @@ components: type: string title: currency_code description: The region's currency code. + example: usd automatic_taxes: type: boolean title: automatic_taxes - description: The region's automatic taxes. + description: Whether taxes are applied automatically during checkout. countries: type: array description: The region's countries. items: - $ref: '#/components/schemas/BaseRegionCountry' + $ref: '#/components/schemas/AdminRegionCountry' payment_providers: type: array description: The region's payment providers. @@ -14518,24 +14474,54 @@ components: $ref: '#/components/schemas/AdminPaymentProvider' metadata: type: object - description: The region's metadata. + description: The region's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The region's created at. + description: The date the region was created. updated_at: type: string format: date-time title: updated_at - description: The region's updated at. + description: The date the region was updated. AdminRegionCountry: type: object - description: The billing address's country. + description: The country's details. x-schemaName: AdminRegionCountry + required: + - id + properties: + id: + type: string + title: id + description: The country's ID. + iso_2: + type: string + title: iso_2 + description: The country's iso 2. + example: us + iso_3: + type: string + title: iso_3 + description: The country's iso 3. + example: usa + num_code: + type: string + title: num_code + description: The country's num code. + example: 840 + name: + type: string + title: name + description: The country's name. + display_name: + type: string + title: display_name + description: The country's display name. AdminRegionResponse: type: object - description: SUMMARY + description: The region's details. x-schemaName: AdminRegionResponse required: - region @@ -14554,7 +14540,6 @@ components: - external_id - description - inventory_item_id - - inventory_item properties: id: type: string @@ -14563,11 +14548,11 @@ components: line_item_id: type: string title: line_item_id - description: The reservation's line item id. + description: The ID of the line item this reservation is for. location_id: type: string title: location_id - description: The reservation's location id. + description: The ID of the location the quantity is reserved from. quantity: type: number title: quantity @@ -14575,7 +14560,7 @@ components: external_id: type: string title: external_id - description: The reservation's external id. + description: An ID in an external system description: type: string title: description @@ -14583,35 +14568,34 @@ components: inventory_item_id: type: string title: inventory_item_id - description: The reservation's inventory item id. + description: The ID of the inventory item this reservation is associated with. inventory_item: - type: object - description: The reservation's inventory item. + $ref: '#/components/schemas/AdminInventoryItem' metadata: type: object - description: The reservation's metadata. + description: The reservation's metadata, can hold custom key-value pairs. created_by: type: string title: created_by - description: The reservation's created by. + description: The ID of the user that created this reservation. deleted_at: type: string format: date-time title: deleted_at - description: The reservation's deleted at. + description: The date this reservation was deleted. created_at: type: string format: date-time title: created_at - description: The reservation's created at. + description: The date this reservation was created. updated_at: type: string format: date-time title: updated_at - description: The reservation's updated at. + description: The date this reservation was updated. AdminReservationResponse: type: object - description: SUMMARY + description: The reservation's details. x-schemaName: AdminReservationResponse required: - reservation @@ -14620,14 +14604,14 @@ components: $ref: '#/components/schemas/AdminReservation' AdminReturn: type: object - description: The exchange's return. + description: The return's details. x-schemaName: AdminReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -14636,14 +14620,47 @@ components: type: string title: id description: The return's ID. + status: + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + description: The return's status. + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. order_id: type: string title: order_id - description: The return's order id. - status: + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: '#/components/schemas/AdminReturnItem' + created_at: type: string - title: status - description: The return's status. + format: date-time + title: created_at + description: The date the return was created. + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time exchange_id: type: string title: exchange_id @@ -14668,31 +14685,13 @@ components: type: boolean title: no_notification description: The return's no notification. - refund_amount: - type: number - title: refund_amount - description: The return's refund amount. - items: - type: array - description: The return's items. - items: - $ref: '#/components/schemas/BaseReturnItem' received_at: type: string title: received_at description: The return's received at. - created_at: - type: string - format: date-time - title: created_at - description: The return's created at. - canceled_at: - type: string - title: canceled_at - description: The return's canceled at. AdminReturnItem: type: object - description: The return item's return items. + description: The item's items. x-schemaName: AdminReturnItem required: - id @@ -14713,33 +14712,33 @@ components: received_quantity: type: number title: received_quantity - description: The return item's received quantity. + description: The received quantity of the item. This quantity is added to the stocked inventory quantity of the item. damaged_quantity: type: number title: damaged_quantity - description: The return item's damaged quantity. + description: The received damaged quantity of the item, which isn't added to the stocked inventory quantity of the item. reason_id: type: string title: reason_id - description: The return item's reason id. + description: The ID of the return reason associated with the item. note: type: string title: note - description: The return item's note. + description: A note about why the item was returned. item_id: type: string title: item_id - description: The return item's item id. + description: The ID of the associated order item. return_id: type: string title: return_id - description: The return item's return id. + description: The ID of the return this return item belongs to. metadata: type: object - description: The return item's metadata. + description: The return item's metadata, can hold custom key-value pairs. AdminReturnPreviewResponse: type: object - description: SUMMARY + description: The details of a return and a preview of the order once the return is applied. x-schemaName: AdminReturnPreviewResponse required: - order_preview @@ -14778,20 +14777,20 @@ components: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. AdminReturnReasonDeleteResponse: type: object - description: SUMMARY + description: The details of the return reason deletion. x-schemaName: AdminReturnReasonDeleteResponse required: - id @@ -14810,10 +14809,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Return Reason was deleted. + description: Whether the return reason was deleted. AdminReturnReasonListResponse: type: object - description: SUMMARY + description: The paginated list of return reasons. x-schemaName: AdminReturnReasonListResponse required: - limit @@ -14824,23 +14823,23 @@ components: limit: type: number title: limit - description: The return reason's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The return reason's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The return reason's count. + description: The total number of items. return_reasons: type: array - description: The return reason's return reasons. + description: The list of return reasons. items: $ref: '#/components/schemas/AdminReturnReason' AdminReturnReasonResponse: type: object - description: SUMMARY + description: The return reason's details. x-schemaName: AdminReturnReasonResponse required: - return_reason @@ -14849,7 +14848,7 @@ components: $ref: '#/components/schemas/AdminReturnReason' AdminReturnResponse: type: object - description: SUMMARY + description: The return's details. x-schemaName: AdminReturnResponse required: - return @@ -14858,50 +14857,38 @@ components: $ref: '#/components/schemas/AdminReturn' AdminRevokeApiKey: type: object - description: SUMMARY + description: The details of revoking the API key. x-schemaName: AdminRevokeApiKey properties: revoke_in: type: number title: revoke_in - description: The api key's revoke in. + description: The time in seconds to revoke the API key after. If not set, the API key is revoked immediately. AdminRuleAttributeOption: type: object - description: The attribute's attributes. + description: The details of a potential rule attribute. x-schemaName: AdminRuleAttributeOption required: - id - value - label - - field_type - - required - - disguised - operators properties: id: type: string title: id - description: The attribute's ID. + description: The rule attribute's ID, which is a rule's `attribute` it refers to. + example: customer_group value: type: string title: value - description: The attribute's value. + description: The rule attribute's value. + example: customer.groups.id label: type: string title: label - description: The attribute's label. - field_type: - type: string - title: field_type - description: The attribute's field type. - required: - type: boolean - title: required - description: The attribute's required. - disguised: - type: boolean - title: disguised - description: The attribute's disguised. + description: The rule attribute option's label. + example: Customer Group operators: type: array description: The attribute's operators. @@ -14909,28 +14896,25 @@ components: $ref: '#/components/schemas/BaseRuleOperatorOptions' AdminRuleValueOption: type: object - description: The value's values. + description: The details of a potential rule value. x-schemaName: AdminRuleValueOption required: - - id - value - label properties: - id: - type: string - title: id - description: The value's ID. value: type: string title: value - description: The value's details. + description: The rule value's value. + example: reg_123 label: type: string title: label - description: The value's label. + description: The rule value's label. + example: Europe Region AdminSalesChannel: type: object - description: The order's sales channel. + description: The sales channel's details. x-schemaName: AdminSalesChannel required: - id @@ -14957,28 +14941,28 @@ components: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The sales channel's created at. + description: The date the sales channel was created. updated_at: type: string format: date-time title: updated_at - description: The sales channel's updated at. + description: The date the sales channel was updated. deleted_at: type: string format: date-time title: deleted_at - description: The sales channel's deleted at. + description: The date the sales channel was deleted. AdminSalesChannelDeleteResponse: type: object - description: SUMMARY + description: The details of deleting a sales channel. x-schemaName: AdminSalesChannelDeleteResponse required: - id @@ -14997,10 +14981,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Sales Channel was deleted. + description: Whether the sales channel was deleted. AdminSalesChannelResponse: type: object - description: SUMMARY + description: The sales channel's details. x-schemaName: AdminSalesChannelResponse required: - sales_channel @@ -15009,7 +14993,7 @@ components: $ref: '#/components/schemas/AdminSalesChannel' AdminServiceZone: type: object - description: The service zone's service zones. + description: The shipping option's service zone. x-schemaName: AdminServiceZone required: - id @@ -15050,78 +15034,261 @@ components: type: string format: date-time title: created_at - description: The service zone's created at. + description: The service zone's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The service zone's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The service zone's deleted at. + AdminServiceZoneDeleteResponse: + type: object + description: The details of the service zone deletion. + x-schemaName: AdminServiceZoneDeleteResponse + required: + - id + - object + - deleted + properties: + id: + type: string + title: id + description: The service zone's ID. + object: + type: string + title: object + description: The name of the deleted object. + default: service_zone + deleted: + type: boolean + title: deleted + description: Whether the service zone was deleted. + parent: + $ref: '#/components/schemas/AdminFulfillmentSet' + AdminServiceZoneResponse: + type: object + description: The service zone's details. + x-schemaName: AdminServiceZoneResponse + required: + - service_zone + properties: + service_zone: + $ref: '#/components/schemas/AdminServiceZone' + AdminShippingOption: + type: object + description: The shipping option's details. + x-schemaName: AdminShippingOption + required: + - id + - name + - price_type + - service_zone_id + - service_zone + - provider_id + - provider + - shipping_option_type_id + - type + - shipping_profile_id + - shipping_profile + - rules + - prices + - data + - metadata + - created_at + - updated_at + - deleted_at + properties: + id: + type: string + title: id + description: The shipping option's ID. + name: + type: string + title: name + description: The shipping option's name. + price_type: + type: string + description: The shipping option's price type. If it's `flat`, the price is fixed and is set in the `prices` property. If it's `calculated`, the price is calculated on checkout by the associated fulfillment provider. + enum: + - calculated + - flat + service_zone_id: + type: string + title: service_zone_id + description: The ID of the service zone this option belongs to. + service_zone: + type: object + provider_id: + type: string + title: provider_id + description: The ID of the provider handling fulfillments created from this shipping option. + provider: + $ref: '#/components/schemas/AdminFulfillmentProvider' + shipping_option_type_id: + type: string + title: shipping_option_type_id + description: The ID of the associated shipping option type. + type: + type: object + shipping_profile_id: + type: string + title: shipping_profile_id + description: The ID of the associated shipping profile. + shipping_profile: + $ref: '#/components/schemas/AdminShippingProfile' + rules: + type: array + description: The shipping option's rules. + items: + $ref: '#/components/schemas/AdminShippingOptionRule' + prices: + type: array + description: The shipping option's prices. If the `price_type` is `calculated`, this array will be empty since the price is calculated by the fulfillment provider during checkout. + items: + $ref: '#/components/schemas/AdminShippingOptionPrice' + data: + type: object + description: The shipping option's data, useful for the fulfillment provider handling fulfillments created from this option. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + metadata: + type: object + description: The shipping option's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping option was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping option was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping option was deleted. + AdminShippingOptionDeleteResponse: + type: object + description: The details of the shipping option's deletion. + x-schemaName: AdminShippingOptionDeleteResponse + required: + - id + - object + - deleted + properties: + id: + type: string + title: id + description: The shipping option's ID. + object: + type: string + title: object + description: The name of the deleted object. + default: shipping_option + deleted: + type: boolean + title: deleted + description: Whether the shipping option was deleted. + AdminShippingOptionPrice: + type: object + description: The details of the shipping option's price. + x-schemaName: AdminShippingOptionPrice + required: + - price_rules + - rules_count + - id + - title + - currency_code + - amount + - raw_amount + - min_quantity + - max_quantity + - price_set_id + - created_at + - updated_at + - deleted_at + properties: + price_rules: + type: array + description: The price's rules. + items: + $ref: '#/components/schemas/AdminShippingOptionPriceRule' + rules_count: + type: number + title: rules_count + description: The number of rules the price has. + id: + type: string + title: id + description: The price's ID. + title: + type: string + title: title + description: The price's title. + currency_code: + type: string + title: currency_code + description: The price's currency code. + example: usd + amount: + type: number + title: amount + description: The price's amount. + raw_amount: + type: object + description: The price's raw amount. + min_quantity: + type: number + title: min_quantity + description: The minimum quantity required in the cart for this price to apply. + max_quantity: + type: number + title: max_quantity + description: The maximum quantity that the cart's items must not surpass for this price to apply. + price_set_id: + type: string + title: price_set_id + description: The ID of the price set this price belongs to. + created_at: + type: string + format: date-time + title: created_at + description: The date the price was created. updated_at: type: string format: date-time title: updated_at - description: The service zone's updated at. + description: The date the price was updated. deleted_at: type: string format: date-time title: deleted_at - description: The service zone's deleted at. - AdminServiceZoneDeleteResponse: - type: object - description: SUMMARY - x-schemaName: AdminServiceZoneDeleteResponse - required: - - id - - object - - deleted - properties: - id: - type: string - title: id - description: The fulfillment set's ID. - object: - type: string - title: object - description: The name of the deleted object. - deleted: - type: boolean - title: deleted - description: Whether the Fulfillment Set was deleted. - parent: - $ref: '#/components/schemas/AdminFulfillmentSet' - AdminServiceZoneResponse: - type: object - description: SUMMARY - x-schemaName: AdminServiceZoneResponse - required: - - service_zone - properties: - service_zone: - $ref: '#/components/schemas/AdminServiceZone' - AdminShippingOption: - type: object - description: The shipping option's shipping options. - x-schemaName: AdminShippingOption - AdminShippingOptionDeleteResponse: + description: The date the price was deleted. + AdminShippingOptionPriceRule: type: object - description: SUMMARY - x-schemaName: AdminShippingOptionDeleteResponse + description: The details of a shipping option price's rule. + x-schemaName: AdminShippingOptionPriceRule required: - id - - object - - deleted + - value properties: id: type: string title: id - description: The shipping option's ID. - object: + description: The price rule's ID. + value: type: string - title: object - description: The name of the deleted object. - default: shipping_option - deleted: - type: boolean - title: deleted - description: Whether the Shipping Option was deleted. + title: value + description: The price rule's value. AdminShippingOptionResponse: type: object - description: SUMMARY + description: The shipping option's details. x-schemaName: AdminShippingOptionResponse required: - shipping_option @@ -15130,7 +15297,7 @@ components: $ref: '#/components/schemas/AdminShippingOption' AdminShippingOptionRule: type: object - description: The updated's details. + description: The shipping option rule's details. x-schemaName: AdminShippingOptionRule required: - id @@ -15145,52 +15312,95 @@ components: id: type: string title: id - description: The updated's ID. + description: The shipping option rule's ID. attribute: type: string title: attribute - description: The updated's attribute. + description: The shipping option rule's attribute. + example: is_return operator: type: string title: operator - description: The updated's operator. + description: The shipping option rule's operator. + example: eq value: oneOf: - type: string title: value - description: The updated's value. + description: The rule's value. + example: '"true"' - type: array - description: The updated's value. + description: The rule's values. items: type: string title: value - description: The value's details. + description: A rule's value + example: '"true"' shipping_option_id: type: string title: shipping_option_id - description: The updated's shipping option id. + description: The ID of the shipping option this rule is for. created_at: type: string format: date-time title: created_at - description: The updated's created at. + description: The date the shipping option rule was created. updated_at: type: string format: date-time title: updated_at - description: The updated's updated at. + description: The date the shipping option rule was updated. deleted_at: type: string format: date-time title: deleted_at - description: The updated's deleted at. + description: The date the shipping option rule was deleted. AdminShippingProfile: type: object - description: The shipping option's shipping profile. + description: The shipping profile's details.. x-schemaName: AdminShippingProfile + properties: + id: + type: string + title: id + description: The shipping profile's ID. + name: + type: string + title: name + description: The shipping profile's name. + type: + type: string + title: type + description: The shipping profile's type. + metadata: + type: object + description: The shipping profile's metadata, holds custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping profile was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping profile was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the shipping profile was deleted. + required: + - id + - name + - type + - metadata + - created_at + - updated_at + - deleted_at AdminShippingProfileDeleteResponse: type: object - description: SUMMARY + description: The details of the shipping profile's deletion. x-schemaName: AdminShippingProfileDeleteResponse required: - id @@ -15209,10 +15419,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Shipping Profile was deleted. + description: Whether the shipping profile was deleted. AdminShippingProfileResponse: type: object - description: SUMMARY + description: The shipping profile's details. x-schemaName: AdminShippingProfileResponse required: - shipping_profile @@ -15221,7 +15431,7 @@ components: $ref: '#/components/schemas/AdminShippingProfile' AdminStockLocation: type: object - description: The parent's location. + description: The stock location's details. x-schemaName: AdminStockLocation required: - id @@ -15239,31 +15449,77 @@ components: address_id: type: string title: address_id - description: The location's address id. + description: The ID of the associated address. address: - $ref: '#/components/schemas/AdminStockLocationAddress' + type: object + description: The details of the stock location address. + x-schemaName: AdminStockLocationAddress + properties: + id: + type: string + title: id + description: The address's ID. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + company: + type: string + title: company + description: The address's company. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + city: + type: string + title: city + description: The address's city. + phone: + type: string + title: phone + description: The address's phone. + postal_code: + type: string + title: postal_code + description: The address's postal code. + province: + type: string + title: province + description: The address's province. + required: + - id + - address_1 + - address_2 + - company + - country_code + - city + - phone + - postal_code + - province sales_channels: type: array - description: The location's sales channels. + description: The sales channels associated with the location. items: $ref: '#/components/schemas/AdminSalesChannel' fulfillment_providers: type: array - description: The location's fulfillment providers. + description: The fulfillment providers associated with the location. items: $ref: '#/components/schemas/AdminFulfillmentProvider' fulfillment_sets: type: array - description: The location's fulfillment sets. + description: The fulfillment sets associated with the location. items: type: object - AdminStockLocationAddress: - type: object - description: The location's address. - x-schemaName: AdminStockLocationAddress AdminStockLocationDeleteResponse: type: object - description: SUMMARY + description: The details of the stock location's deletion. x-schemaName: AdminStockLocationDeleteResponse required: - id @@ -15282,10 +15538,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Stock Location was deleted. + description: Whether the stock location was deleted. AdminStockLocationListResponse: type: object - description: SUMMARY + description: The paginated list of stock locations. x-schemaName: AdminStockLocationListResponse required: - limit @@ -15296,23 +15552,23 @@ components: limit: type: number title: limit - description: The stock location's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The stock location's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The stock location's count. + description: The total number of items. stock_locations: type: array - description: The stock location's stock locations. + description: The list of stock locations. items: $ref: '#/components/schemas/AdminStockLocation' AdminStockLocationResponse: type: object - description: SUMMARY + description: The stock location's details. x-schemaName: AdminStockLocationResponse required: - stock_location @@ -15350,31 +15606,31 @@ components: default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the sales channel used by default in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the region used by default in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the stock location used by default in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The store's created at. + description: The date the store was created. updated_at: type: string format: date-time title: updated_at - description: The store's updated at. + description: The date the store was updated. AdminStoreCurrency: type: object - description: The supported currency's supported currencies. + description: The details of a store's currency. x-schemaName: AdminStoreCurrency required: - id @@ -15389,39 +15645,40 @@ components: id: type: string title: id - description: The supported currency's ID. + description: The currency's ID. currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd store_id: type: string title: store_id - description: The supported currency's store id. + description: The ID of the store this currency belongs to. is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether this currency is the default in the store. currency: $ref: '#/components/schemas/AdminCurrency' created_at: type: string format: date-time title: created_at - description: The supported currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The supported currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The supported currency's deleted at. + description: The date the currency was deleted. AdminStoreListResponse: type: object - description: SUMMARY + description: The paginated list of stores. x-schemaName: AdminStoreListResponse required: - limit @@ -15432,23 +15689,23 @@ components: limit: type: number title: limit - description: The store's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The store's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The store's count. + description: The total number of items. stores: type: array - description: The store's stores. + description: The list of stores. items: $ref: '#/components/schemas/AdminStore' AdminStoreResponse: type: object - description: SUMMARY + description: The store's details. x-schemaName: AdminStoreResponse required: - store @@ -15457,7 +15714,7 @@ components: $ref: '#/components/schemas/AdminStore' AdminTaxRate: type: object - description: The tax rate's parent. + description: The tax rate's details. x-schemaName: AdminTaxRate required: - id @@ -15478,63 +15735,66 @@ components: id: type: string title: id - description: The parent's ID. + description: The tax rate's ID. rate: type: number title: rate - description: The parent's rate. + description: The rate to charge. + example: 10 code: type: string title: code - description: The parent's code. + description: The code the tax rate is identified by. name: type: string title: name - description: The parent's name. + description: The tax rate's name. metadata: type: object - description: The parent's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. tax_region_id: type: string title: tax_region_id - description: The parent's tax region id. + description: The ID of the tax region this rate belongs to. is_combinable: type: boolean title: is_combinable - description: The parent's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates is_default: type: boolean title: is_default - description: The parent's is default. + description: Whether this tax rate is the default in the tax region. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the tax rate was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the tax rate was updated. deleted_at: type: string format: date-time title: deleted_at - description: The parent's deleted at. + description: The date the tax rate was deleted. created_by: type: string title: created_by - description: The parent's created by. + description: The ID of the user that created the tax rate. tax_region: $ref: '#/components/schemas/AdminTaxRegion' rules: type: array - description: The parent's rules. + description: The tax rate's rules. items: $ref: '#/components/schemas/AdminTaxRateRule' AdminTaxRateDeleteResponse: type: object - description: SUMMARY + description: The details of the tax rate deletion. x-schemaName: AdminTaxRateDeleteResponse required: - id @@ -15553,10 +15813,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Tax Rate was deleted. + description: Whether the tax rate was deleted. AdminTaxRateResponse: type: object - description: SUMMARY + description: The tax rate's details. x-schemaName: AdminTaxRateResponse required: - tax_rate @@ -15565,7 +15825,7 @@ components: $ref: '#/components/schemas/AdminTaxRate' AdminTaxRateRule: type: object - description: The rule's rules. + description: The tax rate rule's details. x-schemaName: AdminTaxRateRule required: - reference @@ -15574,26 +15834,22 @@ components: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of a record in the table that this rule references. + example: ptyp_1 AdminTaxRegion: type: object - description: The parent's tax region. + description: The tax region's details. x-schemaName: AdminTaxRegion required: - id - - rate - - code - country_code - province_code - - name - metadata - - tax_region_id - - is_combinable - - is_default - parent_id - created_at - updated_at @@ -15607,67 +15863,44 @@ components: type: string title: id description: The tax region's ID. - rate: - type: number - title: rate - description: The tax region's rate. - code: - type: string - title: code - description: The tax region's code. country_code: type: string title: country_code description: The tax region's country code. + example: us province_code: type: string title: province_code description: The tax region's province code. - name: - type: string - title: name - description: The tax region's name. metadata: type: object - description: The tax region's metadata. - tax_region_id: - type: string - title: tax_region_id - description: The tax region's tax region id. - is_combinable: - type: boolean - title: is_combinable - description: The tax region's is combinable. - is_default: - type: boolean - title: is_default - description: The tax region's is default. + description: The tax region's metadata, can hold custom key-value pairs. parent_id: type: string title: parent_id - description: The tax region's parent id. + description: The ID of the parent tax region. created_at: type: string format: date-time title: created_at - description: The tax region's created at. + description: The date the tax region was created. updated_at: type: string format: date-time title: updated_at - description: The tax region's updated at. + description: The date the tax region was updated. deleted_at: type: string format: date-time title: deleted_at - description: The tax region's deleted at. + description: The date the tax region was deleted. created_by: type: string title: created_by - description: The tax region's created by. + description: The ID of the user that created the tax region. tax_rates: type: array - description: The tax region's tax rates. + description: The tax region's rates. items: type: object parent: @@ -15679,7 +15912,7 @@ components: type: object AdminTaxRegionDeleteResponse: type: object - description: SUMMARY + description: The details of the tax region deletion. x-schemaName: AdminTaxRegionDeleteResponse required: - id @@ -15698,10 +15931,10 @@ components: deleted: type: boolean title: deleted - description: Whether the Tax Region was deleted. + description: Whether the tax region was deleted. AdminTaxRegionResponse: type: object - description: SUMMARY + description: The tax region's details. x-schemaName: AdminTaxRegionResponse required: - tax_region @@ -15710,7 +15943,7 @@ components: $ref: '#/components/schemas/AdminTaxRegion' AdminUpdateApiKey: type: object - description: SUMMARY + description: The details to update in an API key. x-schemaName: AdminUpdateApiKey required: - title @@ -15718,10 +15951,10 @@ components: title: type: string title: title - description: The api key's title. + description: The API key's title. AdminUpdateCollection: type: object - description: SUMMARY + description: The details to update in a collection. x-schemaName: AdminUpdateCollection properties: title: @@ -15734,10 +15967,10 @@ components: description: The collection's handle. metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. AdminUpdateCustomerGroup: type: object - description: SUMMARY + description: The details to update in a customer group. x-schemaName: AdminUpdateCustomerGroup properties: name: @@ -15746,10 +15979,10 @@ components: description: The customer group's name. metadata: type: object - description: The customer group's metadata. + description: The customer group's metadata, can hold custom key-value pairs. AdminUpdatePriceList: type: object - description: SUMMARY + description: the details to update in a price list. x-schemaName: AdminUpdatePriceList properties: title: @@ -15763,111 +15996,133 @@ components: starts_at: type: string title: starts_at - description: The price list's starts at. + description: The date the price list starts. ends_at: type: string title: ends_at - description: The price list's ends at. + description: The date the price list ends. status: - type: string + oneOf: + - type: string + description: The price list's status. + enum: + - ACTIVE + - type: string + description: The price list's status. + enum: + - DRAFT description: The price list's status. - enum: - - active - - draft type: - type: string + oneOf: + - type: string + description: The price list's type. + enum: + - SALE + - type: string + description: The price list's type. + enum: + - OVERRIDE description: The price list's type. - enum: - - sale - - override rules: type: object description: The price list's rules. + example: + customer_group_id: + - cusgrp_123 AdminUpdatePricePreference: type: object - description: SUMMARY + description: The details to update in the price preference. x-schemaName: AdminUpdatePricePreference properties: attribute: type: string title: attribute description: The price preference's attribute. + example: region_id value: type: string title: value description: The price preference's value. + example: reg_123 is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The price preference's is tax inclusive. + description: Whether prices are tax inclusive for this price preference. AdminUpdateProduct: type: object - description: The update's details. + description: The product's details. x-schemaName: AdminUpdateProduct properties: title: type: string title: title - description: The update's title. + description: The product's title. subtitle: type: string title: subtitle - description: The update's subtitle. + description: The product's subtitle. description: type: string title: description - description: The update's description. + description: The product's description. is_giftcard: type: boolean title: is_giftcard - description: The update's is giftcard. + description: Whether the product is a gift card. discountable: type: boolean title: discountable - description: The update's discountable. + description: Whether discounts can be applied on the product. images: type: array - description: The update's images. + description: The product's images. items: type: object - description: The image's images. + description: The image's details. required: - url properties: url: type: string title: url - description: The image's url. + description: The image's URL. thumbnail: type: string title: thumbnail - description: The update's thumbnail. + description: The product's thumbnail URL. handle: - type: string - title: handle - description: The update's handle. - status: - type: string - description: The update's status. - enum: - - draft - - proposed - - published - - rejected + type: string + title: handle + description: The product's unique handle. + status: + oneOf: + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + - type: string + title: status + description: The update's status. + description: The product's status. type_id: type: string title: type_id - description: The update's type id. + description: The ID of the product's type. collection_id: type: string title: collection_id - description: The update's collection id. + description: The ID of the product's collection. categories: type: array - description: The update's categories. + description: The product's categories. items: type: object - description: The category's categories. + description: The product's category. required: - id properties: @@ -15877,10 +16132,10 @@ components: description: The category's ID. tags: type: array - description: The update's tags. + description: The product's tags. items: type: object - description: The tag's tags. + description: The product's tag. required: - id properties: @@ -15890,181 +16145,22 @@ components: description: The tag's ID. options: type: array - description: The update's options. + description: The product's options. items: $ref: '#/components/schemas/AdminUpdateProductOption' variants: type: array - description: The update's variants. + description: The product's variants. You can add new variants or update existing ones, passing their IDs in the object. items: oneOf: - - type: object - description: The variant's variants. - x-schemaName: AdminCreateProductVariant - required: - - title - - prices - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: '#/components/schemas/AdminCreateProductVariantPrice' - options: - type: object - description: The variant's options. - - type: object - description: The variant's variants. - x-schemaName: AdminUpdateProductVariant - properties: - title: - type: string - title: title - description: The variant's title. - sku: - type: string - title: sku - description: The variant's sku. - ean: - type: string - title: ean - description: The variant's ean. - upc: - type: string - title: upc - description: The variant's upc. - barcode: - type: string - title: barcode - description: The variant's barcode. - hs_code: - type: string - title: hs_code - description: The variant's hs code. - mid_code: - type: string - title: mid_code - description: The variant's mid code. - allow_backorder: - type: boolean - title: allow_backorder - description: The variant's allow backorder. - manage_inventory: - type: boolean - title: manage_inventory - description: The variant's manage inventory. - variant_rank: - type: number - title: variant_rank - description: The variant's variant rank. - weight: - type: number - title: weight - description: The variant's weight. - length: - type: number - title: length - description: The variant's length. - height: - type: number - title: height - description: The variant's height. - width: - type: number - title: width - description: The variant's width. - origin_country: - type: string - title: origin_country - description: The variant's origin country. - material: - type: string - title: material - description: The variant's material. - metadata: - type: object - description: The variant's metadata. - prices: - type: array - description: The variant's prices. - items: - $ref: '#/components/schemas/AdminCreateProductVariantPrice' - options: - type: object - description: The variant's options. + - $ref: '#/components/schemas/AdminCreateProductVariant' + - $ref: '#/components/schemas/AdminUpdateProductVariant' sales_channels: type: array - description: The update's sales channels. + description: The sales channels that the product is available in. items: type: object - description: The sales channel's sales channels. + description: The sales channel's details. required: - id properties: @@ -16075,137 +16171,160 @@ components: weight: type: number title: weight - description: The update's weight. + description: The product's weight. length: type: number title: length - description: The update's length. + description: The product's length. height: type: number title: height - description: The update's height. + description: The product's height. width: type: number title: width - description: The update's width. + description: The product's width. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product's MID code. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product's origin country. material: type: string title: material - description: The update's material. + description: The product's material. metadata: type: object - description: The update's metadata. + description: The product's metadata, can hold custom key-value pairs. AdminUpdateProductOption: type: object - description: SUMMARY + description: The details to update in a product option. x-schemaName: AdminUpdateProductOption properties: title: type: string title: title - description: The product's title. + description: The option's title. values: type: array - description: The product's values. + description: The option's values. items: type: string title: values - description: The value's values. + description: An option value. AdminUpdateProductVariant: type: object - description: The update's details. + description: The properties to update of a product variant. x-schemaName: AdminUpdateProductVariant properties: title: type: string title: title - description: The update's title. + description: The product variant's title. sku: type: string title: sku - description: The update's sku. + description: The product variant's SKU. ean: type: string title: ean - description: The update's ean. + description: The product variant's EAN. upc: type: string title: upc - description: The update's upc. + description: The product variant's UPC. barcode: type: string title: barcode - description: The update's barcode. + description: The product variant's barcode. hs_code: type: string title: hs_code - description: The update's hs code. + description: The product variant's HS code. mid_code: type: string title: mid_code - description: The update's mid code. + description: The product variant's MID code. allow_backorder: type: boolean title: allow_backorder - description: The update's allow backorder. + description: Whether customers can order the variant even if it's not in stock. manage_inventory: type: boolean title: manage_inventory - description: The update's manage inventory. + description: Whether the Medusa application manages the variant's inventory. If disabled, the product variant is always considered in stock. variant_rank: type: number title: variant_rank - description: The update's variant rank. + description: The product variant's rank among its siblings. weight: type: number title: weight - description: The update's weight. + description: The product variant's weight. length: type: number title: length - description: The update's length. + description: The product variant's length. height: type: number title: height - description: The update's height. + description: The product variant's height. width: type: number title: width - description: The update's width. + description: The product variant's width. origin_country: type: string title: origin_country - description: The update's origin country. + description: The product variant's origin country. material: type: string title: material - description: The update's material. + description: The product variant's material. metadata: type: object - description: The update's metadata. + description: The product variant's metadata, can hold custom key-value pairs. prices: type: array - description: The update's prices. + description: The product variant's prices. items: $ref: '#/components/schemas/AdminCreateProductVariantPrice' options: type: object - description: The update's options. + description: The product variant's options. + AdminUpdateReturnReason: + type: object + description: The details to update in a return reason. + x-schemaName: AdminUpdateReturnReason + properties: + label: + type: string + title: label + description: The return reason's label. + value: + type: string + title: value + description: The return reason's value. + description: + type: string + title: description + description: The return reason's description. + metadata: + type: object + description: The return reason's metadata, can hold custom key-value pairs. + required: + - value + - label AdminUpdateSalesChannel: type: object - description: SUMMARY + description: The properties to update in the sales channel. x-schemaName: AdminUpdateSalesChannel properties: name: @@ -16219,13 +16338,13 @@ components: is_disabled: type: boolean title: is_disabled - description: The sales channel's is disabled. + description: Whether the sales channel is disabled. metadata: type: object - description: The sales channel's metadata. + description: The sales channel's metadata, can hold custom key-value pairs. AdminUpdateStockLocation: type: object - description: SUMMARY + description: The properties to update in a stock location. x-schemaName: AdminUpdateStockLocation properties: name: @@ -16234,7 +16353,7 @@ components: description: The stock location's name. address: type: object - description: The stock location's address. + description: The stock location's address. Pass this property if you're creating a new address to associate with the location. required: - address_1 - country_code @@ -16242,11 +16361,11 @@ components: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -16259,6 +16378,7 @@ components: type: string title: country_code description: The address's country code. + example: us phone: type: string title: phone @@ -16274,13 +16394,13 @@ components: address_id: type: string title: address_id - description: The stock location's address id. + description: The ID of an existing stock location address to associate the stock location with. metadata: type: object - description: The stock location's metadata. + description: The stock location's metadata, can hold custom key-value pairs. AdminUpdateStore: type: object - description: SUMMARY + description: The properties to update in a store. x-schemaName: AdminUpdateStore properties: name: @@ -16292,56 +16412,57 @@ components: description: The store's supported currencies. items: type: object - description: The supported currency's supported currencies. + description: A store currency. required: - currency_code properties: currency_code: type: string title: currency_code - description: The supported currency's currency code. + description: The currency's code. + example: usd is_default: type: boolean title: is_default - description: The supported currency's is default. + description: Whether the currency is the default in the store. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The supported currency's is tax inclusive. + description: Whether prices using this currency are tax inclusive. default_sales_channel_id: type: string title: default_sales_channel_id - description: The store's default sales channel id. + description: The ID of the default sales channel in the store. default_region_id: type: string title: default_region_id - description: The store's default region id. + description: The ID of the default region in the store. default_location_id: type: string title: default_location_id - description: The store's default location id. + description: The ID of the default stock location in the store. metadata: type: object - description: The store's metadata. + description: The store's metadata, can hold custom key-value pairs. AdminUpdateTaxRate: type: object - description: SUMMARY + description: The properties to update in the tax rate. x-schemaName: AdminUpdateTaxRate properties: rate: type: number title: rate - description: The tax rate's rate. + description: The rate to charge. code: type: string title: code - description: The tax rate's code. + description: The code that the tax rate is identified by. rules: type: array description: The tax rate's rules. items: type: object - description: The rule's rules. + description: A tax rate rule. required: - reference - reference_id @@ -16349,11 +16470,13 @@ components: reference: type: string title: reference - description: The rule's reference. + description: The name of the table this rule references. + example: product_type reference_id: type: string title: reference_id - description: The rule's reference id. + description: The ID of the record in the table that the rule references. + example: ptyp_123 name: type: string title: name @@ -16361,17 +16484,19 @@ components: is_default: type: boolean title: is_default - description: The tax rate's is default. + description: Whether the tax rate is the default in the store. is_combinable: type: boolean title: is_combinable - description: The tax rate's is combinable. + description: Whether the tax rate should be combined with parent rates. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/tax/tax-rates-and-rules#combinable-tax-rates metadata: type: object - description: The tax rate's metadata. + description: The tax rate's metadata, can hold custom key-value pairs. AdminUpdateUser: type: object - description: SUMMARY + description: The properties to update in a user. x-schemaName: AdminUpdateUser properties: first_name: @@ -16385,10 +16510,10 @@ components: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. AdminUpdateVariantInventoryItem: type: object - description: SUMMARY + description: The properties to update of the variant's inventory item association. x-schemaName: AdminUpdateVariantInventoryItem required: - required_quantity @@ -16396,10 +16521,10 @@ components: required_quantity: type: number title: required_quantity - description: The product's required quantity. + description: The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the value set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`. AdminUpsertStockLocationAddress: type: object - description: The stock location's address. + description: The details of the stock location address to create. x-schemaName: AdminUpsertStockLocationAddress required: - address_1 @@ -16408,11 +16533,11 @@ components: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. company: type: string title: company @@ -16421,6 +16546,7 @@ components: type: string title: country_code description: The address's country code. + example: usd city: type: string title: city @@ -16472,28 +16598,28 @@ components: avatar_url: type: string title: avatar_url - description: The user's avatar url. + description: The URL of the user's avatar. metadata: type: object - description: The user's metadata. + description: The user's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The user's created at. + description: The date the user was created. updated_at: type: string format: date-time title: updated_at - description: The user's updated at. + description: The date the user was updated. deleted_at: type: string format: date-time title: deleted_at - description: The user's deleted at. + description: The date the user was deleted. AdminUserDeleteResponse: type: object - description: SUMMARY + description: The details of the deleted user. x-schemaName: AdminUserDeleteResponse required: - id @@ -16512,10 +16638,10 @@ components: deleted: type: boolean title: deleted - description: Whether the User was deleted. + description: Whether the user was deleted. AdminUserListResponse: type: object - description: SUMMARY + description: The paginated list of users. x-schemaName: AdminUserListResponse required: - limit @@ -16526,23 +16652,23 @@ components: limit: type: number title: limit - description: The user's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The user's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The user's count. + description: The total number of items. users: type: array - description: The user's users. + description: The list of users. items: $ref: '#/components/schemas/AdminUser' AdminUserResponse: type: object - description: SUMMARY + description: The user's details. x-schemaName: AdminUserResponse required: - user @@ -16551,7 +16677,7 @@ components: $ref: '#/components/schemas/AdminUser' AdminWorkflowExecution: type: object - description: The workflows execution's workflow execution. + description: The workflows execution's details. x-schemaName: AdminWorkflowExecution required: - id @@ -16570,11 +16696,11 @@ components: workflow_id: type: string title: workflow_id - description: The workflow execution's workflow id. + description: The ID of the workflow. transaction_id: type: string title: transaction_id - description: The workflow execution's transaction id. + description: The workflow execution's transaction ID. execution: $ref: '#/components/schemas/AdminWorkflowExecutionExecution' context: @@ -16594,30 +16720,160 @@ components: type: string format: date-time title: created_at - description: The workflow execution's created at. + description: The date the workflow execution was created. updated_at: type: string format: date-time title: updated_at - description: The workflow execution's updated at. + description: The date the workflow execution was updated. deleted_at: type: string format: date-time title: deleted_at - description: The workflow execution's deleted at. + description: The date the workflow execution was deleted. AdminWorkflowExecutionExecution: type: object - description: The workflow execution's execution. + description: The workflow execution's steps details. x-schemaName: AdminWorkflowExecutionExecution required: - steps properties: steps: type: object - description: The execution's steps. + description: The execution's steps. Each object key is a step ID, and the value is the object whose properties are shown below. + required: + - id + - invoke + - definition + - compensate + - depth + - startedAt + additionalProperties: + type: object + properties: + id: + type: string + title: id + description: The step's ID. + invoke: + type: object + description: The state of the step's invokation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The invokation step's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The invokation step's state. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + definition: + type: object + description: The step's definition details. + x-schemaName: WorkflowExecutionDefinition + properties: + async: + type: boolean + title: async + description: Whether the step is async. + compensateAsync: + type: boolean + title: compensateAsync + description: Whether the compensation function of the step is async. + noCompensation: + type: boolean + title: noCompensation + description: Whether the step doesn't have a compensation function. + continueOnPermanentFailure: + type: boolean + title: continueOnPermanentFailure + description: Whether the step continues executing even if its status is changed to failed. + maxRetries: + type: number + title: maxRetries + description: The maximum number of times to retry the step. + noWait: + type: boolean + title: noWait + description: Whether the workflow shouldn't wait for the step to finish before moving to the next step. + default: false + retryInterval: + type: number + title: retryInterval + description: The interval in seconds between retry attempts when the step fails. + retryIntervalAwaiting: + type: number + title: retryIntervalAwaiting + description: The interval in seconds to retry a step even if its status is `waiting_response`. + saveResponse: + type: boolean + title: saveResponse + description: Whether the step's response is stored. + timeout: + type: number + title: timeout + description: The maximum time in seconds to wait for this step to complete. If the step exceeds this time, the step's state is changed to `timeout`, but the step continues executing. + compensate: + type: object + description: The state of the step's compensation function. + x-schemaName: WorkflowExecutionFn + properties: + state: + type: string + description: The compensation function's state. + enum: + - not_started + - invoking + - compensating + - done + - reverted + - failed + - dormant + - skipped + - skipped_failure + - timeout + status: + type: string + description: The compensation function's status. + enum: + - idle + - ok + - waiting_response + - temp_failure + - permanent_failure + required: + - state + - status + depth: + type: number + title: depth + description: The step's depth in the workflow's execution. + startedAt: + type: number + title: startedAt + description: The timestamp the step started executing. AdminWorkflowExecutionResponse: type: object - description: SUMMARY + description: The workflow execution's details. x-schemaName: AdminWorkflowExecutionResponse required: - workflow_execution @@ -16626,7 +16882,7 @@ components: $ref: '#/components/schemas/AdminWorkflowExecution' ApiKeyResponse: type: object - description: The api key's details. + description: The API key's details. x-schemaName: ApiKeyResponse required: - id @@ -16643,46 +16899,47 @@ components: id: type: string title: id - description: The api key's ID. + description: The API key's ID. token: type: string title: token - description: The api key's token. + description: The API key's token. redacted: type: string title: redacted - description: The api key's redacted. + description: The redacted form of the API key's token. This is useful when showing portion of the token. For example `sk_...123`. title: type: string title: title - description: The api key's title. + description: The API key's title. type: type: string + description: The API key's type. `secret` API keys are used for authenticating admin users, and `publishable` API key are used for storefronts and similar clients to scope requests to sales channels. enum: - secret - publishable last_used_at: type: string title: last_used_at - description: The api key's last used at. + description: The date the API key was last used. format: date-time created_by: type: string title: created_by - description: The api key's created by. + description: The ID of the user that created the API key. created_at: type: string title: created_at - description: The api key's created at. + description: The date the API key was created. format: date-time revoked_by: type: string title: revoked_by - description: The api key's revoked by. + description: The ID of the user that revoked the API key. revoked_at: type: string title: revoked_at - description: The api key's revoked at. + description: The date the API key was revoked. format: date-time AuthAdminSessionResponse: type: object @@ -16728,68 +16985,6 @@ components: title: user description: The logged-in customer. $ref: '#/components/schemas/StoreCustomer' - BaseApplicationMethod: - type: object - description: The promotion's application method. - x-schemaName: BaseApplicationMethod - required: - - id - properties: - id: - type: string - title: id - description: The application method's ID. - type: - type: string - description: The application method's type. - enum: - - fixed - - percentage - target_type: - type: string - description: The application method's target type. - enum: - - items - - shipping_methods - - order - allocation: - type: string - description: The application method's allocation. - enum: - - each - - across - value: - type: number - title: value - description: The application method's value. - currency_code: - type: string - title: currency_code - description: The application method's currency code. - max_quantity: - type: number - title: max_quantity - description: The application method's max quantity. - buy_rules_min_quantity: - type: number - title: buy_rules_min_quantity - description: The application method's buy rules min quantity. - apply_to_quantity: - type: number - title: apply_to_quantity - description: The application method's apply to quantity. - promotion: - $ref: '#/components/schemas/BasePromotion' - target_rules: - type: array - description: The application method's target rules. - items: - $ref: '#/components/schemas/BasePromotionRule' - buy_rules: - type: array - description: The application method's buy rules. - items: - $ref: '#/components/schemas/BasePromotionRule' BaseCalculatedPriceSet: type: object description: The parent's calculated price. @@ -16838,95 +17033,278 @@ components: description: The calculated price's original amount. currency_code: type: string - title: currency_code - description: The calculated price's currency code. - calculated_price: - type: object - description: The calculated price's details. - original_price: + title: currency_code + description: The calculated price's currency code. + calculated_price: + type: object + description: The calculated price's details. + properties: + id: + type: string + title: id + description: The calculated price's ID. + price_list_id: + type: string + title: price_list_id + description: The calculated price's price list id. + price_list_type: + type: string + title: price_list_type + description: The calculated price's price list type. + min_quantity: + type: number + title: min_quantity + description: The calculated price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The calculated price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity + original_price: + type: object + description: The calculated price's original price. + properties: + id: + type: string + title: id + description: The original price's ID. + price_list_id: + type: string + title: price_list_id + description: The original price's price list id. + price_list_type: + type: string + title: price_list_type + description: The original price's price list type. + min_quantity: + type: number + title: min_quantity + description: The original price's min quantity. + max_quantity: + type: number + title: max_quantity + description: The original price's max quantity. + required: + - id + - price_list_id + - price_list_type + - min_quantity + - max_quantity + BaseCapture: + type: object + description: The details of a captured payment. + x-schemaName: BaseCapture + required: + - id + - amount + - created_at + - payment + properties: + id: + type: string + title: id + description: The payment capture's ID. + amount: + type: number + title: amount + description: The captured amount. + created_at: + type: string + format: date-time + title: created_at + description: The date the capture was created. + created_by: + type: string + title: created_by + description: The ID of the user that captured the payment. + payment: type: object - description: The calculated price's original price. - BaseCapture: - type: object - description: The capture's captures. - x-schemaName: BaseCapture BaseCart: type: object description: The item's cart. x-schemaName: BaseCart - BaseCartAddress: - type: object - description: The parent's billing address. - x-schemaName: BaseCartAddress required: - id - - created_at - - updated_at + - currency_code + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total properties: id: type: string title: id - description: The billing address's ID. + description: The cart's ID. + region: + $ref: '#/components/schemas/BaseRegion' + region_id: + type: string + title: region_id + description: The cart's region id. customer_id: type: string title: customer_id - description: The billing address's customer id. - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: - type: string - title: last_name - description: The billing address's last name. - phone: - type: string - title: phone - description: The billing address's phone. - company: - type: string - title: company - description: The billing address's company. - address_1: - type: string - title: address_1 - description: The billing address's address 1. - address_2: - type: string - title: address_2 - description: The billing address's address 2. - city: - type: string - title: city - description: The billing address's city. - country_code: + description: The cart's customer id. + sales_channel_id: type: string - title: country_code - description: The billing address's country code. - province: + title: sales_channel_id + description: The cart's sales channel id. + email: type: string - title: province - description: The billing address's province. - postal_code: + title: email + description: The cart's email. + format: email + currency_code: type: string - title: postal_code - description: The billing address's postal code. + title: currency_code + description: The cart's currency code. + shipping_address: + $ref: '#/components/schemas/BaseCartAddress' + billing_address: + $ref: '#/components/schemas/BaseCartAddress' + items: + type: array + description: The cart's items. + items: + $ref: '#/components/schemas/BaseCartLineItem' + shipping_methods: + type: array + description: The cart's shipping methods. + items: + $ref: '#/components/schemas/BaseCartShippingMethod' + payment_collection: + $ref: '#/components/schemas/BasePaymentCollection' metadata: type: object - description: The billing address's metadata. + description: The cart's metadata. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The cart's created at. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. + description: The cart's updated at. + original_item_total: + type: number + title: original_item_total + description: The cart's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The cart's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The cart's original item tax total. + item_total: + type: number + title: item_total + description: The cart's item total. + item_subtotal: + type: number + title: item_subtotal + description: The cart's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The cart's item tax total. + original_total: + type: number + title: original_total + description: The cart's original total. + original_subtotal: + type: number + title: original_subtotal + description: The cart's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The cart's original tax total. + total: + type: number + title: total + description: The cart's total. + subtotal: + type: number + title: subtotal + description: The cart's subtotal. + tax_total: + type: number + title: tax_total + description: The cart's tax total. + discount_total: + type: number + title: discount_total + description: The cart's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The cart's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The cart's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The cart's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The cart's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The cart's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The cart's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The cart's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The cart's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The cart's original shipping tax total. + BaseCartAddress: + type: object + description: The cart's shipping address. + x-schemaName: BaseCartAddress BaseCartLineItem: type: object - description: The item's items. + description: The tax line's item. x-schemaName: BaseCartLineItem required: - id @@ -16967,17 +17345,9 @@ components: title: thumbnail description: The item's thumbnail. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: quantity + description: The item's quantity. product: $ref: '#/components/schemas/BaseProduct' product_id: @@ -17042,34 +17412,18 @@ components: title: is_tax_inclusive description: The item's is tax inclusive. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: compare_at_unit_price + description: The item's compare at unit price. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: unit_price + description: The item's unit price. tax_lines: type: array description: The item's tax lines. items: - $ref: '#/components/schemas/BaseLineItemTaxLine' + type: object adjustments: type: array description: The item's adjustments. @@ -17100,140 +17454,52 @@ components: title: deleted_at description: The item's deleted at. original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The item's original total. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The item's original subtotal. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The item's original tax total. item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_total + description: The item's item total. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_subtotal + description: The item's item subtotal. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_tax_total + description: The item's item tax total. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The item's total. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The item's subtotal. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The item's tax total. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: '#/components/schemas/IBigNumber' - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The item's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The item's discount tax total. BaseCartShippingMethod: type: object - description: The shipping method's shipping methods. + description: A cart's shipping method. x-schemaName: BaseCartShippingMethod required: - id @@ -17259,7 +17525,7 @@ components: cart_id: type: string title: cart_id - description: The shipping method's cart id. + description: The ID of the cart this shipping method belongs to. name: type: string title: name @@ -17269,31 +17535,25 @@ components: title: description description: The shipping method's description. amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: amount + description: The shipping method's amount. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount is tax inclusive. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: The shipping method's data, useful for fulfillment handling by third-party services. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -17301,335 +17561,703 @@ components: $ref: '#/components/schemas/BaseShippingMethodTaxLine' adjustments: type: array - description: The shipping method's adjustments. + description: The shipping method's adjustments, such as applied promotions. items: $ref: '#/components/schemas/BaseShippingMethodAdjustment' created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The total taxes applied on the shipping method's amount including promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The shipping method's total amount including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The total taxes applied on the shipping method's amount including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The total amount discounted. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - BaseClaim: - type: object - description: The order change's claim. - x-schemaName: BaseClaim + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. BaseClaimItem: type: object - description: The claim item's claim items. - x-schemaName: BaseClaimItem + description: The claim item's details. + x-schemaName: BaseClaimItem + required: + - id + - claim_id + - order_id + - item_id + - quantity + - reason + - raw_quantity + properties: + id: + type: string + title: id + description: The claim item's ID. + claim_id: + type: string + title: claim_id + description: The ID of the claim this item belongs to. + order_id: + type: string + title: order_id + description: The ID of the order this item belongs to. + item_id: + type: string + title: item_id + description: The ID of the item in the order. + quantity: + type: number + title: quantity + description: The quantity claimed. + reason: + type: string + description: The claim's reason. + enum: + - missing_item + - wrong_item + - production_failure + - other + raw_quantity: + type: object + description: The quantity claimed. + properties: + value: + oneOf: + - type: string + title: value + description: The raw quantity's value. + - type: number + title: value + description: The raw quantity's value. + required: + - value + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the claim was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the claim was updated. + BaseCollection: + type: object + description: The collection's details. + x-schemaName: BaseCollection + BaseCustomer: + type: object + description: The customer's details. + x-schemaName: BaseCustomer + required: + - id + - email + - default_billing_address_id + - default_shipping_address_id + - company_name + - first_name + - last_name + - addresses + properties: + id: + type: string + title: id + description: The customer's ID. + email: + type: string + title: email + description: The customer's email. + format: email + default_billing_address_id: + type: string + title: default_billing_address_id + description: The ID of the address used as the default billing address. + default_shipping_address_id: + type: string + title: default_shipping_address_id + description: The ID of the address used as the default shipping address. + company_name: + type: string + title: company_name + description: The customer's company name. + first_name: + type: string + title: first_name + description: The customer's first name. + last_name: + type: string + title: last_name + description: The customer's last name. + addresses: + type: array + description: The customer's addresses. + items: + $ref: '#/components/schemas/BaseCustomerAddress' + phone: + type: string + title: phone + description: The customer's phone. + metadata: + type: object + description: The customer's metadata, used to store custom key-value pairs. + created_by: + type: string + title: created_by + description: The ID of the user that created this customer, if available. + created_at: + type: string + format: date-time + title: created_at + description: The customer's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The customer's update date. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The customer's deletion date. + BaseCustomerAddress: + type: object + description: The customer's address. + x-schemaName: BaseCustomerAddress + required: + - id + - address_name + - is_default_shipping + - is_default_billing + - customer_id + - company + - first_name + - last_name + - address_1 + - address_2 + - city + - country_code + - province + - postal_code + - phone + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The address's ID. + address_name: + type: string + title: address_name + description: The address's name. + is_default_shipping: + type: boolean + title: is_default_shipping + description: Whether the address is the default shipping address. + is_default_billing: + type: boolean + title: is_default_billing + description: Whether the address is the default billing address. + customer_id: + type: string + title: customer_id + description: The ID of the customer that this address belongs to. + company: + type: string + title: company + description: The customer's company. + first_name: + type: string + title: first_name + description: The customer's first name. + last_name: + type: string + title: last_name + description: The customer's last name. + address_1: + type: string + title: address_1 + description: The address's first line. + address_2: + type: string + title: address_2 + description: The address's second line. + city: + type: string + title: city + description: The address's city. + country_code: + type: string + title: country_code + description: The address's country code. + example: us + province: + type: string + title: province + description: The address's province. + postal_code: + type: string + title: postal_code + description: The address's postal code. + phone: + type: string + title: phone + description: The address's phone. + metadata: + type: object + description: The address's metadata, used to store custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The address's creation date. + updated_at: + type: string + format: date-time + title: updated_at + description: The address's update date. + BaseExchangeItem: + type: object + description: The item's details. + x-schemaName: BaseExchangeItem required: - id - - claim_id + - exchange_id - order_id - item_id - quantity - - reason - - raw_quantity + - created_at + - updated_at properties: id: type: string title: id - description: The claim item's ID. - claim_id: + description: The item's ID. + exchange_id: type: string - title: claim_id - description: The claim item's claim id. + title: exchange_id + description: The ID of the exchange this item belongs to. order_id: type: string title: order_id - description: The claim item's order id. + description: The ID of the order this item belongs to. item_id: type: string title: item_id - description: The claim item's item id. + description: The ID of the item in the order. quantity: type: number title: quantity - description: The claim item's quantity. - reason: - type: string - description: The claim item's reason. - enum: - - missing_item - - wrong_item - - production_failure - - other - raw_quantity: - type: object - description: The claim item's raw quantity. + description: The item's quantity. metadata: type: object - description: The claim item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The claim item's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The claim item's updated at. - BaseCollection: - type: object - description: The product's collection. - x-schemaName: BaseCollection - BaseCustomer: + description: The date the item was updated. + BaseLineItemAdjustment: type: object - description: The customer's details. - x-schemaName: BaseCustomer - required: - - id - - email - - default_billing_address_id - - default_shipping_address_id - - company_name - - first_name - - last_name - - addresses + description: The adjustment's details. + x-schemaName: BaseLineItemAdjustment properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies on. id: type: string title: id - description: The customer's ID. - email: + description: The adjustment's ID. + code: type: string - title: email - description: The customer's email. - format: email - default_billing_address_id: + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: type: string - title: default_billing_address_id - description: The ID of the address used as the default billing address. - default_shipping_address_id: + title: cart_id + description: The ID of the cart this adjustment belongs to. + description: type: string - title: default_shipping_address_id - description: The ID of the address used as the default shipping address. - company_name: + title: description + description: The adjustment's description. + promotion_id: type: string - title: company_name - description: The customer's company name. - first_name: + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: type: string - title: first_name - description: The customer's first name. - last_name: + title: provider_id + description: The adjustment's provider ID. + created_at: type: string - title: last_name - description: The customer's last name. - addresses: - type: array - description: The customer's addresses. - items: - $ref: '#/components/schemas/BaseCustomerAddress' - phone: + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: type: string - title: phone - description: The customer's phone. - metadata: - type: object - description: The customer's metadata, used to store custom key-value pairs. - created_by: + format: date-time + title: updated_at + description: The date the adjustment was updated. + required: + - item + - item_id + - id + - amount + - cart_id + - created_at + - updated_at + BaseLineItemTaxLine: + type: object + description: The tax line's details + x-schemaName: BaseLineItemTaxLine + properties: + item: + $ref: '#/components/schemas/BaseCartLineItem' + item_id: type: string - title: created_by - description: The ID of the user that created this customer, if available. + title: item_id + description: The ID of the item the tax line applies on. + total: + type: number + title: total + description: The item's total, including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's subtotal excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the associated tax rate. + code: + type: string + title: code + description: The code the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider. created_at: type: string format: date-time title: created_at - description: The customer's creation date. + description: The date the tax line was created. updated_at: type: string format: date-time title: updated_at - description: The customer's update date. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The customer's deletion date. - BaseCustomerAddress: - type: object - description: The address's addresses. - x-schemaName: BaseCustomerAddress - BaseExchangeItem: + description: The date the tax line was updated. + required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at + BaseOrder: type: object - description: The additional item's additional items. - x-schemaName: BaseExchangeItem + description: The order's details. + x-schemaName: BaseOrder required: + - payment_collections - id - - exchange_id - - order_id - - item_id - - quantity + - version + - region_id + - customer_id + - sales_channel_id + - email + - currency_code + - items + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata - created_at - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total properties: + payment_collections: + type: array + description: The order's payment collections. + items: + $ref: '#/components/schemas/AdminPaymentCollection' + fulfillments: + type: array + description: The order's fulfillments. + items: + $ref: '#/components/schemas/BaseOrderFulfillment' + sales_channel: + $ref: '#/components/schemas/AdminSalesChannel' + customer: + $ref: '#/components/schemas/AdminCustomer' + shipping_address: + $ref: '#/components/schemas/AdminOrderAddress' + billing_address: + $ref: '#/components/schemas/AdminOrderAddress' id: type: string - title: id - description: The additional item's ID. - exchange_id: + title: id + description: The order's ID. + version: + type: number + title: version + description: The order's version. + region_id: + type: string + title: region_id + description: The ID of the region associated with the order. + customer_id: type: string - title: exchange_id - description: The additional item's exchange id. - order_id: + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: type: string - title: order_id - description: The additional item's order id. - item_id: + title: sales_channel_id + description: The ID of the sales channel the order is placed in. + email: type: string - title: item_id - description: The additional item's item id. - quantity: + title: email + description: The email of the customer that placed the order. + format: email + currency_code: + type: string + title: currency_code + description: The order's currency code. + display_id: type: number - title: quantity - description: The additional item's quantity. + title: display_id + description: The order's display ID. + items: + type: array + description: The order's items. + items: + $ref: '#/components/schemas/BaseOrderLineItem' + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: '#/components/schemas/BaseOrderShippingMethod' + payment_status: + type: string + description: The order's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillment_status: + type: string + description: The order's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The order's transactions. + items: + $ref: '#/components/schemas/BaseOrderTransaction' + summary: + $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object - description: The additional item's metadata. + description: The order's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The additional item's created at. + description: The date the order was created. updated_at: type: string format: date-time title: updated_at - description: The additional item's updated at. - BaseFulfillmentProvider: - type: object - description: The shipping option's provider. - x-schemaName: BaseFulfillmentProvider - required: - - id - - is_enabled - properties: - id: - type: string - title: id - description: The provider's ID. - is_enabled: - type: boolean - title: is_enabled - description: The provider's is enabled. - BaseLineItemAdjustment: - type: object - description: The adjustment's adjustments. - x-schemaName: BaseLineItemAdjustment - BaseLineItemTaxLine: - type: object - description: The tax line's tax lines. - x-schemaName: BaseLineItemTaxLine - BaseOrder: - type: object - description: The order change's order. - x-schemaName: BaseOrder + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the order's items including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The total of the order's items excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the order's items excluding promotions. + item_total: + type: number + title: item_total + description: The total of the order's items including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The total of the order's items excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order's items including promotions. + original_total: + type: number + title: original_total + description: The order's total excluding promotions, including taxes. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The order's tax total, excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The order's tax total including promotions. + discount_total: + type: number + title: discount_total + description: The order's discount or promotions total. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total of order's discount or promotion. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The tax total of the order's gift card. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The tax total of the order's shipping. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The tax total of the order's shipping excluding promotions. BaseOrderAddress: type: object - description: The exchange's billing address. + description: An order address x-schemaName: BaseOrderAddress required: - id @@ -17640,215 +18268,153 @@ components: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer this address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us + country: + $ref: '#/components/schemas/AdminRegionCountry' province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. - BaseOrderChange: + description: The date the address was updated. + BaseOrderChangeAction: type: object - description: The order preview's order change. - x-schemaName: BaseOrderChange - required: - - id - - order_id - - actions - - status - - requested_by - - requested_at - - confirmed_by - - confirmed_at - - declined_by - - declined_reason - - metadata - - declined_at - - canceled_by - - canceled_at - - created_at - - updated_at - - version - - return_id - - exchange_id - - claim_id - - order - - return_order - - exchange - - claim + description: The action's actions. + x-schemaName: BaseOrderChangeAction properties: + order_change: + $ref: '#/components/schemas/AdminOrderChange' id: type: string title: id - description: The order change's ID. - order_id: + description: The action's ID. + order_change_id: type: string - title: order_id - description: The order change's order id. - actions: - type: array - description: The order change's actions. - items: - $ref: '#/components/schemas/BaseOrderChangeAction' - status: - type: string - title: status - description: The order change's status. - requested_by: - type: string - title: requested_by - description: The order change's requested by. - requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time - confirmed_by: + title: order_change_id + description: The ID of the order change this action belongs to. + order_id: type: string - title: confirmed_by - description: The order change's confirmed by. - confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time - declined_by: + title: order_id + description: The ID of the associated order. + reference: type: string - title: declined_by - description: The order change's declined by. - declined_reason: + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: type: string - title: declined_reason - description: The order change's declined reason. - metadata: + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + title: action + description: The applied action. + details: type: object - description: The order change's metadata. - declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time - canceled_by: + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: type: string - title: canceled_by - description: The order change's canceled by. - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time + title: internal_note + description: A note viewed only by admin users. created_at: type: string format: date-time title: created_at - description: The order change's created at. + description: The date the order change action was created. updated_at: type: string format: date-time title: updated_at - description: The order change's updated at. - version: - type: number - title: version - description: The order change's version. - change_type: - type: string - description: The order change's change type. - enum: - - return - - exchange - - claim - - edit - - return_request + description: The date the order change action was updated. return_id: type: string title: return_id - description: The order change's return id. - exchange_id: - type: string - title: exchange_id - description: The order change's exchange id. + description: The ID of the associated return. claim_id: type: string title: claim_id - description: The order change's claim id. + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. order: $ref: '#/components/schemas/BaseOrder' - return_order: {} - exchange: {} - claim: - $ref: '#/components/schemas/BaseClaim' - BaseOrderChangeAction: - type: object - description: The action's actions. - x-schemaName: BaseOrderChangeAction + required: + - order_change + - id + - order_change_id + - order_id + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at + - return_id + - claim_id + - exchange_id + - order BaseOrderFulfillment: type: object description: The fulfillment's fulfillments. @@ -17874,55 +18440,129 @@ components: location_id: type: string title: location_id - description: The fulfillment's location id. + description: The ID of the location the items are fulfilled from. packed_at: type: string title: packed_at - description: The fulfillment's packed at. + description: The date the items were packed. format: date-time shipped_at: type: string title: shipped_at - description: The fulfillment's shipped at. + description: The date the items were shipped. format: date-time delivered_at: type: string title: delivered_at - description: The fulfillment's delivered at. + description: The date the items were delivered. format: date-time canceled_at: type: string title: canceled_at - description: The fulfillment's canceled at. + description: The date the items were canceled. format: date-time data: type: object - description: The fulfillment's data. + description: Data useful for the fulfillment provider handling it. This is taken from the associated shipping option. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property provider_id: type: string title: provider_id - description: The fulfillment's provider id. + description: The ID of the fulfillment provider used to handle the fulfillment. shipping_option_id: type: string title: shipping_option_id - description: The fulfillment's shipping option id. + description: The ID of the associated shipping option. metadata: type: object - description: The fulfillment's metadata. + description: The fulfillment's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The fulfillment's created at. + description: The date the fulfillment was created. updated_at: type: string format: date-time title: updated_at - description: The fulfillment's updated at. + description: The date the fulfillment was updated. BaseOrderItemDetail: type: object description: The item's detail. x-schemaName: BaseOrderItemDetail + required: + - id + - item_id + - item + - quantity + - fulfilled_quantity + - delivered_quantity + - shipped_quantity + - return_requested_quantity + - return_received_quantity + - return_dismissed_quantity + - written_off_quantity + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: the detail's ID. + item_id: + type: string + title: id + description: the ID of the associated line item. + item: + $ref: '#/components/schemas/BaseOrderLineItem' + quantity: + type: number + title: quantity + description: The item's quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + delivered_quantity: + type: number + title: fulfilled_quantity + description: The item's delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + return_received_quantity: + type: number + title: return_received_quantity + description: The item's quantity that's returned and added to the underlying variant's stocked quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: The item's quantity that's returned but damaged. So, it's not added to the underlying variant's stocked quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed from the order. + metadata: + type: object + title: metadata + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the detail was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the detail was updated. BaseOrderLineItem: type: object description: The item's items. @@ -17982,19 +18622,19 @@ components: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The URL of the item's thumbnail. variant: $ref: '#/components/schemas/BaseProductVariant' variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated variant. product: $ref: '#/components/schemas/BaseProduct' product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -18014,7 +18654,7 @@ components: product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the collection the item's product belongs to. product_handle: type: string title: product_handle @@ -18022,7 +18662,7 @@ components: variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -18033,23 +18673,25 @@ components: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The values of the item variant's options. + example: + Color: Blue requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item is tax inclusive. compare_at_unit_price: type: number title: compare_at_unit_price - description: The item's compare at unit price. + description: The original price of the item before a promotion or sale. unit_price: type: number title: unit_price @@ -18074,78 +18716,233 @@ components: type: string format: date-time title: created_at - description: The item's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The item's updated at. + description: The date the item was updated. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. original_total: type: number title: original_total - description: The item's original total. + description: The item's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The item's original subtotal. + description: The item's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The item's original tax total. + description: The total taxes of the item, excluding promotions. item_total: type: number title: item_total - description: The item's item total. + description: The total taxes of the item, including promotions. item_subtotal: type: number title: item_subtotal - description: The item's item subtotal. + description: The item's total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The item's item tax total. + description: The total taxes of the item, including promotions. total: type: number title: total - description: The item's total. + description: The item's total, including taxes and promotions. subtotal: type: number title: subtotal - description: The item's subtotal. + description: The item's subtotal excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The item's tax total. + description: The tax total of the item including promotions. discount_total: type: number title: discount_total - description: The item's discount total. + description: The total discount amount of the item. discount_tax_total: type: number title: discount_tax_total - description: The item's discount tax total. + description: The total taxes applied on the discounted amount. refundable_total: type: number title: refundable_total - description: The item's refundable total. + description: The total refundable amount of the item's total. refundable_total_per_unit: type: number title: refundable_total_per_unit - description: The item's refundable total per unit. + description: The total refundable amount of the item's total for a single quantity. BaseOrderLineItemAdjustment: type: object - description: The adjustment's adjustments. + description: The adjustment's details. x-schemaName: BaseOrderLineItemAdjustment + properties: + item: + $ref: '#/components/schemas/BaseOrderLineItem' + item_id: + type: string + title: item_id + description: The ID of the item this adjustment applies to. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion that this applies on the order's item. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. + required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at BaseOrderLineItemTaxLine: type: object description: The tax line's tax lines. x-schemaName: BaseOrderLineItemTaxLine + properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the associated line item. + total: + type: number + title: total + description: The tax line's total including promotions. + subtotal: + type: number + title: subtotal + description: The tax line's subtotal excluding promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax line. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. + required: + - item + - item_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at + BaseOrderShippingDetail: + type: object + description: The shipping method's detail. + x-schemaName: BaseOrderShippingDetail + required: + - id + - shipping_method_id + - shipping_method + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The detail's ID. + shipping_method_id: + type: string + title: shipping_method_id + description: The detail's shipping method id. + shipping_method: + $ref: '#/components/schemas/BaseOrderShippingMethod' + claim_id: + type: string + title: claim_id + description: The detail's claim id. + exchange_id: + type: string + title: exchange_id + description: The detail's exchange id. + return_id: + type: string + title: return_id + description: The detail's return id. + created_at: + type: string + format: date-time + title: created_at + description: The detail's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The detail's updated at. BaseOrderShippingMethod: type: object - description: The shipping method's shipping methods. + description: The shipping method's details. x-schemaName: BaseOrderShippingMethod required: - id @@ -18174,7 +18971,7 @@ components: order_id: type: string title: order_id - description: The shipping method's order id. + description: The ID of the order the shipping method belongs to. name: type: string title: name @@ -18190,17 +18987,19 @@ components: is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The shipping method's is tax inclusive. + description: Whether the shipping method's amount includes applied taxes. shipping_option_id: type: string title: shipping_option_id - description: The shipping method's shipping option id. + description: The ID of the shipping option this method was created from. data: type: object - description: The shipping method's data. + description: The shipping method's data, useful for fulfillment provider handling its fulfillment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property metadata: type: object - description: The shipping method's metadata. + description: The shipping method's metadata, can hold custom key-value pairs. tax_lines: type: array description: The shipping method's tax lines. @@ -18212,122 +19011,172 @@ components: items: $ref: '#/components/schemas/BaseOrderShippingMethodAdjustment' original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The shipping method's total taxes excluding promotions. total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The shipping method's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The shipping method's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The total discounts applied on the shipping method. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_tax_total + description: The taxes applied on the discount amount. created_at: type: string format: date-time title: created_at - description: The shipping method's created at. + description: The date the shipping method was created. updated_at: type: string format: date-time title: updated_at - description: The shipping method's updated at. + description: The date the shipping method was updated. + detail: + $ref: '#/components/schemas/BaseOrderShippingDetail' BaseOrderShippingMethodAdjustment: type: object description: The adjustment's adjustments. x-schemaName: BaseOrderShippingMethodAdjustment + properties: + shipping_method: + $ref: '#/components/schemas/BaseOrderShippingMethod' + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment applies on. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. + required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at BaseOrderShippingMethodTaxLine: type: object - description: The tax line's tax lines. + description: The tax line's details. x-schemaName: BaseOrderShippingMethodTaxLine + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this tax line belongs to. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider handling the tax calculation. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. + required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at BaseOrderSummary: type: object - description: The order's summary. + description: The order's summary details. x-schemaName: BaseOrderSummary required: - total @@ -18338,77 +19187,52 @@ components: - returned_total - return_request_total - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - paid_total - refunded_total properties: total: type: number title: total - description: The summary's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The summary's subtotal. + description: The order's total excluding taxes, including promotions. total_tax: type: number title: total_tax - description: The summary's total tax. + description: The order's total taxes. ordered_total: type: number title: ordered_total - description: The summary's ordered total. + description: The order's total when it was placed. fulfilled_total: type: number title: fulfilled_total - description: The summary's fulfilled total. + description: The total of the fulfilled items of the order. returned_total: type: number title: returned_total - description: The summary's returned total. + description: The total of the order's returned items. return_request_total: type: number title: return_request_total - description: The summary's return request total. + description: The total of the items requested to be returned. write_off_total: type: number title: write_off_total - description: The summary's write off total. - projected_total: - type: number - title: projected_total - description: The summary's projected total. - net_total: - type: number - title: net_total - description: The summary's net total. - net_subtotal: - type: number - title: net_subtotal - description: The summary's net subtotal. - net_total_tax: - type: number - title: net_total_tax - description: The summary's net total tax. - balance: - type: number - title: balance - description: The summary's balance. + description: The total of the items removed from the order. paid_total: type: number title: paid_total - description: The summary's paid total. + description: The total amount paid. refunded_total: type: number title: refunded_total - description: The summary's refunded total. + description: The total amount refunded. BaseOrderTransaction: type: object - description: The transaction's transactions. + description: An order transaction's details. x-schemaName: BaseOrderTransaction required: - id @@ -18428,7 +19252,7 @@ components: order_id: type: string title: order_id - description: The transaction's order id. + description: The ID of the order this transaction belongs to. amount: type: number title: amount @@ -18437,34 +19261,127 @@ components: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: The name of a table that this transaction references. If this transaction is for captured payment, its value is `capture`. If this transaction is for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. metadata: type: object - description: The transaction's metadata. + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. + description: The date that the transaction was updated. BasePayment: type: object - description: The payment's payments. + description: The payment's details. x-schemaName: BasePayment + required: + - id + - amount + - currency_code + - provider_id + properties: + id: + type: string + title: id + description: The payment's ID. + amount: + type: number + title: amount + description: The payment's amount. + authorized_amount: + type: number + title: authorized_amount + description: The amount authorized of the payment. + currency_code: + type: string + title: currency_code + description: The payment's currency code. + provider_id: + type: string + title: provider_id + description: The ID of the payment provider used to process this payment. + cart_id: + type: string + title: cart_id + description: The ID of the associated cart. + order_id: + type: string + title: order_id + description: The ID of the associated order. + order_edit_id: + type: string + title: order_edit_id + description: The ID of the associated order edit. + customer_id: + type: string + title: customer_id + description: ID of the associated customer. + data: + type: object + description: The payment's data, useful for processing by the payment provider. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment#whats-a-payment + created_at: + type: string + format: date-time + title: created_at + description: The date the payment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the payment was updated. + captured_at: + type: string + format: date-time + title: captured_at + description: The date the payment was captured. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the payment was canceled. + captured_amount: + type: number + title: captured_amount + description: The captured amount of the payment. + refunded_amount: + type: number + title: captured_amount + description: The refunded amount of the payment. + captures: + type: array + description: The details of payment captures. + items: + $ref: '#/components/schemas/BaseCapture' + refunds: + type: array + description: The details of payment refunds. + items: + $ref: '#/components/schemas/BaseRefund' + payment_collection: + $ref: '#/components/schemas/BasePaymentCollection' + payment_session: + type: object BasePaymentCollection: type: object - description: The payment collection's payment collections. + description: The payment collection's details. x-schemaName: BasePaymentCollection required: - id @@ -18485,77 +19402,41 @@ components: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -18567,7 +19448,7 @@ components: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: The payment provider used to process the collection's payments and sessions. items: $ref: '#/components/schemas/BasePaymentProvider' payment_sessions: @@ -18584,10 +19465,72 @@ components: type: object description: The payment provider's payment providers. x-schemaName: BasePaymentProvider + required: + - id + properties: + id: + type: string + title: id + description: The payment provider's ID. BasePaymentSession: type: object - description: The payment session's payment sessions. + description: The payment session's details. x-schemaName: BasePaymentSession + properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: The payment session's data, useful for the payment provider processing the payment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: '#/components/schemas/BasePayment' + required: + - id + - amount + - currency_code + - provider_id + - data + - status BaseProduct: type: object description: The parent's product. @@ -18717,100 +19660,260 @@ components: $ref: '#/components/schemas/BaseProductVariant' options: type: array - description: The product's options. - items: - $ref: '#/components/schemas/BaseProductOption' - images: - type: array - description: The product's images. + description: The product's options. + items: + $ref: '#/components/schemas/BaseProductOption' + images: + type: array + description: The product's images. + items: + $ref: '#/components/schemas/BaseProductImage' + discountable: + type: boolean + title: discountable + description: The product's discountable. + external_id: + type: string + title: external_id + description: The product's external id. + created_at: + type: string + format: date-time + title: created_at + description: The product's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The product's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The product's deleted at. + metadata: + type: object + description: The product's metadata. + BaseProductCategory: + type: object + description: The category's categories. + x-schemaName: BaseProductCategory + BaseProductImage: + type: object + description: The image's details. + x-schemaName: BaseProductImage + properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's URL. + created_at: + type: string + format: date-time + title: created_at + description: The date the image was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the image was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the image was deleted. + metadata: + type: object + description: The image's metadata, can hold custom key-value pairs. + required: + - id + - url + BaseProductOption: + type: object + description: The product option's details. + x-schemaName: BaseProductOption + properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + $ref: '#/components/schemas/BaseProduct' + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: '#/components/schemas/BaseProductOptionValue' + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. + required: + - id + - title + BaseProductOptionValue: + type: object + description: The product option value's details. + x-schemaName: BaseProductOptionValue + BaseProductTag: + type: object + description: The tag's tags. + x-schemaName: BaseProductTag + BaseProductVariant: + type: object + description: The product variant's details. + x-schemaName: BaseProductVariant + required: + - id + - title + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory + - hs_code + - origin_country + - mid_code + - material + - weight + - length + - height + - width + - options + - created_at + - updated_at + - deleted_at + properties: + id: + type: string + title: id + description: The variant's ID. + title: + type: string + title: title + description: The variant's title. + sku: + type: string + title: sku + description: The variant's SKU. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's EAN code. + upc: + type: string + title: upc + description: The variant's UPC. + allow_backorder: + type: boolean + title: allow_backorder + description: Whether the variant can be ordered even if it's out of stock. + manage_inventory: + type: boolean + title: manage_inventory + description: Whether the Medusa application manages the variant's inventory quantity and availablility. If disabled, the variant is always considered in stock. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. This is only included if you pass in the `fields` query parameter a `+variants.inventory_quantity` parameter. + hs_code: + type: string + title: hs_code + description: The variant's HS code. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + mid_code: + type: string + title: mid_code + description: The variant's MID code. + material: + type: string + title: material + description: The variant's material. + weight: + type: number + title: weight + description: The variant's weight. + length: + type: number + title: length + description: The variant's length. + height: + type: number + title: height + description: The variant's height. + width: + type: number + title: width + description: The variant's width. + variant_rank: + type: number + title: variant_rank + description: The variant's rank among its sibling variants. + options: + type: array + description: The variant's option values. items: - $ref: '#/components/schemas/BaseProductImage' - discountable: - type: boolean - title: discountable - description: The product's discountable. - external_id: + $ref: '#/components/schemas/BaseProductOptionValue' + product: + type: object + product_id: type: string - title: external_id - description: The product's external id. + title: product_id + description: The ID of the product that the variant belongs to. + calculated_price: + $ref: '#/components/schemas/BaseCalculatedPriceSet' created_at: type: string format: date-time title: created_at - description: The product's created at. + description: The date the variant was created. updated_at: type: string format: date-time title: updated_at - description: The product's updated at. + description: The date the variant was updated. deleted_at: type: string format: date-time title: deleted_at - description: The product's deleted at. - metadata: - type: object - description: The product's metadata. - BaseProductCategory: - type: object - description: The category's categories. - x-schemaName: BaseProductCategory - BaseProductImage: - type: object - description: The image's images. - x-schemaName: BaseProductImage - BaseProductOption: - type: object - description: The option's options. - x-schemaName: BaseProductOption - BaseProductOptionValue: - type: object - description: The option's options. - x-schemaName: BaseProductOptionValue - required: - - id - - value - properties: - id: - type: string - title: id - description: The option's ID. - value: - type: string - title: value - description: The option's value. - option: - $ref: '#/components/schemas/BaseProductOption' - option_id: - type: string - title: option_id - description: The option's option id. + description: The date the variant was deleted. metadata: type: object - description: The option's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The option's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The option's updated at. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The option's deleted at. - BaseProductTag: - type: object - description: The tag's tags. - x-schemaName: BaseProductTag - BaseProductVariant: - type: object - description: The variant's variants. - x-schemaName: BaseProductVariant + description: The variant's metadata, can hold custom key-value pairs. BasePromotion: type: object description: The application method's promotion. @@ -18856,467 +19959,366 @@ components: description: The value's values. x-schemaName: BasePromotionRuleValue required: - - id - properties: - id: - type: string - title: id - description: The value's ID. - value: - type: string - title: value - description: The value's details. - BaseRefund: - type: object - description: The refund's refunds. - x-schemaName: BaseRefund - BaseRegion: - type: object - description: The parent's region. - x-schemaName: BaseRegion - required: - - id - - name - - currency_code - properties: - id: - type: string - title: id - description: The region's ID. - name: - type: string - title: name - description: The region's name. - currency_code: - type: string - title: currency_code - description: The region's currency code. - automatic_taxes: - type: boolean - title: automatic_taxes - description: The region's automatic taxes. - countries: - type: array - description: The region's countries. - items: - $ref: '#/components/schemas/BaseRegionCountry' - payment_providers: - type: array - description: The region's payment providers. - items: - $ref: '#/components/schemas/AdminPaymentProvider' - metadata: - type: object - description: The region's metadata. - created_at: - type: string - format: date-time - title: created_at - description: The region's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The region's updated at. - BaseRegionCountry: - type: object - description: The country's countries. - x-schemaName: BaseRegionCountry - BaseReturnItem: - type: object - description: The item's items. - x-schemaName: BaseReturnItem - BaseRuleOperatorOptions: - type: object - description: The operator's operators. - x-schemaName: BaseRuleOperatorOptions - required: - - id - - value - - label - properties: - id: - type: string - title: id - description: The operator's ID. - value: - type: string - title: value - description: The operator's value. - label: - type: string - title: label - description: The operator's label. - BaseShippingMethodAdjustment: - type: object - description: The adjustment's adjustments. - x-schemaName: BaseShippingMethodAdjustment - BaseShippingMethodTaxLine: - type: object - description: The tax line's tax lines. - x-schemaName: BaseShippingMethodTaxLine - CampaignResponse: - type: object - description: The campaign's details. - x-schemaName: CampaignResponse - required: - - id - - name - - description - - currency - - campaign_identifier - - starts_at - - ends_at - - budget - properties: - id: - type: string - title: id - description: The campaign's ID. - name: - type: string - title: name - description: The campaign's name. - description: - type: string - title: description - description: The campaign's description. - currency: - type: string - title: currency - description: The campaign's currency. - campaign_identifier: - type: string - title: campaign_identifier - description: The campaign's campaign identifier. - starts_at: - type: string - title: starts_at - description: The campaign's starts at. - ends_at: - type: string - title: ends_at - description: The campaign's ends at. - budget: - type: object - description: The campaign's budget. - required: - - id - - type - - currency_code - - limit - - used - properties: - id: - type: string - title: id - description: The budget's ID. - type: - type: string - enum: - - spend - - usage - currency_code: - type: string - title: currency_code - description: The budget's currency code. - limit: - type: number - title: limit - description: The budget's limit. - used: - type: number - title: used - description: The budget's used. - CreateAddress: - type: object - description: The cart's shipping address. - x-schemaName: CreateAddress + - id properties: - customer_id: - type: string - title: customer_id - description: The shipping address's customer id. - company: - type: string - title: company - description: The shipping address's company. - first_name: - type: string - title: first_name - description: The shipping address's first name. - last_name: - type: string - title: last_name - description: The shipping address's last name. - address_1: + id: type: string - title: address_1 - description: The shipping address's address 1. - address_2: + title: id + description: The value's ID. + value: type: string - title: address_2 - description: The shipping address's address 2. - city: + title: value + description: The value's details. + BaseRefund: + type: object + description: The refund's details. + x-schemaName: BaseRefund + required: + - id + - amount + - created_at + - payment + properties: + id: type: string - title: city - description: The shipping address's city. - country_code: + title: id + description: The refund's ID. + amount: + type: number + title: amount + description: The refund's amount. + refund_reason_id: type: string - title: country_code - description: The shipping address's country code. - province: + title: refund_reason_id + description: The ID of the refund reason. + note: type: string - title: province - description: The shipping address's province. - postal_code: + title: note + description: More details about the refund. + created_at: type: string - title: postal_code - description: The shipping address's postal code. - phone: + format: date-time + title: created_at + description: The date the refund was created. + created_by: type: string - title: phone - description: The shipping address's phone. - metadata: - type: object - description: The shipping address's metadata. - CreateCartAddress: + title: created_by + description: The ID of the user that created the refund. + payment: + $ref: '#/components/schemas/BasePayment' + refund_reason: + $ref: '#/components/schemas/RefundReason' + BaseRegion: + type: object + description: The parent's region. + x-schemaName: BaseRegion + BaseRegionCountry: type: object - description: The cart's billing address. - x-schemaName: CreateCartAddress + description: The country's details. + x-schemaName: BaseRegionCountry properties: - first_name: - type: string - title: first_name - description: The billing address's first name. - last_name: + id: type: string - title: last_name - description: The billing address's last name. - phone: + title: id + description: The country's ID. + iso_2: type: string - title: phone - description: The billing address's phone. - company: + title: iso_2 + description: The country's iso 2. + example: us + iso_3: type: string - title: company - description: The billing address's company. - address_1: + title: iso_3 + description: The country's iso 3. + example: usa + num_code: type: string - title: address_1 - description: The billing address's address 1. - address_2: + title: num_code + description: The country's num code. + example: 840 + name: type: string - title: address_2 - description: The billing address's address 2. - city: + title: name + description: The country's name. + display_name: type: string - title: city - description: The billing address's city. - country_code: + title: display_name + description: The country's display name. + required: + - id + BaseRuleOperatorOptions: + type: object + description: The operator's details. + x-schemaName: BaseRuleOperatorOptions + required: + - id + - value + - label + properties: + id: type: string - title: country_code - description: The billing address's country code. - province: + title: id + description: The operator's ID. + example: in + value: type: string - title: province - description: The billing address's province. - postal_code: + title: value + description: The operator's value. + example: in + label: type: string - title: postal_code - description: The billing address's postal code. - metadata: - type: object - description: The billing address's metadata. - CreateCartCreateLineItem: + title: label + description: The operator's label. + example: In + BaseShippingMethodAdjustment: type: object - description: The item's items. - x-schemaName: CreateCartCreateLineItem + description: The adjustment's details. + x-schemaName: BaseShippingMethodAdjustment required: - - quantity - - variant_id + - shipping_method + - shipping_method_id + - id + - amount + - cart_id + - created_at + - updated_at properties: - quantity: + shipping_method: + $ref: '#/components/schemas/BaseCartShippingMethod' + shipping_method_id: type: string - title: quantity - description: The item's quantity. - variant_id: + title: shipping_method_id + description: The ID of the shipping method the adjustment is applied on. + id: type: string - title: variant_id - description: The item's variant id. - title: + title: id + description: The adjustment's ID. + code: type: string - title: title - description: The item's title. - subtitle: + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + cart_id: type: string - title: subtitle - description: The item's subtitle. - thumbnail: + title: cart_id + description: The ID of the associated cart. + description: type: string - title: thumbnail - description: The item's thumbnail. - product_id: + title: description + description: The adjustment's description. + promotion_id: type: string - title: product_id - description: The item's product id. - product_title: + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: type: string - title: product_title - description: The item's product title. - product_description: + title: provider_id + description: The adjustment's provider ID. + created_at: type: string - title: product_description - description: The item's product description. - product_subtitle: + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: type: string - title: product_subtitle - description: The item's product subtitle. - product_type: + format: date-time + title: updated_at + description: The date the adjustment was updated. + BaseShippingMethodTaxLine: + type: object + description: The tax line's details. + x-schemaName: BaseShippingMethodTaxLine + required: + - shipping_method + - shipping_method_id + - total + - subtotal + - id + - code + - rate + - created_at + - updated_at + properties: + shipping_method: + type: object + shipping_method_id: type: string - title: product_type - description: The item's product type. - product_collection: + title: shipping_method_id + description: The ID of this shipping method the tax line belongs to. + total: + type: number + title: total + description: The method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The method's total excluding taxes, including promotions. + id: type: string - title: product_collection - description: The item's product collection. - product_handle: + title: id + description: The tax line's ID. + description: type: string - title: product_handle - description: The item's product handle. - variant_sku: + title: description + description: The tax line's description. + tax_rate_id: type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: + title: tax_rate_id + description: The ID of the applied tax rate. + code: type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: + title: code + description: The code that the rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - is_giftcard: - type: boolean - title: is_giftcard - description: The item's is giftcard. - compare_at_unit_price: + title: provider_id + description: The ID of the tax provider that calculated the taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. + CampaignResponse: + type: object + description: The campaign's details. + x-schemaName: CampaignResponse + required: + - id + - name + - description + - currency + - campaign_identifier + - starts_at + - ends_at + - budget + properties: + id: type: string - title: compare_at_unit_price - description: The item's compare at unit price. - unit_price: + title: id + description: The campaign's ID. + name: type: string - title: unit_price - description: The item's unit price. - metadata: + title: name + description: The campaign's name. + description: + type: string + title: description + description: The campaign's description. + currency: + type: string + title: currency + description: The campaign's currency. + campaign_identifier: + type: string + title: campaign_identifier + description: The campaign's campaign identifier. + starts_at: + type: string + title: starts_at + description: The campaign's starts at. + ends_at: + type: string + title: ends_at + description: The campaign's ends at. + budget: type: object - description: The item's metadata. - CreateCartWorkflowInput: + description: The campaign's budget. + required: + - id + - type + - currency_code + - limit + - used + properties: + id: + type: string + title: id + description: The budget's ID. + type: + type: string + enum: + - spend + - usage + currency_code: + type: string + title: currency_code + description: The budget's currency code. + limit: + type: number + title: limit + description: The budget's limit. + used: + type: number + title: used + description: The budget's used. + CreateAddress: type: object - description: SUMMARY - x-schemaName: CreateCartWorkflowInput + description: The address to create. + x-schemaName: CreateAddress properties: - region_id: - type: string - title: region_id - description: The cart's region id. customer_id: type: string title: customer_id - description: The cart's customer id. - sales_channel_id: + description: The ID of the customer this address belongs to. + company: type: string - title: sales_channel_id - description: The cart's sales channel id. - email: + title: company + description: The address's company. + first_name: type: string - title: email - description: The cart's email. - format: email - currency_code: + title: first_name + description: The address's first name. + last_name: type: string - title: currency_code - description: The cart's currency code. - shipping_address_id: + title: last_name + description: The address's last name. + address_1: type: string - title: shipping_address_id - description: The cart's shipping address id. - billing_address_id: + title: address_1 + description: The address's first line. + address_2: type: string - title: billing_address_id - description: The cart's billing address id. - shipping_address: - oneOf: - - type: string - title: shipping_address - description: The cart's shipping address. - - $ref: '#/components/schemas/CreateCartAddress' - billing_address: - oneOf: - - type: string - title: billing_address - description: The cart's billing address. - - $ref: '#/components/schemas/CreateCartAddress' - metadata: - type: object - description: The cart's metadata. - items: - type: array - description: The cart's items. - items: - $ref: '#/components/schemas/CreateCartCreateLineItem' - promo_codes: - type: array - description: The cart's promo codes. - items: - type: string - title: promo_codes - description: The promo code's promo codes. - CreateOrderReturnReason: - type: object - description: SUMMARY - x-schemaName: CreateOrderReturnReason - required: - - value - - label - properties: - value: + title: address_2 + description: The address's second line. + city: type: string - title: value - description: The return reason's value. - label: + title: city + description: The address's city. + country_code: type: string - title: label - description: The return reason's label. - description: + title: country_code + description: The address's country code. + example: us + province: type: string - title: description - description: The return reason's description. - parent_return_reason_id: + title: province + description: The address's province. + postal_code: type: string - title: parent_return_reason_id - description: The return reason's parent return reason id. + title: postal_code + description: The address's postal code. + phone: + type: string + title: phone + description: The address's phone. metadata: type: object - description: The return reason's metadata. + description: The address's metadata, can hold custom key-value pairs. CustomerGroupInCustomerFilters: type: object - description: The customer's groups. + description: Filter by customer groups to get their associated customers. x-schemaName: CustomerGroupInCustomerFilters required: - id @@ -19329,27 +20331,27 @@ components: oneOf: - type: string title: id - description: The group's ID. + description: Filter by a group's ID. - type: array - description: The group's ID. + description: Filter by group IDs. items: type: string title: id - description: The id's ID. + description: A group's ID. name: oneOf: - type: string title: name - description: The group's name. + description: Filter by a group's name. - type: array - description: The group's name. + description: Filter by group names. items: type: string title: name - description: The name's details. + description: A group's name. created_at: type: object - description: The group's created at. + description: Filter by the group's creation date. properties: $and: type: array @@ -19369,7 +20371,7 @@ components: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -19464,7 +20466,7 @@ components: description: Filter by whether a value for this parameter exists (not `null`). updated_at: type: object - description: The group's updated at. + description: Filter by the group's update date. properties: $and: type: array @@ -19484,7 +20486,7 @@ components: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -19579,7 +20581,7 @@ components: description: Filter by whether a value for this parameter exists (not `null`). deleted_at: type: object - description: The group's deleted at. + description: Filter by the group's deletion date. properties: $and: type: array @@ -19599,7 +20601,7 @@ components: title: $eq description: Filter by an exact match. - type: array - description: Filter by an exact match. + description: Filter by exact matches. items: type: string title: $eq @@ -19696,156 +20698,384 @@ components: title: Response Error type: object properties: - code: + code: + type: string + description: A slug code to indicate the type of the error. + enum: + - invalid_state_error + - invalid_request_error + - api_error + - unknown_error + message: + type: string + description: Description of the error that occurred. + example: first_name must be a string + type: + type: string + description: A slug indicating the type of the error. + enum: + - QueryRunnerAlreadyReleasedError + - TransactionAlreadyStartedError + - TransactionNotStartedError + - conflict + - unauthorized + - payment_authorization_error + - duplicate_error + - not_allowed + - invalid_data + - not_found + - database_error + - unexpected_state + - invalid_argument + - unknown_error + IBigNumber: + type: object + description: The shipping method's discount tax total. + x-schemaName: IBigNumber + InventoryLevel: + type: object + description: The inventory level's details + x-schemaName: InventoryLevel + required: + - id + - inventory_item_id + - location_id + - stocked_quantity + - reserved_quantity + - available_quantity + - incoming_quantity + properties: + id: + type: string + title: id + description: The inventory level's ID. + inventory_item_id: + type: string + title: inventory_item_id + description: The ID of the associated inventory item. + location_id: + type: string + title: location_id + description: The ID of the associated location. + stocked_quantity: + type: number + title: stocked_quantity + description: The inventory level's stocked quantity. + reserved_quantity: + type: number + title: reserved_quantity + description: The inventory level's reserved quantity. + available_quantity: + type: number + title: available_quantity + description: The inventory level's available quantity. + incoming_quantity: + type: number + title: incoming_quantity + description: The inventory level's incoming quantity. + metadata: + type: object + description: The inventory level's metadata, can hold custom key-value pairs. + Order: + type: object + description: The order change's order. + x-schemaName: Order + required: + - id + - version + - status + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_subtotal + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total + properties: + id: type: string - description: A slug code to indicate the type of the error. + title: id + description: The order's ID. + version: + type: number + title: version + description: The order's version. + order_change: + $ref: '#/components/schemas/OrderChange' + status: + type: string + description: The order's status. enum: - - invalid_state_error - - invalid_request_error - - api_error - - unknown_error - message: + - canceled + - requires_action + - pending + - completed + - draft + - archived + region_id: type: string - description: Description of the error that occurred. - example: first_name must be a string - type: + title: region_id + description: The ID of the region the order belongs to. + customer_id: type: string - description: A slug indicating the type of the error. - enum: - - QueryRunnerAlreadyReleasedError - - TransactionAlreadyStartedError - - TransactionNotStartedError - - conflict - - unauthorized - - payment_authorization_error - - duplicate_error - - not_allowed - - invalid_data - - not_found - - database_error - - unexpected_state - - invalid_argument - - unknown_error - File: - type: object - description: The product's file. - x-schemaName: File - required: - - lastModified - - name - - webkitRelativePath - - size - - type - - arrayBuffer - - stream - - text - properties: - lastModified: - type: number - title: lastModified - description: The file's lastmodified. - name: + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: type: string - title: name - description: The file's name. - webkitRelativePath: + title: sales_channel_id + description: The ID of the sales channel the order was placed in. + email: type: string - title: webkitRelativePath - description: The file's webkitrelativepath. - size: - type: number - title: size - description: The file's size. - type: + title: email + description: The email of the customer that placed the order. + format: email + currency_code: type: string - title: type - description: The file's type. - arrayBuffer: + title: currency_code + description: The order's currency code. + example: usd + shipping_address: + $ref: '#/components/schemas/OrderAddress' + billing_address: + $ref: '#/components/schemas/OrderAddress' + items: + type: array + description: The order's items. + items: + $ref: '#/components/schemas/OrderLineItem' + shipping_methods: + type: array + description: The order's shipping methods. + items: + $ref: '#/components/schemas/OrderShippingMethod' + transactions: + type: array + description: The order's transactions. + items: + $ref: '#/components/schemas/OrderTransaction' + summary: + type: object + description: The order's summary. + metadata: + type: object + description: The order's metadata, can hold custom key-value pairs. + canceled_at: + type: string + format: date-time + title: canceled_at + description: The date the order was canceled. + created_at: + type: string + format: date-time + title: created_at + description: The date the order was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order was updated. + original_item_total: + type: number + title: original_item_total + description: The order items' total including taxes, excluding promotions. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The order items' total excluding taxes, including promotions. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The taxes total for order items, excluding promotions. + item_total: + type: number + title: item_total + description: The order items' total including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The order items' total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the order items including promotions. + original_total: + type: number + title: original_total + description: The order's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The order's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order excluding promotions. + total: + type: number + title: total + description: The order's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The order's subtotal excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The tax total of the order including promotions. + discount_subtotal: + type: number + title: discount_subtotal + description: The total discount excluding taxes. + discount_total: + type: number + title: discount_total + description: The total discount including taxes. + discount_tax_total: + type: number + title: discount_tax_total + description: The tax total applied on the discount. + gift_card_total: + type: number + title: gift_card_total + description: The order's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The order's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The order's shipping total including taxes and promotions. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The total taxes of the order's shipping including taxes. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total including taxes, excluding promotions. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping total excluding taxes, including promotions. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The total taxes of the order's shipping excluding promotions. + raw_original_item_total: type: object - description: The file's arraybuffer. - slice: + description: The order's raw original item total. + raw_original_item_subtotal: type: object - description: The file's slice. - stream: + description: The order's raw original item subtotal. + raw_original_item_tax_total: type: object - description: The file's stream. - text: + description: The order's raw original item tax total. + raw_item_total: type: object - description: The file's text. - FileList: - type: object - description: SUMMARY - x-schemaName: FileList - required: - - length - - item - - __@iterator@258 - properties: - length: - type: number - title: length - description: The upload's length. - item: + description: The order's raw item total. + raw_item_subtotal: + type: object + description: The order's raw item subtotal. + raw_item_tax_total: + type: object + description: The order's raw item tax total. + raw_original_total: + type: object + description: The order's raw original total. + raw_original_subtotal: + type: object + description: The order's raw original subtotal. + raw_original_tax_total: + type: object + description: The order's raw original tax total. + raw_total: + type: object + description: The order's raw total. + raw_subtotal: + type: object + description: The order's raw subtotal. + raw_tax_total: + type: object + description: The order's raw tax total. + raw_discount_total: + type: object + description: The order's raw discount total. + raw_discount_tax_total: + type: object + description: The order's raw discount tax total. + raw_gift_card_total: + type: object + description: The order's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The order's raw gift card tax total. + raw_shipping_total: + type: object + description: The order's raw shipping total. + raw_shipping_subtotal: + type: object + description: The order's raw shipping subtotal. + raw_shipping_tax_total: type: object - description: The upload's item. - __@iterator@258: + description: The order's raw shipping tax total. + raw_original_shipping_total: type: object - description: The upload's @iterator@258. - IBigNumber: - type: object - description: The shipping method's discount tax total. - x-schemaName: IBigNumber - InventoryLevel: - type: object - description: The inventory level's inventory levels. - x-schemaName: InventoryLevel - required: - - id - - inventory_item_id - - location_id - - stocked_quantity - - reserved_quantity - - available_quantity - - incoming_quantity - properties: - id: - type: string - title: id - description: The inventory level's ID. - inventory_item_id: - type: string - title: inventory_item_id - description: The inventory level's inventory item id. - location_id: - type: string - title: location_id - description: The inventory level's location id. - stocked_quantity: - type: number - title: stocked_quantity - description: The inventory level's stocked quantity. - reserved_quantity: - type: number - title: reserved_quantity - description: The inventory level's reserved quantity. - available_quantity: - type: number - title: available_quantity - description: The inventory level's available quantity. - incoming_quantity: - type: number - title: incoming_quantity - description: The inventory level's incoming quantity. - metadata: + description: The order's raw original shipping total. + raw_original_shipping_subtotal: type: object - description: The inventory level's metadata. - Order: - type: object - description: The transaction's order. - x-schemaName: Order + description: The order's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The order's raw original shipping tax total. OrderAddress: type: object - description: The order preview's billing address. + description: The address's details. x-schemaName: OrderAddress required: - id @@ -19855,67 +21085,68 @@ components: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer the address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The billing address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The billing address's updated at. + description: The date the address was updated. OrderChange: type: object - description: The order preview's order change. + description: The order change's details. x-schemaName: OrderChange required: - id @@ -19950,10 +21181,10 @@ components: version: type: number title: version - description: The order change's version. + description: The order change's version. This will be the order's version when the change is applied. change_type: type: string - description: The order change's change type. + description: The order change's type. enum: - return - exchange @@ -19962,19 +21193,19 @@ components: order_id: type: string title: order_id - description: The order change's order id. + description: The ID of the order this change applies on. return_id: type: string title: return_id - description: The order change's return id. + description: The ID of the associated return. exchange_id: type: string title: exchange_id - description: The order change's exchange id. + description: The ID of the associated exchange. claim_id: type: string title: claim_id - description: The order change's claim id. + description: The ID of the associated claim. order: type: object return_order: @@ -19990,111 +21221,445 @@ components: $ref: '#/components/schemas/OrderChangeAction' status: type: string - title: status - description: The order change's status. - requested_by: + description: The order change's status. + enum: + - canceled + - requested + - pending + - confirmed + - declined + requested_by: + type: string + title: requested_by + description: The ID of the user that requested the change. + requested_at: + type: string + title: requested_at + description: The date the order change was requested. + format: date-time + confirmed_by: + type: string + title: confirmed_by + description: The ID of the user that confirmed the order change. + confirmed_at: + type: string + title: confirmed_at + description: The date the order change was confirmed. + format: date-time + declined_by: + type: string + title: declined_by + description: The ID of the user that declined the order change. + declined_reason: + type: string + title: declined_reason + description: The reason the order change was declined. + metadata: + type: object + description: The order change's metadata, can hold custom key-value pairs. + declined_at: + type: string + title: declined_at + description: The date the order change was declined. + format: date-time + canceled_by: + type: string + title: canceled_by + description: The ID of the user that canceled the order change. + canceled_at: + type: string + title: canceled_at + description: The date the order change was canceled. + format: date-time + created_at: + type: string + format: date-time + title: created_at + description: The date the order change was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the order change was updated. + OrderChangeAction: + type: object + description: The order change action's details. + x-schemaName: OrderChangeAction + required: + - id + - order_change_id + - order_change + - order_id + - return_id + - claim_id + - exchange_id + - order + - reference + - reference_id + - action + - details + - internal_note + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The action's ID. + order_change_id: + type: string + title: order_change_id + description: The ID of the order change that the action belongs to. + order_change: + $ref: '#/components/schemas/OrderChange' + order_id: + type: string + title: order_id + description: The ID of the order the associated change is for. + return_id: + type: string + title: return_id + description: The ID of the associated return. + claim_id: + type: string + title: claim_id + description: The ID of the associated claim. + exchange_id: + type: string + title: exchange_id + description: The ID of the associated exchange. + order: + type: object + reference: + type: string + title: reference + description: The name of the table this action applies on. + enum: + - claim + - exchange + - return + - order_shipping_method + reference_id: + type: string + title: reference_id + description: The ID of the record in the referenced table. + action: + type: string + description: The applied action. + enum: + - CANCEL_RETURN_ITEM + - FULFILL_ITEM + - DELIVER_ITEM + - CANCEL_ITEM_FULFILLMENT + - ITEM_ADD + - ITEM_REMOVE + - ITEM_UPDATE + - RECEIVE_DAMAGED_RETURN_ITEM + - RECEIVE_RETURN_ITEM + - RETURN_ITEM + - SHIPPING_ADD + - SHIPPING_REMOVE + - SHIP_ITEM + - WRITE_OFF_ITEM + - REINSTATE_ITEM + details: + type: object + description: The action's details. + example: + reference_id: 123 + quantity: 1 + internal_note: + type: string + title: internal_note + description: A note that's viewed only by admin users. + created_at: + type: string + format: date-time + title: created_at + description: The date the action was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the action was updated. + OrderClaim: + type: object + description: The order change's claim. + x-schemaName: OrderClaim + required: + - order_id + - claim_items + - additional_items + - currency_code + - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + properties: + id: + type: string + title: id + description: The claim's ID. + order_id: + type: string + title: order_id + description: The ID of the order associated with the claim. + claim_items: + type: array + description: The order items targetted by the claim. + items: + $ref: '#/components/schemas/BaseClaimItem' + additional_items: + type: array + description: The outbound or new items of the claim. + items: + $ref: '#/components/schemas/BaseClaimItem' + return: + $ref: '#/components/schemas/Return' + return_id: + type: string + title: return_id + description: The ID of the associated return. + no_notification: + type: boolean + title: no_notification + description: Whether the customer should be notified about changes in the claim. + refund_amount: + type: number + title: refund_amount + description: The amount to be refunded. + currency_code: + type: string + title: currency_code + description: The claim's currency code. + region_id: + type: string + title: region_id + description: The ID of the region associated with the claim. + customer_id: type: string - title: requested_by - description: The order change's requested by. - requested_at: - oneOf: - - type: string - title: requested_at - description: The order change's requested at. - - type: string - title: requested_at - description: The order change's requested at. - format: date-time - confirmed_by: + title: customer_id + description: The ID of the customer associated with the claim's order. + sales_channel_id: type: string - title: confirmed_by - description: The order change's confirmed by. - confirmed_at: - oneOf: - - type: string - title: confirmed_at - description: The order change's confirmed at. - - type: string - title: confirmed_at - description: The order change's confirmed at. - format: date-time - declined_by: + title: sales_channel_id + description: The ID of the sales channel the claim's order is created in. + email: type: string - title: declined_by - description: The order change's declined by. - declined_reason: + title: email + description: The email associated with the claim's order. + format: email + display_id: + type: number + title: display_id + description: The claim's display ID. + shipping_address: + $ref: '#/components/schemas/BaseOrderAddress' + billing_address: + $ref: '#/components/schemas/BaseOrderAddress' + shipping_methods: + type: array + description: The claim's shipping methods. + items: + $ref: '#/components/schemas/BaseOrderShippingMethod' + payment_collections: + type: array + description: The claim's payment collections. + items: + $ref: '#/components/schemas/BasePaymentCollection' + payment_status: type: string - title: declined_reason - description: The order change's declined reason. + description: The claim's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The claim's fulfillments. + items: + $ref: '#/components/schemas/BaseOrderFulfillment' + fulfillment_status: + type: string + description: The claim's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The claim's transactions. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + description: Learn more about transactions of orders and associated models. + items: + $ref: '#/components/schemas/BaseOrderTransaction' + summary: + $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object - description: The order change's metadata. - declined_at: - oneOf: - - type: string - title: declined_at - description: The order change's declined at. - - type: string - title: declined_at - description: The order change's declined at. - format: date-time - canceled_by: - type: string - title: canceled_by - description: The order change's canceled by. - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order change's canceled at. - - type: string - title: canceled_at - description: The order change's canceled at. - format: date-time + description: The claim's metadata, used to store custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The order change's created at. + description: The claim's creation date. updated_at: type: string format: date-time title: updated_at - description: The order change's updated at. - OrderChangeAction: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - OrderClaim: - type: object - description: The order change's claim. - x-schemaName: OrderClaim + description: The claim's update date. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the associated order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the associated order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The tax total of the original items in the associated order. + item_total: + type: number + title: item_total + description: The total of the claim's items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the claim's items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the claim's items. + original_total: + type: number + title: original_total + description: The associated order's original total. + original_subtotal: + type: number + title: original_subtotal + description: The associated order's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The associated order's original tax total. + total: + type: number + title: total + description: The associated order's total. + subtotal: + type: number + title: subtotal + description: The claim's subtotal. + tax_total: + type: number + title: tax_total + description: The claim's tax total. + discount_total: + type: number + title: discount_total + description: The claim's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The claim's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The claim's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The claim's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The claim's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The claim's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The claim's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The associated order's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The associated order's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The associated order's original shipping tax total. OrderExchange: type: object description: The order change's exchange. x-schemaName: OrderExchange - OrderItem: - type: object - description: The item's detail. - x-schemaName: OrderItem - OrderLineItemAdjustment: - type: object - description: The adjustment's adjustments. - x-schemaName: OrderLineItemAdjustment - OrderLineItemTaxLine: - type: object - description: The tax line's tax lines. - x-schemaName: OrderLineItemTaxLine - OrderPreview: - type: object - description: The order edit's order preview. - x-schemaName: OrderPreview required: - - order_change - - status + - order_id + - return_items + - additional_items - currency_code - - version - id + - region_id + - customer_id + - sales_channel_id + - email + - shipping_methods + - payment_status + - fulfillment_status + - summary + - metadata + - created_at + - updated_at - original_item_total - original_item_subtotal - original_item_tax_total @@ -20110,1227 +21675,592 @@ components: - discount_total - discount_tax_total - gift_card_total - - gift_card_tax_total - - shipping_total - - shipping_subtotal - - shipping_tax_total - - original_shipping_total - - original_shipping_subtotal - - original_shipping_tax_total - - raw_original_item_total - - raw_original_item_subtotal - - raw_original_item_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - - raw_gift_card_total - - raw_gift_card_tax_total - - raw_shipping_total - - raw_shipping_subtotal - - raw_shipping_tax_total - - raw_original_shipping_total - - raw_original_shipping_subtotal - - raw_original_shipping_tax_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total properties: - order_change: - $ref: '#/components/schemas/OrderChange' - items: + order_id: + type: string + title: order_id + description: The ID of the order the exchange is created for. + return_items: type: array - description: The order preview's items. + description: The items returned (inbound) by the exchange. items: - allOf: - - type: object - description: The item's items. - x-schemaName: OrderLineItem - required: - - id - - title - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - - raw_unit_price - - quantity - - raw_quantity - - detail - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - item_total - - item_subtotal - - item_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - refundable_total - - refundable_total_per_unit - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_item_total - - raw_item_subtotal - - raw_item_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - - raw_refundable_total - - raw_refundable_total_per_unit - properties: - id: - type: string - title: id - description: The item's ID. - title: - type: string - title: title - description: The item's title. - subtitle: - type: string - title: subtitle - description: The item's subtitle. - thumbnail: - type: string - title: thumbnail - description: The item's thumbnail. - variant_id: - type: string - title: variant_id - description: The item's variant id. - product_id: - type: string - title: product_id - description: The item's product id. - product_title: - type: string - title: product_title - description: The item's product title. - product_description: - type: string - title: product_description - description: The item's product description. - product_subtitle: - type: string - title: product_subtitle - description: The item's product subtitle. - product_type: - type: string - title: product_type - description: The item's product type. - product_collection: - type: string - title: product_collection - description: The item's product collection. - product_handle: - type: string - title: product_handle - description: The item's product handle. - variant_sku: - type: string - title: variant_sku - description: The item's variant sku. - variant_barcode: - type: string - title: variant_barcode - description: The item's variant barcode. - variant_title: - type: string - title: variant_title - description: The item's variant title. - variant_option_values: - type: object - description: The item's variant option values. - requires_shipping: - type: boolean - title: requires_shipping - description: The item's requires shipping. - is_discountable: - type: boolean - title: is_discountable - description: The item's is discountable. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The item's is tax inclusive. - compare_at_unit_price: - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - raw_compare_at_unit_price: - type: object - description: The item's raw compare at unit price. - unit_price: - type: number - title: unit_price - description: The item's unit price. - raw_unit_price: - type: object - description: The item's raw unit price. - quantity: - type: number - title: quantity - description: The item's quantity. - raw_quantity: - type: object - description: The item's raw quantity. - tax_lines: - type: array - description: The item's tax lines. - items: - $ref: '#/components/schemas/OrderLineItemTaxLine' - adjustments: - type: array - description: The item's adjustments. - items: - $ref: '#/components/schemas/OrderLineItemAdjustment' - detail: - $ref: '#/components/schemas/OrderItem' - created_at: - type: string - format: date-time - title: created_at - description: The item's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The item's updated at. - metadata: - type: object - description: The item's metadata. - original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: '#/components/schemas/IBigNumber' - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: '#/components/schemas/IBigNumber' - item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: '#/components/schemas/IBigNumber' - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: '#/components/schemas/IBigNumber' - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: '#/components/schemas/IBigNumber' - total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: '#/components/schemas/IBigNumber' - subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: '#/components/schemas/IBigNumber' - tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: '#/components/schemas/IBigNumber' - discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: '#/components/schemas/IBigNumber' - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - refundable_total: - oneOf: - - type: string - title: refundable_total - description: The item's refundable total. - - type: number - title: refundable_total - description: The item's refundable total. - - type: string - title: refundable_total - description: The item's refundable total. - - $ref: '#/components/schemas/IBigNumber' - refundable_total_per_unit: - oneOf: - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: number - title: refundable_total_per_unit - description: The item's refundable total per unit. - - type: string - title: refundable_total_per_unit - description: The item's refundable total per unit. - - $ref: '#/components/schemas/IBigNumber' - raw_original_total: - type: object - description: The item's raw original total. - raw_original_subtotal: - type: object - description: The item's raw original subtotal. - raw_original_tax_total: - type: object - description: The item's raw original tax total. - raw_item_total: - type: object - description: The item's raw item total. - raw_item_subtotal: - type: object - description: The item's raw item subtotal. - raw_item_tax_total: - type: object - description: The item's raw item tax total. - raw_total: - type: object - description: The item's raw total. - raw_subtotal: - type: object - description: The item's raw subtotal. - raw_tax_total: - type: object - description: The item's raw tax total. - raw_discount_total: - type: object - description: The item's raw discount total. - raw_discount_tax_total: - type: object - description: The item's raw discount tax total. - raw_refundable_total: - type: object - description: The item's raw refundable total. - raw_refundable_total_per_unit: - type: object - description: The item's raw refundable total per unit. - - type: object - description: The item's items. - properties: - actions: - type: array - description: The item's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction + $ref: '#/components/schemas/AdminReturnItem' + additional_items: + type: array + description: The new items (outbound) sent by the exchange. + items: + $ref: '#/components/schemas/BaseExchangeItem' + no_notification: + type: boolean + title: no_notification + description: Whether to send the customer notifications when the exchange is updated. + difference_due: + type: number + title: difference_due + description: The amount to be exchanged or refunded. If the amount is negative, it must be refunded. If positive, additional payment is required from the customer. + return: + description: the return associated with the exchange. + $ref: '#/components/schemas/AdminReturn' + return_id: + type: string + title: return_id + description: The ID of the associated exchange. + currency_code: + type: string + title: currency_code + description: The exchange's currency code. + id: + type: string + title: id + description: The exchange's ID. + region_id: + type: string + title: region_id + description: The ID of the associated order's region. + customer_id: + type: string + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: + type: string + title: sales_channel_id + description: The ID of the sales channel the associated order belongs to. + email: + type: string + title: email + description: The email used when placing the order. + format: email + display_id: + type: number + title: display_id + description: The exchange's display ID. + shipping_address: + description: The shipping address to send new items to. + $ref: '#/components/schemas/BaseOrderAddress' + billing_address: + description: The customer's billing address. + $ref: '#/components/schemas/BaseOrderAddress' shipping_methods: type: array - description: The order preview's shipping methods. + description: The shipping methods used to send the new (outbound) items. items: - allOf: - - type: object - description: The shipping method's shipping methods. - x-schemaName: OrderShippingMethod - required: - - id - - order_id - - name - - amount - - raw_amount - - is_tax_inclusive - - created_at - - updated_at - - original_total - - original_subtotal - - original_tax_total - - total - - subtotal - - tax_total - - discount_total - - discount_tax_total - - raw_original_total - - raw_original_subtotal - - raw_original_tax_total - - raw_total - - raw_subtotal - - raw_tax_total - - raw_discount_total - - raw_discount_tax_total - properties: - id: - type: string - title: id - description: The shipping method's ID. - order_id: - type: string - title: order_id - description: The shipping method's order id. - name: - type: string - title: name - description: The shipping method's name. - description: - type: string - title: description - description: The shipping method's description. - amount: - oneOf: - - type: string - title: amount - description: The shipping method's amount. - - type: number - title: amount - description: The shipping method's amount. - - type: string - title: amount - description: The shipping method's amount. - - $ref: '#/components/schemas/IBigNumber' - raw_amount: - type: object - description: The shipping method's raw amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping method's is tax inclusive. - shipping_option_id: - type: string - title: shipping_option_id - description: The shipping method's shipping option id. - data: - type: object - description: The shipping method's data. - metadata: - type: object - description: The shipping method's metadata. - tax_lines: - type: array - description: The shipping method's tax lines. - items: - $ref: '#/components/schemas/OrderShippingMethodTaxLine' - adjustments: - type: array - description: The shipping method's adjustments. - items: - $ref: '#/components/schemas/OrderShippingMethodAdjustment' - created_at: - type: string - format: date-time - title: created_at - description: The shipping method's created at. - updated_at: - type: string - format: date-time - title: updated_at - description: The shipping method's updated at. - original_total: - oneOf: - - type: string - title: original_total - description: The shipping method's original total. - - type: number - title: original_total - description: The shipping method's original total. - - type: string - title: original_total - description: The shipping method's original total. - - $ref: '#/components/schemas/IBigNumber' - original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - type: number - title: original_subtotal - description: The shipping method's original subtotal. - - type: string - title: original_subtotal - description: The shipping method's original subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - type: number - title: original_tax_total - description: The shipping method's original tax total. - - type: string - title: original_tax_total - description: The shipping method's original tax total. - - $ref: '#/components/schemas/IBigNumber' - total: - oneOf: - - type: string - title: total - description: The shipping method's total. - - type: number - title: total - description: The shipping method's total. - - type: string - title: total - description: The shipping method's total. - - $ref: '#/components/schemas/IBigNumber' - subtotal: - oneOf: - - type: string - title: subtotal - description: The shipping method's subtotal. - - type: number - title: subtotal - description: The shipping method's subtotal. - - type: string - title: subtotal - description: The shipping method's subtotal. - - $ref: '#/components/schemas/IBigNumber' - tax_total: - oneOf: - - type: string - title: tax_total - description: The shipping method's tax total. - - type: number - title: tax_total - description: The shipping method's tax total. - - type: string - title: tax_total - description: The shipping method's tax total. - - $ref: '#/components/schemas/IBigNumber' - discount_total: - oneOf: - - type: string - title: discount_total - description: The shipping method's discount total. - - type: number - title: discount_total - description: The shipping method's discount total. - - type: string - title: discount_total - description: The shipping method's discount total. - - $ref: '#/components/schemas/IBigNumber' - discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - type: number - title: discount_tax_total - description: The shipping method's discount tax total. - - type: string - title: discount_tax_total - description: The shipping method's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - raw_original_total: - type: object - description: The shipping method's raw original total. - raw_original_subtotal: - type: object - description: The shipping method's raw original subtotal. - raw_original_tax_total: - type: object - description: The shipping method's raw original tax total. - raw_total: - type: object - description: The shipping method's raw total. - raw_subtotal: - type: object - description: The shipping method's raw subtotal. - raw_tax_total: - type: object - description: The shipping method's raw tax total. - raw_discount_total: - type: object - description: The shipping method's raw discount total. - raw_discount_tax_total: - type: object - description: The shipping method's raw discount tax total. - - type: object - description: The shipping method's shipping methods. - properties: - actions: - type: array - description: The shipping method's actions. - items: - type: object - description: The action's actions. - x-schemaName: OrderChangeAction - status: + $ref: '#/components/schemas/BaseOrderShippingMethod' + payment_collections: + type: array + description: The exchange's payment collections. + items: + $ref: '#/components/schemas/BasePaymentCollection' + payment_status: + type: string + description: The exchange's payment status. + enum: + - canceled + - not_paid + - awaiting + - authorized + - partially_authorized + - captured + - partially_captured + - partially_refunded + - refunded + - requires_action + fulfillments: + type: array + description: The exchange's fulfillments of new (outbound) items. + items: + $ref: '#/components/schemas/BaseOrderFulfillment' + fulfillment_status: + type: string + description: The exchange's fulfillment status. + enum: + - canceled + - not_fulfilled + - partially_fulfilled + - fulfilled + - partially_shipped + - shipped + - partially_delivered + - delivered + transactions: + type: array + description: The exchange's transactions. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions + items: + $ref: '#/components/schemas/BaseOrderTransaction' + summary: + description: The totals summary of the exchange. + $ref: '#/components/schemas/BaseOrderSummary' + metadata: + type: object + description: The exchange's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date that the exchange was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date that the exchange was updated. + original_item_total: + type: number + title: original_item_total + description: The total of the original items in the order. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The subtotal of the original items in the order. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The total tax of the original items in the order. + item_total: + type: number + title: item_total + description: The total of the exchange's new items. + item_subtotal: + type: number + title: item_subtotal + description: The subtotal of the exchange's new items. + item_tax_total: + type: number + title: item_tax_total + description: The tax total of the exchange's new items. + original_total: + type: number + title: original_total + description: The total of the order. + original_subtotal: + type: number + title: original_subtotal + description: The subtotal of the order. + original_tax_total: + type: number + title: original_tax_total + description: The tax total of the order. + total: + type: number + title: total + description: The total of the exchange. + subtotal: + type: number + title: subtotal + description: The subtotal of the exchange. + tax_total: + type: number + title: tax_total + description: The tax total of the exchange. + discount_total: + type: number + title: discount_total + description: The discount total of the exchange. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes on discount of the exchange. + gift_card_total: + type: number + title: gift_card_total + description: The gift cards total of the exchange. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The total taxes on the gift card of the exchange. + shipping_total: + type: number + title: shipping_total + description: The exchange's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The exchange's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The exchange's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The order's shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The order's shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The order's shipping tax total. + OrderItem: + type: object + description: The order item's detail. + x-schemaName: OrderItem + required: + - id + - item_id + - item + - quantity + - raw_quantity + - fulfilled_quantity + - raw_fulfilled_quantity + - delivered_quantity + - raw_delivered_quantity + - shipped_quantity + - raw_shipped_quantity + - return_requested_quantity + - raw_return_requested_quantity + - return_received_quantity + - raw_return_received_quantity + - return_dismissed_quantity + - raw_return_dismissed_quantity + - written_off_quantity + - raw_written_off_quantity + - metadata + - created_at + - updated_at + properties: + id: type: string - description: The order preview's status. - enum: - - canceled - - requires_action - - pending - - completed - - draft - - archived - currency_code: + title: id + description: The item's ID. + item_id: type: string - title: currency_code - description: The order preview's currency code. - version: + title: item_id + description: The ID of the associated line item. + item: + $ref: '#/components/schemas/OrderLineItem' + quantity: type: number - title: version - description: The order preview's version. + title: quantity + description: The item's quantity. + raw_quantity: + type: object + description: The item's raw quantity. + fulfilled_quantity: + type: number + title: fulfilled_quantity + description: The item's fulfilled quantity. + raw_fulfilled_quantity: + type: object + description: The item's raw fulfilled quantity. + delivered_quantity: + type: number + title: delivered_quantity + description: The item's delivered quantity. + raw_delivered_quantity: + type: object + description: The item's raw delivered quantity. + shipped_quantity: + type: number + title: shipped_quantity + description: The item's shipped quantity. + raw_shipped_quantity: + type: object + description: The item's raw shipped quantity. + return_requested_quantity: + type: number + title: return_requested_quantity + description: The item's quantity that's requested to be returned. + raw_return_requested_quantity: + type: object + description: The item's raw return requested quantity. + return_received_quantity: + type: number + title: return_received_quantity + description: The item's quantity that's received through a return. + raw_return_received_quantity: + type: object + description: The item's raw return received quantity. + return_dismissed_quantity: + type: number + title: return_dismissed_quantity + description: The item's quantity that's returned but dismissed because it's damaged. + raw_return_dismissed_quantity: + type: object + description: The item's raw return dismissed quantity. + written_off_quantity: + type: number + title: written_off_quantity + description: The item's quantity that's removed due to an order change. + raw_written_off_quantity: + type: object + description: The item's raw written off quantity. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the item was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the item was updated. + OrderLineItem: + type: object + description: The order line item's details. + x-schemaName: OrderLineItem + required: + - id + - title + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - raw_unit_price + - quantity + - raw_quantity + - detail + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - item_total + - item_subtotal + - item_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - refundable_total + - refundable_total_per_unit + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_refundable_total + - raw_refundable_total_per_unit + properties: id: type: string title: id - description: The order preview's ID. - region_id: + description: The item's ID. + title: type: string - title: region_id - description: The order preview's region id. - customer_id: + title: title + description: The item's title. + subtitle: type: string - title: customer_id - description: The order preview's customer id. - sales_channel_id: + title: subtitle + description: The item's subtitle. + thumbnail: type: string - title: sales_channel_id - description: The order preview's sales channel id. - email: + title: thumbnail + description: The item's thumbnail URL. + variant_id: type: string - title: email - description: The order preview's email. - format: email - shipping_address: - $ref: '#/components/schemas/OrderAddress' - billing_address: - $ref: '#/components/schemas/OrderAddress' - transactions: - type: array - description: The order preview's transactions. - items: - $ref: '#/components/schemas/OrderTransaction' - summary: + title: variant_id + description: The ID of the associated variant. + product_id: + type: string + title: product_id + description: The ID of the associated product. + product_title: + type: string + title: product_title + description: The item's product title. + product_description: + type: string + title: product_description + description: The item's product description. + product_subtitle: + type: string + title: product_subtitle + description: The item's product subtitle. + product_type: + type: string + title: product_type + description: The ID of the associated product's type. + product_collection: + type: string + title: product_collection + description: The ID of the associated product's collection. + product_handle: + type: string + title: product_handle + description: The item's product handle. + variant_sku: + type: string + title: variant_sku + description: The item's variant SKU. + variant_barcode: + type: string + title: variant_barcode + description: The item's variant barcode. + variant_title: + type: string + title: variant_title + description: The item's variant title. + variant_option_values: + type: object + description: The associated variant's values for the associated product's options. + example: + Color: Red + requires_shipping: + type: boolean + title: requires_shipping + description: Whether the item requires shipping. + is_discountable: + type: boolean + title: is_discountable + description: Whether the item is discountable. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the item's price includes taxes. + compare_at_unit_price: + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. + raw_compare_at_unit_price: type: object - description: The order preview's summary. + description: The item's raw compare at unit price. required: - - total - - subtotal - - total_tax - - ordered_total - - fulfilled_total - - returned_total - - return_request_total - - write_off_total - - projected_total - - net_total - - net_subtotal - - net_total_tax - - balance - - paid_total - - refunded_total - - pending_difference - - raw_pending_difference + - value properties: - total: - oneOf: - - type: string - title: total - description: The summary's total. - - type: number - title: total - description: The summary's total. - - type: string - title: total - description: The summary's total. - - type: object - description: The summary's total. - x-schemaName: IBigNumber - subtotal: - oneOf: - - type: string - title: subtotal - description: The summary's subtotal. - - type: number - title: subtotal - description: The summary's subtotal. - - type: string - title: subtotal - description: The summary's subtotal. - - type: object - description: The summary's subtotal. - x-schemaName: IBigNumber - total_tax: - oneOf: - - type: string - title: total_tax - description: The summary's total tax. - - type: number - title: total_tax - description: The summary's total tax. - - type: string - title: total_tax - description: The summary's total tax. - - type: object - description: The summary's total tax. - x-schemaName: IBigNumber - ordered_total: - oneOf: - - type: string - title: ordered_total - description: The summary's ordered total. - - type: number - title: ordered_total - description: The summary's ordered total. - - type: string - title: ordered_total - description: The summary's ordered total. - - type: object - description: The summary's ordered total. - x-schemaName: IBigNumber - fulfilled_total: - oneOf: - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: number - title: fulfilled_total - description: The summary's fulfilled total. - - type: string - title: fulfilled_total - description: The summary's fulfilled total. - - type: object - description: The summary's fulfilled total. - x-schemaName: IBigNumber - returned_total: - oneOf: - - type: string - title: returned_total - description: The summary's returned total. - - type: number - title: returned_total - description: The summary's returned total. - - type: string - title: returned_total - description: The summary's returned total. - - type: object - description: The summary's returned total. - x-schemaName: IBigNumber - return_request_total: - oneOf: - - type: string - title: return_request_total - description: The summary's return request total. - - type: number - title: return_request_total - description: The summary's return request total. - - type: string - title: return_request_total - description: The summary's return request total. - - type: object - description: The summary's return request total. - x-schemaName: IBigNumber - write_off_total: - oneOf: - - type: string - title: write_off_total - description: The summary's write off total. - - type: number - title: write_off_total - description: The summary's write off total. - - type: string - title: write_off_total - description: The summary's write off total. - - type: object - description: The summary's write off total. - x-schemaName: IBigNumber - projected_total: - oneOf: - - type: string - title: projected_total - description: The summary's projected total. - - type: number - title: projected_total - description: The summary's projected total. - - type: string - title: projected_total - description: The summary's projected total. - - type: object - description: The summary's projected total. - x-schemaName: IBigNumber - net_total: - oneOf: - - type: string - title: net_total - description: The summary's net total. - - type: number - title: net_total - description: The summary's net total. - - type: string - title: net_total - description: The summary's net total. - - type: object - description: The summary's net total. - x-schemaName: IBigNumber - net_subtotal: - oneOf: - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: number - title: net_subtotal - description: The summary's net subtotal. - - type: string - title: net_subtotal - description: The summary's net subtotal. - - type: object - description: The summary's net subtotal. - x-schemaName: IBigNumber - net_total_tax: - oneOf: - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: number - title: net_total_tax - description: The summary's net total tax. - - type: string - title: net_total_tax - description: The summary's net total tax. - - type: object - description: The summary's net total tax. - x-schemaName: IBigNumber - balance: - oneOf: - - type: string - title: balance - description: The summary's balance. - - type: number - title: balance - description: The summary's balance. - - type: string - title: balance - description: The summary's balance. - - type: object - description: The summary's balance. - x-schemaName: IBigNumber - paid_total: + value: oneOf: - type: string - title: paid_total - description: The summary's paid total. + title: value + description: The raw compare at unit price's value. - type: number - title: paid_total - description: The summary's paid total. - - type: string - title: paid_total - description: The summary's paid total. - - type: object - description: The summary's paid total. - x-schemaName: IBigNumber - refunded_total: + title: value + description: The raw compare at unit price's value. + unit_price: + type: number + title: unit_price + description: The item's price for a single quantity. + raw_unit_price: + type: object + description: The item's raw unit price. + required: + - value + properties: + value: oneOf: - type: string - title: refunded_total - description: The summary's refunded total. + title: value + description: The raw unit price's value. - type: number - title: refunded_total - description: The summary's refunded total. - - type: string - title: refunded_total - description: The summary's refunded total. - - type: object - description: The summary's refunded total. - x-schemaName: IBigNumber - pending_difference: + title: value + description: The raw unit price's value. + quantity: + type: number + title: quantity + description: The item's quantity. + raw_quantity: + type: object + description: The item's raw quantity. + required: + - value + properties: + value: oneOf: - type: string - title: pending_difference - description: The summary's pending difference. + title: value + description: The raw quantity's value. - type: number - title: pending_difference - description: The summary's pending difference. - - type: string - title: pending_difference - description: The summary's pending difference. - - type: object - description: The summary's pending difference. - x-schemaName: IBigNumber - raw_pending_difference: - type: object - description: The summary's raw pending difference. - metadata: - type: object - description: The order preview's metadata. + title: value + description: The raw quantity's value. + tax_lines: + type: array + description: The item's tax lines. + items: + $ref: '#/components/schemas/OrderLineItemTaxLine' + adjustments: + type: array + description: The item's adjustments. + items: + $ref: '#/components/schemas/OrderLineItemAdjustment' + detail: + $ref: '#/components/schemas/OrderItem' created_at: type: string format: date-time title: created_at - description: The order preview's created at. + description: The date the item was created. updated_at: type: string format: date-time title: updated_at - description: The order preview's updated at. - original_item_total: - oneOf: - - type: string - title: original_item_total - description: The order preview's original item total. - - type: number - title: original_item_total - description: The order preview's original item total. - - type: string - title: original_item_total - description: The order preview's original item total. - - $ref: '#/components/schemas/IBigNumber' - original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: number - title: original_item_subtotal - description: The order preview's original item subtotal. - - type: string - title: original_item_subtotal - description: The order preview's original item subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - type: number - title: original_item_tax_total - description: The order preview's original item tax total. - - type: string - title: original_item_tax_total - description: The order preview's original item tax total. - - $ref: '#/components/schemas/IBigNumber' - item_total: - oneOf: - - type: string - title: item_total - description: The order preview's item total. - - type: number - title: item_total - description: The order preview's item total. - - type: string - title: item_total - description: The order preview's item total. - - $ref: '#/components/schemas/IBigNumber' - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - type: number - title: item_subtotal - description: The order preview's item subtotal. - - type: string - title: item_subtotal - description: The order preview's item subtotal. - - $ref: '#/components/schemas/IBigNumber' - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The order preview's item tax total. - - type: number - title: item_tax_total - description: The order preview's item tax total. - - type: string - title: item_tax_total - description: The order preview's item tax total. - - $ref: '#/components/schemas/IBigNumber' + description: The date the item was updated. + metadata: + type: object + description: The item's metadata, can hold custom key-value pairs. original_total: - oneOf: - - type: string - title: original_total - description: The order preview's original total. - - type: number - title: original_total - description: The order preview's original total. - - type: string - title: original_total - description: The order preview's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The item's total including taxes and promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - type: number - title: original_subtotal - description: The order preview's original subtotal. - - type: string - title: original_subtotal - description: The order preview's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The order preview's original tax total. - - type: number - title: original_tax_total - description: The order preview's original tax total. - - type: string - title: original_tax_total - description: The order preview's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. + item_total: + type: number + title: item_total + description: The item's total for a single quantity, including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The item's total for a single quantity, excluding taxes and including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of a single quantity of the item, including promotions. total: - oneOf: - - type: string - title: total - description: The order preview's total. - - type: number - title: total - description: The order preview's total. - - type: string - title: total - description: The order preview's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The item's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The order preview's subtotal. - - type: number - title: subtotal - description: The order preview's subtotal. - - type: string - title: subtotal - description: The order preview's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The order preview's tax total. - - type: number - title: tax_total - description: The order preview's tax total. - - type: string - title: tax_total - description: The order preview's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The total taxes of the item, including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The order preview's discount total. - - type: number - title: discount_total - description: The order preview's discount total. - - type: string - title: discount_total - description: The order preview's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The item's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - type: number - title: discount_tax_total - description: The order preview's discount tax total. - - type: string - title: discount_tax_total - description: The order preview's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The order preview's gift card total. - - type: number - title: gift_card_total - description: The order preview's gift card total. - - type: string - title: gift_card_total - description: The order preview's gift card total. - - $ref: '#/components/schemas/IBigNumber' - gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: number - title: gift_card_tax_total - description: The order preview's gift card tax total. - - type: string - title: gift_card_tax_total - description: The order preview's gift card tax total. - - $ref: '#/components/schemas/IBigNumber' - shipping_total: - oneOf: - - type: string - title: shipping_total - description: The order preview's shipping total. - - type: number - title: shipping_total - description: The order preview's shipping total. - - type: string - title: shipping_total - description: The order preview's shipping total. - - $ref: '#/components/schemas/IBigNumber' - shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: number - title: shipping_subtotal - description: The order preview's shipping subtotal. - - type: string - title: shipping_subtotal - description: The order preview's shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' - shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: number - title: shipping_tax_total - description: The order preview's shipping tax total. - - type: string - title: shipping_tax_total - description: The order preview's shipping tax total. - - $ref: '#/components/schemas/IBigNumber' - original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - type: number - title: original_shipping_total - description: The order preview's original shipping total. - - type: string - title: original_shipping_total - description: The order preview's original shipping total. - - $ref: '#/components/schemas/IBigNumber' - original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The order preview's original shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' - original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The order preview's original shipping tax total. - - $ref: '#/components/schemas/IBigNumber' - canceled_at: - oneOf: - - type: string - title: canceled_at - description: The order preview's canceled at. - - type: string - title: canceled_at - description: The order preview's canceled at. - format: date-time - raw_original_item_total: + type: number + title: discount_tax_total + description: The total taxes on the discounted amount. + refundable_total: + type: number + title: refundable_total + description: The total amount of the item that can be refunded. + refundable_total_per_unit: + type: number + title: refundable_total_per_unit + description: The total amount that can be refunded of a single quantity of the item. + raw_original_total: type: object - description: The order preview's raw original item total. + description: The item's raw original total. required: - value properties: @@ -21338,13 +22268,13 @@ components: oneOf: - type: string title: value - description: The raw original item total's value. + description: The raw original total's value. - type: number title: value - description: The raw original item total's value. - raw_original_item_subtotal: + description: The raw original total's value. + raw_original_subtotal: type: object - description: The order preview's raw original item subtotal. + description: The item's raw original subtotal. required: - value properties: @@ -21352,13 +22282,13 @@ components: oneOf: - type: string title: value - description: The raw original item subtotal's value. + description: The raw original subtotal's value. - type: number title: value - description: The raw original item subtotal's value. - raw_original_item_tax_total: + description: The raw original subtotal's value. + raw_original_tax_total: type: object - description: The order preview's raw original item tax total. + description: The item's raw original tax total. required: - value properties: @@ -21366,13 +22296,13 @@ components: oneOf: - type: string title: value - description: The raw original item tax total's value. + description: The raw original tax total's value. - type: number title: value - description: The raw original item tax total's value. + description: The raw original tax total's value. raw_item_total: type: object - description: The order preview's raw item total. + description: The item's raw item total. required: - value properties: @@ -21386,7 +22316,7 @@ components: description: The raw item total's value. raw_item_subtotal: type: object - description: The order preview's raw item subtotal. + description: The item's raw item subtotal. required: - value properties: @@ -21400,7 +22330,7 @@ components: description: The raw item subtotal's value. raw_item_tax_total: type: object - description: The order preview's raw item tax total. + description: The item's raw item tax total. required: - value properties: @@ -21412,9 +22342,9 @@ components: - type: number title: value description: The raw item tax total's value. - raw_original_total: + raw_total: type: object - description: The order preview's raw original total. + description: The item's raw total. required: - value properties: @@ -21422,13 +22352,13 @@ components: oneOf: - type: string title: value - description: The raw original total's value. + description: The raw total's value. - type: number title: value - description: The raw original total's value. - raw_original_subtotal: + description: The raw total's value. + raw_subtotal: type: object - description: The order preview's raw original subtotal. + description: The item's raw subtotal. required: - value properties: @@ -21436,13 +22366,13 @@ components: oneOf: - type: string title: value - description: The raw original subtotal's value. + description: The raw subtotal's value. - type: number title: value - description: The raw original subtotal's value. - raw_original_tax_total: + description: The raw subtotal's value. + raw_tax_total: type: object - description: The order preview's raw original tax total. + description: The item's raw tax total. required: - value properties: @@ -21450,13 +22380,13 @@ components: oneOf: - type: string title: value - description: The raw original tax total's value. + description: The raw tax total's value. - type: number title: value - description: The raw original tax total's value. - raw_total: + description: The raw tax total's value. + raw_discount_total: type: object - description: The order preview's raw total. + description: The item's raw discount total. required: - value properties: @@ -21464,13 +22394,13 @@ components: oneOf: - type: string title: value - description: The raw total's value. + description: The raw discount total's value. - type: number title: value - description: The raw total's value. - raw_subtotal: + description: The raw discount total's value. + raw_discount_tax_total: type: object - description: The order preview's raw subtotal. + description: The item's raw discount tax total. required: - value properties: @@ -21478,13 +22408,13 @@ components: oneOf: - type: string title: value - description: The raw subtotal's value. + description: The raw discount tax total's value. - type: number title: value - description: The raw subtotal's value. - raw_tax_total: + description: The raw discount tax total's value. + raw_refundable_total: type: object - description: The order preview's raw tax total. + description: The item's raw refundable total. required: - value properties: @@ -21492,13 +22422,13 @@ components: oneOf: - type: string title: value - description: The raw tax total's value. + description: The raw refundable total's value. - type: number title: value - description: The raw tax total's value. - raw_discount_total: + description: The raw refundable total's value. + raw_refundable_total_per_unit: type: object - description: The order preview's raw discount total. + description: The item's raw refundable total per unit. required: - value properties: @@ -21506,13 +22436,238 @@ components: oneOf: - type: string title: value - description: The raw discount total's value. + description: The raw refundable total per unit's value. - type: number title: value - description: The raw discount total's value. - raw_discount_tax_total: + description: The raw refundable total per unit's value. + OrderLineItemAdjustment: + type: object + description: The line item adjustment's details. + x-schemaName: OrderLineItemAdjustment + required: + - item + - item_id + - id + - amount + - order_id + - created_at + - updated_at + properties: + item: + $ref: '#/components/schemas/OrderLineItem' + item_id: + type: string + title: item_id + description: The ID of the item this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion applied by this adjustment. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. + OrderLineItemTaxLine: + type: object + description: The line item tax line's details. + x-schemaName: OrderLineItemTaxLine + required: + - item + - item_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at + properties: + item: + type: object + item_id: + type: string + title: item_id + description: The ID of the line item that the tax line belongs to. + total: + type: number + title: total + description: The item's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate the tax lines. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. + OrderReturnItem: + type: object + description: The item's items. + x-schemaName: OrderReturnItem + required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id + properties: + id: + type: string + title: id + description: The return item's ID. + quantity: + type: number + title: quantity + description: The return item's quantity. + received_quantity: + type: number + title: received_quantity + description: The received quantity of the item. This quantity is added to the stocked inventory quantity of the item. + damaged_quantity: + type: number + title: damaged_quantity + description: The received damaged quantity of the item, which isn't added to the stocked inventory quantity of the item. + reason_id: + type: string + title: reason_id + description: The ID of the return reason associated with the item. + note: + type: string + title: note + description: A note about why the item was returned. + item_id: + type: string + title: item_id + description: The ID of the associated order item. + return_id: + type: string + title: return_id + description: The ID of the return this return item belongs to. + metadata: + type: object + description: The return item's metadata, can hold custom key-value pairs. + OrderShippingMethod: + type: object + description: The shipping method's details. + x-schemaName: OrderShippingMethod + required: + - id + - order_id + - name + - amount + - raw_amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + properties: + id: + type: string + title: id + description: The shipping method's ID. + order_id: + type: string + title: order_id + description: The ID of the order that the shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + raw_amount: type: object - description: The order preview's raw discount tax total. + description: The shipping method's raw amount. required: - value properties: @@ -21520,13 +22675,81 @@ components: oneOf: - type: string title: value - description: The raw discount tax total's value. + description: The raw amount's value. - type: number title: value - description: The raw discount tax total's value. - raw_gift_card_total: + description: The raw amount's value. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount includes taxes. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: The shipping method's data, useful for the fulfillment provider handling the fulfillment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/order/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: '#/components/schemas/OrderShippingMethodTaxLine' + adjustments: + type: array + description: The shipping method's adjustments. + items: + $ref: '#/components/schemas/OrderShippingMethodAdjustment' + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The shipping method's subtotal excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the shipping method excluding promotions. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes of the shipping method, including promotions. + discount_total: + type: number + title: discount_total + description: The shipping method's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes of the discount amount. + raw_original_total: type: object - description: The order preview's raw gift card total. + description: The shipping method's raw original total. required: - value properties: @@ -21534,13 +22757,13 @@ components: oneOf: - type: string title: value - description: The raw gift card total's value. + description: The raw original total's value. - type: number title: value - description: The raw gift card total's value. - raw_gift_card_tax_total: + description: The raw original total's value. + raw_original_subtotal: type: object - description: The order preview's raw gift card tax total. + description: The shipping method's raw original subtotal. required: - value properties: @@ -21548,13 +22771,13 @@ components: oneOf: - type: string title: value - description: The raw gift card tax total's value. + description: The raw original subtotal's value. - type: number title: value - description: The raw gift card tax total's value. - raw_shipping_total: + description: The raw original subtotal's value. + raw_original_tax_total: type: object - description: The order preview's raw shipping total. + description: The shipping method's raw original tax total. required: - value properties: @@ -21562,13 +22785,13 @@ components: oneOf: - type: string title: value - description: The raw shipping total's value. + description: The raw original tax total's value. - type: number title: value - description: The raw shipping total's value. - raw_shipping_subtotal: + description: The raw original tax total's value. + raw_total: type: object - description: The order preview's raw shipping subtotal. + description: The shipping method's raw total. required: - value properties: @@ -21576,13 +22799,13 @@ components: oneOf: - type: string title: value - description: The raw shipping subtotal's value. + description: The raw total's value. - type: number title: value - description: The raw shipping subtotal's value. - raw_shipping_tax_total: + description: The raw total's value. + raw_subtotal: type: object - description: The order preview's raw shipping tax total. + description: The shipping method's raw subtotal. required: - value properties: @@ -21590,13 +22813,13 @@ components: oneOf: - type: string title: value - description: The raw shipping tax total's value. + description: The raw subtotal's value. - type: number title: value - description: The raw shipping tax total's value. - raw_original_shipping_total: + description: The raw subtotal's value. + raw_tax_total: type: object - description: The order preview's raw original shipping total. + description: The shipping method's raw tax total. required: - value properties: @@ -21604,13 +22827,13 @@ components: oneOf: - type: string title: value - description: The raw original shipping total's value. + description: The raw tax total's value. - type: number title: value - description: The raw original shipping total's value. - raw_original_shipping_subtotal: + description: The raw tax total's value. + raw_discount_total: type: object - description: The order preview's raw original shipping subtotal. + description: The shipping method's raw discount total. required: - value properties: @@ -21618,13 +22841,13 @@ components: oneOf: - type: string title: value - description: The raw original shipping subtotal's value. + description: The raw discount total's value. - type: number title: value - description: The raw original shipping subtotal's value. - raw_original_shipping_tax_total: + description: The raw discount total's value. + raw_discount_tax_total: type: object - description: The order preview's raw original shipping tax total. + description: The shipping method's raw discount tax total. required: - value properties: @@ -21632,34 +22855,152 @@ components: oneOf: - type: string title: value - description: The raw original shipping tax total's value. + description: The raw discount tax total's value. - type: number title: value - description: The raw original shipping tax total's value. + description: The raw discount tax total's value. OrderShippingMethodAdjustment: type: object - description: The adjustment's adjustments. + description: The shipping method adjustment's details. x-schemaName: OrderShippingMethodAdjustment + required: + - shipping_method + - shipping_method_id + - id + - amount + - order_id + - created_at + - updated_at + properties: + shipping_method: + $ref: '#/components/schemas/OrderShippingMethod' + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method this adjustment is for. + id: + type: string + title: id + description: The adjustment's ID. + code: + type: string + title: code + description: The adjustment's code. + amount: + type: number + title: amount + description: The adjustment's amount. + order_id: + type: string + title: order_id + description: The ID of the associated order. + description: + type: string + title: description + description: The adjustment's description. + promotion_id: + type: string + title: promotion_id + description: The ID of the promotion this adjustment applies. + provider_id: + type: string + title: provider_id + description: The adjustment's provider ID. + created_at: + type: string + format: date-time + title: created_at + description: The date the adjustment was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the adjustment was updated. OrderShippingMethodTaxLine: type: object - description: The tax line's tax lines. + description: The shipping method tax line's details. x-schemaName: OrderShippingMethodTaxLine + required: + - shipping_method + - shipping_method_id + - total + - subtotal + - raw_total + - raw_subtotal + - id + - code + - rate + - created_at + - updated_at + properties: + shipping_method: + type: object + shipping_method_id: + type: string + title: shipping_method_id + description: The ID of the shipping method that this tax line is for. + total: + type: number + title: total + description: The shipping method's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The shipping method's total excluding taxes, including promotions. + raw_total: + type: object + description: The tax line's raw total. + raw_subtotal: + type: object + description: The tax line's raw subtotal. + id: + type: string + title: id + description: The tax line's ID. + description: + type: string + title: description + description: The tax line's description. + tax_rate_id: + type: string + title: tax_rate_id + description: The ID of the applied tax rate. + code: + type: string + title: code + description: The code that the tax rate is identified by. + rate: + type: number + title: rate + description: The rate to charge. + provider_id: + type: string + title: provider_id + description: The ID of the tax provider used to calculate taxes. + created_at: + type: string + format: date-time + title: created_at + description: The date the tax line was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tax line was updated. OrderTransaction: type: object - description: The transaction's transactions. + description: The transaction's details. x-schemaName: OrderTransaction required: - id - order_id - - order - amount - - raw_amount - currency_code - reference - reference_id + - metadata - created_at - updated_at - - metadata properties: id: type: string @@ -21668,132 +23009,388 @@ components: order_id: type: string title: order_id - description: The transaction's order id. - order: - type: object + description: The ID of the order this transaction belongs to. amount: - oneOf: - - type: string - title: amount - description: The transaction's amount. - - type: number - title: amount - description: The transaction's amount. - - type: string - title: amount - description: The transaction's amount. - - $ref: '#/components/schemas/IBigNumber' - raw_amount: - type: object - description: The transaction's raw amount. + type: number + title: amount + description: The transaction's amount. currency_code: type: string title: currency_code description: The transaction's currency code. + example: usd reference: type: string title: reference - description: The transaction's reference. + description: The name of a table that this transaction references. If this transaction is for captured payment, its value is `capture`. If this transaction is for refunded payment, its value is `refund`. + enum: + - capture + - refund reference_id: type: string title: reference_id - description: The transaction's reference id. + description: The ID of the referenced record in the referenced table. + metadata: + type: object + description: The transaction's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The transaction's created at. + description: The date that the transaction was created. updated_at: type: string format: date-time title: updated_at - description: The transaction's updated at. + description: The date that the transaction was updated. + RefundReason: + type: object + description: The refund's refund reason. + x-schemaName: RefundReason + required: + - id + - label + - metadata + - created_at + - updated_at + properties: + id: + type: string + title: id + description: The refund reason's ID. + label: + type: string + title: label + description: The refund reason's label. + description: + type: string + title: description + description: The refund reason's description. metadata: type: object - description: The transaction's metadata. + description: The refund reason's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The refund reason's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The refund reason's updated at. RefundReasonResponse: type: object - description: SUMMARY + description: The refund reason's details. x-schemaName: RefundReasonResponse required: - refund_reason properties: refund_reason: $ref: '#/components/schemas/AdminRefundReason' - ReservationResponse: + Return: type: object - description: The reservation's details. - x-schemaName: ReservationResponse + description: The return's details. + x-schemaName: Return required: - id - - line_item_id - - location_id - - quantity - - external_id - - description - - inventory_item_id - - inventory_item + - status + - order_id + - items + - currency_code + - created_at + - updated_at + - original_item_total + - original_item_subtotal + - original_item_tax_total + - item_total + - item_subtotal + - item_tax_total + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + - gift_card_total + - gift_card_tax_total + - shipping_total + - shipping_subtotal + - shipping_tax_total + - original_shipping_total + - original_shipping_subtotal + - original_shipping_tax_total + - discount_subtotal + - raw_original_item_total + - raw_original_item_subtotal + - raw_original_item_tax_total + - raw_item_total + - raw_item_subtotal + - raw_item_tax_total + - raw_original_total + - raw_original_subtotal + - raw_original_tax_total + - raw_total + - raw_subtotal + - raw_tax_total + - raw_discount_total + - raw_discount_tax_total + - raw_gift_card_total + - raw_gift_card_tax_total + - raw_shipping_total + - raw_shipping_subtotal + - raw_shipping_tax_total + - raw_original_shipping_total + - raw_original_shipping_subtotal + - raw_original_shipping_tax_total properties: id: type: string title: id - description: The reservation's ID. - line_item_id: + description: The return's ID. + status: + type: string + description: The return's status. + enum: + - canceled + - requested + - received + - partially_received + refund_amount: + type: number + title: refund_amount + description: The amount refunded by this return. + order_id: type: string - title: line_item_id - description: The reservation's line item id. - location_id: + title: order_id + description: The ID of the associated order. + items: + type: array + description: The return's items. + items: + $ref: '#/components/schemas/OrderReturnItem' + region_id: type: string - title: location_id - description: The reservation's location id. - quantity: + title: region_id + description: The ID of the region this return belongs to. + customer_id: type: string - title: quantity - description: The reservation's quantity. - external_id: + title: customer_id + description: The ID of the customer that placed the order. + sales_channel_id: type: string - title: external_id - description: The reservation's external id. - description: + title: sales_channel_id + description: The ID of the associated order's sales channel. + email: type: string - title: description - description: The reservation's description. - inventory_item_id: + title: email + description: The email of the customer that placed the order. + format: email + currency_code: type: string - title: inventory_item_id - description: The reservation's inventory item id. - inventory_item: + title: currency_code + description: The return's currency code. + example: usd + shipping_address: + $ref: '#/components/schemas/OrderAddress' + billing_address: + $ref: '#/components/schemas/OrderAddress' + shipping_methods: + type: array + description: The return's shipping methods. + items: + $ref: '#/components/schemas/OrderShippingMethod' + transactions: + type: array + description: The return's transactions. + items: + $ref: '#/components/schemas/OrderTransaction' + summary: type: object - description: The reservation's inventory item. + description: The return's summary. metadata: type: object - description: The reservation's metadata. - created_by: - type: string - title: created_by - description: The reservation's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The reservation's deleted at. + description: The return's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The reservation's created at. + description: The date the return was created. updated_at: type: string format: date-time title: updated_at - description: The reservation's updated at. - Return: - type: object - description: The order change's return order. - x-schemaName: Return + description: The date the return was updated. + original_item_total: + type: number + title: original_item_total + description: The return's original item total. + original_item_subtotal: + type: number + title: original_item_subtotal + description: The return's original item subtotal. + original_item_tax_total: + type: number + title: original_item_tax_total + description: The return's original item tax total. + item_total: + type: number + title: item_total + description: The return's item total. + item_subtotal: + type: number + title: item_subtotal + description: The return's item subtotal. + item_tax_total: + type: number + title: item_tax_total + description: The return's item tax total. + original_total: + type: number + title: original_total + description: The return's original total. + original_subtotal: + type: number + title: original_subtotal + description: The return's original subtotal. + original_tax_total: + type: number + title: original_tax_total + description: The return's original tax total. + total: + type: number + title: total + description: The return's total. + subtotal: + type: number + title: subtotal + description: The return's subtotal. + tax_total: + type: number + title: tax_total + description: The return's tax total. + discount_total: + type: number + title: discount_total + description: The return's discount total. + discount_tax_total: + type: number + title: discount_tax_total + description: The return's discount tax total. + gift_card_total: + type: number + title: gift_card_total + description: The return's gift card total. + gift_card_tax_total: + type: number + title: gift_card_tax_total + description: The return's gift card tax total. + shipping_total: + type: number + title: shipping_total + description: The return's shipping total. + shipping_subtotal: + type: number + title: shipping_subtotal + description: The return's shipping subtotal. + shipping_tax_total: + type: number + title: shipping_tax_total + description: The return's shipping tax total. + original_shipping_total: + type: number + title: original_shipping_total + description: The return's original shipping total. + original_shipping_subtotal: + type: number + title: original_shipping_subtotal + description: The return's original shipping subtotal. + original_shipping_tax_total: + type: number + title: original_shipping_tax_total + description: The return's original shipping tax total. + order_change: + type: object + canceled_at: + type: string + title: canceled_at + description: The date the return was canceled. + format: date-time + discount_subtotal: + type: number + title: discount_subtotal + description: The return's discount subtotal. + raw_original_item_total: + type: object + description: The return's raw original item total. + raw_original_item_subtotal: + type: object + description: The return's raw original item subtotal. + raw_original_item_tax_total: + type: object + description: The return's raw original item tax total. + raw_item_total: + type: object + description: The return's raw item total. + raw_item_subtotal: + type: object + description: The return's raw item subtotal. + raw_item_tax_total: + type: object + description: The return's raw item tax total. + raw_original_total: + type: object + description: The return's raw original total. + raw_original_subtotal: + type: object + description: The return's raw original subtotal. + raw_original_tax_total: + type: object + description: The return's raw original tax total. + raw_total: + type: object + description: The return's raw total. + raw_subtotal: + type: object + description: The return's raw subtotal. + raw_tax_total: + type: object + description: The return's raw tax total. + raw_discount_total: + type: object + description: The return's raw discount total. + raw_discount_tax_total: + type: object + description: The return's raw discount tax total. + raw_gift_card_total: + type: object + description: The return's raw gift card total. + raw_gift_card_tax_total: + type: object + description: The return's raw gift card tax total. + raw_shipping_total: + type: object + description: The return's raw shipping total. + raw_shipping_subtotal: + type: object + description: The return's raw shipping subtotal. + raw_shipping_tax_total: + type: object + description: The return's raw shipping tax total. + raw_original_shipping_total: + type: object + description: The return's raw original shipping total. + raw_original_shipping_subtotal: + type: object + description: The return's raw original shipping subtotal. + raw_original_shipping_tax_total: + type: object + description: The return's raw original shipping tax total. StoreAddCartLineItem: type: object - description: SUMMARY + description: The details of the line item to add. x-schemaName: StoreAddCartLineItem required: - variant_id @@ -21802,30 +23399,21 @@ components: variant_id: type: string title: variant_id - description: The cart's variant id. + description: The ID of the product variant to add to the cart. quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. - StoreCalculateCartTaxes: - type: object - description: SUMMARY - x-schemaName: StoreCalculateCartTaxes - properties: - fields: - type: string - title: fields - description: The cart's fields. + description: The item's metadata, can hold custom key-value pairs. StoreCart: type: object - description: The cart's parent. + description: The cart's details. x-schemaName: StoreCart required: - - id - currency_code + - id - original_item_total - original_item_subtotal - original_item_tax_total @@ -21852,326 +23440,151 @@ components: id: type: string title: id - description: The parent's ID. + description: The cart's ID. region: - $ref: '#/components/schemas/BaseRegion' + $ref: '#/components/schemas/StoreRegion' region_id: type: string title: region_id - description: The parent's region id. + description: The ID of the region the cart belongs to. customer_id: type: string title: customer_id - description: The parent's customer id. + description: The ID of the customer the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The parent's sales channel id. + description: The ID of the cart's sales channel. Only products that belong to the same sales channel can be added to the cart. The created order will be associated with the same sales channel. email: type: string title: email - description: The parent's email. + description: The email of the customer the cart belongs to. format: email currency_code: type: string title: currency_code - description: The parent's currency code. + description: The cart's currency code. + example: usd shipping_address: - $ref: '#/components/schemas/BaseCartAddress' + $ref: '#/components/schemas/StoreCartAddress' billing_address: - $ref: '#/components/schemas/BaseCartAddress' + $ref: '#/components/schemas/StoreCartAddress' items: type: array - description: The parent's items. + description: The cart's items. items: - $ref: '#/components/schemas/BaseCartLineItem' + $ref: '#/components/schemas/StoreCartLineItem' shipping_methods: type: array - description: The parent's shipping methods. + description: The cart's shipping methods. items: - $ref: '#/components/schemas/BaseCartShippingMethod' + $ref: '#/components/schemas/StoreCartShippingMethod' payment_collection: - $ref: '#/components/schemas/BasePaymentCollection' + $ref: '#/components/schemas/StorePaymentCollection' metadata: type: object - description: The parent's metadata. + description: The cart's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the cart was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the cart was updated. original_item_total: - oneOf: - - type: string - title: original_item_total - description: The parent's original item total. - - type: number - title: original_item_total - description: The parent's original item total. - - type: string - title: original_item_total - description: The parent's original item total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_item_total + description: The cart items' total including taxes, excluding promotions. original_item_subtotal: - oneOf: - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - type: number - title: original_item_subtotal - description: The parent's original item subtotal. - - type: string - title: original_item_subtotal - description: The parent's original item subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_item_subtotal + description: The cart items' total excluding taxes, including promotions. original_item_tax_total: - oneOf: - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - type: number - title: original_item_tax_total - description: The parent's original item tax total. - - type: string - title: original_item_tax_total - description: The parent's original item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_item_tax_total + description: The cart items' tax total excluding promotions. item_total: - oneOf: - - type: string - title: item_total - description: The parent's item total. - - type: number - title: item_total - description: The parent's item total. - - type: string - title: item_total - description: The parent's item total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_total + description: The cart items' total including taxes and promotions. item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The parent's item subtotal. - - type: number - title: item_subtotal - description: The parent's item subtotal. - - type: string - title: item_subtotal - description: The parent's item subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_subtotal + description: The cart items' total excluding taxes, including promotions. item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The parent's item tax total. - - type: number - title: item_tax_total - description: The parent's item tax total. - - type: string - title: item_tax_total - description: The parent's item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: item_tax_total + description: The cart items' tax total including promotions. original_total: - oneOf: - - type: string - title: original_total - description: The parent's original total. - - type: number - title: original_total - description: The parent's original total. - - type: string - title: original_total - description: The parent's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The cart's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The parent's original subtotal. - - type: number - title: original_subtotal - description: The parent's original subtotal. - - type: string - title: original_subtotal - description: The parent's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The cart's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The parent's original tax total. - - type: number - title: original_tax_total - description: The parent's original tax total. - - type: string - title: original_tax_total - description: The parent's original tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The cart's tax total excluding promotions. total: - oneOf: - - type: string - title: total - description: The parent's total. - - type: number - title: total - description: The parent's total. - - type: string - title: total - description: The parent's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The cart's total including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The parent's subtotal. - - type: number - title: subtotal - description: The parent's subtotal. - - type: string - title: subtotal - description: The parent's subtotal. - - $ref: '#/components/schemas/IBigNumber' - tax_total: - oneOf: - - type: string - title: tax_total - description: The parent's tax total. - - type: number - title: tax_total - description: The parent's tax total. - - type: string - title: tax_total - description: The parent's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The cart's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The cart's tax total including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The parent's discount total. - - type: number - title: discount_total - description: The parent's discount total. - - type: string - title: discount_total - description: The parent's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The cart's discount total. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - type: number - title: discount_tax_total - description: The parent's discount tax total. - - type: string - title: discount_tax_total - description: The parent's discount tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_tax_total + description: The tax total applied on the discounted amount. gift_card_total: - oneOf: - - type: string - title: gift_card_total - description: The parent's gift card total. - - type: number - title: gift_card_total - description: The parent's gift card total. - - type: string - title: gift_card_total - description: The parent's gift card total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: gift_card_total + description: The total gift card amount applied on the cart. gift_card_tax_total: - oneOf: - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: number - title: gift_card_tax_total - description: The parent's gift card tax total. - - type: string - title: gift_card_tax_total - description: The parent's gift card tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: gift_card_tax_total + description: The total taxes applied on the gift card amount. shipping_total: - oneOf: - - type: string - title: shipping_total - description: The parent's shipping total. - - type: number - title: shipping_total - description: The parent's shipping total. - - type: string - title: shipping_total - description: The parent's shipping total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: shipping_total + description: The cart's shipping total including taxes and promotions. shipping_subtotal: - oneOf: - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: number - title: shipping_subtotal - description: The parent's shipping subtotal. - - type: string - title: shipping_subtotal - description: The parent's shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. shipping_tax_total: - oneOf: - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - type: number - title: shipping_tax_total - description: The parent's shipping tax total. - - type: string - title: shipping_tax_total - description: The parent's shipping tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: shipping_tax_total + description: The total taxes applied on the cart's shipping amount. original_shipping_total: - oneOf: - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - type: number - title: original_shipping_total - description: The parent's original shipping total. - - type: string - title: original_shipping_total - description: The parent's original shipping total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_shipping_total + description: The cart's shipping total including taxes, excluding promotions. original_shipping_subtotal: - oneOf: - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: number - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - type: string - title: original_shipping_subtotal - description: The parent's original shipping subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_shipping_subtotal + description: The cart's shipping total excluding taxes, including promotions. original_shipping_tax_total: - oneOf: - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: number - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - type: string - title: original_shipping_tax_total - description: The parent's original shipping tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_shipping_tax_total + description: The total taxes applied on the cart's shipping amount. StoreCartAddress: type: object - description: The cart's billing address. + description: The address's details. x-schemaName: StoreCartAddress required: - id @@ -22181,97 +23594,90 @@ components: id: type: string title: id - description: The billing address's ID. + description: The address's ID. customer_id: type: string title: customer_id - description: The billing address's customer id. + description: The ID of the customer the address belongs to. first_name: type: string title: first_name - description: The billing address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The billing address's last name. + description: The address's last name. phone: type: string title: phone - description: The billing address's phone. + description: The address's phone. company: type: string title: company - description: The billing address's company. + description: The address's company. address_1: type: string title: address_1 - description: The billing address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The billing address's address 2. + description: The address's second line. city: type: string title: city - description: The billing address's city. + description: The address's city. country_code: type: string title: country_code - description: The billing address's country code. + description: The address's country code. + example: us province: type: string title: province - description: The billing address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The billing address's postal code. + description: The address's postal code. metadata: type: object - description: The billing address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: - oneOf: - - type: string - title: created_at - description: The billing address's created at. - - type: string - title: created_at - description: The billing address's created at. - format: date-time + type: string + title: created_at + description: The date the address was created. + format: date-time updated_at: - oneOf: - - type: string - title: updated_at - description: The billing address's updated at. - - type: string - title: updated_at - description: The billing address's updated at. - format: date-time + type: string + title: updated_at + description: The date the address was updated. + format: date-time StoreCartLineItem: type: object - description: The item's items. + description: The item's details. x-schemaName: StoreCartLineItem required: - - id - - title - - quantity - - requires_shipping - - is_discountable - - is_tax_inclusive - - unit_price - cart - - cart_id - - original_total - - original_subtotal - - original_tax_total + - title + - id - item_total - item_subtotal - item_tax_total + - original_total + - original_subtotal + - original_tax_total - total - subtotal - tax_total - discount_total - discount_tax_total + - requires_shipping + - is_discountable + - is_tax_inclusive + - unit_price + - quantity + - cart_id properties: id: type: string @@ -22288,25 +23694,17 @@ components: thumbnail: type: string title: thumbnail - description: The item's thumbnail. + description: The item's thumbnail URL. quantity: - oneOf: - - type: string - title: quantity - description: The item's quantity. - - type: number - title: quantity - description: The item's quantity. - - type: string - title: quantity - description: The item's quantity. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: quantity + description: The item's quantity. product: - $ref: '#/components/schemas/BaseProduct' + $ref: '#/components/schemas/StoreProduct' product_id: type: string title: product_id - description: The item's product id. + description: The ID of the associated product. product_title: type: string title: product_title @@ -22322,25 +23720,25 @@ components: product_type: type: string title: product_type - description: The item's product type. + description: The ID of the associated product's type. product_collection: type: string title: product_collection - description: The item's product collection. + description: The ID of the associated product's collection. product_handle: type: string title: product_handle description: The item's product handle. variant: - $ref: '#/components/schemas/BaseProductVariant' + $ref: '#/components/schemas/StoreProductVariant' variant_id: type: string title: variant_id - description: The item's variant id. + description: The ID of the associated product variant. variant_sku: type: string title: variant_sku - description: The item's variant sku. + description: The item's variant SKU. variant_barcode: type: string title: variant_barcode @@ -22351,43 +23749,29 @@ components: description: The item's variant title. variant_option_values: type: object - description: The item's variant option values. + description: The associated variant's value for the product's options. + example: + Color: Red requires_shipping: type: boolean title: requires_shipping - description: The item's requires shipping. + description: Whether the item requires shipping. is_discountable: type: boolean title: is_discountable - description: The item's is discountable. + description: Whether the item is discountable. is_tax_inclusive: type: boolean title: is_tax_inclusive - description: The item's is tax inclusive. + description: Whether the item's price includes taxes. compare_at_unit_price: - oneOf: - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - type: number - title: compare_at_unit_price - description: The item's compare at unit price. - - type: string - title: compare_at_unit_price - description: The item's compare at unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: compare_at_unit_price + description: The original price of the item before a promotion or sale. unit_price: - oneOf: - - type: string - title: unit_price - description: The item's unit price. - - type: number - title: unit_price - description: The item's unit price. - - type: string - title: unit_price - description: The item's unit price. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: unit_price + description: The price of a single quantity of the item. tax_lines: type: array description: The item's tax lines. @@ -22399,170 +23783,191 @@ components: items: $ref: '#/components/schemas/BaseLineItemAdjustment' cart: - $ref: '#/components/schemas/BaseCart' + type: object cart_id: type: string title: cart_id - description: The item's cart id. + description: The ID of the cart that the line item belongs to. metadata: type: object - description: The item's metadata. + description: The item's metadata, can hold custom key-value pairs. created_at: type: string title: created_at - description: The item's created at. + description: The date the item was created. format: date-time updated_at: type: string title: updated_at - description: The item's updated at. + description: The date the item was updated. format: date-time deleted_at: type: string title: deleted_at - description: The item's deleted at. + description: The date the item was deleted. format: date-time original_total: - oneOf: - - type: string - title: original_total - description: The item's original total. - - type: number - title: original_total - description: The item's original total. - - type: string - title: original_total - description: The item's original total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_total + description: The item's total including taxes, excluding promotions. + original_subtotal: + type: number + title: original_subtotal + description: The item's total excluding taxes, including promotions. + original_tax_total: + type: number + title: original_tax_total + description: The total taxes of the item excluding promotions. + item_total: + type: number + title: original_tax_total + description: The item's total including taxes and promotions. + item_subtotal: + type: number + title: item_subtotal + description: The item's total excluding taxes, including promotions. + item_tax_total: + type: number + title: item_tax_total + description: The total taxes of the item including promotions. + total: + type: number + title: total + description: The item's total including taxes and promotions. + subtotal: + type: number + title: subtotal + description: The item's total excluding taxes, including promotions. + tax_total: + type: number + title: tax_total + description: The total taxes of the item including promotions. + discount_total: + type: number + title: discount_total + description: The total discount of the item. + discount_tax_total: + type: number + title: discount_tax_total + description: The total taxes applied on the discounted amount. + StoreCartResponse: + type: object + description: The cart's details. + x-schemaName: StoreCartResponse + required: + - cart + properties: + cart: + $ref: '#/components/schemas/StoreCart' + StoreCartShippingMethod: + type: object + description: A cart's shipping method. + x-schemaName: StoreCartShippingMethod + required: + - id + - cart_id + - name + - amount + - is_tax_inclusive + - created_at + - updated_at + - original_total + - original_subtotal + - original_tax_total + - total + - subtotal + - tax_total + - discount_total + - discount_tax_total + properties: + id: + type: string + title: id + description: The shipping method's ID. + cart_id: + type: string + title: cart_id + description: The ID of the cart this shipping method belongs to. + name: + type: string + title: name + description: The shipping method's name. + description: + type: string + title: description + description: The shipping method's description. + amount: + type: number + title: amount + description: The shipping method's amount. + is_tax_inclusive: + type: boolean + title: is_tax_inclusive + description: Whether the shipping method's amount is tax inclusive. + shipping_option_id: + type: string + title: shipping_option_id + description: The ID of the shipping option this method was created from. + data: + type: object + description: The shipping method's data, useful for fulfillment handling by third-party services. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property + metadata: + type: object + description: The shipping method's metadata, can hold custom key-value pairs. + tax_lines: + type: array + description: The shipping method's tax lines. + items: + $ref: '#/components/schemas/BaseShippingMethodTaxLine' + adjustments: + type: array + description: The shipping method's adjustments, such as applied promotions. + items: + $ref: '#/components/schemas/BaseShippingMethodAdjustment' + created_at: + type: string + format: date-time + title: created_at + description: The date the shipping method was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the shipping method was updated. + original_total: + type: number + title: original_total + description: The shipping method's total including taxes, excluding promotions. original_subtotal: - oneOf: - - type: string - title: original_subtotal - description: The item's original subtotal. - - type: number - title: original_subtotal - description: The item's original subtotal. - - type: string - title: original_subtotal - description: The item's original subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_subtotal + description: The shipping method's total excluding taxes, including promotions. original_tax_total: - oneOf: - - type: string - title: original_tax_total - description: The item's original tax total. - - type: number - title: original_tax_total - description: The item's original tax total. - - type: string - title: original_tax_total - description: The item's original tax total. - - $ref: '#/components/schemas/IBigNumber' - item_total: - oneOf: - - type: string - title: item_total - description: The item's item total. - - type: number - title: item_total - description: The item's item total. - - type: string - title: item_total - description: The item's item total. - - $ref: '#/components/schemas/IBigNumber' - item_subtotal: - oneOf: - - type: string - title: item_subtotal - description: The item's item subtotal. - - type: number - title: item_subtotal - description: The item's item subtotal. - - type: string - title: item_subtotal - description: The item's item subtotal. - - $ref: '#/components/schemas/IBigNumber' - item_tax_total: - oneOf: - - type: string - title: item_tax_total - description: The item's item tax total. - - type: number - title: item_tax_total - description: The item's item tax total. - - type: string - title: item_tax_total - description: The item's item tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: original_tax_total + description: The total taxes applied on the shipping method's amount including promotions. total: - oneOf: - - type: string - title: total - description: The item's total. - - type: number - title: total - description: The item's total. - - type: string - title: total - description: The item's total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: total + description: The shipping method's total amount including taxes and promotions. subtotal: - oneOf: - - type: string - title: subtotal - description: The item's subtotal. - - type: number - title: subtotal - description: The item's subtotal. - - type: string - title: subtotal - description: The item's subtotal. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: subtotal + description: The shipping method's total amount excluding taxes, including promotions. tax_total: - oneOf: - - type: string - title: tax_total - description: The item's tax total. - - type: number - title: tax_total - description: The item's tax total. - - type: string - title: tax_total - description: The item's tax total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: tax_total + description: The total taxes applied on the shipping method's amount including promotions. discount_total: - oneOf: - - type: string - title: discount_total - description: The item's discount total. - - type: number - title: discount_total - description: The item's discount total. - - type: string - title: discount_total - description: The item's discount total. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: discount_total + description: The total amount discounted. discount_tax_total: - oneOf: - - type: string - title: discount_tax_total - description: The item's discount tax total. - - type: number - title: discount_tax_total - description: The item's discount tax total. - - type: string - title: discount_tax_total - description: The item's discount tax total. - - $ref: '#/components/schemas/IBigNumber' - StoreCartResponse: - type: object - description: SUMMARY - x-schemaName: StoreCartResponse - required: - - cart - properties: - cart: - $ref: '#/components/schemas/StoreCart' + type: number + title: discount_tax_total + description: The taxes applied on the discounted amount. StoreCollection: type: object description: The collection's details. @@ -22592,17 +23997,17 @@ components: type: string format: date-time title: created_at - description: The collection's created at. + description: The date the collection was created. updated_at: type: string format: date-time title: updated_at - description: The collection's updated at. + description: The date the collection was updated. deleted_at: type: string format: date-time title: deleted_at - description: The collection's deleted at. + description: The date the collection was deleted. products: type: array description: The collection's products. @@ -22610,10 +24015,10 @@ components: $ref: '#/components/schemas/AdminProduct' metadata: type: object - description: The collection's metadata. + description: The collection's metadata, can hold custom key-value pairs. StoreCollectionResponse: type: object - description: SUMMARY + description: The collection's details. x-schemaName: StoreCollectionResponse required: - collection @@ -22622,13 +24027,13 @@ components: $ref: '#/components/schemas/StoreCollection' StoreCreateCart: type: object - description: SUMMARY + description: The details of the cart to be created. x-schemaName: StoreCreateCart properties: region_id: type: string title: region_id - description: The cart's region id. + description: The ID of the cart's region. This affects the prices and currency of the cart. shipping_address: $ref: '#/components/schemas/StoreCartAddress' billing_address: @@ -22636,12 +24041,13 @@ components: email: type: string title: email - description: The cart's email. + description: The email of the cart's customer. format: email currency_code: type: string title: currency_code - description: The cart's currency code. + description: The cart's currency code. If not provided, the region's currency is used. This affects prices in the cart, as well. + example: usd items: type: array description: The cart's items. @@ -22650,13 +24056,13 @@ components: sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: The ID of the sales channel that cart is created in. Only products available in that sales channel can be added to the cart. If not provided, the store's default sales channel is associated with the cart instead. metadata: type: object - description: The cart's metadata. + description: The cart's metadata, can hold custom key-value pairs. StoreCreateCustomer: type: object - description: SUMMARY + description: The details of the customer to create. x-schemaName: StoreCreateCustomer required: - email @@ -22684,10 +24090,10 @@ components: description: The customer's phone. metadata: type: object - description: The customer's metadata. + description: The customer's metadata, can hold custom key-value pairs. StoreCreatePaymentCollection: type: object - description: SUMMARY + description: The details of the payment collection to create. x-schemaName: StoreCreatePaymentCollection required: - cart_id @@ -22695,10 +24101,10 @@ components: cart_id: type: string title: cart_id - description: The payment collection's cart id. + description: The ID of the cart this payment collection is for. StoreCreateReturn: type: object - description: SUMMARY + description: The details of the return to create. x-schemaName: StoreCreateReturn required: - order_id @@ -22708,7 +24114,7 @@ components: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. items: type: array description: The return's items. @@ -22719,18 +24125,18 @@ components: note: type: string title: note - description: The return's note. + description: A note with more details about the return. receive_now: type: boolean title: receive_now - description: The return's receive now. + description: Whether to mark the return as received. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location that items are returned to. StoreCreateReturnItem: type: object - description: The item's items. + description: The details of the line item to create. x-schemaName: StoreCreateReturnItem required: - id @@ -22747,14 +24153,14 @@ components: reason_id: type: string title: reason_id - description: The item's reason id. + description: The ID of the associated return reason. note: type: string title: note - description: The item's note. + description: A note with more details about the returned item. StoreCreateReturnShipping: type: object - description: The return's return shipping. + description: The return's shipping details. x-schemaName: StoreCreateReturnShipping required: - option_id @@ -22762,11 +24168,11 @@ components: option_id: type: string title: option_id - description: The return shipping's option id. + description: The ID of the shipping option to use. price: type: number title: price - description: The return shipping's price. + description: The shipping's price. StoreCurrency: type: object description: The currency's details. @@ -22778,7 +24184,6 @@ components: - name - decimal_digits - rounding - - raw_rounding - created_at - updated_at - deleted_at @@ -22787,6 +24192,7 @@ components: type: string title: code description: The currency's code. + example: usd symbol: type: string title: symbol @@ -22807,39 +24213,24 @@ components: type: number title: rounding description: The currency's rounding. - raw_rounding: - type: object - description: The currency's raw rounding. - required: - - value - - precision - properties: - value: - type: string - title: value - description: The raw rounding's value. - precision: - type: number - title: precision - description: The raw rounding's precision. created_at: type: string format: date-time title: created_at - description: The currency's created at. + description: The date the currency was created. updated_at: type: string format: date-time title: updated_at - description: The currency's updated at. + description: The date the currency was updated. deleted_at: type: string format: date-time title: deleted_at - description: The currency's deleted at. + description: The date the currency was deleted. StoreCurrencyListResponse: type: object - description: SUMMARY + description: The paginated list of currencies. x-schemaName: StoreCurrencyListResponse required: - limit @@ -22850,23 +24241,23 @@ components: limit: type: number title: limit - description: The currency's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The currency's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The currency's count. + description: The total count of items. currencies: type: array - description: The currency's currencies. + description: The list of currencies. items: $ref: '#/components/schemas/StoreCurrency' StoreCurrencyResponse: type: object - description: SUMMARY + description: The currency's details. x-schemaName: StoreCurrencyResponse required: - currency @@ -22875,7 +24266,7 @@ components: $ref: '#/components/schemas/StoreCurrency' StoreCustomer: type: object - description: The customer's parent. + description: The customer's details. x-schemaName: StoreCustomer required: - id @@ -22890,66 +24281,66 @@ components: id: type: string title: id - description: The parent's ID. + description: The customer's ID. email: type: string title: email - description: The parent's email. + description: The customer's email. format: email default_billing_address_id: type: string title: default_billing_address_id - description: The parent's default billing address id. + description: The ID of the address used for billing by default. default_shipping_address_id: type: string title: default_shipping_address_id - description: The parent's default shipping address id. + description: The ID of the address used for shipping by default. company_name: type: string title: company_name - description: The parent's company name. + description: The customer's company name. first_name: type: string title: first_name - description: The parent's first name. + description: The customer's first name. last_name: type: string title: last_name - description: The parent's last name. + description: The customer's last name. addresses: type: array - description: The parent's addresses. + description: The customer's addresses. items: $ref: '#/components/schemas/BaseCustomerAddress' phone: type: string title: phone - description: The parent's phone. + description: The customer's phone. metadata: type: object - description: The parent's metadata. - created_by: - type: string - title: created_by - description: The parent's created by. - deleted_at: - type: string - format: date-time - title: deleted_at - description: The parent's deleted at. + description: The customer's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The parent's created at. + description: The date the customer was created. updated_at: type: string format: date-time title: updated_at - description: The parent's updated at. + description: The date the customer was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the customer was deleted. + created_by: + type: string + title: created_by + description: The customer's created by. StoreCustomerAddress: type: object - description: The customer's address. + description: The customer address's details x-schemaName: StoreCustomerAddress required: - id @@ -22978,19 +24369,19 @@ components: address_name: type: string title: address_name - description: The address's address name. + description: The address's name. is_default_shipping: type: boolean title: is_default_shipping - description: The address's is default shipping. + description: Whether the address is used for shipping by default. is_default_billing: type: boolean title: is_default_billing - description: The address's is default billing. + description: Whether the address is used for billing by default. customer_id: type: string title: customer_id - description: The address's customer id. + description: The ID of the customer the address belongs to. company: type: string title: company @@ -23006,11 +24397,11 @@ components: address_1: type: string title: address_1 - description: The address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The address's address 2. + description: The address's second line. city: type: string title: city @@ -23019,6 +24410,7 @@ components: type: string title: country_code description: The address's country code. + example: usd province: type: string title: province @@ -23033,20 +24425,20 @@ components: description: The address's phone. metadata: type: object - description: The address's metadata. + description: The address's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The address's created at. + description: The date the address was created. updated_at: type: string format: date-time title: updated_at - description: The address's updated at. + description: The date the address was updated. StoreCustomerAddressListResponse: type: object - description: SUMMARY + description: The paginated list of customer addresses. x-schemaName: StoreCustomerAddressListResponse required: - limit @@ -23057,23 +24449,23 @@ components: limit: type: number title: limit - description: The customer's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The customer's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The customer's count. + description: The total number of items. addresses: type: array - description: The customer's addresses. + description: The list of addresses. items: $ref: '#/components/schemas/StoreCustomerAddress' StoreCustomerAddressResponse: type: object - description: SUMMARY + description: The address's details. x-schemaName: StoreCustomerAddressResponse required: - address @@ -23082,7 +24474,7 @@ components: $ref: '#/components/schemas/StoreCustomerAddress' StoreCustomerResponse: type: object - description: SUMMARY + description: The customer's details. x-schemaName: StoreCustomerResponse required: - customer @@ -23091,7 +24483,7 @@ components: $ref: '#/components/schemas/StoreCustomer' StoreOrder: type: object - description: The cart's order. + description: The order's details. x-schemaName: StoreOrder required: - id @@ -23143,28 +24535,29 @@ components: region_id: type: string title: region_id - description: The order's region id. + description: The ID of the associated region. customer_id: type: string title: customer_id - description: The order's customer id. + description: The ID of the customer that placed the order. sales_channel_id: type: string title: sales_channel_id - description: The order's sales channel id. + description: The ID of the sales channel the order was placed in. email: type: string title: email - description: The order's email. + description: The email of the customer that placed the order. format: email currency_code: type: string title: currency_code description: The order's currency code. + example: usd display_id: type: number title: display_id - description: The order's display id. + description: The order's display ID. shipping_address: $ref: '#/components/schemas/BaseOrderAddress' billing_address: @@ -23215,74 +24608,69 @@ components: - shipped - partially_delivered - delivered - transactions: - type: array - description: The order's transactions. - items: - $ref: '#/components/schemas/BaseOrderTransaction' summary: $ref: '#/components/schemas/BaseOrderSummary' metadata: type: object - description: The order's metadata. + description: The order's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The order's created at. + description: The date the order was created. updated_at: type: string format: date-time title: updated_at - description: The order's updated at. + description: The date the order was updated. original_item_total: type: number title: original_item_total - description: The order's original item total. + description: The order items' total including taxes, excluding promotions. original_item_subtotal: type: number title: original_item_subtotal - description: The order's original item subtotal. + description: The order items' total excluding taxes, including promotions. original_item_tax_total: type: number title: original_item_tax_total - description: The order's original item tax total. + description: The total taxes applied on the order items, excluding promotions. item_total: type: number title: item_total - description: The order's item total. + description: The order items' total including taxes and promotions. item_subtotal: type: number title: item_subtotal - description: The order's item subtotal. + description: The order items' total excluding taxes, including promotions. item_tax_total: type: number title: item_tax_total - description: The order's item tax total. + description: The total taxes applied on the order's items, including promotions. original_total: type: number title: original_total - description: The order's original total. + description: The order's total including taxes, excluding promotions. original_subtotal: type: number title: original_subtotal - description: The order's original subtotal. + description: The order's total excluding taxes, including promotions. original_tax_total: type: number title: original_tax_total - description: The order's original tax total. + description: The total taxes of the order excluding promotions. total: type: number title: total - description: The order's total. + description: The order's total including taxes and promotions. subtotal: type: number title: subtotal - description: The order's subtotal. + description: The order's total excluding taxes, including promotions. tax_total: type: number title: tax_total - description: The order's tax total. + description: The tax totals of the order including promotions. discount_total: type: number title: discount_total @@ -23290,7 +24678,7 @@ components: discount_tax_total: type: number title: discount_tax_total - description: The order's discount tax total. + description: The total taxes applied on the discounted amount. gift_card_total: type: number title: gift_card_total @@ -23298,51 +24686,53 @@ components: gift_card_tax_total: type: number title: gift_card_tax_total - description: The order's gift card tax total. + description: The total taxes applied on the gift card's amount. shipping_total: type: number title: shipping_total - description: The order's shipping total. + description: The order's shipping total including taxes and promotions. shipping_subtotal: type: number title: shipping_subtotal - description: The order's shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. shipping_tax_total: type: number title: shipping_tax_total - description: The order's shipping tax total. + description: The total taxes of the order's shipping including promotions. original_shipping_total: type: number title: original_shipping_total - description: The order's original shipping total. + description: The order's shipping total including taxes, excluding promotions. original_shipping_subtotal: type: number title: original_shipping_subtotal - description: The order's original shipping subtotal. + description: The order's shipping total excluding taxes, including promotions. original_shipping_tax_total: type: number title: original_shipping_tax_total - description: The order's original shipping tax total. + description: The total taxes of the order's shipping excluding promotions. StoreOrderResponse: type: object - description: SUMMARY + description: The order's details. x-schemaName: StoreOrderResponse required: - order properties: order: - $ref: '#/components/schemas/StoreOrder' + type: string + title: order + description: The order's details. StorePaymentCollection: type: object description: The payment collection's details. x-schemaName: StorePaymentCollection required: + - payment_providers - id - currency_code - region_id - amount - status - - payment_providers properties: id: type: string @@ -23355,77 +24745,41 @@ components: region_id: type: string title: region_id - description: The payment collection's region id. + description: The ID of the region this payment collection is associated with. amount: - oneOf: - - type: string - title: amount - description: The payment collection's amount. - - type: number - title: amount - description: The payment collection's amount. - - type: string - title: amount - description: The payment collection's amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: amount + description: The total amount to be paid. authorized_amount: - oneOf: - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - type: number - title: authorized_amount - description: The payment collection's authorized amount. - - type: string - title: authorized_amount - description: The payment collection's authorized amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: authorized_amount + description: The total authorized amount of the collection's payments. captured_amount: - oneOf: - - type: string - title: captured_amount - description: The payment collection's captured amount. - - type: number - title: captured_amount - description: The payment collection's captured amount. - - type: string - title: captured_amount - description: The payment collection's captured amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: captured_amount + description: The total captured amount of the collection's payments. refunded_amount: - oneOf: - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - type: number - title: refunded_amount - description: The payment collection's refunded amount. - - type: string - title: refunded_amount - description: The payment collection's refunded amount. - - $ref: '#/components/schemas/IBigNumber' + type: number + title: refunded_amount + description: The total refunded amount of the collection's payments. completed_at: - oneOf: - - type: string - title: completed_at - description: The payment collection's completed at. - - type: string - title: completed_at - description: The payment collection's completed at. - format: date-time + type: string + format: date-time + title: completed_at + description: The date the payment collection was completed. created_at: type: string format: date-time title: created_at - description: The payment collection's created at. + description: The date the payment collection was created. updated_at: type: string format: date-time title: updated_at - description: The payment collection's updated at. + description: The date the payment collection was updated. metadata: type: object - description: The payment collection's metadata. + description: The payment collection's metadata, can hold custom key-value pairs. status: type: string description: The payment collection's status. @@ -23437,14 +24791,14 @@ components: - partially_authorized payment_providers: type: array - description: The payment collection's payment providers. + description: The payment provider used to process the collection's payments and sessions. items: - $ref: '#/components/schemas/BasePaymentProvider' + $ref: '#/components/schemas/StorePaymentProvider' payment_sessions: type: array description: The payment collection's payment sessions. items: - $ref: '#/components/schemas/BasePaymentSession' + $ref: '#/components/schemas/StorePaymentSession' payments: type: array description: The payment collection's payments. @@ -23452,7 +24806,7 @@ components: $ref: '#/components/schemas/BasePayment' StorePaymentCollectionResponse: type: object - description: SUMMARY + description: The payment collection's details. x-schemaName: StorePaymentCollectionResponse required: - payment_collection @@ -23470,20 +24824,78 @@ components: type: string title: id description: The payment provider's ID. + StorePaymentSession: + type: object + description: The payment session's details. + x-schemaName: StorePaymentSession + properties: + id: + type: string + title: id + description: The payment session's ID. + amount: + type: number + title: amount + description: The payment session's amount. + currency_code: + type: string + title: currency_code + description: The payment session's currency code. + example: usd + provider_id: + type: string + title: provider_id + description: The ID of the payment provider processing this session. + data: + type: object + description: The payment session's data, useful for the payment provider processing the payment. + externalDocs: + url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + context: + type: object + description: The context around the payment, such as the customer's details. + example: + customer: + id: cus_123 + status: + type: string + description: The payment session's status. + enum: + - authorized + - captured + - canceled + - pending + - requires_more + - error + authorized_at: + type: string + title: authorized_at + description: The date the payment session was authorized. + format: date-time + payment_collection: + type: object + payment: + $ref: '#/components/schemas/BasePayment' + required: + - id + - amount + - currency_code + - provider_id + - data + - status StoreProduct: type: object description: The product's details. x-schemaName: StoreProduct required: + - variants + - options + - images - length - title - status - - options - description - id - - created_at - - updated_at - - variants - handle - subtitle - is_giftcard @@ -23497,9 +24909,10 @@ components: - material - collection_id - type_id - - images - discountable - external_id + - created_at + - updated_at - deleted_at properties: categories: @@ -23529,7 +24942,7 @@ components: type: array description: The product's options. items: - $ref: '#/components/schemas/BaseProductOption' + $ref: '#/components/schemas/StoreProductOption' description: type: string title: description @@ -23540,22 +24953,22 @@ components: description: The product's ID. metadata: type: object - description: The product's metadata. + description: The product's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The product's created at. + description: The date the product was created. updated_at: type: string format: date-time title: updated_at - description: The product's updated at. + description: The date the product was updated. variants: type: array description: The product's variants. items: - $ref: '#/components/schemas/BaseProductVariant' + $ref: '#/components/schemas/StoreProductVariant' handle: type: string title: handle @@ -23567,11 +24980,11 @@ components: is_giftcard: type: boolean title: is_giftcard - description: The product's is giftcard. + description: Whether the product is a gift card. thumbnail: type: string title: thumbnail - description: The product's thumbnail. + description: The product's thumbnail URL. width: type: number title: width @@ -23591,59 +25004,57 @@ components: hs_code: type: string title: hs_code - description: The product's hs code. + description: The product's HS code. mid_code: type: string title: mid_code - description: The product's mid code. + description: The product's MID code. material: type: string title: material description: The product's material. collection: - $ref: '#/components/schemas/BaseCollection' + $ref: '#/components/schemas/StoreCollection' collection_id: type: string title: collection_id - description: The product's collection id. + description: The ID of the collection that the product belongs to. type_id: type: string title: type_id - description: The product's type id. + description: The ID of the product's type. tags: type: array description: The product's tags. items: - $ref: '#/components/schemas/BaseProductTag' + $ref: '#/components/schemas/StoreProductTag' images: type: array description: The product's images. items: - $ref: '#/components/schemas/BaseProductImage' + $ref: '#/components/schemas/StoreProductImage' discountable: type: boolean title: discountable - description: The product's discountable. + description: Whether the product can be discounted. external_id: type: string title: external_id - description: The product's external id. + description: The ID of the product in an external service or system. deleted_at: type: string format: date-time title: deleted_at - description: The product's deleted at. + description: The date the product was deleted. StoreProductCategory: type: object - description: The category's categories. + description: The category's details. x-schemaName: StoreProductCategory required: - id - name - description - handle - - is_active - - is_internal - rank - parent_category_id - parent_category @@ -23673,14 +25084,6 @@ components: type: string title: handle description: The category's handle. - is_active: - type: boolean - title: is_active - description: The category's is active. - is_internal: - type: boolean - title: is_internal - description: The category's is internal. rank: type: number title: rank @@ -23688,35 +25091,35 @@ components: parent_category_id: type: string title: parent_category_id - description: The category's parent category id. + description: The ID of the category's parent. parent_category: - $ref: '#/components/schemas/BaseProductCategory' + type: object category_children: type: array - description: The category's category children. + description: The category's children. items: - $ref: '#/components/schemas/BaseProductCategory' + type: object metadata: type: object - description: The category's metadata. + description: The category's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The category's created at. + description: The date the category was created. updated_at: type: string format: date-time title: updated_at - description: The category's updated at. + description: The date the category was updated. deleted_at: type: string format: date-time title: deleted_at - description: The category's deleted at. + description: The date the category was deleted. StoreProductCategoryListResponse: type: object - description: SUMMARY + description: The paginated list of product categories. x-schemaName: StoreProductCategoryListResponse required: - limit @@ -23727,114 +25130,325 @@ components: limit: type: number title: limit - description: The product category's limit. + description: The maximum number of items returned. offset: type: number title: offset - description: The product category's offset. + description: The number of items skipped before retrieving the returned items. count: type: number title: count - description: The product category's count. + description: The total number of items. product_categories: type: array - description: The product category's product categories. + description: The list of product categories. items: $ref: '#/components/schemas/StoreProductCategory' StoreProductCategoryResponse: type: object - description: SUMMARY + description: The product category's details. x-schemaName: StoreProductCategoryResponse required: - product_category properties: product_category: $ref: '#/components/schemas/StoreProductCategory' + StoreProductImage: + type: object + description: The image's images. + x-schemaName: StoreProductImage + required: + - id + - url + properties: + id: + type: string + title: id + description: The image's ID. + url: + type: string + title: url + description: The image's url. + created_at: + type: string + format: date-time + title: created_at + description: The image's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The image's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The image's deleted at. + metadata: + type: object + description: The image's metadata. + StoreProductOption: + type: object + description: The product option's details. + x-schemaName: StoreProductOption + properties: + id: + type: string + title: id + description: The option's ID. + title: + type: string + title: title + description: The option's title. + product: + type: object + product_id: + type: string + title: product_id + description: The option's product id. + values: + type: array + description: The option's values. + items: + $ref: '#/components/schemas/StoreProductOptionValue' + metadata: + type: object + description: The option's metadata. + created_at: + type: string + format: date-time + title: created_at + description: The option's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The option's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The option's deleted at. + required: + - title + - id + StoreProductOptionValue: + type: object + description: The product option value's details. + x-schemaName: StoreProductOptionValue + required: + - value + - id + properties: + id: + type: string + title: id + description: The value's ID. + value: + type: string + title: value + description: The value. + option: + type: object + option_id: + type: string + title: option_id + description: The ID of the option this value belongs to. + metadata: + type: object + description: The value's metadata, can hold custom key-value pairs. + created_at: + type: string + format: date-time + title: created_at + description: The date the value was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the value was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the value was deleted. StoreProductResponse: type: object - description: SUMMARY + description: The product's details. x-schemaName: StoreProductResponse required: - product properties: product: $ref: '#/components/schemas/StoreProduct' - StoreProductVariantParams: + StoreProductTag: type: object - description: The product's variants. - x-schemaName: StoreProductVariantParams + description: The tag's details. + x-schemaName: StoreProductTag properties: - q: - type: string - title: q - description: The variant's q. id: - oneOf: - - type: string - title: id - description: The variant's ID. - - type: array - description: The variant's ID. - items: - type: string - title: id - description: The id's ID. - sku: - oneOf: - - type: string - title: sku - description: The variant's sku. - - type: array - description: The variant's sku. - items: - type: string - title: sku - description: The sku's details. - product_id: - oneOf: - - type: string - title: product_id - description: The variant's product id. - - type: array - description: The variant's product id. - items: - type: string - title: product_id - description: The product id's details. - options: + type: string + title: id + description: The tag's ID. + value: + type: string + title: value + description: The tag's value. + created_at: + type: string + format: date-time + title: created_at + description: The date the tag was created. + updated_at: + type: string + format: date-time + title: updated_at + description: The date the tag was updated. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The date the tag was deleted. + metadata: type: object + description: The tag's metadata, can hold custom key-value pairs. + required: + - id + - value + - created_at + - updated_at + StoreProductVariant: + type: object + description: The variant's variants. + x-schemaName: StoreProductVariant + properties: + options: + type: array description: The variant's options. - limit: + items: + $ref: '#/components/schemas/StoreProductOptionValue' + product: + $ref: '#/components/schemas/StoreProduct' + length: type: number - title: limit - description: The variant's limit. - offset: + title: length + description: The variant's length. + title: + type: string + title: title + description: The variant's title. + metadata: + type: object + description: The variant's metadata. + id: + type: string + title: id + description: The variant's ID. + width: type: number - title: offset - description: The variant's offset. - order: + title: width + description: The variant's width. + weight: + type: number + title: weight + description: The variant's weight. + height: + type: number + title: height + description: The variant's height. + origin_country: + type: string + title: origin_country + description: The variant's origin country. + hs_code: + type: string + title: hs_code + description: The variant's hs code. + mid_code: + type: string + title: mid_code + description: The variant's mid code. + material: + type: string + title: material + description: The variant's material. + created_at: + type: string + format: date-time + title: created_at + description: The variant's created at. + updated_at: + type: string + format: date-time + title: updated_at + description: The variant's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The variant's deleted at. + product_id: type: string - title: order - description: The variant's order. - fields: + title: product_id + description: The variant's product id. + sku: type: string - title: fields - description: The variant's fields. - $and: - type: array - description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $and - $or: - type: array - description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. - items: - type: object - title: $or + title: sku + description: The variant's sku. + barcode: + type: string + title: barcode + description: The variant's barcode. + ean: + type: string + title: ean + description: The variant's ean. + upc: + type: string + title: upc + description: The variant's upc. + allow_backorder: + type: boolean + title: allow_backorder + description: The variant's allow backorder. + manage_inventory: + type: boolean + title: manage_inventory + description: The variant's manage inventory. + inventory_quantity: + type: number + title: inventory_quantity + description: The variant's inventory quantity. + variant_rank: + type: number + title: variant_rank + description: The variant's variant rank. + calculated_price: + $ref: '#/components/schemas/BaseCalculatedPriceSet' + required: + - options + - length + - title + - id + - width + - weight + - height + - origin_country + - hs_code + - mid_code + - material + - created_at + - updated_at + - deleted_at + - sku + - barcode + - ean + - upc + - allow_backorder + - manage_inventory StoreRegion: type: object - description: The region's details. + description: The parent's region. x-schemaName: StoreRegion required: - id @@ -23885,11 +25499,11 @@ components: description: The return's details. x-schemaName: StoreReturn required: + - items - id - order_id - order_version - display_id - - items - received_at - created_at - canceled_at @@ -23901,57 +25515,118 @@ components: order_id: type: string title: order_id - description: The return's order id. + description: The ID of the order this return is created for. status: - type: string - title: status + oneOf: + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. + - type: string + title: status + description: The return's status. description: The return's status. exchange_id: type: string title: exchange_id - description: The return's exchange id. + description: The ID of the associated exchange. location_id: type: string title: location_id - description: The return's location id. + description: The ID of the location the items are returned to. claim_id: type: string title: claim_id - description: The return's claim id. + description: The ID of the associated claim. order_version: type: number title: order_version - description: The return's order version. + description: The version of the order when the return is applied. display_id: type: number title: display_id - description: The return's display id. + description: The return's display ID. no_notification: type: boolean title: no_notification - description: The return's no notification. + description: Whether the customer should receive updates about changes in the return. refund_amount: type: number title: refund_amount - description: The return's refund amount. + description: The return's refunded amount. items: type: array description: The return's items. items: - $ref: '#/components/schemas/BaseReturnItem' + $ref: '#/components/schemas/StoreReturnItem' received_at: type: string title: received_at - description: The return's received at. + description: The date the return was received. created_at: type: string format: date-time title: created_at - description: The return's created at. + description: The date the return was created. canceled_at: type: string title: canceled_at - description: The return's canceled at. + description: The date the return was updated. + StoreReturnItem: + type: object + description: The item's items. + x-schemaName: StoreReturnItem + properties: + id: + type: string + title: id + description: The item's ID. + quantity: + type: number + title: quantity + description: The item's quantity. + received_quantity: + type: number + title: received_quantity + description: The item's received quantity. + damaged_quantity: + type: number + title: damaged_quantity + description: The item's damaged quantity. + reason_id: + type: string + title: reason_id + description: The item's reason id. + note: + type: string + title: note + description: The item's note. + item_id: + type: string + title: item_id + description: The item's item id. + return_id: + type: string + title: return_id + description: The item's return id. + metadata: + type: object + description: The item's metadata. + required: + - id + - quantity + - received_quantity + - damaged_quantity + - item_id + - return_id StoreReturnReason: type: object description: The return reason's details. @@ -23981,20 +25656,20 @@ components: description: The return reason's description. metadata: type: object - description: The return reason's metadata. + description: The return reason's metadata, can hold custom key-value pairs. created_at: type: string format: date-time title: created_at - description: The return reason's created at. + description: The date the return reason was created. updated_at: type: string format: date-time title: updated_at - description: The return reason's updated at. + description: The date the return reason was updated. StoreReturnReasonResponse: type: object - description: SUMMARY + description: The return reason's details. x-schemaName: StoreReturnReasonResponse required: - return_reason @@ -24003,7 +25678,7 @@ components: $ref: '#/components/schemas/StoreReturnReason' StoreReturnResponse: type: object - description: SUMMARY + description: The return's details. x-schemaName: StoreReturnResponse required: - return @@ -24012,74 +25687,56 @@ components: $ref: '#/components/schemas/StoreReturn' StoreShippingOption: type: object - description: The shipping option's shipping options. + description: The shipping option's details. x-schemaName: StoreShippingOption required: - id - - name - - price_type - - service_zone_id - - provider_id - - provider - - shipping_option_type_id - - type - - shipping_profile_id - - amount - - is_tax_inclusive - - data - - metadata + - label + - description + - code + - shipping_option_id + - created_at + - updated_at + - deleted_at properties: id: type: string title: id description: The shipping option's ID. - name: + label: type: string - title: name - description: The shipping option's name. - price_type: + title: label + description: The type's label. + description: type: string - description: The shipping option's price type. - enum: - - flat - - calculated - service_zone_id: + title: description + description: The type's description. + code: type: string - title: service_zone_id - description: The shipping option's service zone id. - provider_id: + title: code + description: The type's code. + shipping_option_id: type: string - title: provider_id - description: The shipping option's provider id. - provider: - $ref: '#/components/schemas/BaseFulfillmentProvider' - shipping_option_type_id: + title: shipping_option_id + description: The type's shipping option id. + created_at: type: string - title: shipping_option_type_id - description: The shipping option's shipping option type id. - type: - type: object - shipping_profile_id: + format: date-time + title: created_at + description: The type's created at. + updated_at: type: string - title: shipping_profile_id - description: The shipping option's shipping profile id. - amount: - type: number - title: amount - description: The shipping option's amount. - is_tax_inclusive: - type: boolean - title: is_tax_inclusive - description: The shipping option's is tax inclusive. - data: - type: object - description: The shipping option's data. - metadata: - type: object - description: The shipping option's metadata. + format: date-time + title: updated_at + description: The type's updated at. + deleted_at: + type: string + format: date-time + title: deleted_at + description: The type's deleted at. StoreShippingOptionListResponse: type: object - description: SUMMARY + description: The shipping option's details. x-schemaName: StoreShippingOptionListResponse required: - shipping_options @@ -24091,7 +25748,7 @@ components: $ref: '#/components/schemas/StoreShippingOption' StoreUpdateCartLineItem: type: object - description: SUMMARY + description: The details to update in the line item. x-schemaName: StoreUpdateCartLineItem required: - quantity @@ -24099,13 +25756,13 @@ components: quantity: type: number title: quantity - description: The cart's quantity. + description: The item's quantity. metadata: type: object - description: The cart's metadata. + description: The item's metadata, can hold custom key-value pairs. StoreUpdateCustomer: type: object - description: SUMMARY + description: The details to update in the customer. x-schemaName: StoreUpdateCustomer properties: company_name: @@ -24126,7 +25783,7 @@ components: description: The customer's phone. UpdateAddress: type: object - description: The cart's shipping address. + description: The details to update in the address. x-schemaName: UpdateAddress required: - id @@ -24134,88 +25791,90 @@ components: id: type: string title: id - description: The shipping address's ID. + description: The ID of an existing address to update. customer_id: type: string title: customer_id - description: The shipping address's customer id. + description: The ID of the customer that this address belongs to. company: type: string title: company - description: The shipping address's company. + description: The address's company. first_name: type: string title: first_name - description: The shipping address's first name. + description: The address's first name. last_name: type: string title: last_name - description: The shipping address's last name. + description: The address's last name. address_1: type: string title: address_1 - description: The shipping address's address 1. + description: The address's first line. address_2: type: string title: address_2 - description: The shipping address's address 2. + description: The address's second line. city: type: string title: city - description: The shipping address's city. + description: The address's city. country_code: type: string title: country_code - description: The shipping address's country code. + description: The address's country code. + example: usd province: type: string title: province - description: The shipping address's province. + description: The address's province. postal_code: type: string title: postal_code - description: The shipping address's postal code. + description: The address's postal code. phone: type: string title: phone - description: The shipping address's phone. + description: The address's phone. metadata: type: object - description: The shipping address's metadata. + description: The address's metadata, can hold custom key-value pairs. UpdateCartData: type: object - description: SUMMARY + description: The details to update in a cart. x-schemaName: UpdateCartData properties: region_id: type: string title: region_id - description: The cart's region id. + description: The ID of the associated region. This can affect the prices and currency code of the cart. customer_id: type: string title: customer_id - description: The cart's customer id. + description: The ID of the customer that the cart belongs to. sales_channel_id: type: string title: sales_channel_id - description: The cart's sales channel id. + description: The ID of the associated sales channel. Only products available in this channel can be added to the cart. email: type: string title: email - description: The cart's email. + description: The email of the customer that the cart belongs to. format: email currency_code: type: string title: currency_code description: The cart's currency code. + example: usd shipping_address_id: type: string title: shipping_address_id - description: The cart's shipping address id. + description: The ID of the cart's shipping address. billing_address_id: type: string title: billing_address_id - description: The cart's billing address id. + description: The ID of the cart's billing address. billing_address: oneOf: - $ref: '#/components/schemas/CreateAddress' @@ -24226,31 +25885,7 @@ components: - $ref: '#/components/schemas/UpdateAddress' metadata: type: object - description: The cart's metadata. - UpdateOrderReturnReason: - type: object - description: SUMMARY - x-schemaName: UpdateOrderReturnReason - properties: - id: - type: string - title: id - description: The return reason's ID. - label: - type: string - title: label - description: The return reason's label. - value: - type: string - title: value - description: The return reason's value. - description: - type: string - title: description - description: The return reason's description. - metadata: - type: object - description: The return reason's metadata. + description: The cart's metadata, ca hold custom key-value pairs. WorkflowExecutionContext: type: object description: The workflow execution's context. @@ -24262,6 +25897,30 @@ components: data: type: object description: The context's data. + properties: + invoke: + type: object + description: The step's invokation details. + required: + - output + additionalProperties: + type: object + properties: + output: + type: object + description: The invokation's details. + required: + - output + - compensateInput + properties: + output: + description: the step's output + compensateInput: + description: the compensation function's input. + payload: + description: the payload of the transaction. + required: + - invoke compensate: type: object description: The context's compensate. @@ -24270,7 +25929,23 @@ components: description: The context's errors. items: type: object - description: The error's errors. + description: The error's details. + properties: + error: + type: object + description: The error's details. + action: + type: string + title: action + description: The error's action. + handlerType: + type: string + title: handlerType + description: The error's handler type. + required: + - error + - action + - handlerType responses: default_error: description: Default Error diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_taxes.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_taxes.yaml index 9096f876acbec..089c269e8f1f1 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_taxes.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_taxes.yaml @@ -37,11 +37,6 @@ post: if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. without prefix it will replace the entire default fields. - requestBody: - content: - application/json: - schema: - $ref: ../components/schemas/StoreCalculateCartTaxes.yaml x-codeSamples: - lang: Shell label: cURL diff --git a/www/apps/api-reference/specs/store/paths/store_customers.yaml b/www/apps/api-reference/specs/store/paths/store_customers.yaml index bfefdf2b958cb..841f823b1119f 100644 --- a/www/apps/api-reference/specs/store/paths/store_customers.yaml +++ b/www/apps/api-reference/specs/store/paths/store_customers.yaml @@ -69,3 +69,6 @@ post: '500': $ref: ../components/responses/500_error.yaml x-workflow: createCustomerAccountWorkflow + security: + - cookie_auth: [] + - jwt_token: [] diff --git a/www/apps/api-reference/specs/store/paths/store_customers_me_addresses.yaml b/www/apps/api-reference/specs/store/paths/store_customers_me_addresses.yaml index 97175791aaa7c..b58d6ce451476 100644 --- a/www/apps/api-reference/specs/store/paths/store_customers_me_addresses.yaml +++ b/www/apps/api-reference/specs/store/paths/store_customers_me_addresses.yaml @@ -70,31 +70,52 @@ get: - name: city in: query description: Filter by the address's city. - required: true + required: false schema: - type: string - title: city - description: Filter by the address's city. + oneOf: + - type: string + title: city + description: The customer's city. + - type: array + description: The customer's city. + items: + type: string + title: city + description: The city's details. - name: postal_code in: query description: Filter by the address's postal code. - required: true + required: false schema: - type: string - title: postal_code - description: Filter by the address's postal code. + oneOf: + - type: string + title: postal_code + description: The customer's postal code. + - type: array + description: The customer's postal code. + items: + type: string + title: postal_code + description: The postal code's details. - name: country_code in: query description: Filter by the address's country code. - required: true + required: false schema: - type: string - title: country_code - description: Filter by the address's country code. + oneOf: + - type: string + title: country_code + description: The customer's country code. + - type: array + description: The customer's country code. + items: + type: string + title: country_code + description: The country code's details. - name: q in: query description: Search term to filter the address's searchable properties. - required: true + required: false schema: type: string title: q diff --git a/www/apps/api-reference/specs/store/paths/store_products.yaml b/www/apps/api-reference/specs/store/paths/store_products.yaml index d92dd42cf39a0..d18ab49acede7 100644 --- a/www/apps/api-reference/specs/store/paths/store_products.yaml +++ b/www/apps/api-reference/specs/store/paths/store_products.yaml @@ -1020,18 +1020,6 @@ get: url: >- https://docs.medusajs.com/v2/resources/storefront-development/products/price/examples/tax-price description: 'Storefront guide: How to show product variants'' prices with taxes.' - - name: country_code - in: query - description: >- - The country code the products are being viewed from. This is required if - you're retrieving product variant prices with taxes. - required: false - schema: - type: string - title: country_code - description: >- - The country code the products are being viewed from. This is required - if you're retrieving product variant prices with taxes. - name: province in: query description: >- @@ -1046,20 +1034,6 @@ get: The province the products are being viewed from. This is useful to narrow down the tax context when calculating product variant prices with taxes. - - name: cart_id - in: query - description: >- - The ID of the customer's cart. If set, the cart's region and shipping - address's country code and province are used instead of the `region_id`, - `country_code`, and `province` properties. - required: false - schema: - type: string - title: cart_id - description: >- - The ID of the customer's cart. If set, the cart's region and shipping - address's country code and province are used instead of the - `region_id`, `country_code`, and `province` properties. - name: sales_channel_id in: query required: false @@ -1088,6 +1062,102 @@ get: type: string title: category_id description: A product category's ID. + - name: currency_code + in: query + description: The product's currency code. + required: false + schema: + type: string + title: currency_code + description: The product's currency code. + - name: variants + in: query + description: The product's variants. + required: false + schema: + type: object + description: The product's variants. + x-schemaName: StoreProductVariantParams + properties: + q: + type: string + title: q + description: The variant's q. + id: + oneOf: + - type: string + title: id + description: The variant's ID. + - type: array + description: The variant's ID. + items: + type: string + title: id + description: The id's ID. + sku: + oneOf: + - type: string + title: sku + description: The variant's sku. + - type: array + description: The variant's sku. + items: + type: string + title: sku + description: The sku's details. + product_id: + oneOf: + - type: string + title: product_id + description: The variant's product id. + - type: array + description: The variant's product id. + items: + type: string + title: product_id + description: The product id's details. + options: + type: object + description: The variant's options. + limit: + type: number + title: limit + description: Limit the number of items returned in the list. + offset: + type: number + title: offset + description: The number of items to skip when retrieving a list. + order: + type: string + title: order + description: >- + The field to sort the data by. By default, the sort order is + ascending. To change the order to descending, prefix the field + name with `-`. + fields: + type: string + title: fields + description: >- + Comma-separated fields that should be included in the returned + data. if a field is prefixed with `+` it will be added to the + default fields, using `-` will remove it from the default fields. + without prefix it will replace the entire default fields. + $and: + type: array + description: >- + Join query parameters with an AND condition. Each object's content + is the same type as the expected query parameters. + items: + type: object + title: $and + $or: + type: array + description: >- + Join query parameters with an OR condition. Each object's content + is the same type as the expected query parameters. + items: + type: object + title: $or x-codeSamples: - lang: Shell label: cURL diff --git a/www/utils/generated/oas-output/operations/admin/delete_admin_customers_[id].ts b/www/utils/generated/oas-output/operations/admin/delete_admin_customers_[id].ts index 7df0757b602e7..52742f3ae45d2 100644 --- a/www/utils/generated/oas-output/operations/admin/delete_admin_customers_[id].ts +++ b/www/utils/generated/oas-output/operations/admin/delete_admin_customers_[id].ts @@ -60,7 +60,7 @@ * $ref: "#/components/responses/invalid_request_error" * "500": * $ref: "#/components/responses/500_error" - * x-workflow: deleteCustomersWorkflow + * x-workflow: removeCustomerAccountWorkflow * */ diff --git a/www/utils/generated/oas-output/operations/admin/delete_admin_exchanges_[id]_inbound_items_[action_id].ts b/www/utils/generated/oas-output/operations/admin/delete_admin_exchanges_[id]_inbound_items_[action_id].ts index 8cc1db29a5c36..0aab9eec8faeb 100644 --- a/www/utils/generated/oas-output/operations/admin/delete_admin_exchanges_[id]_inbound_items_[action_id].ts +++ b/www/utils/generated/oas-output/operations/admin/delete_admin_exchanges_[id]_inbound_items_[action_id].ts @@ -21,24 +21,6 @@ * required: true * schema: * type: string - * - name: expand - * in: query - * description: Comma-separated relations that should be expanded in the returned data. - * required: false - * schema: - * type: string - * title: expand - * description: Comma-separated relations that should be expanded in the returned data. - * - name: fields - * in: query - * description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default - * fields. without prefix it will replace the entire default fields. - * required: false - * schema: - * type: string - * title: fields - * description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default - * fields. without prefix it will replace the entire default fields. * security: * - api_token: [] * - cookie_auth: [] diff --git a/www/utils/generated/oas-output/operations/admin/delete_admin_users_[id].ts b/www/utils/generated/oas-output/operations/admin/delete_admin_users_[id].ts index 5b5282b3166a4..4296faeaf21d5 100644 --- a/www/utils/generated/oas-output/operations/admin/delete_admin_users_[id].ts +++ b/www/utils/generated/oas-output/operations/admin/delete_admin_users_[id].ts @@ -36,7 +36,7 @@ * $ref: "#/components/responses/invalid_request_error" * "500": * $ref: "#/components/responses/500_error" - * x-workflow: deleteUsersWorkflow + * x-workflow: removeUserAccountWorkflow * */ diff --git a/www/utils/generated/oas-output/operations/admin/get_admin_api-keys.ts b/www/utils/generated/oas-output/operations/admin/get_admin_api-keys.ts index 8f5efa672b26b..314bc6ff87472 100644 --- a/www/utils/generated/oas-output/operations/admin/get_admin_api-keys.ts +++ b/www/utils/generated/oas-output/operations/admin/get_admin_api-keys.ts @@ -102,10 +102,13 @@ * description: Filter by the API key's type. * required: false * schema: - * type: string - * enum: - * - secret - * - publishable + * oneOf: + * - type: string + * title: type + * description: The api key's type. + * - type: string + * title: type + * description: The api key's type. * - name: created_at * in: query * description: Filter by the API key's creation date. diff --git a/www/utils/generated/oas-output/operations/admin/get_admin_products.ts b/www/utils/generated/oas-output/operations/admin/get_admin_products.ts index db1878d01e1cd..f908ba60c982d 100644 --- a/www/utils/generated/oas-output/operations/admin/get_admin_products.ts +++ b/www/utils/generated/oas-output/operations/admin/get_admin_products.ts @@ -583,6 +583,2212 @@ * type: string * title: collection_id * description: A product collection's ID. + * - name: variants + * in: query + * description: The product's variants. + * required: false + * schema: + * type: object + * description: The product's variants. + * x-schemaName: AdminProductVariantParams + * properties: + * q: + * type: string + * title: q + * description: The variant's q. + * id: + * oneOf: + * - type: string + * title: id + * description: The variant's ID. + * - type: array + * description: The variant's ID. + * items: + * type: string + * title: id + * description: The id's ID. + * manage_inventory: + * type: boolean + * title: manage_inventory + * description: The variant's manage inventory. + * allow_backorder: + * type: boolean + * title: allow_backorder + * description: The variant's allow backorder. + * created_at: + * type: object + * description: The variant's created at. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * updated_at: + * type: object + * description: The variant's updated at. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * deleted_at: + * type: object + * description: The variant's deleted at. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * oneOf: + * - type: string + * title: $eq + * description: Filter by an exact match. + * - type: array + * description: Filter by an exact match. + * items: + * type: string + * title: $eq + * description: Filter by an exact match. + * $ne: + * type: string + * title: $ne + * description: Filter by values not equal to this parameter. + * $in: + * type: array + * description: Filter by values in this array. + * items: + * type: string + * title: $in + * description: Filter by values in this array. + * $nin: + * type: array + * description: Filter by values not in this array. + * items: + * type: string + * title: $nin + * description: Filter by values not in this array. + * $not: + * oneOf: + * - type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * properties: + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or + * $eq: + * type: array + * description: Filter by an exact match. + * items: {} + * $ne: + * oneOf: [] + * $in: + * type: array + * description: Filter by values in this array. + * items: {} + * $nin: + * type: array + * description: Filter by values not in this array. + * items: {} + * $not: + * oneOf: + * - type: object + * description: Filter by values not matching the conditions in this parameter. + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * oneOf: [] + * $gte: + * oneOf: [] + * $lt: + * oneOf: [] + * $lte: + * oneOf: [] + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: {} + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * - type: array + * description: Filter by values not matching the conditions in this parameter. + * items: + * type: string + * title: $not + * description: Filter by values not matching the conditions in this parameter. + * $gt: + * type: string + * title: $gt + * description: Filter by values greater than this parameter. Useful for numbers and dates only. + * $gte: + * type: string + * title: $gte + * description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only. + * $lt: + * type: string + * title: $lt + * description: Filter by values less than this parameter. Useful for numbers and dates only. + * $lte: + * type: string + * title: $lte + * description: Filter by values less than or equal to this parameter. Useful for numbers and dates only. + * $like: + * type: string + * title: $like + * description: Apply a `like` filter. Useful for strings only. + * $re: + * type: string + * title: $re + * description: Apply a regex filter. Useful for strings only. + * $ilike: + * type: string + * title: $ilike + * description: Apply a case-insensitive `like` filter. Useful for strings only. + * $fulltext: + * type: string + * title: $fulltext + * description: Filter to apply on full-text properties. + * $overlap: + * type: array + * description: Filter arrays that have overlapping values with this parameter. + * items: + * type: string + * title: $overlap + * description: Filter arrays that have overlapping values with this parameter. + * $contains: + * type: array + * description: Filter arrays that contain some of the values of this parameter. + * items: + * type: string + * title: $contains + * description: Filter arrays that contain some of the values of this parameter. + * $contained: + * type: array + * description: Filter arrays that contain all values of this parameter. + * items: + * type: string + * title: $contained + * description: Filter arrays that contain all values of this parameter. + * $exists: + * type: boolean + * title: $exists + * description: Filter by whether a value for this parameter exists (not `null`). + * limit: + * type: number + * title: limit + * description: Limit the number of items returned in the list. + * offset: + * type: number + * title: offset + * description: The number of items to skip when retrieving a list. + * order: + * type: string + * title: order + * description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + * fields: + * type: string + * title: fields + * description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default + * fields. without prefix it will replace the entire default fields. + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or * security: * - api_token: [] * - cookie_auth: [] diff --git a/www/utils/generated/oas-output/operations/admin/get_admin_promotions_[id]_[rule_type].ts b/www/utils/generated/oas-output/operations/admin/get_admin_promotions_[id]_[rule_type].ts index 59f2c19e681ee..4692fba4347fb 100644 --- a/www/utils/generated/oas-output/operations/admin/get_admin_promotions_[id]_[rule_type].ts +++ b/www/utils/generated/oas-output/operations/admin/get_admin_promotions_[id]_[rule_type].ts @@ -3,12 +3,10 @@ * operationId: GetPromotionsIdRule_type * summary: List Rules of a Promotion * x-sidebar-summary: List Rules - * description: > + * description: | * Retrieve a list of rules in a promotion. The type of rules retrieved depend on the value of the `rule_type` path parameter: - * * - If `rule_type` is `rules`, the promotion's rules are retrivied. - If `rule_type` is `target-rules`, the target rules of the promotion's application method are retrieved. * - * * - If `rule_type` is `buy-rules`, the buy rules of the promotion's application method are retrieved. * x-authenticated: true * parameters: diff --git a/www/utils/generated/oas-output/operations/admin/get_admin_tax-rates.ts b/www/utils/generated/oas-output/operations/admin/get_admin_tax-rates.ts index 0fc9ce14519e1..493388119e1bb 100644 --- a/www/utils/generated/oas-output/operations/admin/get_admin_tax-rates.ts +++ b/www/utils/generated/oas-output/operations/admin/get_admin_tax-rates.ts @@ -119,10 +119,13 @@ * required: false * description: Filter by whether the tax rate is a default in its tax region. * schema: - * type: string - * enum: - * - "true" - * - "false" + * oneOf: + * - type: string + * title: is_default + * description: The tax rate's is default. + * - type: string + * title: is_default + * description: The tax rate's is default. * - name: created_at * in: query * description: Filter by a tax rate's creation date. diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_orders_[id]_archive.ts b/www/utils/generated/oas-output/operations/admin/post_admin_orders_[id]_archive.ts index bd4827a0c2ccb..206e3dfa27f73 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_orders_[id]_archive.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_orders_[id]_archive.ts @@ -37,7 +37,8 @@ * content: * application/json: * schema: - * $ref: "#/components/schemas/AdminArchiveOrder" + * type: object + * description: SUMMARY * x-codeSamples: * - lang: Shell * label: cURL diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_orders_[id]_fulfillments_[fulfillment_id]_mark-as-delivered.ts b/www/utils/generated/oas-output/operations/admin/post_admin_orders_[id]_fulfillments_[fulfillment_id]_mark-as-delivered.ts new file mode 100644 index 0000000000000..a16ab0855cb0b --- /dev/null +++ b/www/utils/generated/oas-output/operations/admin/post_admin_orders_[id]_fulfillments_[fulfillment_id]_mark-as-delivered.ts @@ -0,0 +1,79 @@ +/** + * @oas [post] /admin/orders/{id}/fulfillments/{fulfillment_id}/mark-as-delivered + * operationId: PostOrdersIdFulfillmentsFulfillment_idMarkAsDelivered + * summary: Add Mark As Delivered to Order + * description: Add a Mark As Delivered to a order + * x-authenticated: true + * parameters: + * - name: id + * in: path + * description: The order's ID. + * required: true + * schema: + * type: string + * - name: fulfillment_id + * in: path + * description: The order's fulfillment id. + * required: true + * schema: + * type: string + * - name: expand + * in: query + * description: Comma-separated relations that should be expanded in the returned data. + * required: false + * schema: + * type: string + * title: expand + * description: Comma-separated relations that should be expanded in the returned data. + * - name: fields + * in: query + * description: |- + * Comma-separated fields that should be included in the returned data. + * * if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields. + * * without prefix it will replace the entire default fields. + * required: false + * schema: + * type: string + * title: fields + * description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default + * fields. without prefix it will replace the entire default fields. + * security: + * - api_token: [] + * - cookie_auth: [] + * - jwt_token: [] + * requestBody: + * content: + * application/json: + * schema: + * $ref: "#/components/schemas/AdminMarkOrderFulfillmentDelivered" + * x-codeSamples: + * - lang: Shell + * label: cURL + * source: |- + * curl -X POST '{backend_url}/admin/orders/{id}/fulfillments/{fulfillment_id}/mark-as-delivered' \ + * -H 'Authorization: Bearer {access_token}' + * tags: + * - Orders + * responses: + * "200": + * description: OK + * content: + * application/json: + * schema: + * $ref: "#/components/schemas/AdminOrderResponse" + * "400": + * $ref: "#/components/responses/400_error" + * "401": + * $ref: "#/components/responses/unauthorized" + * "404": + * $ref: "#/components/responses/not_found_error" + * "409": + * $ref: "#/components/responses/invalid_state_error" + * "422": + * $ref: "#/components/responses/invalid_request_error" + * "500": + * $ref: "#/components/responses/500_error" + * x-workflow: markOrderFulfillmentAsDeliveredWorkflow + * +*/ + diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_price-lists_[id]_prices_batch.ts b/www/utils/generated/oas-output/operations/admin/post_admin_price-lists_[id]_prices_batch.ts index 71b719b1424db..26cc84413402e 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_price-lists_[id]_prices_batch.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_price-lists_[id]_prices_batch.ts @@ -31,8 +31,8 @@ * description: A price's details. * required: * - currency_code - * - amount * - variant_id + * - amount * properties: * currency_code: * type: string diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_product-types.ts b/www/utils/generated/oas-output/operations/admin/post_admin_product-types.ts index 449657601612b..d25917f08e55e 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_product-types.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_product-types.ts @@ -31,7 +31,7 @@ * content: * application/json: * schema: - * $ref: "#/components/schemas/AdminCreateProduct" + * $ref: "#/components/schemas/AdminCreateProductType" * x-codeSamples: * - lang: Shell * label: cURL diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_products_[id]_variants_inventory-items_batch.ts b/www/utils/generated/oas-output/operations/admin/post_admin_products_[id]_variants_inventory-items_batch.ts index 79ce80a9dc0ae..48a9166d25d50 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_products_[id]_variants_inventory-items_batch.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_products_[id]_variants_inventory-items_batch.ts @@ -30,9 +30,9 @@ * type: object * description: The associations to create between a product variant and an inventory item. * required: - * - required_quantity - * - inventory_item_id * - variant_id + * - inventory_item_id + * - required_quantity * properties: * required_quantity: * type: number @@ -53,9 +53,9 @@ * type: object * description: Update a product variant's association with an inventory item. * required: - * - required_quantity - * - inventory_item_id * - variant_id + * - inventory_item_id + * - required_quantity * properties: * required_quantity: * type: number @@ -76,8 +76,8 @@ * type: object * description: Delete a product variant's association with an inventory item. * required: - * - inventory_item_id * - variant_id + * - inventory_item_id * properties: * inventory_item_id: * type: string diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_products_export.ts b/www/utils/generated/oas-output/operations/admin/post_admin_products_export.ts index 455bbdc831133..809ac41b0191d 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_products_export.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_products_export.ts @@ -61,6 +61,11 @@ * "500": * $ref: "#/components/responses/500_error" * x-workflow: exportProductsWorkflow + * requestBody: + * content: + * application/json: + * schema: + * $ref: "#/components/schemas/AdminExportProductRequest" * */ diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_buy-rules_batch.ts b/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_buy-rules_batch.ts index 3ba5feda9bd51..166258bb08024 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_buy-rules_batch.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_buy-rules_batch.ts @@ -48,9 +48,9 @@ * type: object * description: A buy rule's details. * required: + * - values * - operator * - attribute - * - values * properties: * operator: * type: string @@ -76,15 +76,33 @@ * oneOf: * - type: string * title: values - * description: The attribute's value. - * example: prod_123 + * description: The create's values. * - type: array - * description: The allowed attribute values. + * description: The create's values. * items: * type: string * title: values - * description: An attribute value. - * example: prod_123 + * description: The value's values. + * - allOf: + * - type: string + * title: values + * description: The create's values. + * - type: array + * description: The create's values. + * items: + * type: string + * title: values + * description: The value's values. + * - allOf: + * - type: array + * description: The create's values. + * items: + * type: string + * title: values + * description: The value's values. + * - type: string + * title: values + * description: The create's values. * update: * type: array * description: The buy rules to update. @@ -92,24 +110,44 @@ * type: object * description: The properties to update in a buy rule. * required: - * - id * - values + * - id * properties: * id: * type: string * title: id * description: The buy rule's ID. * operator: - * type: string + * oneOf: + * - type: string + * description: The update's operator. + * enum: + * - GTE + * - type: string + * description: The update's operator. + * enum: + * - LTE + * - type: string + * description: The update's operator. + * enum: + * - GT + * - type: string + * description: The update's operator. + * enum: + * - LT + * - type: string + * description: The update's operator. + * enum: + * - EQ + * - type: string + * description: The update's operator. + * enum: + * - NE + * - type: string + * description: The update's operator. + * enum: + * - IN * description: The operator used to check whether the buy rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - * enum: - * - gte - * - lte - * - gt - * - lt - * - eq - * - ne - * - in * description: * type: string * title: description @@ -123,15 +161,33 @@ * oneOf: * - type: string * title: values - * description: The attribute's value. - * example: prod_123 + * description: The update's values. * - type: array - * description: The allowed attribute values. + * description: The update's values. * items: * type: string * title: values - * description: An attribute value. - * example: prod_123 + * description: The value's values. + * - allOf: + * - type: string + * title: values + * description: The update's values. + * - type: array + * description: The update's values. + * items: + * type: string + * title: values + * description: The value's values. + * - allOf: + * - type: array + * description: The update's values. + * items: + * type: string + * title: values + * description: The value's values. + * - type: string + * title: values + * description: The update's values. * delete: * type: array * description: The buy rules to delete. diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_rules_batch.ts b/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_rules_batch.ts index 8fac5ffae970d..70d9a246ef541 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_rules_batch.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_rules_batch.ts @@ -48,9 +48,9 @@ * type: object * description: A rule's details. * required: + * - values * - operator * - attribute - * - values * properties: * operator: * type: string @@ -76,15 +76,33 @@ * oneOf: * - type: string * title: values - * description: The attribute's value. - * example: prod_123 + * description: The create's values. * - type: array - * description: The allowed attribute values. + * description: The create's values. * items: * type: string * title: values - * description: An attribute value. - * example: prod_123 + * description: The value's values. + * - allOf: + * - type: string + * title: values + * description: The create's values. + * - type: array + * description: The create's values. + * items: + * type: string + * title: values + * description: The value's values. + * - allOf: + * - type: array + * description: The create's values. + * items: + * type: string + * title: values + * description: The value's values. + * - type: string + * title: values + * description: The create's values. * update: * type: array * description: The rules to update. @@ -92,24 +110,44 @@ * type: object * description: The properties to update in a rule. * required: - * - id * - values + * - id * properties: * id: * type: string * title: id * description: The rule's ID. * operator: - * type: string + * oneOf: + * - type: string + * description: The update's operator. + * enum: + * - GTE + * - type: string + * description: The update's operator. + * enum: + * - LTE + * - type: string + * description: The update's operator. + * enum: + * - GT + * - type: string + * description: The update's operator. + * enum: + * - LT + * - type: string + * description: The update's operator. + * enum: + * - EQ + * - type: string + * description: The update's operator. + * enum: + * - NE + * - type: string + * description: The update's operator. + * enum: + * - IN * description: The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - * enum: - * - gte - * - lte - * - gt - * - lt - * - eq - * - ne - * - in * description: * type: string * title: description @@ -123,15 +161,33 @@ * oneOf: * - type: string * title: values - * description: The attribute's value. - * example: prod_123 + * description: The update's values. * - type: array - * description: The allowed attribute values. + * description: The update's values. * items: * type: string * title: values - * description: An attribute value. - * example: prod_123 + * description: The value's values. + * - allOf: + * - type: string + * title: values + * description: The update's values. + * - type: array + * description: The update's values. + * items: + * type: string + * title: values + * description: The value's values. + * - allOf: + * - type: array + * description: The update's values. + * items: + * type: string + * title: values + * description: The value's values. + * - type: string + * title: values + * description: The update's values. * delete: * type: array * description: The rules to delete. diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_target-rules_batch.ts b/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_target-rules_batch.ts index db91ab4a8536d..358ee204d5e5b 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_target-rules_batch.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_promotions_[id]_target-rules_batch.ts @@ -48,9 +48,9 @@ * type: object * description: A target rule's details. * required: + * - values * - operator * - attribute - * - values * properties: * operator: * type: string @@ -76,15 +76,33 @@ * oneOf: * - type: string * title: values - * description: The attribute's value. - * example: prod_123 + * description: The create's values. * - type: array - * description: The allowed attribute values. + * description: The create's values. * items: * type: string * title: values - * description: An attribute value. - * example: prod_123 + * description: The value's values. + * - allOf: + * - type: string + * title: values + * description: The create's values. + * - type: array + * description: The create's values. + * items: + * type: string + * title: values + * description: The value's values. + * - allOf: + * - type: array + * description: The create's values. + * items: + * type: string + * title: values + * description: The value's values. + * - type: string + * title: values + * description: The create's values. * update: * type: array * description: The target rules to update. @@ -92,24 +110,44 @@ * type: object * description: The properties to update in a target rule. * required: - * - id * - values + * - id * properties: * id: * type: string * title: id * description: The target rule's ID. * operator: - * type: string + * oneOf: + * - type: string + * description: The update's operator. + * enum: + * - GTE + * - type: string + * description: The update's operator. + * enum: + * - LTE + * - type: string + * description: The update's operator. + * enum: + * - GT + * - type: string + * description: The update's operator. + * enum: + * - LT + * - type: string + * description: The update's operator. + * enum: + * - EQ + * - type: string + * description: The update's operator. + * enum: + * - NE + * - type: string + * description: The update's operator. + * enum: + * - IN * description: The operator used to check whether the target rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value. - * enum: - * - gte - * - lte - * - gt - * - lt - * - eq - * - ne - * - in * description: * type: string * title: description @@ -123,15 +161,33 @@ * oneOf: * - type: string * title: values - * description: The attribute's value. - * example: prod_123 + * description: The update's values. * - type: array - * description: The allowed attribute values. + * description: The update's values. * items: * type: string * title: values - * description: An attribute value. - * example: prod_123 + * description: The value's values. + * - allOf: + * - type: string + * title: values + * description: The update's values. + * - type: array + * description: The update's values. + * items: + * type: string + * title: values + * description: The value's values. + * - allOf: + * - type: array + * description: The update's values. + * items: + * type: string + * title: values + * description: The value's values. + * - type: string + * title: values + * description: The update's values. * delete: * type: array * description: The target rules to delete. diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons.ts b/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons.ts index fb9a3cb5de5cc..9913440863d7f 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons.ts @@ -31,7 +31,7 @@ * content: * application/json: * schema: - * $ref: "#/components/schemas/CreateOrderReturnReason" + * $ref: "#/components/schemas/AdminCreateReturnReason" * x-codeSamples: * - lang: Shell * label: cURL diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons_[id].ts b/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons_[id].ts index d21651c8ce8e8..5413700b27597 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons_[id].ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_return-reasons_[id].ts @@ -37,7 +37,7 @@ * content: * application/json: * schema: - * $ref: "#/components/schemas/UpdateOrderReturnReason" + * $ref: "#/components/schemas/AdminUpdateReturnReason" * x-codeSamples: * - lang: Shell * label: cURL diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id].ts b/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id].ts index 9dfd3cd8ebbb1..a674d84a61383 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id].ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id].ts @@ -50,13 +50,18 @@ * externalDocs: * url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property * price_type: - * type: string + * oneOf: + * - type: string + * description: The shipping option's price type. + * enum: + * - CALCULATED + * - type: string + * description: The shipping option's price type. + * enum: + * - FLAT * description: > * The type of the shipping option's price. If `calculated`, its price is retrieved by the associated fulfillment provider during checkout. If `flat`, its price is set in the `prices` * property. - * enum: - * - calculated - * - flat * provider_id: * type: string * title: provider_id @@ -69,9 +74,9 @@ * type: object * description: The shipping option's type. * required: - * - label - * - description * - code + * - description + * - label * properties: * label: * type: string diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id]_rules_batch.ts b/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id]_rules_batch.ts index c5b746d30d603..b4023cb5095c7 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id]_rules_batch.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_shipping-options_[id]_rules_batch.ts @@ -48,9 +48,9 @@ * type: object * description: A shipping option's details. * required: + * - value * - operator * - attribute - * - value * properties: * operator: * type: string @@ -73,15 +73,33 @@ * oneOf: * - type: string * title: value - * description: A value of the attribute that enables this rule. - * example: cusgroup_123 + * description: The create's value. * - type: array - * description: Values of the attribute that enable this rule. + * description: The create's value. * items: * type: string * title: value - * description: A value of the attribute that enables this rule. - * example: cusgroup_123 + * description: The value's details. + * - allOf: + * - type: string + * title: value + * description: The create's value. + * - type: array + * description: The create's value. + * items: + * type: string + * title: value + * description: The value's details. + * - allOf: + * - type: array + * description: The create's value. + * items: + * type: string + * title: value + * description: The value's details. + * - type: string + * title: value + * description: The create's value. * update: * type: array * description: The shipping option rules to update. @@ -89,10 +107,10 @@ * type: object * description: The properties to update in the shipping option rule. * required: + * - value * - id * - operator * - attribute - * - value * properties: * id: * type: string @@ -119,15 +137,33 @@ * oneOf: * - type: string * title: value - * description: A value of the attribute that enables this rule. - * example: cusgroup_123 + * description: The update's value. * - type: array - * description: Values of the attribute that enable this rule. + * description: The update's value. * items: * type: string * title: value - * description: A value of the attribute that enables this rule. - * example: cusgroup_123 + * description: The value's details. + * - allOf: + * - type: string + * title: value + * description: The update's value. + * - type: array + * description: The update's value. + * items: + * type: string + * title: value + * description: The value's details. + * - allOf: + * - type: array + * description: The update's value. + * items: + * type: string + * title: value + * description: The value's details. + * - type: string + * title: value + * description: The update's value. * delete: * type: array * description: The shipping option rules to delete. diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_stock-locations_[id]_fulfillment-sets.ts b/www/utils/generated/oas-output/operations/admin/post_admin_stock-locations_[id]_fulfillment-sets.ts index 9e826a8418dc2..7066fa945e09e 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_stock-locations_[id]_fulfillment-sets.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_stock-locations_[id]_fulfillment-sets.ts @@ -41,8 +41,8 @@ * type: object * description: The fulfillment set to create. * required: - * - name * - type + * - name * properties: * name: * type: string diff --git a/www/utils/generated/oas-output/operations/admin/post_admin_workflows-executions_[workflow_id]_run.ts b/www/utils/generated/oas-output/operations/admin/post_admin_workflows-executions_[workflow_id]_run.ts index 8d60a70b7f0d8..8b70926bcbbfb 100644 --- a/www/utils/generated/oas-output/operations/admin/post_admin_workflows-executions_[workflow_id]_run.ts +++ b/www/utils/generated/oas-output/operations/admin/post_admin_workflows-executions_[workflow_id]_run.ts @@ -45,6 +45,8 @@ * required: * - workflowId * - transactionId + * - hasFinished + * - hasFailed * properties: * workflowId: * type: string @@ -54,6 +56,18 @@ * type: string * description: The ID of the workflow exection's transaction. Use this later to track the workflow execution's progress or succeed / fail its steps. * title: transactionId + * parentStepIdempotencyKey: + * type: string + * title: parentStepIdempotencyKey + * description: The acknowledgement's parentstepidempotencykey. + * hasFinished: + * type: boolean + * title: hasFinished + * description: The acknowledgement's hasfinished. + * hasFailed: + * type: boolean + * title: hasFailed + * description: The acknowledgement's hasfailed. * "400": * $ref: "#/components/responses/400_error" * "401": diff --git a/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_reset-password.ts b/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_reset-password.ts index 810cc60779efa..6352c6a036725 100644 --- a/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_reset-password.ts +++ b/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_reset-password.ts @@ -24,8 +24,6 @@ * tags: * - "[actor_type]" * responses: - * "200": - * description: OK * "400": * $ref: "#/components/responses/400_error" * "401": diff --git a/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_update.ts b/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_update.ts index 33f5b0f454fa3..9f854c1759abd 100644 --- a/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_update.ts +++ b/www/utils/generated/oas-output/operations/auth/post_auth_[actor_type]_[auth_provider]_update.ts @@ -24,8 +24,6 @@ * tags: * - "[actor_type]" * responses: - * "200": - * description: OK * "400": * $ref: "#/components/responses/400_error" * "401": diff --git a/www/utils/generated/oas-output/operations/auth/post_auth_token_refresh.ts b/www/utils/generated/oas-output/operations/auth/post_auth_token_refresh.ts index dd1b87493f54e..c7641f599c764 100644 --- a/www/utils/generated/oas-output/operations/auth/post_auth_token_refresh.ts +++ b/www/utils/generated/oas-output/operations/auth/post_auth_token_refresh.ts @@ -4,7 +4,6 @@ * summary: Create Token * description: Create a token. * x-authenticated: false - * parameters: [] * x-codeSamples: * - lang: Shell * label: cURL @@ -12,8 +11,6 @@ * tags: * - Token * responses: - * "200": - * description: OK * "400": * $ref: "#/components/responses/400_error" * "401": diff --git a/www/utils/generated/oas-output/operations/store/delete_store_carts_[id]_line-items_[line_id].ts b/www/utils/generated/oas-output/operations/store/delete_store_carts_[id]_line-items_[line_id].ts index 5476ef2bf7815..e20e71acb2617 100644 --- a/www/utils/generated/oas-output/operations/store/delete_store_carts_[id]_line-items_[line_id].ts +++ b/www/utils/generated/oas-output/operations/store/delete_store_carts_[id]_line-items_[line_id].ts @@ -69,7 +69,7 @@ * type: string * title: object * description: The name of the deleted object. - * default: "line-item" + * default: line-item * deleted: * type: boolean * title: deleted diff --git a/www/utils/generated/oas-output/operations/store/delete_store_customers_me_addresses_[address_id].ts b/www/utils/generated/oas-output/operations/store/delete_store_customers_me_addresses_[address_id].ts index 85d74a1e2c81a..a579e0f7cf0b1 100644 --- a/www/utils/generated/oas-output/operations/store/delete_store_customers_me_addresses_[address_id].ts +++ b/www/utils/generated/oas-output/operations/store/delete_store_customers_me_addresses_[address_id].ts @@ -67,7 +67,7 @@ * type: string * title: object * description: The name of the deleted object. - * default: "address" + * default: address * deleted: * type: boolean * title: deleted diff --git a/www/utils/generated/oas-output/operations/store/get_store_customers_me_addresses.ts b/www/utils/generated/oas-output/operations/store/get_store_customers_me_addresses.ts index 1b77fa3ccfe57..5363fd8d52da0 100644 --- a/www/utils/generated/oas-output/operations/store/get_store_customers_me_addresses.ts +++ b/www/utils/generated/oas-output/operations/store/get_store_customers_me_addresses.ts @@ -54,31 +54,52 @@ * - name: city * in: query * description: Filter by the address's city. - * required: true + * required: false * schema: - * type: string - * title: city - * description: Filter by the address's city. + * oneOf: + * - type: string + * title: city + * description: The customer's city. + * - type: array + * description: The customer's city. + * items: + * type: string + * title: city + * description: The city's details. * - name: postal_code * in: query * description: Filter by the address's postal code. - * required: true + * required: false * schema: - * type: string - * title: postal_code - * description: Filter by the address's postal code. + * oneOf: + * - type: string + * title: postal_code + * description: The customer's postal code. + * - type: array + * description: The customer's postal code. + * items: + * type: string + * title: postal_code + * description: The postal code's details. * - name: country_code * in: query * description: Filter by the address's country code. - * required: true + * required: false * schema: - * type: string - * title: country_code - * description: Filter by the address's country code. + * oneOf: + * - type: string + * title: country_code + * description: The customer's country code. + * - type: array + * description: The customer's country code. + * items: + * type: string + * title: country_code + * description: The country code's details. * - name: q * in: query * description: Search term to filter the address's searchable properties. - * required: true + * required: false * schema: * type: string * title: q diff --git a/www/utils/generated/oas-output/operations/store/get_store_products.ts b/www/utils/generated/oas-output/operations/store/get_store_products.ts index 26dd6a649c6a3..e5d95690d9aef 100644 --- a/www/utils/generated/oas-output/operations/store/get_store_products.ts +++ b/www/utils/generated/oas-output/operations/store/get_store_products.ts @@ -877,14 +877,6 @@ * externalDocs: * url: https://docs.medusajs.com/v2/resources/storefront-development/products/price/examples/tax-price * description: "Storefront guide: How to show product variants' prices with taxes." - * - name: country_code - * in: query - * description: The country code the products are being viewed from. This is required if you're retrieving product variant prices with taxes. - * required: false - * schema: - * type: string - * title: country_code - * description: The country code the products are being viewed from. This is required if you're retrieving product variant prices with taxes. * - name: province * in: query * description: The province the products are being viewed from. This is useful to narrow down the tax context when calculating product variant prices with taxes. @@ -893,14 +885,6 @@ * type: string * title: province * description: The province the products are being viewed from. This is useful to narrow down the tax context when calculating product variant prices with taxes. - * - name: cart_id - * in: query - * description: The ID of the customer's cart. If set, the cart's region and shipping address's country code and province are used instead of the `region_id`, `country_code`, and `province` properties. - * required: false - * schema: - * type: string - * title: cart_id - * description: The ID of the customer's cart. If set, the cart's region and shipping address's country code and province are used instead of the `region_id`, `country_code`, and `province` properties. * - name: sales_channel_id * in: query * required: false @@ -929,6 +913,92 @@ * type: string * title: category_id * description: A product category's ID. + * - name: currency_code + * in: query + * description: The product's currency code. + * required: false + * schema: + * type: string + * title: currency_code + * description: The product's currency code. + * - name: variants + * in: query + * description: The product's variants. + * required: false + * schema: + * type: object + * description: The product's variants. + * x-schemaName: StoreProductVariantParams + * properties: + * q: + * type: string + * title: q + * description: The variant's q. + * id: + * oneOf: + * - type: string + * title: id + * description: The variant's ID. + * - type: array + * description: The variant's ID. + * items: + * type: string + * title: id + * description: The id's ID. + * sku: + * oneOf: + * - type: string + * title: sku + * description: The variant's sku. + * - type: array + * description: The variant's sku. + * items: + * type: string + * title: sku + * description: The sku's details. + * product_id: + * oneOf: + * - type: string + * title: product_id + * description: The variant's product id. + * - type: array + * description: The variant's product id. + * items: + * type: string + * title: product_id + * description: The product id's details. + * options: + * type: object + * description: The variant's options. + * limit: + * type: number + * title: limit + * description: Limit the number of items returned in the list. + * offset: + * type: number + * title: offset + * description: The number of items to skip when retrieving a list. + * order: + * type: string + * title: order + * description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + * fields: + * type: string + * title: fields + * description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default + * fields. without prefix it will replace the entire default fields. + * $and: + * type: array + * description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $and + * $or: + * type: array + * description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters. + * items: + * type: object + * title: $or * x-codeSamples: * - lang: Shell * label: cURL diff --git a/www/utils/generated/oas-output/operations/store/get_store_regions_[id].ts b/www/utils/generated/oas-output/operations/store/get_store_regions_[id].ts index 31b1cf1ab91d6..6354e3533164c 100644 --- a/www/utils/generated/oas-output/operations/store/get_store_regions_[id].ts +++ b/www/utils/generated/oas-output/operations/store/get_store_regions_[id].ts @@ -32,8 +32,7 @@ * x-codeSamples: * - lang: Shell * label: cURL - * source: |- - * curl '{backend_url}/store/regions/{id}' + * source: curl '{backend_url}/store/regions/{id}' * tags: * - Regions * responses: diff --git a/www/utils/generated/oas-output/operations/store/get_store_shipping-options.ts b/www/utils/generated/oas-output/operations/store/get_store_shipping-options.ts index 15451be75f361..8f1fbf350a65a 100644 --- a/www/utils/generated/oas-output/operations/store/get_store_shipping-options.ts +++ b/www/utils/generated/oas-output/operations/store/get_store_shipping-options.ts @@ -2,10 +2,9 @@ * @oas [get] /store/shipping-options * operationId: GetShippingOptions * summary: List Shipping Options for Cart - * description: > + * description: | * Retrieve a list of shipping options for a cart. The cart's ID is set in the required `cart_id` query parameter. * - * * The shipping options also be sorted or paginated. * externalDocs: * url: https://docs.medusajs.com/v2/resources/storefront-development/checkout/shipping diff --git a/www/utils/generated/oas-output/operations/store/post_store_carts_[id]_complete.ts b/www/utils/generated/oas-output/operations/store/post_store_carts_[id]_complete.ts index 56c3332214d0f..540e3647139fa 100644 --- a/www/utils/generated/oas-output/operations/store/post_store_carts_[id]_complete.ts +++ b/www/utils/generated/oas-output/operations/store/post_store_carts_[id]_complete.ts @@ -94,8 +94,8 @@ * type: string * title: type * description: > - * The error's type. Can be a [MedusaError type](https://docs.medusajs.com/v2/advanced-development/api-routes/errors#medusaerror-types) - * or `payment_authorization_error` or `payment_requires_more_error` for payment-related errors. + * The error's type. Can be a [MedusaError type](https://docs.medusajs.com/v2/advanced-development/api-routes/errors#medusaerror-types) or `payment_authorization_error` or + * `payment_requires_more_error` for payment-related errors. * "400": * $ref: "#/components/responses/400_error" * "401": diff --git a/www/utils/generated/oas-output/operations/store/post_store_customers.ts b/www/utils/generated/oas-output/operations/store/post_store_customers.ts index 330fb03559caf..a1606c5c1fd6b 100644 --- a/www/utils/generated/oas-output/operations/store/post_store_customers.ts +++ b/www/utils/generated/oas-output/operations/store/post_store_customers.ts @@ -68,6 +68,9 @@ * "500": * $ref: "#/components/responses/500_error" * x-workflow: createCustomerAccountWorkflow + * security: + * - cookie_auth: [] + * - jwt_token: [] * */ diff --git a/www/utils/generated/oas-output/operations/store/post_store_payment-collections_[id]_payment-sessions.ts b/www/utils/generated/oas-output/operations/store/post_store_payment-collections_[id]_payment-sessions.ts index 2b68f3f7c6b92..a5b690d40264a 100644 --- a/www/utils/generated/oas-output/operations/store/post_store_payment-collections_[id]_payment-sessions.ts +++ b/www/utils/generated/oas-output/operations/store/post_store_payment-collections_[id]_payment-sessions.ts @@ -3,7 +3,8 @@ * operationId: PostPaymentCollectionsIdPaymentSessions * summary: Initialize Payment Session of a Payment Collection * x-sidebar-summary: Initialize Payment Session - * description: Initialize and add a payment session to a payment collection. This is used during checkout, where you create a payment collection for the cart, then initialize a payment session for the payment provider that the customer chooses. + * description: Initialize and add a payment session to a payment collection. This is used during checkout, where you create a payment collection for the cart, then initialize a payment session for the + * payment provider that the customer chooses. * externalDocs: * url: https://docs.medusajs.com/v2/resources/storefront-development/checkout/payment * description: "Storefront guide: How to implement payment during checkout." diff --git a/www/utils/generated/oas-output/schemas/AdminApplicationMethod.ts b/www/utils/generated/oas-output/schemas/AdminApplicationMethod.ts new file mode 100644 index 0000000000000..317c30c141943 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminApplicationMethod.ts @@ -0,0 +1,118 @@ +/** + * @schema AdminApplicationMethod + * type: object + * description: The promotion's application method. + * x-schemaName: AdminApplicationMethod + * required: + * - id + * properties: + * promotion: + * type: object + * description: The application method's promotion. + * x-schemaName: AdminPromotion + * required: + * - id + * properties: + * application_method: + * type: object + * description: The promotion's application method. + * x-schemaName: AdminApplicationMethod + * rules: + * type: array + * description: The promotion's rules. + * items: + * type: object + * description: The rule's rules. + * x-schemaName: AdminPromotionRule + * id: + * type: string + * title: id + * description: The promotion's ID. + * code: + * type: string + * title: code + * description: The promotion's code. + * type: + * oneOf: + * - type: string + * title: type + * description: The promotion's type. + * - type: string + * title: type + * description: The promotion's type. + * is_automatic: + * type: boolean + * title: is_automatic + * description: The promotion's is automatic. + * campaign_id: + * type: string + * title: campaign_id + * description: The promotion's campaign id. + * campaign: + * type: object + * description: The promotion's campaign. + * x-schemaName: AdminCampaign + * target_rules: + * type: array + * description: The application method's target rules. + * items: + * $ref: "#/components/schemas/AdminPromotionRule" + * buy_rules: + * type: array + * description: The application method's buy rules. + * items: + * $ref: "#/components/schemas/AdminPromotionRule" + * id: + * type: string + * title: id + * description: The application method's ID. + * type: + * oneOf: + * - type: string + * title: type + * description: The application method's type. + * - type: string + * title: type + * description: The application method's type. + * target_type: + * oneOf: + * - type: string + * title: target_type + * description: The application method's target type. + * - type: string + * title: target_type + * description: The application method's target type. + * - type: string + * title: target_type + * description: The application method's target type. + * allocation: + * oneOf: + * - type: string + * title: allocation + * description: The application method's allocation. + * - type: string + * title: allocation + * description: The application method's allocation. + * value: + * type: number + * title: value + * description: The application method's value. + * currency_code: + * type: string + * title: currency_code + * description: The application method's currency code. + * max_quantity: + * type: number + * title: max_quantity + * description: The application method's max quantity. + * buy_rules_min_quantity: + * type: number + * title: buy_rules_min_quantity + * description: The application method's buy rules min quantity. + * apply_to_quantity: + * type: number + * title: apply_to_quantity + * description: The application method's apply to quantity. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminArchiveOrder.ts b/www/utils/generated/oas-output/schemas/AdminArchiveOrder.ts deleted file mode 100644 index 39b4c9c0fa52d..0000000000000 --- a/www/utils/generated/oas-output/schemas/AdminArchiveOrder.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * @schema AdminArchiveOrder - * type: object - * description: SUMMARY - * x-schemaName: AdminArchiveOrder - * required: - * - order_id - * properties: - * order_id: - * type: string - * title: order_id - * description: The order's order id. - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/AdminCampaign.ts b/www/utils/generated/oas-output/schemas/AdminCampaign.ts index 3d94ccbe52160..d1fa693d31faf 100644 --- a/www/utils/generated/oas-output/schemas/AdminCampaign.ts +++ b/www/utils/generated/oas-output/schemas/AdminCampaign.ts @@ -58,8 +58,8 @@ * type: * type: string * description: > - * The budget's type. `spend` means the limit is set on the total amount discounted by the campaign's promotions; `usage` means the limit is set on the total - * number of times the campaign's promotions can be used. + * The budget's type. `spend` means the limit is set on the total amount discounted by the campaign's promotions; `usage` means the limit is set on the total number of times the campaign's + * promotions can be used. * enum: * - spend * - usage @@ -75,8 +75,8 @@ * type: number * title: used * description: > - * How much of the budget has been used. If the limit is `spend`, this property holds the total amount discounted so far. If the limit is `usage`, it holds - * the number of times the campaign's promotions have been used so far. + * How much of the budget has been used. If the limit is `spend`, this property holds the total amount discounted so far. If the limit is `usage`, it holds the number of times the campaign's + * promotions have been used so far. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminClaim.ts b/www/utils/generated/oas-output/schemas/AdminClaim.ts index 0a76ef82e1044..88f25d123d66c 100644 --- a/www/utils/generated/oas-output/schemas/AdminClaim.ts +++ b/www/utils/generated/oas-output/schemas/AdminClaim.ts @@ -4,44 +4,18 @@ * description: The claim's details. * x-schemaName: AdminClaim * required: - * - order_id - * - claim_items - * - additional_items - * - currency_code + * - order + * - return * - id - * - region_id - * - customer_id - * - sales_channel_id - * - email - * - shipping_methods - * - payment_status - * - fulfillment_status - * - summary - * - metadata + * - type + * - order_id + * - display_id + * - order_version * - created_at * - updated_at - * - original_item_total - * - original_item_subtotal - * - original_item_tax_total - * - item_total - * - item_subtotal - * - item_tax_total - * - original_total - * - original_subtotal - * - original_tax_total - * - total - * - subtotal - * - tax_total - * - discount_total - * - discount_tax_total - * - gift_card_total - * - gift_card_tax_total - * - shipping_total - * - shipping_subtotal - * - shipping_tax_total - * - original_shipping_total - * - original_shipping_subtotal - * - original_shipping_tax_total + * - canceled_at + * - additional_items + * - claim_items * properties: * id: * type: string @@ -62,7 +36,7 @@ * items: * $ref: "#/components/schemas/BaseClaimItem" * return: - * $ref: "#/components/schemas/Return" + * $ref: "#/components/schemas/AdminReturn" * return_id: * type: string * title: return_id @@ -75,76 +49,15 @@ * type: number * title: refund_amount * description: The amount to be refunded. - * currency_code: - * type: string - * title: currency_code - * description: The claim's currency code. - * region_id: - * type: string - * title: region_id - * description: The ID of the region associated with the claim. - * customer_id: - * type: string - * title: customer_id - * description: The ID of the customer associated with the claim's order. - * sales_channel_id: - * type: string - * title: sales_channel_id - * description: The ID of the sales channel the claim's order is created in. - * email: - * type: string - * title: email - * description: The email associated with the claim's order. - * format: email * display_id: * type: number * title: display_id * description: The claim's display ID. - * shipping_address: - * $ref: "#/components/schemas/BaseOrderAddress" - * billing_address: - * $ref: "#/components/schemas/BaseOrderAddress" * shipping_methods: * type: array * description: The claim's shipping methods. * items: - * $ref: "#/components/schemas/BaseOrderShippingMethod" - * payment_collections: - * type: array - * description: The claim's payment collections. - * items: - * $ref: "#/components/schemas/BasePaymentCollection" - * payment_status: - * type: string - * description: The claim's payment status. - * enum: - * - canceled - * - not_paid - * - awaiting - * - authorized - * - partially_authorized - * - captured - * - partially_captured - * - partially_refunded - * - refunded - * - requires_action - * fulfillments: - * type: array - * description: The claim's fulfillments. - * items: - * $ref: "#/components/schemas/BaseOrderFulfillment" - * fulfillment_status: - * type: string - * description: The claim's fulfillment status. - * enum: - * - canceled - * - not_fulfilled - * - partially_fulfilled - * - fulfilled - * - partially_shipped - * - shipped - * - partially_delivered - * - delivered + * $ref: "#/components/schemas/AdminOrderShippingMethod" * transactions: * type: array * description: The claim's transactions. @@ -153,8 +66,6 @@ * description: Learn more about transactions of orders and associated models. * items: * $ref: "#/components/schemas/BaseOrderTransaction" - * summary: - * $ref: "#/components/schemas/BaseOrderSummary" * metadata: * type: object * description: The claim's metadata, used to store custom key-value pairs. @@ -168,94 +79,34 @@ * format: date-time * title: updated_at * description: The claim's update date. - * original_item_total: - * type: number - * title: original_item_total - * description: The total of the original items in the associated order. - * original_item_subtotal: - * type: number - * title: original_item_subtotal - * description: The subtotal of the original items in the associated order. - * original_item_tax_total: - * type: number - * title: original_item_tax_total - * description: The tax total of the original items in the associated order. - * item_total: - * type: number - * title: item_total - * description: The total of the claim's items. - * item_subtotal: - * type: number - * title: item_subtotal - * description: The subtotal of the claim's items. - * item_tax_total: - * type: number - * title: item_tax_total - * description: The tax total of the claim's items. - * original_total: - * type: number - * title: original_total - * description: The associated order's original total. - * original_subtotal: - * type: number - * title: original_subtotal - * description: The associated order's original subtotal. - * original_tax_total: - * type: number - * title: original_tax_total - * description: The associated order's original tax total. - * total: - * type: number - * title: total - * description: The associated order's total. - * subtotal: - * type: number - * title: subtotal - * description: The claim's subtotal. - * tax_total: - * type: number - * title: tax_total - * description: The claim's tax total. - * discount_total: - * type: number - * title: discount_total - * description: The claim's discount total. - * discount_tax_total: - * type: number - * title: discount_tax_total - * description: The claim's discount tax total. - * gift_card_total: - * type: number - * title: gift_card_total - * description: The claim's gift card total. - * gift_card_tax_total: - * type: number - * title: gift_card_tax_total - * description: The claim's gift card tax total. - * shipping_total: - * type: number - * title: shipping_total - * description: The claim's shipping total. - * shipping_subtotal: - * type: number - * title: shipping_subtotal - * description: The claim's shipping subtotal. - * shipping_tax_total: - * type: number - * title: shipping_tax_total - * description: The claim's shipping tax total. - * original_shipping_total: - * type: number - * title: original_shipping_total - * description: The associated order's original shipping total. - * original_shipping_subtotal: - * type: number - * title: original_shipping_subtotal - * description: The associated order's original shipping subtotal. - * original_shipping_tax_total: - * type: number - * title: original_shipping_tax_total - * description: The associated order's original shipping tax total. + * order: + * type: string + * title: order + * description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + * type: + * type: string + * description: The claim's type. + * enum: + * - replace + * - refund + * order_version: + * type: string + * title: order_version + * description: The claim's order version. + * created_by: + * type: string + * title: created_by + * description: The claim's created by. + * canceled_at: + * type: string + * title: canceled_at + * description: The claim's canceled at. + * format: date-time + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The claim's deleted at. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminClaimOrderResponse.ts b/www/utils/generated/oas-output/schemas/AdminClaimOrderResponse.ts index 8f9dc90c027b8..89be9e9cf490f 100644 --- a/www/utils/generated/oas-output/schemas/AdminClaimOrderResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminClaimOrderResponse.ts @@ -8,7 +8,9 @@ * - claim * properties: * order: - * $ref: "#/components/schemas/Order" + * type: string + * title: order + * description: The order change's order. * claim: * $ref: "#/components/schemas/AdminClaim" * diff --git a/www/utils/generated/oas-output/schemas/AdminClaimPreviewResponse.ts b/www/utils/generated/oas-output/schemas/AdminClaimPreviewResponse.ts index 5c3753d082184..7a31abdced5f2 100644 --- a/www/utils/generated/oas-output/schemas/AdminClaimPreviewResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminClaimPreviewResponse.ts @@ -8,7 +8,7 @@ * - claim * properties: * order_preview: - * $ref: "#/components/schemas/OrderPreview" + * $ref: "#/components/schemas/AdminOrderPreview" * claim: * $ref: "#/components/schemas/AdminClaim" * diff --git a/www/utils/generated/oas-output/schemas/AdminClaimRequestResponse.ts b/www/utils/generated/oas-output/schemas/AdminClaimRequestResponse.ts index ed77912751e77..b09200f9f0667 100644 --- a/www/utils/generated/oas-output/schemas/AdminClaimRequestResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminClaimRequestResponse.ts @@ -11,7 +11,7 @@ * return: * $ref: "#/components/schemas/AdminReturn" * order_preview: - * $ref: "#/components/schemas/OrderPreview" + * $ref: "#/components/schemas/AdminOrderPreview" * claim: * $ref: "#/components/schemas/AdminClaim" * diff --git a/www/utils/generated/oas-output/schemas/AdminClaimReturnPreviewResponse.ts b/www/utils/generated/oas-output/schemas/AdminClaimReturnPreviewResponse.ts index 24759943eb5f6..cecc92e96613d 100644 --- a/www/utils/generated/oas-output/schemas/AdminClaimReturnPreviewResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminClaimReturnPreviewResponse.ts @@ -8,7 +8,7 @@ * - return * properties: * order_preview: - * $ref: "#/components/schemas/OrderPreview" + * $ref: "#/components/schemas/AdminOrderPreview" * return: * $ref: "#/components/schemas/AdminReturn" * diff --git a/www/utils/generated/oas-output/schemas/AdminCreateApplicationMethod.ts b/www/utils/generated/oas-output/schemas/AdminCreateApplicationMethod.ts deleted file mode 100644 index bf52fb545720e..0000000000000 --- a/www/utils/generated/oas-output/schemas/AdminCreateApplicationMethod.ts +++ /dev/null @@ -1,66 +0,0 @@ -/** - * @schema AdminCreateApplicationMethod - * type: object - * description: The application method's details. - * x-schemaName: AdminCreateApplicationMethod - * required: - * - value - * - type - * - target_type - * properties: - * description: - * type: string - * title: description - * description: The application method's description. - * value: - * type: number - * title: value - * description: The discounted amount applied by the associated promotion based on the `type`. - * currency_code: - * type: string - * title: currency_code - * description: The application method's currency code. - * max_quantity: - * type: number - * title: max_quantity - * description: The max quantity allowed in the cart for the associated promotion to be applied. - * type: - * type: string - * description: The type of the application method indicating how the associated promotion is applied. - * enum: - * - fixed - * - percentage - * target_type: - * type: string - * description: The target type of the application method indicating whether the associated promotion is applied to the cart's items, shipping methods, or the whole order. - * enum: - * - items - * - shipping_methods - * - order - * allocation: - * type: string - * description: The allocation value that indicates whether the associated promotion is applied on each item in a cart or split between the items in the cart. - * enum: - * - each - * - across - * target_rules: - * type: array - * description: The application method's target rules. - * items: - * $ref: "#/components/schemas/AdminCreatePromotionRule" - * buy_rules: - * type: array - * description: The application method's buy rules. - * items: - * $ref: "#/components/schemas/AdminCreatePromotionRule" - * apply_to_quantity: - * type: number - * title: apply_to_quantity - * description: The quantity that results from matching the `buyget` promotion's condition. For example, if the promotion is a "Buy 2 shirts get 1 free", the value f this attribute is `1`. - * buy_rules_min_quantity: - * type: number - * title: buy_rules_min_quantity - * description: The minimum quantity required for a `buyget` promotion to be applied. For example, if the promotion is a "Buy 2 shirts get 1 free", the value of this attribute is `2`. - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/AdminCreateFulfillment.ts b/www/utils/generated/oas-output/schemas/AdminCreateFulfillment.ts index 0895b47c1afd0..9fe2f69296f8a 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreateFulfillment.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateFulfillment.ts @@ -4,15 +4,14 @@ * description: The filfillment's details. * x-schemaName: AdminCreateFulfillment * required: + * - data + * - order_id + * - metadata + * - items * - location_id * - provider_id * - delivery_address - * - items * - labels - * - order - * - order_id - * - data - * - metadata * properties: * location_id: * type: string @@ -77,8 +76,8 @@ * description: An item to fulfill. * required: * - title - * - sku * - quantity + * - sku * - barcode * properties: * title: diff --git a/www/utils/generated/oas-output/schemas/AdminCreatePriceList.ts b/www/utils/generated/oas-output/schemas/AdminCreatePriceList.ts index 1935f0e6b6c3d..64441719d676c 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreatePriceList.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreatePriceList.ts @@ -26,17 +26,27 @@ * description: The date and time the price list ends at. * format: date-time * status: - * type: string + * oneOf: + * - type: string + * description: The price list's status. + * enum: + * - ACTIVE + * - type: string + * description: The price list's status. + * enum: + * - DRAFT * description: The price list's status. - * enum: - * - active - * - draft * type: - * type: string + * oneOf: + * - type: string + * description: The price list's type. + * enum: + * - SALE + * - type: string + * description: The price list's type. + * enum: + * - OVERRIDE * description: The price list's type. - * enum: - * - sale - * - override * rules: * type: object * description: The price list's rules. @@ -50,8 +60,8 @@ * description: A price's details. * required: * - currency_code - * - amount * - variant_id + * - amount * properties: * currency_code: * type: string diff --git a/www/utils/generated/oas-output/schemas/AdminCreateProduct.ts b/www/utils/generated/oas-output/schemas/AdminCreateProduct.ts index 40591a93f416e..cb4734242f66c 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreateProduct.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateProduct.ts @@ -48,13 +48,20 @@ * title: handle * description: The product's handle. * status: - * type: string + * oneOf: + * - type: string + * title: status + * description: The create's status. + * - type: string + * title: status + * description: The create's status. + * - type: string + * title: status + * description: The create's status. + * - type: string + * title: status + * description: The create's status. * description: The product's status. - * enum: - * - draft - * - proposed - * - published - * - rejected * type_id: * type: string * title: type_id diff --git a/www/utils/generated/oas-output/schemas/AdminCreateProductType.ts b/www/utils/generated/oas-output/schemas/AdminCreateProductType.ts new file mode 100644 index 0000000000000..5be0041a03e33 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminCreateProductType.ts @@ -0,0 +1,18 @@ +/** + * @schema AdminCreateProductType + * type: object + * description: The product's details. + * x-schemaName: AdminCreateProductType + * required: + * - value + * properties: + * metadata: + * type: object + * description: The product's metadata, used to store custom key-value pairs. + * value: + * type: string + * title: value + * description: The product type's value. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminCreateProductVariant.ts b/www/utils/generated/oas-output/schemas/AdminCreateProductVariant.ts index 110e73afd54b2..5b96a80c7310e 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreateProductVariant.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateProductVariant.ts @@ -84,5 +84,11 @@ * description: The variant's options, where the key is an option's name, and the value is the option's value. * example: * Color: Black + * inventory_items: + * type: array + * description: The variant's inventory items. + * items: + * $ref: "#/components/schemas/AdminCreateProductVariantInventoryKit" + * */ diff --git a/www/utils/generated/oas-output/schemas/AdminCreateProductVariantInventoryKit.ts b/www/utils/generated/oas-output/schemas/AdminCreateProductVariantInventoryKit.ts new file mode 100644 index 0000000000000..b8afe38164a24 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminCreateProductVariantInventoryKit.ts @@ -0,0 +1,19 @@ +/** + * @schema AdminCreateProductVariantInventoryKit + * type: object + * description: The inventory item's inventory items. + * x-schemaName: AdminCreateProductVariantInventoryKit + * required: + * - inventory_item_id + * properties: + * inventory_item_id: + * type: string + * title: inventory_item_id + * description: The inventory item's inventory item id. + * required_quantity: + * type: number + * title: required_quantity + * description: The inventory item's required quantity. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminCreateProductVariantPrice.ts b/www/utils/generated/oas-output/schemas/AdminCreateProductVariantPrice.ts index 2e7e9cb23c8ec..99b5c78d2ff7d 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreateProductVariantPrice.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateProductVariantPrice.ts @@ -28,6 +28,13 @@ * description: The price's rules. * example: * region_id: reg_123 + * properties: + * region_id: + * type: string + * title: region_id + * description: The rule's region id. + * required: + * - region_id * */ diff --git a/www/utils/generated/oas-output/schemas/CreateOrderReturnReason.ts b/www/utils/generated/oas-output/schemas/AdminCreateReturnReason.ts similarity index 89% rename from www/utils/generated/oas-output/schemas/CreateOrderReturnReason.ts rename to www/utils/generated/oas-output/schemas/AdminCreateReturnReason.ts index 29b79e74cfa35..edc544bb07499 100644 --- a/www/utils/generated/oas-output/schemas/CreateOrderReturnReason.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateReturnReason.ts @@ -1,8 +1,8 @@ /** - * @schema CreateOrderReturnReason + * @schema AdminCreateReturnReason * type: object * description: SUMMARY - * x-schemaName: CreateOrderReturnReason + * x-schemaName: AdminCreateReturnReason * required: * - value * - label diff --git a/www/utils/generated/oas-output/schemas/AdminCreateShippingOption.ts b/www/utils/generated/oas-output/schemas/AdminCreateShippingOption.ts index 7cbadb6e15e78..06e04377d50ff 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreateShippingOption.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateShippingOption.ts @@ -1,7 +1,7 @@ /** * @schema AdminCreateShippingOption * type: object - * description: The shipping option's details. + * description: The shipping option's type. * x-schemaName: AdminCreateShippingOption * required: * - label diff --git a/www/utils/generated/oas-output/schemas/AdminCreateShippingOptionRule.ts b/www/utils/generated/oas-output/schemas/AdminCreateShippingOptionRule.ts deleted file mode 100644 index 6289aaf162708..0000000000000 --- a/www/utils/generated/oas-output/schemas/AdminCreateShippingOptionRule.ts +++ /dev/null @@ -1,43 +0,0 @@ -/** - * @schema AdminCreateShippingOptionRule - * type: object - * description: The details of the shipping option rule. - * x-schemaName: AdminCreateShippingOptionRule - * required: - * - operator - * - attribute - * - value - * properties: - * operator: - * type: string - * description: The operator used to check whether a rule applies. - * enum: - * - gt - * - lt - * - eq - * - ne - * - in - * - lte - * - gte - * - nin - * attribute: - * type: string - * title: attribute - * description: The name of a property or table that the rule applies to. - * example: customer_group - * value: - * oneOf: - * - type: string - * title: value - * description: A value of the attribute that enables this rule. - * example: cusgroup_123 - * - type: array - * description: Values of the attribute that enable this rule. - * items: - * type: string - * title: value - * description: A value of the attribute that enables this rule. - * example: cusgroup_123 - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/AdminCreateVariantInventoryItem.ts b/www/utils/generated/oas-output/schemas/AdminCreateVariantInventoryItem.ts index 492005c32a09e..6b6ff947a2c03 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreateVariantInventoryItem.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateVariantInventoryItem.ts @@ -4,8 +4,8 @@ * description: The details of the variant-inventory item association. * x-schemaName: AdminCreateVariantInventoryItem * required: - * - required_quantity * - inventory_item_id + * - required_quantity * properties: * required_quantity: * type: number diff --git a/www/utils/generated/oas-output/schemas/AdminCreateWorkflowsAsyncResponse.ts b/www/utils/generated/oas-output/schemas/AdminCreateWorkflowsAsyncResponse.ts index a568a9e1de7f1..54109e4733bff 100644 --- a/www/utils/generated/oas-output/schemas/AdminCreateWorkflowsAsyncResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminCreateWorkflowsAsyncResponse.ts @@ -20,11 +20,16 @@ * compensate_input: * description: Sets the compensation function's input. It accepts any response. * action: - * type: string + * oneOf: + * - type: string + * description: The workflows execution's action. + * enum: + * - INVOKE + * - type: string + * description: The workflows execution's action. + * enum: + * - COMPENSATE * description: Whether to invoke or compensate the step. - * enum: - * - invoke - * - compensate * */ diff --git a/www/utils/generated/oas-output/schemas/AdminCurrency.ts b/www/utils/generated/oas-output/schemas/AdminCurrency.ts index 1534e68d8df09..dce4f79075d72 100644 --- a/www/utils/generated/oas-output/schemas/AdminCurrency.ts +++ b/www/utils/generated/oas-output/schemas/AdminCurrency.ts @@ -10,7 +10,6 @@ * - name * - decimal_digits * - rounding - * - raw_rounding * - created_at * - updated_at * - deleted_at diff --git a/www/utils/generated/oas-output/schemas/AdminCustomer.ts b/www/utils/generated/oas-output/schemas/AdminCustomer.ts index 9af5a8c409a1a..befb5c96a83d4 100644 --- a/www/utils/generated/oas-output/schemas/AdminCustomer.ts +++ b/www/utils/generated/oas-output/schemas/AdminCustomer.ts @@ -56,7 +56,7 @@ * type: array * description: The customer's addresses. * items: - * $ref: "#/components/schemas/AdminCustomerAddress" + * $ref: "#/components/schemas/BaseCustomerAddress" * phone: * type: string * title: phone diff --git a/www/utils/generated/oas-output/schemas/AdminCustomerGroup.ts b/www/utils/generated/oas-output/schemas/AdminCustomerGroup.ts index edfaed861cacf..c23881953769b 100644 --- a/www/utils/generated/oas-output/schemas/AdminCustomerGroup.ts +++ b/www/utils/generated/oas-output/schemas/AdminCustomerGroup.ts @@ -23,7 +23,7 @@ * type: array * description: The customer group's customers. * items: - * $ref: "#/components/schemas/AdminCustomer" + * $ref: "#/components/schemas/BaseCustomer" * metadata: * type: object * description: The customer group's metadata, used to store custom key-value pairs. diff --git a/www/utils/generated/oas-output/schemas/AdminExchange.ts b/www/utils/generated/oas-output/schemas/AdminExchange.ts index ea63dbc92a77b..91b3c06540663 100644 --- a/www/utils/generated/oas-output/schemas/AdminExchange.ts +++ b/www/utils/generated/oas-output/schemas/AdminExchange.ts @@ -4,44 +4,14 @@ * description: The exchange's details. * x-schemaName: AdminExchange * required: - * - order_id - * - return_items - * - additional_items - * - currency_code * - id - * - region_id - * - customer_id - * - sales_channel_id - * - email - * - shipping_methods - * - payment_status - * - fulfillment_status - * - summary - * - metadata + * - order_id * - created_at * - updated_at - * - original_item_total - * - original_item_subtotal - * - original_item_tax_total - * - item_total - * - item_subtotal - * - item_tax_total - * - original_total - * - original_subtotal - * - original_tax_total - * - total - * - subtotal - * - tax_total - * - discount_total - * - discount_tax_total - * - gift_card_total - * - gift_card_tax_total - * - shipping_total - * - shipping_subtotal - * - shipping_tax_total - * - original_shipping_total - * - original_shipping_subtotal - * - original_shipping_tax_total + * - canceled_at + * - deleted_at + * - additional_items + * - return_items * properties: * order_id: * type: string @@ -66,88 +36,24 @@ * title: difference_due * description: The amount to be exchanged or refunded. If the amount is negative, it must be refunded. If positive, additional payment is required from the customer. * return: - * description: the return associated with the exchange. * $ref: "#/components/schemas/AdminReturn" * return_id: * type: string * title: return_id * description: The ID of the associated exchange. - * currency_code: - * type: string - * title: currency_code - * description: The exchange's currency code. * id: * type: string * title: id * description: The exchange's ID. - * region_id: - * type: string - * title: region_id - * description: The ID of the associated order's region. - * customer_id: - * type: string - * title: customer_id - * description: The ID of the customer that placed the order. - * sales_channel_id: - * type: string - * title: sales_channel_id - * description: The ID of the sales channel the associated order belongs to. - * email: - * type: string - * title: email - * description: The email used when placing the order. - * format: email * display_id: - * type: number + * type: string * title: display_id * description: The exchange's display ID. - * shipping_address: - * description: The shipping address to send new items to. - * $ref: "#/components/schemas/BaseOrderAddress" - * billing_address: - * description: The customer's billing address. - * $ref: "#/components/schemas/BaseOrderAddress" * shipping_methods: * type: array * description: The shipping methods used to send the new (outbound) items. * items: * $ref: "#/components/schemas/BaseOrderShippingMethod" - * payment_collections: - * type: array - * description: The exchange's payment collections. - * items: - * $ref: "#/components/schemas/BasePaymentCollection" - * payment_status: - * type: string - * description: The exchange's payment status. - * enum: - * - canceled - * - not_paid - * - awaiting - * - authorized - * - partially_authorized - * - captured - * - partially_captured - * - partially_refunded - * - refunded - * - requires_action - * fulfillments: - * type: array - * description: The exchange's fulfillments of new (outbound) items. - * items: - * $ref: "#/components/schemas/BaseOrderFulfillment" - * fulfillment_status: - * type: string - * description: The exchange's fulfillment status. - * enum: - * - canceled - * - not_fulfilled - * - partially_fulfilled - * - fulfilled - * - partially_shipped - * - shipped - * - partially_delivered - * - delivered * transactions: * type: array * description: The exchange's transactions. @@ -155,9 +61,6 @@ * url: https://docs.medusajs.com/v2/resources/commerce-modules/order/transactions * items: * $ref: "#/components/schemas/BaseOrderTransaction" - * summary: - * description: The totals summary of the exchange. - * $ref: "#/components/schemas/BaseOrderSummary" * metadata: * type: object * description: The exchange's metadata, can hold custom key-value pairs. @@ -171,94 +74,32 @@ * format: date-time * title: updated_at * description: The date that the exchange was updated. - * original_item_total: - * type: number - * title: original_item_total - * description: The total of the original items in the order. - * original_item_subtotal: - * type: number - * title: original_item_subtotal - * description: The subtotal of the original items in the order. - * original_item_tax_total: - * type: number - * title: original_item_tax_total - * description: The total tax of the original items in the order. - * item_total: - * type: number - * title: item_total - * description: The total of the exchange's new items. - * item_subtotal: - * type: number - * title: item_subtotal - * description: The subtotal of the exchange's new items. - * item_tax_total: - * type: number - * title: item_tax_total - * description: The tax total of the exchange's new items. - * original_total: - * type: number - * title: original_total - * description: The total of the order. - * original_subtotal: - * type: number - * title: original_subtotal - * description: The subtotal of the order. - * original_tax_total: - * type: number - * title: original_tax_total - * description: The tax total of the order. - * total: - * type: number - * title: total - * description: The total of the exchange. - * subtotal: - * type: number - * title: subtotal - * description: The subtotal of the exchange. - * tax_total: - * type: number - * title: tax_total - * description: The tax total of the exchange. - * discount_total: - * type: number - * title: discount_total - * description: The discount total of the exchange. - * discount_tax_total: - * type: number - * title: discount_tax_total - * description: The total taxes on discount of the exchange. - * gift_card_total: - * type: number - * title: gift_card_total - * description: The gift cards total of the exchange. - * gift_card_tax_total: - * type: number - * title: gift_card_tax_total - * description: The total taxes on the gift card of the exchange. - * shipping_total: - * type: number - * title: shipping_total - * description: The exchange's shipping total. - * shipping_subtotal: - * type: number - * title: shipping_subtotal - * description: The exchange's shipping subtotal. - * shipping_tax_total: - * type: number - * title: shipping_tax_total - * description: The exchange's shipping tax total. - * original_shipping_total: - * type: number - * title: original_shipping_total - * description: The order's shipping total. - * original_shipping_subtotal: - * type: number - * title: original_shipping_subtotal - * description: The order's shipping subtotal. - * original_shipping_tax_total: - * type: number - * title: original_shipping_tax_total - * description: The order's shipping tax total. + * order_version: + * type: string + * title: order_version + * description: The exchange's order version. + * created_by: + * type: string + * title: created_by + * description: The exchange's created by. + * canceled_at: + * type: string + * title: canceled_at + * description: The exchange's canceled at. + * format: date-time + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The exchange's deleted at. + * order: + * type: string + * title: order + * description: The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with `-`. + * allow_backorder: + * type: boolean + * title: allow_backorder + * description: The exchange's allow backorder. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminExchangeOrderResponse.ts b/www/utils/generated/oas-output/schemas/AdminExchangeOrderResponse.ts index aaeac3d197169..1f663050467a9 100644 --- a/www/utils/generated/oas-output/schemas/AdminExchangeOrderResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminExchangeOrderResponse.ts @@ -8,8 +8,9 @@ * - exchange * properties: * order: - * description: The details of the associated order. - * $ref: "#/components/schemas/Order" + * type: string + * title: order + * description: The order change's order. * exchange: * $ref: "#/components/schemas/AdminExchange" * diff --git a/www/utils/generated/oas-output/schemas/AdminExchangePreviewResponse.ts b/www/utils/generated/oas-output/schemas/AdminExchangePreviewResponse.ts index a6db8449985f8..c257a76d4d3fa 100644 --- a/www/utils/generated/oas-output/schemas/AdminExchangePreviewResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminExchangePreviewResponse.ts @@ -8,7 +8,7 @@ * - exchange * properties: * order_preview: - * $ref: "#/components/schemas/OrderPreview" + * $ref: "#/components/schemas/AdminOrderPreview" * exchange: * $ref: "#/components/schemas/AdminExchange" * diff --git a/www/utils/generated/oas-output/schemas/AdminExchangeRequestResponse.ts b/www/utils/generated/oas-output/schemas/AdminExchangeRequestResponse.ts index 27a0f26cf31b9..fb5e1b6da43f2 100644 --- a/www/utils/generated/oas-output/schemas/AdminExchangeRequestResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminExchangeRequestResponse.ts @@ -9,11 +9,9 @@ * - exchange * properties: * return: - * description: The associated return's details. * $ref: "#/components/schemas/AdminReturn" * order_preview: - * description: A preview of the order once the exchange is applied. - * $ref: "#/components/schemas/OrderPreview" + * $ref: "#/components/schemas/AdminOrderPreview" * exchange: * $ref: "#/components/schemas/AdminExchange" * diff --git a/www/utils/generated/oas-output/schemas/AdminExchangeReturnResponse.ts b/www/utils/generated/oas-output/schemas/AdminExchangeReturnResponse.ts index 756d67aec2137..2426fa11b872d 100644 --- a/www/utils/generated/oas-output/schemas/AdminExchangeReturnResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminExchangeReturnResponse.ts @@ -8,7 +8,7 @@ * - return * properties: * order_preview: - * $ref: "#/components/schemas/OrderPreview" + * $ref: "#/components/schemas/AdminOrderPreview" * return: * $ref: "#/components/schemas/AdminReturn" * diff --git a/www/utils/generated/oas-output/schemas/AdminExportProductRequest.ts b/www/utils/generated/oas-output/schemas/AdminExportProductRequest.ts new file mode 100644 index 0000000000000..806b01b1c6527 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminExportProductRequest.ts @@ -0,0 +1,8 @@ +/** + * @schema AdminExportProductRequest + * type: object + * description: SUMMARY + * x-schemaName: AdminExportProductRequest + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminFulfillment.ts b/www/utils/generated/oas-output/schemas/AdminFulfillment.ts index 54b0d33a4887d..f8987a23413d4 100644 --- a/www/utils/generated/oas-output/schemas/AdminFulfillment.ts +++ b/www/utils/generated/oas-output/schemas/AdminFulfillment.ts @@ -39,10 +39,8 @@ * title: shipping_option_id * description: The ID of the shipping option this fulfillment is created for. * provider: - * description: The details of the fulfillment provider using to handle this fulfillment. * $ref: "#/components/schemas/AdminFulfillmentProvider" * delivery_address: - * description: The address to deliver the item to. * $ref: "#/components/schemas/AdminFulfillmentAddress" * items: * type: array diff --git a/www/utils/generated/oas-output/schemas/AdminFulfillmentSet.ts b/www/utils/generated/oas-output/schemas/AdminFulfillmentSet.ts index afe80927e6a61..b7275b238ee7a 100644 --- a/www/utils/generated/oas-output/schemas/AdminFulfillmentSet.ts +++ b/www/utils/generated/oas-output/schemas/AdminFulfillmentSet.ts @@ -26,7 +26,9 @@ * title: type * description: The fulfillment set's type. * location: - * $ref: "#/components/schemas/AdminStockLocation" + * type: object + * description: The stock location's details. + * x-schemaName: AdminStockLocation * service_zones: * type: array * description: The fulfillment set's service zones. diff --git a/www/utils/generated/oas-output/schemas/AdminMarkOrderFulfillmentDelivered.ts b/www/utils/generated/oas-output/schemas/AdminMarkOrderFulfillmentDelivered.ts new file mode 100644 index 0000000000000..5bcfff9aa2e61 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminMarkOrderFulfillmentDelivered.ts @@ -0,0 +1,8 @@ +/** + * @schema AdminMarkOrderFulfillmentDelivered + * type: object + * description: SUMMARY + * x-schemaName: AdminMarkOrderFulfillmentDelivered + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminOrder.ts b/www/utils/generated/oas-output/schemas/AdminOrder.ts index 27cdcf401744e..ef2d92706a74d 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrder.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrder.ts @@ -5,21 +5,20 @@ * x-schemaName: AdminOrder * required: * - payment_collections + * - items + * - shipping_methods + * - currency_code * - id + * - created_at + * - updated_at + * - email * - version * - region_id * - customer_id * - sales_channel_id - * - email - * - currency_code - * - items - * - shipping_methods * - payment_status * - fulfillment_status * - summary - * - metadata - * - created_at - * - updated_at * - original_item_total * - original_item_subtotal * - original_item_tax_total @@ -52,7 +51,7 @@ * type: array * description: The order's fulfillments. * items: - * $ref: "#/components/schemas/BaseOrderFulfillment" + * $ref: "#/components/schemas/AdminOrderFulfillment" * sales_channel: * $ref: "#/components/schemas/AdminSalesChannel" * customer: @@ -98,12 +97,12 @@ * type: array * description: The order's items. * items: - * $ref: "#/components/schemas/BaseOrderLineItem" + * $ref: "#/components/schemas/AdminOrderLineItem" * shipping_methods: * type: array * description: The order's shipping methods. * items: - * $ref: "#/components/schemas/BaseOrderShippingMethod" + * $ref: "#/components/schemas/AdminOrderShippingMethod" * payment_status: * type: string * description: The order's payment status. diff --git a/www/utils/generated/oas-output/schemas/AdminOrderChange.ts b/www/utils/generated/oas-output/schemas/AdminOrderChange.ts index 0f7e52cb6d71a..3bcc38d0886fc 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderChange.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderChange.ts @@ -1,154 +1,153 @@ /** * @schema AdminOrderChange * type: object - * description: The order preview's order change. + * description: The order change's details. * x-schemaName: AdminOrderChange * required: * - order * - claim - * - return + * - return_order * - exchange + * - actions + * - status + * - order_id + * - metadata * - id + * - created_at + * - updated_at * - version - * - order_id + * - canceled_at * - return_id * - exchange_id * - claim_id - * - return_order - * - actions - * - status * - requested_by * - requested_at * - confirmed_by * - confirmed_at * - declined_by * - declined_reason - * - metadata * - declined_at * - canceled_by - * - canceled_at - * - created_at - * - updated_at * properties: * id: * type: string * title: id * description: The order change's ID. + * version: + * type: number + * title: version + * description: The order change's version. This will be the order's version when the change is applied. + * change_type: + * oneOf: + * - type: string + * title: change_type + * description: The order change's change type. + * - type: string + * title: change_type + * description: The order change's change type. + * - type: string + * title: change_type + * description: The order change's change type. + * - type: string + * title: change_type + * description: The order change's change type. + * - type: string + * title: change_type + * description: The order change's change type. + * description: The order change's type. * order_id: * type: string * title: order_id - * description: The order change's order id. + * description: The ID of the order this change applies on. + * return_id: + * type: string + * title: return_id + * description: The ID of the associated return. + * exchange_id: + * type: string + * title: exchange_id + * description: The ID of the associated exchange. + * claim_id: + * type: string + * title: claim_id + * description: The ID of the associated claim. + * order: + * type: string + * title: order + * description: The order change's order. + * return_order: + * $ref: "#/components/schemas/AdminReturn" + * exchange: + * $ref: "#/components/schemas/AdminExchange" + * claim: + * $ref: "#/components/schemas/AdminClaim" * actions: * type: array * description: The order change's actions. * items: - * $ref: "#/components/schemas/BaseOrderChangeAction" + * $ref: "#/components/schemas/AdminOrderChangeAction" * status: * type: string - * title: status * description: The order change's status. + * enum: + * - canceled + * - requested + * - pending + * - confirmed + * - declined * requested_by: * type: string * title: requested_by - * description: The order change's requested by. + * description: The ID of the user that requested the change. * requested_at: - * oneOf: - * - type: string - * title: requested_at - * description: The order change's requested at. - * - type: string - * title: requested_at - * description: The order change's requested at. - * format: date-time + * type: string + * title: requested_at + * description: The date the order change was requested. + * format: date-time * confirmed_by: * type: string * title: confirmed_by - * description: The order change's confirmed by. + * description: The ID of the user that confirmed the order change. * confirmed_at: - * oneOf: - * - type: string - * title: confirmed_at - * description: The order change's confirmed at. - * - type: string - * title: confirmed_at - * description: The order change's confirmed at. - * format: date-time + * type: string + * title: confirmed_at + * description: The date the order change was confirmed. + * format: date-time * declined_by: * type: string * title: declined_by - * description: The order change's declined by. + * description: The ID of the user that declined the order change. * declined_reason: * type: string * title: declined_reason - * description: The order change's declined reason. + * description: The reason the order change was declined. * metadata: * type: object - * description: The order change's metadata. + * description: The order change's metadata, can hold custom key-value pairs. * declined_at: - * oneOf: - * - type: string - * title: declined_at - * description: The order change's declined at. - * - type: string - * title: declined_at - * description: The order change's declined at. - * format: date-time + * type: string + * title: declined_at + * description: The date the order change was declined. + * format: date-time * canceled_by: * type: string * title: canceled_by - * description: The order change's canceled by. + * description: The ID of the user that canceled the order change. * canceled_at: - * oneOf: - * - type: string - * title: canceled_at - * description: The order change's canceled at. - * - type: string - * title: canceled_at - * description: The order change's canceled at. - * format: date-time + * type: string + * title: canceled_at + * description: The date the order change was canceled. + * format: date-time * created_at: * type: string * format: date-time * title: created_at - * description: The order change's created at. + * description: The date the order change was created. * updated_at: * type: string * format: date-time * title: updated_at - * description: The order change's updated at. - * version: - * type: number - * title: version - * description: The order change's version. - * change_type: - * type: string - * description: The order change's change type. - * enum: - * - return - * - exchange - * - claim - * - edit - * - return_request - * return_id: - * type: string - * title: return_id - * description: The order change's return id. - * exchange_id: - * type: string - * title: exchange_id - * description: The order change's exchange id. - * claim_id: - * type: string - * title: claim_id - * description: The order change's claim id. - * order: - * $ref: "#/components/schemas/AdminOrder" - * return_order: - * $ref: "#/components/schemas/AdminReturn" - * exchange: - * $ref: "#/components/schemas/AdminExchange" - * claim: - * $ref: "#/components/schemas/AdminClaim" + * description: The date the order change was updated. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderChangeAction.ts b/www/utils/generated/oas-output/schemas/AdminOrderChangeAction.ts index 568529b6a8003..44309796b5baf 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderChangeAction.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderChangeAction.ts @@ -1,11 +1,25 @@ /** * @schema AdminOrderChangeAction * type: object - * description: The action's details. + * description: The order change action's details. * x-schemaName: AdminOrderChangeAction + * required: + * - order_change + * - order + * - order_id + * - internal_note + * - id + * - created_at + * - updated_at + * - return_id + * - exchange_id + * - claim_id + * - order_change_id + * - reference + * - reference_id + * - action + * - details * properties: - * order_change: - * $ref: "#/components/schemas/AdminOrderChange" * id: * type: string * title: id @@ -13,11 +27,29 @@ * order_change_id: * type: string * title: order_change_id - * description: The ID of the order change this action belongs to. + * description: The ID of the order change that the action belongs to. + * order_change: + * $ref: "#/components/schemas/AdminOrderChange" * order_id: * type: string * title: order_id - * description: The ID of the associated order. + * description: The ID of the order the associated change is for. + * return_id: + * type: string + * title: return_id + * description: The ID of the associated return. + * claim_id: + * type: string + * title: claim_id + * description: The ID of the associated claim. + * exchange_id: + * type: string + * title: exchange_id + * description: The ID of the associated exchange. + * order: + * type: string + * title: order + * description: The order change's order. * reference: * type: string * title: reference @@ -33,8 +65,23 @@ * description: The ID of the record in the referenced table. * action: * type: string - * title: action * description: The applied action. + * enum: + * - CANCEL_RETURN_ITEM + * - FULFILL_ITEM + * - DELIVER_ITEM + * - CANCEL_ITEM_FULFILLMENT + * - ITEM_ADD + * - ITEM_REMOVE + * - ITEM_UPDATE + * - RECEIVE_DAMAGED_RETURN_ITEM + * - RECEIVE_RETURN_ITEM + * - RETURN_ITEM + * - SHIPPING_ADD + * - SHIPPING_REMOVE + * - SHIP_ITEM + * - WRITE_OFF_ITEM + * - REINSTATE_ITEM * details: * type: object * description: The action's details. @@ -44,47 +91,17 @@ * internal_note: * type: string * title: internal_note - * description: A note viewed only by admin users. + * description: A note that's viewed only by admin users. * created_at: * type: string * format: date-time * title: created_at - * description: The date the order change action was created. + * description: The date the action was created. * updated_at: * type: string * format: date-time * title: updated_at - * description: The date the order change action was updated. - * return_id: - * type: string - * title: return_id - * description: The ID of the associated return. - * claim_id: - * type: string - * title: claim_id - * description: The ID of the associated claim. - * exchange_id: - * type: string - * title: exchange_id - * description: The ID of the associated exchange. - * order: - * $ref: "#/components/schemas/BaseOrder" - * required: - * - order_change - * - id - * - order_change_id - * - order_id - * - reference - * - reference_id - * - action - * - details - * - internal_note - * - created_at - * - updated_at - * - return_id - * - claim_id - * - exchange_id - * - order + * description: The date the action was updated. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderChangesResponse.ts b/www/utils/generated/oas-output/schemas/AdminOrderChangesResponse.ts index 2a0edf91b9c6a..caf519784c871 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderChangesResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderChangesResponse.ts @@ -10,7 +10,7 @@ * type: array * description: An order's changes. * items: - * $ref: "#/components/schemas/BaseOrderChange" + * $ref: "#/components/schemas/AdminOrderChange" * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderEditPreviewResponse.ts b/www/utils/generated/oas-output/schemas/AdminOrderEditPreviewResponse.ts index d4ea88105f190..7e842000374c8 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderEditPreviewResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderEditPreviewResponse.ts @@ -7,7 +7,7 @@ * - order_preview * properties: * order_preview: - * $ref: "#/components/schemas/OrderPreview" + * $ref: "#/components/schemas/AdminOrderPreview" * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderEditResponse.ts b/www/utils/generated/oas-output/schemas/AdminOrderEditResponse.ts index 733e24b9198a3..44b69b919ff24 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderEditResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderEditResponse.ts @@ -7,7 +7,7 @@ * - order_change * properties: * order_change: - * $ref: "#/components/schemas/OrderChange" + * $ref: "#/components/schemas/AdminOrderChange" * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderFulfillment.ts b/www/utils/generated/oas-output/schemas/AdminOrderFulfillment.ts index ed6b2051a9232..579a6008525f3 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderFulfillment.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderFulfillment.ts @@ -1,7 +1,7 @@ /** * @schema AdminOrderFulfillment * type: object - * description: The fulfillment's details. + * description: The fulfillment's fulfillments. * x-schemaName: AdminOrderFulfillment * required: * - id @@ -10,6 +10,7 @@ * - shipped_at * - delivered_at * - canceled_at + * - requires_shipping * - data * - provider_id * - shipping_option_id @@ -71,6 +72,10 @@ * format: date-time * title: updated_at * description: The date the fulfillment was updated. + * requires_shipping: + * type: boolean + * title: requires_shipping + * description: The fulfillment's requires shipping. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderLineItem.ts b/www/utils/generated/oas-output/schemas/AdminOrderLineItem.ts index 33887ec101b2d..5564c462b2241 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderLineItem.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderLineItem.ts @@ -1,13 +1,27 @@ /** * @schema AdminOrderLineItem * type: object - * description: The item's details. + * description: The item's items. * x-schemaName: AdminOrderLineItem * required: - * - id * - title + * - metadata + * - id * - subtitle * - thumbnail + * - created_at + * - updated_at + * - item_total + * - item_subtotal + * - item_tax_total + * - original_total + * - original_subtotal + * - original_tax_total + * - total + * - subtotal + * - tax_total + * - discount_total + * - discount_tax_total * - variant_id * - product_id * - product_title @@ -26,20 +40,6 @@ * - unit_price * - quantity * - detail - * - created_at - * - updated_at - * - metadata - * - original_total - * - original_subtotal - * - original_tax_total - * - item_total - * - item_subtotal - * - item_tax_total - * - total - * - subtotal - * - tax_total - * - discount_total - * - discount_tax_total * - refundable_total * - refundable_total_per_unit * properties: @@ -66,7 +66,7 @@ * title: variant_id * description: The ID of the associated variant. * product: - * $ref: "#/components/schemas/BaseProduct" + * $ref: "#/components/schemas/AdminProduct" * product_id: * type: string * title: product_id diff --git a/www/utils/generated/oas-output/schemas/AdminOrderPreview.ts b/www/utils/generated/oas-output/schemas/AdminOrderPreview.ts index 1b21a5046be8a..cda7219834837 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderPreview.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderPreview.ts @@ -7,19 +7,18 @@ * - return_requested_total * - order_change * - currency_code - * - version * - id + * - created_at + * - updated_at + * - email + * - version * - region_id * - customer_id * - sales_channel_id - * - email * - payment_collections * - payment_status * - fulfillment_status * - summary - * - metadata - * - created_at - * - updated_at * - original_item_total * - original_item_subtotal * - original_item_tax_total @@ -48,7 +47,7 @@ * title: return_requested_total * description: The total of the requested return. * order_change: - * $ref: "#/components/schemas/BaseOrderChange" + * $ref: "#/components/schemas/AdminOrderChange" * items: * type: array * description: The order's items. @@ -179,7 +178,7 @@ * compare_at_unit_price: * type: number * title: The original price of the item before a promotion or sale. - * description: The + * description: The * unit_price: * type: number * title: unit_price @@ -493,7 +492,7 @@ * type: array * description: The order's fulfillments. * items: - * $ref: "#/components/schemas/BaseOrderFulfillment" + * $ref: "#/components/schemas/AdminOrderFulfillment" * fulfillment_status: * type: string * description: The order's fulfillment status. diff --git a/www/utils/generated/oas-output/schemas/AdminOrderPreviewResponse.ts b/www/utils/generated/oas-output/schemas/AdminOrderPreviewResponse.ts index 944b249271c52..9fc8081625198 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderPreviewResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderPreviewResponse.ts @@ -7,7 +7,9 @@ * - order * properties: * order: - * $ref: "#/components/schemas/AdminOrderPreview" + * type: string + * title: order + * description: A preview of an order if a change, such as exchange, return, edit, or claim is applied on it. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderResponse.ts b/www/utils/generated/oas-output/schemas/AdminOrderResponse.ts index d16749e467729..a986e8905a34f 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderResponse.ts @@ -7,7 +7,9 @@ * - order * properties: * order: - * $ref: "#/components/schemas/AdminOrder" + * type: string + * title: order + * description: The order's details. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminOrderReturnResponse.ts b/www/utils/generated/oas-output/schemas/AdminOrderReturnResponse.ts index 97033bd4a24cb..7ab2e0f89c6cc 100644 --- a/www/utils/generated/oas-output/schemas/AdminOrderReturnResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminOrderReturnResponse.ts @@ -8,7 +8,9 @@ * - return * properties: * order: - * $ref: "#/components/schemas/Order" + * type: string + * title: order + * description: The order change's order. * return: * $ref: "#/components/schemas/AdminReturn" * diff --git a/www/utils/generated/oas-output/schemas/AdminOrderShippingMethod.ts b/www/utils/generated/oas-output/schemas/AdminOrderShippingMethod.ts new file mode 100644 index 0000000000000..df4f87032e261 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminOrderShippingMethod.ts @@ -0,0 +1,118 @@ +/** + * @schema AdminOrderShippingMethod + * type: object + * description: The shipping method's details. + * x-schemaName: AdminOrderShippingMethod + * required: + * - id + * - order_id + * - name + * - amount + * - is_tax_inclusive + * - shipping_option_id + * - data + * - metadata + * - original_total + * - original_subtotal + * - original_tax_total + * - total + * - subtotal + * - tax_total + * - discount_total + * - discount_tax_total + * - created_at + * - updated_at + * properties: + * id: + * type: string + * title: id + * description: The shipping method's ID. + * order_id: + * type: string + * title: order_id + * description: The ID of the order the shipping method belongs to. + * name: + * type: string + * title: name + * description: The shipping method's name. + * description: + * type: string + * title: description + * description: The shipping method's description. + * amount: + * type: number + * title: amount + * description: The shipping method's amount. + * is_tax_inclusive: + * type: boolean + * title: is_tax_inclusive + * description: Whether the shipping method's amount includes applied taxes. + * shipping_option_id: + * type: string + * title: shipping_option_id + * description: The ID of the shipping option this method was created from. + * data: + * type: object + * description: The shipping method's data, useful for fulfillment provider handling its fulfillment. + * externalDocs: + * url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property + * metadata: + * type: object + * description: The shipping method's metadata, can hold custom key-value pairs. + * tax_lines: + * type: array + * description: The shipping method's tax lines. + * items: + * $ref: "#/components/schemas/BaseOrderShippingMethodTaxLine" + * adjustments: + * type: array + * description: The shipping method's adjustments. + * items: + * $ref: "#/components/schemas/BaseOrderShippingMethodAdjustment" + * original_total: + * type: number + * title: original_total + * description: The shipping method's total including taxes, excluding promotions. + * original_subtotal: + * type: number + * title: original_subtotal + * description: The shipping method's total excluding taxes, including promotions. + * original_tax_total: + * type: number + * title: original_tax_total + * description: The shipping method's total taxes excluding promotions. + * total: + * type: number + * title: total + * description: The shipping method's total including taxes and promotions. + * subtotal: + * type: number + * title: subtotal + * description: The shipping method's total excluding taxes, including promotions. + * tax_total: + * type: number + * title: tax_total + * description: The shipping method's tax total including promotions. + * discount_total: + * type: number + * title: discount_total + * description: The total discounts applied on the shipping method. + * discount_tax_total: + * type: number + * title: discount_tax_total + * description: The taxes applied on the discount amount. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The date the shipping method was created. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The date the shipping method was updated. + * detail: + * $ref: "#/components/schemas/BaseOrderShippingDetail" + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminPayment.ts b/www/utils/generated/oas-output/schemas/AdminPayment.ts index f5ba5a829845d..c08218e88e8cd 100644 --- a/www/utils/generated/oas-output/schemas/AdminPayment.ts +++ b/www/utils/generated/oas-output/schemas/AdminPayment.ts @@ -87,11 +87,11 @@ * type: array * description: The details of payment refunds. * items: - * $ref: "#/components/schemas/BaseRefund" + * $ref: "#/components/schemas/AdminRefund" * payment_collection: - * $ref: "#/components/schemas/BasePaymentCollection" + * $ref: "#/components/schemas/AdminPaymentCollection" * payment_session: - * $ref: "#/components/schemas/BasePaymentSession" + * $ref: "#/components/schemas/AdminPaymentSession" * */ diff --git a/www/utils/generated/oas-output/schemas/AdminPaymentCollection.ts b/www/utils/generated/oas-output/schemas/AdminPaymentCollection.ts index de62171cbdf13..47f94e3ed23a6 100644 --- a/www/utils/generated/oas-output/schemas/AdminPaymentCollection.ts +++ b/www/utils/generated/oas-output/schemas/AdminPaymentCollection.ts @@ -4,12 +4,12 @@ * description: The payment collection's details. * x-schemaName: AdminPaymentCollection * required: + * - payment_providers * - id * - currency_code * - region_id * - amount * - status - * - payment_providers * properties: * id: * type: string @@ -70,17 +70,17 @@ * type: array * description: The payment provider used to process the collection's payments and sessions. * items: - * $ref: "#/components/schemas/BasePaymentProvider" + * $ref: "#/components/schemas/AdminPaymentProvider" * payment_sessions: * type: array * description: The payment collection's payment sessions. * items: - * $ref: "#/components/schemas/BasePaymentSession" + * $ref: "#/components/schemas/AdminPaymentSession" * payments: * type: array * description: The payment collection's payments. * items: - * $ref: "#/components/schemas/BasePayment" + * $ref: "#/components/schemas/AdminPayment" * */ diff --git a/www/utils/generated/oas-output/schemas/AdminPaymentProvider.ts b/www/utils/generated/oas-output/schemas/AdminPaymentProvider.ts index 8199668b77b7e..f9eba5ad0d6bc 100644 --- a/www/utils/generated/oas-output/schemas/AdminPaymentProvider.ts +++ b/www/utils/generated/oas-output/schemas/AdminPaymentProvider.ts @@ -1,7 +1,7 @@ /** * @schema AdminPaymentProvider * type: object - * description: The payment provider's details. + * description: The payment provider's payment providers. * x-schemaName: AdminPaymentProvider * required: * - is_enabled diff --git a/www/utils/generated/oas-output/schemas/AdminPaymentSession.ts b/www/utils/generated/oas-output/schemas/AdminPaymentSession.ts new file mode 100644 index 0000000000000..89e6f58e3ee68 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminPaymentSession.ts @@ -0,0 +1,63 @@ +/** + * @schema AdminPaymentSession + * type: object + * description: The payment session's details. + * x-schemaName: AdminPaymentSession + * properties: + * id: + * type: string + * title: id + * description: The payment session's ID. + * amount: + * type: number + * title: amount + * description: The payment session's amount. + * currency_code: + * type: string + * title: currency_code + * description: The payment session's currency code. + * example: usd + * provider_id: + * type: string + * title: provider_id + * description: The ID of the payment provider processing this session. + * data: + * type: object + * description: The payment session's data, useful for the payment provider processing the payment. + * externalDocs: + * url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + * context: + * type: object + * description: The context around the payment, such as the customer's details. + * example: + * customer: + * id: cus_123 + * status: + * type: string + * description: The payment session's status. + * enum: + * - authorized + * - captured + * - canceled + * - pending + * - requires_more + * - error + * authorized_at: + * type: string + * title: authorized_at + * description: The date the payment session was authorized. + * format: date-time + * payment_collection: + * $ref: "#/components/schemas/AdminPaymentCollection" + * payment: + * $ref: "#/components/schemas/BasePayment" + * required: + * - id + * - amount + * - currency_code + * - provider_id + * - data + * - status + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminPostClaimItemsReqSchema.ts b/www/utils/generated/oas-output/schemas/AdminPostClaimItemsReqSchema.ts index 8864a0e345d6f..39d3000869066 100644 --- a/www/utils/generated/oas-output/schemas/AdminPostClaimItemsReqSchema.ts +++ b/www/utils/generated/oas-output/schemas/AdminPostClaimItemsReqSchema.ts @@ -23,13 +23,24 @@ * title: quantity * description: The quantity of the order's item to add to the claim. * reason: - * type: string + * oneOf: + * - type: string + * description: The item's reason. + * enum: + * - MISSING_ITEM + * - type: string + * description: The item's reason. + * enum: + * - WRONG_ITEM + * - type: string + * description: The item's reason. + * enum: + * - PRODUCTION_FAILURE + * - type: string + * description: The item's reason. + * enum: + * - OTHER * description: The reason the item is claimed. - * enum: - * - missing_item - * - wrong_item - * - production_failure - * - other * description: * type: string * title: description diff --git a/www/utils/generated/oas-output/schemas/AdminPriceListBatchResponse.ts b/www/utils/generated/oas-output/schemas/AdminPriceListBatchResponse.ts index de6914a19df7b..6da5a5f34dd98 100644 --- a/www/utils/generated/oas-output/schemas/AdminPriceListBatchResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminPriceListBatchResponse.ts @@ -37,7 +37,7 @@ * type: string * title: object * description: The name of the deleted object. - * default: "price" + * default: price * deleted: * type: boolean * title: deleted diff --git a/www/utils/generated/oas-output/schemas/AdminPriceListPrice.ts b/www/utils/generated/oas-output/schemas/AdminPriceListPrice.ts index 19225dae0e619..acf2dc74a1d3d 100644 --- a/www/utils/generated/oas-output/schemas/AdminPriceListPrice.ts +++ b/www/utils/generated/oas-output/schemas/AdminPriceListPrice.ts @@ -71,7 +71,7 @@ * type: string * format: date-time * title: deleted_at - * description: The date the price was deleted. + * description: The date the price was deleted. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminProduct.ts b/www/utils/generated/oas-output/schemas/AdminProduct.ts index 6bee20d545b70..2080abf78d6e7 100644 --- a/www/utils/generated/oas-output/schemas/AdminProduct.ts +++ b/www/utils/generated/oas-output/schemas/AdminProduct.ts @@ -4,15 +4,15 @@ * description: The product's details. * x-schemaName: AdminProduct * required: + * - variants * - type + * - options + * - images * - length * - title * - status - * - options * - description * - id - * - created_at - * - updated_at * - handle * - subtitle * - is_giftcard @@ -26,9 +26,10 @@ * - material * - collection_id * - type_id - * - images * - discountable * - external_id + * - created_at + * - updated_at * - deleted_at * properties: * collection: @@ -75,7 +76,7 @@ * type: array * description: The product's options. * items: - * $ref: "#/components/schemas/BaseProductOption" + * $ref: "#/components/schemas/AdminProductOption" * description: * type: string * title: description @@ -153,7 +154,7 @@ * type: array * description: The product's images. * items: - * $ref: "#/components/schemas/BaseProductImage" + * $ref: "#/components/schemas/AdminProductImage" * discountable: * type: boolean * title: discountable diff --git a/www/utils/generated/oas-output/schemas/AdminProductImage.ts b/www/utils/generated/oas-output/schemas/AdminProductImage.ts new file mode 100644 index 0000000000000..d665a8eaab94d --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminProductImage.ts @@ -0,0 +1,38 @@ +/** + * @schema AdminProductImage + * type: object + * description: The image's details. + * x-schemaName: AdminProductImage + * properties: + * id: + * type: string + * title: id + * description: The image's ID. + * url: + * type: string + * title: url + * description: The image's URL. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The date the image was created. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The date the image was updated. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The date the image was deleted. + * metadata: + * type: object + * description: The image's metadata, can hold custom key-value pairs. + * required: + * - id + * - url + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminProductOption.ts b/www/utils/generated/oas-output/schemas/AdminProductOption.ts index 009389c3a0741..e7275d6eeafd7 100644 --- a/www/utils/generated/oas-output/schemas/AdminProductOption.ts +++ b/www/utils/generated/oas-output/schemas/AdminProductOption.ts @@ -3,47 +3,47 @@ * type: object * description: The product option's details. * x-schemaName: AdminProductOption - * required: - * - id - * - title * properties: * id: * type: string * title: id - * description: The product option's ID. + * description: The option's ID. * title: * type: string * title: title - * description: The product option's title. + * description: The option's title. * product: * $ref: "#/components/schemas/AdminProduct" * product_id: * type: string * title: product_id - * description: The ID of the product this option belongs to. + * description: The option's product id. * values: * type: array - * description: The product option's values. + * description: The option's values. * items: - * $ref: "#/components/schemas/BaseProductOptionValue" + * $ref: "#/components/schemas/AdminProductOptionValue" * metadata: * type: object - * description: The product option's metadata, can hold custom key-value pairs. + * description: The option's metadata. * created_at: * type: string * format: date-time * title: created_at - * description: The date the product option was created. + * description: The option's created at. * updated_at: * type: string * format: date-time * title: updated_at - * description: The date the product option was updated. + * description: The option's updated at. * deleted_at: * type: string * format: date-time * title: deleted_at - * description: The date the product option was deleted. + * description: The option's deleted at. + * required: + * - id + * - title * */ diff --git a/www/utils/generated/oas-output/schemas/AdminProductOptionDeleteResponse.ts b/www/utils/generated/oas-output/schemas/AdminProductOptionDeleteResponse.ts index fee9974e1eb8c..2f4c9e7213b4b 100644 --- a/www/utils/generated/oas-output/schemas/AdminProductOptionDeleteResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminProductOptionDeleteResponse.ts @@ -16,7 +16,7 @@ * type: string * title: object * description: The name of the deleted object. - * default: "product_option" + * default: product_option * deleted: * type: boolean * title: deleted diff --git a/www/utils/generated/oas-output/schemas/AdminProductOptionValue.ts b/www/utils/generated/oas-output/schemas/AdminProductOptionValue.ts new file mode 100644 index 0000000000000..1f7a699b7cd5c --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminProductOptionValue.ts @@ -0,0 +1,44 @@ +/** + * @schema AdminProductOptionValue + * type: object + * description: The product option value's details. + * x-schemaName: AdminProductOptionValue + * required: + * - id + * - value + * properties: + * id: + * type: string + * title: id + * description: The value's ID. + * value: + * type: string + * title: value + * description: The value. + * option: + * $ref: "#/components/schemas/AdminProductOption" + * option_id: + * type: string + * title: option_id + * description: The ID of the option this value belongs to. + * metadata: + * type: object + * description: The value's metadata, can hold custom key-value pairs. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The date the value was created. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The date the value was updated. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The date the value was deleted. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminProductVariant.ts b/www/utils/generated/oas-output/schemas/AdminProductVariant.ts index 61d132adcfdc7..d1670f8d02e61 100644 --- a/www/utils/generated/oas-output/schemas/AdminProductVariant.ts +++ b/www/utils/generated/oas-output/schemas/AdminProductVariant.ts @@ -5,6 +5,7 @@ * x-schemaName: AdminProductVariant * required: * - prices + * - options * - id * - title * - sku @@ -21,7 +22,6 @@ * - length * - height * - width - * - options * - created_at * - updated_at * - deleted_at @@ -107,7 +107,7 @@ * type: array * description: The variant's option values. * items: - * $ref: "#/components/schemas/BaseProductOptionValue" + * $ref: "#/components/schemas/AdminProductOptionValue" * product: * $ref: "#/components/schemas/AdminProduct" * product_id: diff --git a/www/utils/generated/oas-output/schemas/AdminProductVariantDeleteResponse.ts b/www/utils/generated/oas-output/schemas/AdminProductVariantDeleteResponse.ts index 5aa38f61b0ed9..d672dc2fe3593 100644 --- a/www/utils/generated/oas-output/schemas/AdminProductVariantDeleteResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminProductVariantDeleteResponse.ts @@ -20,7 +20,7 @@ * type: boolean * title: deleted * description: Whether the product variant was deleted. - * default: "variant" + * default: variant * parent: * $ref: "#/components/schemas/AdminProduct" * diff --git a/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLink.ts b/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLink.ts index ecb6a4cd8128d..9ed3e1b14a6c8 100644 --- a/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLink.ts +++ b/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLink.ts @@ -4,29 +4,29 @@ * description: The details of an association between a product variant and an inventory item. * x-schemaName: AdminProductVariantInventoryLink * required: - * - productService - * - inventoryService + * - Product + * - Inventory * properties: - * productService: + * Product: * type: object - * description: The product variant's details. + * description: The id's product. * required: * - variant_id * properties: * variant_id: * type: string * title: variant_id - * description: The ID of the product variant. - * inventoryService: + * description: The product's variant id. + * Inventory: * type: object - * description: The inventory item's details. + * description: The id's inventory. * required: * - inventory_item_id * properties: * inventory_item_id: * type: string * title: inventory_item_id - * description: The ID of the inventory item. + * description: The inventory's inventory item id. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLinkDeleteResponse.ts b/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLinkDeleteResponse.ts index a369bc5c1c39c..06f6814a41605 100644 --- a/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLinkDeleteResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminProductVariantInventoryLinkDeleteResponse.ts @@ -15,7 +15,7 @@ * type: string * title: object * description: The name of the deleted object. - * default: "variant-inventory-item-link" + * default: variant-inventory-item-link * deleted: * type: boolean * title: deleted diff --git a/www/utils/generated/oas-output/schemas/AdminPromotion.ts b/www/utils/generated/oas-output/schemas/AdminPromotion.ts index 479ea6f4ef423..bd71b0ae9205a 100644 --- a/www/utils/generated/oas-output/schemas/AdminPromotion.ts +++ b/www/utils/generated/oas-output/schemas/AdminPromotion.ts @@ -1,11 +1,16 @@ /** * @schema AdminPromotion * type: object - * description: The promotion's details. + * description: The application method's promotion. * x-schemaName: AdminPromotion - * required: - * - id * properties: + * application_method: + * $ref: "#/components/schemas/AdminApplicationMethod" + * rules: + * type: array + * description: The promotion's rules. + * items: + * $ref: "#/components/schemas/AdminPromotionRule" * id: * type: string * title: id @@ -14,30 +19,26 @@ * type: string * title: code * description: The promotion's code. - * example: OFF50 * type: - * type: string - * description: The promotion's type. - * enum: - * - standard - * - buyget + * oneOf: + * - type: string + * title: type + * description: The promotion's type. + * - type: string + * title: type + * description: The promotion's type. * is_automatic: * type: boolean * title: is_automatic - * description: Whether the promotion is applied on a cart automatically if it matches the promotion's rules. - * application_method: - * $ref: "#/components/schemas/BaseApplicationMethod" - * rules: - * type: array - * description: The promotion's rules. - * items: - * $ref: "#/components/schemas/BasePromotionRule" + * description: The promotion's is automatic. * campaign_id: * type: string * title: campaign_id - * description: The ID of the campaign this promotion belongs to. + * description: The promotion's campaign id. * campaign: * $ref: "#/components/schemas/AdminCampaign" + * required: + * - id * */ diff --git a/www/utils/generated/oas-output/schemas/AdminPromotionRule.ts b/www/utils/generated/oas-output/schemas/AdminPromotionRule.ts index 06d02086b45f9..c4816068a5aa5 100644 --- a/www/utils/generated/oas-output/schemas/AdminPromotionRule.ts +++ b/www/utils/generated/oas-output/schemas/AdminPromotionRule.ts @@ -1,7 +1,7 @@ /** * @schema AdminPromotionRule * type: object - * description: The promotion rule's details. + * description: The target rule's target rules. * x-schemaName: AdminPromotionRule * required: * - id @@ -10,32 +10,41 @@ * id: * type: string * title: id - * description: The promotion rule's ID. + * description: The target rule's ID. * description: * type: string * title: description - * description: The promotion rule's description. + * description: The target rule's description. * attribute: * type: string * title: attribute - * description: The promotion rule's attribute. - * example: customer_group_id + * description: The target rule's attribute. * operator: - * type: string - * description: The updated's operator. - * enum: - * - gt - * - lt - * - eq - * - ne - * - in - * - lte - * - gte + * oneOf: + * - type: string + * title: operator + * description: The target rule's operator. + * - type: string + * title: operator + * description: The target rule's operator. + * - type: string + * title: operator + * description: The target rule's operator. + * - type: string + * title: operator + * description: The target rule's operator. + * - type: string + * title: operator + * description: The target rule's operator. + * - type: string + * title: operator + * description: The target rule's operator. + * - type: string + * title: operator + * description: The target rule's operator. * values: * type: array - * description: The updated's values. - * example: - * - "cusgroup_123" + * description: The target rule's values. * items: * $ref: "#/components/schemas/BasePromotionRuleValue" * diff --git a/www/utils/generated/oas-output/schemas/AdminRefund.ts b/www/utils/generated/oas-output/schemas/AdminRefund.ts new file mode 100644 index 0000000000000..432cbe5a5d836 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/AdminRefund.ts @@ -0,0 +1,43 @@ +/** + * @schema AdminRefund + * type: object + * description: The refund's details. + * x-schemaName: AdminRefund + * required: + * - id + * - amount + * - created_at + * - payment + * properties: + * id: + * type: string + * title: id + * description: The refund's ID. + * amount: + * type: number + * title: amount + * description: The refund's amount. + * refund_reason_id: + * type: string + * title: refund_reason_id + * description: The ID of the refund reason. + * note: + * type: string + * title: note + * description: More details about the refund. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The date the refund was created. + * created_by: + * type: string + * title: created_by + * description: The ID of the user that created the refund. + * payment: + * $ref: "#/components/schemas/BasePayment" + * refund_reason: + * $ref: "#/components/schemas/RefundReason" + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/AdminRegion.ts b/www/utils/generated/oas-output/schemas/AdminRegion.ts index 4e7ae86411449..d009c0536c0ee 100644 --- a/www/utils/generated/oas-output/schemas/AdminRegion.ts +++ b/www/utils/generated/oas-output/schemas/AdminRegion.ts @@ -4,9 +4,9 @@ * description: The region's details. * x-schemaName: AdminRegion * required: - * - id * - name * - currency_code + * - id * properties: * id: * type: string diff --git a/www/utils/generated/oas-output/schemas/AdminReservation.ts b/www/utils/generated/oas-output/schemas/AdminReservation.ts index d61fa20e2f9ff..99da085fc24a2 100644 --- a/www/utils/generated/oas-output/schemas/AdminReservation.ts +++ b/www/utils/generated/oas-output/schemas/AdminReservation.ts @@ -11,7 +11,6 @@ * - external_id * - description * - inventory_item_id - * - inventory_item * properties: * id: * type: string @@ -42,8 +41,7 @@ * title: inventory_item_id * description: The ID of the inventory item this reservation is associated with. * inventory_item: - * type: object - * description: The associated inventory item. + * $ref: "#/components/schemas/AdminInventoryItem" * metadata: * type: object * description: The reservation's metadata, can hold custom key-value pairs. diff --git a/www/utils/generated/oas-output/schemas/AdminReturn.ts b/www/utils/generated/oas-output/schemas/AdminReturn.ts index 6f68b6a60087e..a4bed9e8f0bae 100644 --- a/www/utils/generated/oas-output/schemas/AdminReturn.ts +++ b/www/utils/generated/oas-output/schemas/AdminReturn.ts @@ -4,11 +4,11 @@ * description: The return's details. * x-schemaName: AdminReturn * required: + * - items * - id * - order_id * - order_version * - display_id - * - items * - received_at * - created_at * - canceled_at @@ -17,30 +17,63 @@ * type: string * title: id * description: The return's ID. + * status: + * oneOf: + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. + * description: The return's status. + * refund_amount: + * type: number + * title: refund_amount + * description: The amount refunded by this return. * order_id: * type: string * title: order_id - * description: The ID of the order this return is created for. - * status: + * description: The ID of the associated order. + * items: + * type: array + * description: The return's items. + * items: + * $ref: "#/components/schemas/AdminReturnItem" + * created_at: * type: string - * title: status - * description: The return's status. + * format: date-time + * title: created_at + * description: The date the return was created. + * canceled_at: + * type: string + * title: canceled_at + * description: The date the return was canceled. + * format: date-time * exchange_id: * type: string * title: exchange_id - * description: The ID of the exchange that this return belongs to. + * description: The return's exchange id. * location_id: * type: string * title: location_id - * description: The ID of the location the items are returned to. + * description: The return's location id. * claim_id: * type: string * title: claim_id - * description: The ID of the claim that this return belongs to. + * description: The return's claim id. * order_version: * type: number * title: order_version - * description: The version of the order once the return is applied. + * description: The return's order version. * display_id: * type: number * title: display_id @@ -48,29 +81,11 @@ * no_notification: * type: boolean * title: no_notification - * description: Whether the customer should receive notifications about the return's updates. - * refund_amount: - * type: number - * title: refund_amount - * description: The amount to refund as a result of the return. - * items: - * type: array - * description: The return's items. - * items: - * $ref: "#/components/schemas/BaseReturnItem" + * description: The return's no notification. * received_at: * type: string * title: received_at - * description: The date the return was received. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The date the return was created. - * canceled_at: - * type: string - * title: canceled_at - * description: The date the return was canceled. + * description: The return's received at. * */ diff --git a/www/utils/generated/oas-output/schemas/AdminReturnItem.ts b/www/utils/generated/oas-output/schemas/AdminReturnItem.ts index 077939a72e09b..6b6b1bc95a334 100644 --- a/www/utils/generated/oas-output/schemas/AdminReturnItem.ts +++ b/www/utils/generated/oas-output/schemas/AdminReturnItem.ts @@ -1,7 +1,7 @@ /** * @schema AdminReturnItem * type: object - * description: The return item's details. + * description: The item's items. * x-schemaName: AdminReturnItem * required: * - id diff --git a/www/utils/generated/oas-output/schemas/AdminRuleAttributeOption.ts b/www/utils/generated/oas-output/schemas/AdminRuleAttributeOption.ts index e9a482071350a..77b61ae66b4d0 100644 --- a/www/utils/generated/oas-output/schemas/AdminRuleAttributeOption.ts +++ b/www/utils/generated/oas-output/schemas/AdminRuleAttributeOption.ts @@ -7,25 +7,23 @@ * - id * - value * - label - * - field_type - * - required * - operators * properties: * id: * type: string * title: id * description: The rule attribute's ID, which is a rule's `attribute` it refers to. - * example: "customer_group" + * example: customer_group * value: * type: string * title: value * description: The rule attribute's value. - * example: "customer.groups.id" + * example: customer.groups.id * label: * type: string * title: label * description: The rule attribute option's label. - * example: "Customer Group" + * example: Customer Group * operators: * type: array * description: The attribute's operators. diff --git a/www/utils/generated/oas-output/schemas/AdminRuleValueOption.ts b/www/utils/generated/oas-output/schemas/AdminRuleValueOption.ts index f53655235c5e8..cf5f1f0c33d6e 100644 --- a/www/utils/generated/oas-output/schemas/AdminRuleValueOption.ts +++ b/www/utils/generated/oas-output/schemas/AdminRuleValueOption.ts @@ -11,12 +11,12 @@ * type: string * title: value * description: The rule value's value. - * example: "reg_123" + * example: reg_123 * label: * type: string * title: label * description: The rule value's label. - * example: "Europe Region" + * example: Europe Region * */ diff --git a/www/utils/generated/oas-output/schemas/AdminServiceZoneDeleteResponse.ts b/www/utils/generated/oas-output/schemas/AdminServiceZoneDeleteResponse.ts index 87c44fe313677..8c8952f4f979f 100644 --- a/www/utils/generated/oas-output/schemas/AdminServiceZoneDeleteResponse.ts +++ b/www/utils/generated/oas-output/schemas/AdminServiceZoneDeleteResponse.ts @@ -16,7 +16,7 @@ * type: string * title: object * description: The name of the deleted object. - * default: "service_zone" + * default: service_zone * deleted: * type: boolean * title: deleted diff --git a/www/utils/generated/oas-output/schemas/AdminShippingOption.ts b/www/utils/generated/oas-output/schemas/AdminShippingOption.ts index 89f600fe5d580..b5344490401cb 100644 --- a/www/utils/generated/oas-output/schemas/AdminShippingOption.ts +++ b/www/utils/generated/oas-output/schemas/AdminShippingOption.ts @@ -33,7 +33,8 @@ * description: The shipping option's name. * price_type: * type: string - * description: The shipping option's price type. If it's `flat`, the price is fixed and is set in the `prices` property. If it's `calculated`, the price is calculated on checkout by the associated fulfillment provider. + * description: The shipping option's price type. If it's `flat`, the price is fixed and is set in the `prices` property. If it's `calculated`, the price is calculated on checkout by the associated + * fulfillment provider. * enum: * - calculated * - flat diff --git a/www/utils/generated/oas-output/schemas/AdminStockLocation.ts b/www/utils/generated/oas-output/schemas/AdminStockLocation.ts index 7503b706e8a24..ba826331ec0a7 100644 --- a/www/utils/generated/oas-output/schemas/AdminStockLocation.ts +++ b/www/utils/generated/oas-output/schemas/AdminStockLocation.ts @@ -21,7 +21,57 @@ * title: address_id * description: The ID of the associated address. * address: - * $ref: "#/components/schemas/AdminStockLocationAddress" + * type: object + * description: The details of the stock location address. + * x-schemaName: AdminStockLocationAddress + * properties: + * id: + * type: string + * title: id + * description: The address's ID. + * address_1: + * type: string + * title: address_1 + * description: The address's first line. + * address_2: + * type: string + * title: address_2 + * description: The address's second line. + * company: + * type: string + * title: company + * description: The address's company. + * country_code: + * type: string + * title: country_code + * description: The address's country code. + * example: us + * city: + * type: string + * title: city + * description: The address's city. + * phone: + * type: string + * title: phone + * description: The address's phone. + * postal_code: + * type: string + * title: postal_code + * description: The address's postal code. + * province: + * type: string + * title: province + * description: The address's province. + * required: + * - id + * - address_1 + * - address_2 + * - company + * - country_code + * - city + * - phone + * - postal_code + * - province * sales_channels: * type: array * description: The sales channels associated with the location. diff --git a/www/utils/generated/oas-output/schemas/AdminStockLocationAddress.ts b/www/utils/generated/oas-output/schemas/AdminStockLocationAddress.ts deleted file mode 100644 index 4917c534eb64b..0000000000000 --- a/www/utils/generated/oas-output/schemas/AdminStockLocationAddress.ts +++ /dev/null @@ -1,56 +0,0 @@ -/** - * @schema AdminStockLocationAddress - * type: object - * description: The details of the stock location address. - * x-schemaName: AdminStockLocationAddress - * properties: - * id: - * type: string - * title: id - * description: The address's ID. - * address_1: - * type: string - * title: address_1 - * description: The address's first line. - * address_2: - * type: string - * title: address_2 - * description: The address's second line. - * company: - * type: string - * title: company - * description: The address's company. - * country_code: - * type: string - * title: country_code - * description: The address's country code. - * example: us - * city: - * type: string - * title: city - * description: The address's city. - * phone: - * type: string - * title: phone - * description: The address's phone. - * postal_code: - * type: string - * title: postal_code - * description: The address's postal code. - * province: - * type: string - * title: province - * description: The address's province. - * required: - * - id - * - address_1 - * - address_2 - * - company - * - country_code - * - city - * - phone - * - postal_code - * - province - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/AdminUpdatePriceList.ts b/www/utils/generated/oas-output/schemas/AdminUpdatePriceList.ts index 181682c03fef6..4a53ba8dd9dee 100644 --- a/www/utils/generated/oas-output/schemas/AdminUpdatePriceList.ts +++ b/www/utils/generated/oas-output/schemas/AdminUpdatePriceList.ts @@ -21,22 +21,33 @@ * title: ends_at * description: The date the price list ends. * status: - * type: string + * oneOf: + * - type: string + * description: The price list's status. + * enum: + * - ACTIVE + * - type: string + * description: The price list's status. + * enum: + * - DRAFT * description: The price list's status. - * enum: - * - active - * - draft * type: - * type: string + * oneOf: + * - type: string + * description: The price list's type. + * enum: + * - SALE + * - type: string + * description: The price list's type. + * enum: + * - OVERRIDE * description: The price list's type. - * enum: - * - sale - * - override * rules: * type: object * description: The price list's rules. * example: * customer_group_id: - * - "cusgrp_123" + * - cusgrp_123 + * */ diff --git a/www/utils/generated/oas-output/schemas/AdminUpdateProduct.ts b/www/utils/generated/oas-output/schemas/AdminUpdateProduct.ts index 0d0a012865383..b4c054eb82308 100644 --- a/www/utils/generated/oas-output/schemas/AdminUpdateProduct.ts +++ b/www/utils/generated/oas-output/schemas/AdminUpdateProduct.ts @@ -46,13 +46,20 @@ * title: handle * description: The product's unique handle. * status: - * type: string + * oneOf: + * - type: string + * title: status + * description: The update's status. + * - type: string + * title: status + * description: The update's status. + * - type: string + * title: status + * description: The update's status. + * - type: string + * title: status + * description: The update's status. * description: The product's status. - * enum: - * - draft - * - proposed - * - published - * - rejected * type_id: * type: string * title: type_id diff --git a/www/utils/generated/oas-output/schemas/UpdateOrderReturnReason.ts b/www/utils/generated/oas-output/schemas/AdminUpdateReturnReason.ts similarity index 76% rename from www/utils/generated/oas-output/schemas/UpdateOrderReturnReason.ts rename to www/utils/generated/oas-output/schemas/AdminUpdateReturnReason.ts index 77d26eaea83d2..3508ad4ee8191 100644 --- a/www/utils/generated/oas-output/schemas/UpdateOrderReturnReason.ts +++ b/www/utils/generated/oas-output/schemas/AdminUpdateReturnReason.ts @@ -1,13 +1,9 @@ /** - * @schema UpdateOrderReturnReason + * @schema AdminUpdateReturnReason * type: object * description: The details to update in a return reason. - * x-schemaName: UpdateOrderReturnReason + * x-schemaName: AdminUpdateReturnReason * properties: - * id: - * type: string - * title: id - * description: The return reason's ID. * label: * type: string * title: label @@ -23,6 +19,9 @@ * metadata: * type: object * description: The return reason's metadata, can hold custom key-value pairs. + * required: + * - value + * - label * */ diff --git a/www/utils/generated/oas-output/schemas/AdminUpdateVariantInventoryItem.ts b/www/utils/generated/oas-output/schemas/AdminUpdateVariantInventoryItem.ts index 49bc83bd04307..c8d886461949d 100644 --- a/www/utils/generated/oas-output/schemas/AdminUpdateVariantInventoryItem.ts +++ b/www/utils/generated/oas-output/schemas/AdminUpdateVariantInventoryItem.ts @@ -9,7 +9,8 @@ * required_quantity: * type: number * title: required_quantity - * description: The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the value set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`. + * description: The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the + * value set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseApplicationMethod.ts b/www/utils/generated/oas-output/schemas/BaseApplicationMethod.ts deleted file mode 100644 index 97fb5e99eef83..0000000000000 --- a/www/utils/generated/oas-output/schemas/BaseApplicationMethod.ts +++ /dev/null @@ -1,67 +0,0 @@ -/** - * @schema BaseApplicationMethod - * type: object - * description: The application method's details. - * x-schemaName: BaseApplicationMethod - * required: - * - id - * properties: - * id: - * type: string - * title: id - * description: The application method's ID. - * type: - * type: string - * description: How the associated promotion is applied. `fixed` means a fixed amount is discounted; `percentage` means a percentage of the original amount is discounted. - * enum: - * - fixed - * - percentage - * target_type: - * type: string - * description: Which item does the promotion apply to. `items` mean the promotion applies to the cart's items; `shipping_methods` means the promotion applies to the cart's shipping methods; `order` means the promotion applies on the entire order. - * enum: - * - items - * - shipping_methods - * - order - * allocation: - * type: string - * description: How is the promotion amount discounted. `each` means the discounted amount is applied on each applicable item; `across` means the discounted amount is split accross the applicable items. - * enum: - * - each - * - across - * value: - * type: number - * title: value - * description: The amount to be discounted. - * currency_code: - * type: string - * title: currency_code - * description: The application method's currency code. - * example: usd - * max_quantity: - * type: number - * title: max_quantity - * description: The max quantity allowed in the cart for the associated promotion to be applied. - * buy_rules_min_quantity: - * type: number - * title: buy_rules_min_quantity - * description: The minimum quantity required for a `buyget` promotion to be applied. For example, if the promotion is a "Buy 2 shirts get 1 free", the value of this attribute is `2`. - * apply_to_quantity: - * type: number - * title: apply_to_quantity - * description: The quantity that results from matching the `buyget` promotion's condition. For example, if the promotion is a "Buy 2 shirts get 1 free", the value of this attribute is `1`. - * promotion: - * $ref: "#/components/schemas/BasePromotion" - * target_rules: - * type: array - * description: The application method's target rules. These rules indicate which items / shipping methods the promotion applies to. - * items: - * $ref: "#/components/schemas/BasePromotionRule" - * buy_rules: - * type: array - * description: The application method's buy rules. These rules indicate which items are part of the "Buy X" rule. - * items: - * $ref: "#/components/schemas/BasePromotionRule" - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/BaseCalculatedPriceSet.ts b/www/utils/generated/oas-output/schemas/BaseCalculatedPriceSet.ts index 9e5fa413ef780..f6d145bb03fbc 100644 --- a/www/utils/generated/oas-output/schemas/BaseCalculatedPriceSet.ts +++ b/www/utils/generated/oas-output/schemas/BaseCalculatedPriceSet.ts @@ -52,9 +52,63 @@ * calculated_price: * type: object * description: The calculated price's details. + * properties: + * id: + * type: string + * title: id + * description: The calculated price's ID. + * price_list_id: + * type: string + * title: price_list_id + * description: The calculated price's price list id. + * price_list_type: + * type: string + * title: price_list_type + * description: The calculated price's price list type. + * min_quantity: + * type: number + * title: min_quantity + * description: The calculated price's min quantity. + * max_quantity: + * type: number + * title: max_quantity + * description: The calculated price's max quantity. + * required: + * - id + * - price_list_id + * - price_list_type + * - min_quantity + * - max_quantity * original_price: * type: object * description: The calculated price's original price. + * properties: + * id: + * type: string + * title: id + * description: The original price's ID. + * price_list_id: + * type: string + * title: price_list_id + * description: The original price's price list id. + * price_list_type: + * type: string + * title: price_list_type + * description: The original price's price list type. + * min_quantity: + * type: number + * title: min_quantity + * description: The original price's min quantity. + * max_quantity: + * type: number + * title: max_quantity + * description: The original price's max quantity. + * required: + * - id + * - price_list_id + * - price_list_type + * - min_quantity + * - max_quantity * */ diff --git a/www/utils/generated/oas-output/schemas/BaseCartShippingMethod.ts b/www/utils/generated/oas-output/schemas/BaseCartShippingMethod.ts index b403f0dabdfec..0f843c5c81750 100644 --- a/www/utils/generated/oas-output/schemas/BaseCartShippingMethod.ts +++ b/www/utils/generated/oas-output/schemas/BaseCartShippingMethod.ts @@ -77,36 +77,36 @@ * title: updated_at * description: The date the shipping method was updated. * original_total: - * type: string + * type: number * title: original_total * description: The shipping method's total including taxes, excluding promotions. * original_subtotal: - * type: string + * type: number * title: original_subtotal * description: The shipping method's total excluding taxes, including promotions. * original_tax_total: - * type: string + * type: number * title: original_tax_total * description: The total taxes applied on the shipping method's amount including promotions. * total: - * type: string + * type: number * title: total * description: The shipping method's total amount including taxes and promotions. * subtotal: - * type: string + * type: number * title: subtotal * description: The shipping method's total amount excluding taxes, including promotions. * tax_total: - * type: string + * type: number * title: tax_total * description: The total taxes applied on the shipping method's amount including promotions. * discount_total: - * type: string + * type: number * title: discount_total * description: The total amount discounted. * discount_tax_total: - * type: string - * title: discount_total + * type: number + * title: discount_tax_total * description: The taxes applied on the discounted amount. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseClaim.ts b/www/utils/generated/oas-output/schemas/BaseClaim.ts deleted file mode 100644 index 243d9d56b583d..0000000000000 --- a/www/utils/generated/oas-output/schemas/BaseClaim.ts +++ /dev/null @@ -1,103 +0,0 @@ -/** - * @schema BaseClaim - * type: object - * description: The claim's details. - * x-schemaName: BaseClaim - * required: - * - id - * - type - * - order_id - * - display_id - * - order_version - * - created_at - * - updated_at - * - canceled_at - * - additional_items - * - claim_items - * properties: - * id: - * type: string - * title: id - * description: The claim's ID. - * type: - * type: string - * description: The claim's type. If `refund`, the customer is refunded for the damaged item. If `replace`, new items are sent to the customer. - * enum: - * - refund - * - replace - * order_id: - * type: string - * title: order_id - * description: The ID of the order the claim is created for. - * return_id: - * type: string - * title: return_id - * description: The ID of the returned used to return the items from the customer. - * display_id: - * type: string - * title: display_id - * description: The claim's display ID. - * order_version: - * type: string - * title: order_version - * description: The version of the order when the claim is applied. - * refund_amount: - * type: number - * title: refund_amount - * description: The amount to be refunded. - * created_by: - * type: string - * title: created_by - * description: The ID of the user that created the claim. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The date the claim was created. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The date the claim was updated. - * canceled_at: - * type: string - * format: date-time - * title: updated_at - * description: The date the claim was canceled. - * deleted_at: - * type: string - * format: date-time - * title: deleted_at - * description: The date the claim was deleted. - * additional_items: - * type: array - * description: The items sent to the customer if the claim's type is `replace`. - * items: - * $ref: "#/components/schemas/BaseClaimItem" - * claim_items: - * type: array - * description: The claim items from the original order. - * items: - * $ref: "#/components/schemas/BaseClaimItem" - * no_notification: - * type: boolean - * title: no_notification - * description: Whether to send the customer notifications on the claim's updates. - * order: - * $ref: "#/components/schemas/BaseOrder" - * shipping_methods: - * type: array - * description: The claim's shipping methods, used to send the new items. - * items: - * $ref: "#/components/schemas/BaseOrderShippingMethod" - * transactions: - * type: array - * description: The claim's transactions, such as the refunds made. - * items: - * $ref: "#/components/schemas/BaseOrderTransaction" - * metadata: - * type: object - * description: The claim's metadata, can hold custom key-value pairs. - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/BaseClaimItem.ts b/www/utils/generated/oas-output/schemas/BaseClaimItem.ts index 468a4e9075477..60bf42e179610 100644 --- a/www/utils/generated/oas-output/schemas/BaseClaimItem.ts +++ b/www/utils/generated/oas-output/schemas/BaseClaimItem.ts @@ -43,6 +43,17 @@ * raw_quantity: * type: object * description: The quantity claimed. + * properties: + * value: + * oneOf: + * - type: string + * title: value + * description: The raw quantity's value. + * - type: number + * title: value + * description: The raw quantity's value. + * required: + * - value * metadata: * type: object * description: The item's metadata, can hold custom key-value pairs. diff --git a/www/utils/generated/oas-output/schemas/BaseCollection.ts b/www/utils/generated/oas-output/schemas/BaseCollection.ts index 55999b772b55e..1d074d9ba92ee 100644 --- a/www/utils/generated/oas-output/schemas/BaseCollection.ts +++ b/www/utils/generated/oas-output/schemas/BaseCollection.ts @@ -3,50 +3,6 @@ * type: object * description: The collection's details. * x-schemaName: BaseCollection - * required: - * - id - * - title - * - handle - * - created_at - * - updated_at - * - deleted_at - * - metadata - * properties: - * id: - * type: string - * title: id - * description: The collection's ID. - * title: - * type: string - * title: title - * description: The collection's title. - * handle: - * type: string - * title: handle - * description: The collection's handle. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The date the collection is created. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The date the collection is updated. - * deleted_at: - * type: string - * format: date-time - * title: deleted_at - * description: The date the collection is deleted. - * products: - * type: array - * description: The collection's products. - * items: - * $ref: "#/components/schemas/AdminProduct" - * metadata: - * type: object - * description: The collection's metadata, can hold custom key-value pairs. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseCustomer.ts b/www/utils/generated/oas-output/schemas/BaseCustomer.ts new file mode 100644 index 0000000000000..70f759194b1eb --- /dev/null +++ b/www/utils/generated/oas-output/schemas/BaseCustomer.ts @@ -0,0 +1,78 @@ +/** + * @schema BaseCustomer + * type: object + * description: The customer's details. + * x-schemaName: BaseCustomer + * required: + * - id + * - email + * - default_billing_address_id + * - default_shipping_address_id + * - company_name + * - first_name + * - last_name + * - addresses + * properties: + * id: + * type: string + * title: id + * description: The customer's ID. + * email: + * type: string + * title: email + * description: The customer's email. + * format: email + * default_billing_address_id: + * type: string + * title: default_billing_address_id + * description: The ID of the address used as the default billing address. + * default_shipping_address_id: + * type: string + * title: default_shipping_address_id + * description: The ID of the address used as the default shipping address. + * company_name: + * type: string + * title: company_name + * description: The customer's company name. + * first_name: + * type: string + * title: first_name + * description: The customer's first name. + * last_name: + * type: string + * title: last_name + * description: The customer's last name. + * addresses: + * type: array + * description: The customer's addresses. + * items: + * $ref: "#/components/schemas/BaseCustomerAddress" + * phone: + * type: string + * title: phone + * description: The customer's phone. + * metadata: + * type: object + * description: The customer's metadata, used to store custom key-value pairs. + * created_by: + * type: string + * title: created_by + * description: The ID of the user that created this customer, if available. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The customer's creation date. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The customer's update date. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The customer's deletion date. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/BaseCustomerAddress.ts b/www/utils/generated/oas-output/schemas/BaseCustomerAddress.ts new file mode 100644 index 0000000000000..953edf7e19348 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/BaseCustomerAddress.ts @@ -0,0 +1,102 @@ +/** + * @schema BaseCustomerAddress + * type: object + * description: The customer's address. + * x-schemaName: BaseCustomerAddress + * required: + * - id + * - address_name + * - is_default_shipping + * - is_default_billing + * - customer_id + * - company + * - first_name + * - last_name + * - address_1 + * - address_2 + * - city + * - country_code + * - province + * - postal_code + * - phone + * - metadata + * - created_at + * - updated_at + * properties: + * id: + * type: string + * title: id + * description: The address's ID. + * address_name: + * type: string + * title: address_name + * description: The address's name. + * is_default_shipping: + * type: boolean + * title: is_default_shipping + * description: Whether the address is the default shipping address. + * is_default_billing: + * type: boolean + * title: is_default_billing + * description: Whether the address is the default billing address. + * customer_id: + * type: string + * title: customer_id + * description: The ID of the customer that this address belongs to. + * company: + * type: string + * title: company + * description: The customer's company. + * first_name: + * type: string + * title: first_name + * description: The customer's first name. + * last_name: + * type: string + * title: last_name + * description: The customer's last name. + * address_1: + * type: string + * title: address_1 + * description: The address's first line. + * address_2: + * type: string + * title: address_2 + * description: The address's second line. + * city: + * type: string + * title: city + * description: The address's city. + * country_code: + * type: string + * title: country_code + * description: The address's country code. + * example: us + * province: + * type: string + * title: province + * description: The address's province. + * postal_code: + * type: string + * title: postal_code + * description: The address's postal code. + * phone: + * type: string + * title: phone + * description: The address's phone. + * metadata: + * type: object + * description: The address's metadata, used to store custom key-value pairs. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The address's creation date. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The address's update date. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/BaseFulfillmentProvider.ts b/www/utils/generated/oas-output/schemas/BaseFulfillmentProvider.ts deleted file mode 100644 index ea0e7972f0076..0000000000000 --- a/www/utils/generated/oas-output/schemas/BaseFulfillmentProvider.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * @schema BaseFulfillmentProvider - * type: object - * description: The fulfillment provider's details. - * x-schemaName: BaseFulfillmentProvider - * required: - * - id - * - is_enabled - * properties: - * id: - * type: string - * title: id - * description: The provider's ID. - * is_enabled: - * type: boolean - * title: is_enabled - * description: Whether the provider is enabled. - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/BaseOrderChange.ts b/www/utils/generated/oas-output/schemas/BaseOrderChange.ts deleted file mode 100644 index 5453a675b178a..0000000000000 --- a/www/utils/generated/oas-output/schemas/BaseOrderChange.ts +++ /dev/null @@ -1,154 +0,0 @@ -/** - * @schema BaseOrderChange - * type: object - * description: The order preview's order change. - * x-schemaName: BaseOrderChange - * required: - * - order - * - claim - * - return - * - exchange - * - id - * - version - * - order_id - * - return_id - * - exchange_id - * - claim_id - * - return_order - * - actions - * - status - * - requested_by - * - requested_at - * - confirmed_by - * - confirmed_at - * - declined_by - * - declined_reason - * - metadata - * - declined_at - * - canceled_by - * - canceled_at - * - created_at - * - updated_at - * properties: - * id: - * type: string - * title: id - * description: The order change's ID. - * order_id: - * type: string - * title: order_id - * description: The order change's order id. - * actions: - * type: array - * description: The order change's actions. - * items: - * $ref: "#/components/schemas/BaseOrderChangeAction" - * status: - * type: string - * title: status - * description: The order change's status. - * requested_by: - * type: string - * title: requested_by - * description: The order change's requested by. - * requested_at: - * oneOf: - * - type: string - * title: requested_at - * description: The order change's requested at. - * - type: string - * title: requested_at - * description: The order change's requested at. - * format: date-time - * confirmed_by: - * type: string - * title: confirmed_by - * description: The order change's confirmed by. - * confirmed_at: - * oneOf: - * - type: string - * title: confirmed_at - * description: The order change's confirmed at. - * - type: string - * title: confirmed_at - * description: The order change's confirmed at. - * format: date-time - * declined_by: - * type: string - * title: declined_by - * description: The order change's declined by. - * declined_reason: - * type: string - * title: declined_reason - * description: The order change's declined reason. - * metadata: - * type: object - * description: The order change's metadata. - * declined_at: - * oneOf: - * - type: string - * title: declined_at - * description: The order change's declined at. - * - type: string - * title: declined_at - * description: The order change's declined at. - * format: date-time - * canceled_by: - * type: string - * title: canceled_by - * description: The order change's canceled by. - * canceled_at: - * oneOf: - * - type: string - * title: canceled_at - * description: The order change's canceled at. - * - type: string - * title: canceled_at - * description: The order change's canceled at. - * format: date-time - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The order change's created at. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The order change's updated at. - * version: - * type: number - * title: version - * description: The order change's version. - * change_type: - * type: string - * description: The order change's change type. - * enum: - * - return - * - exchange - * - claim - * - edit - * - return_request - * return_id: - * type: string - * title: return_id - * description: The order change's return id. - * exchange_id: - * type: string - * title: exchange_id - * description: The order change's exchange id. - * claim_id: - * type: string - * title: claim_id - * description: The order change's claim id. - * order: - * $ref: "#/components/schemas/AdminOrder" - * return_order: - * $ref: "#/components/schemas/AdminReturn" - * exchange: - * $ref: "#/components/schemas/AdminExchange" - * claim: - * $ref: "#/components/schemas/AdminClaim" - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/BaseOrderItemDetail.ts b/www/utils/generated/oas-output/schemas/BaseOrderItemDetail.ts index b9eb897f523c1..da43f1307d358 100644 --- a/www/utils/generated/oas-output/schemas/BaseOrderItemDetail.ts +++ b/www/utils/generated/oas-output/schemas/BaseOrderItemDetail.ts @@ -6,6 +6,7 @@ * required: * - id * - item_id + * - item * - quantity * - fulfilled_quantity * - delivered_quantity @@ -27,7 +28,7 @@ * title: id * description: the ID of the associated line item. * item: - * $ref: "#/components/schemas/AdminOrderLineItem" + * $ref: "#/components/schemas/BaseOrderLineItem" * quantity: * type: number * title: quantity @@ -74,5 +75,6 @@ * format: date-time * title: updated_at * description: The date the detail was updated. + * */ diff --git a/www/utils/generated/oas-output/schemas/BaseOrderLineItem.ts b/www/utils/generated/oas-output/schemas/BaseOrderLineItem.ts index 34b103c121241..c7461bb28b27b 100644 --- a/www/utils/generated/oas-output/schemas/BaseOrderLineItem.ts +++ b/www/utils/generated/oas-output/schemas/BaseOrderLineItem.ts @@ -60,7 +60,7 @@ * title: thumbnail * description: The URL of the item's thumbnail. * variant: - * $ref: "#/components/schemas/AdminProductVariant" + * $ref: "#/components/schemas/BaseProductVariant" * variant_id: * type: string * title: variant_id @@ -215,3 +215,4 @@ * description: The total refundable amount of the item's total for a single quantity. * */ + diff --git a/www/utils/generated/oas-output/schemas/BaseOrderShippingDetail.ts b/www/utils/generated/oas-output/schemas/BaseOrderShippingDetail.ts index 1f1c779e7237c..61c14ac4b6aa1 100644 --- a/www/utils/generated/oas-output/schemas/BaseOrderShippingDetail.ts +++ b/www/utils/generated/oas-output/schemas/BaseOrderShippingDetail.ts @@ -1,50 +1,47 @@ /** * @schema BaseOrderShippingDetail * type: object - * description: Details of changes to a shipping method. + * description: The shipping method's detail. * x-schemaName: BaseOrderShippingDetail * required: * - id * - shipping_method_id * - shipping_method - * - claim_id - * - exchange_id - * - return_id * - created_at * - updated_at * properties: * id: * type: string * title: id - * description: The ID of the new changes to the shipping method. + * description: The detail's ID. * shipping_method_id: * type: string * title: shipping_method_id - * description: The ID of the shipping method. + * description: The detail's shipping method id. * shipping_method: * $ref: "#/components/schemas/BaseOrderShippingMethod" * claim_id: * type: string * title: claim_id - * description: The ID of the associated claim. + * description: The detail's claim id. * exchange_id: * type: string * title: exchange_id - * description: The ID of the associated exchange. + * description: The detail's exchange id. * return_id: * type: string * title: return_id - * description: The ID of the associated return. + * description: The detail's return id. * created_at: * type: string * format: date-time * title: created_at - * description: The date the shipping method change was created. + * description: The detail's created at. * updated_at: * type: string * format: date-time * title: updated_at - * description: The date the shipping method change was updated. + * description: The detail's updated at. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseOrderShippingMethod.ts b/www/utils/generated/oas-output/schemas/BaseOrderShippingMethod.ts index 0993279f6cb26..3a1bf9dde79e7 100644 --- a/www/utils/generated/oas-output/schemas/BaseOrderShippingMethod.ts +++ b/www/utils/generated/oas-output/schemas/BaseOrderShippingMethod.ts @@ -111,6 +111,8 @@ * format: date-time * title: updated_at * description: The date the shipping method was updated. + * detail: + * $ref: "#/components/schemas/BaseOrderShippingDetail" * */ diff --git a/www/utils/generated/oas-output/schemas/BaseOrderSummary.ts b/www/utils/generated/oas-output/schemas/BaseOrderSummary.ts index 0055fdc59c36d..9460124a33468 100644 --- a/www/utils/generated/oas-output/schemas/BaseOrderSummary.ts +++ b/www/utils/generated/oas-output/schemas/BaseOrderSummary.ts @@ -12,11 +12,6 @@ * - returned_total * - return_request_total * - write_off_total - * - projected_total - * - net_total - * - net_subtotal - * - net_total_tax - * - balance * - paid_total * - refunded_total * properties: @@ -52,26 +47,6 @@ * type: number * title: write_off_total * description: The total of the items removed from the order. - * projected_total: - * type: number - * title: projected_total - * description: The summary's projected total. - * net_total: - * type: number - * title: net_total - * description: The summary's net total. - * net_subtotal: - * type: number - * title: net_subtotal - * description: The summary's net subtotal. - * net_total_tax: - * type: number - * title: net_total_tax - * description: The summary's net total tax. - * balance: - * type: number - * title: balance - * description: The summary's balance. * paid_total: * type: number * title: paid_total diff --git a/www/utils/generated/oas-output/schemas/BasePaymentProvider.ts b/www/utils/generated/oas-output/schemas/BasePaymentProvider.ts index eb5794eb81f03..043b869198bce 100644 --- a/www/utils/generated/oas-output/schemas/BasePaymentProvider.ts +++ b/www/utils/generated/oas-output/schemas/BasePaymentProvider.ts @@ -4,17 +4,12 @@ * description: The payment provider's payment providers. * x-schemaName: BasePaymentProvider * required: - * - is_enabled * - id * properties: * id: * type: string * title: id * description: The payment provider's ID. - * is_enabled: - * type: boolean - * title: is_enabled - * description: Whether the payment provider is enabled. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseProductOptionValue.ts b/www/utils/generated/oas-output/schemas/BaseProductOptionValue.ts index af37e68f433b6..a7dbcad8e3ced 100644 --- a/www/utils/generated/oas-output/schemas/BaseProductOptionValue.ts +++ b/www/utils/generated/oas-output/schemas/BaseProductOptionValue.ts @@ -3,42 +3,6 @@ * type: object * description: The product option value's details. * x-schemaName: BaseProductOptionValue - * required: - * - id - * - value - * properties: - * id: - * type: string - * title: id - * description: The value's ID. - * value: - * type: string - * title: value - * description: The value. - * option: - * $ref: "#/components/schemas/BaseProductOption" - * option_id: - * type: string - * title: option_id - * description: The ID of the option this value belongs to. - * metadata: - * type: object - * description: The value's metadata, can hold custom key-value pairs. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The date the value was created. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The date the value was updated. - * deleted_at: - * type: string - * format: date-time - * title: deleted_at - * description: The date the value was deleted. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseProductVariant.ts b/www/utils/generated/oas-output/schemas/BaseProductVariant.ts index 4c7c81fccc718..88bdc45e64848 100644 --- a/www/utils/generated/oas-output/schemas/BaseProductVariant.ts +++ b/www/utils/generated/oas-output/schemas/BaseProductVariant.ts @@ -1,8 +1,133 @@ /** * @schema BaseProductVariant * type: object - * description: The variant's variants. + * description: The product variant's details. * x-schemaName: BaseProductVariant + * required: + * - id + * - title + * - sku + * - barcode + * - ean + * - upc + * - allow_backorder + * - manage_inventory + * - hs_code + * - origin_country + * - mid_code + * - material + * - weight + * - length + * - height + * - width + * - options + * - created_at + * - updated_at + * - deleted_at + * properties: + * id: + * type: string + * title: id + * description: The variant's ID. + * title: + * type: string + * title: title + * description: The variant's title. + * sku: + * type: string + * title: sku + * description: The variant's SKU. + * barcode: + * type: string + * title: barcode + * description: The variant's barcode. + * ean: + * type: string + * title: ean + * description: The variant's EAN code. + * upc: + * type: string + * title: upc + * description: The variant's UPC. + * allow_backorder: + * type: boolean + * title: allow_backorder + * description: Whether the variant can be ordered even if it's out of stock. + * manage_inventory: + * type: boolean + * title: manage_inventory + * description: Whether the Medusa application manages the variant's inventory quantity and availablility. If disabled, the variant is always considered in stock. + * inventory_quantity: + * type: number + * title: inventory_quantity + * description: The variant's inventory quantity. This is only included if you pass in the `fields` query parameter a `+variants.inventory_quantity` parameter. + * hs_code: + * type: string + * title: hs_code + * description: The variant's HS code. + * origin_country: + * type: string + * title: origin_country + * description: The variant's origin country. + * mid_code: + * type: string + * title: mid_code + * description: The variant's MID code. + * material: + * type: string + * title: material + * description: The variant's material. + * weight: + * type: number + * title: weight + * description: The variant's weight. + * length: + * type: number + * title: length + * description: The variant's length. + * height: + * type: number + * title: height + * description: The variant's height. + * width: + * type: number + * title: width + * description: The variant's width. + * variant_rank: + * type: number + * title: variant_rank + * description: The variant's rank among its sibling variants. + * options: + * type: array + * description: The variant's option values. + * items: + * $ref: "#/components/schemas/BaseProductOptionValue" + * product: + * $ref: "#/components/schemas/BaseProduct" + * product_id: + * type: string + * title: product_id + * description: The ID of the product that the variant belongs to. + * calculated_price: + * $ref: "#/components/schemas/BaseCalculatedPriceSet" + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The date the variant was created. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The date the variant was updated. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The date the variant was deleted. + * metadata: + * type: object + * description: The variant's metadata, can hold custom key-value pairs. * */ diff --git a/www/utils/generated/oas-output/schemas/BasePromotionRuleValue.ts b/www/utils/generated/oas-output/schemas/BasePromotionRuleValue.ts index de152bfb546bd..02086a90a8236 100644 --- a/www/utils/generated/oas-output/schemas/BasePromotionRuleValue.ts +++ b/www/utils/generated/oas-output/schemas/BasePromotionRuleValue.ts @@ -1,7 +1,7 @@ /** * @schema BasePromotionRuleValue * type: object - * description: The rule value's details. + * description: The value's values. * x-schemaName: BasePromotionRuleValue * required: * - id @@ -13,7 +13,7 @@ * value: * type: string * title: value - * description: The value. + * description: The value's details. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseRefund.ts b/www/utils/generated/oas-output/schemas/BaseRefund.ts index 3e259a6f33189..9a03e337d4498 100644 --- a/www/utils/generated/oas-output/schemas/BaseRefund.ts +++ b/www/utils/generated/oas-output/schemas/BaseRefund.ts @@ -36,6 +36,8 @@ * description: The ID of the user that created the refund. * payment: * $ref: "#/components/schemas/BasePayment" + * refund_reason: + * $ref: "#/components/schemas/RefundReason" * */ diff --git a/www/utils/generated/oas-output/schemas/BaseRegion.ts b/www/utils/generated/oas-output/schemas/BaseRegion.ts index de59008442ba7..d708357635896 100644 --- a/www/utils/generated/oas-output/schemas/BaseRegion.ts +++ b/www/utils/generated/oas-output/schemas/BaseRegion.ts @@ -3,50 +3,6 @@ * type: object * description: The parent's region. * x-schemaName: BaseRegion - * required: - * - id - * - name - * - currency_code - * properties: - * id: - * type: string - * title: id - * description: The region's ID. - * name: - * type: string - * title: name - * description: The region's name. - * currency_code: - * type: string - * title: currency_code - * description: The region's currency code. - * automatic_taxes: - * type: boolean - * title: automatic_taxes - * description: The region's automatic taxes. - * countries: - * type: array - * description: The region's countries. - * items: - * $ref: "#/components/schemas/BaseRegionCountry" - * payment_providers: - * type: array - * description: The region's payment providers. - * items: - * $ref: "#/components/schemas/AdminPaymentProvider" - * metadata: - * type: object - * description: The region's metadata. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The region's created at. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The region's updated at. * */ diff --git a/www/utils/generated/oas-output/schemas/BaseReturnItem.ts b/www/utils/generated/oas-output/schemas/BaseReturnItem.ts deleted file mode 100644 index 9e0b07e3fd8fb..0000000000000 --- a/www/utils/generated/oas-output/schemas/BaseReturnItem.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * @schema BaseReturnItem - * type: object - * description: The item's items. - * x-schemaName: BaseReturnItem - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/BaseRuleOperatorOptions.ts b/www/utils/generated/oas-output/schemas/BaseRuleOperatorOptions.ts index bb039e1c7af9c..2a1a56a9ebda4 100644 --- a/www/utils/generated/oas-output/schemas/BaseRuleOperatorOptions.ts +++ b/www/utils/generated/oas-output/schemas/BaseRuleOperatorOptions.ts @@ -12,17 +12,17 @@ * type: string * title: id * description: The operator's ID. - * example: "in" + * example: in * value: * type: string * title: value * description: The operator's value. - * example: "in" + * example: in * label: * type: string * title: label * description: The operator's label. - * example: "In" + * example: In * */ diff --git a/www/utils/generated/oas-output/schemas/OrderPreview.ts b/www/utils/generated/oas-output/schemas/OrderPreview.ts deleted file mode 100644 index 688e53ab922cf..0000000000000 --- a/www/utils/generated/oas-output/schemas/OrderPreview.ts +++ /dev/null @@ -1,1555 +0,0 @@ -/** - * @schema OrderPreview - * type: object - * description: The order edit's order preview. - * x-schemaName: OrderPreview - * required: - * - order_change - * - status - * - currency_code - * - version - * - id - * - original_item_total - * - original_item_subtotal - * - original_item_tax_total - * - item_total - * - item_subtotal - * - item_tax_total - * - original_total - * - original_subtotal - * - original_tax_total - * - total - * - subtotal - * - tax_total - * - discount_total - * - discount_tax_total - * - gift_card_total - * - gift_card_tax_total - * - shipping_total - * - shipping_subtotal - * - shipping_tax_total - * - original_shipping_total - * - original_shipping_subtotal - * - original_shipping_tax_total - * - raw_original_item_total - * - raw_original_item_subtotal - * - raw_original_item_tax_total - * - raw_item_total - * - raw_item_subtotal - * - raw_item_tax_total - * - raw_original_total - * - raw_original_subtotal - * - raw_original_tax_total - * - raw_total - * - raw_subtotal - * - raw_tax_total - * - raw_discount_total - * - raw_discount_tax_total - * - raw_gift_card_total - * - raw_gift_card_tax_total - * - raw_shipping_total - * - raw_shipping_subtotal - * - raw_shipping_tax_total - * - raw_original_shipping_total - * - raw_original_shipping_subtotal - * - raw_original_shipping_tax_total - * properties: - * order_change: - * $ref: "#/components/schemas/OrderChange" - * items: - * type: array - * description: The order preview's items. - * items: - * allOf: - * - type: object - * description: The item's items. - * x-schemaName: OrderLineItem - * required: - * - id - * - title - * - requires_shipping - * - is_discountable - * - is_tax_inclusive - * - unit_price - * - raw_unit_price - * - quantity - * - raw_quantity - * - detail - * - created_at - * - updated_at - * - original_total - * - original_subtotal - * - original_tax_total - * - item_total - * - item_subtotal - * - item_tax_total - * - total - * - subtotal - * - tax_total - * - discount_total - * - discount_tax_total - * - refundable_total - * - refundable_total_per_unit - * - raw_original_total - * - raw_original_subtotal - * - raw_original_tax_total - * - raw_item_total - * - raw_item_subtotal - * - raw_item_tax_total - * - raw_total - * - raw_subtotal - * - raw_tax_total - * - raw_discount_total - * - raw_discount_tax_total - * - raw_refundable_total - * - raw_refundable_total_per_unit - * properties: - * id: - * type: string - * title: id - * description: The item's ID. - * title: - * type: string - * title: title - * description: The item's title. - * subtitle: - * type: string - * title: subtitle - * description: The item's subtitle. - * thumbnail: - * type: string - * title: thumbnail - * description: The item's thumbnail. - * variant_id: - * type: string - * title: variant_id - * description: The item's variant id. - * product_id: - * type: string - * title: product_id - * description: The item's product id. - * product_title: - * type: string - * title: product_title - * description: The item's product title. - * product_description: - * type: string - * title: product_description - * description: The item's product description. - * product_subtitle: - * type: string - * title: product_subtitle - * description: The item's product subtitle. - * product_type: - * type: string - * title: product_type - * description: The item's product type. - * product_collection: - * type: string - * title: product_collection - * description: The item's product collection. - * product_handle: - * type: string - * title: product_handle - * description: The item's product handle. - * variant_sku: - * type: string - * title: variant_sku - * description: The item's variant sku. - * variant_barcode: - * type: string - * title: variant_barcode - * description: The item's variant barcode. - * variant_title: - * type: string - * title: variant_title - * description: The item's variant title. - * variant_option_values: - * type: object - * description: The item's variant option values. - * requires_shipping: - * type: boolean - * title: requires_shipping - * description: The item's requires shipping. - * is_discountable: - * type: boolean - * title: is_discountable - * description: The item's is discountable. - * is_tax_inclusive: - * type: boolean - * title: is_tax_inclusive - * description: The item's is tax inclusive. - * compare_at_unit_price: - * type: number - * title: compare_at_unit_price - * description: The item's compare at unit price. - * raw_compare_at_unit_price: - * type: object - * description: The item's raw compare at unit price. - * unit_price: - * type: number - * title: unit_price - * description: The item's unit price. - * raw_unit_price: - * type: object - * description: The item's raw unit price. - * quantity: - * type: number - * title: quantity - * description: The item's quantity. - * raw_quantity: - * type: object - * description: The item's raw quantity. - * tax_lines: - * type: array - * description: The item's tax lines. - * items: - * $ref: "#/components/schemas/OrderLineItemTaxLine" - * adjustments: - * type: array - * description: The item's adjustments. - * items: - * $ref: "#/components/schemas/OrderLineItemAdjustment" - * detail: - * $ref: "#/components/schemas/OrderItem" - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The item's created at. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The item's updated at. - * metadata: - * type: object - * description: The item's metadata. - * original_total: - * oneOf: - * - type: string - * title: original_total - * description: The item's original total. - * - type: number - * title: original_total - * description: The item's original total. - * - type: string - * title: original_total - * description: The item's original total. - * - $ref: "#/components/schemas/IBigNumber" - * original_subtotal: - * oneOf: - * - type: string - * title: original_subtotal - * description: The item's original subtotal. - * - type: number - * title: original_subtotal - * description: The item's original subtotal. - * - type: string - * title: original_subtotal - * description: The item's original subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * original_tax_total: - * oneOf: - * - type: string - * title: original_tax_total - * description: The item's original tax total. - * - type: number - * title: original_tax_total - * description: The item's original tax total. - * - type: string - * title: original_tax_total - * description: The item's original tax total. - * - $ref: "#/components/schemas/IBigNumber" - * item_total: - * oneOf: - * - type: string - * title: item_total - * description: The item's item total. - * - type: number - * title: item_total - * description: The item's item total. - * - type: string - * title: item_total - * description: The item's item total. - * - $ref: "#/components/schemas/IBigNumber" - * item_subtotal: - * oneOf: - * - type: string - * title: item_subtotal - * description: The item's item subtotal. - * - type: number - * title: item_subtotal - * description: The item's item subtotal. - * - type: string - * title: item_subtotal - * description: The item's item subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * item_tax_total: - * oneOf: - * - type: string - * title: item_tax_total - * description: The item's item tax total. - * - type: number - * title: item_tax_total - * description: The item's item tax total. - * - type: string - * title: item_tax_total - * description: The item's item tax total. - * - $ref: "#/components/schemas/IBigNumber" - * total: - * oneOf: - * - type: string - * title: total - * description: The item's total. - * - type: number - * title: total - * description: The item's total. - * - type: string - * title: total - * description: The item's total. - * - $ref: "#/components/schemas/IBigNumber" - * subtotal: - * oneOf: - * - type: string - * title: subtotal - * description: The item's subtotal. - * - type: number - * title: subtotal - * description: The item's subtotal. - * - type: string - * title: subtotal - * description: The item's subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * tax_total: - * oneOf: - * - type: string - * title: tax_total - * description: The item's tax total. - * - type: number - * title: tax_total - * description: The item's tax total. - * - type: string - * title: tax_total - * description: The item's tax total. - * - $ref: "#/components/schemas/IBigNumber" - * discount_total: - * oneOf: - * - type: string - * title: discount_total - * description: The item's discount total. - * - type: number - * title: discount_total - * description: The item's discount total. - * - type: string - * title: discount_total - * description: The item's discount total. - * - $ref: "#/components/schemas/IBigNumber" - * discount_tax_total: - * oneOf: - * - type: string - * title: discount_tax_total - * description: The item's discount tax total. - * - type: number - * title: discount_tax_total - * description: The item's discount tax total. - * - type: string - * title: discount_tax_total - * description: The item's discount tax total. - * - $ref: "#/components/schemas/IBigNumber" - * refundable_total: - * oneOf: - * - type: string - * title: refundable_total - * description: The item's refundable total. - * - type: number - * title: refundable_total - * description: The item's refundable total. - * - type: string - * title: refundable_total - * description: The item's refundable total. - * - $ref: "#/components/schemas/IBigNumber" - * refundable_total_per_unit: - * oneOf: - * - type: string - * title: refundable_total_per_unit - * description: The item's refundable total per unit. - * - type: number - * title: refundable_total_per_unit - * description: The item's refundable total per unit. - * - type: string - * title: refundable_total_per_unit - * description: The item's refundable total per unit. - * - $ref: "#/components/schemas/IBigNumber" - * raw_original_total: - * type: object - * description: The item's raw original total. - * raw_original_subtotal: - * type: object - * description: The item's raw original subtotal. - * raw_original_tax_total: - * type: object - * description: The item's raw original tax total. - * raw_item_total: - * type: object - * description: The item's raw item total. - * raw_item_subtotal: - * type: object - * description: The item's raw item subtotal. - * raw_item_tax_total: - * type: object - * description: The item's raw item tax total. - * raw_total: - * type: object - * description: The item's raw total. - * raw_subtotal: - * type: object - * description: The item's raw subtotal. - * raw_tax_total: - * type: object - * description: The item's raw tax total. - * raw_discount_total: - * type: object - * description: The item's raw discount total. - * raw_discount_tax_total: - * type: object - * description: The item's raw discount tax total. - * raw_refundable_total: - * type: object - * description: The item's raw refundable total. - * raw_refundable_total_per_unit: - * type: object - * description: The item's raw refundable total per unit. - * - type: object - * description: The item's items. - * properties: - * actions: - * type: array - * description: The item's actions. - * items: - * type: object - * description: The action's actions. - * x-schemaName: OrderChangeAction - * shipping_methods: - * type: array - * description: The order preview's shipping methods. - * items: - * allOf: - * - type: object - * description: The shipping method's shipping methods. - * x-schemaName: OrderShippingMethod - * required: - * - id - * - order_id - * - name - * - amount - * - raw_amount - * - is_tax_inclusive - * - created_at - * - updated_at - * - original_total - * - original_subtotal - * - original_tax_total - * - total - * - subtotal - * - tax_total - * - discount_total - * - discount_tax_total - * - raw_original_total - * - raw_original_subtotal - * - raw_original_tax_total - * - raw_total - * - raw_subtotal - * - raw_tax_total - * - raw_discount_total - * - raw_discount_tax_total - * properties: - * id: - * type: string - * title: id - * description: The shipping method's ID. - * order_id: - * type: string - * title: order_id - * description: The shipping method's order id. - * name: - * type: string - * title: name - * description: The shipping method's name. - * description: - * type: string - * title: description - * description: The shipping method's description. - * amount: - * oneOf: - * - type: string - * title: amount - * description: The shipping method's amount. - * - type: number - * title: amount - * description: The shipping method's amount. - * - type: string - * title: amount - * description: The shipping method's amount. - * - $ref: "#/components/schemas/IBigNumber" - * raw_amount: - * type: object - * description: The shipping method's raw amount. - * is_tax_inclusive: - * type: boolean - * title: is_tax_inclusive - * description: The shipping method's is tax inclusive. - * shipping_option_id: - * type: string - * title: shipping_option_id - * description: The shipping method's shipping option id. - * data: - * type: object - * description: The shipping method's data. - * metadata: - * type: object - * description: The shipping method's metadata. - * tax_lines: - * type: array - * description: The shipping method's tax lines. - * items: - * $ref: "#/components/schemas/OrderShippingMethodTaxLine" - * adjustments: - * type: array - * description: The shipping method's adjustments. - * items: - * $ref: "#/components/schemas/OrderShippingMethodAdjustment" - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The shipping method's created at. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The shipping method's updated at. - * original_total: - * oneOf: - * - type: string - * title: original_total - * description: The shipping method's original total. - * - type: number - * title: original_total - * description: The shipping method's original total. - * - type: string - * title: original_total - * description: The shipping method's original total. - * - $ref: "#/components/schemas/IBigNumber" - * original_subtotal: - * oneOf: - * - type: string - * title: original_subtotal - * description: The shipping method's original subtotal. - * - type: number - * title: original_subtotal - * description: The shipping method's original subtotal. - * - type: string - * title: original_subtotal - * description: The shipping method's original subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * original_tax_total: - * oneOf: - * - type: string - * title: original_tax_total - * description: The shipping method's original tax total. - * - type: number - * title: original_tax_total - * description: The shipping method's original tax total. - * - type: string - * title: original_tax_total - * description: The shipping method's original tax total. - * - $ref: "#/components/schemas/IBigNumber" - * total: - * oneOf: - * - type: string - * title: total - * description: The shipping method's total. - * - type: number - * title: total - * description: The shipping method's total. - * - type: string - * title: total - * description: The shipping method's total. - * - $ref: "#/components/schemas/IBigNumber" - * subtotal: - * oneOf: - * - type: string - * title: subtotal - * description: The shipping method's subtotal. - * - type: number - * title: subtotal - * description: The shipping method's subtotal. - * - type: string - * title: subtotal - * description: The shipping method's subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * tax_total: - * oneOf: - * - type: string - * title: tax_total - * description: The shipping method's tax total. - * - type: number - * title: tax_total - * description: The shipping method's tax total. - * - type: string - * title: tax_total - * description: The shipping method's tax total. - * - $ref: "#/components/schemas/IBigNumber" - * discount_total: - * oneOf: - * - type: string - * title: discount_total - * description: The shipping method's discount total. - * - type: number - * title: discount_total - * description: The shipping method's discount total. - * - type: string - * title: discount_total - * description: The shipping method's discount total. - * - $ref: "#/components/schemas/IBigNumber" - * discount_tax_total: - * oneOf: - * - type: string - * title: discount_tax_total - * description: The shipping method's discount tax total. - * - type: number - * title: discount_tax_total - * description: The shipping method's discount tax total. - * - type: string - * title: discount_tax_total - * description: The shipping method's discount tax total. - * - $ref: "#/components/schemas/IBigNumber" - * raw_original_total: - * type: object - * description: The shipping method's raw original total. - * raw_original_subtotal: - * type: object - * description: The shipping method's raw original subtotal. - * raw_original_tax_total: - * type: object - * description: The shipping method's raw original tax total. - * raw_total: - * type: object - * description: The shipping method's raw total. - * raw_subtotal: - * type: object - * description: The shipping method's raw subtotal. - * raw_tax_total: - * type: object - * description: The shipping method's raw tax total. - * raw_discount_total: - * type: object - * description: The shipping method's raw discount total. - * raw_discount_tax_total: - * type: object - * description: The shipping method's raw discount tax total. - * - type: object - * description: The shipping method's shipping methods. - * properties: - * actions: - * type: array - * description: The shipping method's actions. - * items: - * type: object - * description: The action's actions. - * x-schemaName: OrderChangeAction - * status: - * type: string - * description: The order preview's status. - * enum: - * - canceled - * - requires_action - * - pending - * - completed - * - draft - * - archived - * currency_code: - * type: string - * title: currency_code - * description: The order preview's currency code. - * version: - * type: number - * title: version - * description: The order preview's version. - * id: - * type: string - * title: id - * description: The order preview's ID. - * region_id: - * type: string - * title: region_id - * description: The order preview's region id. - * customer_id: - * type: string - * title: customer_id - * description: The order preview's customer id. - * sales_channel_id: - * type: string - * title: sales_channel_id - * description: The order preview's sales channel id. - * email: - * type: string - * title: email - * description: The order preview's email. - * format: email - * shipping_address: - * $ref: "#/components/schemas/OrderAddress" - * billing_address: - * $ref: "#/components/schemas/OrderAddress" - * transactions: - * type: array - * description: The order preview's transactions. - * items: - * $ref: "#/components/schemas/OrderTransaction" - * summary: - * type: object - * description: The order preview's summary. - * required: - * - total - * - subtotal - * - total_tax - * - ordered_total - * - fulfilled_total - * - returned_total - * - return_request_total - * - write_off_total - * - projected_total - * - net_total - * - net_subtotal - * - net_total_tax - * - balance - * - paid_total - * - refunded_total - * - pending_difference - * - raw_pending_difference - * properties: - * total: - * oneOf: - * - type: string - * title: total - * description: The summary's total. - * - type: number - * title: total - * description: The summary's total. - * - type: string - * title: total - * description: The summary's total. - * - type: object - * description: The summary's total. - * x-schemaName: IBigNumber - * subtotal: - * oneOf: - * - type: string - * title: subtotal - * description: The summary's subtotal. - * - type: number - * title: subtotal - * description: The summary's subtotal. - * - type: string - * title: subtotal - * description: The summary's subtotal. - * - type: object - * description: The summary's subtotal. - * x-schemaName: IBigNumber - * total_tax: - * oneOf: - * - type: string - * title: total_tax - * description: The summary's total tax. - * - type: number - * title: total_tax - * description: The summary's total tax. - * - type: string - * title: total_tax - * description: The summary's total tax. - * - type: object - * description: The summary's total tax. - * x-schemaName: IBigNumber - * ordered_total: - * oneOf: - * - type: string - * title: ordered_total - * description: The summary's ordered total. - * - type: number - * title: ordered_total - * description: The summary's ordered total. - * - type: string - * title: ordered_total - * description: The summary's ordered total. - * - type: object - * description: The summary's ordered total. - * x-schemaName: IBigNumber - * fulfilled_total: - * oneOf: - * - type: string - * title: fulfilled_total - * description: The summary's fulfilled total. - * - type: number - * title: fulfilled_total - * description: The summary's fulfilled total. - * - type: string - * title: fulfilled_total - * description: The summary's fulfilled total. - * - type: object - * description: The summary's fulfilled total. - * x-schemaName: IBigNumber - * returned_total: - * oneOf: - * - type: string - * title: returned_total - * description: The summary's returned total. - * - type: number - * title: returned_total - * description: The summary's returned total. - * - type: string - * title: returned_total - * description: The summary's returned total. - * - type: object - * description: The summary's returned total. - * x-schemaName: IBigNumber - * return_request_total: - * oneOf: - * - type: string - * title: return_request_total - * description: The summary's return request total. - * - type: number - * title: return_request_total - * description: The summary's return request total. - * - type: string - * title: return_request_total - * description: The summary's return request total. - * - type: object - * description: The summary's return request total. - * x-schemaName: IBigNumber - * write_off_total: - * oneOf: - * - type: string - * title: write_off_total - * description: The summary's write off total. - * - type: number - * title: write_off_total - * description: The summary's write off total. - * - type: string - * title: write_off_total - * description: The summary's write off total. - * - type: object - * description: The summary's write off total. - * x-schemaName: IBigNumber - * projected_total: - * oneOf: - * - type: string - * title: projected_total - * description: The summary's projected total. - * - type: number - * title: projected_total - * description: The summary's projected total. - * - type: string - * title: projected_total - * description: The summary's projected total. - * - type: object - * description: The summary's projected total. - * x-schemaName: IBigNumber - * net_total: - * oneOf: - * - type: string - * title: net_total - * description: The summary's net total. - * - type: number - * title: net_total - * description: The summary's net total. - * - type: string - * title: net_total - * description: The summary's net total. - * - type: object - * description: The summary's net total. - * x-schemaName: IBigNumber - * net_subtotal: - * oneOf: - * - type: string - * title: net_subtotal - * description: The summary's net subtotal. - * - type: number - * title: net_subtotal - * description: The summary's net subtotal. - * - type: string - * title: net_subtotal - * description: The summary's net subtotal. - * - type: object - * description: The summary's net subtotal. - * x-schemaName: IBigNumber - * net_total_tax: - * oneOf: - * - type: string - * title: net_total_tax - * description: The summary's net total tax. - * - type: number - * title: net_total_tax - * description: The summary's net total tax. - * - type: string - * title: net_total_tax - * description: The summary's net total tax. - * - type: object - * description: The summary's net total tax. - * x-schemaName: IBigNumber - * balance: - * oneOf: - * - type: string - * title: balance - * description: The summary's balance. - * - type: number - * title: balance - * description: The summary's balance. - * - type: string - * title: balance - * description: The summary's balance. - * - type: object - * description: The summary's balance. - * x-schemaName: IBigNumber - * paid_total: - * oneOf: - * - type: string - * title: paid_total - * description: The summary's paid total. - * - type: number - * title: paid_total - * description: The summary's paid total. - * - type: string - * title: paid_total - * description: The summary's paid total. - * - type: object - * description: The summary's paid total. - * x-schemaName: IBigNumber - * refunded_total: - * oneOf: - * - type: string - * title: refunded_total - * description: The summary's refunded total. - * - type: number - * title: refunded_total - * description: The summary's refunded total. - * - type: string - * title: refunded_total - * description: The summary's refunded total. - * - type: object - * description: The summary's refunded total. - * x-schemaName: IBigNumber - * pending_difference: - * oneOf: - * - type: string - * title: pending_difference - * description: The summary's pending difference. - * - type: number - * title: pending_difference - * description: The summary's pending difference. - * - type: string - * title: pending_difference - * description: The summary's pending difference. - * - type: object - * description: The summary's pending difference. - * x-schemaName: IBigNumber - * raw_pending_difference: - * type: object - * description: The summary's raw pending difference. - * metadata: - * type: object - * description: The order preview's metadata. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The order preview's created at. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The order preview's updated at. - * original_item_total: - * oneOf: - * - type: string - * title: original_item_total - * description: The order preview's original item total. - * - type: number - * title: original_item_total - * description: The order preview's original item total. - * - type: string - * title: original_item_total - * description: The order preview's original item total. - * - $ref: "#/components/schemas/IBigNumber" - * original_item_subtotal: - * oneOf: - * - type: string - * title: original_item_subtotal - * description: The order preview's original item subtotal. - * - type: number - * title: original_item_subtotal - * description: The order preview's original item subtotal. - * - type: string - * title: original_item_subtotal - * description: The order preview's original item subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * original_item_tax_total: - * oneOf: - * - type: string - * title: original_item_tax_total - * description: The order preview's original item tax total. - * - type: number - * title: original_item_tax_total - * description: The order preview's original item tax total. - * - type: string - * title: original_item_tax_total - * description: The order preview's original item tax total. - * - $ref: "#/components/schemas/IBigNumber" - * item_total: - * oneOf: - * - type: string - * title: item_total - * description: The order preview's item total. - * - type: number - * title: item_total - * description: The order preview's item total. - * - type: string - * title: item_total - * description: The order preview's item total. - * - $ref: "#/components/schemas/IBigNumber" - * item_subtotal: - * oneOf: - * - type: string - * title: item_subtotal - * description: The order preview's item subtotal. - * - type: number - * title: item_subtotal - * description: The order preview's item subtotal. - * - type: string - * title: item_subtotal - * description: The order preview's item subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * item_tax_total: - * oneOf: - * - type: string - * title: item_tax_total - * description: The order preview's item tax total. - * - type: number - * title: item_tax_total - * description: The order preview's item tax total. - * - type: string - * title: item_tax_total - * description: The order preview's item tax total. - * - $ref: "#/components/schemas/IBigNumber" - * original_total: - * oneOf: - * - type: string - * title: original_total - * description: The order preview's original total. - * - type: number - * title: original_total - * description: The order preview's original total. - * - type: string - * title: original_total - * description: The order preview's original total. - * - $ref: "#/components/schemas/IBigNumber" - * original_subtotal: - * oneOf: - * - type: string - * title: original_subtotal - * description: The order preview's original subtotal. - * - type: number - * title: original_subtotal - * description: The order preview's original subtotal. - * - type: string - * title: original_subtotal - * description: The order preview's original subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * original_tax_total: - * oneOf: - * - type: string - * title: original_tax_total - * description: The order preview's original tax total. - * - type: number - * title: original_tax_total - * description: The order preview's original tax total. - * - type: string - * title: original_tax_total - * description: The order preview's original tax total. - * - $ref: "#/components/schemas/IBigNumber" - * total: - * oneOf: - * - type: string - * title: total - * description: The order preview's total. - * - type: number - * title: total - * description: The order preview's total. - * - type: string - * title: total - * description: The order preview's total. - * - $ref: "#/components/schemas/IBigNumber" - * subtotal: - * oneOf: - * - type: string - * title: subtotal - * description: The order preview's subtotal. - * - type: number - * title: subtotal - * description: The order preview's subtotal. - * - type: string - * title: subtotal - * description: The order preview's subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * tax_total: - * oneOf: - * - type: string - * title: tax_total - * description: The order preview's tax total. - * - type: number - * title: tax_total - * description: The order preview's tax total. - * - type: string - * title: tax_total - * description: The order preview's tax total. - * - $ref: "#/components/schemas/IBigNumber" - * discount_total: - * oneOf: - * - type: string - * title: discount_total - * description: The order preview's discount total. - * - type: number - * title: discount_total - * description: The order preview's discount total. - * - type: string - * title: discount_total - * description: The order preview's discount total. - * - $ref: "#/components/schemas/IBigNumber" - * discount_tax_total: - * oneOf: - * - type: string - * title: discount_tax_total - * description: The order preview's discount tax total. - * - type: number - * title: discount_tax_total - * description: The order preview's discount tax total. - * - type: string - * title: discount_tax_total - * description: The order preview's discount tax total. - * - $ref: "#/components/schemas/IBigNumber" - * gift_card_total: - * oneOf: - * - type: string - * title: gift_card_total - * description: The order preview's gift card total. - * - type: number - * title: gift_card_total - * description: The order preview's gift card total. - * - type: string - * title: gift_card_total - * description: The order preview's gift card total. - * - $ref: "#/components/schemas/IBigNumber" - * gift_card_tax_total: - * oneOf: - * - type: string - * title: gift_card_tax_total - * description: The order preview's gift card tax total. - * - type: number - * title: gift_card_tax_total - * description: The order preview's gift card tax total. - * - type: string - * title: gift_card_tax_total - * description: The order preview's gift card tax total. - * - $ref: "#/components/schemas/IBigNumber" - * shipping_total: - * oneOf: - * - type: string - * title: shipping_total - * description: The order preview's shipping total. - * - type: number - * title: shipping_total - * description: The order preview's shipping total. - * - type: string - * title: shipping_total - * description: The order preview's shipping total. - * - $ref: "#/components/schemas/IBigNumber" - * shipping_subtotal: - * oneOf: - * - type: string - * title: shipping_subtotal - * description: The order preview's shipping subtotal. - * - type: number - * title: shipping_subtotal - * description: The order preview's shipping subtotal. - * - type: string - * title: shipping_subtotal - * description: The order preview's shipping subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * shipping_tax_total: - * oneOf: - * - type: string - * title: shipping_tax_total - * description: The order preview's shipping tax total. - * - type: number - * title: shipping_tax_total - * description: The order preview's shipping tax total. - * - type: string - * title: shipping_tax_total - * description: The order preview's shipping tax total. - * - $ref: "#/components/schemas/IBigNumber" - * original_shipping_total: - * oneOf: - * - type: string - * title: original_shipping_total - * description: The order preview's original shipping total. - * - type: number - * title: original_shipping_total - * description: The order preview's original shipping total. - * - type: string - * title: original_shipping_total - * description: The order preview's original shipping total. - * - $ref: "#/components/schemas/IBigNumber" - * original_shipping_subtotal: - * oneOf: - * - type: string - * title: original_shipping_subtotal - * description: The order preview's original shipping subtotal. - * - type: number - * title: original_shipping_subtotal - * description: The order preview's original shipping subtotal. - * - type: string - * title: original_shipping_subtotal - * description: The order preview's original shipping subtotal. - * - $ref: "#/components/schemas/IBigNumber" - * original_shipping_tax_total: - * oneOf: - * - type: string - * title: original_shipping_tax_total - * description: The order preview's original shipping tax total. - * - type: number - * title: original_shipping_tax_total - * description: The order preview's original shipping tax total. - * - type: string - * title: original_shipping_tax_total - * description: The order preview's original shipping tax total. - * - $ref: "#/components/schemas/IBigNumber" - * canceled_at: - * oneOf: - * - type: string - * title: canceled_at - * description: The order preview's canceled at. - * - type: string - * title: canceled_at - * description: The order preview's canceled at. - * format: date-time - * raw_original_item_total: - * type: object - * description: The order preview's raw original item total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original item total's value. - * - type: number - * title: value - * description: The raw original item total's value. - * raw_original_item_subtotal: - * type: object - * description: The order preview's raw original item subtotal. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original item subtotal's value. - * - type: number - * title: value - * description: The raw original item subtotal's value. - * raw_original_item_tax_total: - * type: object - * description: The order preview's raw original item tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original item tax total's value. - * - type: number - * title: value - * description: The raw original item tax total's value. - * raw_item_total: - * type: object - * description: The order preview's raw item total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw item total's value. - * - type: number - * title: value - * description: The raw item total's value. - * raw_item_subtotal: - * type: object - * description: The order preview's raw item subtotal. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw item subtotal's value. - * - type: number - * title: value - * description: The raw item subtotal's value. - * raw_item_tax_total: - * type: object - * description: The order preview's raw item tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw item tax total's value. - * - type: number - * title: value - * description: The raw item tax total's value. - * raw_original_total: - * type: object - * description: The order preview's raw original total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original total's value. - * - type: number - * title: value - * description: The raw original total's value. - * raw_original_subtotal: - * type: object - * description: The order preview's raw original subtotal. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original subtotal's value. - * - type: number - * title: value - * description: The raw original subtotal's value. - * raw_original_tax_total: - * type: object - * description: The order preview's raw original tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original tax total's value. - * - type: number - * title: value - * description: The raw original tax total's value. - * raw_total: - * type: object - * description: The order preview's raw total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw total's value. - * - type: number - * title: value - * description: The raw total's value. - * raw_subtotal: - * type: object - * description: The order preview's raw subtotal. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw subtotal's value. - * - type: number - * title: value - * description: The raw subtotal's value. - * raw_tax_total: - * type: object - * description: The order preview's raw tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw tax total's value. - * - type: number - * title: value - * description: The raw tax total's value. - * raw_discount_total: - * type: object - * description: The order preview's raw discount total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw discount total's value. - * - type: number - * title: value - * description: The raw discount total's value. - * raw_discount_tax_total: - * type: object - * description: The order preview's raw discount tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw discount tax total's value. - * - type: number - * title: value - * description: The raw discount tax total's value. - * raw_gift_card_total: - * type: object - * description: The order preview's raw gift card total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw gift card total's value. - * - type: number - * title: value - * description: The raw gift card total's value. - * raw_gift_card_tax_total: - * type: object - * description: The order preview's raw gift card tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw gift card tax total's value. - * - type: number - * title: value - * description: The raw gift card tax total's value. - * raw_shipping_total: - * type: object - * description: The order preview's raw shipping total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw shipping total's value. - * - type: number - * title: value - * description: The raw shipping total's value. - * raw_shipping_subtotal: - * type: object - * description: The order preview's raw shipping subtotal. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw shipping subtotal's value. - * - type: number - * title: value - * description: The raw shipping subtotal's value. - * raw_shipping_tax_total: - * type: object - * description: The order preview's raw shipping tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw shipping tax total's value. - * - type: number - * title: value - * description: The raw shipping tax total's value. - * raw_original_shipping_total: - * type: object - * description: The order preview's raw original shipping total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original shipping total's value. - * - type: number - * title: value - * description: The raw original shipping total's value. - * raw_original_shipping_subtotal: - * type: object - * description: The order preview's raw original shipping subtotal. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original shipping subtotal's value. - * - type: number - * title: value - * description: The raw original shipping subtotal's value. - * raw_original_shipping_tax_total: - * type: object - * description: The order preview's raw original shipping tax total. - * required: - * - value - * properties: - * value: - * oneOf: - * - type: string - * title: value - * description: The raw original shipping tax total's value. - * - type: number - * title: value - * description: The raw original shipping tax total's value. - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/RefundReason.ts b/www/utils/generated/oas-output/schemas/RefundReason.ts new file mode 100644 index 0000000000000..1629d82d76665 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/RefundReason.ts @@ -0,0 +1,40 @@ +/** + * @schema RefundReason + * type: object + * description: The refund's refund reason. + * x-schemaName: RefundReason + * required: + * - id + * - label + * - metadata + * - created_at + * - updated_at + * properties: + * id: + * type: string + * title: id + * description: The refund reason's ID. + * label: + * type: string + * title: label + * description: The refund reason's label. + * description: + * type: string + * title: description + * description: The refund reason's description. + * metadata: + * type: object + * description: The refund reason's metadata. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The refund reason's created at. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The refund reason's updated at. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/ReservationResponse.ts b/www/utils/generated/oas-output/schemas/ReservationResponse.ts deleted file mode 100644 index 1702fe4ee707e..0000000000000 --- a/www/utils/generated/oas-output/schemas/ReservationResponse.ts +++ /dev/null @@ -1,71 +0,0 @@ -/** - * @schema ReservationResponse - * type: object - * description: The reservation's details. - * x-schemaName: ReservationResponse - * required: - * - id - * - line_item_id - * - location_id - * - quantity - * - external_id - * - description - * - inventory_item_id - * - inventory_item - * properties: - * id: - * type: string - * title: id - * description: The reservation's ID. - * line_item_id: - * type: string - * title: line_item_id - * description: The reservation's line item id. - * location_id: - * type: string - * title: location_id - * description: The reservation's location id. - * quantity: - * type: string - * title: quantity - * description: The reservation's quantity. - * external_id: - * type: string - * title: external_id - * description: The reservation's external id. - * description: - * type: string - * title: description - * description: The reservation's description. - * inventory_item_id: - * type: string - * title: inventory_item_id - * description: The reservation's inventory item id. - * inventory_item: - * type: object - * description: The reservation's inventory item. - * metadata: - * type: object - * description: The reservation's metadata. - * created_by: - * type: string - * title: created_by - * description: The reservation's created by. - * deleted_at: - * type: string - * format: date-time - * title: deleted_at - * description: The reservation's deleted at. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The reservation's created at. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The reservation's updated at. - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/StoreCalculateCartTaxes.ts b/www/utils/generated/oas-output/schemas/StoreCalculateCartTaxes.ts deleted file mode 100644 index 13e68b23cfe04..0000000000000 --- a/www/utils/generated/oas-output/schemas/StoreCalculateCartTaxes.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * @schema StoreCalculateCartTaxes - * type: object - * description: SUMMARY - * x-schemaName: StoreCalculateCartTaxes - * properties: - * fields: - * type: string - * title: fields - * description: The cart's fields. - * -*/ - diff --git a/www/utils/generated/oas-output/schemas/StoreCart.ts b/www/utils/generated/oas-output/schemas/StoreCart.ts index 8aac82e9fd6f0..61aae0b093c0f 100644 --- a/www/utils/generated/oas-output/schemas/StoreCart.ts +++ b/www/utils/generated/oas-output/schemas/StoreCart.ts @@ -4,8 +4,8 @@ * description: The cart's details. * x-schemaName: StoreCart * required: - * - id * - currency_code + * - id * - original_item_total * - original_item_subtotal * - original_item_tax_total @@ -34,7 +34,7 @@ * title: id * description: The cart's ID. * region: - * $ref: "#/components/schemas/BaseRegion" + * $ref: "#/components/schemas/StoreRegion" * region_id: * type: string * title: region_id @@ -70,9 +70,9 @@ * type: array * description: The cart's shipping methods. * items: - * $ref: "#/components/schemas/BaseCartShippingMethod" + * $ref: "#/components/schemas/StoreCartShippingMethod" * payment_collection: - * $ref: "#/components/schemas/BasePaymentCollection" + * $ref: "#/components/schemas/StorePaymentCollection" * metadata: * type: object * description: The cart's metadata, can hold custom key-value pairs. diff --git a/www/utils/generated/oas-output/schemas/StoreCartLineItem.ts b/www/utils/generated/oas-output/schemas/StoreCartLineItem.ts index c28f33d6fc295..7f7a2b551a610 100644 --- a/www/utils/generated/oas-output/schemas/StoreCartLineItem.ts +++ b/www/utils/generated/oas-output/schemas/StoreCartLineItem.ts @@ -4,26 +4,26 @@ * description: The item's details. * x-schemaName: StoreCartLineItem * required: - * - id - * - title - * - quantity - * - requires_shipping - * - is_discountable - * - is_tax_inclusive - * - unit_price * - cart - * - cart_id - * - original_total - * - original_subtotal - * - original_tax_total + * - title + * - id * - item_total * - item_subtotal * - item_tax_total + * - original_total + * - original_subtotal + * - original_tax_total * - total * - subtotal * - tax_total * - discount_total * - discount_tax_total + * - requires_shipping + * - is_discountable + * - is_tax_inclusive + * - unit_price + * - quantity + * - cart_id * properties: * id: * type: string @@ -76,7 +76,7 @@ * title: product_handle * description: The item's product handle. * variant: - * $ref: "#/components/schemas/BaseProductVariant" + * $ref: "#/components/schemas/StoreProductVariant" * variant_id: * type: string * title: variant_id diff --git a/www/utils/generated/oas-output/schemas/StoreCartShippingMethod.ts b/www/utils/generated/oas-output/schemas/StoreCartShippingMethod.ts new file mode 100644 index 0000000000000..7dcb01b665092 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/StoreCartShippingMethod.ts @@ -0,0 +1,113 @@ +/** + * @schema StoreCartShippingMethod + * type: object + * description: A cart's shipping method. + * x-schemaName: StoreCartShippingMethod + * required: + * - id + * - cart_id + * - name + * - amount + * - is_tax_inclusive + * - created_at + * - updated_at + * - original_total + * - original_subtotal + * - original_tax_total + * - total + * - subtotal + * - tax_total + * - discount_total + * - discount_tax_total + * properties: + * id: + * type: string + * title: id + * description: The shipping method's ID. + * cart_id: + * type: string + * title: cart_id + * description: The ID of the cart this shipping method belongs to. + * name: + * type: string + * title: name + * description: The shipping method's name. + * description: + * type: string + * title: description + * description: The shipping method's description. + * amount: + * type: number + * title: amount + * description: The shipping method's amount. + * is_tax_inclusive: + * type: boolean + * title: is_tax_inclusive + * description: Whether the shipping method's amount is tax inclusive. + * shipping_option_id: + * type: string + * title: shipping_option_id + * description: The ID of the shipping option this method was created from. + * data: + * type: object + * description: The shipping method's data, useful for fulfillment handling by third-party services. + * externalDocs: + * url: https://docs.medusajs.com/v2/resources/commerce-modules/cart/concepts#data-property + * metadata: + * type: object + * description: The shipping method's metadata, can hold custom key-value pairs. + * tax_lines: + * type: array + * description: The shipping method's tax lines. + * items: + * $ref: "#/components/schemas/BaseShippingMethodTaxLine" + * adjustments: + * type: array + * description: The shipping method's adjustments, such as applied promotions. + * items: + * $ref: "#/components/schemas/BaseShippingMethodAdjustment" + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The date the shipping method was created. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The date the shipping method was updated. + * original_total: + * type: number + * title: original_total + * description: The shipping method's total including taxes, excluding promotions. + * original_subtotal: + * type: number + * title: original_subtotal + * description: The shipping method's total excluding taxes, including promotions. + * original_tax_total: + * type: number + * title: original_tax_total + * description: The total taxes applied on the shipping method's amount including promotions. + * total: + * type: number + * title: total + * description: The shipping method's total amount including taxes and promotions. + * subtotal: + * type: number + * title: subtotal + * description: The shipping method's total amount excluding taxes, including promotions. + * tax_total: + * type: number + * title: tax_total + * description: The total taxes applied on the shipping method's amount including promotions. + * discount_total: + * type: number + * title: discount_total + * description: The total amount discounted. + * discount_tax_total: + * type: number + * title: discount_tax_total + * description: The taxes applied on the discounted amount. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/StoreCollection.ts b/www/utils/generated/oas-output/schemas/StoreCollection.ts index b2a10aa055fa7..ef32a244e5c84 100644 --- a/www/utils/generated/oas-output/schemas/StoreCollection.ts +++ b/www/utils/generated/oas-output/schemas/StoreCollection.ts @@ -43,7 +43,7 @@ * type: array * description: The collection's products. * items: - * $ref: "#/components/schemas/StoreProduct" + * $ref: "#/components/schemas/AdminProduct" * metadata: * type: object * description: The collection's metadata, can hold custom key-value pairs. diff --git a/www/utils/generated/oas-output/schemas/StoreCurrency.ts b/www/utils/generated/oas-output/schemas/StoreCurrency.ts index b962160490e62..fecf22e57f0a5 100644 --- a/www/utils/generated/oas-output/schemas/StoreCurrency.ts +++ b/www/utils/generated/oas-output/schemas/StoreCurrency.ts @@ -10,7 +10,6 @@ * - name * - decimal_digits * - rounding - * - raw_rounding * - created_at * - updated_at * - deleted_at diff --git a/www/utils/generated/oas-output/schemas/StoreCustomer.ts b/www/utils/generated/oas-output/schemas/StoreCustomer.ts index 8f563c411e5f4..12ed99dfc7ab3 100644 --- a/www/utils/generated/oas-output/schemas/StoreCustomer.ts +++ b/www/utils/generated/oas-output/schemas/StoreCustomer.ts @@ -46,7 +46,7 @@ * type: array * description: The customer's addresses. * items: - * $ref: "#/components/schemas/StoreCustomerAddress" + * $ref: "#/components/schemas/BaseCustomerAddress" * phone: * type: string * title: phone @@ -69,6 +69,10 @@ * format: date-time * title: deleted_at * description: The date the customer was deleted. + * created_by: + * type: string + * title: created_by + * description: The customer's created by. * */ diff --git a/www/utils/generated/oas-output/schemas/StoreCustomerAddress.ts b/www/utils/generated/oas-output/schemas/StoreCustomerAddress.ts index cb10bb5228e5e..efdf6120d71ee 100644 --- a/www/utils/generated/oas-output/schemas/StoreCustomerAddress.ts +++ b/www/utils/generated/oas-output/schemas/StoreCustomerAddress.ts @@ -86,7 +86,7 @@ * description: The address's phone. * metadata: * type: object - * description: The address's metadata, can hold custom key-value pairs. + * description: The address's metadata, can hold custom key-value pairs. * created_at: * type: string * format: date-time diff --git a/www/utils/generated/oas-output/schemas/StoreOrderResponse.ts b/www/utils/generated/oas-output/schemas/StoreOrderResponse.ts index 40c4f78c2df99..b6f6238df9e0b 100644 --- a/www/utils/generated/oas-output/schemas/StoreOrderResponse.ts +++ b/www/utils/generated/oas-output/schemas/StoreOrderResponse.ts @@ -7,7 +7,9 @@ * - order * properties: * order: - * $ref: "#/components/schemas/StoreOrder" + * type: string + * title: order + * description: The order's details. * */ diff --git a/www/utils/generated/oas-output/schemas/StorePaymentCollection.ts b/www/utils/generated/oas-output/schemas/StorePaymentCollection.ts index c56619acec86f..4d03df9bc8cce 100644 --- a/www/utils/generated/oas-output/schemas/StorePaymentCollection.ts +++ b/www/utils/generated/oas-output/schemas/StorePaymentCollection.ts @@ -4,12 +4,12 @@ * description: The payment collection's details. * x-schemaName: StorePaymentCollection * required: + * - payment_providers * - id * - currency_code * - region_id * - amount * - status - * - payment_providers * properties: * id: * type: string @@ -19,32 +19,31 @@ * type: string * title: currency_code * description: The payment collection's currency code. - * example: usd * region_id: * type: string * title: region_id - * description: The ID of the associated region. + * description: The ID of the region this payment collection is associated with. * amount: * type: number * title: amount - * description: The payment collection's amount. + * description: The total amount to be paid. * authorized_amount: * type: number * title: authorized_amount - * description: The payment collection's authorized amount. + * description: The total authorized amount of the collection's payments. * captured_amount: * type: number * title: captured_amount - * description: The payment collection's captured amount. + * description: The total captured amount of the collection's payments. * refunded_amount: * type: number * title: refunded_amount - * description: The payment collection's refunded amount. + * description: The total refunded amount of the collection's payments. * completed_at: * type: string + * format: date-time * title: completed_at * description: The date the payment collection was completed. - * format: date-time * created_at: * type: string * format: date-time @@ -69,14 +68,14 @@ * - partially_authorized * payment_providers: * type: array - * description: The payment collection's payment providers. + * description: The payment provider used to process the collection's payments and sessions. * items: - * $ref: "#/components/schemas/BasePaymentProvider" + * $ref: "#/components/schemas/StorePaymentProvider" * payment_sessions: * type: array * description: The payment collection's payment sessions. * items: - * $ref: "#/components/schemas/BasePaymentSession" + * $ref: "#/components/schemas/StorePaymentSession" * payments: * type: array * description: The payment collection's payments. diff --git a/www/utils/generated/oas-output/schemas/StorePaymentProvider.ts b/www/utils/generated/oas-output/schemas/StorePaymentProvider.ts index 010d2d8553b9b..7d658ffe4b960 100644 --- a/www/utils/generated/oas-output/schemas/StorePaymentProvider.ts +++ b/www/utils/generated/oas-output/schemas/StorePaymentProvider.ts @@ -1,7 +1,7 @@ /** * @schema StorePaymentProvider * type: object - * description: The payment provider's details + * description: The payment provider's payment providers. * x-schemaName: StorePaymentProvider * required: * - id diff --git a/www/utils/generated/oas-output/schemas/StorePaymentSession.ts b/www/utils/generated/oas-output/schemas/StorePaymentSession.ts new file mode 100644 index 0000000000000..d92517147c3c4 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/StorePaymentSession.ts @@ -0,0 +1,63 @@ +/** + * @schema StorePaymentSession + * type: object + * description: The payment session's details. + * x-schemaName: StorePaymentSession + * properties: + * id: + * type: string + * title: id + * description: The payment session's ID. + * amount: + * type: number + * title: amount + * description: The payment session's amount. + * currency_code: + * type: string + * title: currency_code + * description: The payment session's currency code. + * example: usd + * provider_id: + * type: string + * title: provider_id + * description: The ID of the payment provider processing this session. + * data: + * type: object + * description: The payment session's data, useful for the payment provider processing the payment. + * externalDocs: + * url: https://docs.medusajs.com/v2/resources/commerce-modules/payment/payment-session#data-property + * context: + * type: object + * description: The context around the payment, such as the customer's details. + * example: + * customer: + * id: cus_123 + * status: + * type: string + * description: The payment session's status. + * enum: + * - authorized + * - captured + * - canceled + * - pending + * - requires_more + * - error + * authorized_at: + * type: string + * title: authorized_at + * description: The date the payment session was authorized. + * format: date-time + * payment_collection: + * $ref: "#/components/schemas/StorePaymentCollection" + * payment: + * $ref: "#/components/schemas/BasePayment" + * required: + * - id + * - amount + * - currency_code + * - provider_id + * - data + * - status + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/StoreProduct.ts b/www/utils/generated/oas-output/schemas/StoreProduct.ts index 4592f4f3efb54..36aedfd18b360 100644 --- a/www/utils/generated/oas-output/schemas/StoreProduct.ts +++ b/www/utils/generated/oas-output/schemas/StoreProduct.ts @@ -4,15 +4,14 @@ * description: The product's details. * x-schemaName: StoreProduct * required: + * - variants + * - options + * - images * - length * - title * - status - * - options * - description * - id - * - created_at - * - updated_at - * - variants * - handle * - subtitle * - is_giftcard @@ -26,9 +25,10 @@ * - material * - collection_id * - type_id - * - images * - discountable * - external_id + * - created_at + * - updated_at * - deleted_at * properties: * categories: @@ -58,7 +58,7 @@ * type: array * description: The product's options. * items: - * $ref: "#/components/schemas/BaseProductOption" + * $ref: "#/components/schemas/StoreProductOption" * description: * type: string * title: description @@ -84,7 +84,7 @@ * type: array * description: The product's variants. * items: - * $ref: "#/components/schemas/BaseProductVariant" + * $ref: "#/components/schemas/StoreProductVariant" * handle: * type: string * title: handle diff --git a/www/utils/generated/oas-output/schemas/StoreProductImage.ts b/www/utils/generated/oas-output/schemas/StoreProductImage.ts new file mode 100644 index 0000000000000..c6bcf8a182413 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/StoreProductImage.ts @@ -0,0 +1,38 @@ +/** + * @schema StoreProductImage + * type: object + * description: The image's images. + * x-schemaName: StoreProductImage + * required: + * - id + * - url + * properties: + * id: + * type: string + * title: id + * description: The image's ID. + * url: + * type: string + * title: url + * description: The image's url. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The image's created at. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The image's updated at. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The image's deleted at. + * metadata: + * type: object + * description: The image's metadata. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/StoreProductOption.ts b/www/utils/generated/oas-output/schemas/StoreProductOption.ts new file mode 100644 index 0000000000000..b333f3e50d0fa --- /dev/null +++ b/www/utils/generated/oas-output/schemas/StoreProductOption.ts @@ -0,0 +1,49 @@ +/** + * @schema StoreProductOption + * type: object + * description: The product option's details. + * x-schemaName: StoreProductOption + * properties: + * id: + * type: string + * title: id + * description: The option's ID. + * title: + * type: string + * title: title + * description: The option's title. + * product: + * $ref: "#/components/schemas/StoreProduct" + * product_id: + * type: string + * title: product_id + * description: The option's product id. + * values: + * type: array + * description: The option's values. + * items: + * $ref: "#/components/schemas/StoreProductOptionValue" + * metadata: + * type: object + * description: The option's metadata. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The option's created at. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The option's updated at. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The option's deleted at. + * required: + * - title + * - id + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/StoreProductOptionValue.ts b/www/utils/generated/oas-output/schemas/StoreProductOptionValue.ts new file mode 100644 index 0000000000000..1ce6191248f46 --- /dev/null +++ b/www/utils/generated/oas-output/schemas/StoreProductOptionValue.ts @@ -0,0 +1,44 @@ +/** + * @schema StoreProductOptionValue + * type: object + * description: The product option value's details. + * x-schemaName: StoreProductOptionValue + * required: + * - value + * - id + * properties: + * id: + * type: string + * title: id + * description: The value's ID. + * value: + * type: string + * title: value + * description: The value. + * option: + * $ref: "#/components/schemas/StoreProductOption" + * option_id: + * type: string + * title: option_id + * description: The ID of the option this value belongs to. + * metadata: + * type: object + * description: The value's metadata, can hold custom key-value pairs. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The date the value was created. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The date the value was updated. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The date the value was deleted. + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/StoreProductVariant.ts b/www/utils/generated/oas-output/schemas/StoreProductVariant.ts index a0ff3dde3e998..9df862153abff 100644 --- a/www/utils/generated/oas-output/schemas/StoreProductVariant.ts +++ b/www/utils/generated/oas-output/schemas/StoreProductVariant.ts @@ -1,7 +1,7 @@ /** * @schema StoreProductVariant * type: object - * description: The variant's details. + * description: The variant's variants. * x-schemaName: StoreProductVariant * properties: * options: @@ -11,36 +11,21 @@ * $ref: "#/components/schemas/StoreProductOptionValue" * product: * $ref: "#/components/schemas/StoreProduct" - * id: - * type: string - * title: id - * description: The variant's ID. - * metadata: - * type: object - * description: The variant's metadata, can hold custom key-value pairs. - * created_at: - * type: string - * format: date-time - * title: created_at - * description: The date the variant was created. - * updated_at: - * type: string - * format: date-time - * title: updated_at - * description: The date the variant was updated. + * length: + * type: number + * title: length + * description: The variant's length. * title: * type: string * title: title * description: The variant's title. - * product_id: - * type: string - * title: product_id - * description: The ID of the product that the variant belongs to. - * deleted_at: + * metadata: + * type: object + * description: The variant's metadata. + * id: * type: string - * format: date-time - * title: deleted_at - * description: The date the variant was deleted. + * title: id + * description: The variant's ID. * width: * type: number * title: width @@ -49,10 +34,6 @@ * type: number * title: weight * description: The variant's weight. - * length: - * type: number - * title: length - * description: The variant's length. * height: * type: number * title: height @@ -64,19 +45,38 @@ * hs_code: * type: string * title: hs_code - * description: The variant's HS code. + * description: The variant's hs code. * mid_code: * type: string * title: mid_code - * description: The variant's MID code. + * description: The variant's mid code. * material: * type: string * title: material * description: The variant's material. + * created_at: + * type: string + * format: date-time + * title: created_at + * description: The variant's created at. + * updated_at: + * type: string + * format: date-time + * title: updated_at + * description: The variant's updated at. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The variant's deleted at. + * product_id: + * type: string + * title: product_id + * description: The variant's product id. * sku: * type: string * title: sku - * description: The variant's SKU. + * description: The variant's sku. * barcode: * type: string * title: barcode @@ -84,50 +84,44 @@ * ean: * type: string * title: ean - * description: The variant's EAN. + * description: The variant's ean. * upc: * type: string * title: upc - * description: The variant's UPC. + * description: The variant's upc. * allow_backorder: * type: boolean * title: allow_backorder - * description: Whether the variant can be ordered even if it's not in stock. + * description: The variant's allow backorder. * manage_inventory: * type: boolean * title: manage_inventory - * description: Whether Medusa manages the variant's inventory. If disabled, the variant is always considered in stock. - * externalDocs: - * url: https://docs.medusajs.com/v2/resources/storefront-development/products/inventory - * description: "Storefront guide: How to retrieve a product variant's inventory details." + * description: The variant's manage inventory. * inventory_quantity: * type: number * title: inventory_quantity - * description: The variant's inventory quantity. This property is only available if you pass `+variants.inventory_quantity` in the `fields` query parameter. - * externalDocs: - * url: https://docs.medusajs.com/v2/resources/storefront-development/products/inventory - * description: "Storefront guide: How to retrieve a product variant's inventory details." + * description: The variant's inventory quantity. * variant_rank: * type: number * title: variant_rank - * description: The variant's rank among its siblings. + * description: The variant's variant rank. * calculated_price: * $ref: "#/components/schemas/BaseCalculatedPriceSet" * required: * - options - * - id - * - created_at - * - updated_at + * - length * - title - * - deleted_at + * - id * - width * - weight - * - length * - height * - origin_country * - hs_code * - mid_code * - material + * - created_at + * - updated_at + * - deleted_at * - sku * - barcode * - ean diff --git a/www/utils/generated/oas-output/schemas/StoreRegion.ts b/www/utils/generated/oas-output/schemas/StoreRegion.ts index d4692b685d4cf..3723fbc60592d 100644 --- a/www/utils/generated/oas-output/schemas/StoreRegion.ts +++ b/www/utils/generated/oas-output/schemas/StoreRegion.ts @@ -1,7 +1,7 @@ /** * @schema StoreRegion * type: object - * description: The region's details. + * description: The parent's region. * x-schemaName: StoreRegion * required: * - id @@ -20,11 +20,10 @@ * type: string * title: currency_code * description: The region's currency code. - * example: usd * automatic_taxes: * type: boolean * title: automatic_taxes - * description: Whether taxes are calculated automatically during checkout for carts that belong to this region. + * description: The region's automatic taxes. * countries: * type: array * description: The region's countries. @@ -37,17 +36,17 @@ * $ref: "#/components/schemas/AdminPaymentProvider" * metadata: * type: object - * description: The region's metadata, can hold custom key-value pairs. + * description: The region's metadata. * created_at: * type: string * format: date-time * title: created_at - * description: The date the region was created. + * description: The region's created at. * updated_at: * type: string * format: date-time * title: updated_at - * description: The date the region was updated. + * description: The region's updated at. * */ diff --git a/www/utils/generated/oas-output/schemas/StoreReturn.ts b/www/utils/generated/oas-output/schemas/StoreReturn.ts index f023733d355c9..daeda73903bee 100644 --- a/www/utils/generated/oas-output/schemas/StoreReturn.ts +++ b/www/utils/generated/oas-output/schemas/StoreReturn.ts @@ -4,11 +4,11 @@ * description: The return's details. * x-schemaName: StoreReturn * required: + * - items * - id * - order_id * - order_version * - display_id - * - items * - received_at * - created_at * - canceled_at @@ -22,8 +22,22 @@ * title: order_id * description: The ID of the order this return is created for. * status: - * type: string - * title: status + * oneOf: + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. + * - type: string + * title: status + * description: The return's status. * description: The return's status. * exchange_id: * type: string @@ -57,7 +71,7 @@ * type: array * description: The return's items. * items: - * $ref: "#/components/schemas/BaseReturnItem" + * $ref: "#/components/schemas/StoreReturnItem" * received_at: * type: string * title: received_at diff --git a/www/utils/generated/oas-output/schemas/StoreReturnItem.ts b/www/utils/generated/oas-output/schemas/StoreReturnItem.ts new file mode 100644 index 0000000000000..dfa8e6f70b8cd --- /dev/null +++ b/www/utils/generated/oas-output/schemas/StoreReturnItem.ts @@ -0,0 +1,51 @@ +/** + * @schema StoreReturnItem + * type: object + * description: The item's items. + * x-schemaName: StoreReturnItem + * properties: + * id: + * type: string + * title: id + * description: The item's ID. + * quantity: + * type: number + * title: quantity + * description: The item's quantity. + * received_quantity: + * type: number + * title: received_quantity + * description: The item's received quantity. + * damaged_quantity: + * type: number + * title: damaged_quantity + * description: The item's damaged quantity. + * reason_id: + * type: string + * title: reason_id + * description: The item's reason id. + * note: + * type: string + * title: note + * description: The item's note. + * item_id: + * type: string + * title: item_id + * description: The item's item id. + * return_id: + * type: string + * title: return_id + * description: The item's return id. + * metadata: + * type: object + * description: The item's metadata. + * required: + * - id + * - quantity + * - received_quantity + * - damaged_quantity + * - item_id + * - return_id + * +*/ + diff --git a/www/utils/generated/oas-output/schemas/StoreShippingOption.ts b/www/utils/generated/oas-output/schemas/StoreShippingOption.ts index d1a177d67e375..127ddb58355f6 100644 --- a/www/utils/generated/oas-output/schemas/StoreShippingOption.ts +++ b/www/utils/generated/oas-output/schemas/StoreShippingOption.ts @@ -5,69 +5,49 @@ * x-schemaName: StoreShippingOption * required: * - id - * - name - * - price_type - * - service_zone_id - * - provider_id - * - provider - * - shipping_option_type_id - * - type - * - shipping_profile_id - * - amount - * - is_tax_inclusive - * - data - * - metadata + * - label + * - description + * - code + * - shipping_option_id + * - created_at + * - updated_at + * - deleted_at * properties: * id: * type: string * title: id * description: The shipping option's ID. - * name: + * label: * type: string - * title: name - * description: The shipping option's name. - * price_type: + * title: label + * description: The type's label. + * description: * type: string - * description: The shipping option's price type. If it's `flat`, the price is fixed and is set in the `prices` property. If it's `calculated`, the price is calculated on checkout by the associated fulfillment provider. - * enum: - * - flat - * - calculated - * service_zone_id: + * title: description + * description: The type's description. + * code: * type: string - * title: service_zone_id - * description: The ID of the service zone the shipping option belongs to. - * provider_id: + * title: code + * description: The type's code. + * shipping_option_id: * type: string - * title: provider_id - * description: The ID of the fulfillment provider handling this option. - * provider: - * $ref: "#/components/schemas/BaseFulfillmentProvider" - * shipping_option_type_id: + * title: shipping_option_id + * description: The type's shipping option id. + * created_at: * type: string - * title: shipping_option_type_id - * description: The ID of the shipping option's type. - * type: - * $ref: "#/components/schemas/StoreShippingOption" - * shipping_profile_id: + * format: date-time + * title: created_at + * description: The type's created at. + * updated_at: * type: string - * title: shipping_profile_id - * description: The ID of the associated shipping profile. - * amount: - * type: number - * title: amount - * description: The shipping option's amount. - * is_tax_inclusive: - * type: boolean - * title: is_tax_inclusive - * description: Whether the amount includes taxes. - * data: - * type: object - * description: The shipping option's data, useful for the provider handling fulfillment. - * externalDocs: - * url: https://docs.medusajs.com/v2/resources/commerce-modules/fulfillment/shipping-option#data-property - * metadata: - * type: object - * description: The shipping option's metadata, can hold custom key-value pairs. + * format: date-time + * title: updated_at + * description: The type's updated at. + * deleted_at: + * type: string + * format: date-time + * title: deleted_at + * description: The type's deleted at. * */