chore(docs): Generated API Reference (#4706)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com> Co-authored-by: Shahed Nasser <shahednasser@gmail.com>
This commit is contained in:
committed by
GitHub
parent
efdea04963
commit
658339767b
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetAuth
|
||||
summary: Get Current Customer
|
||||
description: Gets the currently logged in Customer.
|
||||
description: Retrieve the currently logged in Customer's details.
|
||||
x-authenticated: true
|
||||
x-codegen:
|
||||
method: getSession
|
||||
@@ -41,8 +41,10 @@ post:
|
||||
operationId: PostAuth
|
||||
summary: Customer Login
|
||||
description: >-
|
||||
Logs a Customer in and authorizes them to view their details. Successful
|
||||
authentication will set a session cookie in the Customer's browser.
|
||||
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:
|
||||
@@ -83,7 +85,7 @@ post:
|
||||
delete:
|
||||
operationId: DeleteAuth
|
||||
summary: Customer Log out
|
||||
description: Destroys a Customer's authenticated session.
|
||||
description: Delete the current session for the logged in customer.
|
||||
x-authenticated: true
|
||||
x-codegen:
|
||||
method: deleteSession
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetAuthEmail
|
||||
summary: Check if email exists
|
||||
description: Checks if a Customer with the given email has signed up.
|
||||
summary: Check if Email Exists
|
||||
description: Check if there's a customer already registered with the provided email.
|
||||
parameters:
|
||||
- in: path
|
||||
name: email
|
||||
@@ -9,7 +9,7 @@ get:
|
||||
type: string
|
||||
format: email
|
||||
required: true
|
||||
description: The email to check if exists.
|
||||
description: The email to check.
|
||||
x-codegen:
|
||||
method: exists
|
||||
x-codeSamples:
|
||||
|
||||
@@ -1,11 +1,17 @@
|
||||
post:
|
||||
summary: Create a Cart
|
||||
operationId: PostCart
|
||||
description: >-
|
||||
Creates a Cart within the given region and with the initial items. If no
|
||||
`region_id` is provided the cart will be associated with the first Region
|
||||
available. If no items are provided the cart will be empty after creation.
|
||||
If a user is logged in the cart's customer id and email will be set.
|
||||
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
|
||||
|
||||
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, the cart's customer ID and email will
|
||||
automatically be set.
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
get:
|
||||
operationId: GetCartsCart
|
||||
summary: Get a Cart
|
||||
description: Retrieves a Cart.
|
||||
description: Retrieve a Cart's details. This includes recalculating its totals.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
@@ -42,12 +42,15 @@ get:
|
||||
post:
|
||||
operationId: PostCartsCart
|
||||
summary: Update a Cart
|
||||
description: Updates 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.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
requestBody:
|
||||
|
||||
@@ -1,18 +1,30 @@
|
||||
post:
|
||||
summary: Complete a Cart
|
||||
operationId: PostCartsCartComplete
|
||||
description: >-
|
||||
Completes a cart. The following steps will be performed. Payment
|
||||
authorization is attempted and if more work is required, we simply return
|
||||
the cart for further updates. If payment is authorized and order is not yet
|
||||
created, we make sure to do so. The completion of a cart can be performed
|
||||
idempotently with a provided header `Idempotency-Key`. If not provided, we
|
||||
will generate one for the request.
|
||||
description: >
|
||||
Complete a cart and place an order or create a swap, based on what the cart
|
||||
is created for. 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
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The Cart id.
|
||||
description: The Cart ID.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
@@ -31,10 +43,12 @@ post:
|
||||
responses:
|
||||
'200':
|
||||
description: >-
|
||||
If a cart was successfully authorized, but requires further action from
|
||||
the user the response body will contain the cart with an updated payment
|
||||
session. If the Cart was successfully completed the response body will
|
||||
contain the newly created Order.
|
||||
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:
|
||||
|
||||
@@ -1,18 +1,21 @@
|
||||
delete:
|
||||
operationId: DeleteCartsCartDiscountsDiscount
|
||||
description: Removes a Discount from a Cart.
|
||||
summary: Remove Discount
|
||||
description: >-
|
||||
Remove a Discount from a Cart. This only removes the application of the
|
||||
discount, and not completely delete it. The totals will be re-calculated and
|
||||
the payment sessions will be refreshed after the removal.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
- in: path
|
||||
name: code
|
||||
required: true
|
||||
description: The unique Discount code.
|
||||
description: The unique discount code.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
post:
|
||||
operationId: PostCartsCartLineItemsItem
|
||||
summary: Update a Line Item
|
||||
description: Updates a Line Item if the desired quantity can be fulfilled.
|
||||
description: Update a line item's quantity.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
- in: path
|
||||
name: line_id
|
||||
required: true
|
||||
description: The id of the Line Item.
|
||||
description: The ID of the Line Item.
|
||||
schema:
|
||||
type: string
|
||||
requestBody:
|
||||
@@ -54,18 +54,20 @@ post:
|
||||
delete:
|
||||
operationId: DeleteCartsCartLineItemsItem
|
||||
summary: Delete a Line Item
|
||||
description: Removes a Line Item from a Cart.
|
||||
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
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
- in: path
|
||||
name: line_id
|
||||
required: true
|
||||
description: The id of the Line Item.
|
||||
description: The ID of the Line Item.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -2,8 +2,9 @@ post:
|
||||
operationId: PostCartsCartPaymentSession
|
||||
summary: Select a Payment Session
|
||||
description: >-
|
||||
Selects a Payment Session as the session intended to be used towards the
|
||||
completion of the Cart.
|
||||
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
|
||||
|
||||
@@ -2,13 +2,15 @@ post:
|
||||
operationId: PostCartsCartPaymentSessions
|
||||
summary: Create Payment Sessions
|
||||
description: >-
|
||||
Creates Payment Sessions for each of the available Payment Providers in the
|
||||
Cart's Region.
|
||||
Create Payment Sessions for each of the available Payment Providers in the
|
||||
Cart's Region. If there only one payment session is 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
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,18 +1,21 @@
|
||||
post:
|
||||
operationId: PostCartsCartPaymentSessionUpdate
|
||||
summary: Update a Payment Session
|
||||
description: Updates a Payment Session with additional data.
|
||||
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
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
- in: path
|
||||
name: provider_id
|
||||
required: true
|
||||
description: The id of the payment provider.
|
||||
description: The ID of the payment provider.
|
||||
schema:
|
||||
type: string
|
||||
requestBody:
|
||||
@@ -55,19 +58,21 @@ post:
|
||||
delete:
|
||||
operationId: DeleteCartsCartPaymentSessionsSession
|
||||
summary: Delete a Payment Session
|
||||
description: Deletes a Payment Session on a Cart. May be useful if a payment has failed.
|
||||
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
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
- in: path
|
||||
name: provider_id
|
||||
required: true
|
||||
description: >-
|
||||
The id of the Payment Provider used to create the Payment Session to be
|
||||
The ID of the Payment Provider used to create the Payment Session to be
|
||||
deleted.
|
||||
schema:
|
||||
type: string
|
||||
|
||||
@@ -2,20 +2,20 @@ post:
|
||||
operationId: PostCartsCartPaymentSessionsSession
|
||||
summary: Refresh a Payment Session
|
||||
description: >-
|
||||
Refreshes a Payment Session to ensure that it is in sync with the Cart -
|
||||
this is usually not necessary.
|
||||
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
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
- in: path
|
||||
name: provider_id
|
||||
required: true
|
||||
description: >-
|
||||
The id of the Payment Provider that created the Payment Session to be
|
||||
The ID of the Payment Provider that created the Payment Session to be
|
||||
refreshed.
|
||||
schema:
|
||||
type: string
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
post:
|
||||
operationId: PostCartsCartShippingMethod
|
||||
description: Adds a Shipping Method to the Cart.
|
||||
summary: Add a Shipping Method
|
||||
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.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
|
||||
@@ -1,9 +1,14 @@
|
||||
post:
|
||||
summary: Calculate Cart Taxes
|
||||
operationId: PostCartsCartTaxes
|
||||
summary: Calculate Cart Taxes
|
||||
description: >-
|
||||
Calculates taxes for a cart. Depending on the cart's region this may involve
|
||||
making 3rd party API calls to a Tax Provider service.
|
||||
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
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
|
||||
@@ -1,19 +1,22 @@
|
||||
get:
|
||||
operationId: GetCollections
|
||||
summary: List Collections
|
||||
description: Retrieve a list of Product Collection.
|
||||
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 collections to skip before starting to collect the
|
||||
collections set
|
||||
The number of product collections to skip when retrieving the product
|
||||
collections.
|
||||
schema:
|
||||
type: integer
|
||||
default: 0
|
||||
- in: query
|
||||
name: limit
|
||||
description: The number of collections to return
|
||||
description: Limit the number of product collections returned.
|
||||
schema:
|
||||
type: integer
|
||||
default: 10
|
||||
@@ -21,14 +24,14 @@ get:
|
||||
name: handle
|
||||
style: form
|
||||
explode: false
|
||||
description: Filter by the collection handle
|
||||
description: Filter by handles
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
- in: query
|
||||
name: created_at
|
||||
description: Date comparison for when resulting collections were created.
|
||||
description: Filter by a creation date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -50,7 +53,7 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: updated_at
|
||||
description: Date comparison for when resulting collections were updated.
|
||||
description: Filter by an update date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -83,7 +86,7 @@ get:
|
||||
source:
|
||||
$ref: ../code_samples/Shell/store_collections/get.sh
|
||||
tags:
|
||||
- Collections
|
||||
- Product Collections
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetCollectionsCollection
|
||||
summary: Get a Collection
|
||||
description: Retrieves a Product Collection.
|
||||
description: Retrieve a Product Collection's details.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
@@ -21,7 +21,7 @@ get:
|
||||
source:
|
||||
$ref: ../code_samples/Shell/store_collections_{id}/get.sh
|
||||
tags:
|
||||
- Collections
|
||||
- Product Collections
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
|
||||
@@ -1,7 +1,12 @@
|
||||
post:
|
||||
operationId: PostCustomers
|
||||
summary: Create a Customer
|
||||
description: Creates a Customer account.
|
||||
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:
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
get:
|
||||
operationId: GetCustomersCustomer
|
||||
summary: Get a Customer
|
||||
description: >-
|
||||
Retrieves a Customer - the Customer must be logged in to retrieve their
|
||||
details.
|
||||
description: Retrieve the logged-in Customer's details.
|
||||
x-authenticated: true
|
||||
x-codegen:
|
||||
method: retrieve
|
||||
@@ -42,7 +40,7 @@ get:
|
||||
post:
|
||||
operationId: PostCustomersCustomer
|
||||
summary: Update Customer
|
||||
description: Updates a Customer's saved details.
|
||||
description: Update the logged-in customer's details.
|
||||
x-authenticated: true
|
||||
requestBody:
|
||||
content:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
post:
|
||||
operationId: PostCustomersCustomerAddresses
|
||||
summary: Add a Shipping Address
|
||||
description: Adds a Shipping Address to a Customer's saved addresses.
|
||||
description: Add a Shipping Address to a Customer's saved addresses.
|
||||
x-authenticated: true
|
||||
requestBody:
|
||||
content:
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
post:
|
||||
operationId: PostCustomersCustomerAddressesAddress
|
||||
summary: Update a Shipping Address
|
||||
description: Updates a Customer's saved Shipping Address.
|
||||
description: Update the logged-in customer's saved Shipping Address's details.
|
||||
x-authenticated: true
|
||||
parameters:
|
||||
- in: path
|
||||
name: address_id
|
||||
required: true
|
||||
description: The id of the Address to update.
|
||||
description: The ID of the Address.
|
||||
schema:
|
||||
type: string
|
||||
requestBody:
|
||||
@@ -55,7 +55,7 @@ post:
|
||||
delete:
|
||||
operationId: DeleteCustomersCustomerAddressesAddress
|
||||
summary: Delete an Address
|
||||
description: Removes an Address from the Customer's saved addresses.
|
||||
description: Delete an Address from the Customer's saved addresses.
|
||||
x-authenticated: true
|
||||
parameters:
|
||||
- in: path
|
||||
|
||||
@@ -1,28 +1,40 @@
|
||||
get:
|
||||
operationId: GetCustomersCustomerOrders
|
||||
summary: List Orders
|
||||
description: Retrieves a list of a Customer's 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.
|
||||
x-authenticated: true
|
||||
parameters:
|
||||
- in: query
|
||||
name: q
|
||||
description: Query used for searching orders.
|
||||
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
|
||||
name: id
|
||||
description: Id of the order to search for.
|
||||
description: Filter by ID.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: status
|
||||
style: form
|
||||
explode: false
|
||||
description: Status to search for.
|
||||
description: Filter by status.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
enum:
|
||||
- pending
|
||||
- completed
|
||||
- archived
|
||||
- canceled
|
||||
- requires_action
|
||||
- in: query
|
||||
name: fulfillment_status
|
||||
style: form
|
||||
@@ -32,6 +44,16 @@ get:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
enum:
|
||||
- not_fulfilled
|
||||
- partially_fulfilled
|
||||
- fulfilled
|
||||
- partially_shipped
|
||||
- shipped
|
||||
- partially_returned
|
||||
- returned
|
||||
- canceled
|
||||
- requires_action
|
||||
- in: query
|
||||
name: payment_status
|
||||
style: form
|
||||
@@ -41,31 +63,39 @@ get:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
enum:
|
||||
- not_paid
|
||||
- awaiting
|
||||
- captured
|
||||
- partially_refunded
|
||||
- refunded
|
||||
- canceled
|
||||
- requires_action
|
||||
- in: query
|
||||
name: display_id
|
||||
description: Display id to search for.
|
||||
description: Filter by display ID.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: cart_id
|
||||
description: to search for.
|
||||
description: Filter by cart ID.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: email
|
||||
description: to search for.
|
||||
description: Filter by email.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: region_id
|
||||
description: to search for.
|
||||
description: Filter by region ID.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: currency_code
|
||||
style: form
|
||||
explode: false
|
||||
description: The 3 character ISO currency code to set prices based on.
|
||||
description: Filter by the 3 character ISO currency code of the order.
|
||||
schema:
|
||||
type: string
|
||||
externalDocs:
|
||||
@@ -73,12 +103,12 @@ get:
|
||||
description: See a list of codes.
|
||||
- in: query
|
||||
name: tax_rate
|
||||
description: to search for.
|
||||
description: Filter by tax rate.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: created_at
|
||||
description: Date comparison for when resulting collections were created.
|
||||
description: Filter by a creation date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -100,7 +130,7 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: updated_at
|
||||
description: Date comparison for when resulting collections were updated.
|
||||
description: Filter by an update date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -122,7 +152,7 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: canceled_at
|
||||
description: Date comparison for when resulting collections were canceled.
|
||||
description: Filter by a cancelation date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -144,28 +174,26 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: limit
|
||||
description: How many orders to return.
|
||||
description: Limit the number of orders returned.
|
||||
schema:
|
||||
type: integer
|
||||
default: 10
|
||||
- in: query
|
||||
name: offset
|
||||
description: The offset in the resulting orders.
|
||||
description: The number of orders to skip when retrieving the orders.
|
||||
schema:
|
||||
type: integer
|
||||
default: 0
|
||||
- in: query
|
||||
name: fields
|
||||
name: expand
|
||||
description: >-
|
||||
(Comma separated string) Which fields should be included in the
|
||||
resulting orders.
|
||||
Comma-separated relations that should be expanded in the returned
|
||||
orders.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: expand
|
||||
description: >-
|
||||
(Comma separated string) Which relations should be expanded in the
|
||||
resulting orders.
|
||||
name: fields
|
||||
description: Comma-separated fields that should be included in the returned orders.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,11 +1,14 @@
|
||||
get:
|
||||
operationId: GetCustomersCustomerPaymentMethods
|
||||
summary: Get Payment Methods
|
||||
summary: Get Saved Payment Methods
|
||||
description: >-
|
||||
Retrieves a list of a Customer's saved payment methods. Payment methods are
|
||||
saved with Payment Providers and it is their responsibility to fetch saved
|
||||
methods.
|
||||
Retrieve the logged-in customer's saved payment methods. This endpoint 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:
|
||||
method: listPaymentMethods
|
||||
x-codeSamples:
|
||||
|
||||
@@ -2,8 +2,13 @@ post:
|
||||
operationId: PostCustomersResetPassword
|
||||
summary: Reset Password
|
||||
description: >-
|
||||
Resets a Customer's password using a password token created by a previous
|
||||
/password-token request.
|
||||
Reset a Customer's password using a password token created by a previous
|
||||
request to the Request Password Reset endpoint. 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
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
|
||||
@@ -2,9 +2,15 @@ post:
|
||||
operationId: PostCustomersCustomerPasswordToken
|
||||
summary: Request Password Reset
|
||||
description: >-
|
||||
Creates a reset password token to be used in a subsequent /reset-password
|
||||
request. The password token should be sent out of band e.g. via email and
|
||||
will not be returned.
|
||||
Create a reset password token to be used in a subsequent Reset Password
|
||||
endpoint. 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
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetGiftCardsCode
|
||||
summary: Get Gift Card by Code
|
||||
description: Retrieves a Gift Card by its associated unique code.
|
||||
description: Retrieve a Gift Card's details by its associated unique code.
|
||||
parameters:
|
||||
- in: path
|
||||
name: code
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetOrderEditsOrderEdit
|
||||
summary: Retrieve an OrderEdit
|
||||
description: Retrieves a OrderEdit.
|
||||
summary: Retrieve an Order Edit
|
||||
description: Retrieve an Order Edit's details.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
|
||||
@@ -1,7 +1,13 @@
|
||||
post:
|
||||
operationId: PostOrderEditsOrderEditComplete
|
||||
summary: Completes an OrderEdit
|
||||
description: Completes an OrderEdit.
|
||||
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 endpoints.
|
||||
externalDocs:
|
||||
description: How to handle order edits in a storefront
|
||||
url: https://docs.medusajs.com/modules/orders/storefront/handle-order-edits
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
post:
|
||||
operationId: PostOrderEditsOrderEditDecline
|
||||
summary: Decline an OrderEdit
|
||||
description: Declines an OrderEdit.
|
||||
summary: Decline an Order Edit
|
||||
description: Decline an Order Edit. The changes are not reflected on the original order.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
|
||||
@@ -1,29 +1,31 @@
|
||||
get:
|
||||
operationId: GetOrders
|
||||
summary: Look Up an Order
|
||||
description: Look up an order using filters.
|
||||
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
|
||||
required: true
|
||||
description: The display id given to the Order.
|
||||
description: Filter by ID.
|
||||
schema:
|
||||
type: number
|
||||
- in: query
|
||||
name: fields
|
||||
description: (Comma separated) Which fields should be included in the result.
|
||||
description: Comma-separated fields that should be expanded in the returned order.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: expand
|
||||
description: (Comma separated) Which fields should be expanded in the result.
|
||||
description: Comma-separated relations that should be expanded in the returned order.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: email
|
||||
style: form
|
||||
explode: false
|
||||
description: The email associated with this order.
|
||||
description: Filter by email.
|
||||
required: true
|
||||
schema:
|
||||
type: string
|
||||
@@ -32,7 +34,7 @@ get:
|
||||
name: shipping_address
|
||||
style: form
|
||||
explode: false
|
||||
description: The shipping address associated with this order.
|
||||
description: Filter by the shipping address's postal code.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
|
||||
@@ -1,9 +1,18 @@
|
||||
post:
|
||||
operationId: PostOrdersCustomerOrderClaim
|
||||
summary: Claim an Order
|
||||
summary: Claim Order
|
||||
description: >-
|
||||
Sends an email to emails registered to orders provided with link to transfer
|
||||
order ownership
|
||||
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
|
||||
endpoint Verify Order Claim. 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
|
||||
x-authenticated: true
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
get:
|
||||
operationId: GetOrdersOrderCartId
|
||||
summary: Get by Cart ID
|
||||
description: Retrieves an Order 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
|
||||
|
||||
@@ -1,9 +1,12 @@
|
||||
post:
|
||||
operationId: PostOrdersCustomerOrderClaimsCustomerOrderClaimAccept
|
||||
summary: Verify an Order Claim
|
||||
summary: Verify Order Claim
|
||||
description: >-
|
||||
Verifies the claim order token provided to the customer upon request of
|
||||
order ownership
|
||||
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
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
get:
|
||||
operationId: GetOrdersOrder
|
||||
summary: Get an Order
|
||||
description: Retrieves an Order
|
||||
description: Retrieve an Order's details.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The id of the Order.
|
||||
description: The ID of the Order.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: fields
|
||||
description: (Comma separated) Which fields should be included in the result.
|
||||
description: Comma-separated fields that should be expanded in the returned order.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: expand
|
||||
description: (Comma separated) Which fields should be expanded in the result.
|
||||
description: Comma-separated relations that should be included in the returned order.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetPaymentCollectionsPaymentCollection
|
||||
summary: Get a PaymentCollection
|
||||
description: Get a Payment Collection
|
||||
description: Retrieve a Payment Collection's details.
|
||||
x-authenticated: false
|
||||
parameters:
|
||||
- in: path
|
||||
@@ -11,13 +11,17 @@ get:
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: expand
|
||||
description: Comma separated list of relations to include in the results.
|
||||
name: fields
|
||||
description: >-
|
||||
Comma-separated fields that should be expanded in the returned payment
|
||||
collection.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: fields
|
||||
description: Comma separated list of fields to include in the results.
|
||||
name: expand
|
||||
description: >-
|
||||
Comma-separated relations that should be expanded in the returned
|
||||
payment collection.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
post:
|
||||
operationId: PostPaymentCollectionsSessions
|
||||
summary: Manage a Payment Session
|
||||
description: Manages Payment Sessions from Payment Collections.
|
||||
summary: Create a Payment Session
|
||||
description: Create a Payment Session for a payment provider in a Payment Collection.
|
||||
x-authenticated: false
|
||||
parameters:
|
||||
- in: path
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
post:
|
||||
operationId: PostPaymentCollectionsPaymentCollectionSessionsBatch
|
||||
summary: Manage Payment Sessions
|
||||
description: Manages Multiple Payment Sessions from Payment Collections.
|
||||
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
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
post:
|
||||
operationId: PostPaymentCollectionsSessionsBatchAuthorize
|
||||
summary: Authorize PaymentSessions
|
||||
description: Authorizes Payment Sessions of a Payment Collection.
|
||||
description: Authorize the Payment Sessions of a Payment Collection.
|
||||
x-authenticated: false
|
||||
parameters:
|
||||
- in: path
|
||||
|
||||
@@ -2,8 +2,8 @@ post:
|
||||
operationId: PostPaymentCollectionsPaymentCollectionPaymentSessionsSession
|
||||
summary: Refresh a Payment Session
|
||||
description: >-
|
||||
Refreshes a Payment Session to ensure that it is in sync with the Payment
|
||||
Collection.
|
||||
Refresh a Payment Session's data to ensure that it is in sync with the
|
||||
Payment Collection.
|
||||
x-authenticated: false
|
||||
parameters:
|
||||
- in: path
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
post:
|
||||
operationId: PostPaymentCollectionsSessionsSessionAuthorize
|
||||
summary: Authorize Payment Session
|
||||
description: Authorizes a Payment Session of a Payment Collection.
|
||||
description: Authorize a Payment Session of a Payment Collection.
|
||||
x-authenticated: false
|
||||
parameters:
|
||||
- in: path
|
||||
|
||||
@@ -1,32 +1,44 @@
|
||||
get:
|
||||
operationId: GetProductCategories
|
||||
summary: List Product Categories
|
||||
description: Retrieve a list of product categories.
|
||||
x-authenticated: false
|
||||
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 endpoint 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
|
||||
parameters:
|
||||
- in: query
|
||||
name: q
|
||||
description: Query used for searching product category names or handles.
|
||||
description: term used to search product category's names and handles.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: handle
|
||||
description: Query used for searching product category by handle.
|
||||
description: Filter by handle.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: parent_category_id
|
||||
description: Returns categories scoped by parent
|
||||
description: >-
|
||||
Filter by the ID of a parent category. Only children of the provided
|
||||
parent category are retrieved.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: include_descendants_tree
|
||||
description: Include all nested descendants of category
|
||||
description: Whether all nested categories inside a category should be retrieved.
|
||||
schema:
|
||||
type: boolean
|
||||
- in: query
|
||||
name: offset
|
||||
description: How many product categories to skip in the result.
|
||||
description: >-
|
||||
The number of product categories to skip when retrieving the product
|
||||
categories.
|
||||
schema:
|
||||
type: integer
|
||||
default: 0
|
||||
@@ -36,6 +48,20 @@ get:
|
||||
schema:
|
||||
type: integer
|
||||
default: 100
|
||||
- in: query
|
||||
name: expand
|
||||
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.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
method: list
|
||||
queryParams: StoreGetProductCategoriesParams
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
get:
|
||||
operationId: GetProductCategoriesCategory
|
||||
summary: Get a Product Category
|
||||
description: Retrieves a Product Category.
|
||||
x-authenticated: false
|
||||
description: Retrieve a Product Category's details.
|
||||
x-featureFlag: product_categories
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
@@ -11,17 +11,17 @@ get:
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: expand
|
||||
name: fields
|
||||
description: >-
|
||||
(Comma separated) Which fields should be expanded in each product
|
||||
Comma-separated fields that should be expanded in the returned product
|
||||
category.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: fields
|
||||
name: expand
|
||||
description: >-
|
||||
(Comma separated) Which fields should be retrieved in each product
|
||||
category.
|
||||
Comma-separated relations that should be expanded in the returned
|
||||
product category.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
get:
|
||||
operationId: GetProductTags
|
||||
summary: List Product Tags
|
||||
description: Retrieve a list of 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.
|
||||
x-authenticated: true
|
||||
x-codegen:
|
||||
method: list
|
||||
@@ -9,31 +11,33 @@ get:
|
||||
parameters:
|
||||
- in: query
|
||||
name: limit
|
||||
description: The number of types to return.
|
||||
description: Limit the number of product tags returned.
|
||||
schema:
|
||||
type: integer
|
||||
default: 20
|
||||
- in: query
|
||||
name: offset
|
||||
description: The number of items to skip before the results.
|
||||
description: The number of product tags to skip when retrieving the product tags.
|
||||
schema:
|
||||
type: integer
|
||||
default: 0
|
||||
- in: query
|
||||
name: order
|
||||
description: The field to sort items by.
|
||||
description: A product-tag field to sort-order the retrieved product tags by.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: discount_condition_id
|
||||
description: The discount condition id on which to filter the product tags.
|
||||
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
|
||||
name: value
|
||||
style: form
|
||||
explode: false
|
||||
description: The tag values to search for
|
||||
description: Filter by tag values.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
@@ -42,19 +46,19 @@ get:
|
||||
name: id
|
||||
style: form
|
||||
explode: false
|
||||
description: The tag IDs to search for
|
||||
description: Filter by IDs.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
- in: query
|
||||
name: q
|
||||
description: A query string to search values for
|
||||
description: term to search product tag's value.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: created_at
|
||||
description: Date comparison for when resulting product tags were created.
|
||||
description: Filter by a creation date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -76,7 +80,7 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: updated_at
|
||||
description: Date comparison for when resulting product tags were updated.
|
||||
description: Filter by an update date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
|
||||
@@ -1,36 +1,41 @@
|
||||
get:
|
||||
operationId: GetProductTypes
|
||||
summary: List Product Types
|
||||
description: Retrieve a list of 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.
|
||||
x-authenticated: true
|
||||
parameters:
|
||||
- in: query
|
||||
name: limit
|
||||
description: The number of types to return.
|
||||
description: Limit the number of product types returned.
|
||||
schema:
|
||||
type: integer
|
||||
default: 20
|
||||
- in: query
|
||||
name: offset
|
||||
description: The number of items to skip before the results.
|
||||
description: The number of product types to skip when retrieving the product types.
|
||||
schema:
|
||||
type: integer
|
||||
default: 0
|
||||
- in: query
|
||||
name: order
|
||||
description: The field to sort items by.
|
||||
description: A product-type field to sort-order the retrieved product types by.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: discount_condition_id
|
||||
description: The discount condition id on which to filter the product types.
|
||||
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
|
||||
name: value
|
||||
style: form
|
||||
explode: false
|
||||
description: The type values to search for
|
||||
description: Filter by type values.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
@@ -39,19 +44,19 @@ get:
|
||||
name: id
|
||||
style: form
|
||||
explode: false
|
||||
description: The type IDs to search for
|
||||
description: Filter by IDs.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
- in: query
|
||||
name: q
|
||||
description: A query string to search values for
|
||||
description: term to search product type's value.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: created_at
|
||||
description: Date comparison for when resulting product types were created.
|
||||
description: Filter by a creation date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -73,7 +78,7 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: updated_at
|
||||
description: Date comparison for when resulting product types were updated.
|
||||
description: Filter by an update date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
|
||||
@@ -1,20 +1,41 @@
|
||||
get:
|
||||
operationId: GetProducts
|
||||
summary: List Products
|
||||
description: Retrieves a list of 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.
|
||||
|
||||
This endpoint 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
|
||||
|
||||
`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`.
|
||||
externalDocs:
|
||||
description: How to retrieve a product by its handle
|
||||
url: >-
|
||||
https://docs.medusajs.com/modules/products/storefront/show-products#retrieve-product-by-handle
|
||||
parameters:
|
||||
- in: query
|
||||
name: q
|
||||
description: >-
|
||||
Query used for searching products by title, description, variant's
|
||||
title, variant's sku, and collection's title
|
||||
term used to search products' title, description, variant's title,
|
||||
variant's sku, and collection's title.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: id
|
||||
style: form
|
||||
explode: false
|
||||
description: product IDs to search for.
|
||||
description: Filter by IDs.
|
||||
schema:
|
||||
oneOf:
|
||||
- type: string
|
||||
@@ -25,7 +46,11 @@ get:
|
||||
name: sales_channel_id
|
||||
style: form
|
||||
explode: false
|
||||
description: an array of sales channel IDs to filter the retrieved products by.
|
||||
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:
|
||||
@@ -34,7 +59,9 @@ get:
|
||||
name: collection_id
|
||||
style: form
|
||||
explode: false
|
||||
description: Collection IDs to search for
|
||||
description: >-
|
||||
Filter by product collection IDs. When provided, only products that
|
||||
belong to the specified product collections are retrieved.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
@@ -43,7 +70,9 @@ get:
|
||||
name: type_id
|
||||
style: form
|
||||
explode: false
|
||||
description: Type IDs to search for
|
||||
description: >-
|
||||
Filter by product type IDs. When provided, only products that belong to
|
||||
the specified product types are retrieved.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
@@ -52,34 +81,36 @@ get:
|
||||
name: tags
|
||||
style: form
|
||||
explode: false
|
||||
description: Tag IDs to search for
|
||||
description: >-
|
||||
Filter by product tag IDs. When provided, only products that belong to
|
||||
the specified product tags are retrieved.
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
- in: query
|
||||
name: title
|
||||
description: title to search for.
|
||||
description: Filter by title.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: description
|
||||
description: description to search for.
|
||||
description: Filter by description
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: handle
|
||||
description: handle to search for.
|
||||
description: Filter by handle.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: is_giftcard
|
||||
description: Search for giftcards using is_giftcard=true.
|
||||
description: Whether to retrieve regular products or gift-card products.
|
||||
schema:
|
||||
type: boolean
|
||||
- in: query
|
||||
name: created_at
|
||||
description: Date comparison for when resulting products were created.
|
||||
description: Filter by a creation date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -101,7 +132,7 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: updated_at
|
||||
description: Date comparison for when resulting products were updated.
|
||||
description: Filter by an update date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -125,19 +156,27 @@ get:
|
||||
name: category_id
|
||||
style: form
|
||||
explode: false
|
||||
description: Category ids to filter by.
|
||||
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
|
||||
items:
|
||||
type: string
|
||||
- in: query
|
||||
name: include_category_children
|
||||
description: Include category children when filtering by category_id.
|
||||
style: form
|
||||
explode: false
|
||||
description: >-
|
||||
Whether to include child product categories when filtering using the
|
||||
`category_id` field.
|
||||
schema:
|
||||
type: boolean
|
||||
x-featureFlag: product_categories
|
||||
- in: query
|
||||
name: offset
|
||||
description: How many products to skip in the result.
|
||||
description: The number of products to skip when retrieving the products.
|
||||
schema:
|
||||
type: integer
|
||||
default: 0
|
||||
@@ -150,37 +189,46 @@ get:
|
||||
- in: query
|
||||
name: expand
|
||||
description: >-
|
||||
(Comma separated) Which fields should be expanded in each product of the
|
||||
result.
|
||||
Comma-separated relations that should be expanded in the returned
|
||||
products.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: fields
|
||||
description: >-
|
||||
(Comma separated) Which fields should be included in each product of the
|
||||
result.
|
||||
description: Comma-separated fields that should be included in the returned products.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: order
|
||||
description: the field used to order the products.
|
||||
description: A product field to sort-order the retrieved products by.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: cart_id
|
||||
description: The id of the Cart to set prices based on.
|
||||
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 to set prices based on.
|
||||
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
|
||||
description: The currency code to use for price selection.
|
||||
style: form
|
||||
explode: false
|
||||
description: >-
|
||||
A 3 character ISO currency code. This is useful for accurate pricing
|
||||
based on the selected currency.
|
||||
schema:
|
||||
type: string
|
||||
externalDocs:
|
||||
url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes
|
||||
description: See a list of codes.
|
||||
x-codegen:
|
||||
method: list
|
||||
queryParams: StoreGetProductsParams
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
post:
|
||||
operationId: PostProductsSearch
|
||||
summary: Search Products
|
||||
description: Run a search query on products using the search engine installed on Medusa
|
||||
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:
|
||||
|
||||
@@ -1,41 +1,59 @@
|
||||
get:
|
||||
operationId: GetProductsProduct
|
||||
summary: Get a Product
|
||||
description: Retrieves 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
|
||||
|
||||
`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`.
|
||||
externalDocs:
|
||||
description: How to pass product pricing parameters
|
||||
url: >-
|
||||
https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The id of the Product.
|
||||
description: The ID of the Product.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: sales_channel_id
|
||||
description: The sales channel used when fetching the product.
|
||||
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 customer's cart.
|
||||
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 the customer is using. This is helpful to ensure
|
||||
correct prices are retrieved for a region.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: fields
|
||||
description: (Comma separated) Which fields should be included in the result.
|
||||
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) Which fields should be expanded in each product of the
|
||||
result.
|
||||
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.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
@@ -43,8 +61,8 @@ get:
|
||||
style: form
|
||||
explode: false
|
||||
description: >-
|
||||
The 3 character ISO currency code to set prices based on. This is
|
||||
helpful to ensure correct prices are retrieved for a currency.
|
||||
A 3 character ISO currency code. This is useful for accurate pricing
|
||||
based on the selected currency.
|
||||
schema:
|
||||
type: string
|
||||
externalDocs:
|
||||
|
||||
@@ -1,11 +1,18 @@
|
||||
get:
|
||||
operationId: GetRegions
|
||||
summary: List Regions
|
||||
description: Retrieves a list of 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 endpoint 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
|
||||
parameters:
|
||||
- in: query
|
||||
name: offset
|
||||
description: How many regions to skip in the result.
|
||||
description: The number of regions to skip when retrieving the regions.
|
||||
schema:
|
||||
type: integer
|
||||
default: 0
|
||||
@@ -17,7 +24,7 @@ get:
|
||||
default: 100
|
||||
- in: query
|
||||
name: created_at
|
||||
description: Date comparison for when resulting regions were created.
|
||||
description: Filter by a creation date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
@@ -39,7 +46,7 @@ get:
|
||||
format: date
|
||||
- in: query
|
||||
name: updated_at
|
||||
description: Date comparison for when resulting regions were updated.
|
||||
description: Filter by an update date range.
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
get:
|
||||
operationId: GetRegionsRegion
|
||||
summary: Get a Region
|
||||
description: Retrieves a Region.
|
||||
description: Retrieve a Region's details.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The id of the Region.
|
||||
description: The ID of the Region.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
get:
|
||||
operationId: GetReturnReasons
|
||||
summary: List Return Reasons
|
||||
description: Retrieves a list of Return Reasons.
|
||||
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:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetReturnReasonsReason
|
||||
summary: Get a Return Reason
|
||||
description: Retrieves a Return Reason.
|
||||
description: Retrieve a Return Reason's details.
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
|
||||
@@ -1,7 +1,12 @@
|
||||
post:
|
||||
operationId: PostReturns
|
||||
summary: Create Return
|
||||
description: Creates a Return for an Order.
|
||||
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
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
|
||||
@@ -1,23 +1,28 @@
|
||||
get:
|
||||
operationId: GetShippingOptions
|
||||
summary: Get Shipping Options
|
||||
description: Retrieves a list of Shipping Options.
|
||||
description: Retrieve a list of Shipping Options.
|
||||
parameters:
|
||||
- in: query
|
||||
name: is_return
|
||||
description: >-
|
||||
Whether return Shipping Options should be included. By default all
|
||||
Shipping Options are returned.
|
||||
Whether return shipping options should be included. By default, all
|
||||
shipping options are returned.
|
||||
schema:
|
||||
type: boolean
|
||||
- in: query
|
||||
name: product_ids
|
||||
description: A comma separated list of Product ids to filter Shipping Options by.
|
||||
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 Region to retrieve Shipping Options from.
|
||||
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:
|
||||
|
||||
@@ -1,12 +1,16 @@
|
||||
get:
|
||||
operationId: GetShippingOptionsCartId
|
||||
summary: List for Cart
|
||||
description: Retrieves a list of Shipping Options available to a cart.
|
||||
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
|
||||
parameters:
|
||||
- in: path
|
||||
name: cart_id
|
||||
required: true
|
||||
description: The id of the Cart.
|
||||
description: The ID of the Cart.
|
||||
schema:
|
||||
type: string
|
||||
x-codegen:
|
||||
|
||||
@@ -1,9 +1,26 @@
|
||||
post:
|
||||
operationId: PostSwaps
|
||||
summary: Create a Swap
|
||||
description: >-
|
||||
Creates a Swap on an Order by providing some items to return along with some
|
||||
items to send back
|
||||
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 endpoint 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
|
||||
url: https://docs.medusajs.com/modules/orders/storefront/create-swap
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
get:
|
||||
operationId: GetSwapsSwapCartId
|
||||
summary: Get by Cart ID
|
||||
description: Retrieves a Swap by the id of the Cart used to confirm the Swap.
|
||||
description: Retrieve a Swap's details by the ID of its cart.
|
||||
parameters:
|
||||
- in: path
|
||||
name: cart_id
|
||||
|
||||
@@ -1,61 +1,122 @@
|
||||
get:
|
||||
operationId: GetVariants
|
||||
summary: Get Product Variants
|
||||
description: Retrieves a list of 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
|
||||
|
||||
`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`.
|
||||
externalDocs:
|
||||
description: How to pass product pricing parameters
|
||||
url: >-
|
||||
https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters
|
||||
parameters:
|
||||
- in: query
|
||||
name: ids
|
||||
description: A comma separated list of Product Variant ids to filter by.
|
||||
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.
|
||||
schema:
|
||||
oneOf:
|
||||
- type: string
|
||||
description: Filter by an ID.
|
||||
- type: array
|
||||
description: Filter by IDs.
|
||||
items:
|
||||
type: string
|
||||
- in: query
|
||||
name: sales_channel_id
|
||||
description: A sales channel id for result configuration.
|
||||
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: A comma separated list of Product Variant relations to load.
|
||||
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.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: offset
|
||||
description: How many product variants to skip in the result.
|
||||
description: The number of products to skip when retrieving the product variants.
|
||||
schema:
|
||||
type: number
|
||||
default: '0'
|
||||
- in: query
|
||||
name: limit
|
||||
description: Maximum number of Product Variants to return.
|
||||
description: Limit the number of product variants returned.
|
||||
schema:
|
||||
type: number
|
||||
default: '100'
|
||||
- in: query
|
||||
name: cart_id
|
||||
description: The id of the Cart to set prices based on.
|
||||
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 to set prices based on.
|
||||
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
|
||||
description: The currency code to use for price selection.
|
||||
style: form
|
||||
explode: false
|
||||
description: >-
|
||||
A 3 character ISO currency code. This is useful for accurate pricing
|
||||
based on the selected currency.
|
||||
schema:
|
||||
type: string
|
||||
externalDocs:
|
||||
url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes
|
||||
description: See a list of codes.
|
||||
- in: query
|
||||
name: title
|
||||
style: form
|
||||
explode: false
|
||||
description: product variant title to search for.
|
||||
description: Filter by title
|
||||
schema:
|
||||
oneOf:
|
||||
- type: string
|
||||
description: a single title to search by
|
||||
description: a single title to filter by
|
||||
- type: array
|
||||
description: multiple titles to search by
|
||||
description: multiple titles to filter by
|
||||
items:
|
||||
type: string
|
||||
- in: query
|
||||
@@ -64,23 +125,23 @@ get:
|
||||
schema:
|
||||
oneOf:
|
||||
- type: number
|
||||
description: a specific number to search by.
|
||||
description: A specific number to filter by.
|
||||
- type: object
|
||||
description: search using less and greater than comparisons.
|
||||
description: Filter using less and greater than comparisons.
|
||||
properties:
|
||||
lt:
|
||||
type: number
|
||||
description: filter by inventory quantity less than this number
|
||||
description: Filter by inventory quantity less than this number
|
||||
gt:
|
||||
type: number
|
||||
description: filter by inventory quantity greater than this number
|
||||
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
|
||||
Filter by inventory quantity greater than or equal to this
|
||||
number
|
||||
x-codegen:
|
||||
method: list
|
||||
@@ -91,7 +152,7 @@ get:
|
||||
source:
|
||||
$ref: ../code_samples/Shell/store_variants/get.sh
|
||||
tags:
|
||||
- Variants
|
||||
- Product Variants
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
|
||||
87
docs/api/store/paths/store_variants_{id}.yaml
Normal file
87
docs/api/store/paths/store_variants_{id}.yaml
Normal file
@@ -0,0 +1,87 @@
|
||||
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
|
||||
|
||||
`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`.
|
||||
externalDocs:
|
||||
description: How to pass product pricing parameters
|
||||
url: >-
|
||||
https://docs.medusajs.com/modules/products/storefront/show-products#product-pricing-parameters
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The ID of the Product Variant.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: sales_channel_id
|
||||
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.
|
||||
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.
|
||||
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.
|
||||
schema:
|
||||
type: string
|
||||
externalDocs:
|
||||
url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes
|
||||
description: See a list of codes.
|
||||
x-codegen:
|
||||
method: retrieve
|
||||
queryParams: StoreGetVariantsVariantParams
|
||||
x-codeSamples:
|
||||
- lang: Shell
|
||||
label: cURL
|
||||
source:
|
||||
$ref: ../code_samples/Shell/store_variants_{id}/get.sh
|
||||
tags:
|
||||
- Product Variants
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: ../components/schemas/StoreVariantsRes.yaml
|
||||
'400':
|
||||
$ref: ../components/responses/400_error.yaml
|
||||
'404':
|
||||
$ref: ../components/responses/not_found_error.yaml
|
||||
'409':
|
||||
$ref: ../components/responses/invalid_state_error.yaml
|
||||
'422':
|
||||
$ref: ../components/responses/invalid_request_error.yaml
|
||||
'500':
|
||||
$ref: ../components/responses/500_error.yaml
|
||||
@@ -1,63 +0,0 @@
|
||||
get:
|
||||
operationId: GetVariantsVariant
|
||||
summary: Get a Product Variant
|
||||
description: Retrieves a Product Variant by id
|
||||
parameters:
|
||||
- in: path
|
||||
name: variant_id
|
||||
required: true
|
||||
description: The id of the Product Variant.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: cart_id
|
||||
description: The id of the Cart to set prices based on.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: sales_channel_id
|
||||
description: A sales channel id for result configuration.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: region_id
|
||||
description: The id of the Region to set prices based on.
|
||||
schema:
|
||||
type: string
|
||||
- in: query
|
||||
name: currency_code
|
||||
style: form
|
||||
explode: false
|
||||
description: The 3 character ISO currency code to set prices based on.
|
||||
schema:
|
||||
type: string
|
||||
externalDocs:
|
||||
url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes
|
||||
description: See a list of codes.
|
||||
x-codegen:
|
||||
method: retrieve
|
||||
queryParams: StoreGetVariantsVariantParams
|
||||
x-codeSamples:
|
||||
- lang: Shell
|
||||
label: cURL
|
||||
source:
|
||||
$ref: ../code_samples/Shell/store_variants_{variant_id}/get.sh
|
||||
tags:
|
||||
- Variants
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: ../components/schemas/StoreVariantsRes.yaml
|
||||
'400':
|
||||
$ref: ../components/responses/400_error.yaml
|
||||
'404':
|
||||
$ref: ../components/responses/not_found_error.yaml
|
||||
'409':
|
||||
$ref: ../components/responses/invalid_state_error.yaml
|
||||
'422':
|
||||
$ref: ../components/responses/invalid_request_error.yaml
|
||||
'500':
|
||||
$ref: ../components/responses/500_error.yaml
|
||||
Reference in New Issue
Block a user