Medusa
Store APIAdmin API
Store APIAdmin API
Discord
Twitter
Linkedin
Github
  1. Getting Started
  • Getting Started
    • Introduction
    • Authentication
    • HTTP Compression
    • Publishable API Key
    • Expanding Fields
    • Selecting Fields
    • Query Parameter Types
    • Pagination
  • Auth
    • Customer Login (JWT)
      POST
    • Customer Login (JWT)
      POST
    • Check if Email Exists
      GET
    • Get Current Customer
      GET
    • Customer Log out
      DELETE
    • Customer Login
      POST
  • Carts
    • Create Payment Sessions
      POST
    • Refresh a Payment Session
      POST
    • Create a Cart
      POST
    • Complete a Cart
      POST
    • Select a Payment Session
      POST
    • Delete a Payment Session
      DELETE
    • Update a Payment Session
      POST
    • Get a Cart
      GET
    • Update a Cart
      POST
    • Add Shipping Method
      POST
    • Update a Line Item
      POST
    • Delete a Line Item
      DELETE
    • Add a Line Item
      POST
    • Calculate Cart Taxes
      POST
    • Remove Discount
      DELETE
  • Customers
    • Request Password Reset
    • Get Saved Payment Methods
    • Add a Shipping Address
    • Update Customer
    • Get a Customer
    • Update a Shipping Address
    • Delete an Address
    • Create a Customer
    • Reset Password
    • List Orders
  • Gift Cards
    • Get Gift Card by Code
  • Orders
    • Claim Order
    • Verify Order Claim
    • Get an Order
    • Look Up an Order
    • Get by Cart ID
  • Order Edits
    • Complete an Order Edit
    • Retrieve an Order Edit
    • Decline an Order Edit
  • Payment Collections
    • Authorize Payment Session
    • Authorize Payment Sessions
    • Refresh a Payment Session
    • Get a PaymentCollection
    • Manage Payment Sessions
    • Create a Payment Session
  • Products
    • Search Products
    • List Products
    • Get a Product
  • Product Variants
    • Get a Product Variant
    • Get Product Variants
  • Product Tags
    • List Product Tags
  • Product Categories
    • List Product Categories
    • Get a Product Category
  • Product Collections
    • Get a Collection
    • List Collections
  • Product Types
    • List Product Types
  • Regions
    • List Regions
    • Get a Region
  • Returns
    • Create Return
  • Return Reasons
    • List Return Reasons
    • Get a Return Reason
  • Shipping Options
    • List for Cart
    • Get Shipping Options
  • Swaps
    • Get by Cart ID
    • Create a Swap
  1. Getting Started

Query Parameter Types

This section covers how to pass some common data types as query parameters.
This is useful if you're sending requests to the API endpoints and not using
our JS Client. For example, when using cURL or Postman.

Strings#

You can pass a string value in the form of <parameter_name>=<value>.
For example:
If the string has any characters other than letters and numbers, you must
encode them.
For example, if the string has spaces, you can encode the space with + or
%20:
You can use tools like this one to learn how
a value can be encoded.

Integers#

You can pass an integer value in the form of <parameter_name>=<value>.
For example:

Boolean#

You can pass a boolean value in the form of <parameter_name>=<value>.
For example:

Date and DateTime#

You can pass a date value in the form <parameter_name>=<value>. The date
must be in the format YYYY-MM-DD.
For example:
You can also pass the time using the format YYYY-MM-DDTHH:MM:SSZ. Please
note that the T and Z here are fixed.
For example:

Array#

Each array value must be passed as a separate query parameter in the form
<parameter_name>[]=<value>. You can also specify the index of each
parameter in the brackets <parameter_name>[0]=<value>.
For example:
Note that the -g parameter passed to curl disables errors being thrown
for using the brackets. Read more
here.

Object#

Object parameters must be passed as separate query parameters in the form
<parameter_name>[<key>]=<value>.
For example:
Modified at 2023-10-10 11:56:42
Previous
Selecting Fields
Next
Pagination
Built with