Product Tags API Routes

GET /store/product-tags#

List Product Tags

Retrieve a list of product tags. The product tags can be filtered by fields such as id. The product tags can also be sorted or paginated.

Authentication: none.

Header parameters

x-publishable-api-keystring
Publishable API Key created in the Medusa Admin.
x-medusa-localestringOptional
The locale in BCP 47 format to retrieve localized content.
Example: en-US

Query parameters

fieldsstringOptional
Comma-separated fields that should be included in the returned data. if a field is prefixed with + it will be added to the default fields, using - will remove it from the default fields. without prefix it will replace the entire default fields.
offsetnumberOptional
The number of items to skip when retrieving a list.
limitnumberOptional
Limit the number of items returned in the list.
orderstringOptional
The field to sort the data by. By default, the sort order is ascending. To change the order to descending, prefix the field name with -.
$andobject[]Optional
Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
$orobject[]Optional
Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
qstringOptional
Query to search product tag's searchable fields.
idstring | string[]Optional
Filter by a product tag's ID.
valuestring | string[]Optional
Filter by a product tag's value.
created_atobjectOptional
Filter by the tag's creation date. Accepts the filter operators.
updated_atobjectOptional
Filter by the tag's update date. Accepts the filter operators.
with_deletedbooleanOptional
Whether to include deleted records in the result.
localestringOptional
The locale in BCP 47 format to retrieve localized content.
Example: en-US
external_idstring | string[]Optional
Filter by a product tag's external ID.

Request examples

Responses

200 OK

limitnumber
The maximum number of items returned.
offsetnumber
The number of items to skip before retrieving the returned items.
countnumber
The total number of items available.
product_tagsobject[]
The list of product tags.
estimate_countnumberOptional
The estimated count retrieved from the PostgreSQL query planner, which may be inaccurate.

400, 401, 404, 409, 422, 500: an error response is returned.


GET /store/product-tags/{id}#

Get a Product Tag

Retrieve a product tag by its ID. You can expand the product tag's relations or select the fields that should be returned.

Authentication: none.

Path parameters

idstring
The product tag's ID.

Header parameters

x-publishable-api-keystring
Publishable API Key created in the Medusa Admin.
x-medusa-localestringOptional
The locale in BCP 47 format to retrieve localized content.
Example: en-US

Query parameters

fieldsstringOptional
Comma-separated fields that should be included in the returned data. if a field is prefixed with + it will be added to the default fields, using - will remove it from the default fields. without prefix it will replace the entire default fields.
localestringOptional
The locale in BCP 47 format to retrieve localized content.
Example: en-US

Request examples

Responses

200 OK

product_tagobject
The tag's details.

400, 401, 404, 409, 422, 500: an error response is returned.

Found a problem with this page?Report Issue
Edited Nov 14·Edit this page