diff --git a/www/apps/api-reference/specs/admin/code_samples/JavaScript/admin_users/get.js b/www/apps/api-reference/specs/admin/code_samples/JavaScript/admin_users/get.js index d703d64f1b..09fb52748f 100644 --- a/www/apps/api-reference/specs/admin/code_samples/JavaScript/admin_users/get.js +++ b/www/apps/api-reference/specs/admin/code_samples/JavaScript/admin_users/get.js @@ -2,6 +2,6 @@ import Medusa from "@medusajs/medusa-js" const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token medusa.admin.users.list() -.then(({ users }) => { +.then(({ users, limit, offset, count }) => { console.log(users.length); }) diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_auth/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_confirm/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_confirm/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_confirm/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_batch-jobs_{id}_confirm/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_collections_{id}_products_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies_{code}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies_{code}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies_{code}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_currencies_{code}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customer-groups_{id}_customers_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_customers_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_code_{code}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_code_{code}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_code_{code}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_code_{code}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes_{code}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes_{code}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes_{code}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_dynamic-codes_{code}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_discounts_{id}_regions_{region_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_pay/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_pay/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_pay/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_draft-orders_{id}_pay/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_gift-cards_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_accept/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_accept/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_accept/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_accept/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}_resend/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}_resend/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}_resend/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_invites_{invite_id}_resend/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_notes_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications_{id}_resend/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications_{id}_resend/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications_{id}_resend/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_notifications_{id}_resend/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_changes_{change_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_changes_{change_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_changes_{change_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_changes_{change_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_confirm/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_confirm/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_confirm/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_confirm/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_items_{item_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_request/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_request/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_request/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_order-edits_{id}_request/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_archive/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_archive/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_archive/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_archive/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_capture/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_capture/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_capture/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_capture/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_shipments/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_shipments/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_shipments/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_claims_{claim_id}_shipments/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_complete/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_complete/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_complete/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_complete/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillment/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillment/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillment/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillment/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_refund/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_refund/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_refund/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_refund/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_return/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_return/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_return/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_return/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipment/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipment/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipment/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipment/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipping-methods/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipping-methods/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipping-methods/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_shipping-methods/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_process-payment/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_process-payment/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_process-payment/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_process-payment/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_shipments/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_shipments/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_shipments/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_shipments/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}_authorize/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}_authorize/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}_authorize/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_payment-collections_{id}_authorize/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_capture/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_capture/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_capture/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_capture/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_refund/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_refund/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_refund/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_payments_{id}_refund/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_prices_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_prices_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_prices_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_prices_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_prices_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_{product_id}_prices/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_{product_id}_prices/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_{product_id}_prices/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_products_{product_id}_prices/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_variants_{variant_id}_prices/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_variants_{variant_id}_prices/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_variants_{variant_id}_prices/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_price-lists_{id}_variants_{variant_id}_prices/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-categories_{id}_products_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-tags/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-tags/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-tags/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-tags/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-types/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-types/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-types/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_product-types/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_tag-usage/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_tag-usage/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_tag-usage/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_tag-usage/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_options_{option_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_products_{id}_variants_{variant_id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_revoke/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_revoke/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_revoke/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_revoke/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries_{country_code}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries_{country_code}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries_{country_code}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_countries_{country_code}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-options/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-options/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-options/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-options/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers_{provider_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers_{provider_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers_{provider_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_fulfillment-providers_{provider_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers_{provider_id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers_{provider_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers_{provider_id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_regions_{id}_payment-providers_{provider_id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_reservations_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_return-reasons_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_cancel/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_cancel/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_cancel/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_cancel/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_receive/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_receive/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_receive/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_returns_{id}_receive/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_products_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_sales-channels_{id}_stock-locations/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-options_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_shipping-profiles_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_stock-locations_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_store/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_currencies_{code}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_payment-providers/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_payment-providers/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_payment-providers/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_payment-providers/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_tax-providers/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_tax-providers/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_tax-providers/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_store_tax-providers/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_swaps_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_product-types_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_products_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_download-url/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_download-url/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_download-url/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_download-url/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_protected/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_protected/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_protected/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_uploads_protected/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_users/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_password-token/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_password-token/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_password-token/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_password-token/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_reset-password/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_reset-password/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_reset-password/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_reset-password/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/deleteundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/deleteundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/delete.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/postundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/postundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_users_{id}/post.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}/get.tsx diff --git a/www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}_inventory/getundefined b/www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}_inventory/get.tsx similarity index 100% rename from www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}_inventory/getundefined rename to www/apps/api-reference/specs/admin/code_samples/tsx/admin_variants_{id}_inventory/get.tsx diff --git a/www/apps/api-reference/specs/admin/components/schemas/AdminUsersListRes.yaml b/www/apps/api-reference/specs/admin/components/schemas/AdminUsersListRes.yaml index 205583a405..689c7d6608 100644 --- a/www/apps/api-reference/specs/admin/components/schemas/AdminUsersListRes.yaml +++ b/www/apps/api-reference/specs/admin/components/schemas/AdminUsersListRes.yaml @@ -2,9 +2,21 @@ type: object description: The list of users. required: - users + - count + - offset + - limit properties: users: type: array description: An array of users details. items: $ref: ./User.yaml + count: + type: integer + description: The total number of items available + offset: + type: integer + description: The number of users skipped when retrieving the users. + limit: + type: integer + description: The number of items per page diff --git a/www/apps/api-reference/specs/admin/openapi.full.yaml b/www/apps/api-reference/specs/admin/openapi.full.yaml index b305e0c33c..3408eae5cd 100644 --- a/www/apps/api-reference/specs/admin/openapi.full.yaml +++ b/www/apps/api-reference/specs/admin/openapi.full.yaml @@ -5,348 +5,236 @@ info: license: name: MIT url: https://github.com/medusajs/medusa/blob/master/LICENSE +servers: + - url: http://localhost:9000 + - url: https://api.medusa-commerce.com tags: - name: Apps Oauth - description: > - Some plugins may require to authenticate with third-party services and - store authentication details, such as the authentication token. To do - that, they can create an Oauth provider within the plugin that handles the - authentication. - - The Apps Oauth API Routes allows admins to manage and generate token for - an app using its oauth provider. + description: | + Some plugins may require to authenticate with third-party services and store authentication details, such as the authentication token. To do that, they can create an Oauth provider within the plugin that handles the authentication. + The Apps Oauth API Routes allows admins to manage and generate token for an app using its oauth provider. - name: Auth - description: > - Authentication API Routes allow admin users to manage their session, such - as login or log out. - - When an admin user is logged in, the cookie header is set indicating the - admin's login session. + description: | + Authentication API Routes allow admin users to manage their session, such as login or log out. + When an admin user is logged in, the cookie header is set indicating the admin's login session. externalDocs: description: How to implement user profiles url: https://docs.medusajs.com/modules/users/admin/manage-profile - name: Batch Jobs - description: > - A batch job is a task that is performed by the Medusa backend - asynchronusly. For example, the Import Product feature is implemented - using batch jobs. - - Batch Job API Routes allow admins to manage the batch jobs and their - state. + description: | + A batch job is a task that is performed by the Medusa backend asynchronusly. For example, the Import Product feature is implemented using batch jobs. + Batch Job API Routes allow admins to manage the batch jobs and their state. externalDocs: description: How to import products url: https://docs.medusajs.com/modules/products/admin/import-products - name: Currencies - description: > - A store can use unlimited currencies, and each region must be associated - with at least one currency. - - Currencies are defined within the Medusa backend. Currency API Routes - allow admins to list and update currencies. + description: | + A store can use unlimited currencies, and each region must be associated with at least one currency. + Currencies are defined within the Medusa backend. Currency API Routes allow admins to list and update currencies. externalDocs: description: How to manage currencies - url: >- - https://docs.medusajs.com/modules/regions-and-currencies/admin/manage-currencies + url: https://docs.medusajs.com/modules/regions-and-currencies/admin/manage-currencies - name: Customers - description: > - Customers can either be created when they register through the Store APIs, - or created by the admin using the Admin APIs. + description: | + Customers can either be created when they register through the Store APIs, or created by the admin using the Admin APIs. externalDocs: description: How to manage customers url: https://docs.medusajs.com/modules/customers/admin/manage-customers - name: Customer Groups - description: > - Customer Groups can be used to organize customers that share similar data - or attributes into dedicated groups. - - This can be useful for different purposes such as setting a different - price for a specific customer group. + description: | + Customer Groups can be used to organize customers that share similar data or attributes into dedicated groups. + This can be useful for different purposes such as setting a different price for a specific customer group. externalDocs: description: How to manage customer groups url: https://docs.medusajs.com/modules/customers/admin/manage-customer-groups - name: Discounts - description: > - Admins can create discounts with conditions and rules, providing them with - advanced settings for variety of cases. - - The Discount API Routes can be used to manage discounts, their conditions, - resources, and more. + description: | + Admins can create discounts with conditions and rules, providing them with advanced settings for variety of cases. + The Discount API Routes can be used to manage discounts, their conditions, resources, and more. externalDocs: description: How to manage discounts url: https://docs.medusajs.com/modules/discounts/admin/manage-discounts - name: Draft Orders - description: > - A draft order is an order created manually by the admin. It allows admins - to create orders without direct involvement from the customer. + description: | + A draft order is an order created manually by the admin. It allows admins to create orders without direct involvement from the customer. externalDocs: description: How to manage draft orders url: https://docs.medusajs.com/modules/orders/admin/manage-draft-orders - name: Gift Cards - description: > - Admins can create gift cards and send them directly to customers, - specifying options like their balance, region, and more. - - These gift cards are different than the saleable gift cards in a store, - which are created and managed through Product API Routes. + description: | + Admins can create gift cards and send them directly to customers, specifying options like their balance, region, and more. + These gift cards are different than the saleable gift cards in a store, which are created and managed through Product API Routes. externalDocs: description: How to manage gift cards - url: >- - https://docs.medusajs.com/modules/gift-cards/admin/manage-gift-cards#manage-custom-gift-cards + url: https://docs.medusajs.com/modules/gift-cards/admin/manage-gift-cards#manage-custom-gift-cards - name: Inventory Items - description: > - Inventory items, provided by the [Inventory - Module](https://docs.medusajs.com/modules/multiwarehouse/inventory-module), - can be used to manage the inventory of saleable items in your store. + description: | + Inventory items, provided by the [Inventory Module](https://docs.medusajs.com/modules/multiwarehouse/inventory-module), can be used to manage the inventory of saleable items in your store. externalDocs: description: How to manage inventory items - url: >- - https://docs.medusajs.com/modules/multiwarehouse/admin/manage-inventory-items + url: https://docs.medusajs.com/modules/multiwarehouse/admin/manage-inventory-items - name: Invites - description: > - An admin can invite new users to manage their team. This would allow new - users to authenticate as admins and perform admin functionalities. + description: | + An admin can invite new users to manage their team. This would allow new users to authenticate as admins and perform admin functionalities. externalDocs: description: How to manage invites url: https://docs.medusajs.com/modules/users/admin/manage-invites - name: Notes - description: > - Notes are created by admins and can be associated with any resource. For - example, an admin can add a note to an order for additional details or - remarks. + description: | + Notes are created by admins and can be associated with any resource. For example, an admin can add a note to an order for additional details or remarks. - name: Notifications - description: > - Notifications are sent to customers to inform them of new updates. For - example, a notification can be sent to the customer when their order is - place or its state is updated. - - The notification's type, such as an email or SMS, is determined by the - notification provider installed on the Medusa backend. + description: | + Notifications are sent to customers to inform them of new updates. For example, a notification can be sent to the customer when their order is place or its state is updated. + The notification's type, such as an email or SMS, is determined by the notification provider installed on the Medusa backend. - name: Orders - description: > - Orders are purchases made by customers, typically through a storefront - using the Store API. Draft orders created by the admin are also - transformed to an Order once the payment is captured. - - Managing orders include managing fulfillment, payment, claims, - reservations, and more. + description: | + Orders are purchases made by customers, typically through a storefront using the Store API. Draft orders created by the admin are also transformed to an Order once the payment is captured. + Managing orders include managing fulfillment, payment, claims, reservations, and more. externalDocs: description: How to manage orders url: https://docs.medusajs.com/modules/orders/admin/manage-orders - name: Order Edits - description: > - An admin can edit an order to remove, add, or update an item's quantity. - When an admin edits an order, they're stored as an `OrderEdit`. + description: | + An admin can edit an order to remove, add, or update an item's quantity. When an admin edits an order, they're stored as an `OrderEdit`. externalDocs: description: How to edit an order url: https://docs.medusajs.com/modules/orders/admin/edit-order - name: Payments - description: > - A payment can be related to an order, swap, return, or more. It can be - captured or refunded. + description: | + A payment can be related to an order, swap, return, or more. It can be captured or refunded. - name: Payment Collections - description: > - A payment collection is useful for managing additional payments, such as - for Order Edits, or installment payments. + description: | + A payment collection is useful for managing additional payments, such as for Order Edits, or installment payments. - name: Price Lists - description: > - A price list are special prices applied to products based on a set of - conditions, such as customer group. + description: | + A price list are special prices applied to products based on a set of conditions, such as customer group. externalDocs: description: How to manage price lists url: https://docs.medusajs.com/modules/price-lists/admin/manage-price-lists - name: Products - description: > - Products are saleable items in a store. This also includes [saleable gift - cards](https://docs.medusajs.com/modules/gift-cards/admin/manage-gift-cards#manage-gift-card-product) - in a store. + description: | + Products are saleable items in a store. This also includes [saleable gift cards](https://docs.medusajs.com/modules/gift-cards/admin/manage-gift-cards#manage-gift-card-product) in a store. externalDocs: description: How to manage products url: https://docs.medusajs.com/modules/products/admin/manage-products - name: Product Categories - description: > - Products can be categoriezed into categories. A product can be added into - more than one category. + description: | + Products can be categoriezed into categories. A product can be added into more than one category. externalDocs: description: How to manage product categories url: https://docs.medusajs.com/modules/products/admin/manage-categories - name: Product Collections - description: > - A product collection is used to organize products for different purposes - such as marketing or discount purposes. For example, you can create a - Summer Collection. + description: | + A product collection is used to organize products for different purposes such as marketing or discount purposes. For example, you can create a Summer Collection. - name: Product Tags - description: > - Product tags are string values created when you create or update a product - with a new tag. - - Products can have more than one tag, and products can share tags. This - allows admins to associate products to similar tags that can be used to - filter products. + description: | + Product tags are string values created when you create or update a product with a new tag. + Products can have more than one tag, and products can share tags. This allows admins to associate products to similar tags that can be used to filter products. - name: Product Types - description: > - Product types are string values created when you create or update a - product with a new type. - - Products can have one type, and products can share types. This allows - admins to associate products with a type that can be used to filter - products. + description: | + Product types are string values created when you create or update a product with a new type. + Products can have one type, and products can share types. This allows admins to associate products with a type that can be used to filter products. - name: Product Variants - description: > - Product variants are the actual salable item in your store. Each variant - is a combination of the different option values available on the product. - + description: | + Product variants are the actual salable item in your store. Each variant is a combination of the different option values available on the product. Product variants can be managed through the Products API Routes. externalDocs: description: How to manage product variants - url: >- - https://docs.medusajs.com/modules/products/admin/manage-products#manage-product-variants + url: https://docs.medusajs.com/modules/products/admin/manage-products#manage-product-variants - name: Publishable API Keys - description: > - Publishable API Keys can be used to scope Store API calls with an API key, - determining what resources are retrieved when querying the API. - - For example, a publishable API key can be associated with one or more - sales channels. When it is passed in the header of a request to the List - Product store API Route, - - the sales channels are inferred from the key and only products associated - with those sales channels are retrieved. - - Admins can manage publishable API keys and their associated resources. - Currently, only Sales Channels are supported as a resource. + description: | + Publishable API Keys can be used to scope Store API calls with an API key, determining what resources are retrieved when querying the API. + For example, a publishable API key can be associated with one or more sales channels. When it is passed in the header of a request to the List Product store API Route, + the sales channels are inferred from the key and only products associated with those sales channels are retrieved. + Admins can manage publishable API keys and their associated resources. Currently, only Sales Channels are supported as a resource. externalDocs: description: How to manage publishable API keys - url: >- - https://docs.medusajs.com/development/publishable-api-keys/admin/manage-publishable-api-keys + url: https://docs.medusajs.com/development/publishable-api-keys/admin/manage-publishable-api-keys - name: Reservations - description: > - Reservations, provided by the [Inventory - Module](https://docs.medusajs.com/modules/multiwarehouse/inventory-module), - are quantities of an item that are reserved, typically when an order is - placed but not yet fulfilled. - - Reservations can be associated with any resources, but commonly with line - items of an order. + description: | + Reservations, provided by the [Inventory Module](https://docs.medusajs.com/modules/multiwarehouse/inventory-module), are quantities of an item that are reserved, typically when an order is placed but not yet fulfilled. + Reservations can be associated with any resources, but commonly with line items of an order. externalDocs: description: How to manage item allocations in orders - url: >- - https://docs.medusajs.com/modules/multiwarehouse/admin/manage-item-allocations-in-orders + url: https://docs.medusajs.com/modules/multiwarehouse/admin/manage-item-allocations-in-orders - name: Regions - description: > - Regions are different countries or geographical regions that the commerce - store serves customers in. - + description: | + Regions are different countries or geographical regions that the commerce store serves customers in. Admins can manage these regions, their providers, and more. externalDocs: description: How to manage regions - url: >- - https://docs.medusajs.com/modules/regions-and-currencies/admin/manage-regions + url: https://docs.medusajs.com/modules/regions-and-currencies/admin/manage-regions - name: Return Reasons - description: > - Return reasons are key-value pairs that are used to specify why an order - return is being created. - - Admins can manage available return reasons, and they can be used by both - admins and customers when creating a return. + description: | + Return reasons are key-value pairs that are used to specify why an order return is being created. + Admins can manage available return reasons, and they can be used by both admins and customers when creating a return. externalDocs: description: How to manage return reasons - url: >- - https://docs.medusajs.com/modules/orders/admin/manage-returns#manage-return-reasons + url: https://docs.medusajs.com/modules/orders/admin/manage-returns#manage-return-reasons - name: Returns - description: > - A return can be created by a customer or an admin to return items in an - order. - + description: | + A return can be created by a customer or an admin to return items in an order. Admins can manage these returns and change their state. externalDocs: description: How to manage returns url: https://docs.medusajs.com/modules/orders/admin/manage-returns - name: Sales Channels - description: > - A sales channel indicates a channel where products can be sold in. For - example, a webshop or a mobile app. - + description: | + A sales channel indicates a channel where products can be sold in. For example, a webshop or a mobile app. Admins can manage sales channels and the products available in them. externalDocs: description: How to manage sales channels url: https://docs.medusajs.com/modules/sales-channels/admin/manage - name: Shipping Options - description: > - A shipping option is used to define the available shipping methods during - checkout or when creating a return. - - Admins can create an unlimited number of shipping options, each associated - with a shipping profile and fulfillment provider, among other resources. + description: | + A shipping option is used to define the available shipping methods during checkout or when creating a return. + Admins can create an unlimited number of shipping options, each associated with a shipping profile and fulfillment provider, among other resources. externalDocs: description: Shipping Option architecture - url: >- - https://docs.medusajs.com/modules/carts-and-checkout/shipping#shipping-option + url: https://docs.medusajs.com/modules/carts-and-checkout/shipping#shipping-option - name: Shipping Profiles - description: > - A shipping profile is used to group products that can be shipped in the - same manner. - - They are created by the admin and they're not associated with a - fulfillment provider. + description: | + A shipping profile is used to group products that can be shipped in the same manner. + They are created by the admin and they're not associated with a fulfillment provider. externalDocs: description: Shipping Profile architecture - url: >- - https://docs.medusajs.com/modules/carts-and-checkout/shipping#shipping-profile + url: https://docs.medusajs.com/modules/carts-and-checkout/shipping#shipping-profile - name: Stock Locations - description: > - A stock location, provided by the [Stock Location - module](https://docs.medusajs.com/modules/multiwarehouse/stock-location-module), - indicates a physical address that stock-kept items, such as physical - products, can be stored in. - + description: | + A stock location, provided by the [Stock Location module](https://docs.medusajs.com/modules/multiwarehouse/stock-location-module), indicates a physical address that stock-kept items, such as physical products, can be stored in. An admin can create and manage available stock locations. externalDocs: description: How to manage stock locations. - url: >- - https://docs.medusajs.com/modules/multiwarehouse/admin/manage-stock-locations + url: https://docs.medusajs.com/modules/multiwarehouse/admin/manage-stock-locations - name: Store - description: > - A store indicates the general configurations and details about the - commerce store. By default, there's only one store in the Medusa backend. - + description: | + A store indicates the general configurations and details about the commerce store. By default, there's only one store in the Medusa backend. Admins can manage the store and its details or configurations. - name: Swaps - description: > - A swap is created by a customer or an admin to exchange an item with a new - one. - - Creating a swap implicitely includes creating a return for the item being - exchanged. + description: | + A swap is created by a customer or an admin to exchange an item with a new one. + Creating a swap implicitely includes creating a return for the item being exchanged. externalDocs: description: How to manage swaps url: https://docs.medusajs.com/modules/orders/admin/manage-swaps - name: Tax Rates - description: > - Each region has at least a default tax rate. Admins can create and manage - additional tax rates that can be applied for certain conditions, such as - for specific product types. + description: | + Each region has at least a default tax rate. Admins can create and manage additional tax rates that can be applied for certain conditions, such as for specific product types. externalDocs: description: How to manage tax rates url: https://docs.medusajs.com/modules/taxes/admin/manage-tax-rates - name: Uploads - description: > - The upload API Routes are used to upload any type of resources. For - example, they can be used to upload CSV files that are used to import - products into the store. + description: | + The upload API Routes are used to upload any type of resources. For example, they can be used to upload CSV files that are used to import products into the store. externalDocs: description: How to upload CSV file when importing a product. - url: >- - https://docs.medusajs.com/modules/products/admin/import-products#1-upload-csv-file + url: https://docs.medusajs.com/modules/products/admin/import-products#1-upload-csv-file - name: Users - description: > - A store can have more than one user, each having the same privileges. - Admins can manage users, their passwords, and more. + description: | + A store can have more than one user, each having the same privileges. Admins can manage users, their passwords, and more. externalDocs: description: How to manage users url: https://docs.medusajs.com/modules/users/admin/manage-users -servers: - - url: http://localhost:9000 - - url: https://api.medusa-commerce.com paths: /admin/apps: get: @@ -391,9 +279,7 @@ paths: post: operationId: PostApps summary: Generate Token for App - description: >- - Use an app's Oauth provider to generate and store a new token for - authentication. + description: Use an app's Oauth provider to generate and store a new token for authentication. x-authenticated: true requestBody: content: @@ -450,16 +336,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.auth.getSession() - .then(({ user }) => { console.log(user.id); }) @@ -515,12 +396,7 @@ paths: operationId: PostAuth summary: User Login x-authenticated: false - description: >- - Log a User in and includes the Cookie session in the response header. - The cookie session can be used in subsequent requests to authorize the - user to perform admin functionalities. When using Medusa's JS or Medusa - React clients, the cookie is automatically attached to subsequent - requests. + description: Log a User in and includes the Cookie session in the response header. The cookie session can be used in subsequent requests to authorize the user to perform admin functionalities. When using Medusa's JS or Medusa React clients, the cookie is automatically attached to subsequent requests. requestBody: content: application/json: @@ -531,17 +407,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.admin.auth.createSession({ email: "user@example.com", password: "supersecret" }) - .then(({ user }) => { console.log(user.id); }) @@ -604,24 +476,16 @@ paths: operationId: DeleteAuth summary: User Logout x-authenticated: true - description: >- - Delete the current session for the logged in user. This will only work - if you're using Cookie session for authentication. If the API token is - still passed in the header, the user is still authorized to perform - admin functionalities in other API Routes. + description: Delete the current session for the logged in user. This will only work if you're using Cookie session for authentication. If the API token is still passed in the header, the user is still authorized to perform admin functionalities in other API Routes. x-codegen: method: deleteSession x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in - medusa.admin.auth.deleteSession() - lang: tsx label: Medusa React @@ -676,9 +540,7 @@ paths: operationId: PostToken summary: User Login (JWT) x-authenticated: false - description: >- - After a successful login, a JWT token is returned, which can be used to - send authenticated requests. + description: After a successful login, a JWT token is returned, which can be used to send authenticated requests. requestBody: content: application/json: @@ -689,17 +551,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.admin.auth.getToken({ email: 'user@example.com', password: 'supersecret' }) - .then(({ access_token }) => { console.log(access_token); }) @@ -737,10 +595,7 @@ paths: get: operationId: GetBatchJobs summary: List Batch Jobs - description: >- - Retrieve a list of Batch Jobs. The batch jobs can be filtered by fields - such as `type` or `confirmed_at`. The batch jobs can also be sorted or - paginated. + description: Retrieve a list of Batch Jobs. The batch jobs can be filtered by fields such as `type` or `confirmed_at`. The batch jobs can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -904,16 +759,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - batch jobs. + description: Comma-separated relations that should be expanded in the returned batch jobs. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned batch - jobs. + description: Comma-separated fields that should be included in the returned batch jobs. schema: type: string - in: query @@ -970,16 +821,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.batchJobs.list() - .then(({ batch_jobs, limit, offset, count }) => { console.log(batch_jobs.length) }) @@ -1048,15 +894,10 @@ paths: post: operationId: PostBatchJobs summary: Create a Batch Job - description: >- - Create a Batch Job to be executed asynchronously in the Medusa backend. - If `dry_run` is set to `true`, the batch job will not be executed until - the it is confirmed, which can be done using the Confirm Batch Job API - Route. + description: Create a Batch Job to be executed asynchronously in the Medusa backend. If `dry_run` is set to `true`, the batch job will not be executed until the it is confirmed, which can be done using the Confirm Batch Job API Route. externalDocs: description: How to create a batch job - url: >- - https://docs.medusajs.com/development/batch-jobs/create#create-batch-job + url: https://docs.medusajs.com/development/batch-jobs/create#create-batch-job x-authenticated: true requestBody: content: @@ -1068,14 +909,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.batchJobs.create({ type: 'product-export', context: {}, @@ -1162,16 +999,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.batchJobs.retrieve(batchJobId) - .then(({ batch_job }) => { console.log(batch_job.id); }) @@ -1231,9 +1063,7 @@ paths: post: operationId: PostBatchJobsBatchJobCancel summary: Cancel a Batch Job - description: >- - Mark a batch job as canceled. When a batch job is canceled, the - processing of the batch job doesn’t automatically stop. + description: Mark a batch job as canceled. When a batch job is canceled, the processing of the batch job doesn’t automatically stop. x-authenticated: true parameters: - in: path @@ -1247,16 +1077,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.batchJobs.cancel(batchJobId) - .then(({ batch_job }) => { console.log(batch_job.id); }) @@ -1320,10 +1145,7 @@ paths: post: operationId: PostBatchJobsBatchJobConfirmProcessing summary: Confirm a Batch Job - description: >- - When a batch job is created, it is not executed automatically if - `dry_run` is set to `true`. This API Route confirms that the batch job - should be executed. + description: When a batch job is created, it is not executed automatically if `dry_run` is set to `true`. This API Route confirms that the batch job should be executed. x-authenticated: true parameters: - in: path @@ -1337,16 +1159,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.batchJobs.confirm(batchJobId) - .then(({ batch_job }) => { console.log(batch_job.id); }) @@ -1410,10 +1227,7 @@ paths: get: operationId: GetCollections summary: List Collections - description: >- - Retrieve a list of Product Collection. The product collections can be - filtered by fields such as `handle` or `title`. The collections can also - be sorted or paginated. + description: Retrieve a list of Product Collection. The product collections can be filtered by fields such as `handle` or `title`. The collections can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -1520,16 +1334,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.collections.list() - .then(({ collections, limit, offset, count }) => { console.log(collections.length); }) @@ -1605,18 +1414,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.collections.create({ title: "New Collection" }) - .then(({ collection }) => { console.log(collection.id); }) @@ -1682,9 +1486,7 @@ paths: get: operationId: GetCollectionsCollection summary: Get a Collection - description: >- - Retrieve a Product Collection by its ID. The products associated with it - are expanded and returned as well. + description: Retrieve a Product Collection by its ID. The products associated with it are expanded and returned as well. x-authenticated: true parameters: - in: path @@ -1698,16 +1500,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.collections.retrieve(collectionId) - .then(({ collection }) => { console.log(collection.id); }) @@ -1785,18 +1582,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.collections.update(collectionId, { title: "New Collection" }) - .then(({ collection }) => { console.log(collection.id); }) @@ -1879,16 +1671,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.collections.delete(collectionId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -1971,21 +1758,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.collections.addProducts(collectionId, { product_ids: [ productId1, productId2 ] }) - .then(({ collection }) => { console.log(collection.products) }) @@ -2056,9 +1838,7 @@ paths: delete: operationId: DeleteProductsFromCollection summary: Remove Products from Collection - description: >- - Remove a list of products from a collection. This would not delete the - product, only the association between the product and the collection. + description: Remove a list of products from a collection. This would not delete the product, only the association between the product and the collection. x-authenticated: true parameters: - in: path @@ -2077,21 +1857,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.collections.removeProducts(collectionId, { product_ids: [ productId1, productId2 ] }) - .then(({ id, object, removed_products }) => { console.log(removed_products) }) @@ -2125,14 +1900,10 @@ paths: export default Collection - lang: Shell label: cURL - source: > - curl -X DELETE '{backend_url}/admin/collections/{id}/products/batch' - \ - + source: | + curl -X DELETE '{backend_url}/admin/collections/{id}/products/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_ids": [ "prod_01G1G5V2MBA328390B5AXJ610F" @@ -2167,9 +1938,7 @@ paths: get: operationId: GetCurrencies summary: List Currency - description: >- - Retrieve a list of currencies. The currencies can be filtered by fields - such as `code`. The currencies can also be sorted or paginated. + description: Retrieve a list of currencies. The currencies can be filtered by fields such as `code`. The currencies can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -2188,6 +1957,11 @@ paths: description: A field to sort order the retrieved currencies by. schema: type: string + - in: query + name: q + description: Term used to search currencies' name and code. + schema: + type: string - in: query name: offset description: The number of currencies to skip when retrieving the currencies. @@ -2206,16 +1980,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.currencies.list() - .then(({ currencies, count, offset, limit }) => { console.log(currencies.length); }) @@ -2299,18 +2068,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.currencies.update(code, { includes_tax: true }) - .then(({ currency }) => { console.log(currency.code); }) @@ -2380,10 +2144,7 @@ paths: get: operationId: GetCustomerGroups summary: List Customer Groups - description: >- - Retrieve a list of customer groups. The customer groups can be filtered - by fields such as `name` or `id. The customer groups can also be sorted - or paginated. + description: Retrieve a list of customer groups. The customer groups can be filtered by fields such as `name` or `id. The customer groups can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -2393,9 +2154,7 @@ paths: type: string - in: query name: offset - description: >- - The number of customer groups to skip when retrieving the customer - groups. + description: The number of customer groups to skip when retrieving the customer groups. schema: type: integer default: 0 @@ -2499,9 +2258,7 @@ paths: default: 10 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - customer groups. + description: Comma-separated relations that should be expanded in the returned customer groups. schema: type: string x-codegen: @@ -2510,16 +2267,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.list() - .then(({ customer_groups, limit, offset, count }) => { console.log(customer_groups.length); }) @@ -2602,18 +2354,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.create({ name: "VIP" }) - .then(({ customer_group }) => { console.log(customer_group.id); }) @@ -2675,9 +2422,7 @@ paths: get: operationId: GetCustomerGroupsGroup summary: Get a Customer Group - description: >- - Retrieve a Customer Group by its ID. You can expand the customer group's - relations or select the fields that should be returned. + description: Retrieve a Customer Group by its ID. You can expand the customer group's relations or select the fields that should be returned. x-authenticated: true parameters: - in: path @@ -2688,16 +2433,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - customer group. + description: Comma-separated relations that should be expanded in the returned customer group. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - customer group. + description: Comma-separated fields that should be included in the returned customer group. schema: type: string x-codegen: @@ -2706,16 +2447,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.retrieve(customerGroupId) - .then(({ customer_group }) => { console.log(customer_group.id); }) @@ -2795,18 +2531,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.update(customerGroupId, { name: "VIP" }) - .then(({ customer_group }) => { console.log(customer_group.id); }) @@ -2873,9 +2604,7 @@ paths: delete: operationId: DeleteCustomerGroupsCustomerGroup summary: Delete a Customer Group - description: >- - Delete a customer group. This doesn't delete the customers associated - with the customer group. + description: Delete a customer group. This doesn't delete the customers associated with the customer group. x-authenticated: true parameters: - in: path @@ -2889,16 +2618,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.delete(customerGroupId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -2960,9 +2684,7 @@ paths: get: operationId: GetCustomerGroupsGroupCustomers summary: List Customers - description: >- - Retrieve a list of customers in a customer group. The customers can be - filtered by the `q` field. The customers can also be paginated. + description: Retrieve a list of customers in a customer group. The customers can be filtered by the `q` field. The customers can also be paginated. x-authenticated: true parameters: - in: path @@ -2985,9 +2707,7 @@ paths: default: 0 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - customers. + description: Comma-separated relations that should be expanded in the returned customers. schema: type: string - in: query @@ -3001,16 +2721,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.listCustomers(customerGroupId) - .then(({ customers }) => { console.log(customers.length); }) @@ -3097,21 +2812,16 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostCustomerGroupsGroupCustomersBatchReq + $ref: '#/components/schemas/AdminPostCustomerGroupsGroupCustomersBatchReq' x-codegen: method: addCustomers x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.addCustomers(customerGroupId, { customer_ids: [ { @@ -3119,7 +2829,6 @@ paths: } ] }) - .then(({ customer_group }) => { console.log(customer_group.id); }) @@ -3157,14 +2866,10 @@ paths: export default CustomerGroup - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/customer-groups/{id}/customers/batch' \ - + source: | + curl -X POST '{backend_url}/admin/customer-groups/{id}/customers/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "customer_ids": [ { @@ -3200,10 +2905,7 @@ paths: delete: operationId: DeleteCustomerGroupsGroupCustomerBatch summary: Remove Customers from Group - description: >- - Remove a list of customers from a customer group. This doesn't delete - the customer, only the association between the customer and the customer - group. + description: Remove a list of customers from a customer group. This doesn't delete the customer, only the association between the customer and the customer group. x-authenticated: true parameters: - in: path @@ -3216,21 +2918,16 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminDeleteCustomerGroupsGroupCustomerBatchReq + $ref: '#/components/schemas/AdminDeleteCustomerGroupsGroupCustomerBatchReq' x-codegen: method: removeCustomers x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customerGroups.removeCustomers(customerGroupId, { customer_ids: [ { @@ -3238,7 +2935,6 @@ paths: } ] }) - .then(({ customer_group }) => { console.log(customer_group.id); }) @@ -3277,14 +2973,10 @@ paths: export default CustomerGroup - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/customer-groups/{id}/customers/batch' \ - + source: | + curl -X DELETE '{backend_url}/admin/customer-groups/{id}/customers/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "customer_ids": [ { @@ -3321,9 +3013,7 @@ paths: get: operationId: GetCustomers summary: List Customers - description: >- - Retrieve a list of Customers. The customers can be filtered by fields - such as `q` or `groups`. The customers can also be paginated. + description: Retrieve a list of Customers. The customers can be filtered by fields such as `q` or `groups`. The customers can also be paginated. x-authenticated: true parameters: - in: query @@ -3340,9 +3030,7 @@ paths: default: 0 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - customer. + description: Comma-separated relations that should be expanded in the returned customer. schema: type: string - in: query @@ -3365,16 +3053,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customers.list() - .then(({ customers, limit, offset, count }) => { console.log(customers.length); }) @@ -3450,21 +3133,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customers.create({ email: "user@example.com", first_name: "Caterina", last_name: "Yost", password: "supersecret" }) - .then(({ customer }) => { console.log(customer.id); }) @@ -3549,16 +3227,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - customer. + description: Comma-separated relations that should be expanded in the returned customer. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - customer. + description: Comma-separated fields that should be included in the returned customer. schema: type: string x-codegen: @@ -3566,16 +3240,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customers.retrieve(customerId) - .then(({ customer }) => { console.log(customer.id); }) @@ -3647,16 +3316,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - customer. + description: Comma-separated relations that should be expanded in the returned customer. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be retrieved in the returned - customer. + description: Comma-separated fields that should be retrieved in the returned customer. schema: type: string requestBody: @@ -3669,18 +3334,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.customers.update(customerId, { first_name: "Dolly" }) - .then(({ customer }) => { console.log(customer.id); }) @@ -3752,9 +3412,7 @@ paths: operationId: GetDiscounts summary: List Discounts x-authenticated: true - description: >- - Retrieve a list of Discounts. The discounts can be filtered by fields - such as `rule` or `is_dynamic`. The discounts can also be paginated. + description: Retrieve a list of Discounts. The discounts can be filtered by fields such as `rule` or `is_dynamic`. The discounts can also be paginated. parameters: - in: query name: q @@ -3804,9 +3462,7 @@ paths: default: '0' - in: query name: expand - description: >- - Comma-separated relations that should be expanded in each returned - discount. + description: Comma-separated relations that should be expanded in each returned discount. schema: type: string x-codegen: @@ -3815,16 +3471,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.list() - .then(({ discounts, limit, offset, count }) => { console.log(discounts.id); }) @@ -3889,22 +3540,16 @@ paths: operationId: PostDiscounts summary: Create a Discount x-authenticated: true - description: >- - Create a Discount with a given set of rules that defines how the - Discount is applied. + description: Create a Discount with a given set of rules that defines how the Discount is applied. parameters: - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be retrieved in the returned - discount. + description: Comma-separated fields that should be retrieved in the returned discount. schema: type: string requestBody: @@ -3918,16 +3563,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - import { AllocationType, DiscountRuleType } from "@medusajs/medusa" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.create({ code: "TEST", rule: { @@ -3939,7 +3579,6 @@ paths: is_dynamic: false, is_disabled: false }) - .then(({ discount }) => { console.log(discount.id); }) @@ -4038,16 +3677,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount. + description: Comma-separated fields that should be included in the returned discount. schema: type: string x-codegen: @@ -4056,16 +3691,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.retrieveByCode(code) - .then(({ discount }) => { console.log(discount.id); }) @@ -4127,12 +3757,7 @@ paths: post: operationId: PostDiscountsDiscountConditions summary: Create a Condition - description: >- - Create a Discount Condition. Only one of `products`, `product_types`, - `product_collections`, `product_tags`, and `customer_groups` should be - provided, based on the type of discount condition. For example, if the - discount condition's type is `products`, the `products` field should be - provided in the request body. + description: Create a Discount Condition. Only one of `products`, `product_types`, `product_collections`, `product_tags`, and `customer_groups` should be provided, based on the type of discount condition. For example, if the discount condition's type is `products`, the `products` field should be provided in the request body. x-authenticated: true parameters: - in: path @@ -4143,16 +3768,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount. + description: Comma-separated fields that should be included in the returned discount. schema: type: string requestBody: @@ -4166,21 +3787,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - import { DiscountConditionOperator } from "@medusajs/medusa" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.createCondition(discountId, { operator: DiscountConditionOperator.IN, products: [productId] }) - .then(({ discount }) => { console.log(discount.id); }) @@ -4272,16 +3887,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount condition. + description: Comma-separated relations that should be expanded in the returned discount condition. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount condition. + description: Comma-separated fields that should be included in the returned discount condition. schema: type: string x-codegen: @@ -4290,16 +3901,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.getCondition(discountId, conditionId) - .then(({ discount_condition }) => { console.log(discount_condition.id); }) @@ -4339,10 +3945,8 @@ paths: export default DiscountCondition - lang: Shell label: cURL - source: > - curl '{backend_url}/admin/discounts/{id}/conditions/{condition_id}' - \ - + source: | + curl '{backend_url}/admin/discounts/{id}/conditions/{condition_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -4372,12 +3976,7 @@ paths: post: operationId: PostDiscountsDiscountConditionsCondition summary: Update a Condition - description: >- - Update a Discount Condition. Only one of `products`, `product_types`, - `product_collections`, `product_tags`, and `customer_groups` should be - provided, based on the type of discount condition. For example, if the - discount condition's type is `products`, the `products` field should be - provided in the request body. + description: Update a Discount Condition. Only one of `products`, `product_types`, `product_collections`, `product_tags`, and `customer_groups` should be provided, based on the type of discount condition. For example, if the discount condition's type is `products`, the `products` field should be provided in the request body. x-authenticated: true parameters: - in: path @@ -4394,44 +3993,34 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount. + description: Comma-separated fields that should be included in the returned discount. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostDiscountsDiscountConditionsCondition + $ref: '#/components/schemas/AdminPostDiscountsDiscountConditionsCondition' x-codegen: method: updateCondition queryParams: AdminPostDiscountsDiscountConditionsConditionParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.updateCondition(discountId, conditionId, { products: [ productId ] }) - .then(({ discount }) => { console.log(discount.id); }) @@ -4474,14 +4063,10 @@ paths: export default DiscountCondition - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/discounts/{id}/conditions/{condition}' \ - + source: | + curl -X POST '{backend_url}/admin/discounts/{id}/conditions/{condition}' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "products": [ "prod_01G1G5V2MBA328390B5AXJ610F" @@ -4515,9 +4100,7 @@ paths: delete: operationId: DeleteDiscountsDiscountConditionsCondition summary: Delete a Condition - description: >- - Delete a Discount Condition. This does not delete resources associated - to the discount condition. + description: Delete a Discount Condition. This does not delete resources associated to the discount condition. x-authenticated: true parameters: - in: path @@ -4534,16 +4117,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount. + description: Comma-separated fields that should be included in the returned discount. schema: type: string x-codegen: @@ -4552,16 +4131,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.deleteCondition(discountId, conditionId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -4599,10 +4173,8 @@ paths: export default Discount - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/discounts/{id}/conditions/{condition_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/discounts/{id}/conditions/{condition_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -4633,11 +4205,7 @@ paths: post: operationId: PostDiscountsDiscountConditionsConditionBatch summary: Add Batch Resources - description: >- - Add a batch of resources to a discount condition. The type of resource - depends on the type of discount condition. For example, if the discount - condition's type is `products`, the resources being added should be - products. + description: Add a batch of resources to a discount condition. The type of resource depends on the type of discount condition. For example, if the discount condition's type is `products`, the resources being added should be products. x-authenticated: true parameters: - in: path @@ -4654,43 +4222,32 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount. + description: Comma-separated fields that should be included in the returned discount. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostDiscountsDiscountConditionsConditionBatchReq + $ref: '#/components/schemas/AdminPostDiscountsDiscountConditionsConditionBatchReq' x-codegen: method: addConditionResourceBatch queryParams: AdminPostDiscountsDiscountConditionsConditionBatchParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.discounts.addConditionResourceBatch(discountId, - conditionId, { + medusa.admin.discounts.addConditionResourceBatch(discountId, conditionId, { resources: [{ id: itemId }] }) - .then(({ discount }) => { console.log(discount.id); }) @@ -4737,15 +4294,10 @@ paths: export default DiscountCondition - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/discounts/{id}/conditions/{condition_id}/batch' - \ - + source: | + curl -X POST '{backend_url}/admin/discounts/{id}/conditions/{condition_id}/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "resources": [{ "id": "item_id" }] }' @@ -4777,10 +4329,7 @@ paths: delete: operationId: DeleteDiscountsDiscountConditionsConditionBatch summary: Remove Batch Resources - description: >- - Remove a batch of resources from a discount condition. This will only - remove the association between the resource and the discount condition, - not the resource itself. + description: Remove a batch of resources from a discount condition. This will only remove the association between the resource and the discount condition, not the resource itself. x-authenticated: true parameters: - in: path @@ -4797,42 +4346,31 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount. + description: Comma-separated fields that should be included in the returned discount. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminDeleteDiscountsDiscountConditionsConditionBatchReq + $ref: '#/components/schemas/AdminDeleteDiscountsDiscountConditionsConditionBatchReq' x-codegen: method: deleteConditionResourceBatch x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.discounts.deleteConditionResourceBatch(discountId, - conditionId, { + medusa.admin.discounts.deleteConditionResourceBatch(discountId, conditionId, { resources: [{ id: itemId }] }) - .then(({ discount }) => { console.log(discount.id); }) @@ -4879,15 +4417,10 @@ paths: export default DiscountCondition - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/discounts/{id}/conditions/{condition_id}/batch' - \ - + source: | + curl -X DELETE '{backend_url}/admin/discounts/{id}/conditions/{condition_id}/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "resources": [{ "id": "item_id" }] }' @@ -4931,16 +4464,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - discount. + description: Comma-separated fields that should be included in the returned discount. schema: type: string x-codegen: @@ -4949,16 +4478,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.retrieve(discountId) - .then(({ discount }) => { console.log(discount.id); }) @@ -5019,9 +4543,7 @@ paths: post: operationId: PostDiscountsDiscount summary: Update a Discount - description: >- - Update a Discount with a given set of rules that define how the Discount - is applied. + description: Update a Discount with a given set of rules that define how the Discount is applied. x-authenticated: true parameters: - in: path @@ -5032,16 +4554,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - discount. + description: Comma-separated relations that should be expanded in the returned discount. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be retrieved in the returned - discount. + description: Comma-separated fields that should be retrieved in the returned discount. schema: type: string requestBody: @@ -5055,18 +4573,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.update(discountId, { code: "TEST" }) - .then(({ discount }) => { console.log(discount.id); }) @@ -5131,9 +4644,7 @@ paths: delete: operationId: DeleteDiscountsDiscount summary: Delete a Discount - description: >- - Delete a Discount. Deleting the discount will make it unavailable for - customers to use. + description: Delete a Discount. Deleting the discount will make it unavailable for customers to use. x-authenticated: true parameters: - in: path @@ -5147,16 +4658,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.delete(discountId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -5212,10 +4718,7 @@ paths: post: operationId: PostDiscountsDiscountDynamicCodes summary: Create a Dynamic Code - description: >- - Create a dynamic unique code that can map to a parent Discount. This is - useful if you want to automatically generate codes with the same rules - and conditions. + description: Create a dynamic unique code that can map to a parent Discount. This is useful if you want to automatically generate codes with the same rules and conditions. x-authenticated: true parameters: - in: path @@ -5234,19 +4737,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.createDynamicCode(discountId, { code: "TEST", usage_limit: 1 }) - .then(({ discount }) => { console.log(discount.id); }) @@ -5340,16 +4838,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.deleteDynamicCode(discountId, code) - .then(({ discount }) => { console.log(discount.id); }) @@ -5381,10 +4874,8 @@ paths: export default Discount - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/discounts/{id}/dynamic-codes/{code}' \ - + source: | + curl -X DELETE '{backend_url}/admin/discounts/{id}/dynamic-codes/{code}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -5435,16 +4926,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.addRegion(discountId, regionId) - .then(({ discount }) => { console.log(discount.id); }) @@ -5476,10 +4962,8 @@ paths: export default Discount - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/discounts/{id}/regions/{region_id}' \ - + source: | + curl -X POST '{backend_url}/admin/discounts/{id}/regions/{region_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -5510,10 +4994,7 @@ paths: operationId: DeleteDiscountsDiscountRegionsRegion summary: Remove Region x-authenticated: true - description: >- - Remove a Region from the list of Regions that a Discount can be used in. - This does not delete a region, only the association between it and the - discount. + description: Remove a Region from the list of Regions that a Discount can be used in. This does not delete a region, only the association between it and the discount. parameters: - in: path name: id @@ -5532,16 +5013,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.discounts.removeRegion(discountId, regionId) - .then(({ discount }) => { console.log(discount.id); }) @@ -5573,10 +5049,8 @@ paths: export default Discount - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/discounts/{id}/regions/{region_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/discounts/{id}/regions/{region_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -5607,9 +5081,7 @@ paths: get: operationId: GetDraftOrders summary: List Draft Orders - description: >- - Retrieve an list of Draft Orders. The draft orders can be filtered by - fields such as `q`. The draft orders can also paginated. + description: Retrieve an list of Draft Orders. The draft orders can be filtered by fields such as `q`. The draft orders can also paginated. x-authenticated: true parameters: - in: query @@ -5626,9 +5098,7 @@ paths: default: '50' - in: query name: q - description: >- - a term to search draft orders' display IDs and emails in the draft - order's cart + description: a term to search draft orders' display IDs and emails in the draft order's cart schema: type: string x-codegen: @@ -5637,16 +5107,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.list() - .then(({ draft_orders, limit, offset, count }) => { console.log(draft_orders.length); }) @@ -5710,9 +5175,7 @@ paths: post: operationId: PostDraftOrders summary: Create a Draft Order - description: >- - Create a Draft Order. A draft order is not transformed into an order - until payment is captured. + description: Create a Draft Order. A draft order is not transformed into an order until payment is captured. x-authenticated: true requestBody: content: @@ -5724,14 +5187,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.create({ email: "user@example.com", region_id, @@ -5746,7 +5205,6 @@ paths: } ], }) - .then(({ draft_order }) => { console.log(draft_order.id); }) @@ -5848,16 +5306,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.retrieve(draftOrderId) - .then(({ draft_order }) => { console.log(draft_order.id); }) @@ -5939,18 +5392,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.update(draftOrderId, { email: "user@example.com" }) - .then(({ draft_order }) => { console.log(draft_order.id); }) @@ -6035,16 +5483,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.delete(draftOrderId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -6129,18 +5572,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.addLineItem(draftOrderId, { quantity: 1 }) - .then(({ draft_order }) => { console.log(draft_order.id); }) @@ -6231,25 +5669,19 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostDraftOrdersDraftOrderLineItemsItemReq + $ref: '#/components/schemas/AdminPostDraftOrdersDraftOrderLineItemsItemReq' x-codegen: method: updateLineItem x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.updateLineItem(draftOrderId, lineId, { quantity: 1 }) - .then(({ draft_order }) => { console.log(draft_order.id); }) @@ -6285,14 +5717,10 @@ paths: export default DraftOrder - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/draft-orders/{id}/line-items/{line_id}' \ - + source: | + curl -X POST '{backend_url}/admin/draft-orders/{id}/line-items/{line_id}' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "quantity": 1 }' @@ -6344,16 +5772,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.removeLineItem(draftOrderId, itemId) - .then(({ draft_order }) => { console.log(draft_order.id); }) @@ -6387,10 +5810,8 @@ paths: export default DraftOrder - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/draft-orders/{id}/line-items/{line_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/draft-orders/{id}/line-items/{line_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -6421,12 +5842,7 @@ paths: post: summary: Mark Paid operationId: PostDraftOrdersDraftOrderRegisterPayment - description: >- - Capture the draft order's payment. This will also set the draft order's - status to `completed` and create an Order from the draft order. The - payment is captured through Medusa's system payment, which is manual - payment that isn't integrated with any third-party payment provider. It - is assumed that the payment capturing is handled manually by the admin. + description: Capture the draft order's payment. This will also set the draft order's status to `completed` and create an Order from the draft order. The payment is captured through Medusa's system payment, which is manual payment that isn't integrated with any third-party payment provider. It is assumed that the payment capturing is handled manually by the admin. x-authenticated: true parameters: - in: path @@ -6440,16 +5856,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.draftOrders.markPaid(draftOrderId) - .then(({ order }) => { console.log(order.id); }) @@ -6498,8 +5909,7 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostDraftOrdersDraftOrderRegisterPaymentRes + $ref: '#/components/schemas/AdminPostDraftOrdersDraftOrderRegisterPaymentRes' '400': $ref: '#/components/responses/400_error' '401': @@ -6516,9 +5926,7 @@ paths: get: operationId: GetGiftCards summary: List Gift Cards - description: >- - Retrieve a list of Gift Cards. The gift cards can be filtered by fields - such as `q`. The gift cards can also paginated. + description: Retrieve a list of Gift Cards. The gift cards can be filtered by fields such as `q`. The gift cards can also paginated. x-authenticated: true parameters: - in: query @@ -6544,16 +5952,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.giftCards.list() - .then(({ gift_cards, limit, offset, count }) => { console.log(gift_cards.length); }) @@ -6618,9 +6021,7 @@ paths: post: operationId: PostGiftCards summary: Create a Gift Card - description: >- - Create a Gift Card that can redeemed by its unique code. The Gift Card - is only valid within 1 region. + description: Create a Gift Card that can redeemed by its unique code. The Gift Card is only valid within 1 region. x-authenticated: true requestBody: content: @@ -6632,18 +6033,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.giftCards.create({ region_id }) - .then(({ gift_card }) => { console.log(gift_card.id); }) @@ -6727,16 +6123,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.giftCards.retrieve(giftCardId) - .then(({ gift_card }) => { console.log(gift_card.id); }) @@ -6814,18 +6205,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.giftCards.update(giftCardId, { region_id }) - .then(({ gift_card }) => { console.log(gift_card.id); }) @@ -6910,16 +6296,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.giftCards.delete(giftCardId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -6985,17 +6366,12 @@ paths: get: operationId: GetInventoryItems summary: List Inventory Items - description: >- - Retrieve a list of inventory items. The inventory items can be filtered - by fields such as `q` or `location_id`. The inventory items can also be - paginated. + description: Retrieve a list of inventory items. The inventory items can be filtered by fields such as `q` or `location_id`. The inventory items can also be paginated. x-authenticated: true parameters: - in: query name: offset - description: >- - The number of inventory items to skip when retrieving the inventory - items. + description: The number of inventory items to skip when retrieving the inventory items. schema: type: integer default: 0 @@ -7007,16 +6383,12 @@ paths: default: 20 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in each returned - inventory item. + description: Comma-separated relations that should be expanded in each returned inventory item. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - inventory item. + description: Comma-separated fields that should be included in the returned inventory item. schema: type: string - in: query @@ -7102,16 +6474,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.inventoryItems.list() - .then(({ inventory_items, count, offset, limit }) => { console.log(inventory_items.length); }) @@ -7164,8 +6531,7 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminInventoryItemsListWithVariantsAndLocationLevelsRes + $ref: '#/components/schemas/AdminInventoryItemsListWithVariantsAndLocationLevelsRes' '400': $ref: '#/components/responses/400_error' '401': @@ -7186,16 +6552,12 @@ paths: parameters: - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - inventory item. + description: Comma-separated relations that should be expanded in the returned inventory item. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - inventory item. + description: Comma-separated fields that should be included in the returned inventory item. schema: type: string requestBody: @@ -7209,18 +6571,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.inventoryItems.create({ variant_id: "variant_123", }) - .then(({ inventory_item }) => { console.log(inventory_item.id); }) @@ -7297,16 +6654,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - inventory item. + description: Comma-separated relations that should be expanded in the returned inventory item. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - inventory item. + description: Comma-separated fields that should be included in the returned inventory item. schema: type: string x-codegen: @@ -7315,16 +6668,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.inventoryItems.retrieve(inventoryItemId) - .then(({ inventory_item }) => { console.log(inventory_item.id); }) @@ -7399,16 +6747,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - inventory level. + description: Comma-separated relations that should be expanded in the returned inventory level. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - inventory level. + description: Comma-separated fields that should be included in the returned inventory level. schema: type: string requestBody: @@ -7422,18 +6766,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.inventoryItems.update(inventoryItemId, { origin_country: "US", }) - .then(({ inventory_item }) => { console.log(inventory_item.id); }) @@ -7504,9 +6843,7 @@ paths: delete: operationId: DeleteInventoryItemsInventoryItem summary: Delete an Inventory Item - description: >- - Delete an Inventory Item. This does not delete the associated product - variant. + description: Delete an Inventory Item. This does not delete the associated product variant. x-authenticated: true parameters: - in: path @@ -7520,16 +6857,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.inventoryItems.delete(inventoryItemId) - .then(({ id, object, deleted }) => { console.log(id) }) @@ -7581,9 +6913,7 @@ paths: get: operationId: GetInventoryItemsInventoryItemLocationLevels summary: List Inventory Level - description: >- - Retrieve a list of inventory levels of an inventory item. The inventory - levels can be filtered by fields such as `location_id`. + description: Retrieve a list of inventory levels of an inventory item. The inventory levels can be filtered by fields such as `location_id`. x-authenticated: true parameters: - in: path @@ -7603,16 +6933,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - inventory levels. + description: Comma-separated relations that should be expanded in the returned inventory levels. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - inventory levels. + description: Comma-separated fields that should be included in the returned inventory levels. schema: type: string x-codegen: @@ -7621,16 +6947,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.inventoryItems.listLocationLevels(inventoryItemId) - .then(({ inventory_item }) => { console.log(inventory_item.location_levels); }) @@ -7711,43 +7032,33 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - inventory item. + description: Comma-separated relations that should be expanded in the returned inventory item. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - inventory item. + description: Comma-separated fields that should be included in the returned inventory item. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostInventoryItemsItemLocationLevelsReq + $ref: '#/components/schemas/AdminPostInventoryItemsItemLocationLevelsReq' x-codegen: method: createLocationLevel queryParams: AdminPostInventoryItemsItemLocationLevelsParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.inventoryItems.createLocationLevel(inventoryItemId, { location_id: "sloc_123", stocked_quantity: 10, }) - .then(({ inventory_item }) => { console.log(inventory_item.id); }) @@ -7787,14 +7098,10 @@ paths: export default InventoryItem - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/inventory-items/{id}/location-levels' \ - + source: | + curl -X POST '{backend_url}/admin/inventory-items/{id}/location-levels' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "location_id": "sloc_123", "stocked_quantity": 10 @@ -7845,43 +7152,32 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - location level. + description: Comma-separated relations that should be expanded in the returned location level. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - location level. + description: Comma-separated fields that should be included in the returned location level. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostInventoryItemsItemLocationLevelsLevelReq + $ref: '#/components/schemas/AdminPostInventoryItemsItemLocationLevelsLevelReq' x-codegen: method: updateLocationLevel queryParams: AdminPostInventoryItemsItemLocationLevelsLevelParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.inventoryItems.updateLocationLevel(inventoryItemId, - locationId, { + medusa.admin.inventoryItems.updateLocationLevel(inventoryItemId, locationId, { stocked_quantity: 15, }) - .then(({ inventory_item }) => { console.log(inventory_item.id); }) @@ -7921,15 +7217,10 @@ paths: export default InventoryItem - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/inventory-items/{id}/location-levels/{location_id}' - \ - + source: | + curl -X POST '{backend_url}/admin/inventory-items/{id}/location-levels/{location_id}' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "stocked_quantity": 15 }' @@ -7981,17 +7272,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.inventoryItems.deleteLocationLevel(inventoryItemId, - locationId) - + medusa.admin.inventoryItems.deleteLocationLevel(inventoryItemId, locationId) .then(({ inventory_item }) => { console.log(inventory_item.id); }) @@ -8023,11 +7308,8 @@ paths: export default InventoryItem - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/inventory-items/{id}/location-levels/{location_id}' - \ - + source: | + curl -X DELETE '{backend_url}/admin/inventory-items/{id}/location-levels/{location_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -8065,16 +7347,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.invites.list() - .then(({ invites }) => { console.log(invites.length); }) @@ -8111,12 +7388,7 @@ paths: post: operationId: PostInvites summary: Create an Invite - description: >- - Create an Invite. This will generate a token associated with the invite - and trigger an `invite.created` event. If you have a Notification - Provider installed that handles this event, a notification should be - sent to the email associated with the invite to allow them to accept the - invite. + description: Create an Invite. This will generate a token associated with the invite and trigger an `invite.created` event. If you have a Notification Provider installed that handles this event, a notification should be sent to the email associated with the invite to allow them to accept the invite. x-authenticated: true requestBody: content: @@ -8128,23 +7400,17 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.invites.create({ user: "user@example.com", role: "admin" }) - .then(() => { // successful }) - .catch(() => { // an error occurred }) @@ -8183,11 +7449,7 @@ paths: post: operationId: PostInvitesInviteAccept summary: Accept an Invite - description: >- - Accept an Invite. This will also delete the invite and create a new user - that can log in and perform admin functionalities. The user will have - the email associated with the invite, and the password provided in the - request body. + description: Accept an Invite. This will also delete the invite and create a new user that can log in and perform admin functionalities. The user will have the email associated with the invite, and the password provided in the request body. requestBody: content: application/json: @@ -8198,14 +7460,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.invites.accept({ token, user: { @@ -8214,11 +7472,9 @@ paths: password: "supersecret" } }) - .then(() => { // successful }) - .catch(() => { // an error occurred }) @@ -8309,16 +7565,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.invites.delete(inviteId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -8382,12 +7633,7 @@ paths: post: operationId: PostInvitesInviteResend summary: Resend an Invite - description: >- - Resend an Invite. This renews the expiry date by 7 days and generates a - new token for the invite. It also triggers the `invite.created` event, - so if you have a Notification Provider installed that handles this - event, a notification should be sent to the email associated with the - invite to allow them to accept the invite. + description: Resend an Invite. This renews the expiry date by 7 days and generates a new token for the invite. It also triggers the `invite.created` event, so if you have a Notification Provider installed that handles this event, a notification should be sent to the email associated with the invite to allow them to accept the invite. x-authenticated: true parameters: - in: path @@ -8401,20 +7647,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.invites.resend(inviteId) - .then(() => { // successful }) - .catch(() => { // an error occurred }) @@ -8475,9 +7715,7 @@ paths: operationId: GetNotes summary: List Notes x-authenticated: true - description: >- - Retrieve a list of notes. The notes can be filtered by fields such as - `resource_id`. The notes can also be paginated. + description: Retrieve a list of notes. The notes can be filtered by fields such as `resource_id`. The notes can also be paginated. parameters: - in: query name: limit @@ -8502,16 +7740,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.notes.list() - .then(({ notes, limit, offset, count }) => { console.log(notes.length); }) @@ -8585,20 +7818,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.notes.create({ resource_id, resource_type: "order", value: "We delivered this order" }) - .then(({ note }) => { console.log(note.id); }) @@ -8682,16 +7910,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.notes.retrieve(noteId) - .then(({ note }) => { console.log(note.id); }) @@ -8769,18 +7992,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.notes.update(noteId, { value: "We delivered this order" }) - .then(({ note }) => { console.log(note.id); }) @@ -8865,16 +8083,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.notes.delete(noteId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -8934,17 +8147,12 @@ paths: get: operationId: GetNotifications summary: List Notifications - description: >- - Retrieve a list of notifications. The notifications can be filtered by - fields such as `event_name` or `resource_type`. The notifications can - also be paginated. + description: Retrieve a list of notifications. The notifications can be filtered by fields such as `event_name` or `resource_type`. The notifications can also be paginated. x-authenticated: true parameters: - in: query name: offset - description: >- - The number of inventory items to skip when retrieving the inventory - items. + description: The number of inventory items to skip when retrieving the inventory items. schema: type: integer default: 0 @@ -8956,23 +8164,17 @@ paths: default: 50 - in: query name: fields - description: >- - Comma-separated fields that should be included in each returned - notification. + description: Comma-separated fields that should be included in each returned notification. schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in each returned - notification. + description: Comma-separated relations that should be expanded in each returned notification. schema: type: string - in: query name: event_name - description: >- - Filter by the name of the event that triggered sending this - notification. + description: Filter by the name of the event that triggered sending this notification. schema: type: string - in: query @@ -8987,17 +8189,12 @@ paths: type: string - in: query name: to - description: >- - Filter by the address that the Notification was sent to. This will - usually be an email address, but it can also represent other - addresses such as a chat bot user id. + description: Filter by the address that the Notification was sent to. This will usually be an email address, but it can also represent other addresses such as a chat bot user id. schema: type: string - in: query name: include_resends - description: >- - A boolean indicating whether the result set should include resent - notifications or not + description: A boolean indicating whether the result set should include resent notifications or not schema: type: string x-codegen: @@ -9006,16 +8203,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.notifications.list() - .then(({ notifications }) => { console.log(notifications.length); }) @@ -9080,9 +8272,7 @@ paths: post: operationId: PostNotificationsNotificationResend summary: Resend Notification - description: >- - Resend a previously sent notifications, with the same data but - optionally to a different address. + description: Resend a previously sent notifications, with the same data but optionally to a different address. x-authenticated: true parameters: - in: path @@ -9101,16 +8291,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.notifications.resend(notificationId) - .then(({ notification }) => { console.log(notification.id); }) @@ -9176,9 +8361,7 @@ paths: get: operationId: GetOrderEdits summary: List Order Edits - description: >- - Retrieve a list of order edits. The order edits can be filtered by - fields such as `q` or `order_id`. The order edits can also be paginated. + description: Retrieve a list of order edits. The order edits can be filtered by fields such as `q` or `order_id`. The order edits can also be paginated. x-authenticated: true parameters: - in: query @@ -9205,16 +8388,12 @@ paths: default: '0' - in: query name: expand - description: >- - Comma-separated relations that should be expanded in each returned - order edit. + description: Comma-separated relations that should be expanded in each returned order edit. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in each returned - order edit. + description: Comma-separated fields that should be included in each returned order edit. schema: type: string x-codegen: @@ -9223,16 +8402,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.list() - .then(({ order_edits, count, limit, offset }) => { console.log(order_edits.length) }) @@ -9310,16 +8484,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.create({ orderId }) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -9348,15 +8517,11 @@ paths: export default CreateOrderEdit - lang: Shell label: cURL - source: > + source: | curl -X POST '{backend_url}/admin/order-edits' \ - -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - - --data-raw '{ "order_id": "my_order_id", "internal_note": - "my_optional_note" }' + --data-raw '{ "order_id": "my_order_id", "internal_note": "my_optional_note" }' security: - api_token: [] - cookie_auth: [] @@ -9397,16 +8562,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in each returned - order edit. + description: Comma-separated relations that should be expanded in each returned order edit. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned order - edit. + description: Comma-separated fields that should be included in the returned order edit. schema: type: string x-codegen: @@ -9415,16 +8576,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.retrieve(orderEditId) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -9505,18 +8661,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.update(orderEditId, { internal_note: "internal reason XY" }) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -9588,9 +8739,7 @@ paths: delete: operationId: DeleteOrderEditsOrderEdit summary: Delete an Order Edit - description: >- - Delete an Order Edit. Only order edits that have the status `created` - can be deleted. + description: Delete an Order Edit. Only order edits that have the status `created` can be deleted. x-authenticated: true parameters: - in: path @@ -9604,16 +8753,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.delete(orderEditId) - .then(({ id, object, deleted }) => { console.log(id) }) @@ -9682,16 +8826,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.cancel(orderEditId) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -9757,9 +8896,7 @@ paths: delete: operationId: DeleteOrderEditsOrderEditItemChange summary: Delete a Line Item Change - description: >- - Delete a line item change that indicates the addition, deletion, or - update of a line item in the original order. + description: Delete a line item change that indicates the addition, deletion, or update of a line item in the original order. x-authenticated: true parameters: - in: path @@ -9779,16 +8916,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.deleteItemChange(orderEdit_id, itemChangeId) - .then(({ id, object, deleted }) => { console.log(id) }) @@ -9826,10 +8958,8 @@ paths: export default OrderEditItemChange - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/order-edits/{id}/changes/{change_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/order-edits/{id}/changes/{change_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -9850,9 +8980,7 @@ paths: post: operationId: PostOrderEditsOrderEditConfirm summary: Confirm an OrderEdit - description: >- - Confirm an Order Edit. This will reflect the changes in the order edit - on the associated order. + description: Confirm an Order Edit. This will reflect the changes in the order edit on the associated order. x-authenticated: true parameters: - in: path @@ -9866,16 +8994,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.confirm(orderEditId) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -9939,10 +9062,7 @@ paths: post: operationId: PostOrderEditsEditLineItems summary: Add a Line Item - description: >- - Create a line item change in the order edit that indicates adding an - item in the original order. The item will not be added to the original - order until the order edit is confirmed. + description: Create a line item change in the order edit that indicates adding an item in the original order. The item will not be added to the original order until the order edit is confirmed. parameters: - in: path name: id @@ -9961,19 +9081,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.addLineItem(orderEditId, { variant_id, quantity }) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -10010,15 +9125,11 @@ paths: export default OrderEdit - lang: Shell label: cURL - source: > + source: | curl -X POST '{backend_url}/admin/order-edits/{id}/items' \ - -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - - --data-raw '{ "variant_id": "variant_01G1G5V2MRX2V3PVSR2WXYPFB6", - "quantity": 3 }' + --data-raw '{ "variant_id": "variant_01G1G5V2MRX2V3PVSR2WXYPFB6", "quantity": 3 }' security: - api_token: [] - cookie_auth: [] @@ -10048,11 +9159,7 @@ paths: post: operationId: PostOrderEditsEditLineItemsLineItem summary: Upsert Line Item Change - description: >- - Create or update a line item change in the order edit that indicates - addition, deletion, or update of a line item into an original order. - Line item changes are only reflected on the original order after the - order edit is confirmed. + description: Create or update a line item change in the order edit that indicates addition, deletion, or update of a line item into an original order. Line item changes are only reflected on the original order after the order edit is confirmed. x-authenticated: true parameters: - in: path @@ -10077,18 +9184,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.updateLineItem(orderEditId, lineItemId, { quantity: 5 }) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -10128,14 +9230,10 @@ paths: export default OrderEditItemChange - lang: Shell label: cURL - source: > - curl -X POST '{backend_url}/admin/order-edits/{id}/items/{item_id}' - \ - + source: | + curl -X POST '{backend_url}/admin/order-edits/{id}/items/{item_id}' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "quantity": 5 }' security: - api_token: [] @@ -10165,10 +9263,7 @@ paths: delete: operationId: DeleteOrderEditsOrderEditLineItemsLineItem summary: Delete Line Item - description: >- - Create a line item change in the order edit that indicates deleting an - item in the original order. The item in the original order will not be - deleted until the order edit is confirmed. + description: Create a line item change in the order edit that indicates deleting an item in the original order. The item in the original order will not be deleted until the order edit is confirmed. x-authenticated: true parameters: - in: path @@ -10188,16 +9283,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.removeLineItem(orderEditId, lineItemId) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -10235,10 +9325,8 @@ paths: export default OrderEditLineItem - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/order-edits/{id}/items/{item_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/order-edits/{id}/items/{item_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -10269,10 +9357,7 @@ paths: post: operationId: PostOrderEditsOrderEditRequest summary: Request Confirmation - description: >- - Request customer confirmation of an Order Edit. This would emit the - event `order-edit.requested` which Notification Providers listen to and - send a notification to the customer about the order edit. + description: Request customer confirmation of an Order Edit. This would emit the event `order-edit.requested` which Notification Providers listen to and send a notification to the customer about the order edit. x-authenticated: true parameters: - in: path @@ -10286,16 +9371,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orderEdits.requestConfirmation(orderEditId) - .then({ order_edit }) => { console.log(order_edit.id) }) @@ -10362,16 +9442,12 @@ paths: get: operationId: GetOrders summary: List Orders - description: >- - Retrieve a list of Orders. The orders can be filtered by fields such as - `status` or `display_id`. The order can also be paginated. + description: Retrieve a list of Orders. The orders can be filtered by fields such as `status` or `display_id`. The order can also be paginated. x-authenticated: true parameters: - in: query name: q - description: >- - term to search orders' shipping address, first name, email, and - display ID + description: term to search orders' shipping address, first name, email, and display ID schema: type: string - in: query @@ -10568,16 +9644,12 @@ paths: default: 50 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -10586,16 +9658,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.list() - .then(({ orders, limit, offset, count }) => { console.log(orders.length); }) @@ -10669,16 +9736,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -10687,16 +9750,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.retrieve(orderId) - .then(({ order }) => { console.log(order.id); }) @@ -10770,16 +9828,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -10793,18 +9847,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.update(orderId, { email: "user@example.com" }) - .then(({ order }) => { console.log(order.id); }) @@ -10888,16 +9937,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -10906,16 +9951,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.archive(orderId) - .then(({ order }) => { console.log(order.id); }) @@ -10981,10 +10021,7 @@ paths: post: operationId: PostOrdersOrderCancel summary: Cancel an Order - description: >- - Cancel an order and change its status. This will also cancel any - associated Fulfillments and Payments, and it may fail if the Payment or - Fulfillment Provider is unable to cancel the Payment/Fulfillment. + description: Cancel an order and change its status. This will also cancel any associated Fulfillments and Payments, and it may fail if the Payment or Fulfillment Provider is unable to cancel the Payment/Fulfillment. x-authenticated: true parameters: - in: path @@ -10995,16 +10032,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -11013,16 +10046,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.cancel(orderId) - .then(({ order }) => { console.log(order.id); }) @@ -11088,9 +10116,7 @@ paths: post: operationId: PostOrdersOrderCapture summary: Capture an Order's Payments - description: >- - Capture all the Payments associated with an Order. The payment of - canceled orders can't be captured. + description: Capture all the Payments associated with an Order. The payment of canceled orders can't be captured. x-authenticated: true parameters: - in: path @@ -11101,16 +10127,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -11119,16 +10141,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.capturePayment(orderId) - .then(({ order }) => { console.log(order.id); }) @@ -11194,10 +10211,7 @@ paths: post: operationId: PostOrdersOrderClaims summary: Create a Claim - description: >- - Create a Claim for an order. If a return shipping method is specified, a - return will also be created and associated with the claim. If the - claim's type is `refund`, the refund is processed as well. + description: Create a Claim for an order. If a return shipping method is specified, a return will also be created and associated with the claim. If the claim's type is `refund`, the refund is processed as well. externalDocs: description: How are claims created url: https://docs.medusajs.com/modules/orders/claims#how-are-claims-created @@ -11211,16 +10225,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -11234,14 +10244,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.createClaim(orderId, { type: 'refund', claim_items: [ @@ -11251,7 +10257,6 @@ paths: } ] }) - .then(({ order }) => { console.log(order.id); }) @@ -11352,16 +10357,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -11375,18 +10376,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.updateClaim(orderId, claimId, { no_notification: true }) - .then(({ order }) => { console.log(order.id); }) @@ -11458,10 +10454,7 @@ paths: post: operationId: PostOrdersClaimCancel summary: Cancel a Claim - description: >- - Cancel a Claim and change its status. A claim can't be canceled if it - has a refund, if its fulfillments haven't been canceled, of if its - associated return hasn't been canceled. + description: Cancel a Claim and change its status. A claim can't be canceled if it has a refund, if its fulfillments haven't been canceled, of if its associated return hasn't been canceled. x-authenticated: true externalDocs: description: Canceling a claim @@ -11481,16 +10474,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -11499,16 +10488,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.cancelClaim(orderId, claimId) - .then(({ order }) => { console.log(order.id); }) @@ -11537,10 +10521,8 @@ paths: export default Claim - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/claims/{claim_id}/cancel' \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/claims/{claim_id}/cancel' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -11571,11 +10553,7 @@ paths: post: operationId: PostOrdersOrderClaimsClaimFulfillments summary: Create a Claim Fulfillment - description: >- - Create a Fulfillment for a Claim, and change its fulfillment status to - `partially_fulfilled` or `fulfilled` depending on whether all the items - were fulfilled. It may also change the status to `requires_action` if - any actions are required. + description: Create a Fulfillment for a Claim, and change its fulfillment status to `partially_fulfilled` or `fulfilled` depending on whether all the items were fulfilled. It may also change the status to `requires_action` if any actions are required. x-authenticated: true externalDocs: description: Fulfill a claim @@ -11595,42 +10573,31 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostOrdersOrderClaimsClaimFulfillmentsReq + $ref: '#/components/schemas/AdminPostOrdersOrderClaimsClaimFulfillmentsReq' x-codegen: method: fulfillClaim params: AdminPostOrdersOrderClaimsClaimFulfillmentsReq x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.fulfillClaim(orderId, claimId, { - }) - .then(({ order }) => { console.log(order.id); }) @@ -11665,10 +10632,8 @@ paths: export default Claim - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/claims/{claim_id}/fulfillments' \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/claims/{claim_id}/fulfillments' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -11699,9 +10664,7 @@ paths: post: operationId: PostOrdersClaimFulfillmentsCancel summary: Cancel Claim's Fulfillment - description: >- - Cancel a claim's fulfillment and change its fulfillment status to - `canceled`. + description: Cancel a claim's fulfillment and change its fulfillment status to `canceled`. x-authenticated: true parameters: - in: path @@ -11724,16 +10687,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -11742,17 +10701,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.orders.cancelClaimFulfillment(orderId, claimId, - fulfillmentId) - + medusa.admin.orders.cancelClaimFulfillment(orderId, claimId, fulfillmentId) .then(({ order }) => { console.log(order.id); }) @@ -11790,11 +10743,8 @@ paths: export default Claim - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/claims/{claim_id}/fulfillments/{fulfillment_id}/cancel' - \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/claims/{claim_id}/fulfillments/{fulfillment_id}/cancel' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -11825,11 +10775,7 @@ paths: post: operationId: PostOrdersOrderClaimsClaimShipments summary: Ship a Claim's Fulfillment - description: >- - Create a shipment for the claim and mark its fulfillment as shipped. - This changes the claim's fulfillment status to either - `partially_shipped` or `shipped`, depending on whether all the items - were shipped. + description: Create a shipment for the claim and mark its fulfillment as shipped. This changes the claim's fulfillment status to either `partially_shipped` or `shipped`, depending on whether all the items were shipped. x-authenticated: true externalDocs: description: Fulfill a claim @@ -11849,16 +10795,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -11872,18 +10814,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.createClaimShipment(orderId, claimId, { fulfillment_id }) - .then(({ order }) => { console.log(order.id); }) @@ -11919,14 +10856,10 @@ paths: export default Claim - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/claims/{claim_id}/shipments' \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/claims/{claim_id}/shipments' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "fulfillment_id": "{fulfillment_id}" }' @@ -11959,9 +10892,7 @@ paths: post: operationId: PostOrdersOrderComplete summary: Complete an Order - description: >- - Complete an Order and change its status. A canceled order can't be - completed. + description: Complete an Order and change its status. A canceled order can't be completed. x-authenticated: true parameters: - in: path @@ -11972,16 +10903,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -11990,16 +10917,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.complete(orderId) - .then(({ order }) => { console.log(order.id); }) @@ -12065,10 +10987,7 @@ paths: post: operationId: PostOrdersOrderFulfillments summary: Create a Fulfillment - description: >- - Create a Fulfillment of an Order using the fulfillment provider, and - change the order's fulfillment status to either `partially_fulfilled` or - `fulfilled`, depending on whether all the items were fulfilled. + description: Create a Fulfillment of an Order using the fulfillment provider, and change the order's fulfillment status to either `partially_fulfilled` or `fulfilled`, depending on whether all the items were fulfilled. x-authenticated: true externalDocs: description: Fulfillments of orders @@ -12082,16 +11001,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -12105,14 +11020,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.createFulfillment(orderId, { items: [ { @@ -12121,7 +11032,6 @@ paths: } ] }) - .then(({ order }) => { console.log(order.id); }) @@ -12206,9 +11116,7 @@ paths: post: operationId: PostOrdersOrderFulfillmentsCancel summary: Cancel a Fulfilmment - description: >- - Cancel an order's fulfillment and change its fulfillment status to - `canceled`. + description: Cancel an order's fulfillment and change its fulfillment status to `canceled`. x-authenticated: true parameters: - in: path @@ -12225,16 +11133,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -12243,16 +11147,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.cancelFulfillment(orderId, fulfillmentId) - .then(({ order }) => { console.log(order.id); }) @@ -12288,11 +11187,8 @@ paths: export default Order - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/fulfillments/{fulfillment_id}/cancel' - \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/fulfillments/{fulfillment_id}/cancel' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -12323,9 +11219,7 @@ paths: post: operationId: PostOrdersOrderLineItemReservations summary: Create a Reservation - description: >- - Create a Reservation for a line item at a specified location, optionally - for a partial quantity. + description: Create a Reservation for a line item at a specified location, optionally for a partial quantity. x-authenticated: true parameters: - in: path @@ -12348,15 +11242,10 @@ paths: x-codeSamples: - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/line-items/{line_item_id}/reserve' - \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/line-items/{line_item_id}/reserve' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "location_id": "loc_1" }' @@ -12389,9 +11278,7 @@ paths: post: operationId: PostOrdersOrderRefunds summary: Create a Refund - description: >- - Refund an amount for an order. The amount must be less than or equal the - `refundable_amount` of the order. + description: Refund an amount for an order. The amount must be less than or equal the `refundable_amount` of the order. x-authenticated: true parameters: - in: path @@ -12402,16 +11289,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -12425,19 +11308,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.refundPayment(orderId, { amount: 1000, reason: "Do not like it" }) - .then(({ order }) => { console.log(order.id); }) @@ -12570,9 +11448,7 @@ paths: post: operationId: PostOrdersOrderReturns summary: Request a Return - description: >- - Request and create a Return for items in an order. If the return - shipping method is specified, it will be automatically fulfilled. + description: Request and create a Return for items in an order. If the return shipping method is specified, it will be automatically fulfilled. x-authenticated: true externalDocs: description: Return creation process @@ -12586,16 +11462,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -12609,14 +11481,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.requestReturn(orderId, { items: [ { @@ -12625,7 +11493,6 @@ paths: } ] }) - .then(({ order }) => { console.log(order.id); }) @@ -12710,10 +11577,7 @@ paths: post: operationId: PostOrdersOrderShipment summary: Ship a Fulfillment - description: >- - Create a shipment and mark a fulfillment as shipped. This changes the - order's fulfillment status to either `partially_shipped` or `shipped`, - depending on whether all the items were shipped. + description: Create a shipment and mark a fulfillment as shipped. This changes the order's fulfillment status to either `partially_shipped` or `shipped`, depending on whether all the items were shipped. x-authenticated: true externalDocs: description: Fulfillments of orders @@ -12727,16 +11591,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -12750,18 +11610,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.createShipment(order_id, { fulfillment_id }) - .then(({ order }) => { console.log(order.id); }) @@ -12835,10 +11690,7 @@ paths: post: operationId: PostOrdersOrderShippingMethods summary: Add a Shipping Method - description: >- - Add a Shipping Method to an Order. If another Shipping Method exists - with the same Shipping Profile, the previous Shipping Method will be - replaced. + description: Add a Shipping Method to an Order. If another Shipping Method exists with the same Shipping Profile, the previous Shipping Method will be replaced. parameters: - in: path name: id @@ -12848,16 +11700,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -12872,19 +11720,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.addShippingMethod(orderId, { price: 1000, option_id }) - .then(({ order }) => { console.log(order.id); }) @@ -12961,9 +11804,7 @@ paths: post: operationId: PostOrdersOrderSwaps summary: Create a Swap - description: >- - Create a Swap. This includes creating a return that is associated with - the swap. + description: Create a Swap. This includes creating a return that is associated with the swap. x-authenticated: true externalDocs: description: How are swaps created @@ -12977,16 +11818,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -13000,14 +11837,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.createSwap(orderId, { return_items: [ { @@ -13016,7 +11849,6 @@ paths: } ] }) - .then(({ order }) => { console.log(order.id); }) @@ -13116,16 +11948,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -13134,16 +11962,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.cancelSwap(orderId, swapId) - .then(({ order }) => { console.log(order.id); }) @@ -13181,10 +12004,8 @@ paths: export default Swap - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{order_id}/swaps/{swap_id}/cancel' \ - + source: | + curl -X POST '{backend_url}/admin/orders/{order_id}/swaps/{swap_id}/cancel' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -13215,15 +12036,11 @@ paths: post: operationId: PostOrdersOrderSwapsSwapFulfillments summary: Create a Swap Fulfillment - description: >- - Create a Fulfillment for a Swap and change its fulfillment status to - `fulfilled`. If it requires any additional actions, its fulfillment - status may change to `requires_action`. + description: Create a Fulfillment for a Swap and change its fulfillment status to `fulfilled`. If it requires any additional actions, its fulfillment status may change to `requires_action`. x-authenticated: true externalDocs: description: Handling a swap's fulfillment - url: >- - https://docs.medusajs.com/modules/orders/swaps#handling-swap-fulfillment + url: https://docs.medusajs.com/modules/orders/swaps#handling-swap-fulfillment parameters: - in: path name: id @@ -13239,43 +12056,32 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostOrdersOrderSwapsSwapFulfillmentsReq + $ref: '#/components/schemas/AdminPostOrdersOrderSwapsSwapFulfillmentsReq' x-codegen: method: fulfillSwap params: AdminPostOrdersOrderSwapsSwapFulfillmentsParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.fulfillSwap(orderId, swapId, { - }) - .then(({ order }) => { console.log(order.id); }) @@ -13315,10 +12121,8 @@ paths: export default Swap - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/swaps/{swap_id}/fulfillments' \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/swaps/{swap_id}/fulfillments' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -13349,9 +12153,7 @@ paths: post: operationId: PostOrdersSwapFulfillmentsCancel summary: Cancel Swap's Fulfilmment - description: >- - Cancel a swap's fulfillment and change its fulfillment status to - `canceled`. + description: Cancel a swap's fulfillment and change its fulfillment status to `canceled`. x-authenticated: true parameters: - in: path @@ -13374,16 +12176,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -13392,17 +12190,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.orders.cancelSwapFulfillment(orderId, swapId, - fulfillmentId) - + medusa.admin.orders.cancelSwapFulfillment(orderId, swapId, fulfillmentId) .then(({ order }) => { console.log(order.id); }) @@ -13441,11 +12233,8 @@ paths: export default Swap - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/swaps/{swap_id}/fulfillments/{fulfillment_id}/cancel' - \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/swaps/{swap_id}/fulfillments/{fulfillment_id}/cancel' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -13476,11 +12265,7 @@ paths: post: operationId: PostOrdersOrderSwapsSwapProcessPayment summary: Process a Swap Payment - description: >- - Process a swap's payment either by refunding or issuing a payment. This - depends on the `difference_due` of the swap. If `difference_due` is - negative, the amount is refunded. If `difference_due` is positive, the - amount is captured. + description: Process a swap's payment either by refunding or issuing a payment. This depends on the `difference_due` of the swap. If `difference_due` is negative, the amount is refunded. If `difference_due` is positive, the amount is captured. x-authenticated: true externalDocs: description: Handling a swap's payment @@ -13500,16 +12285,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string x-codegen: @@ -13518,16 +12299,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.processSwapPayment(orderId, swapId) - .then(({ order }) => { console.log(order.id); }) @@ -13565,10 +12341,8 @@ paths: export default Swap - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/swaps/{swap_id}/process-payment' \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/swaps/{swap_id}/process-payment' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -13599,15 +12373,11 @@ paths: post: operationId: PostOrdersOrderSwapsSwapShipments summary: Ship a Swap's Fulfillment - description: >- - Create a shipment for a swap and mark its fulfillment as shipped. This - changes the swap's fulfillment status to either `partially_shipped` or - `shipped`, depending on whether all the items were shipped. + description: Create a shipment for a swap and mark its fulfillment as shipped. This changes the swap's fulfillment status to either `partially_shipped` or `shipped`, depending on whether all the items were shipped. x-authenticated: true externalDocs: description: Handling swap fulfillments - url: >- - https://docs.medusajs.com/modules/orders/swaps#handling-swap-fulfillment + url: https://docs.medusajs.com/modules/orders/swaps#handling-swap-fulfillment parameters: - in: path name: id @@ -13623,16 +12393,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - order. + description: Comma-separated fields that should be included in the returned order. schema: type: string requestBody: @@ -13646,18 +12412,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.orders.createSwapShipment(orderId, swapId, { fulfillment_id }) - .then(({ order }) => { console.log(order.id); }) @@ -13700,14 +12461,10 @@ paths: export default Swap - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/orders/{id}/swaps/{swap_id}/shipments' \ - + source: | + curl -X POST '{backend_url}/admin/orders/{id}/swaps/{swap_id}/shipments' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "fulfillment_id": "{fulfillment_id}" }' @@ -13751,16 +12508,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - payment collection. + description: Comma-separated relations that should be expanded in the returned payment collection. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - payment collection. + description: Comma-separated fields that should be included in the returned payment collection. schema: type: string x-codegen: @@ -13769,16 +12522,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.paymentCollections.retrieve(paymentCollectionId) - .then(({ payment_collection }) => { console.log(payment_collection.id) }) @@ -13862,18 +12610,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.paymentCollections.update(paymentCollectionId, { description }) - .then(({ payment_collection }) => { console.log(payment_collection.id) }) @@ -13946,9 +12689,7 @@ paths: delete: operationId: DeletePaymentCollectionsPaymentCollection summary: Delete a Payment Collection - description: >- - Delete a Payment Collection. Only payment collections with the statuses - `canceled` or `not_paid` can be deleted. + description: Delete a Payment Collection. Only payment collections with the statuses `canceled` or `not_paid` can be deleted. x-authenticated: true parameters: - in: path @@ -13962,16 +12703,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.paymentCollections.delete(paymentCollectionId) - .then(({ id, object, deleted }) => { console.log(id) }) @@ -14029,9 +12765,7 @@ paths: post: operationId: PostPaymentCollectionsPaymentCollectionAuthorize summary: Mark Authorized - description: >- - Set the status of a Payment Collection as `authorized`. This will also - change the `authorized_amount` of the payment collection. + description: Set the status of a Payment Collection as `authorized`. This will also change the `authorized_amount` of the payment collection. x-authenticated: true parameters: - in: path @@ -14045,33 +12779,24 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.paymentCollections.markAsAuthorized(paymentCollectionId) - .then(({ payment_collection }) => { console.log(payment_collection.id) }) - lang: tsx label: Medusa React - source: > + source: | import React from "react" - - import { useAdminMarkPaymentCollectionAsAuthorized } from - "medusa-react" - + import { useAdminMarkPaymentCollectionAsAuthorized } from "medusa-react" type Props = { paymentCollectionId: string } - const PaymentCollection = ({ paymentCollectionId }: Props) => { const markAsAuthorized = useAdminMarkPaymentCollectionAsAuthorized( paymentCollectionId @@ -14089,14 +12814,11 @@ paths: // ... } - export default PaymentCollection - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/payment-collections/{id}/authorize' \ - + source: | + curl -X POST '{backend_url}/admin/payment-collections/{id}/authorize' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -14142,16 +12864,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.payments.retrieve(paymentId) - .then(({ payment }) => { console.log(payment.id); }) @@ -14229,16 +12946,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.payments.capturePayment(paymentId) - .then(({ payment }) => { console.log(payment.id); }) @@ -14323,20 +13035,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.payments.refundPayment(paymentId, { amount: 1000, reason: "return", note: "Do not like it", }) - .then(({ payment }) => { console.log(payment.id); }) @@ -14417,10 +13124,7 @@ paths: get: operationId: GetPriceLists summary: List Price Lists - description: >- - Retrieve a list of price lists. The price lists can be filtered by - fields such as `q` or `status`. The price lists can also be sorted or - paginated. + description: Retrieve a list of price lists. The price lists can be filtered by fields such as `q` or `status`. The price lists can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -14437,16 +13141,12 @@ paths: default: '0' - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - price lists. + description: Comma-separated relations that should be expanded in the returned price lists. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned price - lists. + description: Comma-separated fields that should be included in the returned price lists. schema: type: string - in: query @@ -14461,9 +13161,7 @@ paths: type: string - in: query name: q - description: >- - term to search price lists' description, name, and customer group's - name. + description: term to search price lists' description, name, and customer group's name. schema: type: string - in: query @@ -14576,16 +13274,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.list() - .then(({ price_lists, limit, offset, count }) => { console.log(price_lists.length); }) @@ -14661,16 +13354,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - import { PriceListType } from "@medusajs/medusa" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.create({ name: "New Price List", description: "A new price list", @@ -14683,7 +13371,6 @@ paths: } ] }) - .then(({ price_list }) => { console.log(price_list.id); }) @@ -14789,16 +13476,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.retrieve(priceListId) - .then(({ price_list }) => { console.log(price_list.id); }) @@ -14881,18 +13563,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.update(priceListId, { name: "New Price List" }) - .then(({ price_list }) => { console.log(price_list.id); }) @@ -14979,16 +13656,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.delete(priceListId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -15073,14 +13745,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.addPrices(priceListId, { prices: [ { @@ -15090,7 +13758,6 @@ paths: } ] }) - .then(({ price_list }) => { console.log(price_list.id); }) @@ -15192,20 +13859,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.deletePrices(priceListId, { price_ids: [ price_id ] }) - .then(({ ids, object, deleted }) => { console.log(ids.length); }) @@ -15275,9 +13937,7 @@ paths: get: operationId: GetPriceListsPriceListProducts summary: List Products - description: >- - Retrieve a price list's products. The products can be filtered by fields - such as `q` or `status`. The products can also be sorted or paginated. + description: Retrieve a price list's products. The products can be filtered by fields such as `q` or `status`. The products can also be sorted or paginated. x-authenticated: true parameters: - in: path @@ -15288,9 +13948,7 @@ paths: type: string - in: query name: q - description: >- - term used to search products' title, description, product variant's - title and sku, and product collection's title. + description: term used to search products' title, description, product variant's title and sku, and product collection's title. schema: type: string - in: query @@ -15314,9 +13972,7 @@ paths: - rejected - in: query name: collection_id - description: >- - Filter by product collection ID. Only products in the specified - collections are retrieved. + description: Filter by product collection ID. Only products in the specified collections are retrieved. style: form explode: false schema: @@ -15325,9 +13981,7 @@ paths: type: string - in: query name: tags - description: >- - Filter by tag IDs. Only products having the specified tags are - retrieved. + description: Filter by tag IDs. Only products having the specified tags are retrieved. style: form explode: false schema: @@ -15351,9 +14005,7 @@ paths: type: string - in: query name: is_giftcard - description: >- - A boolean value to filter by whether the product is a gift card or - not. + description: A boolean value to filter by whether the product is a gift card or not. schema: type: string - in: query @@ -15446,16 +14098,12 @@ paths: default: 50 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - products. + description: Comma-separated relations that should be expanded in the returned products. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - products. + description: Comma-separated fields that should be included in the returned products. schema: type: string x-codegen: @@ -15464,16 +14112,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.listProducts(priceListId) - .then(({ products, limit, offset, count }) => { console.log(products.length); }) @@ -15560,21 +14203,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.deleteProductsPrices(priceListId, { product_ids: [ productId1, productId2, ] }) - .then(({ ids, object, deleted }) => { console.log(ids.length); }) @@ -15612,14 +14250,10 @@ paths: export default PriceList - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/price-lists/{id}/products/prices/batch' \ - + source: | + curl -X DELETE '{backend_url}/admin/price-lists/{id}/products/prices/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_ids": [ "prod_1", @@ -15675,16 +14309,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.deleteProductPrices(priceListId, productId) - .then(({ ids, object, deleted }) => { console.log(ids.length); }) @@ -15725,11 +14354,8 @@ paths: export default PriceListProduct - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/price-lists/{id}/products/{product_id}/prices' - \ - + source: | + curl -X DELETE '{backend_url}/admin/price-lists/{id}/products/{product_id}/prices' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -15780,16 +14406,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.priceLists.deleteVariantPrices(priceListId, variantId) - .then(({ ids, object, deleted }) => { console.log(ids); }) @@ -15830,11 +14451,8 @@ paths: export default PriceListVariant - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/price-lists/{id}/variants/{variant_id}/prices' - \ - + source: | + curl -X DELETE '{backend_url}/admin/price-lists/{id}/variants/{variant_id}/prices' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -15865,10 +14483,7 @@ paths: get: operationId: GetProductCategories summary: List Product Categories - description: >- - Retrieve a list of product categories. The product categories can be - filtered by fields such as `q` or `handle`. The product categories can - also be paginated. + description: Retrieve a list of product categories. The product categories can be filtered by fields such as `q` or `handle`. The product categories can also be paginated. x-authenticated: true x-featureFlag: product_categories parameters: @@ -15894,9 +14509,7 @@ paths: type: boolean - in: query name: include_descendants_tree - description: >- - If set to `true`, all nested descendants of a category are included - in the response. + description: If set to `true`, all nested descendants of a category are included in the response. schema: type: boolean - in: query @@ -15906,9 +14519,7 @@ paths: type: string - in: query name: offset - description: >- - The number of product categories to skip when retrieving the product - categories. + description: The number of product categories to skip when retrieving the product categories. schema: type: integer default: 0 @@ -15920,16 +14531,12 @@ paths: default: 100 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product categories. + description: Comma-separated relations that should be expanded in the returned product categories. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product categories. + description: Comma-separated fields that should be included in the returned product categories. schema: type: string x-codegen: @@ -15938,16 +14545,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productCategories.list() - .then(({ product_categories, limit, offset, count }) => { console.log(product_categories.length); }) @@ -16022,16 +14624,12 @@ paths: parameters: - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product category. + description: Comma-separated relations that should be expanded in the returned product category. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product category. + description: Comma-separated fields that should be included in the returned product category. schema: type: string requestBody: @@ -16045,18 +14643,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productCategories.create({ name: "Skinny Jeans", }) - .then(({ product_category }) => { console.log(product_category.id); }) @@ -16136,16 +14729,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product category. + description: Comma-separated relations that should be expanded in the returned product category. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product category. + description: Comma-separated fields that should be included in the returned product category. schema: type: string x-codegen: @@ -16154,16 +14743,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productCategories.retrieve(productCategoryId) - .then(({ product_category }) => { console.log(product_category.id); }) @@ -16242,16 +14826,12 @@ paths: type: string - in: query name: expand - description: >- - (Comma separated) Which fields should be expanded in each product - category. + description: (Comma separated) Which fields should be expanded in each product category. schema: type: string - in: query name: fields - description: >- - (Comma separated) Which fields should be retrieved in each product - category. + description: (Comma separated) Which fields should be retrieved in each product category. schema: type: string requestBody: @@ -16265,18 +14845,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productCategories.update(productCategoryId, { name: "Skinny Jeans" }) - .then(({ product_category }) => { console.log(product_category.id); }) @@ -16366,16 +14941,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productCategories.delete(productCategoryId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -16455,38 +15025,29 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product category. + description: Comma-separated relations that should be expanded in the returned product category. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product category. + description: Comma-separated fields that should be included in the returned product category. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostProductCategoriesCategoryProductsBatchReq + $ref: '#/components/schemas/AdminPostProductCategoriesCategoryProductsBatchReq' x-codegen: method: addProducts queryParams: AdminPostProductCategoriesCategoryProductsBatchParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productCategories.addProducts(productCategoryId, { product_ids: [ { @@ -16494,7 +15055,6 @@ paths: } ] }) - .then(({ product_category }) => { console.log(product_category.id); }) @@ -16538,14 +15098,10 @@ paths: export default Category - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/product-categories/{id}/products/batch' \ - + source: | + curl -X POST '{backend_url}/admin/product-categories/{id}/products/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_ids": [ { @@ -16593,38 +15149,29 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product category. + description: Comma-separated relations that should be expanded in the returned product category. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product category. + description: Comma-separated fields that should be included in the returned product category. schema: type: string requestBody: content: application/json: schema: - $ref: >- - #/components/schemas/AdminDeleteProductCategoriesCategoryProductsBatchReq + $ref: '#/components/schemas/AdminDeleteProductCategoriesCategoryProductsBatchReq' x-codegen: method: removeProducts queryParams: AdminDeleteProductCategoriesCategoryProductsBatchParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productCategories.removeProducts(productCategoryId, { product_ids: [ { @@ -16632,7 +15179,6 @@ paths: } ] }) - .then(({ product_category }) => { console.log(product_category.id); }) @@ -16676,14 +15222,10 @@ paths: export default Category - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/product-categories/{id}/products/batch' \ - + source: | + curl -X DELETE '{backend_url}/admin/product-categories/{id}/products/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_ids": [ { @@ -16720,10 +15262,7 @@ paths: get: operationId: GetProductTags summary: List Product Tags - description: >- - Retrieve a list of product tags. The product tags can be filtered by - fields such as `q` or `value`. The product tags can also be sorted or - paginated. + description: Retrieve a list of product tags. The product tags can be filtered by fields such as `q` or `value`. The product tags can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -16745,9 +15284,7 @@ paths: type: string - in: query name: discount_condition_id - description: >- - Filter by the ID of a discount condition. Only product tags that - this discount condition is applied to will be retrieved. + description: Filter by the ID of a discount condition. Only product tags that this discount condition is applied to will be retrieved. schema: type: string - in: query @@ -16823,16 +15360,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productTags.list() - .then(({ product_tags }) => { console.log(product_tags.length); }) @@ -16902,10 +15434,7 @@ paths: get: operationId: GetProductTypes summary: List Product Types - description: >- - Retrieve a list of product types. The product types can be filtered by - fields such as `q` or `value`. The product types can also be sorted or - paginated. + description: Retrieve a list of product types. The product types can be filtered by fields such as `q` or `value`. The product types can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -16916,9 +15445,7 @@ paths: default: 20 - in: query name: offset - description: >- - The number of product types to skip when retrieving the product - types. + description: The number of product types to skip when retrieving the product types. schema: type: integer default: 0 @@ -16929,9 +15456,7 @@ paths: type: string - in: query name: discount_condition_id - description: >- - Filter by the ID of a discount condition. Only product types that - this discount condition is applied to will be retrieved. + description: Filter by the ID of a discount condition. Only product types that this discount condition is applied to will be retrieved. schema: type: string - in: query @@ -17007,16 +15532,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.productTypes.list() - .then(({ product_types }) => { console.log(product_types.length); }) @@ -17086,23 +15606,17 @@ paths: get: operationId: GetProducts summary: List Products - description: >- - Retrieve a list of products. The products can be filtered by fields such - as `q` or `status`. The products can also be sorted or paginated. + description: Retrieve a list of products. The products can be filtered by fields such as `q` or `status`. The products can also be sorted or paginated. x-authenticated: true parameters: - in: query name: q - description: >- - term to search products' title, description, variants' title and - sku, and collections' title. + description: term to search products' title, description, variants' title and sku, and collections' title. schema: type: string - in: query name: discount_condition_id - description: >- - Filter by the ID of a discount condition. Only products that this - discount condition is applied to will be retrieved. + description: Filter by the ID of a discount condition. Only products that this discount condition is applied to will be retrieved. schema: type: string - in: query @@ -17136,9 +15650,7 @@ paths: name: collection_id style: form explode: false - description: >- - Filter by product collection IDs. Only products that are associated - with the specified collections will be retrieved. + description: Filter by product collection IDs. Only products that are associated with the specified collections will be retrieved. schema: type: array items: @@ -17147,9 +15659,7 @@ paths: name: tags style: form explode: false - description: >- - Filter by product tag IDs. Only products that are associated with - the specified tags will be retrieved. + description: Filter by product tag IDs. Only products that are associated with the specified tags will be retrieved. schema: type: array items: @@ -17158,9 +15668,7 @@ paths: name: price_list_id style: form explode: false - description: >- - Filter by IDs of price lists. Only products that these price lists - are applied to will be retrieved. + description: Filter by IDs of price lists. Only products that these price lists are applied to will be retrieved. schema: type: array items: @@ -17169,9 +15677,7 @@ paths: name: sales_channel_id style: form explode: false - description: >- - Filter by sales channel IDs. Only products that are available in the - specified sales channels will be retrieved. + description: Filter by sales channel IDs. Only products that are available in the specified sales channels will be retrieved. schema: type: array items: @@ -17180,9 +15686,7 @@ paths: name: type_id style: form explode: false - description: >- - Filter by product type IDs. Only products that are associated with - the specified types will be retrieved. + description: Filter by product type IDs. Only products that are associated with the specified types will be retrieved. schema: type: array items: @@ -17191,9 +15695,7 @@ paths: name: category_id style: form explode: false - description: >- - Filter by product category IDs. Only products that are associated - with the specified categories will be retrieved. + description: Filter by product category IDs. Only products that are associated with the specified categories will be retrieved. schema: type: array x-featureFlag: product_categories @@ -17203,9 +15705,7 @@ paths: name: include_category_children style: form explode: false - description: >- - whether to include product category children when filtering by - `category_id` + description: whether to include product category children when filtering by `category_id` schema: type: boolean x-featureFlag: product_categories @@ -17309,16 +15809,12 @@ paths: default: 50 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - products. + description: Comma-separated relations that should be expanded in the returned products. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - products. + description: Comma-separated fields that should be included in the returned products. schema: type: string - in: query @@ -17332,16 +15828,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.list() - .then(({ products, limit, offset, count }) => { console.log(products.length); }) @@ -17404,9 +15895,7 @@ paths: operationId: PostProducts summary: Create a Product x-authenticated: true - description: >- - Create a new Product. This API Route can also be used to create a gift - card if the `is_giftcard` field is set to `true`. + description: Create a new Product. This API Route can also be used to create a gift card if the `is_giftcard` field is set to `true`. requestBody: content: application/json: @@ -17417,20 +15906,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.create({ title: "Shirt", is_giftcard: false, discountable: true }) - .then(({ product }) => { console.log(product.id); }) @@ -17523,25 +16007,18 @@ paths: get: operationId: GetProductsTagUsage summary: List Tags Usage Number - description: >- - Retrieve a list of Product Tags with how many times each is used in - products. + description: Retrieve a list of Product Tags with how many times each is used in products. x-authenticated: true x-codegen: method: listTags x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.listTags() - .then(({ tags }) => { console.log(tags.length); }) @@ -17612,16 +16089,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.listTypes() - .then(({ types }) => { console.log(types.length); }) @@ -17673,16 +16145,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.retrieve(productId) - .then(({ product }) => { console.log(product.id); }) @@ -17764,18 +16231,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.update(productId, { title: "Shirt", }) - .then(({ product }) => { console.log(product.id); }) @@ -17862,16 +16324,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.delete(productId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -17937,13 +16394,10 @@ paths: post: operationId: PostProductsProductMetadata summary: Set Metadata - description: >- - Set the metadata of a Product. It can be any key-value pair, which - allows adding custom data to a product. + description: Set the metadata of a Product. It can be any key-value pair, which allows adding custom data to a product. externalDocs: description: Learn about the metadata attribute, and how to delete and update it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute x-authenticated: true parameters: - in: path @@ -17962,19 +16416,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.setMetadata(productId, { key: "test", value: "true" }) - .then(({ product }) => { console.log(product.id); }) @@ -18036,18 +16485,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.addOption(productId, { title: "Size" }) - .then(({ product }) => { console.log(product.id); }) @@ -18146,18 +16590,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.updateOption(productId, optionId, { title: "Size" }) - .then(({ product }) => { console.log(product.id); }) @@ -18200,14 +16639,10 @@ paths: export default ProductOption - lang: Shell label: cURL - source: > - curl -X POST '{backend_url}/admin/products/{id}/options/{option_id}' - \ - + source: | + curl -X POST '{backend_url}/admin/products/{id}/options/{option_id}' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "title": "Size" }' @@ -18239,9 +16674,7 @@ paths: delete: operationId: DeleteProductsProductOptionsOption summary: Delete a Product Option - description: >- - Delete a Product Option. If there are product variants that use this - product option, they must be deleted before deleting the product option. + description: Delete a Product Option. If there are product variants that use this product option, they must be deleted before deleting the product option. x-authenticated: true parameters: - in: path @@ -18261,16 +16694,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.deleteOption(productId, optionId) - .then(({ option_id, object, deleted, product }) => { console.log(product.id); }) @@ -18308,10 +16736,8 @@ paths: export default ProductOption - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/products/{id}/options/{option_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/products/{id}/options/{option_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -18342,14 +16768,10 @@ paths: get: operationId: GetProductsProductVariants summary: List a Product's Variants - description: > - Retrieve a list of Product Variants associated with a Product. The - variants can be paginated. + description: | + Retrieve a list of Product Variants associated with a Product. The variants can be paginated. - - By default, each variant will only have the `id` and `variant_id` - fields. You can use the `expand` and `fields` request parameters to - retrieve more fields or relations. + By default, each variant will only have the `id` and `variant_id` fields. You can use the `expand` and `fields` request parameters to retrieve more fields or relations. x-authenticated: true parameters: - in: path @@ -18360,23 +16782,17 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product variants. + description: Comma-separated fields that should be included in the returned product variants. schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product variants. + description: Comma-separated relations that should be expanded in the returned product variants. schema: type: string - in: query name: offset - description: >- - The number of product variants to skip when retrieving the product - variants. + description: The number of product variants to skip when retrieving the product variants. schema: type: integer default: 0 @@ -18423,9 +16839,7 @@ paths: post: operationId: PostProductsProductVariants summary: Create a Product Variant - description: >- - Create a Product Variant associated with a Product. Each product variant - must have a unique combination of Product Option values. + description: Create a Product Variant associated with a Product. Each product variant must have a unique combination of Product Option values. x-authenticated: true parameters: - in: path @@ -18444,14 +16858,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.createVariant(productId, { title: "Color", prices: [ @@ -18468,7 +16878,6 @@ paths: ], inventory_quantity: 100 }) - .then(({ product }) => { console.log(product.id); }) @@ -18589,14 +16998,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.updateVariant(productId, variantId, { title: "Color", prices: [ @@ -18613,7 +17018,6 @@ paths: ], inventory_quantity: 100 }) - .then(({ product }) => { console.log(product.id); }) @@ -18654,14 +17058,10 @@ paths: export default ProductVariant - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/products/{id}/variants/{variant_id}' \ - + source: | + curl -X POST '{backend_url}/admin/products/{id}/variants/{variant_id}' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "title": "Color", "prices": [ @@ -18719,16 +17119,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.products.deleteVariant(productId, variantId) - .then(({ variant_id, object, deleted, product }) => { console.log(product.id); }) @@ -18766,10 +17161,8 @@ paths: export default ProductVariant - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/products/{id}/variants/{variant_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/products/{id}/variants/{variant_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -18800,10 +17193,7 @@ paths: get: operationId: GetPublishableApiKeys summary: List Publishable API keys - description: >- - Retrieve a list of publishable API keys. The publishable API keys can be - filtered by fields such as `q`. The publishable API keys can also be - paginated. + description: Retrieve a list of publishable API keys. The publishable API keys can be filtered by fields such as `q`. The publishable API keys can also be paginated. x-authenticated: true parameters: - in: query @@ -18819,24 +17209,18 @@ paths: default: '20' - in: query name: offset - description: >- - The number of publishable API keys to skip when retrieving the - publishable API keys. + description: The number of publishable API keys to skip when retrieving the publishable API keys. schema: type: number default: '0' - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - publishable API keys. + description: Comma-separated relations that should be expanded in the returned publishable API keys. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - publishable API keys. + description: Comma-separated fields that should be included in the returned publishable API keys. schema: type: string x-codegen: @@ -18845,16 +17229,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.publishableApiKeys.list() - .then(({ publishable_api_keys, count, limit, offset }) => { console.log(publishable_api_keys) }) @@ -18937,18 +17316,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.publishableApiKeys.create({ title }) - .then(({ publishable_api_key }) => { console.log(publishable_api_key.id) }) @@ -19028,16 +17402,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.publishableApiKeys.retrieve(publishableApiKeyId) - .then(({ publishable_api_key }) => { console.log(publishable_api_key.id) }) @@ -19117,25 +17486,19 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostPublishableApiKeysPublishableApiKeyReq + $ref: '#/components/schemas/AdminPostPublishableApiKeysPublishableApiKeyReq' x-codegen: method: update x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.publishableApiKeys.update(publishableApiKeyId, { title: "new title" }) - .then(({ publishable_api_key }) => { console.log(publishable_api_key.id) }) @@ -19208,9 +17571,7 @@ paths: delete: operationId: DeletePublishableApiKeysPublishableApiKey summary: Delete Publishable API Key - description: >- - Delete a Publishable API Key. Associated resources, such as sales - channels, are not deleted. + description: Delete a Publishable API Key. Associated resources, such as sales channels, are not deleted. x-authenticated: true parameters: - in: path @@ -19224,16 +17585,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.publishableApiKeys.delete(publishableApiKeyId) - .then(({ id, object, deleted }) => { console.log(id) }) @@ -19291,9 +17647,7 @@ paths: post: operationId: PostPublishableApiKeysPublishableApiKeyRevoke summary: Revoke a Publishable API Key - description: >- - Revoke a Publishable API Key. Revoking the publishable API Key can't be - undone, and the key can't be used in future requests. + description: Revoke a Publishable API Key. Revoking the publishable API Key can't be undone, and the key can't be used in future requests. parameters: - in: path name: id @@ -19307,16 +17661,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.publishableApiKeys.revoke(publishableApiKeyId) - .then(({ publishable_api_key }) => { console.log(publishable_api_key.id) }) @@ -19352,10 +17701,8 @@ paths: export default PublishableApiKey - lang: Shell label: cURL - source: > - curl -X POST '{backend_url}/admin/publishable-api-keys/{id}/revoke' - \ - + source: | + curl -X POST '{backend_url}/admin/publishable-api-keys/{id}/revoke' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -19386,9 +17733,7 @@ paths: get: operationId: GetPublishableApiKeySalesChannels summary: List Sales Channels - description: >- - List the sales channels associated with a publishable API key. The sales - channels can be filtered by fields such as `q`. + description: List the sales channels associated with a publishable API key. The sales channels can be filtered by fields such as `q`. x-authenticated: true parameters: - in: path @@ -19408,16 +17753,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.publishableApiKeys.listSalesChannels() - .then(({ sales_channels }) => { console.log(sales_channels.length) }) @@ -19461,10 +17801,8 @@ paths: export default SalesChannels - lang: Shell label: cURL - source: > - curl '{backend_url}/admin/publishable-api-keys/{id}/sales-channels' - \ - + source: | + curl '{backend_url}/admin/publishable-api-keys/{id}/sales-channels' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -19478,8 +17816,7 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPublishableApiKeysListSalesChannelsRes + $ref: '#/components/schemas/AdminPublishableApiKeysListSalesChannelsRes' '400': $ref: '#/components/responses/400_error' '401': @@ -19509,30 +17846,23 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostPublishableApiKeySalesChannelsBatchReq + $ref: '#/components/schemas/AdminPostPublishableApiKeySalesChannelsBatchReq' x-codegen: method: addSalesChannelsBatch x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.publishableApiKeys.addSalesChannelsBatch(publishableApiKeyId, - { + medusa.admin.publishableApiKeys.addSalesChannelsBatch(publishableApiKeyId, { sales_channel_ids: [ { id: channelId } ] }) - .then(({ publishable_api_key }) => { console.log(publishable_api_key.id); }) @@ -19577,14 +17907,10 @@ paths: export default PublishableApiKey - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/publishable-api-keys/{pak_id}/batch' \ - + source: | + curl -X POST '{backend_url}/admin/publishable-api-keys/{pak_id}/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "sales_channel_ids": [ { @@ -19620,10 +17946,7 @@ paths: delete: operationId: DeletePublishableApiKeySalesChannelsChannelsBatch summary: Remove Sales Channels - description: >- - Remove a list of sales channels from a publishable API key. This doesn't - delete the sales channels and only removes the association between them - and the publishable API key. + description: Remove a list of sales channels from a publishable API key. This doesn't delete the sales channels and only removes the association between them and the publishable API key. x-authenticated: true parameters: - in: path @@ -19636,30 +17959,23 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminDeletePublishableApiKeySalesChannelsBatchReq + $ref: '#/components/schemas/AdminDeletePublishableApiKeySalesChannelsBatchReq' x-codegen: method: deleteSalesChannelsBatch x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.admin.publishableApiKeys.deleteSalesChannelsBatch(publishableApiKeyId, - { + medusa.admin.publishableApiKeys.deleteSalesChannelsBatch(publishableApiKeyId, { sales_channel_ids: [ { id: channelId } ] }) - .then(({ publishable_api_key }) => { console.log(publishable_api_key.id); }) @@ -19704,14 +18020,10 @@ paths: export default PublishableApiKey - lang: Shell label: cURL - source: > - curl -X DELETE '{backend_url}/admin/publishable-api-keys/{id}/batch' - \ - + source: | + curl -X DELETE '{backend_url}/admin/publishable-api-keys/{id}/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "sales_channel_ids": [ { @@ -19748,11 +18060,19 @@ paths: get: operationId: GetRegions summary: List Regions - description: >- - Retrieve a list of Regions. The regions can be filtered by fields such - as `created_at`. The regions can also be paginated. + description: Retrieve a list of Regions. The regions can be filtered by fields such as `created_at`. The regions can also be paginated. x-authenticated: true parameters: + - in: query + name: q + description: Term used to search regions' name. + schema: + type: string + - in: query + name: order + description: A field to sort-order the retrieved regions by. + schema: + type: string - in: query name: limit schema: @@ -19842,16 +18162,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.list() - .then(({ regions, limit, offset, count }) => { console.log(regions.length); }) @@ -19925,14 +18240,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.create({ name: "Europe", currency_code: "eur", @@ -19947,7 +18258,6 @@ paths: "DK" ] }) - .then(({ region }) => { console.log(region.id); }) @@ -20045,16 +18355,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.retrieve(regionId) - .then(({ region }) => { console.log(region.id); }) @@ -20136,18 +18441,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.update(regionId, { name: "Europe" }) - .then(({ region }) => { console.log(region.id); }) @@ -20220,9 +18520,7 @@ paths: delete: operationId: DeleteRegionsRegion summary: Delete a Region - description: >- - Delete a Region. Associated resources, such as providers or currencies - are not deleted. Associated tax rates are deleted. + description: Delete a Region. Associated resources, such as providers or currencies are not deleted. Associated tax rates are deleted. x-authenticated: true parameters: - in: path @@ -20236,16 +18534,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.delete(regionId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -20330,18 +18623,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.addCountry(regionId, { country_code: "dk" }) - .then(({ region }) => { console.log(region.id); }) @@ -20416,10 +18704,7 @@ paths: operationId: PostRegionsRegionCountriesCountry summary: Remove Country x-authenticated: true - description: >- - Remove a Country from the list of Countries in a Region. The country - will still be available in the system, and it can be used in other - regions. + description: Remove a Country from the list of Countries in a Region. The country will still be available in the system, and it can be used in other regions. parameters: - in: path name: id @@ -20441,16 +18726,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.deleteCountry(regionId, "dk") - .then(({ region }) => { console.log(region.id); }) @@ -20486,10 +18766,8 @@ paths: export default Region - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/regions/{id}/countries/{country_code}' \ - + source: | + curl -X DELETE '{backend_url}/admin/regions/{id}/countries/{country_code}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -20534,16 +18812,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.retrieveFulfillmentOptions(regionId) - .then(({ fulfillment_options }) => { console.log(fulfillment_options.length); }) @@ -20605,8 +18878,7 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminGetRegionsRegionFulfillmentOptionsRes + $ref: '#/components/schemas/AdminGetRegionsRegionFulfillmentOptionsRes' '400': $ref: '#/components/responses/400_error' '401': @@ -20623,9 +18895,7 @@ paths: post: operationId: PostRegionsRegionFulfillmentProviders summary: Add Fulfillment Provider - description: >- - Add a Fulfillment Provider to the list of fulfullment providers in a - Region. + description: Add a Fulfillment Provider to the list of fulfullment providers in a Region. x-authenticated: true parameters: - in: path @@ -20638,25 +18908,19 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostRegionsRegionFulfillmentProvidersReq + $ref: '#/components/schemas/AdminPostRegionsRegionFulfillmentProvidersReq' x-codegen: method: addFulfillmentProvider x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.addFulfillmentProvider(regionId, { provider_id: "manual" }) - .then(({ region }) => { console.log(region.id); }) @@ -20697,14 +18961,10 @@ paths: export default Region - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/regions/{id}/fulfillment-providers' \ - + source: | + curl -X POST '{backend_url}/admin/regions/{id}/fulfillment-providers' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "provider_id": "manual" }' @@ -20737,9 +18997,7 @@ paths: delete: operationId: PostRegionsRegionFulfillmentProvidersProvider summary: Remove Fulfillment Provider - description: >- - Remove a Fulfillment Provider from a Region. The fulfillment provider - will still be available for usage in other regions. + description: Remove a Fulfillment Provider from a Region. The fulfillment provider will still be available for usage in other regions. x-authenticated: true parameters: - in: path @@ -20759,16 +19017,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.deleteFulfillmentProvider(regionId, "manual") - .then(({ region }) => { console.log(region.id); }) @@ -20807,11 +19060,8 @@ paths: export default Region - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/regions/{id}/fulfillment-providers/{provider_id}' - \ - + source: | + curl -X DELETE '{backend_url}/admin/regions/{id}/fulfillment-providers/{provider_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -20861,18 +19111,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.addPaymentProvider(regionId, { provider_id: "manual" }) - .then(({ region }) => { console.log(region.id); }) @@ -20949,9 +19194,7 @@ paths: delete: operationId: PostRegionsRegionPaymentProvidersProvider summary: Remove Payment Provider - description: >- - Remove a Payment Provider from a Region. The payment provider will still - be available for usage in other regions. + description: Remove a Payment Provider from a Region. The payment provider will still be available for usage in other regions. x-authenticated: true parameters: - in: path @@ -20971,16 +19214,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.regions.deletePaymentProvider(regionId, "manual") - .then(({ region }) => { console.log(region.id); }) @@ -21019,10 +19257,8 @@ paths: export default Region - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/regions/{id}/payment-providers/{provider_id}' \ - + source: | + curl -X DELETE '{backend_url}/admin/regions/{id}/payment-providers/{provider_id}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -21053,10 +19289,7 @@ paths: get: operationId: GetReservations summary: List Reservations - description: >- - Retrieve a list of Reservations. The reservations can be filtered by - fields such as `location_id` or `quantity`. The reservations can also be - paginated. + description: Retrieve a list of Reservations. The reservations can be filtered by fields such as `location_id` or `quantity`. The reservations can also be paginated. x-authenticated: true parameters: - in: query @@ -21100,14 +19333,10 @@ paths: description: filter by reservation quantity greater than this number lte: type: number - description: >- - filter by reservation quantity less than or equal to this - number + description: filter by reservation quantity less than or equal to this number gte: type: number - description: >- - filter by reservation quantity greater than or equal to this - number + description: filter by reservation quantity greater than or equal to this number - in: query name: description description: Filter by description. @@ -21119,19 +19348,13 @@ paths: properties: contains: type: string - description: >- - filter by reservation description containing search - string. + description: filter by reservation description containing search string. starts_with: type: string - description: >- - filter by reservation description starting with search - string. + description: filter by reservation description starting with search string. ends_with: type: string - description: >- - filter by reservation description ending with search - string. + description: filter by reservation description ending with search string. - in: query name: created_at description: Filter by a creation date range. @@ -21168,16 +19391,12 @@ paths: default: 20 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - reservations. + description: Comma-separated relations that should be expanded in the returned reservations. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - reservations. + description: Comma-separated fields that should be included in the returned reservations. schema: type: string x-codegen: @@ -21186,16 +19405,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.reservations.list() - .then(({ reservations, count, limit, offset }) => { console.log(reservations.length) }) @@ -21259,9 +19473,7 @@ paths: post: operationId: PostReservations summary: Create a Reservation - description: >- - Create a Reservation which can be associated with any resource, such as - an order's line item. + description: Create a Reservation which can be associated with any resource, such as an order's line item. x-authenticated: true requestBody: content: @@ -21271,21 +19483,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.reservations.create({ line_item_id: "item_123", location_id: "loc_123", inventory_item_id: "iitem_123", quantity: 1 }) - .then(({ reservation }) => { console.log(reservation.id); }) @@ -21372,16 +19579,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.reservations.retrieve(reservationId) - .then(({ reservation }) => { console.log(reservation.id); }) @@ -21459,18 +19661,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.reservations.update(reservationId, { quantity: 3 }) - .then(({ reservation }) => { console.log(reservation.id); }) @@ -21539,9 +19736,7 @@ paths: delete: operationId: DeleteReservationsReservation summary: Delete a Reservation - description: >- - Delete a Reservation. Associated resources, such as the line item, will - not be deleted. + description: Delete a Reservation. Associated resources, such as the line item, will not be deleted. x-authenticated: true parameters: - in: path @@ -21555,16 +19750,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.reservations.delete(reservationId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -21637,16 +19827,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returnReasons.list() - .then(({ return_reasons }) => { console.log(return_reasons.length); }) @@ -21724,19 +19909,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returnReasons.create({ label: "Damaged", value: "damaged" }) - .then(({ return_reason }) => { console.log(return_reason.id); }) @@ -21821,16 +20001,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returnReasons.retrieve(returnReasonId) - .then(({ return_reason }) => { console.log(return_reason.id); }) @@ -21910,18 +20085,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returnReasons.update(returnReasonId, { label: "Damaged" }) - .then(({ return_reason }) => { console.log(return_reason.id); }) @@ -22008,16 +20178,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returnReasons.delete(returnReasonId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -22103,16 +20268,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returns.list() - .then(({ returns, limit, offset, count }) => { console.log(returns.length) }) @@ -22179,9 +20339,7 @@ paths: post: operationId: PostReturnsReturnCancel summary: Cancel a Return - description: >- - Registers a Return as canceled. The return can be associated with an - order, claim, or swap. + description: Registers a Return as canceled. The return can be associated with an order, claim, or swap. parameters: - in: path name: id @@ -22194,16 +20352,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returns.cancel(returnId) - .then(({ order }) => { console.log(order.id) }) @@ -22269,9 +20422,7 @@ paths: post: operationId: PostReturnsReturnReceive summary: Receive a Return - description: >- - Mark a Return as received. This also updates the status of associated - order, claim, or swap accordingly. + description: Mark a Return as received. This also updates the status of associated order, claim, or swap accordingly. parameters: - in: path name: id @@ -22289,14 +20440,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.returns.receive(returnId, { items: [ { @@ -22305,7 +20452,6 @@ paths: } ] }) - .then((data) => { console.log(data.return.id); }) @@ -22387,10 +20533,7 @@ paths: get: operationId: GetSalesChannels summary: List Sales Channels - description: >- - Retrieve a list of sales channels. The sales channels can be filtered by - fields such as `q` or `name`. The sales channels can also be sorted or - paginated. + description: Retrieve a list of sales channels. The sales channels can be filtered by fields such as `q` or `name`. The sales channels can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -22486,9 +20629,7 @@ paths: format: date - in: query name: offset - description: >- - The number of sales channels to skip when retrieving the sales - channels. + description: The number of sales channels to skip when retrieving the sales channels. schema: type: integer default: 0 @@ -22500,16 +20641,12 @@ paths: default: 20 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - sales channels. + description: Comma-separated relations that should be expanded in the returned sales channels. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned sales - channels. + description: Comma-separated fields that should be included in the returned sales channels. schema: type: string x-codegen: @@ -22518,16 +20655,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.list() - .then(({ sales_channels, limit, offset, count }) => { console.log(sales_channels.length) }) @@ -22603,19 +20735,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.create({ name: "App", description: "Mobile app" }) - .then(({ sales_channel }) => { console.log(sales_channel.id); }) @@ -22696,16 +20823,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.retrieve(salesChannelId) - .then(({ sales_channel }) => { console.log(sales_channel.id); }) @@ -22786,18 +20908,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.update(salesChannelId, { name: "App" }) - .then(({ sales_channel }) => { console.log(sales_channel.id); }) @@ -22870,9 +20987,7 @@ paths: delete: operationId: DeleteSalesChannelsSalesChannel summary: Delete a Sales Channel - description: >- - Delete a sales channel. Associated products, stock locations, and other - resources are not deleted. + description: Delete a sales channel. Associated products, stock locations, and other resources are not deleted. x-authenticated: true parameters: - in: path @@ -22886,16 +21001,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.delete(salesChannelId) - .then(({ id, object, deleted }) => { console.log(id) }) @@ -22974,21 +21084,16 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostSalesChannelsChannelProductsBatchReq + $ref: '#/components/schemas/AdminPostSalesChannelsChannelProductsBatchReq' x-codegen: method: addProducts x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.addProducts(salesChannelId, { product_ids: [ { @@ -22996,7 +21101,6 @@ paths: } ] }) - .then(({ sales_channel }) => { console.log(sales_channel.id); }) @@ -23036,14 +21140,10 @@ paths: export default SalesChannel - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/sales-channels/{id}/products/batch' \ - + source: | + curl -X POST '{backend_url}/admin/sales-channels/{id}/products/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_ids": [ { @@ -23079,10 +21179,7 @@ paths: delete: operationId: DeleteSalesChannelsChannelProductsBatch summary: Remove Products from Sales Channel - description: >- - Remove a list of products from a sales channel. This does not delete the - product. It only removes the association between the product and the - sales channel. + description: Remove a list of products from a sales channel. This does not delete the product. It only removes the association between the product and the sales channel. x-authenticated: true parameters: - in: path @@ -23095,21 +21192,16 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminDeleteSalesChannelsChannelProductsBatchReq + $ref: '#/components/schemas/AdminDeleteSalesChannelsChannelProductsBatchReq' x-codegen: method: removeProducts x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.removeProducts(salesChannelId, { product_ids: [ { @@ -23117,7 +21209,6 @@ paths: } ] }) - .then(({ sales_channel }) => { console.log(sales_channel.id) }) @@ -23159,14 +21250,10 @@ paths: export default SalesChannel - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/sales-channels/{id}/products/batch' \ - + source: | + curl -X DELETE '{backend_url}/admin/sales-channels/{id}/products/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_ids": [ { @@ -23216,25 +21303,19 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminPostSalesChannelsChannelStockLocationsReq + $ref: '#/components/schemas/AdminPostSalesChannelsChannelStockLocationsReq' x-codegen: method: addLocation x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.addLocation(salesChannelId, { location_id: "loc_123" }) - .then(({ sales_channel }) => { console.log(sales_channel.id); }) @@ -23271,14 +21352,10 @@ paths: export default SalesChannel - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/sales-channels/{id}/stock-locations' \ - + source: | + curl -X POST '{backend_url}/admin/sales-channels/{id}/stock-locations' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "locaton_id": "loc_123" }' @@ -23310,10 +21387,7 @@ paths: delete: operationId: DeleteSalesChannelsSalesChannelStockLocation summary: Remove Stock Location from Sales Channels. - description: >- - Remove a stock location from a Sales Channel. This only removes the - association between the stock location and the sales channel. It does - not delete the stock location. + description: Remove a stock location from a Sales Channel. This only removes the association between the stock location and the sales channel. It does not delete the stock location. x-authenticated: true parameters: - in: path @@ -23326,25 +21400,19 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminDeleteSalesChannelsChannelStockLocationsReq + $ref: '#/components/schemas/AdminDeleteSalesChannelsChannelStockLocationsReq' x-codegen: method: removeLocation x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.salesChannels.removeLocation(salesChannelId, { location_id: "loc_id" }) - .then(({ sales_channel }) => { console.log(sales_channel.id); }) @@ -23381,14 +21449,10 @@ paths: export default SalesChannel - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/sales-channels/{id}/stock-locations' \ - + source: | + curl -X DELETE '{backend_url}/admin/sales-channels/{id}/stock-locations' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "locaton_id": "loc_id" }' @@ -23421,42 +21485,151 @@ paths: get: operationId: GetShippingOptions summary: List Shipping Options - description: >- - Retrieve a list of Shipping Options. The shipping options can be - filtered by fields such as `region_id` or `is_return`. + description: Retrieve a list of Shipping Options. The shipping options can be filtered by fields such as `region_id` or `is_return`. The shipping options can also be sorted or paginated. x-authenticated: true parameters: - in: query - name: region_id + name: name + description: Filter by name. + schema: + type: string + - in: query + name: region_id + description: Filter by the ID of the region the shipping options belong to. schema: type: string - description: Filter by a region ID. - in: query name: is_return - description: Filter by whether the shipping option is used for returns or orders. + description: Filter by whether the shipping options are return shipping options. schema: type: boolean - in: query name: admin_only + description: Filter by whether the shipping options are available for admin users only. schema: type: boolean - description: Filter by whether the shipping option is used only by admins or not. + - in: query + name: q + description: Term used to search shipping options' name. + schema: + type: string + - in: query + name: order + description: A shipping option field to sort-order the retrieved shipping options by. + schema: + type: string + - in: query + name: id + style: form + explode: false + description: Filter by shipping option IDs. + schema: + oneOf: + - type: string + description: ID of the shipping option. + - type: array + items: + type: string + description: ID of a shipping option. + - in: query + name: created_at + description: Filter by a creation date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: updated_at + description: Filter by an update date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: deleted_at + description: Filter by a deletion date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: offset + description: The number of users to skip when retrieving the shipping options. + schema: + type: integer + default: 0 + - in: query + name: limit + description: Limit the number of shipping options returned. + schema: + type: integer + default: 20 + - in: query + name: expand + description: Comma-separated relations that should be expanded in the returned shipping options. + schema: + type: string + - in: query + name: fields + description: Comma-separated fields that should be included in the returned shipping options. + schema: + type: string x-codegen: method: list queryParams: AdminGetShippingOptionsParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingOptions.list() - .then(({ shipping_options, count }) => { console.log(shipping_options.length); }) @@ -23535,14 +21708,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingOptions.create({ name: "PostFake", region_id, @@ -23551,7 +21720,6 @@ paths: }, price_type: "flat_rate" }) - .then(({ shipping_option }) => { console.log(shipping_option.id); }) @@ -23650,16 +21818,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingOptions.retrieve(optionId) - .then(({ shipping_option }) => { console.log(shipping_option.id); }) @@ -23742,14 +21905,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingOptions.update(optionId, { name: "PostFake", requirements: [ @@ -23760,7 +21919,6 @@ paths: } ] }) - .then(({ shipping_option }) => { console.log(shipping_option.id); }) @@ -23844,9 +22002,7 @@ paths: delete: operationId: DeleteShippingOptionsOption summary: Delete Shipping Option - description: >- - Delete a Shipping Option. Once deleted, it can't be used when creating - orders or returns. + description: Delete a Shipping Option. Once deleted, it can't be used when creating orders or returns. x-authenticated: true parameters: - in: path @@ -23860,16 +22016,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingOptions.delete(optionId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -23942,16 +22093,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingProfiles.list() - .then(({ shipping_profiles }) => { console.log(shipping_profiles.length); }) @@ -24030,18 +22176,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingProfiles.create({ name: "Large Products" }) - .then(({ shipping_profile }) => { console.log(shipping_profile.id); }) @@ -24126,16 +22267,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingProfiles.retrieve(profileId) - .then(({ shipping_profile }) => { console.log(shipping_profile.id); }) @@ -24219,18 +22355,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingProfiles.update(shippingProfileId, { name: 'Large Products' }) - .then(({ shipping_profile }) => { console.log(shipping_profile.id); }) @@ -24306,9 +22437,7 @@ paths: delete: operationId: DeleteShippingProfilesProfile summary: Delete a Shipping Profile - description: >- - Delete a Shipping Profile. Associated shipping options are deleted as - well. + description: Delete a Shipping Profile. Associated shipping options are deleted as well. x-authenticated: true parameters: - in: path @@ -24322,16 +22451,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.shippingProfiles.delete(profileId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -24397,10 +22521,7 @@ paths: get: operationId: GetStockLocations summary: List Stock Locations - description: >- - Retrieve a list of stock locations. The stock locations can be filtered - by fields such as `name` or `created_at`. The stock locations can also - be sorted or paginated. + description: Retrieve a list of stock locations. The stock locations can be filtered by fields such as `name` or `created_at`. The stock locations can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -24415,9 +22536,7 @@ paths: type: string - in: query name: order - description: >- - A stock-location field to sort-order the retrieved stock locations - by. + description: A stock-location field to sort-order the retrieved stock locations by. schema: type: string - in: query @@ -24488,9 +22607,7 @@ paths: format: date - in: query name: offset - description: >- - The number of stock locations to skip when retrieving the stock - locations. + description: The number of stock locations to skip when retrieving the stock locations. schema: type: integer default: 0 @@ -24502,16 +22619,12 @@ paths: default: 20 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - stock locations. + description: Comma-separated relations that should be expanded in the returned stock locations. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned stock - locations. + description: Comma-separated fields that should be included in the returned stock locations. schema: type: string x-codegen: @@ -24520,16 +22633,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.stockLocations.list() - .then(({ stock_locations, limit, offset, count }) => { console.log(stock_locations.length); }) @@ -24603,16 +22711,12 @@ paths: parameters: - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - stock location. + description: Comma-separated relations that should be expanded in the returned stock location. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned stock - location. + description: Comma-separated fields that should be included in the returned stock location. schema: type: string requestBody: @@ -24625,18 +22729,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.stockLocations.create({ name: "Main Warehouse", }) - .then(({ stock_location }) => { console.log(stock_location.id); }) @@ -24713,16 +22812,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - stock location. + description: Comma-separated relations that should be expanded in the returned stock location. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned stock - location. + description: Comma-separated fields that should be included in the returned stock location. schema: type: string x-codegen: @@ -24731,16 +22826,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.stockLocations.retrieve(stockLocationId) - .then(({ stock_location }) => { console.log(stock_location.id); }) @@ -24803,16 +22893,12 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - stock location. + description: Comma-separated relations that should be expanded in the returned stock location. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned stock - location. + description: Comma-separated fields that should be included in the returned stock location. schema: type: string requestBody: @@ -24825,18 +22911,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.stockLocations.update(stockLocationId, { name: 'Main Warehouse' }) - .then(({ stock_location }) => { console.log(stock_location.id); }) @@ -24919,16 +23000,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.stockLocations.delete(stockLocationId) - .then(({ id, object, deleted }) => { console.log(id) }) @@ -24989,16 +23065,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.store.retrieve() - .then(({ store }) => { console.log(store.id); }) @@ -25068,18 +23139,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.store.update({ name: "Medusa Store" }) - .then(({ store }) => { console.log(store.id); }) @@ -25145,11 +23211,7 @@ paths: post: operationId: PostStoreCurrenciesCode summary: Add a Currency Code - description: >- - Add a Currency Code to the available currencies in a store. This does - not create new currencies, as currencies are defined within the Medusa - backend. To create a currency, you can create a migration that inserts - the currency into the database. + description: Add a Currency Code to the available currencies in a store. This does not create new currencies, as currencies are defined within the Medusa backend. To create a currency, you can create a migration that inserts the currency into the database. x-authenticated: true parameters: - in: path @@ -25166,16 +23228,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.store.addCurrency("eur") - .then(({ store }) => { console.log(store.currencies); }) @@ -25203,10 +23260,8 @@ paths: export default Store - lang: Shell label: cURL - source: > - curl -X POST '{backend_url}/admin/store/currencies/{currency_code}' - \ - + source: | + curl -X POST '{backend_url}/admin/store/currencies/{currency_code}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -25236,10 +23291,7 @@ paths: delete: operationId: DeleteStoreCurrenciesCode summary: Remove a Currency - description: >- - Remove a Currency Code from the available currencies in a store. This - does not completely delete the currency and it can be added again later - to the store. + description: Remove a Currency Code from the available currencies in a store. This does not completely delete the currency and it can be added again later to the store. x-authenticated: true parameters: - in: path @@ -25256,16 +23308,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.store.deleteCurrency("eur") - .then(({ store }) => { console.log(store.currencies); }) @@ -25293,10 +23340,8 @@ paths: export default Store - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/store/currencies/{currency_code}' \ - + source: | + curl -X DELETE '{backend_url}/admin/store/currencies/{currency_code}' \ -H 'x-medusa-access-token: {api_token}' security: - api_token: [] @@ -25334,16 +23379,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.store.listPaymentProviders() - .then(({ payment_providers }) => { console.log(payment_providers.length); }) @@ -25419,16 +23459,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.store.listTaxProviders() - .then(({ tax_providers }) => { console.log(tax_providers.length); }) @@ -25518,16 +23553,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.swaps.list() - .then(({ swaps }) => { console.log(swaps.length); }) @@ -25604,16 +23634,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.swaps.retrieve(swapId) - .then(({ swap }) => { console.log(swap.id); }) @@ -25673,9 +23698,7 @@ paths: get: operationId: GetTaxRates summary: List Tax Rates - description: >- - Retrieve a list of Tax Rates. The tax rates can be filtered by fields - such as `name` or `rate`. The tax rates can also be paginated. + description: Retrieve a list of Tax Rates. The tax rates can be filtered by fields such as `name` or `rate`. The tax rates can also be paginated. x-authenticated: true parameters: - in: query @@ -25735,9 +23758,7 @@ paths: default: 50 - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -25746,9 +23767,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -25761,16 +23780,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.list() - .then(({ tax_rates, limit, offset, count }) => { console.log(tax_rates.length); }) @@ -25841,9 +23855,7 @@ paths: parameters: - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -25852,9 +23864,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -25873,20 +23883,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.create({ code: "TEST", name: "New Tax Rate", region_id }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -25975,9 +23980,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -25986,9 +23989,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26002,16 +24003,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.retrieve(taxRateId) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -26080,9 +24076,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -26091,9 +24085,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26112,18 +24104,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.update(taxRateId, { name: "New Tax Rate" }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -26194,9 +24181,7 @@ paths: delete: operationId: DeleteTaxRatesTaxRate summary: Delete a Tax Rate - description: >- - Delete a Tax Rate. Resources associated with the tax rate, such as - products or product types, are not deleted. + description: Delete a Tax Rate. Resources associated with the tax rate, such as products or product types, are not deleted. x-authenticated: true parameters: - in: path @@ -26210,16 +24195,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.delete(taxRateId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -26293,9 +24273,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -26304,9 +24282,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26325,20 +24301,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.addProductTypes(taxRateId, { product_types: [ productTypeId ] }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -26376,14 +24347,10 @@ paths: export default TaxRate - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/tax-rates/{id}/product-types/batch' \ - + source: | + curl -X POST '{backend_url}/admin/tax-rates/{id}/product-types/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_types": [ "{product_type_id}" @@ -26417,10 +24384,7 @@ paths: delete: operationId: DeleteTaxRatesTaxRateProductTypes summary: Remove Product Types from Rate - description: >- - Remove product types from a tax rate. This only removes the association - between the product types and the tax rate. It does not delete the - product types. + description: Remove product types from a tax rate. This only removes the association between the product types and the tax rate. It does not delete the product types. parameters: - in: path name: id @@ -26430,9 +24394,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -26441,9 +24403,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26462,20 +24422,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.removeProductTypes(taxRateId, { product_types: [ productTypeId ] }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -26515,14 +24470,10 @@ paths: export default TaxRate - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/tax-rates/{id}/product-types/batch' \ - + source: | + curl -X DELETE '{backend_url}/admin/tax-rates/{id}/product-types/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "product_types": [ "{product_type_id}" @@ -26567,9 +24518,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -26578,9 +24527,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26599,20 +24546,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.addProducts(taxRateId, { products: [ productId ] }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -26683,9 +24625,7 @@ paths: delete: operationId: DeleteTaxRatesTaxRateProducts summary: Remove Products from Rate - description: >- - Remove products from a tax rate. This only removes the association - between the products and the tax rate. It does not delete the products. + description: Remove products from a tax rate. This only removes the association between the products and the tax rate. It does not delete the products. parameters: - in: path name: id @@ -26695,9 +24635,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -26706,9 +24644,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26727,20 +24663,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.removeProducts(taxRateId, { products: [ productId ] }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -26822,9 +24753,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -26833,9 +24762,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26854,20 +24781,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.addShippingOptions(taxRateId, { shipping_options: [ shippingOptionId ] }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -26905,14 +24827,10 @@ paths: export default TaxRate - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/admin/tax-rates/{id}/shipping-options/batch' \ - + source: | + curl -X POST '{backend_url}/admin/tax-rates/{id}/shipping-options/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "shipping_options": [ "{shipping_option_id}" @@ -26946,10 +24864,7 @@ paths: delete: operationId: DeleteTaxRatesTaxRateShippingOptions summary: Remove Shipping Options from Rate - description: >- - Remove shipping options from a tax rate. This only removes the - association between the shipping options and the tax rate. It does not - delete the shipping options. + description: Remove shipping options from a tax rate. This only removes the association between the shipping options and the tax rate. It does not delete the shipping options. parameters: - in: path name: id @@ -26959,9 +24874,7 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned tax - rate. + description: Comma-separated fields that should be included in the returned tax rate. style: form explode: false schema: @@ -26970,9 +24883,7 @@ paths: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - tax rate. + description: Comma-separated relations that should be expanded in the returned tax rate. style: form explode: false schema: @@ -26984,28 +24895,22 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/AdminDeleteTaxRatesTaxRateShippingOptionsReq + $ref: '#/components/schemas/AdminDeleteTaxRatesTaxRateShippingOptionsReq' x-codegen: method: removeShippingOptions queryParams: AdminDeleteTaxRatesTaxRateShippingOptionsParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.taxRates.removeShippingOptions(taxRateId, { shipping_options: [ shippingOptionId ] }) - .then(({ tax_rate }) => { console.log(tax_rate.id); }) @@ -27043,14 +24948,10 @@ paths: export default TaxRate - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/admin/tax-rates/{id}/shipping-options/batch' \ - + source: | + curl -X DELETE '{backend_url}/admin/tax-rates/{id}/shipping-options/batch' \ -H 'x-medusa-access-token: {api_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "shipping_options": [ "{shipping_option_id}" @@ -27085,9 +24986,7 @@ paths: post: operationId: PostUploads summary: Upload Files - description: >- - Upload at least one file to a public bucket or storage. The file upload - is handled by the file service installed on the Medusa backend. + description: Upload at least one file to a public bucket or storage. The file upload is handled by the file service installed on the Medusa backend. x-authenticated: true requestBody: content: @@ -27101,16 +25000,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.uploads.create(file) - .then(({ uploads }) => { console.log(uploads.length); }) @@ -27172,9 +25066,7 @@ paths: delete: operationId: DeleteUploads summary: Delete an Uploaded File - description: >- - Delete an uploaded file from storage. The file is deleted using the - installed file service on the Medusa backend. + description: Delete an uploaded file from storage. The file is deleted using the installed file service on the Medusa backend. x-authenticated: true requestBody: content: @@ -27184,18 +25076,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.uploads.delete({ file_key }) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -27261,10 +25148,7 @@ paths: post: operationId: PostUploadsDownloadUrl summary: Get a File's Download URL - description: >- - Create and retrieve a presigned or public download URL for a file. The - URL creation is handled by the file service installed on the Medusa - backend. + description: Create and retrieve a presigned or public download URL for a file. The URL creation is handled by the file service installed on the Medusa backend. x-authenticated: true requestBody: content: @@ -27274,18 +25158,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.uploads.getPresignedDownloadUrl({ file_key }) - .then(({ download_url }) => { console.log(download_url); }) @@ -27351,9 +25230,7 @@ paths: post: operationId: PostUploadsProtected summary: Protected File Upload - description: >- - Upload at least one file to an ACL or a non-public bucket. The file - upload is handled by the file service installed on the Medusa backend. + description: Upload at least one file to an ACL or a non-public bucket. The file upload is handled by the file service installed on the Medusa backend. x-authenticated: true requestBody: content: @@ -27367,16 +25244,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.uploads.createProtected(file) - .then(({ uploads }) => { console.log(uploads.length); }) @@ -27439,24 +25311,142 @@ paths: get: operationId: GetUsers summary: List Users - description: Retrieve all admin users. + description: Retrieves a list of users. The users can be filtered by fields such as `q` or `email`. The users can also be sorted or paginated. x-authenticated: true + parameters: + - in: query + name: email + description: Filter by email. + schema: + type: string + - in: query + name: first_name + description: Filter by first name. + schema: + type: string + - in: query + name: last_name + description: Filter by last name. + schema: + type: string + - in: query + name: q + description: Term used to search users' first name, last name, and email. + schema: + type: string + - in: query + name: order + description: A user field to sort-order the retrieved users by. + schema: + type: string + - in: query + name: id + style: form + explode: false + description: Filter by user IDs. + schema: + oneOf: + - type: string + description: ID of the user. + - type: array + items: + type: string + description: ID of a user. + - in: query + name: created_at + description: Filter by a creation date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: updated_at + description: Filter by an update date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: deleted_at + description: Filter by a deletion date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: offset + description: The number of users to skip when retrieving the users. + schema: + type: integer + default: 0 + - in: query + name: limit + description: Limit the number of users returned. + schema: + type: integer + default: 20 + - in: query + name: fields + description: Comma-separated fields that should be included in the returned users. + schema: + type: string x-codegen: method: list + queryParams: AdminGetUsersParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.users.list() - - .then(({ users }) => { + .then(({ users, limit, offset, count }) => { console.log(users.length); }) - lang: tsx @@ -27517,10 +25507,7 @@ paths: post: operationId: PostUsers summary: Create a User - description: >- - Create an admin User. The user has the same privileges as all admin - users, and will be able to authenticate and perform admin - functionalities right after creation. + description: Create an admin User. The user has the same privileges as all admin users, and will be able to authenticate and perform admin functionalities right after creation. x-authenticated: true requestBody: content: @@ -27532,19 +25519,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.users.create({ email: "user@example.com", password: "supersecret" }) - .then(({ user }) => { console.log(user.id); }) @@ -27612,19 +25594,10 @@ paths: post: operationId: PostUsersUserPasswordToken summary: Request Password Reset - description: >- - Generate a password token for an admin user with a given email. This - also triggers the `user.password_reset` event. So, if you have a - Notification Service installed that can handle this event, a - notification, such as an email, will be sent to the user. The token is - triggered as part of the `user.password_reset` event's payload. That - token must be used later to reset the password using the [Reset - Password](https://docs.medusajs.com/api/admin#users_postusersuserpassword) - API Route. + description: Generate a password token for an admin user with a given email. This also triggers the `user.password_reset` event. So, if you have a Notification Service installed that can handle this event, a notification, such as an email, will be sent to the user. The token is triggered as part of the `user.password_reset` event's payload. That token must be used later to reset the password using the [Reset Password](https://docs.medusajs.com/api/admin#users_postusersuserpassword) API Route. externalDocs: description: How to reset a user's password - url: >- - https://docs.medusajs.com/modules/users/admin/manage-profile#reset-password + url: https://docs.medusajs.com/modules/users/admin/manage-profile#reset-password requestBody: content: application/json: @@ -27635,22 +25608,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.users.sendResetPasswordToken({ email: "user@example.com" }) - .then(() => { // successful }) - .catch(() => { // error occurred }) @@ -27714,14 +25681,10 @@ paths: post: operationId: PostUsersUserPassword summary: Reset Password - description: >- - Reset the password of an admin User using their reset password token. A - user must request to reset their password first before attempting to - reset their password with this request. + description: Reset the password of an admin User using their reset password token. A user must request to reset their password first before attempting to reset their password with this request. externalDocs: description: How to reset a user's password - url: >- - https://docs.medusajs.com/modules/users/admin/manage-profile#reset-password + url: https://docs.medusajs.com/modules/users/admin/manage-profile#reset-password requestBody: content: application/json: @@ -27732,19 +25695,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.users.resetPassword({ token: "supersecrettoken", password: "supersecret" }) - .then(({ user }) => { console.log(user.id); }) @@ -27829,16 +25787,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.users.retrieve(userId) - .then(({ user }) => { console.log(user.id); }) @@ -27918,18 +25871,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.users.update(userId, { first_name: "Marcellus" }) - .then(({ user }) => { console.log(user.id); }) @@ -28000,9 +25948,7 @@ paths: delete: operationId: DeleteUsersUser summary: Delete a User - description: >- - Delete a User. Once deleted, the user will not be able to authenticate - or perform admin functionalities. + description: Delete a User. Once deleted, the user will not be able to authenticate or perform admin functionalities. x-authenticated: true parameters: - in: path @@ -28016,16 +25962,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.users.delete(userId) - .then(({ id, object, deleted }) => { console.log(id); }) @@ -28089,10 +26030,7 @@ paths: get: operationId: GetVariants summary: List Product Variants - description: >- - Retrieve a list of Product Variants. The product variant can be filtered - by fields such as `id` or `title`. The product variant can also be - paginated. + description: Retrieve a list of Product Variants. The product variant can be filtered by fields such as `id` or `title`. The product variant can also be paginated. x-authenticated: true parameters: - in: query @@ -28110,23 +26048,17 @@ paths: type: string - in: query name: expand - description: >- - "Comma-separated relations that should be expanded in the returned - product variants." + description: '"Comma-separated relations that should be expanded in the returned product variants."' schema: type: string - in: query name: fields - description: >- - "Comma-separated fields that should be included in the returned - product variants." + description: '"Comma-separated fields that should be included in the returned product variants."' schema: type: string - in: query name: offset - description: >- - The number of product variants to skip when retrieving the product - variants. + description: The number of product variants to skip when retrieving the product variants. schema: type: number default: '0' @@ -28152,21 +26084,17 @@ paths: type: string externalDocs: description: Price selection context overview - url: >- - https://docs.medusajs.com/modules/price-lists/price-selection-strategy#context-object + url: https://docs.medusajs.com/modules/price-lists/price-selection-strategy#context-object - in: query name: currency_code style: form explode: false - description: >- - The 3 character ISO currency code to use for the price selection - context. + description: The 3 character ISO currency code to use for the price selection context. schema: type: string externalDocs: description: Price selection context overview - url: >- - https://docs.medusajs.com/modules/price-lists/price-selection-strategy#context-object + url: https://docs.medusajs.com/modules/price-lists/price-selection-strategy#context-object - in: query name: customer_id style: form @@ -28176,8 +26104,7 @@ paths: type: string externalDocs: description: Price selection context overview - url: >- - https://docs.medusajs.com/modules/price-lists/price-selection-strategy#context-object + url: https://docs.medusajs.com/modules/price-lists/price-selection-strategy#context-object - in: query name: title style: form @@ -28209,30 +26136,21 @@ paths: description: filter by inventory quantity greater than this number lte: type: number - description: >- - filter by inventory quantity less than or equal to this - number + description: filter by inventory quantity less than or equal to this number gte: type: number - description: >- - filter by inventory quantity greater than or equal to this - number + description: filter by inventory quantity greater than or equal to this number x-codegen: method: list queryParams: AdminGetVariantsParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.variants.list() - .then(({ variants, limit, offset, count }) => { console.log(variants.length); }) @@ -28308,16 +26226,12 @@ paths: type: string - in: query name: expand - description: >- - "Comma-separated relations that should be expanded in the returned - product variant." + description: '"Comma-separated relations that should be expanded in the returned product variant."' schema: type: string - in: query name: fields - description: >- - "Comma-separated fields that should be included in the returned - product variant." + description: '"Comma-separated fields that should be included in the returned product variant."' schema: type: string x-codegen: @@ -28326,16 +26240,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.variants.retrieve(variantId) - .then(({ variant }) => { console.log(variant.id); }) @@ -28411,16 +26320,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.admin.variants.getInventory(variantId) - .then(({ variant }) => { console.log(variant.inventory, variant.sales_channel_availability) }) @@ -28507,9 +26411,7 @@ components: $ref: '#/components/schemas/Error' example: code: unknown_error - message: >- - The request conflicted with another request. You may retry the - request with the provided Idempotency-Key. + message: The request conflicted with another request. You may retry the request with the provided Idempotency-Key. type: QueryRunnerAlreadyReleasedError invalid_request_error: description: Invalid Request Error @@ -28590,9 +26492,7 @@ components: multiple_errors: summary: Multiple Errors value: - message: >- - Provided request body contains errors. Please check the data and retry - the request + message: Provided request body contains errors. Please check the data and retry the request errors: - message: first_name must be a string type: invalid_data @@ -28638,10 +26538,7 @@ components: schemas: Address: title: Address - description: >- - An address is used across the Medusa backend within other schemas and - object types. For example, a customer's billing and shipping addresses - both use the Address entity. + description: An address is used across the Medusa backend within other schemas and object types. For example, a customer's billing and shipping addresses both use the Address entity. type: object required: - address_1 @@ -28709,8 +26606,7 @@ components: nullable: true type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. example: st country: @@ -28753,11 +26649,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AddressCreatePayload: type: object description: Address fields used when creating an address. @@ -28799,8 +26692,7 @@ components: description: The 2 character ISO code of the country in lower case type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. example: st province: @@ -28851,8 +26743,7 @@ components: description: The 2 character ISO code of the country in lower case type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. example: st province: @@ -28969,9 +26860,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product collections skipped when retrieving the - product collections. + description: The number of product collections skipped when retrieving the product collections. limit: type: integer description: The number of items per page @@ -29005,9 +26894,7 @@ components: description: The last name of the User. type: string role: - description: >- - The role assigned to the user. These roles don't provide any - different privileges. + description: The role assigned to the user. These roles don't provide any different privileges. type: string enum: - admin @@ -29085,9 +26972,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of customer groups skipped when retrieving the customer - groups. + description: The number of customer groups skipped when retrieving the customer groups. limit: type: integer description: The number of items per page @@ -29241,9 +27126,7 @@ components: type: string AdminDeletePublishableApiKeySalesChannelsBatchReq: type: object - description: >- - The details of the sales channels to remove from the publishable API - key. + description: The details of the sales channels to remove from the publishable API key. required: - sales_channel_ids properties: @@ -29309,39 +27192,29 @@ components: properties: product_types: type: array - description: >- - The IDs of the product types to remove their association with this - tax rate. + description: The IDs of the product types to remove their association with this tax rate. items: type: string AdminDeleteTaxRatesTaxRateProductsReq: type: object - description: >- - The details of the products to remove their associated with the tax - rate. + description: The details of the products to remove their associated with the tax rate. required: - products properties: products: type: array - description: >- - The IDs of the products to remove their association with this tax - rate. + description: The IDs of the products to remove their association with this tax rate. items: type: string AdminDeleteTaxRatesTaxRateShippingOptionsReq: type: object - description: >- - The details of the shipping options to remove their associate with the - tax rate. + description: The details of the shipping options to remove their associate with the tax rate. required: - shipping_options properties: shipping_options: type: array - description: >- - The IDs of the shipping options to remove their association with - this tax rate. + description: The IDs of the shipping options to remove their association with this tax rate. items: type: string AdminDeleteUploadsReq: @@ -29351,9 +27224,7 @@ components: - file_key properties: file_key: - description: >- - key of the file to delete. This is obtained when you first uploaded - the file, or by the file service if you used it directly. + description: key of the file to delete. This is obtained when you first uploaded the file, or by the file service if you used it directly. type: string AdminDeleteUploadsRes: type: object @@ -29610,9 +27481,7 @@ components: $ref: '#/components/schemas/DraftOrder' AdminExtendedStoresRes: type: object - description: >- - The store's details with additional details like payment and tax - providers. + description: The store's details with additional details like payment and tax providers. x-expanded-relations: field: store relations: @@ -29761,9 +27630,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of inventory items skipped when retrieving the inventory - items. + description: The number of inventory items skipped when retrieving the inventory items. limit: type: integer description: The number of items per page @@ -29785,9 +27652,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of inventory items skipped when retrieving the inventory - items. + description: The number of inventory items skipped when retrieving the inventory items. limit: type: integer description: The number of items per page @@ -29919,9 +27784,7 @@ components: description: The total number of notifications offset: type: integer - description: >- - The number of notifications skipped when retrieving the - notifications. + description: The number of notifications skipped when retrieving the notifications. limit: type: integer description: The number of notifications per page @@ -30425,15 +28288,11 @@ components: properties: type: type: string - description: >- - The type of batch job to start, which is defined by the `batchType` - property of the associated batch job strategy. + description: The type of batch job to start, which is defined by the `batchType` property of the associated batch job strategy. example: product-export context: type: object - description: >- - Additional infomration regarding the batch to be used for - processing. + description: Additional infomration regarding the batch to be used for processing. example: shape: prices: @@ -30452,9 +28311,7 @@ components: - images dry_run: type: boolean - description: >- - Set a batch job in dry_run mode, which would delay executing the - batch job until it's confirmed. + description: Set a batch job in dry_run mode, which would delay executing the batch job until it's confirmed. default: false AdminPostCollectionsCollectionReq: type: object @@ -30465,18 +28322,13 @@ components: description: The title of the collection. handle: type: string - description: >- - An optional handle to be used in slugs. If none is provided, the - kebab-case version of the title will be used. + description: An optional handle to be used in slugs. If none is provided, the kebab-case version of the title will be used. metadata: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostCollectionsReq: type: object description: The product collection's details. @@ -30488,18 +28340,13 @@ components: description: The title of the collection. handle: type: string - description: >- - An optional handle to be used in slugs. If none is provided, the - kebab-case version of the title will be used. + description: An optional handle to be used in slugs. If none is provided, the kebab-case version of the title will be used. metadata: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostCurrenciesCurrencyReq: type: object description: The details to update in the currency @@ -30536,11 +28383,8 @@ components: description: Metadata of the customer group. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostCustomerGroupsReq: type: object description: The details of the customer group to create. @@ -30554,20 +28398,15 @@ components: type: object description: Metadata of the customer group. externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostCustomersCustomerReq: type: object description: The details of the customer to update. properties: email: type: string - description: >- - The Customer's email. You can't update the email of a registered - customer. + description: The Customer's email. You can't update the email of a registered customer. format: email first_name: type: string @@ -30597,11 +28436,8 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostCustomersReq: type: object description: The details of the customer to create. @@ -30632,22 +28468,15 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostDiscountsDiscountConditions: type: object required: - operator properties: operator: - description: >- - Operator of the condition. `in` indicates that discountable - resources are within the specified resources. `not_in` indicates - that discountable resources are everything but the specified - resources. + description: Operator of the condition. `in` indicates that discountable resources are within the specified resources. `not_in` indicates that discountable resources are everything but the specified resources. type: string enum: - in @@ -30664,9 +28493,7 @@ components: type: string product_collections: type: array - description: >- - list of product collection IDs if the condition's type is - `product_collections`. + description: list of product collection IDs if the condition's type is `product_collections`. items: type: string product_tags: @@ -30676,9 +28503,7 @@ components: type: string customer_groups: type: array - description: >- - list of customer group IDs if the condition's type is - `customer_groups`. + description: list of customer group IDs if the condition's type is `customer_groups`. items: type: string AdminPostDiscountsDiscountConditionsCondition: @@ -30696,9 +28521,7 @@ components: type: string product_collections: type: array - description: >- - list of product collection IDs if the condition's type is - `product_collections`. + description: list of product collection IDs if the condition's type is `product_collections`. items: type: string product_tags: @@ -30708,9 +28531,7 @@ components: type: string customer_groups: type: array - description: >- - list of customer group IDs if the condition's type is - `customer_groups`. + description: list of customer group IDs if the condition's type is `customer_groups`. items: type: string AdminPostDiscountsDiscountConditionsConditionBatchReq: @@ -30747,11 +28568,8 @@ components: type: object description: An optional set of key-value pairs to hold additional information. externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostDiscountsDiscountReq: type: object description: The details of the discount to update. @@ -30773,26 +28591,16 @@ components: description: A short description of the discount value: type: number - description: >- - The value that the discount represents. This will depend on the - type of the discount. + description: The value that the discount represents. This will depend on the type of the discount. allocation: type: string - description: >- - The scope that the discount should apply to. `total` indicates - that the discount should be applied on the cart total, and - `item` indicates that the discount should be applied to each - discountable item in the cart. + description: The scope that the discount should apply to. `total` indicates that the discount should be applied on the cart total, and `item` indicates that the discount should be applied to each discountable item in the cart. enum: - total - item conditions: type: array - description: >- - A set of conditions that can be used to limit when the discount - can be used. Only one of `products`, `product_types`, - `product_collections`, `product_tags`, and `customer_groups` - should be provided based on the discount condition's type. + description: A set of conditions that can be used to limit when the discount can be used. Only one of `products`, `product_types`, `product_collections`, `product_tags`, and `customer_groups` should be provided based on the discount condition's type. items: type: object required: @@ -30803,11 +28611,7 @@ components: description: The ID of the condition operator: type: string - description: >- - Operator of the condition. `in` indicates that - discountable resources are within the specified resources. - `not_in` indicates that discountable resources are - everything but the specified resources. + description: Operator of the condition. `in` indicates that discountable resources are within the specified resources. `not_in` indicates that discountable resources are everything but the specified resources. enum: - in - not_in @@ -30818,37 +28622,27 @@ components: type: string product_types: type: array - description: >- - list of product type IDs if the condition's type is - `product_types`. + description: list of product type IDs if the condition's type is `product_types`. items: type: string product_collections: type: array - description: >- - list of product collection IDs if the condition's type is - `product_collections`. + description: list of product collection IDs if the condition's type is `product_collections`. items: type: string product_tags: type: array - description: >- - list of product tag IDs if the condition's type is - `product_tags`. + description: list of product tag IDs if the condition's type is `product_tags`. items: type: string customer_groups: type: array - description: >- - list of customer group IDs if the condition's type is - `customer_groups`. + description: list of customer group IDs if the condition's type is `customer_groups`. items: type: string is_disabled: type: boolean - description: >- - Whether the discount code is disabled on creation. If set to `true`, - it will not be available for customers. + description: Whether the discount code is disabled on creation. If set to `true`, it will not be available for customers. starts_at: type: string format: date-time @@ -30856,9 +28650,7 @@ components: ends_at: type: string format: date-time - description: >- - The date and time at which the discount should no longer be - available. + description: The date and time at which the discount should no longer be available. valid_duration: type: string description: The duration the discount runs between @@ -30867,9 +28659,7 @@ components: type: number description: Maximum number of times the discount can be used regions: - description: >- - A list of region IDs representing the Regions in which the Discount - can be used. + description: A list of region IDs representing the Regions in which the Discount can be used. type: array items: type: string @@ -30877,11 +28667,8 @@ components: description: An object containing metadata of the discount type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostDiscountsReq: type: object description: The details of the discount to create. @@ -30895,11 +28682,7 @@ components: description: A unique code that will be used to redeem the discount is_dynamic: type: boolean - description: >- - Whether the discount should have multiple instances of itself, each - with a different code. This can be useful for automatically - generated discount codes that all have to follow a common set of - rules. + description: Whether the discount should have multiple instances of itself, each with a different code. This can be useful for automatically generated discount codes that all have to follow a common set of rules. default: false rule: description: The discount rule that defines how discounts are calculated @@ -30914,36 +28697,23 @@ components: description: A short description of the discount type: type: string - description: >- - The type of the discount, can be `fixed` for discounts that - reduce the price by a fixed amount, `percentage` for percentage - reductions or `free_shipping` for shipping vouchers. + description: The type of the discount, can be `fixed` for discounts that reduce the price by a fixed amount, `percentage` for percentage reductions or `free_shipping` for shipping vouchers. enum: - fixed - percentage - free_shipping value: type: number - description: >- - The value that the discount represents. This will depend on the - type of the discount. + description: The value that the discount represents. This will depend on the type of the discount. allocation: type: string - description: >- - The scope that the discount should apply to. `total` indicates - that the discount should be applied on the cart total, and - `item` indicates that the discount should be applied to each - discountable item in the cart. + description: The scope that the discount should apply to. `total` indicates that the discount should be applied on the cart total, and `item` indicates that the discount should be applied to each discountable item in the cart. enum: - total - item conditions: type: array - description: >- - A set of conditions that can be used to limit when the discount - can be used. Only one of `products`, `product_types`, - `product_collections`, `product_tags`, and `customer_groups` - should be provided based on the discount condition's type. + description: A set of conditions that can be used to limit when the discount can be used. Only one of `products`, `product_types`, `product_collections`, `product_tags`, and `customer_groups` should be provided based on the discount condition's type. items: type: object required: @@ -30951,11 +28721,7 @@ components: properties: operator: type: string - description: >- - Operator of the condition. `in` indicates that - discountable resources are within the specified resources. - `not_in` indicates that discountable resources are - everything but the specified resources. + description: Operator of the condition. `in` indicates that discountable resources are within the specified resources. `not_in` indicates that discountable resources are everything but the specified resources. enum: - in - not_in @@ -30966,37 +28732,27 @@ components: type: string product_types: type: array - description: >- - list of product type IDs if the condition's type is - `product_types`. + description: list of product type IDs if the condition's type is `product_types`. items: type: string product_collections: type: array - description: >- - list of product collection IDs if the condition's type is - `product_collections`. + description: list of product collection IDs if the condition's type is `product_collections`. items: type: string product_tags: type: array - description: >- - list of product tag IDs if the condition's type is - `product_tags`. + description: list of product tag IDs if the condition's type is `product_tags`. items: type: string customer_groups: type: array - description: >- - list of customer group IDs if the condition's type is - `customer_groups`. + description: list of customer group IDs if the condition's type is `customer_groups`. items: type: string is_disabled: type: boolean - description: >- - Whether the discount code is disabled on creation. If set to `true`, - it will not be available for customers. + description: Whether the discount code is disabled on creation. If set to `true`, it will not be available for customers. default: false starts_at: type: string @@ -31005,17 +28761,13 @@ components: ends_at: type: string format: date-time - description: >- - The date and time at which the discount should no longer be - available. + description: The date and time at which the discount should no longer be available. valid_duration: type: string description: The duration the discount runs between example: P3Y6M4DT12H30M5S regions: - description: >- - A list of region IDs representing the Regions in which the Discount - can be used. + description: A list of region IDs representing the Regions in which the Discount can be used. type: array items: type: string @@ -31026,19 +28778,14 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostDraftOrdersDraftOrderLineItemsItemReq: type: object description: The details to update of the line item. properties: unit_price: - description: >- - The custom price of the line item. If a `variant_id` is supplied, - the price provided here will override the variant's price. + description: The custom price of the line item. If a `variant_id` is supplied, the price provided here will override the variant's price. type: integer title: description: The title of the line item if `variant_id` is not provided. @@ -31047,16 +28794,11 @@ components: description: The quantity of the line item. type: integer metadata: - description: >- - The optional key-value map with additional details about the Line - Item. + description: The optional key-value map with additional details about the Line Item. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostDraftOrdersDraftOrderLineItemsReq: type: object description: The details of the line item to create. @@ -31064,14 +28806,10 @@ components: - quantity properties: variant_id: - description: >- - The ID of the Product Variant associated with the line item. If the - line item is custom, the `variant_id` should be omitted. + description: The ID of the Product Variant associated with the line item. If the line item is custom, the `variant_id` should be omitted. type: string unit_price: - description: >- - The custom price of the line item. If a `variant_id` is supplied, - the price provided here will override the variant's price. + description: The custom price of the line item. If a `variant_id` is supplied, the price provided here will override the variant's price. type: integer title: description: The title of the line item if `variant_id` is not provided. @@ -31081,16 +28819,11 @@ components: description: The quantity of the line item. type: integer metadata: - description: >- - The optional key-value map with additional details about the Line - Item. + description: The optional key-value map with additional details about the Line Item. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostDraftOrdersDraftOrderRegisterPaymentRes: type: object description: The order's details. @@ -31111,8 +28844,7 @@ components: type: string description: The 2 character ISO code for the Country. externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. email: type: string @@ -31140,10 +28872,7 @@ components: description: The code that a Discount is identifed by. type: string no_notification_order: - description: >- - An optional flag passed to the resulting order that indicates - whether the customer should receive notifications about order - updates. + description: An optional flag passed to the resulting order that indicates whether the customer should receive notifications about order updates. type: boolean customer_id: description: The ID of the customer this draft order is associated with. @@ -31157,10 +28886,7 @@ components: - shipping_methods properties: status: - description: >- - The status of the draft order. The draft order's default status is - `open`. It's changed to `completed` when its payment is marked as - paid. + description: The status of the draft order. The draft order's default status is `open`. It's changed to `completed` when its payment is marked as paid. type: string enum: - open @@ -31188,16 +28914,10 @@ components: - quantity properties: variant_id: - description: >- - The ID of the Product Variant associated with the line item. - If the line item is custom, the `variant_id` should be - omitted. + description: The ID of the Product Variant associated with the line item. If the line item is custom, the `variant_id` should be omitted. type: string unit_price: - description: >- - The custom price of the line item. If a `variant_id` is - supplied, the price provided here will override the variant's - price. + description: The custom price of the line item. If a `variant_id` is supplied, the price provided here will override the variant's price. type: integer title: description: The title of the line item if `variant_id` is not provided. @@ -31206,16 +28926,11 @@ components: description: The quantity of the line item. type: integer metadata: - description: >- - The optional key-value map with additional details about the - line item. + description: The optional key-value map with additional details about the line item. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and - update it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute region_id: description: The ID of the region for the draft order type: string @@ -31234,10 +28949,7 @@ components: description: The ID of the customer this draft order is associated with. type: string no_notification_order: - description: >- - An optional flag passed to the resulting order that indicates - whether the customer should receive notifications about order - updates. + description: An optional flag passed to the resulting order that indicates whether the customer should receive notifications about order updates. type: boolean shipping_methods: description: The shipping methods for the draft order @@ -31257,16 +28969,11 @@ components: description: The price of the shipping method. type: integer metadata: - description: >- - The optional key-value map with additional details about the Draft - Order. + description: The optional key-value map with additional details about the Draft Order. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostGiftCardsGiftCardReq: type: object description: The details to update of the gift card. @@ -31276,15 +28983,11 @@ components: description: The value (excluding VAT) that the Gift Card should represent. is_disabled: type: boolean - description: >- - Whether the Gift Card is disabled on creation. If set to `true`, the - gift card will not be available for customers. + description: Whether the Gift Card is disabled on creation. If set to `true`, the gift card will not be available for customers. ends_at: type: string format: date-time - description: >- - The date and time at which the Gift Card should no longer be - available. + description: The date and time at which the Gift Card should no longer be available. region_id: description: The ID of the Region in which the Gift Card can be used. type: string @@ -31292,11 +28995,8 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostGiftCardsReq: type: object description: The details of the gift card to create. @@ -31308,15 +29008,11 @@ components: description: The value (excluding VAT) that the Gift Card should represent. is_disabled: type: boolean - description: >- - Whether the Gift Card is disabled on creation. If set to `true`, the - gift card will not be available for customers. + description: Whether the Gift Card is disabled on creation. If set to `true`, the gift card will not be available for customers. ends_at: type: string format: date-time - description: >- - The date and time at which the Gift Card should no longer be - available. + description: The date and time at which the Gift Card should no longer be available. region_id: description: The ID of the Region in which the Gift Card can be used. type: string @@ -31324,58 +29020,35 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostInventoryItemsInventoryItemReq: type: object description: The attributes to update in an inventory item. properties: hs_code: - description: >- - The Harmonized System code of the Inventory Item. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string origin_country: - description: >- - The country in which the Inventory Item was produced. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Inventory Item was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Inventory Item. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string material: - description: >- - The material and composition that the Inventory Item is made of, May - be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Inventory Item is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string weight: - description: >- - The weight of the Inventory Item. May be used in shipping rate - calculations. + description: The weight of the Inventory Item. May be used in shipping rate calculations. type: number height: - description: >- - The height of the Inventory Item. May be used in shipping rate - calculations. + description: The height of the Inventory Item. May be used in shipping rate calculations. type: number width: - description: >- - The width of the Inventory Item. May be used in shipping rate - calculations. + description: The width of the Inventory Item. May be used in shipping rate calculations. type: number length: - description: >- - The length of the Inventory Item. May be used in shipping rate - calculations. + description: The length of the Inventory Item. May be used in shipping rate calculations. type: number title: description: The inventory item's title. @@ -31393,14 +29066,10 @@ components: type: object properties: stocked_quantity: - description: >- - the total stock quantity of an inventory item at the given location - ID + description: the total stock quantity of an inventory item at the given location ID type: number incoming_quantity: - description: >- - the incoming stock quantity of an inventory item at the given - location ID + description: the incoming stock quantity of an inventory item at the given location ID type: number AdminPostInventoryItemsItemLocationLevelsReq: type: object @@ -31440,63 +29109,39 @@ components: description: A generic GTIN field for the Product Variant. type: string hs_code: - description: >- - The Harmonized System code of the Inventory Item. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string inventory_quantity: description: The amount of stock kept of the associated Product Variant. type: integer default: 0 allow_backorder: - description: >- - Whether the associated Product Variant can be purchased when out of - stock. + description: Whether the associated Product Variant can be purchased when out of stock. type: boolean manage_inventory: - description: >- - Whether Medusa should keep track of the inventory for the associated - Product Variant. + description: Whether Medusa should keep track of the inventory for the associated Product Variant. type: boolean default: true weight: - description: >- - The weight of the Inventory Item. May be used in shipping rate - calculations. + description: The weight of the Inventory Item. May be used in shipping rate calculations. type: number length: - description: >- - The length of the Inventory Item. May be used in shipping rate - calculations. + description: The length of the Inventory Item. May be used in shipping rate calculations. type: number height: - description: >- - The height of the Inventory Item. May be used in shipping rate - calculations. + description: The height of the Inventory Item. May be used in shipping rate calculations. type: number width: - description: >- - The width of the Inventory Item. May be used in shipping rate - calculations. + description: The width of the Inventory Item. May be used in shipping rate calculations. type: number origin_country: - description: >- - The country in which the Inventory Item was produced. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Inventory Item was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Inventory Item. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string material: - description: >- - The material and composition that the Inventory Item is made of, May - be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Inventory Item is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string title: description: The inventory item's title. @@ -31511,11 +29156,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostInvitesInviteAcceptReq: type: object description: The details of the invite to be accepted. @@ -31524,9 +29166,7 @@ components: - user properties: token: - description: >- - The token of the invite to accept. This is a unique token generated - when the invite was created or resent. + description: The token of the invite to accept. This is a unique token generated when the invite was created or resent. type: string user: description: The details of the user to create. @@ -31553,15 +29193,11 @@ components: - role properties: user: - description: >- - The email associated with the invite. Once the invite is accepted, - the email will be associated with the created user. + description: The email associated with the invite. Once the invite is accepted, the email will be associated with the created user. type: string format: email role: - description: >- - The role of the user to be created. This does not actually change - the privileges of the user that is eventually created. + description: The role of the user to be created. This does not actually change the privileges of the user that is eventually created. type: string enum: - admin @@ -31586,14 +29222,10 @@ components: properties: resource_id: type: string - description: >- - The ID of the resource which the Note relates to. For example, an - order ID. + description: The ID of the resource which the Note relates to. For example, an order ID. resource_type: type: string - description: >- - The type of resource which the Note relates to. For example, - `order`. + description: The type of resource which the Note relates to. For example, `order`. value: type: string description: The content of the Note to create. @@ -31602,10 +29234,7 @@ components: description: The resend details. properties: to: - description: >- - A new address or user identifier that the Notification should be - sent to. If not provided, the previous `to` field of the - notification will be used. + description: A new address or user identifier that the Notification should be sent to. If not provided, the previous `to` field of the notification will be used. type: string AdminPostOrderEditsEditLineItemsLineItemReq: type: object @@ -31633,11 +29262,8 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostOrderEditsOrderEditReq: type: object description: The details to update of the order edit. @@ -31664,15 +29290,10 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute no_notification: - description: >- - If set to `true`, no notification will be sent to the customer - related to this Claim. + description: If set to `true`, no notification will be sent to the customer related to this Claim. type: boolean location_id: description: The ID of the fulfillment's location. @@ -31735,16 +29356,11 @@ components: type: string description: Image URL metadata: - description: >- - An optional set of key-value pairs to hold additional - information. + description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and - update it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute shipping_methods: description: The Shipping Methods to send the additional Line Items with. type: array @@ -31761,9 +29377,7 @@ components: description: The price to charge for the Shipping Method type: integer data: - description: >- - An optional set of key-value pairs to hold additional - information. + description: An optional set of key-value pairs to hold additional information. type: object no_notification: description: If set to true no notification will be send related to this Swap. @@ -31772,11 +29386,8 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostOrdersOrderClaimsClaimShipmentsReq: type: object required: @@ -31798,11 +29409,7 @@ components: - claim_items properties: type: - description: >- - The type of the Claim. This will determine how the Claim is treated: - `replace` Claims will result in a Fulfillment with new items being - created, while a `refund` Claim will refund the amount paid for the - claimed items. + description: 'The type of the Claim. This will determine how the Claim is treated: `replace` Claims will result in a Fulfillment with new items being created, while a `refund` Claim will refund the amount paid for the claimed items.' type: string enum: - replace @@ -31843,24 +29450,17 @@ components: items: type: string return_shipping: - description: >- - Optional details for the Return Shipping Method, if the items are to - be sent back. Providing this field will result in a return being - created and associated with the claim. + description: Optional details for the Return Shipping Method, if the items are to be sent back. Providing this field will result in a return being created and associated with the claim. type: object properties: option_id: type: string - description: >- - The ID of the Shipping Option to create the Shipping Method - from. + description: The ID of the Shipping Option to create the Shipping Method from. price: type: integer description: The price to charge for the Shipping Method. additional_items: - description: >- - The new items to send to the Customer. This is only used if the - claim's type is `replace`. + description: The new items to send to the Customer. This is only used if the claim's type is `replace`. type: array items: type: object @@ -31875,9 +29475,7 @@ components: description: The quantity of the Product Variant. type: integer shipping_methods: - description: >- - The Shipping Methods to send the additional Line Items with. This is - only used if the claim's type is `replace`. + description: The Shipping Methods to send the additional Line Items with. This is only used if the claim's type is `replace`. type: array items: type: object @@ -31892,19 +29490,13 @@ components: description: The price to charge for the Shipping Method type: integer data: - description: >- - An optional set of key-value pairs to hold additional - information. + description: An optional set of key-value pairs to hold additional information. type: object shipping_address: - description: >- - An optional shipping address to send the claimed items to. If not - provided, the parent order's shipping address will be used. + description: An optional shipping address to send the claimed items to. If not provided, the parent order's shipping address will be used. $ref: '#/components/schemas/AddressPayload' refund_amount: - description: >- - The amount to refund the customer. This is used when the claim's - type is `refund`. + description: The amount to refund the customer. This is used when the claim's type is `refund`. type: integer no_notification: description: If set to true no notification will be send related to this Claim. @@ -31916,11 +29508,8 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostOrdersOrderFulfillmentsReq: type: object description: The details of the fulfillment to be created. @@ -31946,19 +29535,14 @@ components: type: string description: The ID of the location where the items will be fulfilled from. no_notification: - description: >- - If set to `true`, no notification will be sent to the customer - related to this fulfillment. + description: If set to `true`, no notification will be sent to the customer related to this fulfillment. type: boolean metadata: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostOrdersOrderRefundsReq: type: object description: The details of the order refund. @@ -31967,9 +29551,7 @@ components: - reason properties: amount: - description: >- - The amount to refund. It should be less than or equal the - `refundable_amount` of the order. + description: The amount to refund. It should be less than or equal the `refundable_amount` of the order. type: integer reason: description: The reason for the Refund. @@ -31978,9 +29560,7 @@ components: description: A note with additional details about the Refund. type: string no_notification: - description: >- - If set to `true`, no notification will be sent to the customer - related to this Refund. + description: If set to `true`, no notification will be sent to the customer related to this Refund. type: boolean AdminPostOrdersOrderReq: type: object @@ -32043,9 +29623,7 @@ components: $ref: '#/components/schemas/LineItem' description: Items to ship no_notification: - description: >- - If set to `true`, no notification will be sent to the customer - related to this order. + description: If set to `true`, no notification will be sent to the customer related to this order. type: boolean AdminPostOrdersOrderReturnsReq: type: object @@ -32080,9 +29658,7 @@ components: properties: option_id: type: string - description: >- - The ID of the Shipping Option to create the Shipping Method - from. + description: The ID of the Shipping Option to create the Shipping Method from. price: type: integer description: The price to charge for the Shipping Method. @@ -32090,15 +29666,11 @@ components: description: An optional note with information about the Return. type: string receive_now: - description: >- - A flag to indicate if the Return should be registerd as received - immediately. + description: A flag to indicate if the Return should be registerd as received immediately. type: boolean default: false no_notification: - description: >- - If set to `true`, no notification will be sent to the customer - related to this Return. + description: If set to `true`, no notification will be sent to the customer related to this Return. type: boolean refund: description: The amount to refund. @@ -32121,9 +29693,7 @@ components: items: type: string no_notification: - description: >- - If set to true no notification will be send related to this - Shipment. + description: If set to true no notification will be send related to this Shipment. type: boolean AdminPostOrdersOrderShippingMethodsReq: type: object @@ -32134,17 +29704,13 @@ components: properties: price: type: number - description: >- - The price (excluding VAT) that should be charged for the Shipping - Method + description: The price (excluding VAT) that should be charged for the Shipping Method option_id: type: string description: The ID of the Shipping Option to create the Shipping Method from. data: type: object - description: >- - The data required for the Shipping Option to create a Shipping - Method. This depends on the Fulfillment Provider. + description: The data required for the Shipping Option to create a Shipping Method. This depends on the Fulfillment Provider. AdminPostOrdersOrderSwapsReq: type: object description: The details of the swap to create. @@ -32180,9 +29746,7 @@ components: properties: option_id: type: string - description: >- - The ID of the Shipping Option to create the Shipping Method - from. + description: The ID of the Shipping Option to create the Shipping Method from. price: type: integer description: The price to charge for the Shipping Method. @@ -32205,9 +29769,7 @@ components: type: string description: The ID of the sales channel associated with the swap. custom_shipping_options: - description: >- - An array of custom shipping options to potentially create a Shipping - Method from to send the additional items. + description: An array of custom shipping options to potentially create a Shipping Method from to send the additional items. type: array items: type: object @@ -32222,9 +29784,7 @@ components: description: The custom price of the Shipping Option. type: integer no_notification: - description: >- - If set to `true`, no notification will be sent to the customer - related to this Swap. + description: If set to `true`, no notification will be sent to the customer related to this Swap. type: boolean return_location_id: type: string @@ -32240,15 +29800,10 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute no_notification: - description: >- - If set to `true`, no notification will be sent to the customer - related to this swap. + description: If set to `true`, no notification will be sent to the customer related to this swap. type: boolean location_id: description: The ID of the fulfillment's location. @@ -32302,14 +29857,10 @@ components: description: The ID of the price. type: string region_id: - description: >- - The ID of the Region for which the price is used. This is only - required if `currecny_code` is not provided. + description: The ID of the Region for which the price is used. This is only required if `currecny_code` is not provided. type: string currency_code: - description: >- - The 3 character ISO currency code for which the price will be - used. This is only required if `region_id` is not provided. + description: The 3 character ISO currency code for which the price will be used. This is only required if `region_id` is not provided. type: string externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes @@ -32327,9 +29878,7 @@ components: description: The maximum quantity for which the price will be used. type: integer override: - description: >- - If set to `true`, the prices will replace all existing prices - associated with the Price List. + description: If set to `true`, the prices will replace all existing prices associated with the Price List. type: boolean AdminPostPriceListsPriceListPriceListReq: type: object @@ -32356,10 +29905,7 @@ components: - sale - override status: - description: >- - The status of the Price List. If the status is set to `draft`, the - prices created in the price list will not be available of the - customer. + description: The status of the Price List. If the status is set to `draft`, the prices created in the price list will not be available of the customer. type: string enum: - active @@ -32377,14 +29923,10 @@ components: description: The ID of the price. type: string region_id: - description: >- - The ID of the Region for which the price is used. This is only - required if `currecny_code` is not provided. + description: The ID of the Region for which the price is used. This is only required if `currecny_code` is not provided. type: string currency_code: - description: >- - The 3 character ISO currency code for which the price will be - used. This is only required if `region_id` is not provided. + description: The 3 character ISO currency code for which the price will be used. This is only required if `region_id` is not provided. type: string externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes @@ -32446,10 +29988,7 @@ components: - sale - override status: - description: >- - The status of the Price List. If the status is set to `draft`, the - prices created in the price list will not be available of the - customer. + description: The status of the Price List. If the status is set to `draft`, the prices created in the price list will not be available of the customer. type: string enum: - active @@ -32464,14 +30003,10 @@ components: - variant_id properties: region_id: - description: >- - The ID of the Region for which the price is used. This is only - required if `currecny_code` is not provided. + description: The ID of the Region for which the price is used. This is only required if `currecny_code` is not provided. type: string currency_code: - description: >- - The 3 character ISO currency code for which the price will be - used. This is only required if `region_id` is not provided. + description: The 3 character ISO currency code for which the price will be used. This is only required if `region_id` is not provided. type: string externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes @@ -32549,11 +30084,8 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostProductCategoriesReq: type: object description: The details of the product category to create. @@ -32568,20 +30100,13 @@ components: description: The description of the product category. handle: type: string - description: >- - The handle of the product category. If none is provided, the - kebab-case version of the name will be used. This field can be used - as a slug in URLs. + description: The handle of the product category. If none is provided, the kebab-case version of the name will be used. This field can be used as a slug in URLs. is_internal: type: boolean - description: >- - If set to `true`, the product category will only be available to - admins. + description: If set to `true`, the product category will only be available to admins. is_active: type: boolean - description: >- - If set to `false`, the product category will not be available in the - storefront. + description: If set to `false`, the product category will not be available in the storefront. parent_category_id: type: string description: The ID of the parent product category @@ -32589,11 +30114,8 @@ components: description: An optional set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostProductsProductMetadataReq: type: object required: @@ -32638,34 +30160,21 @@ components: description: The description of the Product. type: string discountable: - description: >- - A flag to indicate if discounts can be applied to the Line Items - generated from this Product + description: A flag to indicate if discounts can be applied to the Line Items generated from this Product type: boolean images: - description: >- - An array of images of the Product. Each value in the array is a URL - to the image. You can use the upload API Routes to upload the image - and obtain a URL. + description: An array of images of the Product. Each value in the array is a URL to the image. You can use the upload API Routes to upload the image and obtain a URL. type: array items: type: string thumbnail: - description: >- - The thumbnail to use for the Product. The value is a URL to the - thumbnail. You can use the upload API Routes to upload the thumbnail - and obtain a URL. + description: The thumbnail to use for the Product. The value is a URL to the thumbnail. You can use the upload API Routes to upload the thumbnail and obtain a URL. type: string handle: - description: >- - A unique handle to identify the Product by. If not provided, the - kebab-case version of the product title will be used. This can be - used as a slug in URLs. + description: A unique handle to identify the Product by. If not provided, the kebab-case version of the product title will be used. This can be used as a slug in URLs. type: string status: - description: >- - The status of the product. The product is shown to the customer only - if its status is `published`. + description: The status of the product. The product is shown to the customer only if its status is `published`. type: string enum: - draft @@ -32679,9 +30188,7 @@ components: - value properties: id: - description: >- - The ID of an existing Product Type. If not provided, a new - product type will be created. + description: The ID of an existing Product Type. If not provided, a new product type will be created. type: string value: description: The value of the Product Type. @@ -32698,14 +30205,10 @@ components: - value properties: id: - description: >- - The ID of an existing Product Tag. If not provided, a new - product tag will be created. + description: The ID of an existing Product Tag. If not provided, a new product tag will be created. type: string value: - description: >- - The value of the Tag. If the `id` is provided, the value of - the existing tag will be updated. + description: The value of the Tag. If the `id` is provided, the value of the existing tag will be updated. type: string sales_channels: description: Sales channels to associate the Product with. @@ -32730,19 +30233,13 @@ components: description: The ID of a Product Category. type: string variants: - description: >- - An array of Product Variants to create with the Product. Each - product variant must have a unique combination of Product Option - values. + description: An array of Product Variants to create with the Product. Each product variant must have a unique combination of Product Option values. type: array items: type: object properties: id: - description: >- - The id of an existing product variant. If provided, the - details of the product variant will be updated. If not, a new - product variant will be created. + description: The id of an existing product variant. If provided, the details of the product variant will be updated. If not, a new product variant will be created. type: string title: description: The title of the product variant. @@ -32766,14 +30263,10 @@ components: description: The amount of stock kept of the product variant. type: integer allow_backorder: - description: >- - Whether the product variant can be purchased when out of - stock. + description: Whether the product variant can be purchased when out of stock. type: boolean manage_inventory: - description: >- - Whether Medusa should keep track of the inventory of this - product variant. + description: Whether Medusa should keep track of the inventory of this product variant. type: boolean weight: description: The weight of the product variant. @@ -32797,24 +30290,16 @@ components: description: The material composition of the product variant. type: string metadata: - description: >- - An optional set of key-value pairs with additional - information. + description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and - update it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute prices: type: array - description: >- - An array of product variant prices. A product variant can have - different prices for each region or currency code. + description: An array of product variant prices. A product variant can have different prices for each region or currency code. externalDocs: - url: >- - https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices + url: https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices description: Product variant pricing. items: type: object @@ -32822,20 +30307,13 @@ components: - amount properties: id: - description: >- - The ID of the Price. If provided, the existing price - will be updated. Otherwise, a new price will be created. + description: The ID of the Price. If provided, the existing price will be updated. Otherwise, a new price will be created. type: string region_id: - description: >- - The ID of the Region the price will be used in. This is - only required if `currency_code` is not provided. + description: The ID of the Region the price will be used in. This is only required if `currency_code` is not provided. type: string currency_code: - description: >- - The 3 character ISO currency code the price will be used - in. This is only required if `region_id` is not - provided. + description: The 3 character ISO currency code the price will be used in. This is only required if `region_id` is not provided. type: string externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes @@ -32844,20 +30322,14 @@ components: description: The price amount. type: integer min_quantity: - description: >- - The minimum quantity required to be added to the cart - for the price to be used. + description: The minimum quantity required to be added to the cart for the price to be used. type: integer max_quantity: - description: >- - The maximum quantity required to be added to the cart - for the price to be used. + description: The maximum quantity required to be added to the cart for the price to be used. type: integer options: type: array - description: >- - An array of Product Option values that the variant corresponds - to. + description: An array of Product Option values that the variant corresponds to. items: type: object required: @@ -32898,11 +30370,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostProductsProductVariantsReq: type: object description: The details of the product variant to create. @@ -32937,9 +30406,7 @@ components: description: Whether the product variant can be purchased when out of stock. type: boolean manage_inventory: - description: >- - Whether Medusa should keep track of the inventory of this product - variant. + description: Whether Medusa should keep track of the inventory of this product variant. type: boolean default: true weight: @@ -32967,19 +30434,13 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute prices: type: array - description: >- - An array of product variant prices. A product variant can have - different prices for each region or currency code. + description: An array of product variant prices. A product variant can have different prices for each region or currency code. externalDocs: - url: >- - https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices + url: https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices description: Product variant pricing. items: type: object @@ -32987,14 +30448,10 @@ components: - amount properties: region_id: - description: >- - The ID of the Region the price will be used in. This is only - required if `currency_code` is not provided. + description: The ID of the Region the price will be used in. This is only required if `currency_code` is not provided. type: string currency_code: - description: >- - The 3 character ISO currency code the price will be used in. - This is only required if `region_id` is not provided. + description: The 3 character ISO currency code the price will be used in. This is only required if `region_id` is not provided. type: string externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes @@ -33003,14 +30460,10 @@ components: description: The price amount. type: integer min_quantity: - description: >- - The minimum quantity required to be added to the cart for the - price to be used. + description: The minimum quantity required to be added to the cart for the price to be used. type: integer max_quantity: - description: >- - The maximum quantity required to be added to the cart for the - price to be used. + description: The maximum quantity required to be added to the cart for the price to be used. type: integer options: type: array @@ -33055,9 +30508,7 @@ components: description: Whether the product variant can be purchased when out of stock. type: boolean manage_inventory: - description: >- - Whether Medusa should keep track of the inventory of this product - variant. + description: Whether Medusa should keep track of the inventory of this product variant. type: boolean weight: description: The weight of the product variant. @@ -33084,19 +30535,13 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute prices: type: array - description: >- - An array of product variant prices. A product variant can have - different prices for each region or currency code. + description: An array of product variant prices. A product variant can have different prices for each region or currency code. externalDocs: - url: >- - https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices + url: https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices description: Product variant pricing. items: type: object @@ -33104,19 +30549,13 @@ components: - amount properties: id: - description: >- - The ID of the price. If provided, the existing price will be - updated. Otherwise, a new price will be created. + description: The ID of the price. If provided, the existing price will be updated. Otherwise, a new price will be created. type: string region_id: - description: >- - The ID of the Region the price will be used in. This is only - required if `currency_code` is not provided. + description: The ID of the Region the price will be used in. This is only required if `currency_code` is not provided. type: string currency_code: - description: >- - The 3 character ISO currency code the price will be used in. - This is only required if `region_id` is not provided. + description: The 3 character ISO currency code the price will be used in. This is only required if `region_id` is not provided. type: string externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes @@ -33125,14 +30564,10 @@ components: description: The price amount. type: integer min_quantity: - description: >- - The minimum quantity required to be added to the cart for the - price to be used. + description: The minimum quantity required to be added to the cart for the price to be used. type: integer max_quantity: - description: >- - The maximum quantity required to be added to the cart for the - price to be used. + description: The maximum quantity required to be added to the cart for the price to be used. type: integer options: type: array @@ -33165,42 +30600,26 @@ components: description: The description of the Product. type: string is_giftcard: - description: >- - A flag to indicate if the Product represents a Gift Card. Purchasing - Products with this flag set to `true` will result in a Gift Card - being created. + description: A flag to indicate if the Product represents a Gift Card. Purchasing Products with this flag set to `true` will result in a Gift Card being created. type: boolean default: false discountable: - description: >- - A flag to indicate if discounts can be applied to the Line Items - generated from this Product + description: A flag to indicate if discounts can be applied to the Line Items generated from this Product type: boolean default: true images: - description: >- - An array of images of the Product. Each value in the array is a URL - to the image. You can use the upload API Routes to upload the image - and obtain a URL. + description: An array of images of the Product. Each value in the array is a URL to the image. You can use the upload API Routes to upload the image and obtain a URL. type: array items: type: string thumbnail: - description: >- - The thumbnail to use for the Product. The value is a URL to the - thumbnail. You can use the upload API Routes to upload the thumbnail - and obtain a URL. + description: The thumbnail to use for the Product. The value is a URL to the thumbnail. You can use the upload API Routes to upload the thumbnail and obtain a URL. type: string handle: - description: >- - A unique handle to identify the Product by. If not provided, the - kebab-case version of the product title will be used. This can be - used as a slug in URLs. + description: A unique handle to identify the Product by. If not provided, the kebab-case version of the product title will be used. This can be used as a slug in URLs. type: string status: - description: >- - The status of the product. The product is shown to the customer only - if its status is `published`. + description: The status of the product. The product is shown to the customer only if its status is `published`. type: string enum: - draft @@ -33215,9 +30634,7 @@ components: - value properties: id: - description: >- - The ID of an existing Product Type. If not provided, a new - product type will be created. + description: The ID of an existing Product Type. If not provided, a new product type will be created. type: string value: description: The value of the Product Type. @@ -33234,14 +30651,10 @@ components: - value properties: id: - description: >- - The ID of an existing Product Tag. If not provided, a new - product tag will be created. + description: The ID of an existing Product Tag. If not provided, a new product tag will be created. type: string value: - description: >- - The value of the Tag. If the `id` is provided, the value of - the existing tag will be updated. + description: The value of the Tag. If the `id` is provided, the value of the existing tag will be updated. type: string sales_channels: description: Sales channels to associate the Product with. @@ -33267,9 +30680,7 @@ components: description: The ID of a Product Category. type: string options: - description: >- - The Options that the Product should have. A new product option will - be created for every item in the array. + description: The Options that the Product should have. A new product option will be created for every item in the array. type: array items: type: object @@ -33280,10 +30691,7 @@ components: description: The title of the Product Option. type: string variants: - description: >- - An array of Product Variants to create with the Product. Each - product variant must have a unique combination of Product Option - values. + description: An array of Product Variants to create with the Product. Each product variant must have a unique combination of Product Option values. type: array items: type: object @@ -33313,14 +30721,10 @@ components: type: integer default: 0 allow_backorder: - description: >- - Whether the Product Variant can be purchased when out of - stock. + description: Whether the Product Variant can be purchased when out of stock. type: boolean manage_inventory: - description: >- - Whether Medusa should keep track of the inventory of this - Product Variant. + description: Whether Medusa should keep track of the inventory of this Product Variant. type: boolean weight: description: The wieght of the Product Variant. @@ -33344,24 +30748,16 @@ components: description: The material composition of the Product Variant. type: string metadata: - description: >- - An optional set of key-value pairs with additional - information. + description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and - update it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute prices: type: array - description: >- - An array of product variant prices. A product variant can have - different prices for each region or currency code. + description: An array of product variant prices. A product variant can have different prices for each region or currency code. externalDocs: - url: >- - https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices + url: https://docs.medusajs.com/modules/products/admin/manage-products#product-variant-prices description: Product variant pricing. items: type: object @@ -33369,15 +30765,10 @@ components: - amount properties: region_id: - description: >- - The ID of the Region the price will be used in. This is - only required if `currency_code` is not provided. + description: The ID of the Region the price will be used in. This is only required if `currency_code` is not provided. type: string currency_code: - description: >- - The 3 character ISO currency code the price will be used - in. This is only required if `region_id` is not - provided. + description: The 3 character ISO currency code the price will be used in. This is only required if `region_id` is not provided. type: string externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes @@ -33386,24 +30777,16 @@ components: description: The price amount. type: integer min_quantity: - description: >- - The minimum quantity required to be added to the cart - for the price to be used. + description: The minimum quantity required to be added to the cart for the price to be used. type: integer max_quantity: - description: >- - The maximum quantity required to be added to the cart - for the price to be used. + description: The maximum quantity required to be added to the cart for the price to be used. type: integer options: type: array - description: >- - An array of Product Option values that the variant corresponds - to. The option values should be added into the array in the - same index as in the `options` field of the product. + description: An array of Product Option values that the variant corresponds to. The option values should be added into the array in the same index as in the `options` field of the product. externalDocs: - url: >- - https://docs.medusajs.com/modules/products/admin/manage-products#create-a-product + url: https://docs.medusajs.com/modules/products/admin/manage-products#create-a-product description: Example of how to create a product with options and variants items: type: object @@ -33411,9 +30794,7 @@ components: - value properties: value: - description: >- - The value to give for the Product Option at the same - index in the Product's `options` field. + description: The value to give for the Product Option at the same index in the Product's `options` field. type: string weight: description: The weight of the Product. @@ -33443,11 +30824,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostProductsToCollectionReq: type: object description: The details of the products to add to the collection. @@ -33503,8 +30881,7 @@ components: description: The 2 character ISO code for the Country. type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. AdminPostRegionsRegionFulfillmentProvidersReq: type: object @@ -33538,22 +30915,16 @@ components: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes description: See a list of codes. automatic_taxes: - description: >- - If set to `true`, the Medusa backend will automatically calculate - taxes for carts in this region. If set to `false`, the taxes must be - calculated manually. + description: If set to `true`, the Medusa backend will automatically calculate taxes for carts in this region. If set to `false`, the taxes must be calculated manually. externalDocs: - url: >- - https://docs.medusajs.com/modules/taxes/storefront/manual-calculation + url: https://docs.medusajs.com/modules/taxes/storefront/manual-calculation description: How to calculate taxes in a storefront. type: boolean gift_cards_taxable: description: If set to `true`, taxes will be applied on gift cards. type: boolean tax_provider_id: - description: >- - The ID of the tax provider to use. If none provided, the system tax - provider is used. + description: The ID of the tax provider to use. If none provided, the system tax provider is used. type: string tax_code: description: The tax code of the Region. @@ -33576,9 +30947,7 @@ components: items: type: string countries: - description: >- - A list of countries' 2 ISO characters that should be included in the - Region. + description: A list of countries' 2 ISO characters that should be included in the Region. type: array items: type: string @@ -33619,9 +30988,7 @@ components: items: type: string countries: - description: >- - A list of countries' 2 ISO characters that should be included in the - Region. + description: A list of countries' 2 ISO characters that should be included in the Region. example: - US type: array @@ -33658,11 +31025,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostReservationsReservationReq: type: object description: The details to update of the reservation. @@ -33680,11 +31044,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostReturnReasonsReasonReq: type: object description: The details to update of the return reason. @@ -33702,11 +31063,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostReturnReasonsReq: type: object description: The details of the return reason to create. @@ -33730,11 +31088,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostReturnsReturnReceiveReq: type: object description: The details of the received return. @@ -33825,29 +31180,19 @@ components: description: The name of the Shipping Option type: string amount: - description: >- - The amount to charge for the Shipping Option. If the `price_type` of - the shipping option is `calculated`, this amount will not actually - be used. + description: The amount to charge for the Shipping Option. If the `price_type` of the shipping option is `calculated`, this amount will not actually be used. type: integer admin_only: - description: >- - If set to `true`, the shipping option can only be used when creating - draft orders. + description: If set to `true`, the shipping option can only be used when creating draft orders. type: boolean metadata: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute requirements: - description: >- - The requirements that must be satisfied for the Shipping Option to - be available. + description: The requirements that must be satisfied for the Shipping Option to be available. type: array items: type: object @@ -33856,10 +31201,7 @@ components: - amount properties: id: - description: >- - The ID of an existing requirement. If an ID is passed, the - existing requirement's details are updated. Otherwise, a new - requirement is created. + description: The ID of an existing requirement. If an ID is passed, the existing requirement's details are updated. Otherwise, a new requirement is created. type: string type: description: The type of the requirement @@ -33897,28 +31239,19 @@ components: description: The ID of the Shipping Profile to add the Shipping Option to. type: number data: - description: >- - The data needed for the Fulfillment Provider to handle shipping with - this Shipping Option. + description: The data needed for the Fulfillment Provider to handle shipping with this Shipping Option. type: object price_type: - description: >- - The type of the Shipping Option price. `flat_rate` indicates fixed - pricing, whereas `calculated` indicates that the price will be - calculated each time by the fulfillment provider. + description: The type of the Shipping Option price. `flat_rate` indicates fixed pricing, whereas `calculated` indicates that the price will be calculated each time by the fulfillment provider. type: string enum: - flat_rate - calculated amount: - description: >- - The amount to charge for the Shipping Option. If the `price_type` is - set to `calculated`, this amount will not actually be used. + description: The amount to charge for the Shipping Option. If the `price_type` is set to `calculated`, this amount will not actually be used. type: integer requirements: - description: >- - The requirements that must be satisfied for the Shipping Option to - be available. + description: The requirements that must be satisfied for the Shipping Option to be available. type: array items: type: object @@ -33936,26 +31269,19 @@ components: description: The amount to compare with. type: integer is_return: - description: >- - Whether the Shipping Option can be used for returns or during - checkout. + description: Whether the Shipping Option can be used for returns or during checkout. type: boolean default: false admin_only: - description: >- - If set to `true`, the shipping option can only be used when creating - draft orders. + description: If set to `true`, the shipping option can only be used when creating draft orders. type: boolean default: false metadata: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute includes_tax: description: Tax included in prices of shipping option x-featureFlag: tax_inclusive_pricing @@ -33971,11 +31297,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute type: description: The type of the Shipping Profile type: string @@ -34010,11 +31333,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostStockLocationsLocationReq: type: object description: The details to update of the stock location. @@ -34031,11 +31351,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute address: description: The data of an associated address to create or update. $ref: '#/components/schemas/StockLocationAddressInput' @@ -34049,9 +31366,7 @@ components: description: the name of the stock location type: string address_id: - description: >- - the ID of an existing stock location address to associate with the - stock location. Only required if `address` is not provided. + description: the ID of an existing stock location address to associate with the stock location. Only required if `address` is not provided. type: string metadata: type: object @@ -34059,15 +31374,10 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute address: - description: >- - A new stock location address to create and associate with the stock - location. Only required if `address_id` is not provided. + description: A new stock location address to create and associate with the stock location. Only required if `address_id` is not provided. $ref: '#/components/schemas/StockLocationAddressInput' AdminPostStockLocationsReqAddress: type: object @@ -34094,8 +31404,7 @@ components: description: The two character ISO code for the country. type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. phone: type: string @@ -34117,21 +31426,15 @@ components: description: The name of the Store type: string swap_link_template: - description: >- - A template for Swap links - use `{{cart_id}}` to insert the Swap - Cart ID + description: A template for Swap links - use `{{cart_id}}` to insert the Swap Cart ID type: string example: http://example.com/swaps/{{cart_id}} payment_link_template: - description: >- - A template for payment links - use `{{cart_id}}` to insert the Cart - ID + description: A template for payment links - use `{{cart_id}}` to insert the Cart ID example: http://example.com/payments/{{cart_id}} type: string invite_link_template: - description: >- - A template for invite links - use `{{invite_token}}` to insert the - invite token + description: A template for invite links - use `{{invite_token}}` to insert the invite token example: http://example.com/invite?token={{invite_token}} type: string default_currency_code: @@ -34141,9 +31444,7 @@ components: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes description: See a list of codes. currencies: - description: >- - Array of available currencies in the store. Each currency is in 3 - character ISO code format. + description: Array of available currencies in the store. Each currency is in 3 character ISO code format. type: array items: type: string @@ -34154,11 +31455,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminPostTaxRatesReq: type: object description: The details of the tax rate to create. @@ -34265,10 +31563,7 @@ components: - file_key properties: file_key: - description: >- - key of the file to obtain the download link for. This is obtained - when you first uploaded the file, or by the file service if you used - it directly. + description: key of the file to obtain the download link for. This is obtained when you first uploaded the file, or by the file service if you used it directly. type: string AdminPriceListDeleteBatchRes: type: object @@ -34286,9 +31581,7 @@ components: description: The ID of a deleted price. object: type: string - description: >- - The type of the object that was deleted. A price is also named - `money-amount`. + description: The type of the object that was deleted. A price is also named `money-amount`. default: money-amount deleted: type: boolean @@ -34308,9 +31601,7 @@ components: type: string object: type: string - description: >- - The type of the object that was deleted. A price is also named - `money-amount`. + description: The type of the object that was deleted. A price is also named `money-amount`. default: money-amount deleted: type: boolean @@ -34348,9 +31639,7 @@ components: type: string object: type: string - description: >- - The type of the object that was deleted. A price is also named - `money-amount`. + description: The type of the object that was deleted. A price is also named `money-amount`. default: money-amount deleted: type: boolean @@ -34483,9 +31772,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product categories skipped when retrieving the product - categories. + description: The number of product categories skipped when retrieving the product categories. limit: type: integer description: The number of items per page @@ -34531,9 +31818,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product types skipped when retrieving the product - types. + description: The number of product types skipped when retrieving the product types. limit: type: integer description: The number of items per page @@ -34713,9 +31998,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product variants skipped when retrieving the product - variants. + description: The number of product variants skipped when retrieving the product variants. limit: type: integer description: The number of items per page @@ -34776,9 +32059,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of publishable API keys skipped when retrieving the - publishable API keys. + description: The number of publishable API keys skipped when retrieving the publishable API keys. limit: type: integer description: The number of items per page @@ -34941,9 +32222,7 @@ components: type: string format: email token: - description: >- - The password-reset token generated when the password reset was - requested. + description: The password-reset token generated when the password reset was requested. type: string password: description: The User's new password. @@ -35219,9 +32498,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of shipping options skipped when retrieving the shipping - options. + description: The number of shipping options skipped when retrieving the shipping options. limit: type: integer description: The number of items per page @@ -35305,9 +32582,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of stock locations skipped when retrieving the stock - locations. + description: The number of stock locations skipped when retrieving the stock locations. limit: type: integer description: The number of items per page @@ -35451,11 +32726,8 @@ components: description: A set of key-value pairs to hold additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminUpdateUserRequest: type: object properties: @@ -35466,9 +32738,7 @@ components: description: The last name of the User. type: string role: - description: >- - The role assigned to the user. These roles don't provide any - different privileges. + description: The role assigned to the user. These roles don't provide any different privileges. type: string enum: - admin @@ -35481,11 +32751,8 @@ components: description: An optional set of key-value pairs with additional information. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AdminUploadsDownloadUrlRes: type: object description: The download URL details. @@ -35515,9 +32782,7 @@ components: type: string format: uri key: - description: >- - The key of the file that is identifiable by the file service. - It can be used later to retrieve or manipulate the file. + description: The key of the file that is identifiable by the file service. It can be used later to retrieve or manipulate the file. type: string AdminUserRes: type: object @@ -35533,12 +32798,24 @@ components: description: The list of users. required: - users + - count + - offset + - limit properties: users: type: array description: An array of users details. items: $ref: '#/components/schemas/User' + count: + type: integer + description: The total number of items available + offset: + type: integer + description: The number of users skipped when retrieving the users. + limit: + type: integer + description: The number of items per page AdminVariantsListRes: type: object description: The list of variants with pagination fields. @@ -35566,9 +32843,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product variants skipped when retrieving the product - variants. + description: The number of product variants skipped when retrieving the product variants. limit: type: integer description: The number of items per page @@ -35589,9 +32864,7 @@ components: $ref: '#/components/schemas/PricedVariant' BatchJob: title: Batch Job - description: >- - A Batch Job indicates an asynchronus task stored in the Medusa backend. - Its status determines whether it has been executed or not. + description: A Batch Job indicates an asynchronus task stored in the Medusa backend. Its status determines whether it has been executed or not. type: object required: - canceled_at @@ -35644,9 +32917,7 @@ components: nullable: true $ref: '#/components/schemas/User' context: - description: >- - The context of the batch job, the type of the batch job determines - what the context should contain. + description: The context of the batch job, the type of the batch job determines what the context should contain. nullable: true type: object example: @@ -35761,9 +33032,7 @@ components: format: date-time Cart: title: Cart - description: >- - A cart represents a virtual shopping bag. It can be used to complete an - order, a swap, or a claim. + description: A cart represents a virtual shopping bag. It can be used to complete an order, a swap, or a claim. type: object required: - billing_address_id @@ -35898,18 +33167,14 @@ components: type: string format: date-time idempotency_key: - description: >- - Randomly generated key used to continue the completion of a cart in - case of failure. + description: Randomly generated key used to continue the completion of a cart in case of failure. nullable: true type: string externalDocs: url: https://docs.medusajs.com/development/idempotency-key/overview.md description: Learn more how to use the idempotency key. context: - description: >- - The context of the cart which can include info like IP or user - agent. + description: The context of the cart which can include info like IP or user agent. nullable: true type: object example: @@ -35945,11 +33210,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute shipping_total: description: The total of shipping type: integer @@ -35975,9 +33237,7 @@ components: type: integer example: 0 refunded_total: - description: >- - The total amount refunded if the order associated with this cart is - returned. + description: The total amount refunded if the order associated with this cart is returned. type: integer example: 0 total: @@ -36056,16 +33316,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ClaimItem: title: Claim Item - description: >- - A claim item is an item created as part of a claim. It references an - item in the order that should be exchanged or refunded. + description: A claim item is an item created as part of a claim. It references an item in the order that should be exchanged or refunded. type: object required: - claim_order_id @@ -36103,9 +33358,7 @@ components: type: string example: item_01G8ZM25TN49YV9EQBE2NC27KC item: - description: >- - The details of the line item in the original order that this claim - item refers to. + description: The details of the line item in the original order that this claim item refers to. x-expandable: item nullable: true $ref: '#/components/schemas/LineItem' @@ -36114,9 +33367,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 variant: - description: >- - The details of the product variant to potentially replace the item - in the original order. + description: The details of the product variant to potentially replace the item in the original order. x-expandable: variant nullable: true $ref: '#/components/schemas/ProductVariant' @@ -36134,9 +33385,7 @@ components: type: string example: I don't like it. quantity: - description: >- - The quantity of the item that is being claimed; must be less than or - equal to the amount purchased in the original order. + description: The quantity of the item that is being claimed; must be less than or equal to the amount purchased in the original order. type: integer example: 1 tags: @@ -36165,18 +33414,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ClaimOrder: title: Claim - description: >- - A Claim represents a group of faulty or missing items. It consists of - claim items that refer to items in the original order that should be - replaced or refunded. It also includes details related to shipping and - fulfillment. + description: A Claim represents a group of faulty or missing items. It consists of claim items that refer to items in the original order that should be replaced or refunded. It also includes details related to shipping and fulfillment. type: object required: - canceled_at @@ -36233,9 +33475,7 @@ components: items: $ref: '#/components/schemas/ClaimItem' additional_items: - description: >- - The details of the new items to be shipped when the claim's type is - `replace` + description: The details of the new items to be shipped when the claim's type is `replace` type: array x-expandable: additional_items items: @@ -36250,9 +33490,7 @@ components: nullable: true type: object return_order: - description: >- - The details of the return associated with the claim if the claim's - type is `replace`. + description: The details of the return associated with the claim if the claim's type is `replace`. x-expandable: return_order nullable: true type: object @@ -36267,9 +33505,7 @@ components: nullable: true $ref: '#/components/schemas/Address' shipping_methods: - description: >- - The details of the shipping methods that the claim order will be - shipped with. + description: The details of the shipping methods that the claim order will be shipped with. type: array x-expandable: shipping_methods items: @@ -36310,22 +33546,15 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute no_notification: - description: >- - Flag for describing whether or not notifications related to this - should be send. + description: Flag for describing whether or not notifications related to this should be send. nullable: true type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the cart - associated with the claim in case of failure. + description: Randomly generated key used to continue the completion of the cart associated with the claim in case of failure. nullable: true type: string externalDocs: @@ -36333,9 +33562,7 @@ components: description: Learn more how to use the idempotency key. ClaimTag: title: Claim Tag - description: >- - Claim Tags are user defined tags that can be assigned to claim items for - easy filtering and grouping. + description: Claim Tags are user defined tags that can be assigned to claim items for easy filtering and grouping. type: object required: - created_at @@ -36373,11 +33600,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Country: title: Country description: Country details @@ -36400,24 +33624,21 @@ components: type: string example: it externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. iso_3: description: The 2 character ISO code of the country in lower case type: string example: ita externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3#Officially_assigned_code_elements description: See a list of codes. num_code: description: The numerical ISO code for the country. type: string example: 380 externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_numeric#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_numeric#Officially_assigned_code_elements description: See a list of codes. name: description: The normalized country name in upper case. @@ -36496,10 +33717,7 @@ components: default: false CustomShippingOption: title: Custom Shipping Option - description: >- - Custom Shipping Options are overridden Shipping Options. Admins can - attach a Custom Shipping Option to a cart in order to set a custom price - for a particular Shipping Option. + description: Custom Shipping Options are overridden Shipping Options. Admins can attach a Custom Shipping Option to a cart in order to set a custom price for a particular Shipping Option. type: object required: - cart_id @@ -36516,15 +33734,11 @@ components: type: string example: cso_01G8X99XNB77DMFBJFWX6DN9V9 price: - description: >- - The custom price set that will override the shipping option's - original price + description: The custom price set that will override the shipping option's original price type: integer example: 1000 shipping_option_id: - description: >- - The ID of the Shipping Option that the custom shipping option - overrides + description: The ID of the Shipping Option that the custom shipping option overrides type: string example: so_01G1G5V27GYX4QXNARRQCW1N8T shipping_option: @@ -36562,11 +33776,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Customer: title: Customer description: A customer can make purchases in your store and manage their profile. @@ -36659,16 +33870,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute CustomerGroup: title: Customer Group - description: >- - A customer group that can be used to organize customers into groups of - similar traits. + description: A customer group that can be used to organize customers into groups of similar traits. type: object required: - created_at @@ -36718,11 +33924,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DecoratedInventoryItemDTO: type: object allOf: @@ -36774,48 +33977,34 @@ components: type: string example: disc_01F0YESMW10MGHWJKZSDDMN0VN code: - description: >- - A unique code for the discount - this will be used by the customer - to apply the discount + description: A unique code for the discount - this will be used by the customer to apply the discount type: string example: 10DISC is_dynamic: - description: >- - A flag to indicate if multiple instances of the discount can be - generated. I.e. for newsletter discounts + description: A flag to indicate if multiple instances of the discount can be generated. I.e. for newsletter discounts type: boolean example: false rule_id: - description: >- - The ID of the discount rule that defines how the discount will be - applied to a cart. + description: The ID of the discount rule that defines how the discount will be applied to a cart. nullable: true type: string example: dru_01F0YESMVK96HVX7N419E3CJ7C rule: - description: >- - The details of the discount rule that defines how the discount will - be applied to a cart.. + description: The details of the discount rule that defines how the discount will be applied to a cart.. x-expandable: rule nullable: true $ref: '#/components/schemas/DiscountRule' is_disabled: - description: >- - Whether the Discount has been disabled. Disabled discounts cannot be - applied to carts + description: Whether the Discount has been disabled. Disabled discounts cannot be applied to carts type: boolean example: false parent_discount_id: - description: >- - The Discount that the discount was created from. This will always be - a dynamic discount + description: The Discount that the discount was created from. This will always be a dynamic discount nullable: true type: string example: disc_01G8ZH853YPY9B94857DY91YGW parent_discount: - description: >- - The details of the parent discount that this discount was created - from. + description: The details of the parent discount that this discount was created from. x-expandable: parent_discount nullable: true type: object @@ -36869,11 +34058,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountCondition: title: Discount Condition description: Holds rule conditions for when a discount is applicable @@ -36893,12 +34079,7 @@ components: type: string example: discon_01G8X9A7ESKAJXG2H0E6F1MW7A type: - description: >- - The type of the condition. The type affects the available resources - associated with the condition. For example, if the type is - `products`, that means the `products` relation will hold the - products associated with this condition and other relations will be - empty. + description: The type of the condition. The type affects the available resources associated with the condition. For example, if the type is `products`, that means the `products` relation will hold the products associated with this condition and other relations will be empty. type: string enum: - products @@ -36907,11 +34088,7 @@ components: - product_tags - customer_groups operator: - description: >- - The operator of the condition. `in` indicates that discountable - resources are within the specified resources. `not_in` indicates - that discountable resources are everything but the specified - resources. + description: The operator of the condition. `in` indicates that discountable resources are within the specified resources. `not_in` indicates that discountable resources are everything but the specified resources. type: string enum: - in @@ -36932,33 +34109,25 @@ components: items: $ref: '#/components/schemas/Product' product_types: - description: >- - Product types associated with this condition if `type` is - `product_types`. + description: Product types associated with this condition if `type` is `product_types`. type: array x-expandable: product_types items: $ref: '#/components/schemas/ProductType' product_tags: - description: >- - Product tags associated with this condition if `type` is - `product_tags`. + description: Product tags associated with this condition if `type` is `product_tags`. type: array x-expandable: product_tags items: $ref: '#/components/schemas/ProductTag' product_collections: - description: >- - Product collections associated with this condition if `type` is - `product_collections`. + description: Product collections associated with this condition if `type` is `product_collections`. type: array x-expandable: product_collections items: $ref: '#/components/schemas/ProductCollection' customer_groups: - description: >- - Customer groups associated with this condition if `type` is - `customer_groups`. + description: Customer groups associated with this condition if `type` is `customer_groups`. type: array x-expandable: customer_groups items: @@ -36983,11 +34152,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionCustomerGroup: title: Product Tag Discount Condition description: Associates a discount condition with a customer group @@ -37030,16 +34196,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProduct: title: Product Discount Condition - description: >- - This represents the association between a discount condition and a - product + description: This represents the association between a discount condition and a product type: object required: - condition_id @@ -37081,16 +34242,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProductCollection: title: Product Collection Discount Condition - description: >- - This represents the association between a discount condition and a - product collection + description: This represents the association between a discount condition and a product collection type: object required: - condition_id @@ -37132,16 +34288,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProductTag: title: Product Tag Discount Condition - description: >- - This represents the association between a discount condition and a - product tag + description: This represents the association between a discount condition and a product tag type: object required: - condition_id @@ -37183,16 +34334,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProductType: title: Product Type Discount Condition - description: >- - This represents the association between a discount condition and a - product type + description: This represents the association between a discount condition and a product type type: object required: - condition_id @@ -37234,16 +34380,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountRule: title: Discount Rule - description: >- - A discount rule defines how a Discount is calculated when applied to a - Cart. + description: A discount rule defines how a Discount is calculated when applied to a Cart. type: object required: - allocation @@ -37261,10 +34402,7 @@ components: type: string example: dru_01F0YESMVK96HVX7N419E3CJ7C type: - description: >- - The type of the Discount, can be `fixed` for discounts that reduce - the price by a fixed amount, `percentage` for percentage reductions - or `free_shipping` for shipping vouchers. + description: The type of the Discount, can be `fixed` for discounts that reduce the price by a fixed amount, `percentage` for percentage reductions or `free_shipping` for shipping vouchers. type: string enum: - fixed @@ -37277,9 +34415,7 @@ components: type: string example: 10 Percent value: - description: >- - The value that the discount represents; this will depend on the type - of the discount + description: The value that the discount represents; this will depend on the type of the discount type: integer example: 10 allocation: @@ -37291,9 +34427,7 @@ components: - item example: total conditions: - description: >- - The details of the discount conditions associated with the rule. - They can be used to limit when the discount can be used. + description: The details of the discount conditions associated with the rule. They can be used to limit when the discount can be used. type: array x-expandable: conditions items: @@ -37318,17 +34452,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DraftOrder: title: DraftOrder - description: >- - A draft order is created by an admin without direct involvement of the - customer. Once its payment is marked as captured, it is transformed into - an order. + description: A draft order is created by an admin without direct involvement of the customer. Once its payment is marked as captured, it is transformed into an order. type: object required: - canceled_at @@ -37349,9 +34477,7 @@ components: type: string example: dorder_01G8TJFKBG38YYFQ035MSVG03C status: - description: >- - The status of the draft order. It's changed to `completed` when it's - transformed to an order. + description: The status of the draft order. It's changed to `completed` when it's transformed to an order. type: string enum: - open @@ -37372,16 +34498,12 @@ components: nullable: true type: object order_id: - description: >- - The ID of the order created from the draft order when its payment is - captured. + description: The ID of the order created from the draft order when its payment is captured. nullable: true type: string example: order_01G8TJSYT9M6AVS5N4EMNFS1EK order: - description: >- - The details of the order created from the draft order when its - payment is captured. + description: The details of the order created from the draft order when its payment is captured. x-expandable: order nullable: true type: object @@ -37401,9 +34523,7 @@ components: type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the cart - associated with the draft order in case of failure. + description: Randomly generated key used to continue the completion of the cart associated with the draft order in case of failure. nullable: true type: string externalDocs: @@ -37424,11 +34544,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Error: title: Response Error type: object @@ -37513,12 +34630,7 @@ components: type: boolean Fulfillment: title: Fulfillment - description: >- - A Fulfillment is created once an admin can prepare the purchased goods. - Fulfillments will eventually be shipped and hold information about how - to track shipments. Fulfillments are created through a fulfillment - provider, which typically integrates a third-party shipping service. - Fulfillments can be associated with orders, claims, swaps, and returns. + description: A Fulfillment is created once an admin can prepare the purchased goods. Fulfillments will eventually be shipped and hold information about how to track shipments. Fulfillments are created through a fulfillment provider, which typically integrates a third-party shipping service. Fulfillments can be associated with orders, claims, swaps, and returns. type: object required: - canceled_at @@ -37572,15 +34684,11 @@ components: nullable: true type: object provider_id: - description: >- - The ID of the Fulfillment Provider responsible for handling the - fulfillment. + description: The ID of the Fulfillment Provider responsible for handling the fulfillment. type: string example: manual provider: - description: >- - The details of the fulfillment provider responsible for handling the - fulfillment. + description: The details of the fulfillment provider responsible for handling the fulfillment. x-expandable: provider nullable: true $ref: '#/components/schemas/FulfillmentProvider' @@ -37590,34 +34698,25 @@ components: type: string example: sloc_01G8TJSYT9M6AVS5N4EMNFS1EK items: - description: >- - The Fulfillment Items in the Fulfillment. These hold information - about how many of each Line Item has been fulfilled. + description: The Fulfillment Items in the Fulfillment. These hold information about how many of each Line Item has been fulfilled. type: array x-expandable: items items: $ref: '#/components/schemas/FulfillmentItem' tracking_links: - description: >- - The Tracking Links that can be used to track the status of the - Fulfillment. These will usually be provided by the Fulfillment - Provider. + description: The Tracking Links that can be used to track the status of the Fulfillment. These will usually be provided by the Fulfillment Provider. type: array x-expandable: tracking_links items: $ref: '#/components/schemas/TrackingLink' tracking_numbers: - description: >- - The tracking numbers that can be used to track the status of the - fulfillment. + description: The tracking numbers that can be used to track the status of the fulfillment. deprecated: true type: array items: type: string data: - description: >- - This contains all the data necessary for the Fulfillment provider to - handle the fulfillment. + description: This contains all the data necessary for the Fulfillment provider to handle the fulfillment. type: object example: {} shipped_at: @@ -37626,9 +34725,7 @@ components: type: string format: date-time no_notification: - description: >- - Flag for describing whether or not notifications related to this - should be sent. + description: Flag for describing whether or not notifications related to this should be sent. nullable: true type: boolean example: false @@ -37638,9 +34735,7 @@ components: type: string format: date-time idempotency_key: - description: >- - Randomly generated key used to continue the completion of the - fulfillment in case of failure. + description: Randomly generated key used to continue the completion of the fulfillment in case of failure. nullable: true type: string externalDocs: @@ -37661,11 +34756,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute FulfillmentItem: title: Fulfillment Item description: This represents the association between a Line Item and a Fulfillment. @@ -37699,33 +34791,23 @@ components: example: 1 FulfillmentProvider: title: Fulfillment Provider - description: >- - A fulfillment provider represents a fulfillment service installed in the - Medusa backend, either through a plugin or backend customizations. It - holds the fulfillment service's installation status. + description: A fulfillment provider represents a fulfillment service installed in the Medusa backend, either through a plugin or backend customizations. It holds the fulfillment service's installation status. type: object required: - id - is_installed properties: id: - description: >- - The ID of the fulfillment provider as given by the fulfillment - service. + description: The ID of the fulfillment provider as given by the fulfillment service. type: string example: manual is_installed: - description: >- - Whether the fulfillment service is installed in the current version. - If a fulfillment service is no longer installed, the `is_installed` - attribute is set to `false`. + description: Whether the fulfillment service is installed in the current version. If a fulfillment service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true GiftCard: title: Gift Card - description: >- - Gift Cards are redeemable and represent a value that can be used towards - the payment of an Order. + description: Gift Cards are redeemable and represent a value that can be used towards the payment of an Order. type: object required: - balance @@ -37747,9 +34829,7 @@ components: type: string example: gift_01G8XKBPBQY2R7RBET4J7E0XQZ code: - description: >- - The unique code that identifies the Gift Card. This is used by the - Customer to redeem the value of the Gift Card. + description: The unique code that identifies the Gift Card. This is used by the Customer to redeem the value of the Gift Card. type: string example: 3RFT-MH2C-Y4YZ-XMN4 value: @@ -37780,9 +34860,7 @@ components: nullable: true type: object is_disabled: - description: >- - Whether the Gift Card has been disabled. Disabled Gift Cards cannot - be applied to carts. + description: Whether the Gift Card has been disabled. Disabled Gift Cards cannot be applied to carts. type: boolean default: false ends_at: @@ -37815,16 +34893,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute GiftCardTransaction: title: Gift Card Transaction - description: >- - Gift Card Transactions are created once a Customer uses a Gift Card to - pay for their Order. + description: Gift Card Transactions are created once a Customer uses a Gift Card to pay for their Order. type: object required: - amount @@ -37877,9 +34950,7 @@ components: example: 0 IdempotencyKey: title: Idempotency Key - description: >- - Idempotency Key is used to continue a process in case of any failure - that might occur. + description: Idempotency Key is used to continue a process in case of any failure that might occur. type: object required: - created_at @@ -37898,9 +34969,7 @@ components: type: string example: ikey_01G8X9A7ESKAJXG2H0E6F1MW7A idempotency_key: - description: >- - The unique randomly generated key used to determine the state of a - process. + description: The unique randomly generated key used to determine the state of a process. type: string externalDocs: url: https://docs.medusajs.com/development/idempotency-key/overview.md @@ -37947,10 +35016,7 @@ components: default: started Image: title: Image - description: >- - An Image is used to store details about uploaded images. Images are - uploaded by the File Service, and the URL is provided by the File - Service. + description: An Image is used to store details about uploaded images. Images are uploaded by the File Service, and the URL is provided by the File Service. type: object required: - created_at @@ -37988,11 +35054,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute InventoryItemDTO: type: object required: @@ -38006,22 +35069,13 @@ components: description: The Stock Keeping Unit (SKU) code of the Inventory Item. type: string hs_code: - description: >- - The Harmonized System code of the Inventory Item. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string origin_country: - description: >- - The country in which the Inventory Item was produced. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Inventory Item was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Inventory Item. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string title: description: Title of the inventory item @@ -38033,30 +35087,19 @@ components: description: Thumbnail for the inventory item type: string material: - description: >- - The material and composition that the Inventory Item is made of, May - be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Inventory Item is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string weight: - description: >- - The weight of the Inventory Item. May be used in shipping rate - calculations. + description: The weight of the Inventory Item. May be used in shipping rate calculations. type: number height: - description: >- - The height of the Inventory Item. May be used in shipping rate - calculations. + description: The height of the Inventory Item. May be used in shipping rate calculations. type: number width: - description: >- - The width of the Inventory Item. May be used in shipping rate - calculations. + description: The width of the Inventory Item. May be used in shipping rate calculations. type: number length: - description: >- - The length of the Inventory Item. May be used in shipping rate - calculations. + description: The length of the Inventory Item. May be used in shipping rate calculations. type: number requires_shipping: description: Whether the item requires shipping. @@ -38091,19 +35134,13 @@ components: description: the item location ID type: string stocked_quantity: - description: >- - the total stock quantity of an inventory item at the given location - ID + description: the total stock quantity of an inventory item at the given location ID type: number reserved_quantity: - description: >- - the reserved stock quantity of an inventory item at the given - location ID + description: the reserved stock quantity of an inventory item at the given location ID type: number incoming_quantity: - description: >- - the incoming stock quantity of an inventory item at the given - location ID + description: the incoming stock quantity of an inventory item at the given location ID type: number metadata: type: object @@ -38124,9 +35161,7 @@ components: format: date-time Invite: title: Invite - description: >- - An invite is created when an admin user invites a new user to join the - store's team. Once the invite is accepted, it's deleted. + description: An invite is created when an admin user invites a new user to join the store's team. Once the invite is accepted, it's deleted. type: object required: - accepted @@ -38149,9 +35184,7 @@ components: type: string format: email role: - description: >- - The user's role. These roles don't change the privileges of the - user. + description: The user's role. These roles don't change the privileges of the user. nullable: true type: string enum: @@ -38190,18 +35223,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute LineItem: title: Line Item - description: >- - Line Items are created when a product is added to a Cart. When Line - Items are purchased they will get copied to the resulting order, swap, - or claim, and can eventually be referenced in Fulfillments and Returns. - Line items may also be used for order edits. + description: Line Items are created when a product is added to a Cart. When Line Items are purchased they will get copied to the resulting order, swap, or claim, and can eventually be referenced in Fulfillments and Returns. Line items may also be used for order edits. type: object required: - allow_discounts @@ -38280,18 +35306,13 @@ components: items: $ref: '#/components/schemas/LineItemTaxLine' adjustments: - description: >- - The details of the item's adjustments, which are available when a - discount is applied on the item. + description: The details of the item's adjustments, which are available when a discount is applied on the item. x-expandable: adjustments type: array items: $ref: '#/components/schemas/LineItemAdjustment' original_item_id: - description: >- - The ID of the original line item. This is useful if the line item - belongs to a resource that references an order, such as a return or - an order edit. + description: The ID of the original line item. This is useful if the line item belongs to a resource that references an order, such as a return or an order edit. nullable: true type: string order_edit_id: @@ -38317,8 +35338,7 @@ components: nullable: true type: string format: uri - example: >- - https://medusa-public-images.s3.eu-west-1.amazonaws.com/coffee-mug.png + example: https://medusa-public-images.s3.eu-west-1.amazonaws.com/coffee-mug.png is_return: description: Is the item being returned type: boolean @@ -38328,29 +35348,20 @@ components: type: boolean default: false should_merge: - description: >- - Flag to indicate if new Line Items with the same variant should be - merged or added as an additional Line Item. + description: Flag to indicate if new Line Items with the same variant should be merged or added as an additional Line Item. type: boolean default: true allow_discounts: - description: >- - Flag to indicate if the Line Item should be included when doing - discount calculations. + description: Flag to indicate if the Line Item should be included when doing discount calculations. type: boolean default: true has_shipping: - description: >- - Flag to indicate if the Line Item has fulfillment associated with - it. + description: Flag to indicate if the Line Item has fulfillment associated with it. nullable: true type: boolean example: false unit_price: - description: >- - The price of one unit of the content in the Line Item. This should - be in the currency defined by the Cart/Order/Swap/Claim that the - Line Item belongs to. + description: The price of one unit of the content in the Line Item. This should be in the currency defined by the Cart/Order/Swap/Claim that the Line Item belongs to. type: integer example: 8000 variant_id: @@ -38383,9 +35394,7 @@ components: type: integer example: 0 refundable: - description: >- - The amount that can be refunded from the given Line Item. Takes - taxes and discounts into consideration. + description: The amount that can be refunded from the given Line Item. Takes taxes and discounts into consideration. type: integer example: 0 subtotal: @@ -38440,16 +35449,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute LineItemAdjustment: title: Line Item Adjustment - description: >- - A Line Item Adjustment includes details on discounts applied on a line - item. + description: A Line Item Adjustment includes details on discounts applied on a line item. type: object required: - amount @@ -38497,11 +35501,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute LineItemTaxLine: title: Line Item Tax Line description: A Line Item Tax Line represents the taxes applied on a line item. @@ -38557,11 +35558,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ModulesResponse: type: array items: @@ -38574,19 +35572,11 @@ components: description: The key of the module. type: string resolution: - description: >- - The resolution path of the module or false if module is not - installed. + description: The resolution path of the module or false if module is not installed. type: string MoneyAmount: title: Money Amount - description: >- - A Money Amount represent a price amount, for example, a product - variant's price or a price in a price list. Each Money Amount either has - a Currency or Region associated with it to indicate the pricing in a - given Currency or, for fully region-based pricing, the given price in a - specific Region. If region-based pricing is used, the amount will be in - the currency defined for the Region. + description: A Money Amount represent a price amount, for example, a product variant's price or a price in a price list. Each Money Amount either has a Currency or Region associated with it to indicate the pricing in a given Currency or, for fully region-based pricing, the given price in a specific Region. If region-based pricing is used, the amount will be in the currency defined for the Region. type: object required: - amount @@ -38618,22 +35608,16 @@ components: nullable: true $ref: '#/components/schemas/Currency' amount: - description: >- - The amount in the smallest currecny unit (e.g. cents 100 cents to - charge $1) that the Product Variant will cost. + description: The amount in the smallest currecny unit (e.g. cents 100 cents to charge $1) that the Product Variant will cost. type: integer example: 100 min_quantity: - description: >- - The minimum quantity that the Money Amount applies to. If this value - is not set, the Money Amount applies to all quantities. + description: The minimum quantity that the Money Amount applies to. If this value is not set, the Money Amount applies to all quantities. nullable: true type: integer example: 1 max_quantity: - description: >- - The maximum quantity that the Money Amount applies to. If this value - is not set, the Money Amount applies to all quantities. + description: The maximum quantity that the Money Amount applies to. If this value is not set, the Money Amount applies to all quantities. nullable: true type: integer example: 1 @@ -38653,9 +35637,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 variant: - description: >- - The details of the product variant that the money amount may belong - to. + description: The details of the product variant that the money amount may belong to. x-expandable: variant nullable: true type: object @@ -38693,15 +35675,10 @@ components: $ref: '#/components/schemas/Error' message: type: string - default: >- - Provided request body contains errors. Please check the data and - retry the request + default: Provided request body contains errors. Please check the data and retry the request Note: title: Note - description: >- - A Note is an element that can be used in association with different - resources to allow admin users to describe additional information. For - example, they can be used to add additional information about orders. + description: A Note is an element that can be used in association with different resources to allow admin users to describe additional information. For example, they can be used to add additional information about orders. type: object required: - author_id @@ -38761,10 +35738,7 @@ components: car: white Notification: title: Notification - description: >- - A notification is an alert sent, typically to customers, using the - installed Notification Provider as a reaction to internal events such as - `order.placed`. Notifications can be resent. + description: A notification is an alert sent, typically to customers, using the installed Notification Provider as a reaction to internal events such as `order.placed`. Notifications can be resent. type: object required: - created_at @@ -38807,16 +35781,11 @@ components: nullable: true $ref: '#/components/schemas/Customer' to: - description: >- - The address that the Notification was sent to. This will usually be - an email address, but can represent other addresses such as a chat - bot user ID. + description: The address that the Notification was sent to. This will usually be an email address, but can represent other addresses such as a chat bot user ID. type: string example: user@example.com data: - description: >- - The data that the Notification was sent with. This contains all the - data necessary for the Notification Provider to initiate a resend. + description: The data that the Notification was sent with. This contains all the data necessary for the Notification Provider to initiate a resend. type: object example: {} parent_id: @@ -38855,33 +35824,23 @@ components: format: date-time NotificationProvider: title: Notification Provider - description: >- - A notification provider represents a notification service installed in - the Medusa backend, either through a plugin or backend customizations. - It holds the notification service's installation status. + description: A notification provider represents a notification service installed in the Medusa backend, either through a plugin or backend customizations. It holds the notification service's installation status. type: object required: - id - is_installed properties: id: - description: >- - The ID of the notification provider as given by the notification - service. + description: The ID of the notification provider as given by the notification service. type: string example: sendgrid is_installed: - description: >- - Whether the notification service is installed in the current - version. If a notification service is no longer installed, the - `is_installed` attribute is set to `false`. + description: Whether the notification service is installed in the current version. If a notification service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true OAuth: title: OAuth - description: >- - An Oauth app is typically created by a plugin to handle authentication - to third-party services. + description: An Oauth app is typically created by a plugin to handle authentication to third-party services. type: object required: - application_name @@ -38920,10 +35879,7 @@ components: example: {} Order: title: Order - description: >- - An order is a purchase made by a customer. It holds details about - payment and fulfillment of the order. An order may also be created from - a draft order, which is created by an admin user. + description: An order is a purchase made by a customer. It holds details about payment and fulfillment of the order. An order may also be created from a draft order, which is created by an admin user. type: object required: - billing_address_id @@ -39150,16 +36106,12 @@ components: type: string format: date-time no_notification: - description: >- - Flag for describing whether or not notifications related to this - should be send. + description: Flag for describing whether or not notifications related to this should be send. nullable: true type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the processing of the order - in case of failure. + description: Randomly generated key used to continue the processing of the order in case of failure. nullable: true type: string externalDocs: @@ -39235,9 +36187,7 @@ components: type: integer example: 0 returnable_items: - description: >- - The details of the line items that are returnable as part of the - order, swaps, or claims + description: The details of the line items that are returnable as part of the order, swaps, or claims type: array x-expandable: returnable_items items: @@ -39257,11 +36207,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute sales_channels: description: The associated sales channels. type: array @@ -39272,10 +36219,7 @@ components: $ref: '#/components/schemas/SalesChannel' OrderEdit: title: Order Edit - description: >- - Order edit allows modifying items in an order, such as adding, updating, - or deleting items from the original order. Once the order edit is - confirmed, the changes are reflected on the original order. + description: Order edit allows modifying items in an order, such as adding, updating, or deleting items from the original order. Once the order edit is confirmed, the changes are reflected on the original order. type: object required: - canceled_at @@ -39321,14 +36265,10 @@ components: type: string example: Included two more items B to the order. created_by: - description: >- - The unique identifier of the user or customer who created the order - edit. + description: The unique identifier of the user or customer who created the order edit. type: string requested_by: - description: >- - The unique identifier of the user or customer who requested the - order edit. + description: The unique identifier of the user or customer who requested the order edit. nullable: true type: string requested_at: @@ -39337,9 +36277,7 @@ components: type: string format: date-time confirmed_by: - description: >- - The unique identifier of the user or customer who confirmed the - order edit. + description: The unique identifier of the user or customer who confirmed the order edit. nullable: true type: string confirmed_at: @@ -39348,9 +36286,7 @@ components: type: string format: date-time declined_by: - description: >- - The unique identifier of the user or customer who declined the order - edit. + description: The unique identifier of the user or customer who declined the order edit. nullable: true type: string declined_at: @@ -39363,9 +36299,7 @@ components: nullable: true type: string canceled_by: - description: >- - The unique identifier of the user or customer who cancelled the - order edit. + description: The unique identifier of the user or customer who cancelled the order edit. nullable: true type: string canceled_at: @@ -39402,9 +36336,7 @@ components: type: integer example: 8200 difference_due: - description: >- - The difference between the total amount of the order and total - amount of edited order. + description: The difference between the total amount of the order and total amount of edited order. type: integer example: 8200 status: @@ -39417,10 +36349,7 @@ components: - created - canceled items: - description: >- - The details of the cloned items from the original order with the new - changes. Once the order edit is confirmed, these line items are - associated with the original order. + description: The details of the cloned items from the original order with the new changes. Once the order edit is confirmed, these line items are associated with the original order. type: array x-expandable: items items: @@ -39431,9 +36360,7 @@ components: type: string example: paycol_01G8TJSYT9M6AVS5N4EMNFS1EK payment_collection: - description: >- - The details of the payment collection used to authorize additional - payment if necessary. + description: The details of the payment collection used to authorize additional payment if necessary. x-expandable: payment_collection nullable: true $ref: '#/components/schemas/PaymentCollection' @@ -39447,10 +36374,7 @@ components: format: date-time OrderItemChange: title: Order Item Change - description: >- - An order item change is a change made within an order edit to an order's - items. These changes are not reflected on the original order until the - order edit is confirmed. + description: An order item change is a change made within an order edit to an order's items. These changes are not reflected on the original order until the order edit is confirmed. type: object required: - created_at @@ -39488,10 +36412,7 @@ components: type: string example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN original_line_item: - description: >- - The details of the original line item this item change references. - This is used if the item change updates or deletes the original - item. + description: The details of the original line item this item change references. This is used if the item change updates or deletes the original item. x-expandable: original_line_item nullable: true $ref: '#/components/schemas/LineItem' @@ -39501,10 +36422,7 @@ components: type: string example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN line_item: - description: >- - The details of the resulting line item after the item change. This - line item is then used in the original order once the order edit is - confirmed. + description: The details of the resulting line item after the item change. This line item is then used in the original order once the order edit is confirmed. x-expandable: line_item nullable: true $ref: '#/components/schemas/LineItem' @@ -39523,12 +36441,7 @@ components: format: date-time Payment: title: Payment - description: >- - A payment is originally created from a payment session. Once a payment - session is authorized, the payment is created to represent the - authorized amount with a given payment method. Payments can be captured, - canceled or refunded. Payments can be made towards orders, swaps, order - edits, or other resources. + description: A payment is originally created from a payment session. Once a payment session is authorized, the payment is created to represent the authorized amount with a given payment method. Payments can be captured, canceled or refunded. Payments can be made towards orders, swaps, order edits, or other resources. type: object required: - amount @@ -39557,36 +36470,26 @@ components: type: string example: null swap: - description: >- - The details of the swap that this payment was potentially created - for. + description: The details of the swap that this payment was potentially created for. x-expandable: swap nullable: true type: object cart_id: - description: >- - The ID of the cart that the payment session was potentially created - for. + description: The ID of the cart that the payment session was potentially created for. nullable: true type: string cart: - description: >- - The details of the cart that the payment session was potentially - created for. + description: The details of the cart that the payment session was potentially created for. x-expandable: cart nullable: true type: object order_id: - description: >- - The ID of the order that the payment session was potentially created - for. + description: The ID of the order that the payment session was potentially created for. nullable: true type: string example: order_01G8TJSYT9M6AVS5N4EMNFS1EK order: - description: >- - The details of the order that the payment session was potentially - created for. + description: The details of the order that the payment session was potentially created for. x-expandable: order nullable: true type: object @@ -39607,9 +36510,7 @@ components: nullable: true $ref: '#/components/schemas/Currency' amount_refunded: - description: >- - The amount of the original Payment amount that has been refunded - back to the Customer. + description: The amount of the original Payment amount that has been refunded back to the Customer. type: integer default: 0 example: 0 @@ -39618,11 +36519,7 @@ components: type: string example: manual data: - description: >- - The data required for the Payment Provider to identify, modify and - process the Payment. Typically this will be an object that holds an - id to the external payment session, but can be an empty object if - the Payment Provider doesn't hold any state. + description: The data required for the Payment Provider to identify, modify and process the Payment. Typically this will be an object that holds an id to the external payment session, but can be an empty object if the Payment Provider doesn't hold any state. type: object example: {} captured_at: @@ -39636,9 +36533,7 @@ components: type: string format: date-time idempotency_key: - description: >- - Randomly generated key used to continue the completion of a payment - in case of failure. + description: Randomly generated key used to continue the completion of a payment in case of failure. nullable: true type: string externalDocs: @@ -39659,17 +36554,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute PaymentCollection: title: Payment Collection - description: >- - A payment collection allows grouping and managing a list of payments at - one. This can be helpful when making additional payment for order edits - or integrating installment payments. + description: A payment collection allows grouping and managing a list of payments at one. This can be helpful when making additional payment for order edits or integrating installment payments. type: object required: - amount @@ -39720,40 +36609,30 @@ components: type: string example: reg_01G1G5V26T9H8Y0M4JNE3YGA4G region: - description: >- - The details of the region this payment collection is associated - with. + description: The details of the region this payment collection is associated with. x-expandable: region nullable: true $ref: '#/components/schemas/Region' currency_code: - description: >- - The three character ISO code for the currency this payment - collection is associated with. + description: The three character ISO code for the currency this payment collection is associated with. type: string example: usd externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes description: See a list of codes. currency: - description: >- - The details of the currency this payment collection is associated - with. + description: The details of the currency this payment collection is associated with. x-expandable: currency nullable: true $ref: '#/components/schemas/Currency' payment_sessions: - description: >- - The details of the payment sessions created as part of the payment - collection. + description: The details of the payment sessions created as part of the payment collection. type: array x-expandable: payment_sessions items: $ref: '#/components/schemas/PaymentSession' payments: - description: >- - The details of the payments created as part of the payment - collection. + description: The details of the payments created as part of the payment collection. type: array x-expandable: payments items: @@ -39781,17 +36660,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute PaymentProvider: title: Payment Provider - description: >- - A payment provider represents a payment service installed in the Medusa - backend, either through a plugin or backend customizations. It holds the - payment service's installation status. + description: A payment provider represents a payment service installed in the Medusa backend, either through a plugin or backend customizations. It holds the payment service's installation status. type: object required: - id @@ -39802,22 +36675,12 @@ components: type: string example: manual is_installed: - description: >- - Whether the payment service is installed in the current version. If - a payment service is no longer installed, the `is_installed` - attribute is set to `false`. + description: Whether the payment service is installed in the current version. If a payment service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true PaymentSession: title: Payment Session - description: >- - A Payment Session is created when a Customer initilizes the checkout - flow, and can be used to hold the state of a payment flow. Each Payment - Session is controlled by a Payment Provider, which is responsible for - the communication with external payment services. Authorized Payment - Sessions will eventually get promoted to Payments to indicate that they - are authorized for payment processing such as capture or refund. Payment - sessions can also be used as part of payment collections. + description: A Payment Session is created when a Customer initilizes the checkout flow, and can be used to hold the state of a payment flow. Each Payment Session is controlled by a Payment Provider, which is responsible for the communication with external payment services. Authorized Payment Sessions will eventually get promoted to Payments to indicate that they are authorized for payment processing such as capture or refund. Payment sessions can also be used as part of payment collections. type: object required: - amount @@ -39848,31 +36711,21 @@ components: nullable: true $ref: '#/components/schemas/Cart' provider_id: - description: >- - The ID of the Payment Provider that is responsible for the Payment - Session + description: The ID of the Payment Provider that is responsible for the Payment Session type: string example: manual is_selected: - description: >- - A flag to indicate if the Payment Session has been selected as the - method that will be used to complete the purchase. + description: A flag to indicate if the Payment Session has been selected as the method that will be used to complete the purchase. nullable: true type: boolean example: true is_initiated: - description: >- - A flag to indicate if a communication with the third party provider - has been initiated. + description: A flag to indicate if a communication with the third party provider has been initiated. type: boolean default: false example: true status: - description: >- - Indicates the status of the Payment Session. Will default to - `pending`, and will eventually become `authorized`. Payment Sessions - may have the status of `requires_more` to indicate that further - actions are to be completed by the Customer. + description: Indicates the status of the Payment Session. Will default to `pending`, and will eventually become `authorized`. Payment Sessions may have the status of `requires_more` to indicate that further actions are to be completed by the Customer. type: string enum: - authorized @@ -39882,17 +36735,11 @@ components: - canceled example: pending data: - description: >- - The data required for the Payment Provider to identify, modify and - process the Payment Session. Typically this will be an object that - holds an id to the external payment session, but can be an empty - object if the Payment Provider doesn't hold any state. + description: The data required for the Payment Provider to identify, modify and process the Payment Session. Typically this will be an object that holds an id to the external payment session, but can be an empty object if the Payment Provider doesn't hold any state. type: object example: {} idempotency_key: - description: >- - Randomly generated key used to continue the completion of a cart in - case of failure. + description: Randomly generated key used to continue the completion of a cart in case of failure. nullable: true type: string externalDocs: @@ -39918,9 +36765,7 @@ components: format: date-time PriceList: title: Price List - description: >- - A Price List represents a set of prices that override the default price - for one or more product variants. + description: A Price List represents a set of prices that override the default price for one or more product variants. type: object required: - created_at @@ -39947,9 +36792,7 @@ components: type: string example: Prices for VIP customers type: - description: >- - The type of Price List. This can be one of either `sale` or - `override`. + description: The type of Price List. This can be one of either `sale` or `override`. type: string enum: - sale @@ -39979,9 +36822,7 @@ components: items: $ref: '#/components/schemas/CustomerGroup' prices: - description: >- - The prices that belong to the price list, represented as a Money - Amount. + description: The prices that belong to the price list, represented as a Money Amount. type: array x-expandable: prices items: @@ -40053,9 +36894,7 @@ components: properties: original_price: type: number - description: >- - The original price of the variant without any discounted prices - applied. + description: The original price of the variant without any discounted prices applied. calculated_price: type: number description: The calculated price of the variant. Can be a discounted price. @@ -40088,12 +36927,7 @@ components: description: The code of the tax rate Product: title: Product - description: >- - A product is a saleable item that holds general information such as name - or description. It must include at least one Product Variant, where each - product variant defines different options to purchase the product with - (for example, different sizes or colors). The prices and inventory of - the product are defined on the variant level. + description: A product is a saleable item that holds general information such as name or description. It must include at least one Product Variant, where each product variant defines different options to purchase the product with (for example, different sizes or colors). The prices and inventory of the product are defined on the variant level. type: object required: - collection_id @@ -40127,15 +36961,11 @@ components: type: string example: prod_01G1G5V2MBA328390B5AXJ610F title: - description: >- - A title that can be displayed for easy identification of the - Product. + description: A title that can be displayed for easy identification of the Product. type: string example: Medusa Coffee Mug subtitle: - description: >- - An optional subtitle that can be used to further specify the - Product. + description: An optional subtitle that can be used to further specify the Product. nullable: true type: string description: @@ -40149,10 +36979,7 @@ components: type: string example: coffee-mug is_giftcard: - description: >- - Whether the Product represents a Gift Card. Products that represent - Gift Cards will automatically generate a redeemable Gift Card code - once they are purchased. + description: Whether the Product represents a Gift Card. Products that represent Gift Cards will automatically generate a redeemable Gift Card code once they are purchased. type: boolean default: false status: @@ -40176,18 +37003,13 @@ components: type: string format: uri options: - description: >- - The details of the Product Options that are defined for the Product. - The product's variants will have a unique combination of values of - the product's options. + description: The details of the Product Options that are defined for the Product. The product's variants will have a unique combination of values of the product's options. type: array x-expandable: options items: $ref: '#/components/schemas/ProductOption' variants: - description: >- - The details of the Product Variants that belong to the Product. Each - will have a unique combination of values of the product's options. + description: The details of the Product Variants that belong to the Product. Each will have a unique combination of values of the product's options. type: array x-expandable: variants items: @@ -40200,17 +37022,11 @@ components: items: $ref: '#/components/schemas/ProductCategory' profile_id: - description: >- - The ID of the shipping profile that the product belongs to. The - shipping profile has a set of defined shipping options that can be - used to fulfill the product. + description: The ID of the shipping profile that the product belongs to. The shipping profile has a set of defined shipping options that can be used to fulfill the product. type: string example: sp_01G1G5V239ENSZ5MV4JAR737BM profile: - description: >- - The details of the shipping profile that the product belongs to. The - shipping profile has a set of defined shipping options that can be - used to fulfill the product. + description: The details of the shipping profile that the product belongs to. The shipping profile has a set of defined shipping options that can be used to fulfill the product. x-expandable: profile nullable: true $ref: '#/components/schemas/ShippingProfile' @@ -40221,62 +37037,42 @@ components: items: $ref: '#/components/schemas/ShippingProfile' weight: - description: >- - The weight of the Product Variant. May be used in shipping rate - calculations. + description: The weight of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null length: - description: >- - The length of the Product Variant. May be used in shipping rate - calculations. + description: The length of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null height: - description: >- - The height of the Product Variant. May be used in shipping rate - calculations. + description: The height of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null width: - description: >- - The width of the Product Variant. May be used in shipping rate - calculations. + description: The width of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null hs_code: - description: >- - The Harmonized System code of the Product Variant. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null origin_country: - description: >- - The country in which the Product Variant was produced. May be used - by Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Product Variant was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Product Variant. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null material: - description: >- - The material and composition that the Product Variant is made of, - May be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Product Variant is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null @@ -40307,9 +37103,7 @@ components: items: $ref: '#/components/schemas/ProductTag' discountable: - description: >- - Whether the Product can be discounted. Discounts will not apply to - Line Items of this Product when this flag is set to `false`. + description: Whether the Product can be discounted. Discounts will not apply to Line Items of this Product when this flag is set to `false`. type: boolean default: true external_id: @@ -40343,16 +37137,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductCategory: title: Product Category - description: >- - A product category can be used to categorize products into a hierarchy - of categories. + description: A product category can be used to categorize products into a hierarchy of categories. x-resourceId: ProductCategory x-featureFlag: product_categories type: object @@ -40382,15 +37171,11 @@ components: type: string default: '' handle: - description: >- - A unique string that identifies the Product Category - can for - example be used in slug structures. + description: A unique string that identifies the Product Category - can for example be used in slug structures. type: string example: regular-fit mpath: - description: >- - A string for Materialized Paths - used for finding ancestors and - descendents + description: A string for Materialized Paths - used for finding ancestors and descendents nullable: true type: string example: pcat_id1.pcat_id2.pcat_id3 @@ -40443,17 +37228,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductCollection: title: Product Collection - description: >- - A Product Collection allows grouping together products for promotional - purposes. For example, an admin can create a Summer collection, add - products to it, and showcase it on the storefront. + description: A Product Collection allows grouping together products for promotional purposes. For example, an admin can create a Summer collection, add products to it, and showcase it on the storefront. type: object required: - created_at @@ -40473,9 +37252,7 @@ components: type: string example: Summer Collection handle: - description: >- - A unique string that identifies the Product Collection - can for - example be used in slug structures. + description: A unique string that identifies the Product Collection - can for example be used in slug structures. nullable: true type: string example: summer-collection @@ -40505,17 +37282,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductOption: title: Product Option - description: >- - A Product Option defines properties that may vary between different - variants of a Product. Common Product Options are "Size" and "Color". - Admins are free to create any product options. + description: A Product Option defines properties that may vary between different variants of a Product. Common Product Options are "Size" and "Color". Admins are free to create any product options. type: object required: - created_at @@ -40569,16 +37340,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductOptionValue: title: Product Option Value - description: >- - An option value is one of the possible values of a Product Option. - Product Variants specify a unique combination of product option values. + description: An option value is one of the possible values of a Product Option. Product Variants specify a unique combination of product option values. type: object required: - created_at @@ -40595,22 +37361,15 @@ components: type: string example: optval_01F0YESHR7S6ECD03RF6W12DSJ value: - description: >- - The value that the Product Variant has defined for the specific - Product Option (e.g. if the Product Option is "Size" this value - could be `Small`, `Medium` or `Large`). + description: The value that the Product Variant has defined for the specific Product Option (e.g. if the Product Option is "Size" this value could be `Small`, `Medium` or `Large`). type: string example: large option_id: - description: >- - The ID of the Product Option that the Product Option Value belongs - to. + description: The ID of the Product Option that the Product Option Value belongs to. type: string example: opt_01F0YESHQBZVKCEXJ24BS6PCX3 option: - description: >- - The details of the product option that the Product Option Value - belongs to. + description: The details of the product option that the Product Option Value belongs to. x-expandable: option nullable: true type: object @@ -40619,9 +37378,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 variant: - description: >- - The details of the product variant that uses this product option - value. + description: The details of the product variant that uses this product option value. x-expandable: variant nullable: true type: object @@ -40645,11 +37402,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductTag: title: Product Tag description: A Product Tag can be added to Products for easy filtering and grouping. @@ -40690,16 +37444,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductTaxRate: title: Product Tax Rate - description: >- - This represents the association between a tax rate and a product to - indicate that the product is taxed in a way different than the default. + description: This represents the association between a tax rate and a product to indicate that the product is taxed in a way different than the default. type: object required: - created_at @@ -40741,16 +37490,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductType: title: Product Type - description: >- - A Product Type can be added to Products for filtering and reporting - purposes. + description: A Product Type can be added to Products for filtering and reporting purposes. type: object required: - created_at @@ -40788,17 +37532,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductTypeTaxRate: title: Product Type Tax Rate - description: >- - This represents the association between a tax rate and a product type to - indicate that the product type is taxed in a different way than the - default. + description: This represents the association between a tax rate and a product type to indicate that the product type is taxed in a different way than the default. type: object required: - created_at @@ -40840,18 +37578,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductVariant: title: Product Variant - description: >- - A Product Variant represents a Product with a specific set of Product - Option configurations. The maximum number of Product Variants that a - Product can have is given by the number of available Product Option - combinations. A product must at least have one product variant. + description: A Product Variant represents a Product with a specific set of Product Option configurations. The maximum number of Product Variants that a Product can have is given by the number of available Product Option combinations. A product must at least have one product variant. type: object required: - allow_backorder @@ -40882,9 +37613,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 title: - description: >- - A title that can be displayed for easy identification of the Product - Variant. + description: A title that can be displayed for easy identification of the Product Variant. type: string example: Small product_id: @@ -40897,40 +37626,28 @@ components: nullable: true type: object prices: - description: >- - The details of the prices of the Product Variant, each represented - as a Money Amount. Each Money Amount represents a price in a given - currency or a specific Region. + description: The details of the prices of the Product Variant, each represented as a Money Amount. Each Money Amount represents a price in a given currency or a specific Region. type: array x-expandable: prices items: $ref: '#/components/schemas/MoneyAmount' sku: - description: >- - The unique stock keeping unit used to identify the Product Variant. - This will usually be a unique identifer for the item that is to be - shipped, and can be referenced across multiple systems. + description: The unique stock keeping unit used to identify the Product Variant. This will usually be a unique identifer for the item that is to be shipped, and can be referenced across multiple systems. nullable: true type: string example: shirt-123 barcode: - description: >- - A generic field for a GTIN number that can be used to identify the - Product Variant. + description: A generic field for a GTIN number that can be used to identify the Product Variant. nullable: true type: string example: null ean: - description: >- - An EAN barcode number that can be used to identify the Product - Variant. + description: An EAN barcode number that can be used to identify the Product Variant. nullable: true type: string example: null upc: - description: >- - A UPC barcode number that can be used to identify the Product - Variant. + description: A UPC barcode number that can be used to identify the Product Variant. nullable: true type: string example: null @@ -40944,9 +37661,7 @@ components: type: integer example: 100 allow_backorder: - description: >- - Whether the Product Variant should be purchasable when - `inventory_quantity` is 0. + description: Whether the Product Variant should be purchasable when `inventory_quantity` is 0. type: boolean default: false manage_inventory: @@ -40954,69 +37669,47 @@ components: type: boolean default: true hs_code: - description: >- - The Harmonized System code of the Product Variant. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null origin_country: - description: >- - The country in which the Product Variant was produced. May be used - by Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Product Variant was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Product Variant. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null material: - description: >- - The material and composition that the Product Variant is made of, - May be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Product Variant is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null weight: - description: >- - The weight of the Product Variant. May be used in shipping rate - calculations. + description: The weight of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null length: - description: >- - The length of the Product Variant. May be used in shipping rate - calculations. + description: The length of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null height: - description: >- - The height of the Product Variant. May be used in shipping rate - calculations. + description: The height of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null width: - description: >- - The width of the Product Variant. May be used in shipping rate - calculations. + description: The width of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null options: - description: >- - The details of the product options that this product variant defines - values for. + description: The details of the product options that this product variant defines values for. type: array x-expandable: options items: @@ -41047,18 +37740,12 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute purchasable: - description: > + description: | Only used with the inventory modules. - - A boolean value indicating whether the Product Variant is - purchasable. - + A boolean value indicating whether the Product Variant is purchasable. A variant is purchasable if: - inventory is not managed - it has no inventory items @@ -41067,9 +37754,7 @@ components: type: boolean ProductVariantInventoryItem: title: Product Variant Inventory Item - description: >- - A Product Variant Inventory Item links variants with inventory items and - denotes the required quantity of the variant. + description: A Product Variant Inventory Item links variants with inventory items and denotes the required quantity of the variant. type: object required: - created_at @@ -41114,15 +37799,7 @@ components: format: date-time PublishableApiKey: title: Publishable API key - description: >- - A Publishable API key defines scopes that resources are available in. - Then, it can be used in request to infer the resources without having to - directly pass them. For example, a publishable API key can be associated - with one or more sales channels. Then, when the publishable API key is - passed in the header of a request, it is inferred what sales channel is - being used without having to pass the sales channel as a query or body - parameter of the request. Publishable API keys can only be used with - sales channels, at the moment. + description: A Publishable API key defines scopes that resources are available in. Then, it can be used in request to infer the resources without having to directly pass them. For example, a publishable API key can be associated with one or more sales channels. Then, when the publishable API key is passed in the header of a request, it is inferred what sales channel is being used without having to pass the sales channel as a query or body parameter of the request. Publishable API keys can only be used with sales channels, at the moment. type: object required: - created_at @@ -41165,9 +37842,7 @@ components: format: date-time PublishableApiKeySalesChannel: title: Publishable API Key Sales Channel - description: >- - This represents the association between the Publishable API keys and - Sales Channels + description: This represents the association between the Publishable API keys and Sales Channels type: object required: - publishable_key_id @@ -41203,10 +37878,7 @@ components: format: date-time Refund: title: Refund - description: >- - A refund represents an amount of money transfered back to the customer - for a given reason. Refunds may occur in relation to Returns, Swaps and - Claims, but can also be initiated by an admin for an order. + description: A refund represents an amount of money transfered back to the customer for a given reason. Refunds may occur in relation to Returns, Swaps and Claims, but can also be initiated by an admin for an order. type: object required: - amount @@ -41254,9 +37926,7 @@ components: type: string example: I didn't like it reason: - description: >- - The reason given for the Refund, will automatically be set when - processed as part of a Swap, Claim or Return. + description: The reason given for the Refund, will automatically be set when processed as part of a Swap, Claim or Return. type: string enum: - discount @@ -41266,9 +37936,7 @@ components: - other example: return idempotency_key: - description: >- - Randomly generated key used to continue the completion of the refund - in case of failure. + description: Randomly generated key used to continue the completion of the refund in case of failure. nullable: true type: string externalDocs: @@ -41289,18 +37957,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Region: title: Region - description: >- - A region holds settings specific to a geographical location, including - the currency, tax rates, and fulfillment and payment providers. A Region - can consist of multiple countries to accomodate common shopping settings - across countries. + description: A region holds settings specific to a geographical location, including the currency, tax rates, and fulfillment and payment providers. A Region can consist of multiple countries to accomodate common shopping settings across countries. type: object required: - automatic_taxes @@ -41321,9 +37982,7 @@ components: type: string example: reg_01G1G5V26T9H8Y0M4JNE3YGA4G name: - description: >- - The name of the region as displayed to the customer. If the Region - only has one country it is recommended to write the country name. + description: The name of the region as displayed to the customer. If the Region only has one country it is recommended to write the country name. type: string example: EU currency_code: @@ -41343,17 +38002,13 @@ components: type: number example: 0 tax_rates: - description: >- - The details of the tax rates used in the region, aside from the - default rate. + description: The details of the tax rates used in the region, aside from the default rate. type: array x-expandable: tax_rates items: $ref: '#/components/schemas/TaxRate' tax_code: - description: >- - The tax code used on purchases in the Region. This may be used by - other systems for accounting purposes. + description: The tax code used on purchases in the Region. This may be used by other systems for accounting purposes. nullable: true type: string example: null @@ -41382,17 +38037,13 @@ components: nullable: true $ref: '#/components/schemas/TaxProvider' payment_providers: - description: >- - The details of the payment providers that can be used to process - payments in the region. + description: The details of the payment providers that can be used to process payments in the region. type: array x-expandable: payment_providers items: $ref: '#/components/schemas/PaymentProvider' fulfillment_providers: - description: >- - The details of the fulfillment providers that can be used to fulfill - items of orders and similar resources in the region. + description: The details of the fulfillment providers that can be used to fulfill items of orders and similar resources in the region. type: array x-expandable: fulfillment_providers items: @@ -41422,11 +38073,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ReservationItemDTO: title: Reservation item description: Represents a reservation of an inventory item at a stock location @@ -41492,10 +38140,7 @@ components: type: number Return: title: Return - description: >- - A Return holds information about Line Items that a Customer wishes to - send back, along with how the items will be returned. Returns can also - be used as part of a Swap or a Claim. + description: A Return holds information about Line Items that a Customer wishes to send back, along with how the items will be returned. Returns can also be used as part of a Swap or a Claim. type: object required: - claim_order_id @@ -41563,17 +38208,12 @@ components: nullable: true type: object shipping_method: - description: >- - The details of the Shipping Method that will be used to send the - Return back. Can be null if the Customer will handle the return - shipment themselves. + description: The details of the Shipping Method that will be used to send the Return back. Can be null if the Customer will handle the return shipment themselves. x-expandable: shipping_method nullable: true $ref: '#/components/schemas/ShippingMethod' shipping_data: - description: >- - Data about the return shipment as provided by the Fulfilment - Provider that handles the return shipment. + description: Data about the return shipment as provided by the Fulfilment Provider that handles the return shipment. nullable: true type: object example: {} @@ -41587,16 +38227,12 @@ components: type: integer example: 1000 no_notification: - description: >- - When set to true, no notification will be sent related to this - return. + description: When set to true, no notification will be sent related to this return. nullable: true type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the return - in case of failure. + description: Randomly generated key used to continue the completion of the return in case of failure. nullable: true type: string externalDocs: @@ -41622,16 +38258,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ReturnItem: title: Return Item - description: >- - A return item represents a line item in an order that is to be returned. - It includes details related to the return and the reason behind it. + description: A return item represents a line item in an order that is to be returned. It includes details related to the return and the reason behind it. type: object required: - is_requested @@ -41667,9 +38298,7 @@ components: type: integer example: 1 is_requested: - description: >- - Whether the Return Item was requested initially or received - unexpectedly in the warehouse. + description: Whether the Return Item was requested initially or received unexpectedly in the warehouse. type: boolean default: true requested_quantity: @@ -41704,16 +38333,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ReturnReason: title: Return Reason - description: >- - A Return Reason is a value defined by an admin. It can be used on Return - Items in order to indicate why a Line Item was returned. + description: A Return Reason is a value defined by an admin. It can be used on Return Items in order to indicate why a Line Item was returned. type: object required: - created_at @@ -41777,17 +38401,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute SalesChannel: title: Sales Channel - description: >- - A Sales Channel is a method a business offers its products for purchase - for the customers. For example, a Webshop can be a sales channel, and a - mobile app can be another. + description: A Sales Channel is a method a business offers its products for purchase for the customers. For example, a Webshop can be a sales channel, and a mobile app can be another. type: object required: - created_at @@ -41841,11 +38459,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute carts: description: The associated carts. type: array @@ -41871,9 +38486,7 @@ components: type: object SalesChannelLocation: title: Sales Channel Stock Location - description: >- - This represents the association between a sales channel and a stock - locations. + description: This represents the association between a sales channel and a stock locations. type: object required: - created_at @@ -41914,13 +38527,7 @@ components: format: date-time ShippingMethod: title: Shipping Method - description: >- - A Shipping Method represents a way in which an Order or Return can be - shipped. Shipping Methods are created from a Shipping Option, but may - contain additional details that can be necessary for the Fulfillment - Provider to handle the shipment. If the shipping method is created for a - return, it may be associated with a claim or a swap that the return is - part of. + description: A Shipping Method represents a way in which an Order or Return can be shipped. Shipping Methods are created from a Shipping Option, but may contain additional details that can be necessary for the Fulfillment Provider to handle the shipment. If the shipping method is created for a return, it may be associated with a claim or a swap that the return is part of. type: object required: - cart_id @@ -41938,9 +38545,7 @@ components: type: string example: sm_01F0YET7DR2E7CYVSDHM593QG2 shipping_option_id: - description: >- - The ID of the Shipping Option that the Shipping Method is built - from. + description: The ID of the Shipping Option that the Shipping Method is built from. type: string example: so_01G1G5V27GYX4QXNARRQCW1N8T order_id: @@ -42005,17 +38610,11 @@ components: items: $ref: '#/components/schemas/ShippingMethodTaxLine' price: - description: >- - The amount to charge for the Shipping Method. The currency of the - price is defined by the Region that the Order that the Shipping - Method belongs to is a part of. + description: The amount to charge for the Shipping Method. The currency of the price is defined by the Region that the Order that the Shipping Method belongs to is a part of. type: integer example: 200 data: - description: >- - Additional data that the Fulfillment Provider needs to fulfill the - shipment. This is used in combination with the Shipping Options - data, and may contain information such as a drop point id. + description: Additional data that the Fulfillment Provider needs to fulfill the shipment. This is used in combination with the Shipping Options data, and may contain information such as a drop point id. type: object example: {} includes_tax: @@ -42037,9 +38636,7 @@ components: example: 0 ShippingMethodTaxLine: title: Shipping Method Tax Line - description: >- - A Shipping Method Tax Line represents the taxes applied on a shipping - method in a cart. + description: A Shipping Method Tax Line represents the taxes applied on a shipping method in a cart. type: object required: - code @@ -42092,20 +38689,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ShippingOption: title: Shipping Option - description: >- - A Shipping Option represents a way in which an Order or Return can be - shipped. Shipping Options have an associated Fulfillment Provider that - will be used when the fulfillment of an Order is initiated. Shipping - Options themselves cannot be added to Carts, but serve as a template for - Shipping Methods. This distinction makes it possible to customize - individual Shipping Methods with additional information. + description: A Shipping Option represents a way in which an Order or Return can be shipped. Shipping Options have an associated Fulfillment Provider that will be used when the fulfillment of an Order is initiated. Shipping Options themselves cannot be added to Carts, but serve as a template for Shipping Methods. This distinction makes it possible to customize individual Shipping Methods with additional information. type: object required: - admin_only @@ -42128,9 +38716,7 @@ components: type: string example: so_01G1G5V27GYX4QXNARRQCW1N8T name: - description: >- - The name given to the Shipping Option - this may be displayed to the - Customer. + description: The name given to the Shipping Option - this may be displayed to the Customer. type: string example: PostFake Standard region_id: @@ -42147,69 +38733,47 @@ components: type: string example: sp_01G1G5V239ENSZ5MV4JAR737BM profile: - description: >- - The details of the shipping profile that the shipping option belongs - to. + description: The details of the shipping profile that the shipping option belongs to. x-expandable: profile nullable: true $ref: '#/components/schemas/ShippingProfile' provider_id: - description: >- - The ID of the fulfillment provider that will be used to later to - process the shipping method created from this shipping option and - its fulfillments. + description: The ID of the fulfillment provider that will be used to later to process the shipping method created from this shipping option and its fulfillments. type: string example: manual provider: - description: >- - The details of the fulfillment provider that will be used to later - to process the shipping method created from this shipping option and - its fulfillments. + description: The details of the fulfillment provider that will be used to later to process the shipping method created from this shipping option and its fulfillments. x-expandable: provider nullable: true $ref: '#/components/schemas/FulfillmentProvider' price_type: - description: >- - The type of pricing calculation that is used when creatin Shipping - Methods from the Shipping Option. Can be `flat_rate` for fixed - prices or `calculated` if the Fulfillment Provider can provide price - calulations. + description: The type of pricing calculation that is used when creatin Shipping Methods from the Shipping Option. Can be `flat_rate` for fixed prices or `calculated` if the Fulfillment Provider can provide price calulations. type: string enum: - flat_rate - calculated example: flat_rate amount: - description: >- - The amount to charge for shipping when the Shipping Option price - type is `flat_rate`. + description: The amount to charge for shipping when the Shipping Option price type is `flat_rate`. nullable: true type: integer example: 200 is_return: - description: >- - Flag to indicate if the Shipping Option can be used for Return - shipments. + description: Flag to indicate if the Shipping Option can be used for Return shipments. type: boolean default: false admin_only: - description: >- - Flag to indicate if the Shipping Option usage is restricted to admin - users. + description: Flag to indicate if the Shipping Option usage is restricted to admin users. type: boolean default: false requirements: - description: >- - The details of the requirements that must be satisfied for the - Shipping Option to be available for usage in a Cart. + description: The details of the requirements that must be satisfied for the Shipping Option to be available for usage in a Cart. type: array x-expandable: requirements items: $ref: '#/components/schemas/ShippingOptionRequirement' data: - description: >- - The data needed for the Fulfillment Provider to identify the - Shipping Option. + description: The data needed for the Fulfillment Provider to identify the Shipping Option. type: object example: {} includes_tax: @@ -42237,16 +38801,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ShippingOptionRequirement: title: Shipping Option Requirement - description: >- - A shipping option requirement defines conditions that a Cart must - satisfy for the Shipping Option to be available for usage in the Cart. + description: A shipping option requirement defines conditions that a Cart must satisfy for the Shipping Option to be available for usage in the Cart. type: object required: - amount @@ -42269,12 +38828,7 @@ components: nullable: true type: object type: - description: >- - The type of the requirement, this defines how the value will be - compared to the Cart's total. `min_subtotal` requirements define the - minimum subtotal that is needed for the Shipping Option to be - available, while the `max_subtotal` defines the maximum subtotal - that the Cart can have for the Shipping Option to be available. + description: The type of the requirement, this defines how the value will be compared to the Cart's total. `min_subtotal` requirements define the minimum subtotal that is needed for the Shipping Option to be available, while the `max_subtotal` defines the maximum subtotal that the Cart can have for the Shipping Option to be available. type: string enum: - min_subtotal @@ -42291,12 +38845,7 @@ components: format: date-time ShippingProfile: title: Shipping Profile - description: >- - A Shipping Profile has a set of defined Shipping Options that can be - used to fulfill a given set of Products. For example, gift cards are - shipped differently than physical products, so a shipping profile with - the type `gift_card` groups together the shipping options that can only - be used for gift cards. + description: A Shipping Profile has a set of defined Shipping Options that can be used to fulfill a given set of Products. For example, gift cards are shipped differently than physical products, so a shipping profile with the type `gift_card` groups together the shipping options that can only be used for gift cards. type: object required: - created_at @@ -42312,15 +38861,11 @@ components: type: string example: sp_01G1G5V239ENSZ5MV4JAR737BM name: - description: >- - The name given to the Shipping profile - this may be displayed to - the Customer. + description: The name given to the Shipping profile - this may be displayed to the Customer. type: string example: Default Shipping Profile type: - description: >- - The type of the Shipping Profile, may be `default`, `gift_card` or - `custom`. + description: The type of the Shipping Profile, may be `default`, `gift_card` or `custom`. type: string enum: - default @@ -42328,18 +38873,13 @@ components: - custom example: default products: - description: >- - The details of the products that the Shipping Profile defines - Shipping Options for. Available if the relation `products` is - expanded. + description: The details of the products that the Shipping Profile defines Shipping Options for. Available if the relation `products` is expanded. type: array x-expandable: products items: type: object shipping_options: - description: >- - The details of the shipping options that can be used to create - shipping methods for the Products in the Shipping Profile. + description: The details of the shipping options that can be used to create shipping methods for the Products in the Shipping Profile. type: array x-expandable: shipping_options items: @@ -42364,11 +38904,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ShippingTaxRate: title: Shipping Tax Rate description: This represents the tax rates applied on a shipping option. @@ -42413,11 +38950,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute StagedJob: title: Staged Job description: A staged job resource @@ -42603,11 +39137,7 @@ components: $ref: '#/components/schemas/SalesChannel' Store: title: Store - description: >- - A store holds the main settings of the commerce shop. By default, only - one store is created and used within the Medusa backend. It holds - settings related to the name of the store, available currencies, and - more. + description: A store holds the main settings of the commerce shop. By default, only one store is created and used within the Medusa backend. It holds settings related to the name of the store, available currencies, and more. type: object required: - created_at @@ -42650,16 +39180,12 @@ components: items: $ref: '#/components/schemas/Currency' swap_link_template: - description: >- - A template to generate Swap links from. Use {{cart_id}} to include - the Swap's `cart_id` in the link. + description: A template to generate Swap links from. Use {{cart_id}} to include the Swap's `cart_id` in the link. nullable: true type: string example: null payment_link_template: - description: >- - A template to generate Payment links from. Use {{cart_id}} to - include the payment's `cart_id` in the link. + description: A template to generate Payment links from. Use {{cart_id}} to include the payment's `cart_id` in the link. nullable: true type: string example: null @@ -42698,19 +39224,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Swap: title: Swap - description: >- - A swap can be created when a Customer wishes to exchange Products that - they have purchased with different Products. It consists of a Return of - previously purchased Products and a Fulfillment of new Products. It also - includes information on any additional payment or refund required based - on the difference between the exchanged products. + description: A swap can be created when a Customer wishes to exchange Products that they have purchased with different Products. It consists of a Return of previously purchased Products and a Fulfillment of new Products. It also includes information on any additional payment or refund required based on the difference between the exchanged products. type: object required: - allow_backorder @@ -42746,9 +39264,7 @@ components: - requires_action example: not_fulfilled payment_status: - description: >- - The status of the Payment of the Swap. The payment may either refer - to the refund of an amount or the authorization of a new amount. + description: The status of the Payment of the Swap. The payment may either refer to the refund of an amount or the authorization of a new amount. type: string enum: - not_paid @@ -42771,63 +39287,44 @@ components: nullable: true type: object additional_items: - description: >- - The details of the new products to send to the customer, represented - as line items. + description: The details of the new products to send to the customer, represented as line items. type: array x-expandable: additional_items items: $ref: '#/components/schemas/LineItem' return_order: - description: >- - The details of the return that belongs to the swap, which holds the - details on the items being returned. + description: The details of the return that belongs to the swap, which holds the details on the items being returned. x-expandable: return_order nullable: true type: object fulfillments: - description: >- - The details of the fulfillments that are used to send the new items - to the customer. + description: The details of the fulfillments that are used to send the new items to the customer. x-expandable: fulfillments type: array items: type: object payment: - description: >- - The details of the additional payment authorized by the customer - when `difference_due` is positive. + description: The details of the additional payment authorized by the customer when `difference_due` is positive. x-expandable: payment nullable: true type: object difference_due: - description: >- - The difference amount between the order’s original total and the new - total imposed by the swap. If its value is negative, a refund must - be issues to the customer. If it's positive, additional payment must - be authorized by the customer. Otherwise, no payment processing is - required. + description: The difference amount between the order’s original total and the new total imposed by the swap. If its value is negative, a refund must be issues to the customer. If it's positive, additional payment must be authorized by the customer. Otherwise, no payment processing is required. nullable: true type: integer example: 0 shipping_address_id: - description: >- - The Address to send the new Line Items to - in most cases this will - be the same as the shipping address on the Order. + description: The Address to send the new Line Items to - in most cases this will be the same as the shipping address on the Order. nullable: true type: string example: addr_01G8ZH853YPY9B94857DY91YGW shipping_address: - description: >- - The details of the shipping address that the new items should be - sent to. + description: The details of the shipping address that the new items should be sent to. x-expandable: shipping_address nullable: true $ref: '#/components/schemas/Address' shipping_methods: - description: >- - The details of the shipping methods used to fulfill the additional - items purchased. + description: The details of the shipping methods used to fulfill the additional items purchased. type: array x-expandable: shipping_methods items: @@ -42843,9 +39340,7 @@ components: nullable: true type: object confirmed_at: - description: >- - The date with timezone at which the Swap was confirmed by the - Customer. + description: The date with timezone at which the Swap was confirmed by the Customer. nullable: true type: string format: date-time @@ -42864,9 +39359,7 @@ components: type: boolean default: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the swap - in case of failure. + description: Randomly generated key used to continue the completion of the swap in case of failure. nullable: true type: string externalDocs: @@ -42892,11 +39385,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute TaxLine: title: Tax Line description: A tax line represents the taxes amount applied to a line item. @@ -42942,17 +39432,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute TaxProvider: title: Tax Provider - description: >- - A tax provider represents a tax service installed in the Medusa backend, - either through a plugin or backend customizations. It holds the tax - service's installation status. + description: A tax provider represents a tax service installed in the Medusa backend, either through a plugin or backend customizations. It holds the tax service's installation status. type: object required: - id @@ -42963,17 +39447,12 @@ components: type: string example: manual is_installed: - description: >- - Whether the tax service is installed in the current version. If a - tax service is no longer installed, the `is_installed` attribute is - set to `false`. + description: Whether the tax service is installed in the current version. If a tax service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true TaxRate: title: Tax Rate - description: >- - A Tax Rate can be used to define a custom rate to charge on specified - products, product types, and shipping options within a given region. + description: A Tax Rate can be used to define a custom rate to charge on specified products, product types, and shipping options within a given region. type: object required: - code @@ -43057,19 +39536,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute TrackingLink: title: Tracking Link - description: >- - A tracking link holds information about tracking numbers for a - Fulfillment. Tracking Links can optionally contain a URL that can be - visited to see the status of the shipment. Typically, the tracking link - is provided from the third-party service integrated through the used - fulfillment provider. + description: A tracking link holds information about tracking numbers for a Fulfillment. Tracking Links can optionally contain a URL that can be visited to see the status of the shipment. Typically, the tracking link is provided from the third-party service integrated through the used fulfillment provider. type: object required: - created_at @@ -43105,9 +39576,7 @@ components: nullable: true type: object idempotency_key: - description: >- - Randomly generated key used to continue the completion of a process - in case of failure. + description: Randomly generated key used to continue the completion of a process in case of failure. nullable: true type: string externalDocs: @@ -43133,11 +39602,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute UpdateStockLocationInput: title: Update Stock Location Input description: Represents the Input to update a Stock Location @@ -43226,11 +39692,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute VariantInventory: type: object required: @@ -43246,9 +39709,7 @@ components: $ref: '#/components/schemas/ResponseInventoryItem' sales_channel_availability: type: array - description: >- - Details about the variant's inventory availability in sales - channels. + description: Details about the variant's inventory availability in sales channels. items: type: object required: diff --git a/www/apps/api-reference/specs/admin/openapi.yaml b/www/apps/api-reference/specs/admin/openapi.yaml index 626235e729..14bf37b3e9 100644 --- a/www/apps/api-reference/specs/admin/openapi.yaml +++ b/www/apps/api-reference/specs/admin/openapi.yaml @@ -5,6 +5,9 @@ info: license: name: MIT url: https://github.com/medusajs/medusa/blob/master/LICENSE +servers: + - url: http://localhost:9000 + - url: https://api.medusa-commerce.com tags: - name: Apps Oauth description: > @@ -344,9 +347,6 @@ tags: externalDocs: description: How to manage users url: https://docs.medusajs.com/modules/users/admin/manage-users -servers: - - url: http://localhost:9000 - - url: https://api.medusa-commerce.com paths: /admin/apps: $ref: paths/admin_apps.yaml diff --git a/www/apps/api-reference/specs/admin/paths/admin_auth.yaml b/www/apps/api-reference/specs/admin/paths/admin_auth.yaml index b4c2e8f4f1..d49b279bb1 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_auth.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_auth.yaml @@ -13,7 +13,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_auth/getundefined + $ref: ../code_samples/tsx/admin_auth/get.tsx - lang: Shell label: cURL source: @@ -67,7 +67,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_auth/postundefined + $ref: ../code_samples/tsx/admin_auth/post.tsx - lang: Shell label: cURL source: @@ -112,7 +112,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_auth/deleteundefined + $ref: ../code_samples/tsx/admin_auth/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs.yaml b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs.yaml index faff8f3c18..c6729da828 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs.yaml @@ -238,7 +238,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_batch-jobs/getundefined + $ref: ../code_samples/tsx/admin_batch-jobs/get.tsx - lang: Shell label: cURL source: @@ -294,7 +294,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_batch-jobs/postundefined + $ref: ../code_samples/tsx/admin_batch-jobs/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}.yaml index 7c0267d11c..73d0f2b431 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_batch-jobs_{id}/getundefined + $ref: ../code_samples/tsx/admin_batch-jobs_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_cancel.yaml index 275f30edb7..6e9c39897e 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_cancel.yaml @@ -22,7 +22,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_batch-jobs_{id}_cancel/postundefined + $ref: ../code_samples/tsx/admin_batch-jobs_{id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_confirm.yaml b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_confirm.yaml index 2803f0e740..59251f1d8f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_confirm.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_batch-jobs_{id}_confirm.yaml @@ -23,7 +23,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_batch-jobs_{id}_confirm/postundefined + $ref: ../code_samples/tsx/admin_batch-jobs_{id}_confirm/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_collections.yaml b/www/apps/api-reference/specs/admin/paths/admin_collections.yaml index d1d384a300..142bc873f4 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_collections.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_collections.yaml @@ -116,7 +116,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_collections/getundefined + $ref: ../code_samples/tsx/admin_collections/get.tsx - lang: Shell label: cURL source: @@ -166,7 +166,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_collections/postundefined + $ref: ../code_samples/tsx/admin_collections/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_collections_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_collections_{id}.yaml index 39692b0904..55ad2ba56e 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_collections_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_collections_{id}.yaml @@ -22,7 +22,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_collections_{id}/getundefined + $ref: ../code_samples/tsx/admin_collections_{id}/get.tsx - lang: Shell label: cURL source: @@ -79,7 +79,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_collections_{id}/postundefined + $ref: ../code_samples/tsx/admin_collections_{id}/post.tsx - lang: Shell label: cURL source: @@ -131,7 +131,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_collections_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_collections_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_collections_{id}_products_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_collections_{id}_products_batch.yaml index b22423ec05..f3bebda2b3 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_collections_{id}_products_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_collections_{id}_products_batch.yaml @@ -26,8 +26,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_collections_{id}_products_batch/postundefined + $ref: ../code_samples/tsx/admin_collections_{id}_products_batch/post.tsx - lang: Shell label: cURL source: @@ -87,8 +86,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_collections_{id}_products_batch/deleteundefined + $ref: ../code_samples/tsx/admin_collections_{id}_products_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_currencies.yaml b/www/apps/api-reference/specs/admin/paths/admin_currencies.yaml index ebc510fe9a..3d0620a81e 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_currencies.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_currencies.yaml @@ -22,6 +22,11 @@ get: description: A field to sort order the retrieved currencies by. schema: type: string + - in: query + name: q + description: Term used to search currencies' name and code. + schema: + type: string - in: query name: offset description: The number of currencies to skip when retrieving the currencies. @@ -45,7 +50,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_currencies/getundefined + $ref: ../code_samples/tsx/admin_currencies/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_currencies_{code}.yaml b/www/apps/api-reference/specs/admin/paths/admin_currencies_{code}.yaml index b8ea4d9738..2b932fa874 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_currencies_{code}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_currencies_{code}.yaml @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_currencies_{code}/postundefined + $ref: ../code_samples/tsx/admin_currencies_{code}/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_customer-groups.yaml b/www/apps/api-reference/specs/admin/paths/admin_customer-groups.yaml index aa98753fd0..d86c24ca3c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_customer-groups.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_customer-groups.yaml @@ -136,7 +136,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customer-groups/getundefined + $ref: ../code_samples/tsx/admin_customer-groups/get.tsx - lang: Shell label: cURL source: @@ -186,7 +186,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customer-groups/postundefined + $ref: ../code_samples/tsx/admin_customer-groups/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}.yaml index 607b8bd187..047ca1ac56 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}.yaml @@ -37,7 +37,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customer-groups_{id}/getundefined + $ref: ../code_samples/tsx/admin_customer-groups_{id}/get.tsx - lang: Shell label: cURL source: @@ -94,7 +94,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customer-groups_{id}/postundefined + $ref: ../code_samples/tsx/admin_customer-groups_{id}/post.tsx - lang: Shell label: cURL source: @@ -148,7 +148,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customer-groups_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_customer-groups_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers.yaml b/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers.yaml index dbf71cceb7..0d5b23de37 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers.yaml @@ -47,7 +47,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customer-groups_{id}_customers/getundefined + $ref: ../code_samples/tsx/admin_customer-groups_{id}_customers/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers_batch.yaml index 156e819ad3..7fcfc1496f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_customer-groups_{id}_customers_batch.yaml @@ -28,7 +28,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_customer-groups_{id}_customers_batch/postundefined + ../code_samples/tsx/admin_customer-groups_{id}_customers_batch/post.tsx - lang: Shell label: cURL source: @@ -91,7 +91,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_customer-groups_{id}_customers_batch/deleteundefined + ../code_samples/tsx/admin_customer-groups_{id}_customers_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_customers.yaml b/www/apps/api-reference/specs/admin/paths/admin_customers.yaml index c0f48ddb61..f1f20e25cd 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_customers.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_customers.yaml @@ -50,7 +50,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customers/getundefined + $ref: ../code_samples/tsx/admin_customers/get.tsx - lang: Shell label: cURL source: @@ -100,7 +100,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customers/postundefined + $ref: ../code_samples/tsx/admin_customers/post.tsx - lang: Shell label: cURL source: 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 7be8cd5827..7c88c29522 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 @@ -32,7 +32,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customers_{id}/getundefined + $ref: ../code_samples/tsx/admin_customers_{id}/get.tsx - lang: Shell label: cURL source: @@ -103,7 +103,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_customers_{id}/postundefined + $ref: ../code_samples/tsx/admin_customers_{id}/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts.yaml index 4002e4822f..d8d07ca410 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts.yaml @@ -70,7 +70,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_discounts/getundefined + $ref: ../code_samples/tsx/admin_discounts/get.tsx - lang: Shell label: cURL source: @@ -138,7 +138,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_discounts/postundefined + $ref: ../code_samples/tsx/admin_discounts/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_code_{code}.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_code_{code}.yaml index 46f9df2596..1a8d89a44c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_code_{code}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_code_{code}.yaml @@ -33,7 +33,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_discounts_code_{code}/getundefined + $ref: ../code_samples/tsx/admin_discounts_code_{code}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions.yaml index 6747c77b17..0d79eefdf2 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions.yaml @@ -44,8 +44,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_discounts_{discount_id}_conditions/postundefined + $ref: ../code_samples/tsx/admin_discounts_{discount_id}_conditions/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}.yaml index 47f6e081a0..d37318f7ed 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}.yaml @@ -43,7 +43,7 @@ get: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/getundefined + ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/get.tsx - lang: Shell label: cURL source: @@ -128,7 +128,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/postundefined + ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/post.tsx - lang: Shell label: cURL source: @@ -204,7 +204,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/deleteundefined + ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}_batch.yaml index 332bf46809..23b937438f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_{discount_id}_conditions_{condition_id}_batch.yaml @@ -51,7 +51,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/postundefined + ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/post.tsx - lang: Shell label: cURL source: @@ -133,7 +133,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/deleteundefined + ../code_samples/tsx/admin_discounts_{discount_id}_conditions_{condition_id}_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}.yaml index 6b1c16ffb6..d26af24edc 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}.yaml @@ -33,7 +33,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_discounts_{id}/getundefined + $ref: ../code_samples/tsx/admin_discounts_{id}/get.tsx - lang: Shell label: cURL source: @@ -107,7 +107,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_discounts_{id}/postundefined + $ref: ../code_samples/tsx/admin_discounts_{id}/post.tsx - lang: Shell label: cURL source: @@ -161,7 +161,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_discounts_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_discounts_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes.yaml index ed5e277745..873adfc362 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes.yaml @@ -28,7 +28,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_discounts_{id}_dynamic-codes/postundefined + $ref: ../code_samples/tsx/admin_discounts_{id}_dynamic-codes/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes_{code}.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes_{code}.yaml index a3aa1bdd58..674e44c28f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes_{code}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_dynamic-codes_{code}.yaml @@ -28,7 +28,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_discounts_{id}_dynamic-codes_{code}/deleteundefined + ../code_samples/tsx/admin_discounts_{id}_dynamic-codes_{code}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_regions_{region_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_regions_{region_id}.yaml index 95162434c1..0ee9e2b50d 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_regions_{region_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_discounts_{id}_regions_{region_id}.yaml @@ -27,8 +27,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_discounts_{id}_regions_{region_id}/postundefined + $ref: ../code_samples/tsx/admin_discounts_{id}_regions_{region_id}/post.tsx - lang: Shell label: cURL source: @@ -91,7 +90,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_discounts_{id}_regions_{region_id}/deleteundefined + ../code_samples/tsx/admin_discounts_{id}_regions_{region_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_draft-orders.yaml b/www/apps/api-reference/specs/admin/paths/admin_draft-orders.yaml index 97be490ee1..2c18e9c97c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_draft-orders.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_draft-orders.yaml @@ -36,7 +36,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_draft-orders/getundefined + $ref: ../code_samples/tsx/admin_draft-orders/get.tsx - lang: Shell label: cURL source: @@ -88,7 +88,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_draft-orders/postundefined + $ref: ../code_samples/tsx/admin_draft-orders/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}.yaml index a6e23ca2ea..9cd62c7cdc 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_draft-orders_{id}/getundefined + $ref: ../code_samples/tsx/admin_draft-orders_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_draft-orders_{id}/postundefined + $ref: ../code_samples/tsx/admin_draft-orders_{id}/post.tsx - lang: Shell label: cURL source: @@ -129,7 +129,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_draft-orders_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_draft-orders_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items.yaml b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items.yaml index b7b2d4d4d2..801806cd48 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items.yaml @@ -26,7 +26,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_draft-orders_{id}_line-items/postundefined + $ref: ../code_samples/tsx/admin_draft-orders_{id}_line-items/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items_{line_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items_{line_id}.yaml index bcd56ca1f3..caa7d48f0f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items_{line_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_line-items_{line_id}.yaml @@ -34,7 +34,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/postundefined + ../code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/post.tsx - lang: Shell label: cURL source: @@ -95,7 +95,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/deleteundefined + ../code_samples/tsx/admin_draft-orders_{id}_line-items_{line_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_pay.yaml b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_pay.yaml index 5a0c51c8a0..cc7b96fe65 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_pay.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_draft-orders_{id}_pay.yaml @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_draft-orders_{id}_pay/postundefined + $ref: ../code_samples/tsx/admin_draft-orders_{id}_pay/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_gift-cards.yaml b/www/apps/api-reference/specs/admin/paths/admin_gift-cards.yaml index 73f7827f22..c281cba274 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_gift-cards.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_gift-cards.yaml @@ -34,7 +34,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_gift-cards/getundefined + $ref: ../code_samples/tsx/admin_gift-cards/get.tsx - lang: Shell label: cURL source: @@ -86,7 +86,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_gift-cards/postundefined + $ref: ../code_samples/tsx/admin_gift-cards/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_gift-cards_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_gift-cards_{id}.yaml index d99023f74c..a6a5a09fc9 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_gift-cards_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_gift-cards_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_gift-cards_{id}/getundefined + $ref: ../code_samples/tsx/admin_gift-cards_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_gift-cards_{id}/postundefined + $ref: ../code_samples/tsx/admin_gift-cards_{id}/post.tsx - lang: Shell label: cURL source: @@ -129,7 +129,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_gift-cards_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_gift-cards_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_inventory-items.yaml b/www/apps/api-reference/specs/admin/paths/admin_inventory-items.yaml index 80115ee411..61d14b4b88 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_inventory-items.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_inventory-items.yaml @@ -123,7 +123,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_inventory-items/getundefined + $ref: ../code_samples/tsx/admin_inventory-items/get.tsx - lang: Shell label: cURL source: @@ -190,7 +190,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_inventory-items/postundefined + $ref: ../code_samples/tsx/admin_inventory-items/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}.yaml index 035240b1cc..ee6f7efc9b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}.yaml @@ -35,7 +35,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_inventory-items_{id}/getundefined + $ref: ../code_samples/tsx/admin_inventory-items_{id}/get.tsx - lang: Shell label: cURL source: @@ -107,7 +107,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_inventory-items_{id}/postundefined + $ref: ../code_samples/tsx/admin_inventory-items_{id}/post.tsx - lang: Shell label: cURL source: @@ -161,7 +161,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_inventory-items_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_inventory-items_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels.yaml b/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels.yaml index be6e70151f..3c85af2cc7 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels.yaml @@ -47,8 +47,7 @@ get: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_inventory-items_{id}_location-levels/getundefined + $ref: ../code_samples/tsx/admin_inventory-items_{id}_location-levels/get.tsx - lang: Shell label: cURL source: @@ -124,7 +123,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_inventory-items_{id}_location-levels/postundefined + ../code_samples/tsx/admin_inventory-items_{id}_location-levels/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels_{location_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels_{location_id}.yaml index 7ce47e7e20..9e19fd4d02 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels_{location_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_inventory-items_{id}_location-levels_{location_id}.yaml @@ -49,7 +49,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/postundefined + ../code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/post.tsx - lang: Shell label: cURL source: @@ -110,7 +110,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/deleteundefined + ../code_samples/tsx/admin_inventory-items_{id}_location-levels_{location_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_invites_accept.yaml b/www/apps/api-reference/specs/admin/paths/admin_invites_accept.yaml index 347fc4bb99..2bb68b8d72 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_invites_accept.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_invites_accept.yaml @@ -21,7 +21,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_invites_accept/postundefined + $ref: ../code_samples/tsx/admin_invites_accept/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}.yaml index b569761311..ac7b1db6fe 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}.yaml @@ -20,7 +20,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_invites_{invite_id}/deleteundefined + $ref: ../code_samples/tsx/admin_invites_{invite_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}_resend.yaml b/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}_resend.yaml index 6eb360d7af..694616e2c4 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}_resend.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_invites_{invite_id}_resend.yaml @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_invites_{invite_id}_resend/postundefined + $ref: ../code_samples/tsx/admin_invites_{invite_id}_resend/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_notes.yaml b/www/apps/api-reference/specs/admin/paths/admin_notes.yaml index 2593827f27..a992bb570b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_notes.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_notes.yaml @@ -34,7 +34,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_notes/getundefined + $ref: ../code_samples/tsx/admin_notes/get.tsx - lang: Shell label: cURL source: @@ -84,7 +84,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_notes/postundefined + $ref: ../code_samples/tsx/admin_notes/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_notes_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_notes_{id}.yaml index 89cd2ab7ac..cd8dee5841 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_notes_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_notes_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_notes_{id}/getundefined + $ref: ../code_samples/tsx/admin_notes_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_notes_{id}/postundefined + $ref: ../code_samples/tsx/admin_notes_{id}/post.tsx - lang: Shell label: cURL source: @@ -129,7 +129,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_notes_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_notes_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_notifications.yaml b/www/apps/api-reference/specs/admin/paths/admin_notifications.yaml index fceb70a740..c043b0a9c1 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_notifications.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_notifications.yaml @@ -78,7 +78,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_notifications/getundefined + $ref: ../code_samples/tsx/admin_notifications/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_notifications_{id}_resend.yaml b/www/apps/api-reference/specs/admin/paths/admin_notifications_{id}_resend.yaml index bb29184aea..3e382de389 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_notifications_{id}_resend.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_notifications_{id}_resend.yaml @@ -28,7 +28,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_notifications_{id}_resend/postundefined + $ref: ../code_samples/tsx/admin_notifications_{id}_resend/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits.yaml index dc8589a9ff..19a9334f27 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits.yaml @@ -53,7 +53,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits/getundefined + $ref: ../code_samples/tsx/admin_order-edits/get.tsx - lang: Shell label: cURL source: @@ -103,7 +103,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits/postundefined + $ref: ../code_samples/tsx/admin_order-edits/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}.yaml index a6edb0f990..d0c3ca3f2b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}.yaml @@ -35,7 +35,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits_{id}/getundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}/get.tsx - lang: Shell label: cURL source: @@ -92,7 +92,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits_{id}/postundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}/post.tsx - lang: Shell label: cURL source: @@ -146,7 +146,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_cancel.yaml index d5f8a85cfd..fc42019072 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_cancel.yaml @@ -20,7 +20,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits_{id}_cancel/postundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_changes_{change_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_changes_{change_id}.yaml index d0277fa95d..fc15dc544b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_changes_{change_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_changes_{change_id}.yaml @@ -30,7 +30,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_order-edits_{id}_changes_{change_id}/deleteundefined + ../code_samples/tsx/admin_order-edits_{id}_changes_{change_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_confirm.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_confirm.yaml index a7d4432a29..8a2ae80f0b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_confirm.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_confirm.yaml @@ -22,7 +22,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits_{id}_confirm/postundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}_confirm/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items.yaml index e0f88f9263..becb950301 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items.yaml @@ -28,7 +28,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits_{id}_items/postundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}_items/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items_{item_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items_{item_id}.yaml index a4a8a0467b..93679eead3 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items_{item_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_items_{item_id}.yaml @@ -37,8 +37,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_order-edits_{id}_items_{item_id}/postundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}_items_{item_id}/post.tsx - lang: Shell label: cURL source: @@ -100,8 +99,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_order-edits_{id}_items_{item_id}/deleteundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}_items_{item_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_request.yaml b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_request.yaml index f4862c08a2..febe4c4098 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_request.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_order-edits_{id}_request.yaml @@ -23,7 +23,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_order-edits_{id}_request/postundefined + $ref: ../code_samples/tsx/admin_order-edits_{id}_request/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders.yaml index 92dc66dc8b..3244bd35c7 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders.yaml @@ -226,7 +226,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders/getundefined + $ref: ../code_samples/tsx/admin_orders/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}.yaml index f2fcec1303..e7dc8f5f30 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}.yaml @@ -31,7 +31,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}/getundefined + $ref: ../code_samples/tsx/admin_orders_{id}/get.tsx - lang: Shell label: cURL source: @@ -99,7 +99,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}/post.tsx - lang: Shell label: cURL source: 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 534ed11fef..df799a3349 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 @@ -31,7 +31,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_archive/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_archive/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_cancel.yaml index 2667616408..01d027a2aa 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_cancel.yaml @@ -34,7 +34,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_cancel/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_capture.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_capture.yaml index 9230b9ceba..25d0568742 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_capture.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_capture.yaml @@ -33,7 +33,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_capture/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_capture/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims.yaml index bd6d840507..7e042dbdf4 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims.yaml @@ -42,7 +42,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_claims/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_claims/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}.yaml index 107dd50c6d..fba41972fe 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}.yaml @@ -42,7 +42,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_cancel.yaml index da4ef2f48e..b76b555a22 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_cancel.yaml @@ -45,7 +45,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_cancel/postundefined + ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments.yaml index 43b839c0e9..104e29b9f7 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments.yaml @@ -52,7 +52,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments/postundefined + ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel.yaml index bff407f3e4..9e3c2b5bc5 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel.yaml @@ -47,7 +47,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel/postundefined + ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_fulfillments_{fulfillment_id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_shipments.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_shipments.yaml index 0b2960c4c2..41bef37cee 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_shipments.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_claims_{claim_id}_shipments.yaml @@ -51,7 +51,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_shipments/postundefined + ../code_samples/tsx/admin_orders_{id}_claims_{claim_id}_shipments/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_complete.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_complete.yaml index a2332aff18..08a987bb82 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_complete.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_complete.yaml @@ -33,7 +33,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_complete/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_complete/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillment.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillment.yaml index 4dbaee4eb5..d09ab05cec 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillment.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillment.yaml @@ -42,7 +42,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_fulfillment/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_fulfillment/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel.yaml index 0a48f17e02..33db86d4c9 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel.yaml @@ -41,7 +41,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel/postundefined + ../code_samples/tsx/admin_orders_{id}_fulfillments_{fulfillment_id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_refund.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_refund.yaml index a2861f9d61..424a18ee97 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_refund.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_refund.yaml @@ -38,7 +38,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_refund/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_refund/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_return.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_return.yaml index 18964ba718..3c4a04485a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_return.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_return.yaml @@ -41,7 +41,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_return/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_return/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipment.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipment.yaml index 8b6fad6785..ab895f771a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipment.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipment.yaml @@ -42,7 +42,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_shipment/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_shipment/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipping-methods.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipping-methods.yaml index 848d29e111..7af83bc1c5 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipping-methods.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_shipping-methods.yaml @@ -38,7 +38,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_shipping-methods/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_shipping-methods/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps.yaml index 2797c81e50..8dbd5f5d89 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps.yaml @@ -41,7 +41,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_orders_{id}_swaps/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_swaps/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_cancel.yaml index 7196d52a5e..0329a44efd 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_cancel.yaml @@ -41,8 +41,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_cancel/postundefined + $ref: ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments.yaml index 9819e76966..ddbdd23177 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments.yaml @@ -51,7 +51,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments/postundefined + ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel.yaml index 5364c0b0a9..799a798833 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel.yaml @@ -45,7 +45,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel/postundefined + ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_fulfillments_{fulfillment_id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_process-payment.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_process-payment.yaml index a069bf940e..e6fe219307 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_process-payment.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_process-payment.yaml @@ -46,7 +46,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_process-payment/postundefined + ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_process-payment/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_shipments.yaml b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_shipments.yaml index 7165e23c63..2ff1fc3202 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_shipments.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_orders_{id}_swaps_{swap_id}_shipments.yaml @@ -50,7 +50,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_shipments/postundefined + ../code_samples/tsx/admin_orders_{id}_swaps_{swap_id}_shipments/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}.yaml index 9607ba9443..2fa9a1dd1a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}.yaml @@ -35,7 +35,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_payment-collections_{id}/getundefined + $ref: ../code_samples/tsx/admin_payment-collections_{id}/get.tsx - lang: Shell label: cURL source: @@ -92,7 +92,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_payment-collections_{id}/postundefined + $ref: ../code_samples/tsx/admin_payment-collections_{id}/post.tsx - lang: Shell label: cURL source: @@ -146,7 +146,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_payment-collections_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_payment-collections_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}_authorize.yaml b/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}_authorize.yaml index 9c8589aade..0a2ea66422 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}_authorize.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_payment-collections_{id}_authorize.yaml @@ -23,8 +23,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_payment-collections_{id}_authorize/postundefined + $ref: ../code_samples/tsx/admin_payment-collections_{id}_authorize/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_payments_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_payments_{id}.yaml index 4df6652835..5e4970311d 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_payments_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_payments_{id}.yaml @@ -21,7 +21,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_payments_{id}/getundefined + $ref: ../code_samples/tsx/admin_payments_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_capture.yaml b/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_capture.yaml index d2b2b0d931..c85f6e22f4 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_capture.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_capture.yaml @@ -20,7 +20,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_payments_{id}_capture/postundefined + $ref: ../code_samples/tsx/admin_payments_{id}_capture/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_refund.yaml b/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_refund.yaml index 7e2432271f..8cfee91bd0 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_refund.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_payments_{id}_refund.yaml @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_payments_{id}_refund/postundefined + $ref: ../code_samples/tsx/admin_payments_{id}_refund/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_price-lists.yaml b/www/apps/api-reference/specs/admin/paths/admin_price-lists.yaml index 371ca3a602..521e7e2d0b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_price-lists.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_price-lists.yaml @@ -164,7 +164,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_price-lists/getundefined + $ref: ../code_samples/tsx/admin_price-lists/get.tsx - lang: Shell label: cURL source: @@ -214,7 +214,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_price-lists/postundefined + $ref: ../code_samples/tsx/admin_price-lists/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}.yaml index c68178526c..b51a93221e 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_price-lists_{id}/getundefined + $ref: ../code_samples/tsx/admin_price-lists_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_price-lists_{id}/postundefined + $ref: ../code_samples/tsx/admin_price-lists_{id}/post.tsx - lang: Shell label: cURL source: @@ -129,7 +129,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_price-lists_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_price-lists_{id}/delete.tsx - lang: Shell label: cURL source: 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 c56dadfead..f0aa4ca243 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 @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_price-lists_{id}_prices_batch/postundefined + $ref: ../code_samples/tsx/admin_price-lists_{id}_prices_batch/post.tsx - lang: Shell label: cURL source: @@ -83,8 +83,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_price-lists_{id}_prices_batch/deleteundefined + $ref: ../code_samples/tsx/admin_price-lists_{id}_prices_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products.yaml b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products.yaml index 77992018f4..1b957dbaab 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products.yaml @@ -191,7 +191,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_price-lists_{id}_products/getundefined + $ref: ../code_samples/tsx/admin_price-lists_{id}_products/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_prices_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_prices_batch.yaml index e32df4e876..b6517fe03b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_prices_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_prices_batch.yaml @@ -22,7 +22,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_price-lists_{id}_products_prices_batch/deleteundefined + ../code_samples/tsx/admin_price-lists_{id}_products_prices_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_{product_id}_prices.yaml b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_{product_id}_prices.yaml index 940db4d0c5..89253deeb0 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_{product_id}_prices.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_products_{product_id}_prices.yaml @@ -28,7 +28,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_price-lists_{id}_products_{product_id}_prices/deleteundefined + ../code_samples/tsx/admin_price-lists_{id}_products_{product_id}_prices/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_variants_{variant_id}_prices.yaml b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_variants_{variant_id}_prices.yaml index f982472164..e2ec2c1837 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_variants_{variant_id}_prices.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_price-lists_{id}_variants_{variant_id}_prices.yaml @@ -28,7 +28,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_price-lists_{id}_variants_{variant_id}_prices/deleteundefined + ../code_samples/tsx/admin_price-lists_{id}_variants_{variant_id}_prices/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_product-categories.yaml b/www/apps/api-reference/specs/admin/paths/admin_product-categories.yaml index 71e6e1efdd..3b69348c96 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_product-categories.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_product-categories.yaml @@ -79,7 +79,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_product-categories/getundefined + $ref: ../code_samples/tsx/admin_product-categories/get.tsx - lang: Shell label: cURL source: @@ -146,7 +146,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_product-categories/postundefined + $ref: ../code_samples/tsx/admin_product-categories/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}.yaml index 22a166b3e5..89d2f617e0 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}.yaml @@ -36,7 +36,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_product-categories_{id}/getundefined + $ref: ../code_samples/tsx/admin_product-categories_{id}/get.tsx - lang: Shell label: cURL source: @@ -109,7 +109,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_product-categories_{id}/postundefined + $ref: ../code_samples/tsx/admin_product-categories_{id}/post.tsx - lang: Shell label: cURL source: @@ -162,7 +162,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_product-categories_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_product-categories_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}_products_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}_products_batch.yaml index aa72405b59..ff56628e8a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}_products_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_product-categories_{id}_products_batch.yaml @@ -44,7 +44,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_product-categories_{id}_products_batch/postundefined + ../code_samples/tsx/admin_product-categories_{id}_products_batch/post.tsx - lang: Shell label: cURL source: @@ -121,7 +121,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_product-categories_{id}_products_batch/deleteundefined + ../code_samples/tsx/admin_product-categories_{id}_products_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_product-tags.yaml b/www/apps/api-reference/specs/admin/paths/admin_product-tags.yaml index 0d31950ae3..d48e708d2a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_product-tags.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_product-tags.yaml @@ -108,7 +108,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_product-tags/getundefined + $ref: ../code_samples/tsx/admin_product-tags/get.tsx - lang: Shell label: cURL source: 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 f5aec8cd5f..39d754196e 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 @@ -109,7 +109,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_product-types/getundefined + $ref: ../code_samples/tsx/admin_product-types/get.tsx - lang: Shell label: cURL source: 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 cb1a13968c..129116b655 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products.yaml @@ -250,7 +250,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products/getundefined + $ref: ../code_samples/tsx/admin_products/get.tsx - lang: Shell label: cURL source: @@ -302,7 +302,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products/postundefined + $ref: ../code_samples/tsx/admin_products/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_tag-usage.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_tag-usage.yaml index 748e3b4d42..293f2324a4 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_tag-usage.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_tag-usage.yaml @@ -15,7 +15,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products_tag-usage/getundefined + $ref: ../code_samples/tsx/admin_products_tag-usage/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_{id}.yaml index e2a4f359c4..b81c91e549 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products_{id}/getundefined + $ref: ../code_samples/tsx/admin_products_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products_{id}/postundefined + $ref: ../code_samples/tsx/admin_products_{id}/post.tsx - lang: Shell label: cURL source: @@ -129,7 +129,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_products_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options.yaml index 3f0c5dbd05..c44c2876cd 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options.yaml @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products_{id}_options/postundefined + $ref: ../code_samples/tsx/admin_products_{id}_options/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options_{option_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options_{option_id}.yaml index 0e4c51c22c..7997789d60 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options_{option_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_options_{option_id}.yaml @@ -32,8 +32,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_products_{id}_options_{option_id}/postundefined + $ref: ../code_samples/tsx/admin_products_{id}_options_{option_id}/post.tsx - lang: Shell label: cURL source: @@ -94,8 +93,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_products_{id}_options_{option_id}/deleteundefined + $ref: ../code_samples/tsx/admin_products_{id}_options_{option_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants.yaml index e45e2cd64e..8036e87aeb 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants.yaml @@ -107,7 +107,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_products_{id}_variants/postundefined + $ref: ../code_samples/tsx/admin_products_{id}_variants/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_{variant_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_{variant_id}.yaml index 17f92ec34d..03690bd85f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_{variant_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_products_{id}_variants_{variant_id}.yaml @@ -33,8 +33,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_products_{id}_variants_{variant_id}/postundefined + $ref: ../code_samples/tsx/admin_products_{id}_variants_{variant_id}/post.tsx - lang: Shell label: cURL source: @@ -95,7 +94,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_products_{id}_variants_{variant_id}/deleteundefined + ../code_samples/tsx/admin_products_{id}_variants_{variant_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys.yaml b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys.yaml index 99de392329..a104dd9801 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys.yaml @@ -51,7 +51,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_publishable-api-keys/getundefined + $ref: ../code_samples/tsx/admin_publishable-api-keys/get.tsx - lang: Shell label: cURL source: @@ -101,7 +101,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_publishable-api-keys/postundefined + $ref: ../code_samples/tsx/admin_publishable-api-keys/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}.yaml index d8df49a5e1..f59456e4ee 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_publishable-api-keys_{id}/getundefined + $ref: ../code_samples/tsx/admin_publishable-api-keys_{id}/get.tsx - lang: Shell label: cURL source: @@ -78,7 +78,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_publishable-api-keys_{id}/postundefined + $ref: ../code_samples/tsx/admin_publishable-api-keys_{id}/post.tsx - lang: Shell label: cURL source: @@ -132,7 +132,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_publishable-api-keys_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_publishable-api-keys_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_revoke.yaml b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_revoke.yaml index 89f6a19a09..f335595594 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_revoke.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_revoke.yaml @@ -23,8 +23,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_publishable-api-keys_{id}_revoke/postundefined + $ref: ../code_samples/tsx/admin_publishable-api-keys_{id}_revoke/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels.yaml b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels.yaml index 450af1659b..b17be96a7a 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels.yaml @@ -30,7 +30,7 @@ get: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels/getundefined + ../code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels_batch.yaml index 1002e0fa3b..765d78ba7c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_publishable-api-keys_{id}_sales-channels_batch.yaml @@ -28,7 +28,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/postundefined + ../code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/post.tsx - lang: Shell label: cURL source: @@ -92,7 +92,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/deleteundefined + ../code_samples/tsx/admin_publishable-api-keys_{id}_sales-channels_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions.yaml index 45897c8337..bfa341f9ab 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions.yaml @@ -6,6 +6,16 @@ get: `created_at`. The regions can also be paginated. x-authenticated: true parameters: + - in: query + name: q + description: Term used to search regions' name. + schema: + type: string + - in: query + name: order + description: A field to sort-order the retrieved regions by. + schema: + type: string - in: query name: limit schema: @@ -100,7 +110,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_regions/getundefined + $ref: ../code_samples/tsx/admin_regions/get.tsx - lang: Shell label: cURL source: @@ -150,7 +160,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_regions/postundefined + $ref: ../code_samples/tsx/admin_regions/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}.yaml index c1c84271c5..77959ddb8b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_regions_{id}/getundefined + $ref: ../code_samples/tsx/admin_regions_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_regions_{id}/postundefined + $ref: ../code_samples/tsx/admin_regions_{id}/post.tsx - lang: Shell label: cURL source: @@ -131,7 +131,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_regions_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_regions_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries.yaml index 9658422b8e..8ffe359873 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries.yaml @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_regions_{id}_countries/postundefined + $ref: ../code_samples/tsx/admin_regions_{id}_countries/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries_{country_code}.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries_{country_code}.yaml index 0db6225b1e..3edf2e65e3 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries_{country_code}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_countries_{country_code}.yaml @@ -33,7 +33,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_regions_{id}_countries_{country_code}/deleteundefined + ../code_samples/tsx/admin_regions_{id}_countries_{country_code}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-options.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-options.yaml index 0c488fbdda..4a6fe68b25 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-options.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-options.yaml @@ -21,8 +21,7 @@ get: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_regions_{id}_fulfillment-options/getundefined + $ref: ../code_samples/tsx/admin_regions_{id}_fulfillment-options/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers.yaml index 70e61845e6..7b142621e1 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers.yaml @@ -27,8 +27,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_regions_{id}_fulfillment-providers/postundefined + $ref: ../code_samples/tsx/admin_regions_{id}_fulfillment-providers/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers_{provider_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers_{provider_id}.yaml index 7389294d72..4f7cf35cc5 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers_{provider_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_fulfillment-providers_{provider_id}.yaml @@ -30,7 +30,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_regions_{id}_fulfillment-providers_{provider_id}/deleteundefined + ../code_samples/tsx/admin_regions_{id}_fulfillment-providers_{provider_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers.yaml index 24d8840434..fe27ec283f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers.yaml @@ -26,7 +26,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_regions_{id}_payment-providers/postundefined + $ref: ../code_samples/tsx/admin_regions_{id}_payment-providers/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers_{provider_id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers_{provider_id}.yaml index c81f86587e..0131879952 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers_{provider_id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_regions_{id}_payment-providers_{provider_id}.yaml @@ -30,7 +30,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_regions_{id}_payment-providers_{provider_id}/deleteundefined + ../code_samples/tsx/admin_regions_{id}_payment-providers_{provider_id}/delete.tsx - lang: Shell label: cURL source: 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 4ddbe499a9..22ec0261f0 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_reservations.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_reservations.yaml @@ -130,7 +130,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_reservations/getundefined + $ref: ../code_samples/tsx/admin_reservations/get.tsx - lang: Shell label: cURL source: @@ -180,7 +180,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_reservations/postundefined + $ref: ../code_samples/tsx/admin_reservations/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_reservations_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_reservations_{id}.yaml index 4e77892f3e..66eb23944b 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_reservations_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_reservations_{id}.yaml @@ -18,7 +18,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_reservations_{id}/getundefined + $ref: ../code_samples/tsx/admin_reservations_{id}/get.tsx - lang: Shell label: cURL source: @@ -73,7 +73,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_reservations_{id}/postundefined + $ref: ../code_samples/tsx/admin_reservations_{id}/post.tsx - lang: Shell label: cURL source: @@ -127,7 +127,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_reservations_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_reservations_{id}/delete.tsx - lang: Shell label: cURL source: 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 8a6d16ba21..699865186d 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 @@ -13,7 +13,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_return-reasons/getundefined + $ref: ../code_samples/tsx/admin_return-reasons/get.tsx - lang: Shell label: cURL source: @@ -63,7 +63,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_return-reasons/postundefined + $ref: ../code_samples/tsx/admin_return-reasons/post.tsx - lang: Shell label: cURL source: 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 fac2b9ecd2..c3fab4290f 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 @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_return-reasons_{id}/getundefined + $ref: ../code_samples/tsx/admin_return-reasons_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_return-reasons_{id}/postundefined + $ref: ../code_samples/tsx/admin_return-reasons_{id}/post.tsx - lang: Shell label: cURL source: @@ -129,7 +129,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_return-reasons_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_return-reasons_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_returns.yaml b/www/apps/api-reference/specs/admin/paths/admin_returns.yaml index b913041806..b42a66200d 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_returns.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_returns.yaml @@ -26,7 +26,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_returns/getundefined + $ref: ../code_samples/tsx/admin_returns/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_cancel.yaml b/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_cancel.yaml index bdc449a1d4..60377bb750 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_cancel.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_cancel.yaml @@ -21,7 +21,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_returns_{id}_cancel/postundefined + $ref: ../code_samples/tsx/admin_returns_{id}_cancel/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_receive.yaml b/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_receive.yaml index 1c8cc905d2..da69097234 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_receive.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_returns_{id}_receive.yaml @@ -26,7 +26,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_returns_{id}_receive/postundefined + $ref: ../code_samples/tsx/admin_returns_{id}_receive/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_sales-channels.yaml b/www/apps/api-reference/specs/admin/paths/admin_sales-channels.yaml index 1116100c1b..5aeaee384d 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_sales-channels.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_sales-channels.yaml @@ -135,7 +135,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_sales-channels/getundefined + $ref: ../code_samples/tsx/admin_sales-channels/get.tsx - lang: Shell label: cURL source: @@ -185,7 +185,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_sales-channels/postundefined + $ref: ../code_samples/tsx/admin_sales-channels/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}.yaml index 887e5c5923..f8d08b909c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_sales-channels_{id}/getundefined + $ref: ../code_samples/tsx/admin_sales-channels_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_sales-channels_{id}/postundefined + $ref: ../code_samples/tsx/admin_sales-channels_{id}/post.tsx - lang: Shell label: cURL source: @@ -131,7 +131,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_sales-channels_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_sales-channels_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_products_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_products_batch.yaml index aba8b471c3..8c7d65fa3c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_products_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_products_batch.yaml @@ -27,8 +27,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_sales-channels_{id}_products_batch/postundefined + $ref: ../code_samples/tsx/admin_sales-channels_{id}_products_batch/post.tsx - lang: Shell label: cURL source: @@ -91,7 +90,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_sales-channels_{id}_products_batch/deleteundefined + ../code_samples/tsx/admin_sales-channels_{id}_products_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_stock-locations.yaml b/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_stock-locations.yaml index 705d3e33f2..b4e2c2e06f 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_stock-locations.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_sales-channels_{id}_stock-locations.yaml @@ -27,8 +27,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_sales-channels_{id}_stock-locations/postundefined + $ref: ../code_samples/tsx/admin_sales-channels_{id}_stock-locations/post.tsx - lang: Shell label: cURL source: @@ -92,7 +91,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_sales-channels_{id}_stock-locations/deleteundefined + ../code_samples/tsx/admin_sales-channels_{id}_stock-locations/delete.tsx - lang: Shell label: cURL source: 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 b169ff4482..a9c1ad7830 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 @@ -3,24 +3,147 @@ get: summary: List Shipping Options description: >- Retrieve a list of Shipping Options. The shipping options can be filtered by - fields such as `region_id` or `is_return`. + fields such as `region_id` or `is_return`. The shipping options can also be + sorted or paginated. x-authenticated: true parameters: - in: query - name: region_id + name: name + description: Filter by name. + schema: + type: string + - in: query + name: region_id + description: Filter by the ID of the region the shipping options belong to. schema: type: string - description: Filter by a region ID. - in: query name: is_return - description: Filter by whether the shipping option is used for returns or orders. + description: Filter by whether the shipping options are return shipping options. schema: type: boolean - in: query name: admin_only + description: >- + Filter by whether the shipping options are available for admin users + only. schema: type: boolean - description: Filter by whether the shipping option is used only by admins or not. + - in: query + name: q + description: Term used to search shipping options' name. + schema: + type: string + - in: query + name: order + description: A shipping option field to sort-order the retrieved shipping options by. + schema: + type: string + - in: query + name: id + style: form + explode: false + description: Filter by shipping option IDs. + schema: + oneOf: + - type: string + description: ID of the shipping option. + - type: array + items: + type: string + description: ID of a shipping option. + - in: query + name: created_at + description: Filter by a creation date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: updated_at + description: Filter by an update date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: deleted_at + description: Filter by a deletion date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: offset + description: The number of users to skip when retrieving the shipping options. + schema: + type: integer + default: 0 + - in: query + name: limit + description: Limit the number of shipping options returned. + schema: + type: integer + default: 20 + - in: query + name: expand + description: >- + Comma-separated relations that should be expanded in the returned + shipping options. + schema: + type: string + - in: query + name: fields + description: >- + Comma-separated fields that should be included in the returned shipping + options. + schema: + type: string x-codegen: method: list queryParams: AdminGetShippingOptionsParams @@ -32,7 +155,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-options/getundefined + $ref: ../code_samples/tsx/admin_shipping-options/get.tsx - lang: Shell label: cURL source: @@ -82,7 +205,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-options/postundefined + $ref: ../code_samples/tsx/admin_shipping-options/post.tsx - lang: Shell label: cURL source: 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 137746074d..7982c5a43c 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 @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-options_{id}/getundefined + $ref: ../code_samples/tsx/admin_shipping-options_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-options_{id}/postundefined + $ref: ../code_samples/tsx/admin_shipping-options_{id}/post.tsx - lang: Shell label: cURL source: @@ -131,7 +131,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-options_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_shipping-options_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles.yaml b/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles.yaml index 365e742a86..ba35d5e49d 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles.yaml @@ -13,7 +13,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-profiles/getundefined + $ref: ../code_samples/tsx/admin_shipping-profiles/get.tsx - lang: Shell label: cURL source: @@ -63,7 +63,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-profiles/postundefined + $ref: ../code_samples/tsx/admin_shipping-profiles/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles_{id}.yaml index e9a7962dce..d2066e176c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_shipping-profiles_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-profiles_{id}/getundefined + $ref: ../code_samples/tsx/admin_shipping-profiles_{id}/get.tsx - lang: Shell label: cURL source: @@ -76,7 +76,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-profiles_{id}/postundefined + $ref: ../code_samples/tsx/admin_shipping-profiles_{id}/post.tsx - lang: Shell label: cURL source: @@ -128,7 +128,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_shipping-profiles_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_shipping-profiles_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_stock-locations.yaml b/www/apps/api-reference/specs/admin/paths/admin_stock-locations.yaml index 7d2a2e6569..b04a6dd66e 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_stock-locations.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_stock-locations.yaml @@ -127,7 +127,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_stock-locations/getundefined + $ref: ../code_samples/tsx/admin_stock-locations/get.tsx - lang: Shell label: cURL source: @@ -192,7 +192,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_stock-locations/postundefined + $ref: ../code_samples/tsx/admin_stock-locations/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}.yaml index 98666c1c34..86c2e6d617 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_stock-locations_{id}.yaml @@ -35,7 +35,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_stock-locations_{id}/getundefined + $ref: ../code_samples/tsx/admin_stock-locations_{id}/get.tsx - lang: Shell label: cURL source: @@ -94,7 +94,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_stock-locations_{id}/postundefined + $ref: ../code_samples/tsx/admin_stock-locations_{id}/post.tsx - lang: Shell label: cURL source: @@ -144,7 +144,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_stock-locations_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_stock-locations_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_store.yaml b/www/apps/api-reference/specs/admin/paths/admin_store.yaml index 5d1e5d687d..4e6c57fa89 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_store.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_store.yaml @@ -13,7 +13,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_store/getundefined + $ref: ../code_samples/tsx/admin_store/get.tsx - lang: Shell label: cURL source: @@ -63,7 +63,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_store/postundefined + $ref: ../code_samples/tsx/admin_store/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_store_currencies_{code}.yaml b/www/apps/api-reference/specs/admin/paths/admin_store_currencies_{code}.yaml index 81f5aa0901..ab1f5e055d 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_store_currencies_{code}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_store_currencies_{code}.yaml @@ -27,7 +27,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_store_currencies_{code}/postundefined + $ref: ../code_samples/tsx/admin_store_currencies_{code}/post.tsx - lang: Shell label: cURL source: @@ -85,7 +85,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_store_currencies_{code}/deleteundefined + $ref: ../code_samples/tsx/admin_store_currencies_{code}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_store_payment-providers.yaml b/www/apps/api-reference/specs/admin/paths/admin_store_payment-providers.yaml index e2c007f677..5d9018dd67 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_store_payment-providers.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_store_payment-providers.yaml @@ -13,7 +13,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_store_payment-providers/getundefined + $ref: ../code_samples/tsx/admin_store_payment-providers/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_store_tax-providers.yaml b/www/apps/api-reference/specs/admin/paths/admin_store_tax-providers.yaml index bdb7dcf378..d90408c6ab 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_store_tax-providers.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_store_tax-providers.yaml @@ -13,7 +13,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_store_tax-providers/getundefined + $ref: ../code_samples/tsx/admin_store_tax-providers/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_swaps.yaml b/www/apps/api-reference/specs/admin/paths/admin_swaps.yaml index d57352ef85..41cfb9b155 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_swaps.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_swaps.yaml @@ -27,7 +27,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_swaps/getundefined + $ref: ../code_samples/tsx/admin_swaps/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_swaps_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_swaps_{id}.yaml index 50f0751248..20e67289ed 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_swaps_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_swaps_{id}.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_swaps_{id}/getundefined + $ref: ../code_samples/tsx/admin_swaps_{id}/get.tsx - lang: Shell label: cURL source: 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 922db8a48d..0745b309a8 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 @@ -92,7 +92,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_tax-rates/getundefined + $ref: ../code_samples/tsx/admin_tax-rates/get.tsx - lang: Shell label: cURL source: @@ -164,7 +164,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_tax-rates/postundefined + $ref: ../code_samples/tsx/admin_tax-rates/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}.yaml index f11fcb72ee..798f39125c 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}.yaml @@ -41,7 +41,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_tax-rates_{id}/getundefined + $ref: ../code_samples/tsx/admin_tax-rates_{id}/get.tsx - lang: Shell label: cURL source: @@ -119,7 +119,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_tax-rates_{id}/postundefined + $ref: ../code_samples/tsx/admin_tax-rates_{id}/post.tsx - lang: Shell label: cURL source: @@ -173,7 +173,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_tax-rates_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_tax-rates_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_product-types_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_product-types_batch.yaml index 7634a60cd2..a6a7b73e11 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_product-types_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_product-types_batch.yaml @@ -47,8 +47,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_tax-rates_{id}_product-types_batch/postundefined + $ref: ../code_samples/tsx/admin_tax-rates_{id}_product-types_batch/post.tsx - lang: Shell label: cURL source: @@ -131,7 +130,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_tax-rates_{id}_product-types_batch/deleteundefined + ../code_samples/tsx/admin_tax-rates_{id}_product-types_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_products_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_products_batch.yaml index a9c3098d52..d5c460fb81 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_products_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_products_batch.yaml @@ -46,7 +46,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_tax-rates_{id}_products_batch/postundefined + $ref: ../code_samples/tsx/admin_tax-rates_{id}_products_batch/post.tsx - lang: Shell label: cURL source: @@ -127,8 +127,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/admin_tax-rates_{id}_products_batch/deleteundefined + $ref: ../code_samples/tsx/admin_tax-rates_{id}_products_batch/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_shipping-options_batch.yaml b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_shipping-options_batch.yaml index 7b0b6adc5f..5c25dcd132 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_shipping-options_batch.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_tax-rates_{id}_shipping-options_batch.yaml @@ -49,7 +49,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/postundefined + ../code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/post.tsx - lang: Shell label: cURL source: @@ -134,7 +134,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/deleteundefined + ../code_samples/tsx/admin_tax-rates_{id}_shipping-options_batch/delete.tsx - lang: Shell label: cURL source: 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 fc1acb2ccb..5c5b0333fe 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_uploads.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_uploads.yaml @@ -22,7 +22,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_uploads/postundefined + $ref: ../code_samples/tsx/admin_uploads/post.tsx - lang: Shell label: cURL source: @@ -72,7 +72,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_uploads/deleteundefined + $ref: ../code_samples/tsx/admin_uploads/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_uploads_download-url.yaml b/www/apps/api-reference/specs/admin/paths/admin_uploads_download-url.yaml index 9f81ea0af1..3fb82c3f51 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_uploads_download-url.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_uploads_download-url.yaml @@ -18,7 +18,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_uploads_download-url/postundefined + $ref: ../code_samples/tsx/admin_uploads_download-url/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_uploads_protected.yaml b/www/apps/api-reference/specs/admin/paths/admin_uploads_protected.yaml index 190a80b21e..2fd2cd20d7 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_uploads_protected.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_uploads_protected.yaml @@ -22,7 +22,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_uploads_protected/postundefined + $ref: ../code_samples/tsx/admin_uploads_protected/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_users.yaml b/www/apps/api-reference/specs/admin/paths/admin_users.yaml index 72cbef814c..23af6b6cb9 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_users.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_users.yaml @@ -1,10 +1,135 @@ get: operationId: GetUsers summary: List Users - description: Retrieve all admin users. + description: >- + Retrieves a list of users. The users can be filtered by fields such as `q` + or `email`. The users can also be sorted or paginated. x-authenticated: true + parameters: + - in: query + name: email + description: Filter by email. + schema: + type: string + - in: query + name: first_name + description: Filter by first name. + schema: + type: string + - in: query + name: last_name + description: Filter by last name. + schema: + type: string + - in: query + name: q + description: Term used to search users' first name, last name, and email. + schema: + type: string + - in: query + name: order + description: A user field to sort-order the retrieved users by. + schema: + type: string + - in: query + name: id + style: form + explode: false + description: Filter by user IDs. + schema: + oneOf: + - type: string + description: ID of the user. + - type: array + items: + type: string + description: ID of a user. + - in: query + name: created_at + description: Filter by a creation date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: updated_at + description: Filter by an update date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: deleted_at + description: Filter by a deletion date range. + schema: + type: object + properties: + lt: + type: string + description: filter by dates less than this date + format: date + gt: + type: string + description: filter by dates greater than this date + format: date + lte: + type: string + description: filter by dates less than or equal to this date + format: date + gte: + type: string + description: filter by dates greater than or equal to this date + format: date + - in: query + name: offset + description: The number of users to skip when retrieving the users. + schema: + type: integer + default: 0 + - in: query + name: limit + description: Limit the number of users returned. + schema: + type: integer + default: 20 + - in: query + name: fields + description: Comma-separated fields that should be included in the returned users. + schema: + type: string x-codegen: method: list + queryParams: AdminGetUsersParams x-codeSamples: - lang: JavaScript label: JS Client @@ -13,7 +138,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_users/getundefined + $ref: ../code_samples/tsx/admin_users/get.tsx - lang: Shell label: cURL source: @@ -66,7 +191,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_users/postundefined + $ref: ../code_samples/tsx/admin_users/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_users_password-token.yaml b/www/apps/api-reference/specs/admin/paths/admin_users_password-token.yaml index b54eedb45c..48baf75e04 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_users_password-token.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_users_password-token.yaml @@ -29,7 +29,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_users_password-token/postundefined + $ref: ../code_samples/tsx/admin_users_password-token/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_users_reset-password.yaml b/www/apps/api-reference/specs/admin/paths/admin_users_reset-password.yaml index d0c88879df..46e9bebb59 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_users_reset-password.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_users_reset-password.yaml @@ -24,7 +24,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_users_reset-password/postundefined + $ref: ../code_samples/tsx/admin_users_reset-password/post.tsx - lang: Shell label: cURL source: 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 0ce02c73db..04a88d0f85 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 @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_users_{id}/getundefined + $ref: ../code_samples/tsx/admin_users_{id}/get.tsx - lang: Shell label: cURL source: @@ -77,7 +77,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_users_{id}/postundefined + $ref: ../code_samples/tsx/admin_users_{id}/post.tsx - lang: Shell label: cURL source: @@ -131,7 +131,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_users_{id}/deleteundefined + $ref: ../code_samples/tsx/admin_users_{id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_variants.yaml b/www/apps/api-reference/specs/admin/paths/admin_variants.yaml index 5b9958dee5..ee84257124 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_variants.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_variants.yaml @@ -137,7 +137,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_variants/getundefined + $ref: ../code_samples/tsx/admin_variants/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_variants_{id}.yaml b/www/apps/api-reference/specs/admin/paths/admin_variants_{id}.yaml index f18259be5e..373135b647 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_variants_{id}.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_variants_{id}.yaml @@ -35,7 +35,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_variants_{id}/getundefined + $ref: ../code_samples/tsx/admin_variants_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/admin/paths/admin_variants_{id}_inventory.yaml b/www/apps/api-reference/specs/admin/paths/admin_variants_{id}_inventory.yaml index 16ff1dd352..cf22026890 100644 --- a/www/apps/api-reference/specs/admin/paths/admin_variants_{id}_inventory.yaml +++ b/www/apps/api-reference/specs/admin/paths/admin_variants_{id}_inventory.yaml @@ -20,7 +20,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/admin_variants_{id}_inventory/getundefined + $ref: ../code_samples/tsx/admin_variants_{id}_inventory/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_complete/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_complete/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_complete/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_complete/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/deleteundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/deleteundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/delete.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_line-items_{line_id}/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-session/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-session/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-session/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-session/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/deleteundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/delete.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/deleteundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/delete.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}_refresh/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}_refresh/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}_refresh/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}_refresh/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_shipping-methods/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_shipping-methods/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_shipping-methods/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_carts_{id}_shipping-methods/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_collections/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_collections/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_collections/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_collections/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_collections_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_collections_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_collections_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_collections_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_customers/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_customers/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_customers/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_customers/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me_orders/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me_orders/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me_orders/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_customers_me_orders/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_gift-cards_{code}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_gift-cards_{code}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_gift-cards_{code}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_gift-cards_{code}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_complete/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_complete/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_complete/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_complete/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_decline/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_decline/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_decline/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_order-edits_{id}_decline/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_orders/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_orders/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_orders/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_orders/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_batch_customer_token/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_batch_customer_token/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_orders_batch_customer_token/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_orders_batch_customer_token/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_cart_{cart_id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_cart_{cart_id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_orders_cart_{cart_id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_orders_cart_{cart_id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_customer_confirm/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_customer_confirm/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_orders_customer_confirm/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_orders_customer_confirm/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_orders_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_orders_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_orders_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch_authorize/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch_authorize/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch_authorize/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_batch_authorize/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}_authorize/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}_authorize/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}_authorize/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}_authorize/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_product-categories_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_product-tags/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_product-tags/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_product-tags/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_product-tags/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_product-types/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_product-types/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_product-types/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_product-types/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_products/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_products/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_products/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_products/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_products_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_products_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_products_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_products_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_regions/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_regions/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_regions/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_regions/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_regions_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_regions_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_regions_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_regions_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons_{id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons_{id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons_{id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_return-reasons_{id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_returns/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_returns/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_returns/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_returns/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options_{cart_id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options_{cart_id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options_{cart_id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_shipping-options_{cart_id}/get.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_swaps/postundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_swaps/post.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_swaps/postundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_swaps/post.tsx diff --git a/www/apps/api-reference/specs/store/code_samples/tsx/store_swaps_{cart_id}/getundefined b/www/apps/api-reference/specs/store/code_samples/tsx/store_swaps_{cart_id}/get.tsx similarity index 100% rename from www/apps/api-reference/specs/store/code_samples/tsx/store_swaps_{cart_id}/getundefined rename to www/apps/api-reference/specs/store/code_samples/tsx/store_swaps_{cart_id}/get.tsx diff --git a/www/apps/api-reference/specs/store/openapi.full.yaml b/www/apps/api-reference/specs/store/openapi.full.yaml index 0895c27e80..80315b72cf 100644 --- a/www/apps/api-reference/specs/store/openapi.full.yaml +++ b/www/apps/api-reference/specs/store/openapi.full.yaml @@ -5,103 +5,75 @@ info: license: name: MIT url: https://github.com/medusajs/medusa/blob/master/LICENSE +servers: + - url: http://localhost:9000 + - url: https://api.medusa-commerce.com tags: - name: Auth - description: > - Authentication API Routes allow you to manage a customer's session, such - as login or log out. - - You can send authenticated requests for a customer either using the Cookie - header or using the JWT Token. + description: | + Authentication API Routes allow you to manage a customer's session, such as login or log out. + You can send authenticated requests for a customer either using the Cookie header or using the JWT Token. externalDocs: description: How to implement customer profiles in your storefront - url: >- - https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles + url: https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles - name: Carts - description: > - A cart is a virtual shopping bag that customers can use to add items they - want to purchase. - + description: | + A cart is a virtual shopping bag that customers can use to add items they want to purchase. A cart is then used to checkout and place an order. externalDocs: description: How to implement cart functionality in your storefront - url: >- - https://docs.medusajs.com/modules/carts-and-checkout/storefront/implement-cart + url: https://docs.medusajs.com/modules/carts-and-checkout/storefront/implement-cart - name: Customers - description: > - A customer can register and manage their information such as addresses, - orders, payment methods, and more. + description: | + A customer can register and manage their information such as addresses, orders, payment methods, and more. externalDocs: description: How to implement customer profiles in your storefront - url: >- - https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles + url: https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles - name: Gift Cards - description: > - Customers can use gift cards during checkout to deduct the gift card's - balance from the checkout total. - - The Gift Card API Routes allow retrieving a gift card's details by its - code. A gift card can be applied to a cart using the Carts API Routes. + description: | + Customers can use gift cards during checkout to deduct the gift card's balance from the checkout total. + The Gift Card API Routes allow retrieving a gift card's details by its code. A gift card can be applied to a cart using the Carts API Routes. externalDocs: description: How to use gift cards in a storefront url: https://docs.medusajs.com/modules/gift-cards/storefront/use-gift-cards - name: Orders - description: > + description: | Orders are purchases made by customers, typically through a storefront. - - Orders are placed and created using the Carts API Routes. The Orders API - Routes allow retrieving and claiming orders. + Orders are placed and created using the Carts API Routes. The Orders API Routes allow retrieving and claiming orders. externalDocs: description: How to retrieve order details in a storefront - url: >- - https://docs.medusajs.com/modules/orders/storefront/retrieve-order-details + url: https://docs.medusajs.com/modules/orders/storefront/retrieve-order-details - name: Order Edits - description: > - Order edits are changes made to items in an order such as adding, updating - their quantity, or deleting them. Order edits are created by the admin. - - A customer can review order edit requests created by an admin and confirm - or decline them. + description: | + Order edits are changes made to items in an order such as adding, updating their quantity, or deleting them. Order edits are created by the admin. + A customer can review order edit requests created by an admin and confirm or decline them. externalDocs: description: How to handle order edits in a storefront url: https://docs.medusajs.com/modules/orders/storefront/handle-order-edits - name: Payment Collections - description: > - A payment collection is useful for managing additional payments, such as - for Order Edits, or installment payments. + description: | + A payment collection is useful for managing additional payments, such as for Order Edits, or installment payments. - name: Products - description: > - Products are saleable items in a store. This also includes [saleable gift - cards](https://docs.medusajs.com/modules/gift-cards/storefront/use-gift-cards) - in a store. - - Using these API Routes, you can filter products by categories, - collections, sales channels, and more. + description: | + Products are saleable items in a store. This also includes [saleable gift cards](https://docs.medusajs.com/modules/gift-cards/storefront/use-gift-cards) in a store. + Using these API Routes, you can filter products by categories, collections, sales channels, and more. externalDocs: description: How to show products in a storefront url: https://docs.medusajs.com/modules/products/storefront/show-products - name: Product Variants - description: > - Product variants are the actual salable item in your store. Each variant - is a combination of the different option values available on the product. + description: | + Product variants are the actual salable item in your store. Each variant is a combination of the different option values available on the product. - name: Product Categories - description: > - Products can be categoriezed into categories. A product can be associated - more than one category. - - Using these API Routes, you can list or retrieve a category's details and - products. + description: | + Products can be categoriezed into categories. A product can be associated more than one category. + Using these API Routes, you can list or retrieve a category's details and products. externalDocs: description: How to use product categories in a storefront url: https://docs.medusajs.com/modules/products/storefront/use-categories - name: Product Collections - description: > - A product collection is used to organize products for different purposes - such as marketing or discount purposes. For example, you can create a - Summer Collection. - - Using these API Routes, you can list or retrieve a collection's details - and products. + description: | + A product collection is used to organize products for different purposes such as marketing or discount purposes. For example, you can create a Summer Collection. + Using these API Routes, you can list or retrieve a collection's details and products. - name: Product Tags description: | Product tags are string values that can be used to filter products by. @@ -111,16 +83,12 @@ tags: Product types are string values that can be used to filter products by. Products can have more than one tag, and products can share types. - name: Regions - description: > - Regions are different countries or geographical regions that the commerce - store serves customers in. - - Customers can choose what region they're in, which can be used to change - the prices shown based on the region and its currency. + description: | + Regions are different countries or geographical regions that the commerce store serves customers in. + Customers can choose what region they're in, which can be used to change the prices shown based on the region and its currency. externalDocs: description: How to use regions in a storefront - url: >- - https://docs.medusajs.com/modules/regions-and-currencies/storefront/use-regions + url: https://docs.medusajs.com/modules/regions-and-currencies/storefront/use-regions - name: Returns description: | A return can be created by a customer to return items in an order. @@ -128,30 +96,21 @@ tags: description: How to create a return in a storefront url: https://docs.medusajs.com/modules/orders/storefront/create-return - name: Return Reasons - description: > - Return reasons are key-value pairs that are used to specify why an order - return is being created. + description: | + Return reasons are key-value pairs that are used to specify why an order return is being created. - name: Shipping Options - description: > - A shipping option is used to define the available shipping methods during - checkout or when creating a return. + description: | + A shipping option is used to define the available shipping methods during checkout or when creating a return. externalDocs: description: Shipping Option architecture - url: >- - https://docs.medusajs.com/modules/carts-and-checkout/shipping#shipping-option + url: https://docs.medusajs.com/modules/carts-and-checkout/shipping#shipping-option - name: Swaps - description: > - A swap is created by a customer or an admin to exchange an item with a new - one. - - Creating a swap implicitely includes creating a return for the item being - exchanged. + description: | + A swap is created by a customer or an admin to exchange an item with a new one. + Creating a swap implicitely includes creating a return for the item being exchanged. externalDocs: description: How to create a swap in a storefront url: https://docs.medusajs.com/modules/orders/storefront/create-swap -servers: - - url: http://localhost:9000 - - url: https://api.medusa-commerce.com paths: /store/auth: get: @@ -164,16 +123,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.auth.getSession() - .then(({ customer }) => { console.log(customer.id); }) @@ -209,11 +163,7 @@ paths: post: operationId: PostAuth summary: Customer Login - description: >- - Log a customer in and includes the Cookie session in the response - header. The cookie session can be used in subsequent requests to - authenticate the customer. When using Medusa's JS or Medusa React - clients, the cookie is automatically attached to subsequent requests. + description: Log a customer in and includes the Cookie session in the response header. The cookie session can be used in subsequent requests to authenticate the customer. When using Medusa's JS or Medusa React clients, the cookie is automatically attached to subsequent requests. requestBody: content: application/json: @@ -224,17 +174,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.auth.authenticate({ email: "user@example.com", password: "user@example.com" }) - .then(({ customer }) => { console.log(customer.id); }) @@ -278,14 +224,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.auth.deleteSession() - .then(() => { // customer logged out successfully }) @@ -319,9 +261,7 @@ paths: operationId: PostToken summary: Customer Login (JWT) x-authenticated: false - description: >- - After a successful login, a JWT token is returned, which can be used to - send authenticated requests. + description: After a successful login, a JWT token is returned, which can be used to send authenticated requests. requestBody: content: application/json: @@ -332,17 +272,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.auth.getToken({ email: 'user@example.com', password: 'supersecret' }) - .then(({ access_token }) => { console.log(access_token); }) @@ -394,12 +330,9 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.auth.exists("user@example.com") - lang: Shell label: cURL @@ -428,17 +361,11 @@ paths: post: operationId: PostCart summary: Create a Cart - description: > - Create a Cart. Although optional, specifying the cart's region and sales - channel can affect the cart's pricing and + description: | + Create a Cart. Although optional, specifying the cart's region and sales channel can affect the cart's pricing and + the products that can be added to the cart respectively. So, make sure to set those early on and change them if necessary, such as when the customer changes their region. - the products that can be added to the cart respectively. So, make sure - to set those early on and change them if necessary, such as when the - customer changes their region. - - - If a customer is logged in, make sure to pass its ID or email within the - cart's details so that the cart is attached to the customer. + If a customer is logged in, make sure to pass its ID or email within the cart's details so that the cart is attached to the customer. requestBody: content: application/json: @@ -449,14 +376,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.create() - .then(({ cart }) => { console.log(cart.id); }) @@ -528,14 +451,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.retrieve(cartId) - .then(({ cart }) => { console.log(cart.id); }) @@ -596,10 +515,7 @@ paths: post: operationId: PostCartsCart summary: Update a Cart - description: >- - Update a Cart's details. If the cart has payment sessions and the region - was not changed, the payment sessions are updated. The cart's totals are - also recalculated. + description: Update a Cart's details. If the cart has payment sessions and the region was not changed, the payment sessions are updated. The cart's totals are also recalculated. parameters: - in: path name: id @@ -617,16 +533,12 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.update(cartId, { email: "user@example.com" }) - .then(({ cart }) => { console.log(cart.id); }) @@ -690,27 +602,16 @@ paths: post: summary: Complete a Cart operationId: PostCartsCartComplete - description: > - Complete a cart and place an order or create a swap, based on the cart's - type. This includes attempting to authorize the cart's payment. - - If authorizing the payment requires more action, the cart will not be - completed and the order will not be placed or the swap will not be - created. - - - An idempotency key will be generated if none is provided in the header - `Idempotency-Key` and added to - - the response. If an error occurs during cart completion or the request - is interrupted for any reason, the cart completion can be retried by - passing the idempotency + description: | + Complete a cart and place an order or create a swap, based on the cart's type. This includes attempting to authorize the cart's payment. + If authorizing the payment requires more action, the cart will not be completed and the order will not be placed or the swap will not be created. + An idempotency key will be generated if none is provided in the header `Idempotency-Key` and added to + the response. If an error occurs during cart completion or the request is interrupted for any reason, the cart completion can be retried by passing the idempotency key in the `Idempotency-Key` header. externalDocs: description: Cart completion overview - url: >- - https://docs.medusajs.com/modules/carts-and-checkout/cart#cart-completion + url: https://docs.medusajs.com/modules/carts-and-checkout/cart#cart-completion parameters: - in: path name: id @@ -723,14 +624,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.complete(cartId) - .then(({ cart }) => { console.log(cart.id); }) @@ -767,13 +664,7 @@ paths: - Carts responses: '200': - description: >- - If the payment of the cart was successfully authorized, but requires - further action from the customer, the response body will contain the - cart with an updated payment session. Otherwise, if the payment was - authorized and the cart was successfully completed, the response - body will contain either the newly created order or swap, depending - on what the cart was created for. + description: If the payment of the cart was successfully authorized, but requires further action from the customer, the response body will contain the cart with an updated payment session. Otherwise, if the payment was authorized and the cart was successfully completed, the response body will contain either the newly created order or swap, depending on what the cart was created for. content: application/json: schema: @@ -792,11 +683,7 @@ paths: delete: operationId: DeleteCartsCartDiscountsDiscount summary: Remove Discount - description: >- - Remove a Discount from a Cart. This only removes the application of the - discount, and not completely deletes it. The totals will be - re-calculated and the payment sessions will be refreshed after the - removal. + description: Remove a Discount from a Cart. This only removes the application of the discount, and not completely deletes it. The totals will be re-calculated and the payment sessions will be refreshed after the removal. parameters: - in: path name: id @@ -815,14 +702,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.deleteDiscount(cartId, code) - .then(({ cart }) => { console.log(cart.id); }) @@ -853,9 +736,7 @@ paths: post: operationId: PostCartsCartLineItems summary: Add a Line Item - description: >- - Generates a Line Item with a given Product Variant and adds it to the - Cart + description: Generates a Line Item with a given Product Variant and adds it to the Cart parameters: - in: path name: id @@ -873,17 +754,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.lineItems.create(cart_id, { variant_id, quantity: 1 }) - .then(({ cart }) => { console.log(cart.id); }) @@ -974,16 +851,12 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.lineItems.update(cartId, lineId, { quantity: 1 }) - .then(({ cart }) => { console.log(cart.id); }) @@ -1048,9 +921,7 @@ paths: delete: operationId: DeleteCartsCartLineItemsItem summary: Delete a Line Item - description: >- - Delete a Line Item from a Cart. The payment sessions will be updated and - the totals will be recalculated. + description: Delete a Line Item from a Cart. The payment sessions will be updated and the totals will be recalculated. parameters: - in: path name: id @@ -1069,14 +940,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.lineItems.delete(cartId, lineId) - .then(({ cart }) => { console.log(cart.id); }) @@ -1136,10 +1003,7 @@ paths: post: operationId: PostCartsCartPaymentSession summary: Select a Payment Session - description: >- - Select the Payment Session that will be used to complete the cart. This - is typically used when the customer chooses their preferred payment - method during checkout. The totals of the cart will be recalculated. + description: Select the Payment Session that will be used to complete the cart. This is typically used when the customer chooses their preferred payment method during checkout. The totals of the cart will be recalculated. parameters: - in: path name: id @@ -1157,16 +1021,12 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.setPaymentSession(cartId, { provider_id: "manual" }) - .then(({ cart }) => { console.log(cart.id); }) @@ -1230,12 +1090,7 @@ paths: post: operationId: PostCartsCartPaymentSessions summary: Create Payment Sessions - description: >- - Create Payment Sessions for each of the available Payment Providers in - the Cart's Region. If there's only one payment session created, it will - be selected by default. The creation of the payment session uses the - payment provider and may require sending requests to third-party - services. + description: Create Payment Sessions for each of the available Payment Providers in the Cart's Region. If there's only one payment session created, it will be selected by default. The creation of the payment session uses the payment provider and may require sending requests to third-party services. parameters: - in: path name: id @@ -1248,14 +1103,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.createPaymentSessions(cartId) - .then(({ cart }) => { console.log(cart.id); }) @@ -1311,10 +1162,7 @@ paths: post: operationId: PostCartsCartPaymentSessionUpdate summary: Update a Payment Session - description: >- - Update a Payment Session with additional data. This can be useful - depending on the payment provider used. All payment sessions are updated - and cart totals are recalculated afterwards. + description: Update a Payment Session with additional data. This can be useful depending on the payment provider used. All payment sessions are updated and cart totals are recalculated afterwards. parameters: - in: path name: id @@ -1338,18 +1186,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.updatePaymentSession(cartId, "manual", { data: { } }) - .then(({ cart }) => { console.log(cart.id); }) @@ -1386,12 +1230,9 @@ paths: export default Cart - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/store/carts/{id}/payment-sessions/manual' \ - + source: | + curl -X POST '{backend_url}/store/carts/{id}/payment-sessions/manual' \ -H 'Content-Type: application/json' \ - --data-raw '{ "data": {} }' @@ -1417,9 +1258,7 @@ paths: delete: operationId: DeleteCartsCartPaymentSessionsSession summary: Delete a Payment Session - description: >- - Delete a Payment Session in a Cart. May be useful if a payment has - failed. The totals will be recalculated. + description: Delete a Payment Session in a Cart. May be useful if a payment has failed. The totals will be recalculated. parameters: - in: path name: id @@ -1430,9 +1269,7 @@ paths: - in: path name: provider_id required: true - description: >- - The ID of the Payment Provider used to create the Payment Session to - be deleted. + description: The ID of the Payment Provider used to create the Payment Session to be deleted. schema: type: string x-codegen: @@ -1440,14 +1277,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.deletePaymentSession(cartId, "manual") - .then(({ cart }) => { console.log(cart.id); }) @@ -1482,9 +1315,8 @@ paths: export default Cart - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/store/carts/{id}/payment-sessions/{provider_id}' + source: | + curl -X DELETE '{backend_url}/store/carts/{id}/payment-sessions/{provider_id}' tags: - Carts responses: @@ -1508,9 +1340,7 @@ paths: post: operationId: PostCartsCartPaymentSessionsSession summary: Refresh a Payment Session - description: >- - Refresh a Payment Session to ensure that it is in sync with the Cart. - This is usually not necessary, but is provided for edge cases. + description: Refresh a Payment Session to ensure that it is in sync with the Cart. This is usually not necessary, but is provided for edge cases. parameters: - in: path name: id @@ -1521,9 +1351,7 @@ paths: - in: path name: provider_id required: true - description: >- - The ID of the Payment Provider that created the Payment Session to - be refreshed. + description: The ID of the Payment Provider that created the Payment Session to be refreshed. schema: type: string x-codegen: @@ -1531,14 +1359,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.refreshPaymentSession(cartId, "manual") - .then(({ cart }) => { console.log(cart.id); }) @@ -1573,9 +1397,8 @@ paths: export default Cart - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/store/carts/{id}/payment-sessions/{provider_id}/refresh' + source: | + curl -X POST '{backend_url}/store/carts/{id}/payment-sessions/{provider_id}/refresh' tags: - Carts responses: @@ -1599,9 +1422,7 @@ paths: post: operationId: PostCartsCartShippingMethod summary: Add Shipping Method - description: >- - Add a Shipping Method to the Cart. The validation of the `data` field is - handled by the fulfillment provider of the chosen shipping option. + description: Add a Shipping Method to the Cart. The validation of the `data` field is handled by the fulfillment provider of the chosen shipping option. parameters: - in: path name: id @@ -1619,16 +1440,12 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.carts.addShippingMethod(cartId, { option_id }) - .then(({ cart }) => { console.log(cart.id); }) @@ -1692,11 +1509,7 @@ paths: post: operationId: PostCartsCartTaxes summary: Calculate Cart Taxes - description: >- - Calculate the taxes for a cart. This is useful if the `automatic_taxes` - field of the cart's region is set to `false`. If the cart's region uses - a tax provider other than Medusa's system provider, this may lead to - sending requests to third-party services. + description: Calculate the taxes for a cart. This is useful if the `automatic_taxes` field of the cart's region is set to `false`. If the cart's region uses a tax provider other than Medusa's system provider, this may lead to sending requests to third-party services. externalDocs: description: How to calculate taxes manually during checkout url: https://docs.medusajs.com/modules/taxes/storefront/manual-calculation @@ -1737,16 +1550,11 @@ paths: get: operationId: GetCollections summary: List Collections - description: >- - Retrieve a list of product collections. The product collections can be - filtered by fields such as `handle` or `created_at`. The product - collections can also be paginated. + description: Retrieve a list of product collections. The product collections can be filtered by fields such as `handle` or `created_at`. The product collections can also be paginated. parameters: - in: query name: offset - description: >- - The number of product collections to skip when retrieving the - product collections. + description: The number of product collections to skip when retrieving the product collections. schema: type: integer default: 0 @@ -1815,14 +1623,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.collections.list() - .then(({ collections, limit, offset, count }) => { console.log(collections.length); }) @@ -1893,14 +1697,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.collections.retrieve(collectionId) - .then(({ collection }) => { console.log(collection.id); }) @@ -1953,12 +1753,7 @@ paths: post: operationId: PostCustomers summary: Create a Customer - description: >- - Register a new customer. This will also automatically authenticate the - customer and set their login session in the response Cookie header. The - cookie session can be used in subsequent requests to authenticate the - customer. When using Medusa's JS or Medusa React clients, the cookie is - automatically attached to subsequent requests. + description: Register a new customer. This will also automatically authenticate the customer and set their login session in the response Cookie header. The cookie session can be used in subsequent requests to authenticate the customer. When using Medusa's JS or Medusa React clients, the cookie is automatically attached to subsequent requests. requestBody: content: application/json: @@ -1969,19 +1764,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.customers.create({ first_name: "Alec", last_name: "Reynolds", email: "user@example.com", password: "supersecret" }) - .then(({ customer }) => { console.log(customer.id); }) @@ -2060,9 +1851,7 @@ paths: example: code: invalid_request_error type: duplicate_error - message: >- - A customer with the given email already has an account. Log in - instead + message: A customer with the given email already has an account. Log in instead '500': $ref: '#/components/responses/500_error' /store/customers/me: @@ -2076,16 +1865,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.customers.retrieve() - .then(({ customer }) => { console.log(customer.id); }) @@ -2153,18 +1937,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.customers.update({ first_name: "Laury" }) - .then(({ customer }) => { console.log(customer.id); }) @@ -2249,14 +2028,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.customers.addresses.addAddress({ address: { first_name: "Celia", @@ -2270,7 +2045,6 @@ paths: province: "Georgia", } }) - .then(({ customer }) => { console.log(customer.id); }) @@ -2331,38 +2105,28 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/StorePostCustomersCustomerAddressesAddressReq + $ref: '#/components/schemas/StorePostCustomersCustomerAddressesAddressReq' x-codegen: method: updateAddress x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.customers.addresses.updateAddress(addressId, { first_name: "Gina" }) - .then(({ customer }) => { console.log(customer.id); }) - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/store/customers/me/addresses/{address_id}' \ - + source: | + curl -X POST '{backend_url}/store/customers/me/addresses/{address_id}' \ -H 'Authorization: Bearer {access_token}' \ - -H 'Content-Type: application/json' \ - --data-raw '{ "first_name": "Gina" }' @@ -2407,25 +2171,18 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.customers.addresses.deleteAddress(addressId) - .then(({ customer }) => { console.log(customer.id); }) - lang: Shell label: cURL - source: > - curl -X DELETE - '{backend_url}/store/customers/me/addresses/{address_id}' \ - + source: | + curl -X DELETE '{backend_url}/store/customers/me/addresses/{address_id}' \ -H 'Authorization: Bearer {access_token}' security: - cookie_auth: [] @@ -2455,18 +2212,12 @@ paths: get: operationId: GetCustomersCustomerOrders summary: List Orders - description: >- - Retrieve a list of the logged-in Customer's Orders. The orders can be - filtered by fields such as `status` or `fulfillment_status`. The orders - can also be paginated. + description: Retrieve a list of the logged-in Customer's Orders. The orders can be filtered by fields such as `status` or `fulfillment_status`. The orders can also be paginated. x-authenticated: true parameters: - in: query name: q - description: >- - term to search orders' display ID, email, shipping address's first - name, customer's first name, customer's last name, and customer's - phone number. + description: term to search orders' display ID, email, shipping address's first name, customer's first name, customer's last name, and customer's phone number. schema: type: string - in: query @@ -2640,16 +2391,12 @@ paths: default: 0 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - orders. + description: Comma-separated relations that should be expanded in the returned orders. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - orders. + description: Comma-separated fields that should be included in the returned orders. schema: type: string x-codegen: @@ -2658,16 +2405,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.customers.listOrders() - .then(({ orders, limit, offset, count }) => { console.log(orders); }) @@ -2730,12 +2472,7 @@ paths: get: operationId: GetCustomersCustomerPaymentMethods summary: Get Saved Payment Methods - description: >- - Retrieve the logged-in customer's saved payment methods. This API Route - only works with payment providers created with the deprecated Payment - Service interface. The payment methods are saved using the Payment - Service's third-party service, and not on the Medusa backend. So, - they're retrieved from the third-party service. + description: Retrieve the logged-in customer's saved payment methods. This API Route only works with payment providers created with the deprecated Payment Service interface. The payment methods are saved using the Payment Service's third-party service, and not on the Medusa backend. So, they're retrieved from the third-party service. x-authenticated: true deprecated: true x-codegen: @@ -2743,16 +2480,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged - medusa.customers.paymentMethods.list() - .then(({ payment_methods }) => { console.log(payment_methods.length); }) @@ -2789,14 +2521,10 @@ paths: post: operationId: PostCustomersResetPassword summary: Reset Password - description: >- - Reset a Customer's password using a password token created by a previous - request to the Request Password Reset API Route. If the password token - expired, you must create a new one. + description: Reset a Customer's password using a password token created by a previous request to the Request Password Reset API Route. If the password token expired, you must create a new one. externalDocs: description: How to reset password - url: >- - https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles#reset-password + url: https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles#reset-password requestBody: content: application/json: @@ -2807,18 +2535,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.customers.resetPassword({ email: "user@example.com", password: "supersecret", token: "supersecrettoken" }) - .then(({ customer }) => { console.log(customer.id); }) @@ -2857,16 +2581,10 @@ paths: post: operationId: PostCustomersCustomerPasswordToken summary: Request Password Reset - description: >- - Create a reset password token to be used in a subsequent Reset Password - API Route. This emits the event `customer.password_reset`. If a - notification provider is installed in the Medusa backend and is - configured to handle this event, a notification to the customer, such as - an email, may be sent with reset instructions. + description: Create a reset password token to be used in a subsequent Reset Password API Route. This emits the event `customer.password_reset`. If a notification provider is installed in the Medusa backend and is configured to handle this event, a notification to the customer, such as an email, may be sent with reset instructions. externalDocs: description: How to reset password - url: >- - https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles#reset-password + url: https://docs.medusajs.com/modules/customers/storefront/implement-customer-profiles#reset-password requestBody: content: application/json: @@ -2877,20 +2595,15 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.customers.generatePasswordToken({ email: "user@example.com" }) - .then(() => { // successful }) - .catch(() => { // failed }) @@ -2936,14 +2649,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.giftCards.retrieve(code) - .then(({ gift_card }) => { console.log(gift_card.id); }) @@ -3012,14 +2721,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.orderEdits.retrieve(orderEditId) - .then(({ order_edit }) => { console.log(order_edit.id); }) @@ -3080,10 +2785,7 @@ paths: post: operationId: PostOrderEditsOrderEditComplete summary: Complete an Order Edit - description: >- - Complete an Order Edit and reflect its changes on the original order. - Any additional payment required must be authorized first using the - Payment Collection API Routes. + description: Complete an Order Edit and reflect its changes on the original order. Any additional payment required must be authorized first using the Payment Collection API Routes. externalDocs: description: How to handle order edits in a storefront url: https://docs.medusajs.com/modules/orders/storefront/handle-order-edits @@ -3099,14 +2801,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.orderEdits.complete(orderEditId) - .then(({ order_edit }) => { console.log(order_edit.id) }) @@ -3163,9 +2861,7 @@ paths: post: operationId: PostOrderEditsOrderEditDecline summary: Decline an Order Edit - description: >- - Decline an Order Edit. The changes are not reflected on the original - order. + description: Decline an Order Edit. The changes are not reflected on the original order. parameters: - in: path name: id @@ -3183,14 +2879,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.orderEdits.decline(orderEditId) - .then(({ order_edit }) => { console.log(order_edit.id); }) @@ -3249,9 +2941,7 @@ paths: get: operationId: GetOrders summary: Look Up an Order - description: >- - Look up an order using filters. If the filters don't narrow down the - results to a single order, a 404 response is returned with no orders. + description: Look up an order using filters. If the filters don't narrow down the results to a single order, a 404 response is returned with no orders. parameters: - in: query name: display_id @@ -3261,16 +2951,12 @@ paths: type: number - in: query name: fields - description: >- - Comma-separated fields that should be expanded in the returned - order. + description: Comma-separated fields that should be expanded in the returned order. schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - order. + description: Comma-separated relations that should be expanded in the returned order. schema: type: string - in: query @@ -3299,17 +2985,13 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.orders.lookupOrder({ display_id: 1, email: "user@example.com" }) - .then(({ order }) => { console.log(order.id); }) @@ -3348,9 +3030,8 @@ paths: export default Order - lang: Shell label: cURL - source: > - curl - '{backend_url}/store/orders?display_id=1&email=user@example.com' + source: | + curl '{backend_url}/store/orders?display_id=1&email=user@example.com' tags: - Orders responses: @@ -3374,18 +3055,10 @@ paths: post: operationId: PostOrdersCustomerOrderClaim summary: Claim Order - description: >- - Allow the logged-in customer to claim ownership of one or more orders. - This generates a token that can be used later on to verify the claim - using the Verify Order Claim API Route. This also emits the event - `order-update-token.created`. So, if you have a notification provider - installed that handles this event and sends the customer a notification, - such as an email, the customer should receive instructions on how to - finalize their claim ownership. + description: Allow the logged-in customer to claim ownership of one or more orders. This generates a token that can be used later on to verify the claim using the Verify Order Claim API Route. This also emits the event `order-update-token.created`. So, if you have a notification provider installed that handles this event and sends the customer a notification, such as an email, the customer should receive instructions on how to finalize their claim ownership. externalDocs: description: How to implement claim-order flow in a storefront - url: >- - https://docs.medusajs.com/modules/orders/storefront/implement-claim-order + url: https://docs.medusajs.com/modules/orders/storefront/implement-claim-order x-authenticated: true requestBody: content: @@ -3397,22 +3070,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.orders.requestCustomerOrders({ order_ids, }) - .then(() => { // successful }) - .catch(() => { // an error occurred }) @@ -3477,9 +3144,7 @@ paths: get: operationId: GetOrdersOrderCartId summary: Get by Cart ID - description: >- - Retrieve an Order's details by the ID of the Cart that was used to - create the Order. + description: Retrieve an Order's details by the ID of the Cart that was used to create the Order. parameters: - in: path name: cart_id @@ -3492,14 +3157,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.orders.retrieveByCartId(cartId) - .then(({ order }) => { console.log(order.id); }) @@ -3556,13 +3217,10 @@ paths: post: operationId: PostOrdersCustomerOrderClaimsCustomerOrderClaimAccept summary: Verify Order Claim - description: >- - Verify the claim order token provided to the customer when they request - ownership of an order. + description: Verify the claim order token provided to the customer when they request ownership of an order. externalDocs: description: How to implement claim-order flow in a storefront - url: >- - https://docs.medusajs.com/modules/orders/storefront/implement-claim-order + url: https://docs.medusajs.com/modules/orders/storefront/implement-claim-order requestBody: content: application/json: @@ -3573,22 +3231,16 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.orders.confirmRequest( token, ) - .then(() => { // successful }) - .catch(() => { // an error occurred }) @@ -3663,16 +3315,12 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be expanded in the returned - order. + description: Comma-separated fields that should be expanded in the returned order. schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be included in the returned - order. + description: Comma-separated relations that should be included in the returned order. schema: type: string x-codegen: @@ -3680,14 +3328,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.orders.retrieve(orderId) - .then(({ order }) => { console.log(order.id); }) @@ -3755,16 +3399,12 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be expanded in the returned - payment collection. + description: Comma-separated fields that should be expanded in the returned payment collection. schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - payment collection. + description: Comma-separated relations that should be expanded in the returned payment collection. schema: type: string x-codegen: @@ -3773,16 +3413,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.paymentCollections.retrieve(paymentCollectionId) - .then(({ payment_collection }) => { console.log(payment_collection.id) }) @@ -3868,17 +3503,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - - medusa.paymentCollections.managePaymentSession(payment_id, { - provider_id: "stripe" }) - + medusa.paymentCollections.managePaymentSession(payment_id, { provider_id: "stripe" }) .then(({ payment_collection }) => { console.log(payment_collection.id); }) @@ -3917,12 +3546,9 @@ paths: export default PaymentCollection - lang: Shell label: cURL - source: > - curl -X POST '{backend_url}/store/payment-collections/{id}/sessions' - \ - + source: | + curl -X POST '{backend_url}/store/payment-collections/{id}/sessions' \ -H 'Content-Type: application/json' \ - --data-raw '{ "provider_id": "stripe" }' @@ -3954,10 +3580,7 @@ paths: post: operationId: PostPaymentCollectionsPaymentCollectionSessionsBatch summary: Manage Payment Sessions - description: >- - Create, update, or delete a list of payment sessions of a Payment - Collections. If a payment session is not provided in the `sessions` - array, it's deleted. + description: Create, update, or delete a list of payment sessions of a Payment Collections. If a payment session is not provided in the `sessions` array, it's deleted. x-authenticated: false parameters: - in: path @@ -3976,20 +3599,14 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - // Total amount = 10000 - // Example 1: Adding two new sessions - medusa.paymentCollections.managePaymentSessionsBatch(paymentId, { sessions: [ { @@ -4002,14 +3619,11 @@ paths: }, ] }) - .then(({ payment_collection }) => { console.log(payment_collection.id); }) - // Example 2: Updating one session and removing the other - medusa.paymentCollections.managePaymentSessionsBatch(paymentId, { sessions: [ { @@ -4019,7 +3633,6 @@ paths: }, ] }) - .then(({ payment_collection }) => { console.log(payment_collection.id); }) @@ -4083,12 +3696,9 @@ paths: export default PaymentCollection - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/store/payment-collections/{id}/sessions/batch' \ - + source: | + curl -X POST '{backend_url}/store/payment-collections/{id}/sessions/batch' \ -H 'Content-Type: application/json' \ - --data-raw '{ "sessions": [ { @@ -4142,23 +3752,17 @@ paths: content: application/json: schema: - $ref: >- - #/components/schemas/StorePostPaymentCollectionsBatchSessionsAuthorizeReq + $ref: '#/components/schemas/StorePostPaymentCollectionsBatchSessionsAuthorizeReq' x-codegen: method: authorizePaymentSessionsBatch x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.paymentCollections.authorize(paymentId) - .then(({ payment_collection }) => { console.log(payment_collection.id); }) @@ -4196,9 +3800,8 @@ paths: export default PaymentCollection - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/store/payment-collections/{id}/sessions/batch/authorize' + source: | + curl -X POST '{backend_url}/store/payment-collections/{id}/sessions/batch/authorize' security: - cookie_auth: [] - jwt_token: [] @@ -4227,9 +3830,7 @@ paths: post: operationId: PostPaymentCollectionsPaymentCollectionPaymentSessionsSession summary: Refresh a Payment Session - description: >- - Refresh a Payment Session's data to ensure that it is in sync with the - Payment Collection. + description: Refresh a Payment Session's data to ensure that it is in sync with the Payment Collection. x-authenticated: false parameters: - in: path @@ -4249,32 +3850,23 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - - medusa.paymentCollections.refreshPaymentSession(paymentCollectionId, - sessionId) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) + medusa.paymentCollections.refreshPaymentSession(paymentCollectionId, sessionId) .then(({ payment_session }) => { console.log(payment_session.id); }) - lang: tsx label: Medusa React - source: > + source: | import React from "react" - - import { usePaymentCollectionRefreshPaymentSession } from - "medusa-react" - + import { usePaymentCollectionRefreshPaymentSession } from "medusa-react" type Props = { paymentCollectionId: string } - const PaymentCollection = ({ paymentCollectionId }: Props) => { @@ -4294,13 +3886,11 @@ paths: // ... } - export default PaymentCollection - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/store/payment-collections/{id}/sessions/{session_id}' + source: | + curl -X POST '{backend_url}/store/payment-collections/{id}/sessions/{session_id}' security: - cookie_auth: [] - jwt_token: [] @@ -4347,16 +3937,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.paymentCollections.authorize(paymentId, sessionId) - .then(({ payment_collection }) => { console.log(payment_collection.id); }) @@ -4392,9 +3977,8 @@ paths: export default PaymentCollection - lang: Shell label: cURL - source: > - curl -X POST - '{backend_url}/store/payment-collections/{id}/sessions/{session_id}/authorize' + source: | + curl -X POST '{backend_url}/store/payment-collections/{id}/sessions/{session_id}/authorize' security: - cookie_auth: [] - jwt_token: [] @@ -4423,16 +4007,11 @@ paths: get: operationId: GetProductCategories summary: List Product Categories - description: >- - Retrieve a list of product categories. The product categories can be - filtered by fields such as `handle` or `q`. The product categories can - also be paginated. This API Route can also be used to retrieve a product - category by its handle. + description: Retrieve a list of product categories. The product categories can be filtered by fields such as `handle` or `q`. The product categories can also be paginated. This API Route can also be used to retrieve a product category by its handle. x-featureFlag: product_categories externalDocs: description: How to retrieve a product category by its handle - url: >- - https://docs.medusajs.com/modules/products/storefront/use-categories#get-a-category-by-its-handle + url: https://docs.medusajs.com/modules/products/storefront/use-categories#get-a-category-by-its-handle parameters: - in: query name: q @@ -4446,9 +4025,7 @@ paths: type: string - in: query name: parent_category_id - description: >- - Filter by the ID of a parent category. Only children of the provided - parent category are retrieved. + description: Filter by the ID of a parent category. Only children of the provided parent category are retrieved. schema: type: string - in: query @@ -4458,9 +4035,7 @@ paths: type: boolean - in: query name: offset - description: >- - The number of product categories to skip when retrieving the product - categories. + description: The number of product categories to skip when retrieving the product categories. schema: type: integer default: 0 @@ -4472,16 +4047,12 @@ paths: default: 100 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product categories. + description: Comma-separated relations that should be expanded in the returned product categories. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product categories. + description: Comma-separated fields that should be included in the returned product categories. schema: type: string x-codegen: @@ -4490,14 +4061,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.productCategories.list() - .then(({ product_categories, limit, offset, count }) => { console.log(product_categories.length); }) @@ -4578,16 +4145,12 @@ paths: type: string - in: query name: fields - description: >- - Comma-separated fields that should be expanded in the returned - product category. + description: Comma-separated fields that should be expanded in the returned product category. schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product category. + description: Comma-separated relations that should be expanded in the returned product category. schema: type: string x-codegen: @@ -4596,16 +4159,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.productCategories.retrieve(productCategoryId) - .then(({ product_category }) => { console.log(product_category.id); }) @@ -4667,10 +4225,7 @@ paths: get: operationId: GetProductTags summary: List Product Tags - description: >- - Retrieve a list of product tags. The product tags can be filtered by - fields such as `id` or `q`. The product tags can also be sorted or - paginated. + description: Retrieve a list of product tags. The product tags can be filtered by fields such as `id` or `q`. The product tags can also be sorted or paginated. x-authenticated: true x-codegen: method: list @@ -4695,9 +4250,7 @@ paths: type: string - in: query name: discount_condition_id - description: >- - Filter by the ID of a discount condition. When provided, only tags - that the discount condition applies for will be retrieved. + description: Filter by the ID of a discount condition. When provided, only tags that the discount condition applies for will be retrieved. schema: type: string - in: query @@ -4770,14 +4323,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.productTags.list() - .then(({ product_tags }) => { console.log(product_tags.length); }) @@ -4842,10 +4391,7 @@ paths: get: operationId: GetProductTypes summary: List Product Types - description: >- - Retrieve a list of product types. The product types can be filtered by - fields such as `value` or `q`. The product types can also be sorted or - paginated. + description: Retrieve a list of product types. The product types can be filtered by fields such as `value` or `q`. The product types can also be sorted or paginated. x-authenticated: true parameters: - in: query @@ -4856,9 +4402,7 @@ paths: default: 20 - in: query name: offset - description: >- - The number of product types to skip when retrieving the product - types. + description: The number of product types to skip when retrieving the product types. schema: type: integer default: 0 @@ -4869,9 +4413,7 @@ paths: type: string - in: query name: discount_condition_id - description: >- - Filter by the ID of a discount condition. When provided, only types - that the discount condition applies for will be retrieved. + description: Filter by the ID of a discount condition. When provided, only types that the discount condition applies for will be retrieved. schema: type: string - in: query @@ -4947,16 +4489,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.productTypes.list() - .then(({ product_types }) => { console.log(product_types.length); }) @@ -5025,34 +4562,22 @@ paths: get: operationId: GetProducts summary: List Products - description: > - Retrieves a list of products. The products can be filtered by fields - such as `id` or `q`. The products can also be sorted or paginated. - + description: | + Retrieves a list of products. The products can be filtered by fields such as `id` or `q`. The products can also be sorted or paginated. This API Route can also be used to retrieve a product by its handle. - - For accurate and correct pricing of the products based on the customer's - context, it's highly recommended to pass fields such as - + For accurate and correct pricing of the products based on the customer's context, it's highly recommended to pass fields such as `region_id`, `currency_code`, and `cart_id` when available. - - Passing `sales_channel_id` ensures retrieving only products available in - the specified sales channel. - - You can alternatively use a publishable API key in the request header - instead of passing a `sales_channel_id`. + Passing `sales_channel_id` ensures retrieving only products available in the specified sales channel. + You can alternatively use a publishable API key in the request header instead of passing a `sales_channel_id`. externalDocs: description: How to retrieve a product by its handle - url: >- - https://docs.medusajs.com/modules/products/storefront/show-products#retrieve-product-by-handle + url: https://docs.medusajs.com/modules/products/storefront/show-products#retrieve-product-by-handle parameters: - in: query name: q - description: >- - term used to search products' title, description, variant's title, - variant's sku, and collection's title. + description: term used to search products' title, description, variant's title, variant's sku, and collection's title. schema: type: string - in: query @@ -5070,11 +4595,7 @@ paths: name: sales_channel_id style: form explode: false - description: >- - Filter by sales channel IDs. When provided, only products available - in the selected sales channels are retrieved. Alternatively, you can - pass a publishable API key in the request header and this will have - the same effect. + description: Filter by sales channel IDs. When provided, only products available in the selected sales channels are retrieved. Alternatively, you can pass a publishable API key in the request header and this will have the same effect. schema: type: array items: @@ -5083,9 +4604,7 @@ paths: name: collection_id style: form explode: false - description: >- - Filter by product collection IDs. When provided, only products that - belong to the specified product collections are retrieved. + description: Filter by product collection IDs. When provided, only products that belong to the specified product collections are retrieved. schema: type: array items: @@ -5094,9 +4613,7 @@ paths: name: type_id style: form explode: false - description: >- - Filter by product type IDs. When provided, only products that belong - to the specified product types are retrieved. + description: Filter by product type IDs. When provided, only products that belong to the specified product types are retrieved. schema: type: array items: @@ -5105,9 +4622,7 @@ paths: name: tags style: form explode: false - description: >- - Filter by product tag IDs. When provided, only products that belong - to the specified product tags are retrieved. + description: Filter by product tag IDs. When provided, only products that belong to the specified product tags are retrieved. schema: type: array items: @@ -5180,9 +4695,7 @@ paths: name: category_id style: form explode: false - description: >- - Filter by product category IDs. When provided, only products that - belong to the specified product categories are retrieved. + description: Filter by product category IDs. When provided, only products that belong to the specified product categories are retrieved. schema: type: array x-featureFlag: product_categories @@ -5192,9 +4705,7 @@ paths: name: include_category_children style: form explode: false - description: >- - Whether to include child product categories when filtering using the - `category_id` field. + description: Whether to include child product categories when filtering using the `category_id` field. schema: type: boolean x-featureFlag: product_categories @@ -5212,16 +4723,12 @@ paths: default: 100 - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - products. + description: Comma-separated relations that should be expanded in the returned products. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - products. + description: Comma-separated fields that should be included in the returned products. schema: type: string - in: query @@ -5231,25 +4738,19 @@ paths: type: string - in: query name: cart_id - description: >- - The ID of the cart. This is useful for accurate pricing based on the - cart's context. + description: The ID of the cart. This is useful for accurate pricing based on the cart's context. schema: type: string - in: query name: region_id - description: >- - The ID of the region. This is useful for accurate pricing based on - the selected region. + description: The ID of the region. This is useful for accurate pricing based on the selected region. schema: type: string - in: query name: currency_code style: form explode: false - description: >- - A 3 character ISO currency code. This is useful for accurate pricing - based on the selected currency. + description: A 3 character ISO currency code. This is useful for accurate pricing based on the selected currency. schema: type: string externalDocs: @@ -5261,14 +4762,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.products.list() - .then(({ products, limit, offset, count }) => { console.log(products.length); }) @@ -5324,10 +4821,7 @@ paths: post: operationId: PostProductsSearch summary: Search Products - description: >- - Run a search query on products using the search service installed on the - Medusa backend. The searching is handled through the search service, so - the returned data's format depends on the search service you're using. + description: Run a search query on products using the search service installed on the Medusa backend. The searching is handled through the search service, so the returned data's format depends on the search service you're using. requestBody: content: application/json: @@ -5338,16 +4832,12 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.products.search({ q: "Shirt" }) - .then(({ hits }) => { console.log(hits.length); }) @@ -5382,23 +4872,15 @@ paths: get: operationId: GetProductsProduct summary: Get a Product - description: > - Retrieve a Product's details. For accurate and correct pricing of the - product based on the customer's context, it's highly recommended to pass - fields such as - + description: | + Retrieve a Product's details. For accurate and correct pricing of the product based on the customer's context, it's highly recommended to pass fields such as `region_id`, `currency_code`, and `cart_id` when available. - - Passing `sales_channel_id` ensures retrieving only products available in - the current sales channel. - - You can alternatively use a publishable API key in the request header - instead of passing a `sales_channel_id`. + Passing `sales_channel_id` ensures retrieving only products available in the current sales channel. + You can alternatively use a publishable API key in the request header instead of passing a `sales_channel_id`. externalDocs: description: How to pass product pricing parameters - url: >- - https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters + url: https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters parameters: - in: path name: id @@ -5408,46 +4890,34 @@ paths: type: string - in: query name: sales_channel_id - description: >- - The ID of the sales channel the customer is viewing the product - from. + description: The ID of the sales channel the customer is viewing the product from. schema: type: string - in: query name: cart_id - description: >- - The ID of the cart. This is useful for accurate pricing based on the - cart's context. + description: The ID of the cart. This is useful for accurate pricing based on the cart's context. schema: type: string - in: query name: region_id - description: >- - The ID of the region. This is useful for accurate pricing based on - the selected region. + description: The ID of the region. This is useful for accurate pricing based on the selected region. schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product. + description: Comma-separated relations that should be expanded in the returned product. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product. + description: Comma-separated fields that should be included in the returned product. schema: type: string - in: query name: currency_code style: form explode: false - description: >- - A 3 character ISO currency code. This is useful for accurate pricing - based on the selected currency. + description: A 3 character ISO currency code. This is useful for accurate pricing based on the selected currency. schema: type: string externalDocs: @@ -5459,14 +4929,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.products.retrieve(productId) - .then(({ product }) => { console.log(product.id); }) @@ -5519,14 +4985,10 @@ paths: get: operationId: GetRegions summary: List Regions - description: >- - Retrieve a list of regions. The regions can be filtered by fields such - as `created_at`. The regions can also be paginated. This API Route is - useful to show the customer all available regions to choose from. + description: Retrieve a list of regions. The regions can be filtered by fields such as `created_at`. The regions can also be paginated. This API Route is useful to show the customer all available regions to choose from. externalDocs: description: How to use regions in a storefront - url: >- - https://docs.medusajs.com/modules/regions-and-currencies/storefront/use-regions + url: https://docs.medusajs.com/modules/regions-and-currencies/storefront/use-regions parameters: - in: query name: offset @@ -5590,14 +5052,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.regions.list() - .then(({ regions, count, limit, offset }) => { console.log(regions.length); }) @@ -5667,14 +5125,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.regions.retrieve(regionId) - .then(({ region }) => { console.log(region.id); }) @@ -5729,22 +5183,16 @@ paths: get: operationId: GetReturnReasons summary: List Return Reasons - description: >- - Retrieve a list of Return Reasons. This is useful when implementing a - Create Return flow in the storefront. + description: Retrieve a list of Return Reasons. This is useful when implementing a Create Return flow in the storefront. x-codegen: method: list x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.returnReasons.list() - .then(({ return_reasons }) => { console.log(return_reasons.length); }) @@ -5817,14 +5265,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.returnReasons.retrieve(reasonId) - .then(({ return_reason }) => { console.log(return_reason.id); }) @@ -5882,9 +5326,7 @@ paths: post: operationId: PostReturns summary: Create Return - description: >- - Create a Return for an Order. If a return shipping method is specified, - the return is automatically fulfilled. + description: Create a Return for an Order. If a return shipping method is specified, the return is automatically fulfilled. externalDocs: description: How to create a return in a storefront url: https://docs.medusajs.com/modules/orders/storefront/create-return @@ -5898,12 +5340,9 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.returns.create({ order_id, items: [ @@ -5913,7 +5352,6 @@ paths: } ] }) - .then((data) => { console.log(data.return.id); }) @@ -5997,24 +5435,17 @@ paths: parameters: - in: query name: is_return - description: >- - Whether return shipping options should be included. By default, all - shipping options are returned. + description: Whether return shipping options should be included. By default, all shipping options are returned. schema: type: boolean - in: query name: product_ids - description: >- - "Comma-separated list of Product IDs to filter Shipping Options by. - If provided, only shipping options that can be used with the - provided products are retrieved." + description: '"Comma-separated list of Product IDs to filter Shipping Options by. If provided, only shipping options that can be used with the provided products are retrieved."' schema: type: string - in: query name: region_id - description: >- - "The ID of the region that the shipping options belong to. If not - provided, all shipping options are retrieved." + description: '"The ID of the region that the shipping options belong to. If not provided, all shipping options are retrieved."' schema: type: string x-codegen: @@ -6023,14 +5454,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.shippingOptions.list() - .then(({ shipping_options }) => { console.log(shipping_options.length); }) @@ -6094,8 +5521,7 @@ paths: description: Retrieve a list of Shipping Options available for a cart. externalDocs: description: How to implement shipping step in checkout - url: >- - https://docs.medusajs.com/modules/carts-and-checkout/storefront/implement-checkout-flow#shipping-step + url: https://docs.medusajs.com/modules/carts-and-checkout/storefront/implement-checkout-flow#shipping-step parameters: - in: path name: cart_id @@ -6108,14 +5534,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.shippingOptions.listCartOptions(cartId) - .then(({ shipping_options }) => { console.log(shipping_options.length); }) @@ -6182,22 +5604,12 @@ paths: post: operationId: PostSwaps summary: Create a Swap - description: > - Create a Swap for an Order. This will also create a return and associate - it with the swap. If a return shipping option is specified, the return - will automatically be fulfilled. - - To complete the swap, you must use the Complete Cart API Route passing - it the ID of the swap's cart. - - - An idempotency key will be generated if none is provided in the header - `Idempotency-Key` and added to - - the response. If an error occurs during swap creation or the request is - interrupted for any reason, the swap creation can be retried by passing - the idempotency + description: | + Create a Swap for an Order. This will also create a return and associate it with the swap. If a return shipping option is specified, the return will automatically be fulfilled. + To complete the swap, you must use the Complete Cart API Route passing it the ID of the swap's cart. + An idempotency key will be generated if none is provided in the header `Idempotency-Key` and added to + the response. If an error occurs during swap creation or the request is interrupted for any reason, the swap creation can be retried by passing the idempotency key in the `Idempotency-Key` header. externalDocs: description: How to create a swap @@ -6212,12 +5624,9 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.swaps.create({ order_id, return_items: [ @@ -6233,7 +5642,6 @@ paths: } ] }) - .then(({ swap }) => { console.log(swap.id); }) @@ -6338,14 +5746,10 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) medusa.swaps.retrieveByCartId(cartId) - .then(({ swap }) => { console.log(swap.id); }) @@ -6401,42 +5805,28 @@ paths: get: operationId: GetVariants summary: Get Product Variants - description: > - Retrieves a list of product variants. The product variants can be - filtered by fields such as `id` or `title`. The product variants can - also be paginated. - - - For accurate and correct pricing of the product variants based on the - customer's context, it's highly recommended to pass fields such as + description: | + Retrieves a list of product variants. The product variants can be filtered by fields such as `id` or `title`. The product variants can also be paginated. + For accurate and correct pricing of the product variants based on the customer's context, it's highly recommended to pass fields such as `region_id`, `currency_code`, and `cart_id` when available. - - Passing `sales_channel_id` ensures retrieving only variants of products - available in the specified sales channel. - - You can alternatively use a publishable API key in the request header - instead of passing a `sales_channel_id`. + Passing `sales_channel_id` ensures retrieving only variants of products available in the specified sales channel. + You can alternatively use a publishable API key in the request header instead of passing a `sales_channel_id`. externalDocs: description: How to pass product pricing parameters - url: >- - https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters + url: https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters parameters: - in: query name: ids - description: >- - Filter by a comma-separated list of IDs. If supplied, it overrides - the `id` parameter. + description: Filter by a comma-separated list of IDs. If supplied, it overrides the `id` parameter. schema: type: string - in: query name: id style: form explode: false - description: >- - Filter by one or more IDs. If `ids` is supplied, it's overrides the - value of this parameter. + description: Filter by one or more IDs. If `ids` is supplied, it's overrides the value of this parameter. schema: oneOf: - type: string @@ -6447,25 +5837,17 @@ paths: type: string - in: query name: sales_channel_id - description: >- - "Filter by sales channel IDs. When provided, only products available - in the selected sales channels are retrieved. Alternatively, you can - pass a publishable API key in the request header and this will have - the same effect." + description: '"Filter by sales channel IDs. When provided, only products available in the selected sales channels are retrieved. Alternatively, you can pass a publishable API key in the request header and this will have the same effect."' schema: type: string - in: query name: expand - description: >- - Comma-separated relations that should be expanded in the returned - product variants. + description: Comma-separated relations that should be expanded in the returned product variants. schema: type: string - in: query name: fields - description: >- - Comma-separated fields that should be included in the returned - product variants. + description: Comma-separated fields that should be included in the returned product variants. schema: type: string - in: query @@ -6482,25 +5864,19 @@ paths: default: '100' - in: query name: cart_id - description: >- - The ID of the cart. This is useful for accurate pricing based on the - cart's context. + description: The ID of the cart. This is useful for accurate pricing based on the cart's context. schema: type: string - in: query name: region_id - description: >- - The ID of the region. This is useful for accurate pricing based on - the selected region. + description: The ID of the region. This is useful for accurate pricing based on the selected region. schema: type: string - in: query name: currency_code style: form explode: false - description: >- - A 3 character ISO currency code. This is useful for accurate pricing - based on the selected currency. + description: A 3 character ISO currency code. This is useful for accurate pricing based on the selected currency. schema: type: string externalDocs: @@ -6537,30 +5913,21 @@ paths: description: Filter by inventory quantity greater than this number lte: type: number - description: >- - Filter by inventory quantity less than or equal to this - number + description: Filter by inventory quantity less than or equal to this number gte: type: number - description: >- - Filter by inventory quantity greater than or equal to this - number + description: Filter by inventory quantity greater than or equal to this number x-codegen: method: list queryParams: StoreGetVariantsParams x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.product.variants.list() - .then(({ variants }) => { console.log(variants.length); }) @@ -6591,23 +5958,15 @@ paths: get: operationId: GetVariantsVariant summary: Get a Product Variant - description: > - Retrieve a Product Variant's details. For accurate and correct pricing - of the product variant based on the customer's context, it's highly - recommended to pass fields such as - + description: | + Retrieve a Product Variant's details. For accurate and correct pricing of the product variant based on the customer's context, it's highly recommended to pass fields such as `region_id`, `currency_code`, and `cart_id` when available. - - Passing `sales_channel_id` ensures retrieving only variants of products - available in the current sales channel. - - You can alternatively use a publishable API key in the request header - instead of passing a `sales_channel_id`. + Passing `sales_channel_id` ensures retrieving only variants of products available in the current sales channel. + You can alternatively use a publishable API key in the request header instead of passing a `sales_channel_id`. externalDocs: description: How to pass product pricing parameters - url: >- - https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters + url: https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters parameters: - in: path name: id @@ -6617,32 +5976,24 @@ paths: type: string - in: query name: sales_channel_id - description: >- - The ID of the sales channel the customer is viewing the product - variant from. + description: The ID of the sales channel the customer is viewing the product variant from. schema: type: string - in: query name: cart_id - description: >- - The ID of the cart. This is useful for accurate pricing based on the - cart's context. + description: The ID of the cart. This is useful for accurate pricing based on the cart's context. schema: type: string - in: query name: region_id - description: >- - The ID of the region. This is useful for accurate pricing based on - the selected region. + description: The ID of the region. This is useful for accurate pricing based on the selected region. schema: type: string - in: query name: currency_code style: form explode: false - description: >- - A 3 character ISO currency code. This is useful for accurate pricing - based on the selected currency. + description: A 3 character ISO currency code. This is useful for accurate pricing based on the selected currency. schema: type: string externalDocs: @@ -6654,16 +6005,11 @@ paths: x-codeSamples: - lang: JavaScript label: JS Client - source: > + source: | import Medusa from "@medusajs/medusa-js" - - const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: - 3 }) - + const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 }) // must be previously logged in or use api token - medusa.product.variants.retrieve(productVariantId) - .then(({ variant }) => { console.log(variant.id); }) @@ -6710,9 +6056,7 @@ components: $ref: '#/components/schemas/Error' example: code: unknown_error - message: >- - The request conflicted with another request. You may retry the - request with the provided Idempotency-Key. + message: The request conflicted with another request. You may retry the request with the provided Idempotency-Key. type: QueryRunnerAlreadyReleasedError invalid_request_error: description: Invalid Request Error @@ -6793,9 +6137,7 @@ components: multiple_errors: summary: Multiple Errors value: - message: >- - Provided request body contains errors. Please check the data and retry - the request + message: Provided request body contains errors. Please check the data and retry the request errors: - message: first_name must be a string type: invalid_data @@ -6833,74 +6175,44 @@ components: x-displayName: Cookie Session ID in: cookie name: connect.sid - description: > + description: | Use a cookie session to send authenticated requests. - ### How to Obtain the Cookie Session + If you're sending requests through a browser, using JS Client, or using tools like Postman, the cookie session should be automatically set when the customer is logged in. - If you're sending requests through a browser, using JS Client, or using - tools like Postman, the cookie session should be automatically set when - the customer is logged in. - - - If you're sending requests using cURL, you must set the Session ID in - the cookie manually. - - - To do that, send a request to [authenticate the - customer](#tag/Auth/operation/PostAuth) and pass the cURL option `-v`: + If you're sending requests using cURL, you must set the Session ID in the cookie manually. + To do that, send a request to [authenticate the customer](#tag/Auth/operation/PostAuth) and pass the cURL option `-v`: ```bash - curl -v --location --request POST 'https://medusa-url.com/store/auth' \ - --header 'Content-Type: application/json' \ - --data-raw '{ "email": "user@example.com", "password": "supersecret" }' - ``` - - The headers will be logged in the terminal as well as the response. You - should find in the headers a Cookie header similar to this: - + The headers will be logged in the terminal as well as the response. You should find in the headers a Cookie header similar to this: ```bash - - Set-Cookie: - connect.sid=s%3A2Bu8BkaP9JUfHu9rG59G16Ma0QZf6Gj1.WT549XqX37PN8n0OecqnMCq798eLjZC5IT7yiDCBHPM; - + Set-Cookie: connect.sid=s%3A2Bu8BkaP9JUfHu9rG59G16Ma0QZf6Gj1.WT549XqX37PN8n0OecqnMCq798eLjZC5IT7yiDCBHPM; ``` - - Copy the value after `connect.sid` (without the `;` at the end) and pass - it as a cookie in subsequent requests as the following: - + Copy the value after `connect.sid` (without the `;` at the end) and pass it as a cookie in subsequent requests as the following: ```bash - - curl --location --request GET - 'https://medusa-url.com/store/customers/me/orders' \ - + curl --location --request GET 'https://medusa-url.com/store/customers/me/orders' \ --header 'Cookie: connect.sid={sid}' - ``` - Where `{sid}` is the value of `connect.sid` that you copied. schemas: Address: title: Address - description: >- - An address is used across the Medusa backend within other schemas and - object types. For example, a customer's billing and shipping addresses - both use the Address entity. + description: An address is used across the Medusa backend within other schemas and object types. For example, a customer's billing and shipping addresses both use the Address entity. type: object required: - address_1 @@ -6968,8 +6280,7 @@ components: nullable: true type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. example: st country: @@ -7012,11 +6323,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute AddressCreatePayload: type: object description: Address fields used when creating an address. @@ -7058,8 +6366,7 @@ components: description: The 2 character ISO code of the country in lower case type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. example: st province: @@ -7110,8 +6417,7 @@ components: description: The 2 character ISO code of the country in lower case type: string externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. example: st province: @@ -7129,9 +6435,7 @@ components: description: An optional key-value map with additional details BatchJob: title: Batch Job - description: >- - A Batch Job indicates an asynchronus task stored in the Medusa backend. - Its status determines whether it has been executed or not. + description: A Batch Job indicates an asynchronus task stored in the Medusa backend. Its status determines whether it has been executed or not. type: object required: - canceled_at @@ -7184,9 +6488,7 @@ components: nullable: true $ref: '#/components/schemas/User' context: - description: >- - The context of the batch job, the type of the batch job determines - what the context should contain. + description: The context of the batch job, the type of the batch job determines what the context should contain. nullable: true type: object example: @@ -7301,9 +6603,7 @@ components: format: date-time Cart: title: Cart - description: >- - A cart represents a virtual shopping bag. It can be used to complete an - order, a swap, or a claim. + description: A cart represents a virtual shopping bag. It can be used to complete an order, a swap, or a claim. type: object required: - billing_address_id @@ -7438,18 +6738,14 @@ components: type: string format: date-time idempotency_key: - description: >- - Randomly generated key used to continue the completion of a cart in - case of failure. + description: Randomly generated key used to continue the completion of a cart in case of failure. nullable: true type: string externalDocs: url: https://docs.medusajs.com/development/idempotency-key/overview.md description: Learn more how to use the idempotency key. context: - description: >- - The context of the cart which can include info like IP or user - agent. + description: The context of the cart which can include info like IP or user agent. nullable: true type: object example: @@ -7485,11 +6781,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute shipping_total: description: The total of shipping type: integer @@ -7515,9 +6808,7 @@ components: type: integer example: 0 refunded_total: - description: >- - The total amount refunded if the order associated with this cart is - returned. + description: The total amount refunded if the order associated with this cart is returned. type: integer example: 0 total: @@ -7596,16 +6887,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ClaimItem: title: Claim Item - description: >- - A claim item is an item created as part of a claim. It references an - item in the order that should be exchanged or refunded. + description: A claim item is an item created as part of a claim. It references an item in the order that should be exchanged or refunded. type: object required: - claim_order_id @@ -7643,9 +6929,7 @@ components: type: string example: item_01G8ZM25TN49YV9EQBE2NC27KC item: - description: >- - The details of the line item in the original order that this claim - item refers to. + description: The details of the line item in the original order that this claim item refers to. x-expandable: item nullable: true $ref: '#/components/schemas/LineItem' @@ -7654,9 +6938,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 variant: - description: >- - The details of the product variant to potentially replace the item - in the original order. + description: The details of the product variant to potentially replace the item in the original order. x-expandable: variant nullable: true $ref: '#/components/schemas/ProductVariant' @@ -7674,9 +6956,7 @@ components: type: string example: I don't like it. quantity: - description: >- - The quantity of the item that is being claimed; must be less than or - equal to the amount purchased in the original order. + description: The quantity of the item that is being claimed; must be less than or equal to the amount purchased in the original order. type: integer example: 1 tags: @@ -7705,18 +6985,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ClaimOrder: title: Claim - description: >- - A Claim represents a group of faulty or missing items. It consists of - claim items that refer to items in the original order that should be - replaced or refunded. It also includes details related to shipping and - fulfillment. + description: A Claim represents a group of faulty or missing items. It consists of claim items that refer to items in the original order that should be replaced or refunded. It also includes details related to shipping and fulfillment. type: object required: - canceled_at @@ -7773,9 +7046,7 @@ components: items: $ref: '#/components/schemas/ClaimItem' additional_items: - description: >- - The details of the new items to be shipped when the claim's type is - `replace` + description: The details of the new items to be shipped when the claim's type is `replace` type: array x-expandable: additional_items items: @@ -7790,9 +7061,7 @@ components: nullable: true type: object return_order: - description: >- - The details of the return associated with the claim if the claim's - type is `replace`. + description: The details of the return associated with the claim if the claim's type is `replace`. x-expandable: return_order nullable: true type: object @@ -7807,9 +7076,7 @@ components: nullable: true $ref: '#/components/schemas/Address' shipping_methods: - description: >- - The details of the shipping methods that the claim order will be - shipped with. + description: The details of the shipping methods that the claim order will be shipped with. type: array x-expandable: shipping_methods items: @@ -7850,22 +7117,15 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute no_notification: - description: >- - Flag for describing whether or not notifications related to this - should be send. + description: Flag for describing whether or not notifications related to this should be send. nullable: true type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the cart - associated with the claim in case of failure. + description: Randomly generated key used to continue the completion of the cart associated with the claim in case of failure. nullable: true type: string externalDocs: @@ -7873,9 +7133,7 @@ components: description: Learn more how to use the idempotency key. ClaimTag: title: Claim Tag - description: >- - Claim Tags are user defined tags that can be assigned to claim items for - easy filtering and grouping. + description: Claim Tags are user defined tags that can be assigned to claim items for easy filtering and grouping. type: object required: - created_at @@ -7913,11 +7171,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Country: title: Country description: Country details @@ -7940,24 +7195,21 @@ components: type: string example: it externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. iso_3: description: The 2 character ISO code of the country in lower case type: string example: ita externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3#Officially_assigned_code_elements description: See a list of codes. num_code: description: The numerical ISO code for the country. type: string example: 380 externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_numeric#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_numeric#Officially_assigned_code_elements description: See a list of codes. name: description: The normalized country name in upper case. @@ -8036,10 +7288,7 @@ components: default: false CustomShippingOption: title: Custom Shipping Option - description: >- - Custom Shipping Options are overridden Shipping Options. Admins can - attach a Custom Shipping Option to a cart in order to set a custom price - for a particular Shipping Option. + description: Custom Shipping Options are overridden Shipping Options. Admins can attach a Custom Shipping Option to a cart in order to set a custom price for a particular Shipping Option. type: object required: - cart_id @@ -8056,15 +7305,11 @@ components: type: string example: cso_01G8X99XNB77DMFBJFWX6DN9V9 price: - description: >- - The custom price set that will override the shipping option's - original price + description: The custom price set that will override the shipping option's original price type: integer example: 1000 shipping_option_id: - description: >- - The ID of the Shipping Option that the custom shipping option - overrides + description: The ID of the Shipping Option that the custom shipping option overrides type: string example: so_01G1G5V27GYX4QXNARRQCW1N8T shipping_option: @@ -8102,11 +7347,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Customer: title: Customer description: A customer can make purchases in your store and manage their profile. @@ -8199,16 +7441,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute CustomerGroup: title: Customer Group - description: >- - A customer group that can be used to organize customers into groups of - similar traits. + description: A customer group that can be used to organize customers into groups of similar traits. type: object required: - created_at @@ -8258,11 +7495,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Discount: title: Discount description: A discount can be applied to a cart for promotional purposes. @@ -8289,48 +7523,34 @@ components: type: string example: disc_01F0YESMW10MGHWJKZSDDMN0VN code: - description: >- - A unique code for the discount - this will be used by the customer - to apply the discount + description: A unique code for the discount - this will be used by the customer to apply the discount type: string example: 10DISC is_dynamic: - description: >- - A flag to indicate if multiple instances of the discount can be - generated. I.e. for newsletter discounts + description: A flag to indicate if multiple instances of the discount can be generated. I.e. for newsletter discounts type: boolean example: false rule_id: - description: >- - The ID of the discount rule that defines how the discount will be - applied to a cart. + description: The ID of the discount rule that defines how the discount will be applied to a cart. nullable: true type: string example: dru_01F0YESMVK96HVX7N419E3CJ7C rule: - description: >- - The details of the discount rule that defines how the discount will - be applied to a cart.. + description: The details of the discount rule that defines how the discount will be applied to a cart.. x-expandable: rule nullable: true $ref: '#/components/schemas/DiscountRule' is_disabled: - description: >- - Whether the Discount has been disabled. Disabled discounts cannot be - applied to carts + description: Whether the Discount has been disabled. Disabled discounts cannot be applied to carts type: boolean example: false parent_discount_id: - description: >- - The Discount that the discount was created from. This will always be - a dynamic discount + description: The Discount that the discount was created from. This will always be a dynamic discount nullable: true type: string example: disc_01G8ZH853YPY9B94857DY91YGW parent_discount: - description: >- - The details of the parent discount that this discount was created - from. + description: The details of the parent discount that this discount was created from. x-expandable: parent_discount nullable: true type: object @@ -8384,11 +7604,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountCondition: title: Discount Condition description: Holds rule conditions for when a discount is applicable @@ -8408,12 +7625,7 @@ components: type: string example: discon_01G8X9A7ESKAJXG2H0E6F1MW7A type: - description: >- - The type of the condition. The type affects the available resources - associated with the condition. For example, if the type is - `products`, that means the `products` relation will hold the - products associated with this condition and other relations will be - empty. + description: The type of the condition. The type affects the available resources associated with the condition. For example, if the type is `products`, that means the `products` relation will hold the products associated with this condition and other relations will be empty. type: string enum: - products @@ -8422,11 +7634,7 @@ components: - product_tags - customer_groups operator: - description: >- - The operator of the condition. `in` indicates that discountable - resources are within the specified resources. `not_in` indicates - that discountable resources are everything but the specified - resources. + description: The operator of the condition. `in` indicates that discountable resources are within the specified resources. `not_in` indicates that discountable resources are everything but the specified resources. type: string enum: - in @@ -8447,33 +7655,25 @@ components: items: $ref: '#/components/schemas/Product' product_types: - description: >- - Product types associated with this condition if `type` is - `product_types`. + description: Product types associated with this condition if `type` is `product_types`. type: array x-expandable: product_types items: $ref: '#/components/schemas/ProductType' product_tags: - description: >- - Product tags associated with this condition if `type` is - `product_tags`. + description: Product tags associated with this condition if `type` is `product_tags`. type: array x-expandable: product_tags items: $ref: '#/components/schemas/ProductTag' product_collections: - description: >- - Product collections associated with this condition if `type` is - `product_collections`. + description: Product collections associated with this condition if `type` is `product_collections`. type: array x-expandable: product_collections items: $ref: '#/components/schemas/ProductCollection' customer_groups: - description: >- - Customer groups associated with this condition if `type` is - `customer_groups`. + description: Customer groups associated with this condition if `type` is `customer_groups`. type: array x-expandable: customer_groups items: @@ -8498,11 +7698,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionCustomerGroup: title: Product Tag Discount Condition description: Associates a discount condition with a customer group @@ -8545,16 +7742,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProduct: title: Product Discount Condition - description: >- - This represents the association between a discount condition and a - product + description: This represents the association between a discount condition and a product type: object required: - condition_id @@ -8596,16 +7788,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProductCollection: title: Product Collection Discount Condition - description: >- - This represents the association between a discount condition and a - product collection + description: This represents the association between a discount condition and a product collection type: object required: - condition_id @@ -8647,16 +7834,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProductTag: title: Product Tag Discount Condition - description: >- - This represents the association between a discount condition and a - product tag + description: This represents the association between a discount condition and a product tag type: object required: - condition_id @@ -8698,16 +7880,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountConditionProductType: title: Product Type Discount Condition - description: >- - This represents the association between a discount condition and a - product type + description: This represents the association between a discount condition and a product type type: object required: - condition_id @@ -8749,16 +7926,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DiscountRule: title: Discount Rule - description: >- - A discount rule defines how a Discount is calculated when applied to a - Cart. + description: A discount rule defines how a Discount is calculated when applied to a Cart. type: object required: - allocation @@ -8776,10 +7948,7 @@ components: type: string example: dru_01F0YESMVK96HVX7N419E3CJ7C type: - description: >- - The type of the Discount, can be `fixed` for discounts that reduce - the price by a fixed amount, `percentage` for percentage reductions - or `free_shipping` for shipping vouchers. + description: The type of the Discount, can be `fixed` for discounts that reduce the price by a fixed amount, `percentage` for percentage reductions or `free_shipping` for shipping vouchers. type: string enum: - fixed @@ -8792,9 +7961,7 @@ components: type: string example: 10 Percent value: - description: >- - The value that the discount represents; this will depend on the type - of the discount + description: The value that the discount represents; this will depend on the type of the discount type: integer example: 10 allocation: @@ -8806,9 +7973,7 @@ components: - item example: total conditions: - description: >- - The details of the discount conditions associated with the rule. - They can be used to limit when the discount can be used. + description: The details of the discount conditions associated with the rule. They can be used to limit when the discount can be used. type: array x-expandable: conditions items: @@ -8833,17 +7998,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute DraftOrder: title: DraftOrder - description: >- - A draft order is created by an admin without direct involvement of the - customer. Once its payment is marked as captured, it is transformed into - an order. + description: A draft order is created by an admin without direct involvement of the customer. Once its payment is marked as captured, it is transformed into an order. type: object required: - canceled_at @@ -8864,9 +8023,7 @@ components: type: string example: dorder_01G8TJFKBG38YYFQ035MSVG03C status: - description: >- - The status of the draft order. It's changed to `completed` when it's - transformed to an order. + description: The status of the draft order. It's changed to `completed` when it's transformed to an order. type: string enum: - open @@ -8887,16 +8044,12 @@ components: nullable: true type: object order_id: - description: >- - The ID of the order created from the draft order when its payment is - captured. + description: The ID of the order created from the draft order when its payment is captured. nullable: true type: string example: order_01G8TJSYT9M6AVS5N4EMNFS1EK order: - description: >- - The details of the order created from the draft order when its - payment is captured. + description: The details of the order created from the draft order when its payment is captured. x-expandable: order nullable: true type: object @@ -8916,9 +8069,7 @@ components: type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the cart - associated with the draft order in case of failure. + description: Randomly generated key used to continue the completion of the cart associated with the draft order in case of failure. nullable: true type: string externalDocs: @@ -8939,11 +8090,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Error: title: Response Error type: object @@ -9016,12 +8164,7 @@ components: type: boolean Fulfillment: title: Fulfillment - description: >- - A Fulfillment is created once an admin can prepare the purchased goods. - Fulfillments will eventually be shipped and hold information about how - to track shipments. Fulfillments are created through a fulfillment - provider, which typically integrates a third-party shipping service. - Fulfillments can be associated with orders, claims, swaps, and returns. + description: A Fulfillment is created once an admin can prepare the purchased goods. Fulfillments will eventually be shipped and hold information about how to track shipments. Fulfillments are created through a fulfillment provider, which typically integrates a third-party shipping service. Fulfillments can be associated with orders, claims, swaps, and returns. type: object required: - canceled_at @@ -9075,15 +8218,11 @@ components: nullable: true type: object provider_id: - description: >- - The ID of the Fulfillment Provider responsible for handling the - fulfillment. + description: The ID of the Fulfillment Provider responsible for handling the fulfillment. type: string example: manual provider: - description: >- - The details of the fulfillment provider responsible for handling the - fulfillment. + description: The details of the fulfillment provider responsible for handling the fulfillment. x-expandable: provider nullable: true $ref: '#/components/schemas/FulfillmentProvider' @@ -9093,34 +8232,25 @@ components: type: string example: sloc_01G8TJSYT9M6AVS5N4EMNFS1EK items: - description: >- - The Fulfillment Items in the Fulfillment. These hold information - about how many of each Line Item has been fulfilled. + description: The Fulfillment Items in the Fulfillment. These hold information about how many of each Line Item has been fulfilled. type: array x-expandable: items items: $ref: '#/components/schemas/FulfillmentItem' tracking_links: - description: >- - The Tracking Links that can be used to track the status of the - Fulfillment. These will usually be provided by the Fulfillment - Provider. + description: The Tracking Links that can be used to track the status of the Fulfillment. These will usually be provided by the Fulfillment Provider. type: array x-expandable: tracking_links items: $ref: '#/components/schemas/TrackingLink' tracking_numbers: - description: >- - The tracking numbers that can be used to track the status of the - fulfillment. + description: The tracking numbers that can be used to track the status of the fulfillment. deprecated: true type: array items: type: string data: - description: >- - This contains all the data necessary for the Fulfillment provider to - handle the fulfillment. + description: This contains all the data necessary for the Fulfillment provider to handle the fulfillment. type: object example: {} shipped_at: @@ -9129,9 +8259,7 @@ components: type: string format: date-time no_notification: - description: >- - Flag for describing whether or not notifications related to this - should be sent. + description: Flag for describing whether or not notifications related to this should be sent. nullable: true type: boolean example: false @@ -9141,9 +8269,7 @@ components: type: string format: date-time idempotency_key: - description: >- - Randomly generated key used to continue the completion of the - fulfillment in case of failure. + description: Randomly generated key used to continue the completion of the fulfillment in case of failure. nullable: true type: string externalDocs: @@ -9164,11 +8290,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute FulfillmentItem: title: Fulfillment Item description: This represents the association between a Line Item and a Fulfillment. @@ -9202,33 +8325,23 @@ components: example: 1 FulfillmentProvider: title: Fulfillment Provider - description: >- - A fulfillment provider represents a fulfillment service installed in the - Medusa backend, either through a plugin or backend customizations. It - holds the fulfillment service's installation status. + description: A fulfillment provider represents a fulfillment service installed in the Medusa backend, either through a plugin or backend customizations. It holds the fulfillment service's installation status. type: object required: - id - is_installed properties: id: - description: >- - The ID of the fulfillment provider as given by the fulfillment - service. + description: The ID of the fulfillment provider as given by the fulfillment service. type: string example: manual is_installed: - description: >- - Whether the fulfillment service is installed in the current version. - If a fulfillment service is no longer installed, the `is_installed` - attribute is set to `false`. + description: Whether the fulfillment service is installed in the current version. If a fulfillment service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true GiftCard: title: Gift Card - description: >- - Gift Cards are redeemable and represent a value that can be used towards - the payment of an Order. + description: Gift Cards are redeemable and represent a value that can be used towards the payment of an Order. type: object required: - balance @@ -9250,9 +8363,7 @@ components: type: string example: gift_01G8XKBPBQY2R7RBET4J7E0XQZ code: - description: >- - The unique code that identifies the Gift Card. This is used by the - Customer to redeem the value of the Gift Card. + description: The unique code that identifies the Gift Card. This is used by the Customer to redeem the value of the Gift Card. type: string example: 3RFT-MH2C-Y4YZ-XMN4 value: @@ -9283,9 +8394,7 @@ components: nullable: true type: object is_disabled: - description: >- - Whether the Gift Card has been disabled. Disabled Gift Cards cannot - be applied to carts. + description: Whether the Gift Card has been disabled. Disabled Gift Cards cannot be applied to carts. type: boolean default: false ends_at: @@ -9318,16 +8427,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute GiftCardTransaction: title: Gift Card Transaction - description: >- - Gift Card Transactions are created once a Customer uses a Gift Card to - pay for their Order. + description: Gift Card Transactions are created once a Customer uses a Gift Card to pay for their Order. type: object required: - amount @@ -9380,9 +8484,7 @@ components: example: 0 IdempotencyKey: title: Idempotency Key - description: >- - Idempotency Key is used to continue a process in case of any failure - that might occur. + description: Idempotency Key is used to continue a process in case of any failure that might occur. type: object required: - created_at @@ -9401,9 +8503,7 @@ components: type: string example: ikey_01G8X9A7ESKAJXG2H0E6F1MW7A idempotency_key: - description: >- - The unique randomly generated key used to determine the state of a - process. + description: The unique randomly generated key used to determine the state of a process. type: string externalDocs: url: https://docs.medusajs.com/development/idempotency-key/overview.md @@ -9450,10 +8550,7 @@ components: default: started Image: title: Image - description: >- - An Image is used to store details about uploaded images. Images are - uploaded by the File Service, and the URL is provided by the File - Service. + description: An Image is used to store details about uploaded images. Images are uploaded by the File Service, and the URL is provided by the File Service. type: object required: - created_at @@ -9491,11 +8588,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute InventoryItemDTO: type: object required: @@ -9509,22 +8603,13 @@ components: description: The Stock Keeping Unit (SKU) code of the Inventory Item. type: string hs_code: - description: >- - The Harmonized System code of the Inventory Item. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string origin_country: - description: >- - The country in which the Inventory Item was produced. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Inventory Item was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Inventory Item. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Inventory Item. May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string title: description: Title of the inventory item @@ -9536,30 +8621,19 @@ components: description: Thumbnail for the inventory item type: string material: - description: >- - The material and composition that the Inventory Item is made of, May - be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Inventory Item is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. type: string weight: - description: >- - The weight of the Inventory Item. May be used in shipping rate - calculations. + description: The weight of the Inventory Item. May be used in shipping rate calculations. type: number height: - description: >- - The height of the Inventory Item. May be used in shipping rate - calculations. + description: The height of the Inventory Item. May be used in shipping rate calculations. type: number width: - description: >- - The width of the Inventory Item. May be used in shipping rate - calculations. + description: The width of the Inventory Item. May be used in shipping rate calculations. type: number length: - description: >- - The length of the Inventory Item. May be used in shipping rate - calculations. + description: The length of the Inventory Item. May be used in shipping rate calculations. type: number requires_shipping: description: Whether the item requires shipping. @@ -9594,19 +8668,13 @@ components: description: the item location ID type: string stocked_quantity: - description: >- - the total stock quantity of an inventory item at the given location - ID + description: the total stock quantity of an inventory item at the given location ID type: number reserved_quantity: - description: >- - the reserved stock quantity of an inventory item at the given - location ID + description: the reserved stock quantity of an inventory item at the given location ID type: number incoming_quantity: - description: >- - the incoming stock quantity of an inventory item at the given - location ID + description: the incoming stock quantity of an inventory item at the given location ID type: number metadata: type: object @@ -9627,9 +8695,7 @@ components: format: date-time Invite: title: Invite - description: >- - An invite is created when an admin user invites a new user to join the - store's team. Once the invite is accepted, it's deleted. + description: An invite is created when an admin user invites a new user to join the store's team. Once the invite is accepted, it's deleted. type: object required: - accepted @@ -9652,9 +8718,7 @@ components: type: string format: email role: - description: >- - The user's role. These roles don't change the privileges of the - user. + description: The user's role. These roles don't change the privileges of the user. nullable: true type: string enum: @@ -9693,18 +8757,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute LineItem: title: Line Item - description: >- - Line Items are created when a product is added to a Cart. When Line - Items are purchased they will get copied to the resulting order, swap, - or claim, and can eventually be referenced in Fulfillments and Returns. - Line items may also be used for order edits. + description: Line Items are created when a product is added to a Cart. When Line Items are purchased they will get copied to the resulting order, swap, or claim, and can eventually be referenced in Fulfillments and Returns. Line items may also be used for order edits. type: object required: - allow_discounts @@ -9783,18 +8840,13 @@ components: items: $ref: '#/components/schemas/LineItemTaxLine' adjustments: - description: >- - The details of the item's adjustments, which are available when a - discount is applied on the item. + description: The details of the item's adjustments, which are available when a discount is applied on the item. x-expandable: adjustments type: array items: $ref: '#/components/schemas/LineItemAdjustment' original_item_id: - description: >- - The ID of the original line item. This is useful if the line item - belongs to a resource that references an order, such as a return or - an order edit. + description: The ID of the original line item. This is useful if the line item belongs to a resource that references an order, such as a return or an order edit. nullable: true type: string order_edit_id: @@ -9820,8 +8872,7 @@ components: nullable: true type: string format: uri - example: >- - https://medusa-public-images.s3.eu-west-1.amazonaws.com/coffee-mug.png + example: https://medusa-public-images.s3.eu-west-1.amazonaws.com/coffee-mug.png is_return: description: Is the item being returned type: boolean @@ -9831,29 +8882,20 @@ components: type: boolean default: false should_merge: - description: >- - Flag to indicate if new Line Items with the same variant should be - merged or added as an additional Line Item. + description: Flag to indicate if new Line Items with the same variant should be merged or added as an additional Line Item. type: boolean default: true allow_discounts: - description: >- - Flag to indicate if the Line Item should be included when doing - discount calculations. + description: Flag to indicate if the Line Item should be included when doing discount calculations. type: boolean default: true has_shipping: - description: >- - Flag to indicate if the Line Item has fulfillment associated with - it. + description: Flag to indicate if the Line Item has fulfillment associated with it. nullable: true type: boolean example: false unit_price: - description: >- - The price of one unit of the content in the Line Item. This should - be in the currency defined by the Cart/Order/Swap/Claim that the - Line Item belongs to. + description: The price of one unit of the content in the Line Item. This should be in the currency defined by the Cart/Order/Swap/Claim that the Line Item belongs to. type: integer example: 8000 variant_id: @@ -9886,9 +8928,7 @@ components: type: integer example: 0 refundable: - description: >- - The amount that can be refunded from the given Line Item. Takes - taxes and discounts into consideration. + description: The amount that can be refunded from the given Line Item. Takes taxes and discounts into consideration. type: integer example: 0 subtotal: @@ -9943,16 +8983,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute LineItemAdjustment: title: Line Item Adjustment - description: >- - A Line Item Adjustment includes details on discounts applied on a line - item. + description: A Line Item Adjustment includes details on discounts applied on a line item. type: object required: - amount @@ -10000,11 +9035,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute LineItemTaxLine: title: Line Item Tax Line description: A Line Item Tax Line represents the taxes applied on a line item. @@ -10060,11 +9092,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ModulesResponse: type: array items: @@ -10077,19 +9106,11 @@ components: description: The key of the module. type: string resolution: - description: >- - The resolution path of the module or false if module is not - installed. + description: The resolution path of the module or false if module is not installed. type: string MoneyAmount: title: Money Amount - description: >- - A Money Amount represent a price amount, for example, a product - variant's price or a price in a price list. Each Money Amount either has - a Currency or Region associated with it to indicate the pricing in a - given Currency or, for fully region-based pricing, the given price in a - specific Region. If region-based pricing is used, the amount will be in - the currency defined for the Region. + description: A Money Amount represent a price amount, for example, a product variant's price or a price in a price list. Each Money Amount either has a Currency or Region associated with it to indicate the pricing in a given Currency or, for fully region-based pricing, the given price in a specific Region. If region-based pricing is used, the amount will be in the currency defined for the Region. type: object required: - amount @@ -10121,22 +9142,16 @@ components: nullable: true $ref: '#/components/schemas/Currency' amount: - description: >- - The amount in the smallest currecny unit (e.g. cents 100 cents to - charge $1) that the Product Variant will cost. + description: The amount in the smallest currecny unit (e.g. cents 100 cents to charge $1) that the Product Variant will cost. type: integer example: 100 min_quantity: - description: >- - The minimum quantity that the Money Amount applies to. If this value - is not set, the Money Amount applies to all quantities. + description: The minimum quantity that the Money Amount applies to. If this value is not set, the Money Amount applies to all quantities. nullable: true type: integer example: 1 max_quantity: - description: >- - The maximum quantity that the Money Amount applies to. If this value - is not set, the Money Amount applies to all quantities. + description: The maximum quantity that the Money Amount applies to. If this value is not set, the Money Amount applies to all quantities. nullable: true type: integer example: 1 @@ -10156,9 +9171,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 variant: - description: >- - The details of the product variant that the money amount may belong - to. + description: The details of the product variant that the money amount may belong to. x-expandable: variant nullable: true type: object @@ -10196,15 +9209,10 @@ components: $ref: '#/components/schemas/Error' message: type: string - default: >- - Provided request body contains errors. Please check the data and - retry the request + default: Provided request body contains errors. Please check the data and retry the request Note: title: Note - description: >- - A Note is an element that can be used in association with different - resources to allow admin users to describe additional information. For - example, they can be used to add additional information about orders. + description: A Note is an element that can be used in association with different resources to allow admin users to describe additional information. For example, they can be used to add additional information about orders. type: object required: - author_id @@ -10264,10 +9272,7 @@ components: car: white Notification: title: Notification - description: >- - A notification is an alert sent, typically to customers, using the - installed Notification Provider as a reaction to internal events such as - `order.placed`. Notifications can be resent. + description: A notification is an alert sent, typically to customers, using the installed Notification Provider as a reaction to internal events such as `order.placed`. Notifications can be resent. type: object required: - created_at @@ -10310,16 +9315,11 @@ components: nullable: true $ref: '#/components/schemas/Customer' to: - description: >- - The address that the Notification was sent to. This will usually be - an email address, but can represent other addresses such as a chat - bot user ID. + description: The address that the Notification was sent to. This will usually be an email address, but can represent other addresses such as a chat bot user ID. type: string example: user@example.com data: - description: >- - The data that the Notification was sent with. This contains all the - data necessary for the Notification Provider to initiate a resend. + description: The data that the Notification was sent with. This contains all the data necessary for the Notification Provider to initiate a resend. type: object example: {} parent_id: @@ -10358,33 +9358,23 @@ components: format: date-time NotificationProvider: title: Notification Provider - description: >- - A notification provider represents a notification service installed in - the Medusa backend, either through a plugin or backend customizations. - It holds the notification service's installation status. + description: A notification provider represents a notification service installed in the Medusa backend, either through a plugin or backend customizations. It holds the notification service's installation status. type: object required: - id - is_installed properties: id: - description: >- - The ID of the notification provider as given by the notification - service. + description: The ID of the notification provider as given by the notification service. type: string example: sendgrid is_installed: - description: >- - Whether the notification service is installed in the current - version. If a notification service is no longer installed, the - `is_installed` attribute is set to `false`. + description: Whether the notification service is installed in the current version. If a notification service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true OAuth: title: OAuth - description: >- - An Oauth app is typically created by a plugin to handle authentication - to third-party services. + description: An Oauth app is typically created by a plugin to handle authentication to third-party services. type: object required: - application_name @@ -10423,10 +9413,7 @@ components: example: {} Order: title: Order - description: >- - An order is a purchase made by a customer. It holds details about - payment and fulfillment of the order. An order may also be created from - a draft order, which is created by an admin user. + description: An order is a purchase made by a customer. It holds details about payment and fulfillment of the order. An order may also be created from a draft order, which is created by an admin user. type: object required: - billing_address_id @@ -10653,16 +9640,12 @@ components: type: string format: date-time no_notification: - description: >- - Flag for describing whether or not notifications related to this - should be send. + description: Flag for describing whether or not notifications related to this should be send. nullable: true type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the processing of the order - in case of failure. + description: Randomly generated key used to continue the processing of the order in case of failure. nullable: true type: string externalDocs: @@ -10738,9 +9721,7 @@ components: type: integer example: 0 returnable_items: - description: >- - The details of the line items that are returnable as part of the - order, swaps, or claims + description: The details of the line items that are returnable as part of the order, swaps, or claims type: array x-expandable: returnable_items items: @@ -10760,11 +9741,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute sales_channels: description: The associated sales channels. type: array @@ -10775,10 +9753,7 @@ components: $ref: '#/components/schemas/SalesChannel' OrderEdit: title: Order Edit - description: >- - Order edit allows modifying items in an order, such as adding, updating, - or deleting items from the original order. Once the order edit is - confirmed, the changes are reflected on the original order. + description: Order edit allows modifying items in an order, such as adding, updating, or deleting items from the original order. Once the order edit is confirmed, the changes are reflected on the original order. type: object required: - canceled_at @@ -10824,14 +9799,10 @@ components: type: string example: Included two more items B to the order. created_by: - description: >- - The unique identifier of the user or customer who created the order - edit. + description: The unique identifier of the user or customer who created the order edit. type: string requested_by: - description: >- - The unique identifier of the user or customer who requested the - order edit. + description: The unique identifier of the user or customer who requested the order edit. nullable: true type: string requested_at: @@ -10840,9 +9811,7 @@ components: type: string format: date-time confirmed_by: - description: >- - The unique identifier of the user or customer who confirmed the - order edit. + description: The unique identifier of the user or customer who confirmed the order edit. nullable: true type: string confirmed_at: @@ -10851,9 +9820,7 @@ components: type: string format: date-time declined_by: - description: >- - The unique identifier of the user or customer who declined the order - edit. + description: The unique identifier of the user or customer who declined the order edit. nullable: true type: string declined_at: @@ -10866,9 +9833,7 @@ components: nullable: true type: string canceled_by: - description: >- - The unique identifier of the user or customer who cancelled the - order edit. + description: The unique identifier of the user or customer who cancelled the order edit. nullable: true type: string canceled_at: @@ -10905,9 +9870,7 @@ components: type: integer example: 8200 difference_due: - description: >- - The difference between the total amount of the order and total - amount of edited order. + description: The difference between the total amount of the order and total amount of edited order. type: integer example: 8200 status: @@ -10920,10 +9883,7 @@ components: - created - canceled items: - description: >- - The details of the cloned items from the original order with the new - changes. Once the order edit is confirmed, these line items are - associated with the original order. + description: The details of the cloned items from the original order with the new changes. Once the order edit is confirmed, these line items are associated with the original order. type: array x-expandable: items items: @@ -10934,9 +9894,7 @@ components: type: string example: paycol_01G8TJSYT9M6AVS5N4EMNFS1EK payment_collection: - description: >- - The details of the payment collection used to authorize additional - payment if necessary. + description: The details of the payment collection used to authorize additional payment if necessary. x-expandable: payment_collection nullable: true $ref: '#/components/schemas/PaymentCollection' @@ -10950,10 +9908,7 @@ components: format: date-time OrderItemChange: title: Order Item Change - description: >- - An order item change is a change made within an order edit to an order's - items. These changes are not reflected on the original order until the - order edit is confirmed. + description: An order item change is a change made within an order edit to an order's items. These changes are not reflected on the original order until the order edit is confirmed. type: object required: - created_at @@ -10991,10 +9946,7 @@ components: type: string example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN original_line_item: - description: >- - The details of the original line item this item change references. - This is used if the item change updates or deletes the original - item. + description: The details of the original line item this item change references. This is used if the item change updates or deletes the original item. x-expandable: original_line_item nullable: true $ref: '#/components/schemas/LineItem' @@ -11004,10 +9956,7 @@ components: type: string example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN line_item: - description: >- - The details of the resulting line item after the item change. This - line item is then used in the original order once the order edit is - confirmed. + description: The details of the resulting line item after the item change. This line item is then used in the original order once the order edit is confirmed. x-expandable: line_item nullable: true $ref: '#/components/schemas/LineItem' @@ -11026,12 +9975,7 @@ components: format: date-time Payment: title: Payment - description: >- - A payment is originally created from a payment session. Once a payment - session is authorized, the payment is created to represent the - authorized amount with a given payment method. Payments can be captured, - canceled or refunded. Payments can be made towards orders, swaps, order - edits, or other resources. + description: A payment is originally created from a payment session. Once a payment session is authorized, the payment is created to represent the authorized amount with a given payment method. Payments can be captured, canceled or refunded. Payments can be made towards orders, swaps, order edits, or other resources. type: object required: - amount @@ -11060,36 +10004,26 @@ components: type: string example: null swap: - description: >- - The details of the swap that this payment was potentially created - for. + description: The details of the swap that this payment was potentially created for. x-expandable: swap nullable: true type: object cart_id: - description: >- - The ID of the cart that the payment session was potentially created - for. + description: The ID of the cart that the payment session was potentially created for. nullable: true type: string cart: - description: >- - The details of the cart that the payment session was potentially - created for. + description: The details of the cart that the payment session was potentially created for. x-expandable: cart nullable: true type: object order_id: - description: >- - The ID of the order that the payment session was potentially created - for. + description: The ID of the order that the payment session was potentially created for. nullable: true type: string example: order_01G8TJSYT9M6AVS5N4EMNFS1EK order: - description: >- - The details of the order that the payment session was potentially - created for. + description: The details of the order that the payment session was potentially created for. x-expandable: order nullable: true type: object @@ -11110,9 +10044,7 @@ components: nullable: true $ref: '#/components/schemas/Currency' amount_refunded: - description: >- - The amount of the original Payment amount that has been refunded - back to the Customer. + description: The amount of the original Payment amount that has been refunded back to the Customer. type: integer default: 0 example: 0 @@ -11121,11 +10053,7 @@ components: type: string example: manual data: - description: >- - The data required for the Payment Provider to identify, modify and - process the Payment. Typically this will be an object that holds an - id to the external payment session, but can be an empty object if - the Payment Provider doesn't hold any state. + description: The data required for the Payment Provider to identify, modify and process the Payment. Typically this will be an object that holds an id to the external payment session, but can be an empty object if the Payment Provider doesn't hold any state. type: object example: {} captured_at: @@ -11139,9 +10067,7 @@ components: type: string format: date-time idempotency_key: - description: >- - Randomly generated key used to continue the completion of a payment - in case of failure. + description: Randomly generated key used to continue the completion of a payment in case of failure. nullable: true type: string externalDocs: @@ -11162,17 +10088,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute PaymentCollection: title: Payment Collection - description: >- - A payment collection allows grouping and managing a list of payments at - one. This can be helpful when making additional payment for order edits - or integrating installment payments. + description: A payment collection allows grouping and managing a list of payments at one. This can be helpful when making additional payment for order edits or integrating installment payments. type: object required: - amount @@ -11223,40 +10143,30 @@ components: type: string example: reg_01G1G5V26T9H8Y0M4JNE3YGA4G region: - description: >- - The details of the region this payment collection is associated - with. + description: The details of the region this payment collection is associated with. x-expandable: region nullable: true $ref: '#/components/schemas/Region' currency_code: - description: >- - The three character ISO code for the currency this payment - collection is associated with. + description: The three character ISO code for the currency this payment collection is associated with. type: string example: usd externalDocs: url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes description: See a list of codes. currency: - description: >- - The details of the currency this payment collection is associated - with. + description: The details of the currency this payment collection is associated with. x-expandable: currency nullable: true $ref: '#/components/schemas/Currency' payment_sessions: - description: >- - The details of the payment sessions created as part of the payment - collection. + description: The details of the payment sessions created as part of the payment collection. type: array x-expandable: payment_sessions items: $ref: '#/components/schemas/PaymentSession' payments: - description: >- - The details of the payments created as part of the payment - collection. + description: The details of the payments created as part of the payment collection. type: array x-expandable: payments items: @@ -11284,17 +10194,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute PaymentProvider: title: Payment Provider - description: >- - A payment provider represents a payment service installed in the Medusa - backend, either through a plugin or backend customizations. It holds the - payment service's installation status. + description: A payment provider represents a payment service installed in the Medusa backend, either through a plugin or backend customizations. It holds the payment service's installation status. type: object required: - id @@ -11305,22 +10209,12 @@ components: type: string example: manual is_installed: - description: >- - Whether the payment service is installed in the current version. If - a payment service is no longer installed, the `is_installed` - attribute is set to `false`. + description: Whether the payment service is installed in the current version. If a payment service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true PaymentSession: title: Payment Session - description: >- - A Payment Session is created when a Customer initilizes the checkout - flow, and can be used to hold the state of a payment flow. Each Payment - Session is controlled by a Payment Provider, which is responsible for - the communication with external payment services. Authorized Payment - Sessions will eventually get promoted to Payments to indicate that they - are authorized for payment processing such as capture or refund. Payment - sessions can also be used as part of payment collections. + description: A Payment Session is created when a Customer initilizes the checkout flow, and can be used to hold the state of a payment flow. Each Payment Session is controlled by a Payment Provider, which is responsible for the communication with external payment services. Authorized Payment Sessions will eventually get promoted to Payments to indicate that they are authorized for payment processing such as capture or refund. Payment sessions can also be used as part of payment collections. type: object required: - amount @@ -11351,31 +10245,21 @@ components: nullable: true $ref: '#/components/schemas/Cart' provider_id: - description: >- - The ID of the Payment Provider that is responsible for the Payment - Session + description: The ID of the Payment Provider that is responsible for the Payment Session type: string example: manual is_selected: - description: >- - A flag to indicate if the Payment Session has been selected as the - method that will be used to complete the purchase. + description: A flag to indicate if the Payment Session has been selected as the method that will be used to complete the purchase. nullable: true type: boolean example: true is_initiated: - description: >- - A flag to indicate if a communication with the third party provider - has been initiated. + description: A flag to indicate if a communication with the third party provider has been initiated. type: boolean default: false example: true status: - description: >- - Indicates the status of the Payment Session. Will default to - `pending`, and will eventually become `authorized`. Payment Sessions - may have the status of `requires_more` to indicate that further - actions are to be completed by the Customer. + description: Indicates the status of the Payment Session. Will default to `pending`, and will eventually become `authorized`. Payment Sessions may have the status of `requires_more` to indicate that further actions are to be completed by the Customer. type: string enum: - authorized @@ -11385,17 +10269,11 @@ components: - canceled example: pending data: - description: >- - The data required for the Payment Provider to identify, modify and - process the Payment Session. Typically this will be an object that - holds an id to the external payment session, but can be an empty - object if the Payment Provider doesn't hold any state. + description: The data required for the Payment Provider to identify, modify and process the Payment Session. Typically this will be an object that holds an id to the external payment session, but can be an empty object if the Payment Provider doesn't hold any state. type: object example: {} idempotency_key: - description: >- - Randomly generated key used to continue the completion of a cart in - case of failure. + description: Randomly generated key used to continue the completion of a cart in case of failure. nullable: true type: string externalDocs: @@ -11421,9 +10299,7 @@ components: format: date-time PriceList: title: Price List - description: >- - A Price List represents a set of prices that override the default price - for one or more product variants. + description: A Price List represents a set of prices that override the default price for one or more product variants. type: object required: - created_at @@ -11450,9 +10326,7 @@ components: type: string example: Prices for VIP customers type: - description: >- - The type of Price List. This can be one of either `sale` or - `override`. + description: The type of Price List. This can be one of either `sale` or `override`. type: string enum: - sale @@ -11482,9 +10356,7 @@ components: items: $ref: '#/components/schemas/CustomerGroup' prices: - description: >- - The prices that belong to the price list, represented as a Money - Amount. + description: The prices that belong to the price list, represented as a Money Amount. type: array x-expandable: prices items: @@ -11556,9 +10428,7 @@ components: properties: original_price: type: number - description: >- - The original price of the variant without any discounted prices - applied. + description: The original price of the variant without any discounted prices applied. calculated_price: type: number description: The calculated price of the variant. Can be a discounted price. @@ -11591,12 +10461,7 @@ components: description: The code of the tax rate Product: title: Product - description: >- - A product is a saleable item that holds general information such as name - or description. It must include at least one Product Variant, where each - product variant defines different options to purchase the product with - (for example, different sizes or colors). The prices and inventory of - the product are defined on the variant level. + description: A product is a saleable item that holds general information such as name or description. It must include at least one Product Variant, where each product variant defines different options to purchase the product with (for example, different sizes or colors). The prices and inventory of the product are defined on the variant level. type: object required: - collection_id @@ -11630,15 +10495,11 @@ components: type: string example: prod_01G1G5V2MBA328390B5AXJ610F title: - description: >- - A title that can be displayed for easy identification of the - Product. + description: A title that can be displayed for easy identification of the Product. type: string example: Medusa Coffee Mug subtitle: - description: >- - An optional subtitle that can be used to further specify the - Product. + description: An optional subtitle that can be used to further specify the Product. nullable: true type: string description: @@ -11652,10 +10513,7 @@ components: type: string example: coffee-mug is_giftcard: - description: >- - Whether the Product represents a Gift Card. Products that represent - Gift Cards will automatically generate a redeemable Gift Card code - once they are purchased. + description: Whether the Product represents a Gift Card. Products that represent Gift Cards will automatically generate a redeemable Gift Card code once they are purchased. type: boolean default: false status: @@ -11679,18 +10537,13 @@ components: type: string format: uri options: - description: >- - The details of the Product Options that are defined for the Product. - The product's variants will have a unique combination of values of - the product's options. + description: The details of the Product Options that are defined for the Product. The product's variants will have a unique combination of values of the product's options. type: array x-expandable: options items: $ref: '#/components/schemas/ProductOption' variants: - description: >- - The details of the Product Variants that belong to the Product. Each - will have a unique combination of values of the product's options. + description: The details of the Product Variants that belong to the Product. Each will have a unique combination of values of the product's options. type: array x-expandable: variants items: @@ -11703,17 +10556,11 @@ components: items: $ref: '#/components/schemas/ProductCategory' profile_id: - description: >- - The ID of the shipping profile that the product belongs to. The - shipping profile has a set of defined shipping options that can be - used to fulfill the product. + description: The ID of the shipping profile that the product belongs to. The shipping profile has a set of defined shipping options that can be used to fulfill the product. type: string example: sp_01G1G5V239ENSZ5MV4JAR737BM profile: - description: >- - The details of the shipping profile that the product belongs to. The - shipping profile has a set of defined shipping options that can be - used to fulfill the product. + description: The details of the shipping profile that the product belongs to. The shipping profile has a set of defined shipping options that can be used to fulfill the product. x-expandable: profile nullable: true $ref: '#/components/schemas/ShippingProfile' @@ -11724,62 +10571,42 @@ components: items: $ref: '#/components/schemas/ShippingProfile' weight: - description: >- - The weight of the Product Variant. May be used in shipping rate - calculations. + description: The weight of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null length: - description: >- - The length of the Product Variant. May be used in shipping rate - calculations. + description: The length of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null height: - description: >- - The height of the Product Variant. May be used in shipping rate - calculations. + description: The height of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null width: - description: >- - The width of the Product Variant. May be used in shipping rate - calculations. + description: The width of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null hs_code: - description: >- - The Harmonized System code of the Product Variant. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null origin_country: - description: >- - The country in which the Product Variant was produced. May be used - by Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Product Variant was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Product Variant. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null material: - description: >- - The material and composition that the Product Variant is made of, - May be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Product Variant is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null @@ -11810,9 +10637,7 @@ components: items: $ref: '#/components/schemas/ProductTag' discountable: - description: >- - Whether the Product can be discounted. Discounts will not apply to - Line Items of this Product when this flag is set to `false`. + description: Whether the Product can be discounted. Discounts will not apply to Line Items of this Product when this flag is set to `false`. type: boolean default: true external_id: @@ -11846,16 +10671,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductCategory: title: Product Category - description: >- - A product category can be used to categorize products into a hierarchy - of categories. + description: A product category can be used to categorize products into a hierarchy of categories. x-resourceId: ProductCategory x-featureFlag: product_categories type: object @@ -11885,15 +10705,11 @@ components: type: string default: '' handle: - description: >- - A unique string that identifies the Product Category - can for - example be used in slug structures. + description: A unique string that identifies the Product Category - can for example be used in slug structures. type: string example: regular-fit mpath: - description: >- - A string for Materialized Paths - used for finding ancestors and - descendents + description: A string for Materialized Paths - used for finding ancestors and descendents nullable: true type: string example: pcat_id1.pcat_id2.pcat_id3 @@ -11946,17 +10762,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductCollection: title: Product Collection - description: >- - A Product Collection allows grouping together products for promotional - purposes. For example, an admin can create a Summer collection, add - products to it, and showcase it on the storefront. + description: A Product Collection allows grouping together products for promotional purposes. For example, an admin can create a Summer collection, add products to it, and showcase it on the storefront. type: object required: - created_at @@ -11976,9 +10786,7 @@ components: type: string example: Summer Collection handle: - description: >- - A unique string that identifies the Product Collection - can for - example be used in slug structures. + description: A unique string that identifies the Product Collection - can for example be used in slug structures. nullable: true type: string example: summer-collection @@ -12008,17 +10816,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductOption: title: Product Option - description: >- - A Product Option defines properties that may vary between different - variants of a Product. Common Product Options are "Size" and "Color". - Admins are free to create any product options. + description: A Product Option defines properties that may vary between different variants of a Product. Common Product Options are "Size" and "Color". Admins are free to create any product options. type: object required: - created_at @@ -12072,16 +10874,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductOptionValue: title: Product Option Value - description: >- - An option value is one of the possible values of a Product Option. - Product Variants specify a unique combination of product option values. + description: An option value is one of the possible values of a Product Option. Product Variants specify a unique combination of product option values. type: object required: - created_at @@ -12098,22 +10895,15 @@ components: type: string example: optval_01F0YESHR7S6ECD03RF6W12DSJ value: - description: >- - The value that the Product Variant has defined for the specific - Product Option (e.g. if the Product Option is "Size" this value - could be `Small`, `Medium` or `Large`). + description: The value that the Product Variant has defined for the specific Product Option (e.g. if the Product Option is "Size" this value could be `Small`, `Medium` or `Large`). type: string example: large option_id: - description: >- - The ID of the Product Option that the Product Option Value belongs - to. + description: The ID of the Product Option that the Product Option Value belongs to. type: string example: opt_01F0YESHQBZVKCEXJ24BS6PCX3 option: - description: >- - The details of the product option that the Product Option Value - belongs to. + description: The details of the product option that the Product Option Value belongs to. x-expandable: option nullable: true type: object @@ -12122,9 +10912,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 variant: - description: >- - The details of the product variant that uses this product option - value. + description: The details of the product variant that uses this product option value. x-expandable: variant nullable: true type: object @@ -12148,11 +10936,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductTag: title: Product Tag description: A Product Tag can be added to Products for easy filtering and grouping. @@ -12193,16 +10978,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductTaxRate: title: Product Tax Rate - description: >- - This represents the association between a tax rate and a product to - indicate that the product is taxed in a way different than the default. + description: This represents the association between a tax rate and a product to indicate that the product is taxed in a way different than the default. type: object required: - created_at @@ -12244,16 +11024,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductType: title: Product Type - description: >- - A Product Type can be added to Products for filtering and reporting - purposes. + description: A Product Type can be added to Products for filtering and reporting purposes. type: object required: - created_at @@ -12291,17 +11066,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductTypeTaxRate: title: Product Type Tax Rate - description: >- - This represents the association between a tax rate and a product type to - indicate that the product type is taxed in a different way than the - default. + description: This represents the association between a tax rate and a product type to indicate that the product type is taxed in a different way than the default. type: object required: - created_at @@ -12343,18 +11112,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ProductVariant: title: Product Variant - description: >- - A Product Variant represents a Product with a specific set of Product - Option configurations. The maximum number of Product Variants that a - Product can have is given by the number of available Product Option - combinations. A product must at least have one product variant. + description: A Product Variant represents a Product with a specific set of Product Option configurations. The maximum number of Product Variants that a Product can have is given by the number of available Product Option combinations. A product must at least have one product variant. type: object required: - allow_backorder @@ -12385,9 +11147,7 @@ components: type: string example: variant_01G1G5V2MRX2V3PVSR2WXYPFB6 title: - description: >- - A title that can be displayed for easy identification of the Product - Variant. + description: A title that can be displayed for easy identification of the Product Variant. type: string example: Small product_id: @@ -12400,40 +11160,28 @@ components: nullable: true type: object prices: - description: >- - The details of the prices of the Product Variant, each represented - as a Money Amount. Each Money Amount represents a price in a given - currency or a specific Region. + description: The details of the prices of the Product Variant, each represented as a Money Amount. Each Money Amount represents a price in a given currency or a specific Region. type: array x-expandable: prices items: $ref: '#/components/schemas/MoneyAmount' sku: - description: >- - The unique stock keeping unit used to identify the Product Variant. - This will usually be a unique identifer for the item that is to be - shipped, and can be referenced across multiple systems. + description: The unique stock keeping unit used to identify the Product Variant. This will usually be a unique identifer for the item that is to be shipped, and can be referenced across multiple systems. nullable: true type: string example: shirt-123 barcode: - description: >- - A generic field for a GTIN number that can be used to identify the - Product Variant. + description: A generic field for a GTIN number that can be used to identify the Product Variant. nullable: true type: string example: null ean: - description: >- - An EAN barcode number that can be used to identify the Product - Variant. + description: An EAN barcode number that can be used to identify the Product Variant. nullable: true type: string example: null upc: - description: >- - A UPC barcode number that can be used to identify the Product - Variant. + description: A UPC barcode number that can be used to identify the Product Variant. nullable: true type: string example: null @@ -12447,9 +11195,7 @@ components: type: integer example: 100 allow_backorder: - description: >- - Whether the Product Variant should be purchasable when - `inventory_quantity` is 0. + description: Whether the Product Variant should be purchasable when `inventory_quantity` is 0. type: boolean default: false manage_inventory: @@ -12457,69 +11203,47 @@ components: type: boolean default: true hs_code: - description: >- - The Harmonized System code of the Product Variant. May be used by - Fulfillment Providers to pass customs information to shipping - carriers. + description: The Harmonized System code of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null origin_country: - description: >- - The country in which the Product Variant was produced. May be used - by Fulfillment Providers to pass customs information to shipping - carriers. + description: The country in which the Product Variant was produced. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null mid_code: - description: >- - The Manufacturers Identification code that identifies the - manufacturer of the Product Variant. May be used by Fulfillment - Providers to pass customs information to shipping carriers. + description: The Manufacturers Identification code that identifies the manufacturer of the Product Variant. May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null material: - description: >- - The material and composition that the Product Variant is made of, - May be used by Fulfillment Providers to pass customs information to - shipping carriers. + description: The material and composition that the Product Variant is made of, May be used by Fulfillment Providers to pass customs information to shipping carriers. nullable: true type: string example: null weight: - description: >- - The weight of the Product Variant. May be used in shipping rate - calculations. + description: The weight of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null length: - description: >- - The length of the Product Variant. May be used in shipping rate - calculations. + description: The length of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null height: - description: >- - The height of the Product Variant. May be used in shipping rate - calculations. + description: The height of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null width: - description: >- - The width of the Product Variant. May be used in shipping rate - calculations. + description: The width of the Product Variant. May be used in shipping rate calculations. nullable: true type: number example: null options: - description: >- - The details of the product options that this product variant defines - values for. + description: The details of the product options that this product variant defines values for. type: array x-expandable: options items: @@ -12550,18 +11274,12 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute purchasable: - description: > + description: | Only used with the inventory modules. - - A boolean value indicating whether the Product Variant is - purchasable. - + A boolean value indicating whether the Product Variant is purchasable. A variant is purchasable if: - inventory is not managed - it has no inventory items @@ -12570,9 +11288,7 @@ components: type: boolean ProductVariantInventoryItem: title: Product Variant Inventory Item - description: >- - A Product Variant Inventory Item links variants with inventory items and - denotes the required quantity of the variant. + description: A Product Variant Inventory Item links variants with inventory items and denotes the required quantity of the variant. type: object required: - created_at @@ -12617,15 +11333,7 @@ components: format: date-time PublishableApiKey: title: Publishable API key - description: >- - A Publishable API key defines scopes that resources are available in. - Then, it can be used in request to infer the resources without having to - directly pass them. For example, a publishable API key can be associated - with one or more sales channels. Then, when the publishable API key is - passed in the header of a request, it is inferred what sales channel is - being used without having to pass the sales channel as a query or body - parameter of the request. Publishable API keys can only be used with - sales channels, at the moment. + description: A Publishable API key defines scopes that resources are available in. Then, it can be used in request to infer the resources without having to directly pass them. For example, a publishable API key can be associated with one or more sales channels. Then, when the publishable API key is passed in the header of a request, it is inferred what sales channel is being used without having to pass the sales channel as a query or body parameter of the request. Publishable API keys can only be used with sales channels, at the moment. type: object required: - created_at @@ -12668,9 +11376,7 @@ components: format: date-time PublishableApiKeySalesChannel: title: Publishable API Key Sales Channel - description: >- - This represents the association between the Publishable API keys and - Sales Channels + description: This represents the association between the Publishable API keys and Sales Channels type: object required: - publishable_key_id @@ -12706,10 +11412,7 @@ components: format: date-time Refund: title: Refund - description: >- - A refund represents an amount of money transfered back to the customer - for a given reason. Refunds may occur in relation to Returns, Swaps and - Claims, but can also be initiated by an admin for an order. + description: A refund represents an amount of money transfered back to the customer for a given reason. Refunds may occur in relation to Returns, Swaps and Claims, but can also be initiated by an admin for an order. type: object required: - amount @@ -12757,9 +11460,7 @@ components: type: string example: I didn't like it reason: - description: >- - The reason given for the Refund, will automatically be set when - processed as part of a Swap, Claim or Return. + description: The reason given for the Refund, will automatically be set when processed as part of a Swap, Claim or Return. type: string enum: - discount @@ -12769,9 +11470,7 @@ components: - other example: return idempotency_key: - description: >- - Randomly generated key used to continue the completion of the refund - in case of failure. + description: Randomly generated key used to continue the completion of the refund in case of failure. nullable: true type: string externalDocs: @@ -12792,18 +11491,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute Region: title: Region - description: >- - A region holds settings specific to a geographical location, including - the currency, tax rates, and fulfillment and payment providers. A Region - can consist of multiple countries to accomodate common shopping settings - across countries. + description: A region holds settings specific to a geographical location, including the currency, tax rates, and fulfillment and payment providers. A Region can consist of multiple countries to accomodate common shopping settings across countries. type: object required: - automatic_taxes @@ -12824,9 +11516,7 @@ components: type: string example: reg_01G1G5V26T9H8Y0M4JNE3YGA4G name: - description: >- - The name of the region as displayed to the customer. If the Region - only has one country it is recommended to write the country name. + description: The name of the region as displayed to the customer. If the Region only has one country it is recommended to write the country name. type: string example: EU currency_code: @@ -12846,17 +11536,13 @@ components: type: number example: 0 tax_rates: - description: >- - The details of the tax rates used in the region, aside from the - default rate. + description: The details of the tax rates used in the region, aside from the default rate. type: array x-expandable: tax_rates items: $ref: '#/components/schemas/TaxRate' tax_code: - description: >- - The tax code used on purchases in the Region. This may be used by - other systems for accounting purposes. + description: The tax code used on purchases in the Region. This may be used by other systems for accounting purposes. nullable: true type: string example: null @@ -12885,17 +11571,13 @@ components: nullable: true $ref: '#/components/schemas/TaxProvider' payment_providers: - description: >- - The details of the payment providers that can be used to process - payments in the region. + description: The details of the payment providers that can be used to process payments in the region. type: array x-expandable: payment_providers items: $ref: '#/components/schemas/PaymentProvider' fulfillment_providers: - description: >- - The details of the fulfillment providers that can be used to fulfill - items of orders and similar resources in the region. + description: The details of the fulfillment providers that can be used to fulfill items of orders and similar resources in the region. type: array x-expandable: fulfillment_providers items: @@ -12925,11 +11607,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ReservationItemDTO: title: Reservation item description: Represents a reservation of an inventory item at a stock location @@ -12977,10 +11656,7 @@ components: format: date-time Return: title: Return - description: >- - A Return holds information about Line Items that a Customer wishes to - send back, along with how the items will be returned. Returns can also - be used as part of a Swap or a Claim. + description: A Return holds information about Line Items that a Customer wishes to send back, along with how the items will be returned. Returns can also be used as part of a Swap or a Claim. type: object required: - claim_order_id @@ -13048,17 +11724,12 @@ components: nullable: true type: object shipping_method: - description: >- - The details of the Shipping Method that will be used to send the - Return back. Can be null if the Customer will handle the return - shipment themselves. + description: The details of the Shipping Method that will be used to send the Return back. Can be null if the Customer will handle the return shipment themselves. x-expandable: shipping_method nullable: true $ref: '#/components/schemas/ShippingMethod' shipping_data: - description: >- - Data about the return shipment as provided by the Fulfilment - Provider that handles the return shipment. + description: Data about the return shipment as provided by the Fulfilment Provider that handles the return shipment. nullable: true type: object example: {} @@ -13072,16 +11743,12 @@ components: type: integer example: 1000 no_notification: - description: >- - When set to true, no notification will be sent related to this - return. + description: When set to true, no notification will be sent related to this return. nullable: true type: boolean example: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the return - in case of failure. + description: Randomly generated key used to continue the completion of the return in case of failure. nullable: true type: string externalDocs: @@ -13107,16 +11774,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ReturnItem: title: Return Item - description: >- - A return item represents a line item in an order that is to be returned. - It includes details related to the return and the reason behind it. + description: A return item represents a line item in an order that is to be returned. It includes details related to the return and the reason behind it. type: object required: - is_requested @@ -13152,9 +11814,7 @@ components: type: integer example: 1 is_requested: - description: >- - Whether the Return Item was requested initially or received - unexpectedly in the warehouse. + description: Whether the Return Item was requested initially or received unexpectedly in the warehouse. type: boolean default: true requested_quantity: @@ -13189,16 +11849,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ReturnReason: title: Return Reason - description: >- - A Return Reason is a value defined by an admin. It can be used on Return - Items in order to indicate why a Line Item was returned. + description: A Return Reason is a value defined by an admin. It can be used on Return Items in order to indicate why a Line Item was returned. type: object required: - created_at @@ -13262,17 +11917,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute SalesChannel: title: Sales Channel - description: >- - A Sales Channel is a method a business offers its products for purchase - for the customers. For example, a Webshop can be a sales channel, and a - mobile app can be another. + description: A Sales Channel is a method a business offers its products for purchase for the customers. For example, a Webshop can be a sales channel, and a mobile app can be another. type: object required: - created_at @@ -13326,11 +11975,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute carts: description: The associated carts. type: array @@ -13356,9 +12002,7 @@ components: type: object SalesChannelLocation: title: Sales Channel Stock Location - description: >- - This represents the association between a sales channel and a stock - locations. + description: This represents the association between a sales channel and a stock locations. type: object required: - created_at @@ -13399,13 +12043,7 @@ components: format: date-time ShippingMethod: title: Shipping Method - description: >- - A Shipping Method represents a way in which an Order or Return can be - shipped. Shipping Methods are created from a Shipping Option, but may - contain additional details that can be necessary for the Fulfillment - Provider to handle the shipment. If the shipping method is created for a - return, it may be associated with a claim or a swap that the return is - part of. + description: A Shipping Method represents a way in which an Order or Return can be shipped. Shipping Methods are created from a Shipping Option, but may contain additional details that can be necessary for the Fulfillment Provider to handle the shipment. If the shipping method is created for a return, it may be associated with a claim or a swap that the return is part of. type: object required: - cart_id @@ -13423,9 +12061,7 @@ components: type: string example: sm_01F0YET7DR2E7CYVSDHM593QG2 shipping_option_id: - description: >- - The ID of the Shipping Option that the Shipping Method is built - from. + description: The ID of the Shipping Option that the Shipping Method is built from. type: string example: so_01G1G5V27GYX4QXNARRQCW1N8T order_id: @@ -13490,17 +12126,11 @@ components: items: $ref: '#/components/schemas/ShippingMethodTaxLine' price: - description: >- - The amount to charge for the Shipping Method. The currency of the - price is defined by the Region that the Order that the Shipping - Method belongs to is a part of. + description: The amount to charge for the Shipping Method. The currency of the price is defined by the Region that the Order that the Shipping Method belongs to is a part of. type: integer example: 200 data: - description: >- - Additional data that the Fulfillment Provider needs to fulfill the - shipment. This is used in combination with the Shipping Options - data, and may contain information such as a drop point id. + description: Additional data that the Fulfillment Provider needs to fulfill the shipment. This is used in combination with the Shipping Options data, and may contain information such as a drop point id. type: object example: {} includes_tax: @@ -13522,9 +12152,7 @@ components: example: 0 ShippingMethodTaxLine: title: Shipping Method Tax Line - description: >- - A Shipping Method Tax Line represents the taxes applied on a shipping - method in a cart. + description: A Shipping Method Tax Line represents the taxes applied on a shipping method in a cart. type: object required: - code @@ -13577,20 +12205,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ShippingOption: title: Shipping Option - description: >- - A Shipping Option represents a way in which an Order or Return can be - shipped. Shipping Options have an associated Fulfillment Provider that - will be used when the fulfillment of an Order is initiated. Shipping - Options themselves cannot be added to Carts, but serve as a template for - Shipping Methods. This distinction makes it possible to customize - individual Shipping Methods with additional information. + description: A Shipping Option represents a way in which an Order or Return can be shipped. Shipping Options have an associated Fulfillment Provider that will be used when the fulfillment of an Order is initiated. Shipping Options themselves cannot be added to Carts, but serve as a template for Shipping Methods. This distinction makes it possible to customize individual Shipping Methods with additional information. type: object required: - admin_only @@ -13613,9 +12232,7 @@ components: type: string example: so_01G1G5V27GYX4QXNARRQCW1N8T name: - description: >- - The name given to the Shipping Option - this may be displayed to the - Customer. + description: The name given to the Shipping Option - this may be displayed to the Customer. type: string example: PostFake Standard region_id: @@ -13632,69 +12249,47 @@ components: type: string example: sp_01G1G5V239ENSZ5MV4JAR737BM profile: - description: >- - The details of the shipping profile that the shipping option belongs - to. + description: The details of the shipping profile that the shipping option belongs to. x-expandable: profile nullable: true $ref: '#/components/schemas/ShippingProfile' provider_id: - description: >- - The ID of the fulfillment provider that will be used to later to - process the shipping method created from this shipping option and - its fulfillments. + description: The ID of the fulfillment provider that will be used to later to process the shipping method created from this shipping option and its fulfillments. type: string example: manual provider: - description: >- - The details of the fulfillment provider that will be used to later - to process the shipping method created from this shipping option and - its fulfillments. + description: The details of the fulfillment provider that will be used to later to process the shipping method created from this shipping option and its fulfillments. x-expandable: provider nullable: true $ref: '#/components/schemas/FulfillmentProvider' price_type: - description: >- - The type of pricing calculation that is used when creatin Shipping - Methods from the Shipping Option. Can be `flat_rate` for fixed - prices or `calculated` if the Fulfillment Provider can provide price - calulations. + description: The type of pricing calculation that is used when creatin Shipping Methods from the Shipping Option. Can be `flat_rate` for fixed prices or `calculated` if the Fulfillment Provider can provide price calulations. type: string enum: - flat_rate - calculated example: flat_rate amount: - description: >- - The amount to charge for shipping when the Shipping Option price - type is `flat_rate`. + description: The amount to charge for shipping when the Shipping Option price type is `flat_rate`. nullable: true type: integer example: 200 is_return: - description: >- - Flag to indicate if the Shipping Option can be used for Return - shipments. + description: Flag to indicate if the Shipping Option can be used for Return shipments. type: boolean default: false admin_only: - description: >- - Flag to indicate if the Shipping Option usage is restricted to admin - users. + description: Flag to indicate if the Shipping Option usage is restricted to admin users. type: boolean default: false requirements: - description: >- - The details of the requirements that must be satisfied for the - Shipping Option to be available for usage in a Cart. + description: The details of the requirements that must be satisfied for the Shipping Option to be available for usage in a Cart. type: array x-expandable: requirements items: $ref: '#/components/schemas/ShippingOptionRequirement' data: - description: >- - The data needed for the Fulfillment Provider to identify the - Shipping Option. + description: The data needed for the Fulfillment Provider to identify the Shipping Option. type: object example: {} includes_tax: @@ -13722,16 +12317,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ShippingOptionRequirement: title: Shipping Option Requirement - description: >- - A shipping option requirement defines conditions that a Cart must - satisfy for the Shipping Option to be available for usage in the Cart. + description: A shipping option requirement defines conditions that a Cart must satisfy for the Shipping Option to be available for usage in the Cart. type: object required: - amount @@ -13754,12 +12344,7 @@ components: nullable: true type: object type: - description: >- - The type of the requirement, this defines how the value will be - compared to the Cart's total. `min_subtotal` requirements define the - minimum subtotal that is needed for the Shipping Option to be - available, while the `max_subtotal` defines the maximum subtotal - that the Cart can have for the Shipping Option to be available. + description: The type of the requirement, this defines how the value will be compared to the Cart's total. `min_subtotal` requirements define the minimum subtotal that is needed for the Shipping Option to be available, while the `max_subtotal` defines the maximum subtotal that the Cart can have for the Shipping Option to be available. type: string enum: - min_subtotal @@ -13776,12 +12361,7 @@ components: format: date-time ShippingProfile: title: Shipping Profile - description: >- - A Shipping Profile has a set of defined Shipping Options that can be - used to fulfill a given set of Products. For example, gift cards are - shipped differently than physical products, so a shipping profile with - the type `gift_card` groups together the shipping options that can only - be used for gift cards. + description: A Shipping Profile has a set of defined Shipping Options that can be used to fulfill a given set of Products. For example, gift cards are shipped differently than physical products, so a shipping profile with the type `gift_card` groups together the shipping options that can only be used for gift cards. type: object required: - created_at @@ -13797,15 +12377,11 @@ components: type: string example: sp_01G1G5V239ENSZ5MV4JAR737BM name: - description: >- - The name given to the Shipping profile - this may be displayed to - the Customer. + description: The name given to the Shipping profile - this may be displayed to the Customer. type: string example: Default Shipping Profile type: - description: >- - The type of the Shipping Profile, may be `default`, `gift_card` or - `custom`. + description: The type of the Shipping Profile, may be `default`, `gift_card` or `custom`. type: string enum: - default @@ -13813,18 +12389,13 @@ components: - custom example: default products: - description: >- - The details of the products that the Shipping Profile defines - Shipping Options for. Available if the relation `products` is - expanded. + description: The details of the products that the Shipping Profile defines Shipping Options for. Available if the relation `products` is expanded. type: array x-expandable: products items: type: object shipping_options: - description: >- - The details of the shipping options that can be used to create - shipping methods for the Products in the Shipping Profile. + description: The details of the shipping options that can be used to create shipping methods for the Products in the Shipping Profile. type: array x-expandable: shipping_options items: @@ -13849,11 +12420,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute ShippingTaxRate: title: Shipping Tax Rate description: This represents the tax rates applied on a shipping option. @@ -13898,11 +12466,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute StagedJob: title: Staged Job description: A staged job resource @@ -14088,11 +12653,7 @@ components: $ref: '#/components/schemas/SalesChannel' Store: title: Store - description: >- - A store holds the main settings of the commerce shop. By default, only - one store is created and used within the Medusa backend. It holds - settings related to the name of the store, available currencies, and - more. + description: A store holds the main settings of the commerce shop. By default, only one store is created and used within the Medusa backend. It holds settings related to the name of the store, available currencies, and more. type: object required: - created_at @@ -14135,16 +12696,12 @@ components: items: $ref: '#/components/schemas/Currency' swap_link_template: - description: >- - A template to generate Swap links from. Use {{cart_id}} to include - the Swap's `cart_id` in the link. + description: A template to generate Swap links from. Use {{cart_id}} to include the Swap's `cart_id` in the link. nullable: true type: string example: null payment_link_template: - description: >- - A template to generate Payment links from. Use {{cart_id}} to - include the payment's `cart_id` in the link. + description: A template to generate Payment links from. Use {{cart_id}} to include the payment's `cart_id` in the link. nullable: true type: string example: null @@ -14183,11 +12740,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute StoreAuthRes: type: object description: The customer's details. @@ -14309,9 +12863,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product collections skipped when retrieving the - product collections. + description: The number of product collections skipped when retrieving the product collections. limit: type: integer description: The number of items per page @@ -14326,24 +12878,14 @@ components: $ref: '#/components/schemas/ProductCollection' StoreCompleteCartRes: type: object - description: >- - If the cart is completed successfully, this will have the created order - or the swap's details, based on the cart's type. Otherwise, it'll be the - cart's details. + description: If the cart is completed successfully, this will have the created order or the swap's details, based on the cart's type. Otherwise, it'll be the cart's details. required: - type - data properties: type: type: string - description: >- - The type of the data property. If the cart completion fails, type - will be `cart` and the data object will be the cart's details. If - the cart completion is successful and the cart is used for checkout, - type will be `order` and the data object will be the order's - details. If the cart completion is successful and the cart is used - for swap creation, type will be `swap` and the data object will be - the swap's details. + description: The type of the data property. If the cart completion fails, type will be `cart` and the data object will be the cart's details. If the cart completion is successful and the cart is used for checkout, type will be `order` and the data object will be the order's details. If the cart completion is successful and the cart is used for swap creation, type will be `swap` and the data object will be the swap's details. enum: - order - cart @@ -14354,21 +12896,15 @@ components: oneOf: - type: object allOf: - - description: >- - Cart was successfully authorized and order was placed - successfully. + - description: Cart was successfully authorized and order was placed successfully. - $ref: '#/components/schemas/Order' - type: object allOf: - - description: >- - Cart was successfully authorized but requires further - actions. + - description: Cart was successfully authorized but requires further actions. - $ref: '#/components/schemas/Cart' - type: object allOf: - - description: >- - Cart was used for a swap and it has been completed - successfully. + - description: Cart was used for a swap and it has been completed successfully. - $ref: '#/components/schemas/Swap' StoreCustomersListOrdersRes: type: object @@ -14491,14 +13027,10 @@ components: - data properties: provider_id: - description: >- - The ID of the Payment Provider where the payment method is - saved. + description: The ID of the Payment Provider where the payment method is saved. type: string data: - description: >- - The data needed for the Payment Provider to use the saved - payment method. + description: The data needed for the Payment Provider to use the saved payment method. type: object StoreCustomersRes: type: object @@ -14569,9 +13101,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product categories skipped when retrieving the product - categories. + description: The number of product categories skipped when retrieving the product categories. limit: type: integer description: The number of items per page @@ -14771,35 +13301,15 @@ components: properties: region_id: type: string - description: >- - The ID of the Region to create the Cart in. Setting the cart's - region can affect the pricing of the items in the cart as well as - the used currency. If this parameter is not provided, the first - region in the store is used by default. + description: The ID of the Region to create the Cart in. Setting the cart's region can affect the pricing of the items in the cart as well as the used currency. If this parameter is not provided, the first region in the store is used by default. sales_channel_id: type: string - description: >- - The ID of the Sales channel to create the Cart in. The cart's sales - channel affects which products can be added to the cart. If a - product does not exist in the cart's sales channel, it cannot be - added to the cart. If you add a publishable API key in the header of - this request and specify a sales channel ID, the specified sales - channel must be within the scope of the publishable API key's - resources. If you add a publishable API key in the header of this - request, you don't specify a sales channel ID, and the publishable - API key is associated with one sales channel, that sales channel - will be attached to the cart. If no sales channel is passed and no - publishable API key header is passed or the publishable API key - isn't associated with any sales channel, the cart will not be - associated with any sales channel. + description: The ID of the Sales channel to create the Cart in. The cart's sales channel affects which products can be added to the cart. If a product does not exist in the cart's sales channel, it cannot be added to the cart. If you add a publishable API key in the header of this request and specify a sales channel ID, the specified sales channel must be within the scope of the publishable API key's resources. If you add a publishable API key in the header of this request, you don't specify a sales channel ID, and the publishable API key is associated with one sales channel, that sales channel will be attached to the cart. If no sales channel is passed and no publishable API key header is passed or the publishable API key isn't associated with any sales channel, the cart will not be associated with any sales channel. country_code: type: string - description: >- - The two character ISO country code to create the Cart in. Setting - this parameter will set the country code of the shipping address. + description: The two character ISO country code to create the Cart in. Setting this parameter will set the country code of the shipping address. externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. items: description: An array of product variants to generate line items from. @@ -14817,9 +13327,7 @@ components: description: The quantity to add into the cart. type: integer context: - description: >- - An object to provide context to the Cart. The `context` field is - automatically populated with `ip` and `user_agent` + description: An object to provide context to the Cart. The `context` field is automatically populated with `ip` and `user_agent` type: object example: ip: '::1' @@ -14835,15 +13343,10 @@ components: description: The quantity of the line item in the cart. metadata: type: object - description: >- - An optional key-value map with additional details about the Line - Item. If omitted, the metadata will remain unchanged." + description: An optional key-value map with additional details about the Line Item. If omitted, the metadata will remain unchanged." externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute StorePostCartsCartLineItemsReq: type: object description: The details of the line item to create. @@ -14859,15 +13362,10 @@ components: description: The quantity of the Product Variant to add to the Line Item. metadata: type: object - description: >- - An optional key-value map with additional details about the Line - Item. + description: An optional key-value map with additional details about the Line Item. externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute StorePostCartsCartPaymentSessionReq: type: object description: The details of the payment session to set. @@ -14891,18 +13389,12 @@ components: properties: region_id: type: string - description: >- - The ID of the Region to create the Cart in. Setting the cart's - region can affect the pricing of the items in the cart as well as - the used currency. + description: The ID of the Region to create the Cart in. Setting the cart's region can affect the pricing of the items in the cart as well as the used currency. country_code: type: string - description: >- - The 2 character ISO country code to create the Cart in. Setting this - parameter will set the country code of the shipping address. + description: The 2 character ISO country code to create the Cart in. Setting this parameter will set the country code of the shipping address. externalDocs: - url: >- - https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements + url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements description: See a list of codes. email: type: string @@ -14910,14 +13402,7 @@ components: format: email sales_channel_id: type: string - description: >- - The ID of the Sales channel to create the Cart in. The cart's sales - channel affects which products can be added to the cart. If a - product does not exist in the cart's sales channel, it cannot be - added to the cart. If you add a publishable API key in the header of - this request and specify a sales channel ID, the specified sales - channel must be within the scope of the publishable API key's - resources. + description: The ID of the Sales channel to create the Cart in. The cart's sales channel affects which products can be added to the cart. If a product does not exist in the cart's sales channel, it cannot be added to the cart. If you add a publishable API key in the header of this request and specify a sales channel ID, the specified sales channel must be within the scope of the publishable API key's resources. billing_address: description: The Address to be used for billing purposes. anyOf: @@ -14958,9 +13443,7 @@ components: description: The ID of the Customer to associate the Cart with. type: string context: - description: >- - An object to provide context to the Cart. The `context` field is - automatically populated with `ip` and `user_agent` + description: An object to provide context to the Cart. The `context` field is automatically populated with `ip` and `user_agent` type: object example: ip: '::1' @@ -14976,10 +13459,7 @@ components: description: ID of the shipping option to create the method from. data: type: object - description: >- - Used to hold any data that the shipping method may need to process - the fulfillment of the order. This depends on the fulfillment - provider you're using. + description: Used to hold any data that the shipping method may need to process the fulfillment of the order. This depends on the fulfillment provider you're using. StorePostCustomersCustomerAcceptClaimReq: type: object description: The details necessary to grant order access. @@ -14987,9 +13467,7 @@ components: - token properties: token: - description: >- - The claim token generated by previous request to the Claim Order API - Route. + description: The claim token generated by previous request to the Claim Order API Route. type: string StorePostCustomersCustomerAddressesAddressReq: anyOf: @@ -15052,11 +13530,8 @@ components: description: Additional custom data about the customer. type: object externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute StorePostCustomersReq: type: object description: The details of the customer to create. @@ -15126,9 +13601,7 @@ components: - sessions properties: sessions: - description: >- - Payment sessions related to the Payment Collection. Existing - sessions that are not added in this array will be deleted. + description: Payment sessions related to the Payment Collection. Existing sessions that are not added in this array will be deleted. type: array items: type: object @@ -15144,9 +13617,7 @@ components: description: The payment amount session_id: type: string - description: >- - The ID of the Payment Session to be updated. If no ID is - provided, a new payment session is created. + description: The ID of the Payment Session to be updated. If no ID is provided, a new payment session is created. StorePostReturnsReq: type: object description: The details of the return to create. @@ -15173,26 +13644,20 @@ components: description: The quantity to return. type: integer reason_id: - description: >- - The ID of the return reason. Return reasons can be retrieved - from the List Return Reasons API Route. + description: The ID of the return reason. Return reasons can be retrieved from the List Return Reasons API Route. type: string note: description: A note to add to the item returned. type: string return_shipping: - description: >- - The return shipping method used to return the items. If provided, a - fulfillment is automatically created for the return. + description: The return shipping method used to return the items. If provided, a fulfillment is automatically created for the return. type: object required: - option_id properties: option_id: type: string - description: >- - The ID of the Shipping Option to create the Shipping Method - from. + description: The ID of the Shipping Option to create the Shipping Method from. StorePostSearchReq: type: object properties: @@ -15215,9 +13680,7 @@ components: - hits properties: hits: - description: >- - Array of search results. The format of the items depends on the - search engine installed on the Medusa backend. + description: Array of search results. The format of the items depends on the search engine installed on the Medusa backend. type: array - type: object StorePostSwapsReq: @@ -15247,9 +13710,7 @@ components: description: The quantity to return. type: integer reason_id: - description: >- - The ID of the reason of this return. Return reasons can be - retrieved from the List Return Reasons API Route. + description: The ID of the reason of this return. Return reasons can be retrieved from the List Return Reasons API Route. type: string note: description: The note to add to the item being swapped. @@ -15313,9 +13774,7 @@ components: description: The total number of items available offset: type: integer - description: >- - The number of product types skipped when retrieving the product - types. + description: The number of product types skipped when retrieving the product types. limit: type: integer description: The number of items per page @@ -15548,12 +14007,7 @@ components: $ref: '#/components/schemas/PricedVariant' Swap: title: Swap - description: >- - A swap can be created when a Customer wishes to exchange Products that - they have purchased with different Products. It consists of a Return of - previously purchased Products and a Fulfillment of new Products. It also - includes information on any additional payment or refund required based - on the difference between the exchanged products. + description: A swap can be created when a Customer wishes to exchange Products that they have purchased with different Products. It consists of a Return of previously purchased Products and a Fulfillment of new Products. It also includes information on any additional payment or refund required based on the difference between the exchanged products. type: object required: - allow_backorder @@ -15589,9 +14043,7 @@ components: - requires_action example: not_fulfilled payment_status: - description: >- - The status of the Payment of the Swap. The payment may either refer - to the refund of an amount or the authorization of a new amount. + description: The status of the Payment of the Swap. The payment may either refer to the refund of an amount or the authorization of a new amount. type: string enum: - not_paid @@ -15614,63 +14066,44 @@ components: nullable: true type: object additional_items: - description: >- - The details of the new products to send to the customer, represented - as line items. + description: The details of the new products to send to the customer, represented as line items. type: array x-expandable: additional_items items: $ref: '#/components/schemas/LineItem' return_order: - description: >- - The details of the return that belongs to the swap, which holds the - details on the items being returned. + description: The details of the return that belongs to the swap, which holds the details on the items being returned. x-expandable: return_order nullable: true type: object fulfillments: - description: >- - The details of the fulfillments that are used to send the new items - to the customer. + description: The details of the fulfillments that are used to send the new items to the customer. x-expandable: fulfillments type: array items: type: object payment: - description: >- - The details of the additional payment authorized by the customer - when `difference_due` is positive. + description: The details of the additional payment authorized by the customer when `difference_due` is positive. x-expandable: payment nullable: true type: object difference_due: - description: >- - The difference amount between the order’s original total and the new - total imposed by the swap. If its value is negative, a refund must - be issues to the customer. If it's positive, additional payment must - be authorized by the customer. Otherwise, no payment processing is - required. + description: The difference amount between the order’s original total and the new total imposed by the swap. If its value is negative, a refund must be issues to the customer. If it's positive, additional payment must be authorized by the customer. Otherwise, no payment processing is required. nullable: true type: integer example: 0 shipping_address_id: - description: >- - The Address to send the new Line Items to - in most cases this will - be the same as the shipping address on the Order. + description: The Address to send the new Line Items to - in most cases this will be the same as the shipping address on the Order. nullable: true type: string example: addr_01G8ZH853YPY9B94857DY91YGW shipping_address: - description: >- - The details of the shipping address that the new items should be - sent to. + description: The details of the shipping address that the new items should be sent to. x-expandable: shipping_address nullable: true $ref: '#/components/schemas/Address' shipping_methods: - description: >- - The details of the shipping methods used to fulfill the additional - items purchased. + description: The details of the shipping methods used to fulfill the additional items purchased. type: array x-expandable: shipping_methods items: @@ -15686,9 +14119,7 @@ components: nullable: true type: object confirmed_at: - description: >- - The date with timezone at which the Swap was confirmed by the - Customer. + description: The date with timezone at which the Swap was confirmed by the Customer. nullable: true type: string format: date-time @@ -15707,9 +14138,7 @@ components: type: boolean default: false idempotency_key: - description: >- - Randomly generated key used to continue the completion of the swap - in case of failure. + description: Randomly generated key used to continue the completion of the swap in case of failure. nullable: true type: string externalDocs: @@ -15735,11 +14164,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute TaxLine: title: Tax Line description: A tax line represents the taxes amount applied to a line item. @@ -15785,17 +14211,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute TaxProvider: title: Tax Provider - description: >- - A tax provider represents a tax service installed in the Medusa backend, - either through a plugin or backend customizations. It holds the tax - service's installation status. + description: A tax provider represents a tax service installed in the Medusa backend, either through a plugin or backend customizations. It holds the tax service's installation status. type: object required: - id @@ -15806,17 +14226,12 @@ components: type: string example: manual is_installed: - description: >- - Whether the tax service is installed in the current version. If a - tax service is no longer installed, the `is_installed` attribute is - set to `false`. + description: Whether the tax service is installed in the current version. If a tax service is no longer installed, the `is_installed` attribute is set to `false`. type: boolean default: true TaxRate: title: Tax Rate - description: >- - A Tax Rate can be used to define a custom rate to charge on specified - products, product types, and shipping options within a given region. + description: A Tax Rate can be used to define a custom rate to charge on specified products, product types, and shipping options within a given region. type: object required: - code @@ -15900,19 +14315,11 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute TrackingLink: title: Tracking Link - description: >- - A tracking link holds information about tracking numbers for a - Fulfillment. Tracking Links can optionally contain a URL that can be - visited to see the status of the shipment. Typically, the tracking link - is provided from the third-party service integrated through the used - fulfillment provider. + description: A tracking link holds information about tracking numbers for a Fulfillment. Tracking Links can optionally contain a URL that can be visited to see the status of the shipment. Typically, the tracking link is provided from the third-party service integrated through the used fulfillment provider. type: object required: - created_at @@ -15948,9 +14355,7 @@ components: nullable: true type: object idempotency_key: - description: >- - Randomly generated key used to continue the completion of a process - in case of failure. + description: Randomly generated key used to continue the completion of a process in case of failure. nullable: true type: string externalDocs: @@ -15976,11 +14381,8 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute UpdateStockLocationInput: title: Update Stock Location Input description: Represents the Input to update a Stock Location @@ -16069,8 +14471,5 @@ components: example: car: white externalDocs: - description: >- - Learn about the metadata attribute, and how to delete and update - it. - url: >- - https://docs.medusajs.com/development/entities/overview#metadata-attribute + description: Learn about the metadata attribute, and how to delete and update it. + url: https://docs.medusajs.com/development/entities/overview#metadata-attribute diff --git a/www/apps/api-reference/specs/store/openapi.yaml b/www/apps/api-reference/specs/store/openapi.yaml index 0701018e89..3811f07124 100644 --- a/www/apps/api-reference/specs/store/openapi.yaml +++ b/www/apps/api-reference/specs/store/openapi.yaml @@ -5,6 +5,9 @@ info: license: name: MIT url: https://github.com/medusajs/medusa/blob/master/LICENSE +servers: + - url: http://localhost:9000 + - url: https://api.medusa-commerce.com tags: - name: Auth description: > @@ -149,9 +152,6 @@ tags: externalDocs: description: How to create a swap in a storefront url: https://docs.medusajs.com/modules/orders/storefront/create-swap -servers: - - url: http://localhost:9000 - - url: https://api.medusa-commerce.com paths: /store/auth: $ref: paths/store_auth.yaml diff --git a/www/apps/api-reference/specs/store/paths/store_carts.yaml b/www/apps/api-reference/specs/store/paths/store_carts.yaml index c876671fbd..fe36954e14 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts.yaml @@ -27,7 +27,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts/postundefined + $ref: ../code_samples/tsx/store_carts/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}.yaml index dc67f514ba..f64f7415c8 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}.yaml @@ -19,7 +19,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts_{id}/getundefined + $ref: ../code_samples/tsx/store_carts_{id}/get.tsx - lang: Shell label: cURL source: @@ -72,7 +72,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts_{id}/postundefined + $ref: ../code_samples/tsx/store_carts_{id}/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_complete.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_complete.yaml index d5e19567d3..999000b60c 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_complete.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_complete.yaml @@ -37,7 +37,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts_{id}_complete/postundefined + $ref: ../code_samples/tsx/store_carts_{id}_complete/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items.yaml index efa934965b..d3c6533c7d 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items.yaml @@ -24,7 +24,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts_{id}_line-items/postundefined + $ref: ../code_samples/tsx/store_carts_{id}_line-items/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items_{line_id}.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items_{line_id}.yaml index b47e280b42..1478eb81ea 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items_{line_id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_line-items_{line_id}.yaml @@ -31,8 +31,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/store_carts_{id}_line-items_{line_id}/postundefined + $ref: ../code_samples/tsx/store_carts_{id}_line-items_{line_id}/post.tsx - lang: Shell label: cURL source: @@ -86,8 +85,7 @@ delete: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/store_carts_{id}_line-items_{line_id}/deleteundefined + $ref: ../code_samples/tsx/store_carts_{id}_line-items_{line_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-session.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-session.yaml index 577f3381a3..3b2bbff0dd 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-session.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-session.yaml @@ -27,7 +27,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts_{id}_payment-session/postundefined + $ref: ../code_samples/tsx/store_carts_{id}_payment-session/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions.yaml index 55d64a93db..73aaef6c07 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions.yaml @@ -23,7 +23,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts_{id}_payment-sessions/postundefined + $ref: ../code_samples/tsx/store_carts_{id}_payment-sessions/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}.yaml index f28d465963..a1c3285a73 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}.yaml @@ -35,7 +35,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/postundefined + ../code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/post.tsx - lang: Shell label: cURL source: @@ -93,7 +93,7 @@ delete: label: Medusa React source: $ref: >- - ../code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/deleteundefined + ../code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}/delete.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}_refresh.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}_refresh.yaml index b2ce470828..d7090b15dc 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}_refresh.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_payment-sessions_{provider_id}_refresh.yaml @@ -31,7 +31,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}_refresh/postundefined + ../code_samples/tsx/store_carts_{id}_payment-sessions_{provider_id}_refresh/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_carts_{id}_shipping-methods.yaml b/www/apps/api-reference/specs/store/paths/store_carts_{id}_shipping-methods.yaml index ce8d8093ba..e3fee76747 100644 --- a/www/apps/api-reference/specs/store/paths/store_carts_{id}_shipping-methods.yaml +++ b/www/apps/api-reference/specs/store/paths/store_carts_{id}_shipping-methods.yaml @@ -26,7 +26,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_carts_{id}_shipping-methods/postundefined + $ref: ../code_samples/tsx/store_carts_{id}_shipping-methods/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_collections.yaml b/www/apps/api-reference/specs/store/paths/store_collections.yaml index b7d013a7fb..e798d10141 100644 --- a/www/apps/api-reference/specs/store/paths/store_collections.yaml +++ b/www/apps/api-reference/specs/store/paths/store_collections.yaml @@ -84,7 +84,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_collections/getundefined + $ref: ../code_samples/tsx/store_collections/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_collections_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_collections_{id}.yaml index deae8fc2e2..f417830db6 100644 --- a/www/apps/api-reference/specs/store/paths/store_collections_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_collections_{id}.yaml @@ -19,7 +19,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_collections_{id}/getundefined + $ref: ../code_samples/tsx/store_collections_{id}/get.tsx - lang: Shell label: cURL source: 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 243ecc32af..4066cea147 100644 --- a/www/apps/api-reference/specs/store/paths/store_customers.yaml +++ b/www/apps/api-reference/specs/store/paths/store_customers.yaml @@ -22,7 +22,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_customers/postundefined + $ref: ../code_samples/tsx/store_customers/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_customers_me.yaml b/www/apps/api-reference/specs/store/paths/store_customers_me.yaml index d7d83fe2d8..c47ff60add 100644 --- a/www/apps/api-reference/specs/store/paths/store_customers_me.yaml +++ b/www/apps/api-reference/specs/store/paths/store_customers_me.yaml @@ -13,7 +13,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_customers_me/getundefined + $ref: ../code_samples/tsx/store_customers_me/get.tsx - lang: Shell label: cURL source: @@ -62,7 +62,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_customers_me/postundefined + $ref: ../code_samples/tsx/store_customers_me/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_customers_me_orders.yaml b/www/apps/api-reference/specs/store/paths/store_customers_me_orders.yaml index c437a28621..5939bc14b4 100644 --- a/www/apps/api-reference/specs/store/paths/store_customers_me_orders.yaml +++ b/www/apps/api-reference/specs/store/paths/store_customers_me_orders.yaml @@ -207,7 +207,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_customers_me_orders/getundefined + $ref: ../code_samples/tsx/store_customers_me_orders/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_gift-cards_{code}.yaml b/www/apps/api-reference/specs/store/paths/store_gift-cards_{code}.yaml index c3fa88a3de..bac81d521a 100644 --- a/www/apps/api-reference/specs/store/paths/store_gift-cards_{code}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_gift-cards_{code}.yaml @@ -19,7 +19,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_gift-cards_{code}/getundefined + $ref: ../code_samples/tsx/store_gift-cards_{code}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_order-edits_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_order-edits_{id}.yaml index 3abdb3c8fd..42f6ca79d8 100644 --- a/www/apps/api-reference/specs/store/paths/store_order-edits_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_order-edits_{id}.yaml @@ -19,7 +19,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_order-edits_{id}/getundefined + $ref: ../code_samples/tsx/store_order-edits_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_complete.yaml b/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_complete.yaml index d56050141f..fb014d017c 100644 --- a/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_complete.yaml +++ b/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_complete.yaml @@ -25,7 +25,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_order-edits_{id}_complete/postundefined + $ref: ../code_samples/tsx/store_order-edits_{id}_complete/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_decline.yaml b/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_decline.yaml index 78d018ed8e..77758822dc 100644 --- a/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_decline.yaml +++ b/www/apps/api-reference/specs/store/paths/store_order-edits_{id}_decline.yaml @@ -24,7 +24,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_order-edits_{id}_decline/postundefined + $ref: ../code_samples/tsx/store_order-edits_{id}_decline/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_orders.yaml b/www/apps/api-reference/specs/store/paths/store_orders.yaml index 6dea58f029..ac43935045 100644 --- a/www/apps/api-reference/specs/store/paths/store_orders.yaml +++ b/www/apps/api-reference/specs/store/paths/store_orders.yaml @@ -52,7 +52,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_orders/getundefined + $ref: ../code_samples/tsx/store_orders/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_orders_batch_customer_token.yaml b/www/apps/api-reference/specs/store/paths/store_orders_batch_customer_token.yaml index 96fc1760c4..93e26c1aa0 100644 --- a/www/apps/api-reference/specs/store/paths/store_orders_batch_customer_token.yaml +++ b/www/apps/api-reference/specs/store/paths/store_orders_batch_customer_token.yaml @@ -28,7 +28,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_orders_batch_customer_token/postundefined + $ref: ../code_samples/tsx/store_orders_batch_customer_token/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_orders_cart_{cart_id}.yaml b/www/apps/api-reference/specs/store/paths/store_orders_cart_{cart_id}.yaml index 8de225126f..9adc1e3528 100644 --- a/www/apps/api-reference/specs/store/paths/store_orders_cart_{cart_id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_orders_cart_{cart_id}.yaml @@ -21,7 +21,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_orders_cart_{cart_id}/getundefined + $ref: ../code_samples/tsx/store_orders_cart_{cart_id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_orders_customer_confirm.yaml b/www/apps/api-reference/specs/store/paths/store_orders_customer_confirm.yaml index 47ae9bbc0d..c6eda5bd8a 100644 --- a/www/apps/api-reference/specs/store/paths/store_orders_customer_confirm.yaml +++ b/www/apps/api-reference/specs/store/paths/store_orders_customer_confirm.yaml @@ -22,7 +22,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_orders_customer_confirm/postundefined + $ref: ../code_samples/tsx/store_orders_customer_confirm/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_orders_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_orders_{id}.yaml index 8620f73831..b79018cb51 100644 --- a/www/apps/api-reference/specs/store/paths/store_orders_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_orders_{id}.yaml @@ -29,7 +29,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_orders_{id}/getundefined + $ref: ../code_samples/tsx/store_orders_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}.yaml index fdf679fad9..7c117d86c9 100644 --- a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}.yaml @@ -35,7 +35,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_payment-collections_{id}/getundefined + $ref: ../code_samples/tsx/store_payment-collections_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions.yaml b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions.yaml index cb639711d6..9bcb2e1e8a 100644 --- a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions.yaml +++ b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions.yaml @@ -26,8 +26,7 @@ post: - lang: tsx label: Medusa React source: - $ref: >- - ../code_samples/tsx/store_payment-collections_{id}_sessions/postundefined + $ref: ../code_samples/tsx/store_payment-collections_{id}_sessions/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch.yaml b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch.yaml index 5cb5db9784..e8896b1bc9 100644 --- a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch.yaml +++ b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch.yaml @@ -31,7 +31,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/store_payment-collections_{id}_sessions_batch/postundefined + ../code_samples/tsx/store_payment-collections_{id}_sessions_batch/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch_authorize.yaml b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch_authorize.yaml index 44246966d8..028af4b2ed 100644 --- a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch_authorize.yaml +++ b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_batch_authorize.yaml @@ -28,7 +28,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/store_payment-collections_{id}_sessions_batch_authorize/postundefined + ../code_samples/tsx/store_payment-collections_{id}_sessions_batch_authorize/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}.yaml b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}.yaml index bb13dd01d3..35e1714798 100644 --- a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}.yaml @@ -30,7 +30,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}/postundefined + ../code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}_authorize.yaml b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}_authorize.yaml index 027073342e..f55c6942e3 100644 --- a/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}_authorize.yaml +++ b/www/apps/api-reference/specs/store/paths/store_payment-collections_{id}_sessions_{session_id}_authorize.yaml @@ -28,7 +28,7 @@ post: label: Medusa React source: $ref: >- - ../code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}_authorize/postundefined + ../code_samples/tsx/store_payment-collections_{id}_sessions_{session_id}_authorize/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_product-categories.yaml b/www/apps/api-reference/specs/store/paths/store_product-categories.yaml index dfa55d05ff..db7fe719f7 100644 --- a/www/apps/api-reference/specs/store/paths/store_product-categories.yaml +++ b/www/apps/api-reference/specs/store/paths/store_product-categories.yaml @@ -73,7 +73,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_product-categories/getundefined + $ref: ../code_samples/tsx/store_product-categories/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_product-categories_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_product-categories_{id}.yaml index d6c68744f6..97b4ef6609 100644 --- a/www/apps/api-reference/specs/store/paths/store_product-categories_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_product-categories_{id}.yaml @@ -35,7 +35,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_product-categories_{id}/getundefined + $ref: ../code_samples/tsx/store_product-categories_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_product-tags.yaml b/www/apps/api-reference/specs/store/paths/store_product-tags.yaml index fe223363b3..64981bfa3b 100644 --- a/www/apps/api-reference/specs/store/paths/store_product-tags.yaml +++ b/www/apps/api-reference/specs/store/paths/store_product-tags.yaml @@ -108,7 +108,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_product-tags/getundefined + $ref: ../code_samples/tsx/store_product-tags/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_product-types.yaml b/www/apps/api-reference/specs/store/paths/store_product-types.yaml index c2c4464279..116d462d60 100644 --- a/www/apps/api-reference/specs/store/paths/store_product-types.yaml +++ b/www/apps/api-reference/specs/store/paths/store_product-types.yaml @@ -109,7 +109,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_product-types/getundefined + $ref: ../code_samples/tsx/store_product-types/get.tsx - lang: Shell label: cURL source: 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 1dea7e73fb..4ba195f147 100644 --- a/www/apps/api-reference/specs/store/paths/store_products.yaml +++ b/www/apps/api-reference/specs/store/paths/store_products.yaml @@ -240,7 +240,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_products/getundefined + $ref: ../code_samples/tsx/store_products/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_products_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_products_{id}.yaml index 1bea1f59af..d86103a15f 100644 --- a/www/apps/api-reference/specs/store/paths/store_products_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_products_{id}.yaml @@ -79,7 +79,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_products_{id}/getundefined + $ref: ../code_samples/tsx/store_products_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_regions.yaml b/www/apps/api-reference/specs/store/paths/store_regions.yaml index 9b7281db06..bf97482e18 100644 --- a/www/apps/api-reference/specs/store/paths/store_regions.yaml +++ b/www/apps/api-reference/specs/store/paths/store_regions.yaml @@ -77,7 +77,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_regions/getundefined + $ref: ../code_samples/tsx/store_regions/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_regions_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_regions_{id}.yaml index 0685fe0d2e..67ad39ae69 100644 --- a/www/apps/api-reference/specs/store/paths/store_regions_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_regions_{id}.yaml @@ -19,7 +19,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_regions_{id}/getundefined + $ref: ../code_samples/tsx/store_regions_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_return-reasons.yaml b/www/apps/api-reference/specs/store/paths/store_return-reasons.yaml index ac732ae6b5..aa5801b6d4 100644 --- a/www/apps/api-reference/specs/store/paths/store_return-reasons.yaml +++ b/www/apps/api-reference/specs/store/paths/store_return-reasons.yaml @@ -14,7 +14,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_return-reasons/getundefined + $ref: ../code_samples/tsx/store_return-reasons/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_return-reasons_{id}.yaml b/www/apps/api-reference/specs/store/paths/store_return-reasons_{id}.yaml index 21bd015421..fae3979347 100644 --- a/www/apps/api-reference/specs/store/paths/store_return-reasons_{id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_return-reasons_{id}.yaml @@ -19,7 +19,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_return-reasons_{id}/getundefined + $ref: ../code_samples/tsx/store_return-reasons_{id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_returns.yaml b/www/apps/api-reference/specs/store/paths/store_returns.yaml index bab47098a1..7f8aca95a2 100644 --- a/www/apps/api-reference/specs/store/paths/store_returns.yaml +++ b/www/apps/api-reference/specs/store/paths/store_returns.yaml @@ -22,7 +22,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_returns/postundefined + $ref: ../code_samples/tsx/store_returns/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_shipping-options.yaml b/www/apps/api-reference/specs/store/paths/store_shipping-options.yaml index 46c0a96171..502166c2cc 100644 --- a/www/apps/api-reference/specs/store/paths/store_shipping-options.yaml +++ b/www/apps/api-reference/specs/store/paths/store_shipping-options.yaml @@ -36,7 +36,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_shipping-options/getundefined + $ref: ../code_samples/tsx/store_shipping-options/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_shipping-options_{cart_id}.yaml b/www/apps/api-reference/specs/store/paths/store_shipping-options_{cart_id}.yaml index fdae31e141..ad69d42ff2 100644 --- a/www/apps/api-reference/specs/store/paths/store_shipping-options_{cart_id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_shipping-options_{cart_id}.yaml @@ -23,7 +23,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_shipping-options_{cart_id}/getundefined + $ref: ../code_samples/tsx/store_shipping-options_{cart_id}/get.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_swaps.yaml b/www/apps/api-reference/specs/store/paths/store_swaps.yaml index 1684c22a37..b069f049f5 100644 --- a/www/apps/api-reference/specs/store/paths/store_swaps.yaml +++ b/www/apps/api-reference/specs/store/paths/store_swaps.yaml @@ -36,7 +36,7 @@ post: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_swaps/postundefined + $ref: ../code_samples/tsx/store_swaps/post.tsx - lang: Shell label: cURL source: diff --git a/www/apps/api-reference/specs/store/paths/store_swaps_{cart_id}.yaml b/www/apps/api-reference/specs/store/paths/store_swaps_{cart_id}.yaml index b8071c2112..a0054ac2b5 100644 --- a/www/apps/api-reference/specs/store/paths/store_swaps_{cart_id}.yaml +++ b/www/apps/api-reference/specs/store/paths/store_swaps_{cart_id}.yaml @@ -19,7 +19,7 @@ get: - lang: tsx label: Medusa React source: - $ref: ../code_samples/tsx/store_swaps_{cart_id}/getundefined + $ref: ../code_samples/tsx/store_swaps_{cart_id}/get.tsx - lang: Shell label: cURL source: