Skip to main content

Managing availability

Marking a product as unavailable​

Send a delete event when a product becomes unavailable for purchase. Include stockId to mark it as unavailable at that stock. Omit stockId to mark it as unavailable across all stocks.

Replace <PARTNER_ID> with your store identifier and <PAT> with your token.

At one stock​

Include the product id and stockId in the delete object:

curl --include --request POST \
'https://catalog.retailrocket.net/productCatalog/s2s/<PARTNER_ID>/events:publish' \
--header 'Authorization: Bearer <PAT>' \
--header 'Content-Type: application/json' \
--data-raw '{
"events": [
{
"delete": {
"id": "100001",
"stockId": "main"
}
}
]
}'

This request marks product 100001 as unavailable at stock main. Availability at other stocks stays the same.

At all stocks​

Pass only the product id:

curl --include --request POST \
'https://catalog.retailrocket.net/productCatalog/s2s/<PARTNER_ID>/events:publish' \
--header 'Authorization: Bearer <PAT>' \
--header 'Content-Type: application/json' \
--data-raw '{
"events": [
{
"delete": {
"id": "100001"
}
}
]
}'

This request marks product 100001 as unavailable across all stocks.

See Statuses and responses for HTTP statuses and error handling.

Restoring availability​

When the product is available again, send a complete update with isAvailable: true. Include stockId to update availability at a particular stock.

See Publishing products for the data format and a request example.