Skip to main content
POST
Merge Duplicate Products

Authorizations

Authorization
string
header
required

Bearer API key for server-to-server access. Session auth is also supported in first-party UI flows.

Body

application/json
productIds
string[]
required

Ordered standalone catalog product IDs. Products are grouped by exact SKU; each group merges into one master.

Required array length: 2 - 20 elements
Required string length: 1 - 255
dryRun
boolean

True runs the same merge transaction and rolls it back, including database reference/constraint validation. No product changes are saved, no mutation events or duplicate refreshes run, and marketplace listings stay unchanged. Requires catalog:write. Omitted/false performs the reviewed merge. This differs from CLI --dry-run, which only prints a request.

organizationId
string

Required only for session-authenticated calls. API credentials use their own organization.

masterProductIds
string[]

Optional master per SKU group, chosen from productIds; at most one per group. Defaults to the first requested product of each group. The master keeps its content, images, price and stock.

Required array length: 1 - 10 elements
Required string length: 1 - 255
expectedGroups
object[]

Optional groups from a preview to pin: membership, master (first product) and SKU. Groups that changed or are omitted are not merged.

Required array length: 1 - 10 elements
explanation
string
Maximum string length: 2000

Response

Batch processed. data holds groups[] (with survivingProductId, mergedProductIds, error), ordered per-product items[], succeededCount and failedCount. ok is true only when every group merged.

ok
boolean
required
apiVersion
string
required
operationId
string
required
status
enum<string>
required
Available options:
accepted,
completed,
failed
data
object
required
warnings
string[]
required
recommendations
string[]
required
error
string