API reference · Listings
Upsert listings
/listingsCreate or update one listing or an array of listings with the desired values. The response reports each item's result. An invalid item does not fail the rest of the batch.
Example
These examples send requests to the sandbox.
curl --request POST \
--url 'https://api-sandbox.snapcaster.ca/api/v1/marketplace/listings' \
--header "Authorization: Bearer $MARKETPLACE_API_KEY" \
--header 'Content-Type: application/json' \
--data @- <<EOF
{
"skuId": 14602,
"productId": 86,
"price": 2499,
"quantity": 3,
"externalRef": "platform-listing-1042",
"asOf": "$(node -p 'new Date().toISOString()')"
}
EOFcurl --request POST \
--url 'https://api-sandbox.snapcaster.ca/api/v1/marketplace/listings' \
--header "Authorization: Bearer $MARKETPLACE_API_KEY" \
--header 'Content-Type: application/json' \
--data @- <<EOF
[
{
"skuId": 14602,
"productId": 86,
"price": 2499,
"quantity": 3,
"externalRef": "platform-listing-1042",
"asOf": "$(node -p 'new Date().toISOString()')"
},
{
"skuId": 363348,
"productId": 86,
"price": 2699,
"quantity": 1,
"externalRef": "platform-listing-1043",
"asOf": "$(node -p 'new Date().toISOString()')"
}
]
EOF$(node -p 'new Date().toISOString()') sets asOf to the current UTC time in milliseconds, so two writes in the same second never share an asOf.
{
"success": true,
"data": {
"results": [
{
"skuId": 14602,
"op": "upsert",
"status": "applied",
"externalRef": "platform-listing-1042"
}
]
}
}Endpoint
| Environment | URL |
|---|---|
| Sandbox | https://api-sandbox.snapcaster.ca/api/v1/marketplace |
| Production | https://api.snapcaster.ca/api/v1/marketplace |
marketplaceApiKey-http bearer. Send the seller's marketplace API key asAuthorization: Bearer mp_{sellerCode}_{hex}. Themp_{sellerCode}_prefix identifies the seller; the trailing hex is the secret. The seller generates the key and supplies it to your platform.
Request
Headers
X-Snapcaster-Api-VersionstringOverride the platform pin for this request only. Webhook versions and the platform pin do not change.
Constraints: allowed values:
2026-10Example2026-10
This operation takes no Idempotency-Key. Retries says how to resend it safely.
Request body
skuIdinteger requiredSee Canonical catalog in Core concepts.
Constraints: exclusive minimum: 0 Example
14602productIdintegerThe TCGplayer product of
skuId. Required only whileskuIdis absent from the canonical catalog; otherwise Snapcaster takes the product from the catalog and rejects a different value withPRODUCT_MISMATCH.Constraints: exclusive minimum: 0 Example
86priceinteger requiredThe unit price in minor currency units.
Constraints: minimum: 0 Example
2499quantityinteger requiredThe number of units.
Example
3externalRefstringSee Listing in Core concepts.
Constraints: maximum length: 255 Example
platform-listing-1042asOfstring requiredSee Send ordered listing snapshots in Core concepts.
Constraints: format: date-time Example
2026-09-04T18:30:00.000Z
The body can also be an array of up to 1,000 of these objects.
Response
200
Per-item multi-status results.
Response body: Listing
successboolean requiredWhether the operation completed as requested.
Constraints: allowed values:
trueExampletruedataobject requiredThe operation or event payload.
Show child fieldsHide child fields
data.results ListingrequiredItem Result[] The outcome recorded for each submitted item.
Show child fieldsHide child fields
data.integer requiredresults[]. skuId See Canonical catalog in Core concepts.
Example
14602data.string requiredresults[]. op The write operation to apply to this item.
Constraints: allowed values:
upsert,deleteExampleupsertdata.string requiredresults[]. status The result for this item.
unmatchedcorresponds toUNMATCHED: Snapcaster stored the item, but its SKU is absent from the canonical catalog.rejectedcorresponds toREJECTED: validation failed and Snapcaster did not store the item. Checkreasonfor details.Constraints: allowed values:
applied,unmatched,rejected,noopExampleapplieddata.stringresults[]. code The stable machine-readable code for this result.
Constraints: allowed values:
INVALID_REQUEST,STALE_SNAPSHOT,SNAPSHOT_CONFLICT,PRODUCT_MISMATCHdata.stringresults[]. reason Why the item was rejected; present only when status is "rejected".
data.stringresults[]. externalRef The submitted listing reference, if supplied.
Example
platform-listing-1042
Errors
Errors return a Marketplace body, except HTTP 413 (Marketplace or Api) and HTTP 500 (Api). Error codes explains both error bodies and lists every code.
400
INVALID_REQUESTUNSUPPORTED_API_VERSIONThe request failed validation (
INVALID_REQUEST). Unknown or retired API-version override (UNSUPPORTED_API_VERSION).Do this: Correct the fields named in the error details, then retry the request. For UNSUPPORTED_API_VERSION, choose a supported version from the API versioning guide.
401
UNAUTHORIZEDMissing or invalid marketplace API key (
UNAUTHORIZED).Do this: Send the marketplace API key for this seller as a Bearer token, then retry.
409
SELLER_SOURCE_EXCLUSIVEThe seller's inventory source is not
platform(SELLER_SOURCE_EXCLUSIVE). Only platform-source sellers can write listings through the integration API. A seller uses one inventory source at a time.Do this: Use the seller’s declared inventory source, or ask Snapcaster to move the seller to the platform source.
413
BATCH_TOO_LARGEPAYLOAD_TOO_LARGEThe request exceeds the 1,000-item limit (
BATCH_TOO_LARGE). The body is larger than this route accepts (PAYLOAD_TOO_LARGE).Do this: Split the write into batches of at most 1,000 items and retry each batch. Send a smaller body and retry.
429
RATE_LIMITEDThe per-seller item rate ceiling was exceeded (
RATE_LIMITED).Do this: Wait the Retry-After duration in seconds, then retry with bounded retries and jitter.
500
INTERNAL_ERRORAn unexpected failure (
INTERNAL_ERROR).Do this: Retry with bounded retries and jitter. If the failure persists, contact Snapcaster with the X-Correlation-ID response header.
Per-item errors
A successful HTTP response can still reject items. Each rejected item carries one of these codes.
INVALID_REQUESTThe item failed validation.
Do this: Correct the fields named in reason before submitting this item again.
STALE_SNAPSHOTThe snapshot is older than the retained listing or purge watermark.
Do this: Discard the delayed snapshot. Measure current stock before sending a new snapshot; do not relabel stale stock with a newer timestamp.
SNAPSHOT_CONFLICTThe same snapshot instant was used with different contents.
Do this: Retry the original contents, or measure current stock and send it with its actual capture time.
PRODUCT_MISMATCHThe
productIdnames a different product than the canonical catalog holds for theskuId. Snapcaster stored nothing for the item and left any existing listing for the SKU unchanged.Do this: Send the
productIdthatreasonnames, or omitproductIdso Snapcaster takes it from the catalog.