Resolve Draft Categories
POST/api/v2/listing-drafts/resolve-categories
Resolve the channel category for up to 500 products on one sales channel in a single call, before creating drafts in bulk: the product's own override on the channel first, else the category its product type is mapped to — with provenance and the category's default template per product. Nothing is created. A product that resolves to nothing comes back with sales_channel_category and provenance null; pick a category for it (or map its type) before publishing.
products:writeGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Authentication: Requires Bearer token.
Fields:
sales_channel_id(required, integer)product_ids(required, array of integers, 1–500)
Each resolution carries:
product_id,sales_channel_idsales_channel_category—{id, name, path, external_id, is_leaf}, or null when nothing resolvedprovenance—override(the product's own override on the channel) ortype_map(its product type's map row on the channel); null when nothing resolvedproduct_type—{id, name, path}of the type the product resolves under (a variant with no type of its own uses its parent's), or nulltemplate—{id, name, is_default}: the template pinned by the override, else the resolved category's default template; null when there is noneoverride—{id, sales_channel_category_id, sales_channel_product_template_id, created_at}when an override is set, else nulltype_map_category— set only while an override is in force AND the type map points at a different category, so the difference can be shown; otherwise null
Pass each product's sales_channel_category.id, template.id and provenance on to Create Drafts in Bulk as products[].sales_channel_category_id, products[].sales_channel_product_template_id and products[].category_provenance.
Requires permission: listings.create
Read-only resolution: requires the listings read permission (not create).
Request
Responses
- 200
- 401
- 403
- 422
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Validation failed — the body is a field → messages map (Laravel shape) or the platform envelope with a stable machine-readable code. Fix the payload and resubmit.
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.