storlaunch.product.archived.v1

Fires when a product is archived (soft-deleted) via DELETE /v1/storefront/products/:id or the dashboard's archive action. Storlaunch does not hard-delete products — archive is the terminal state. Subscribers should remove the product from public-facing surfaces (search, feeds, recommendations) while keeping it queryable in their own audit log.

When it fires

Once per DELETE call. Re-archiving an already-archived product is a no-op and does not re-fire the event. There's no companion unarchive event; restoring is dashboard-only and emits storlaunch.product.updated.v1.

Payload

Notably slim — unlike created.v1 and updated.v1, this carries just id and accountId. Your downstream mirror should already have the rest from prior events.

{
  "id": "evt_01HX...",
  "type": "storlaunch.product.archived.v1",
  "createdAt": "2026-05-13T11:00:00Z",
  "accountId": "acc_01HX...",
  "data": {
    "id": "prod_01HX...",
    "accountId": "acc_01HX..."
  }
}

Handler examples

// Node
if (event.type === 'storlaunch.product.archived.v1') {
  const { id } = event.data;
  await searchIndex.delete(id);
  await crm.audit.log({ entityId: id, action: 'archived', source: 'storlaunch' });
}
# Python
if event["type"] == "storlaunch.product.archived.v1":
    pid = event["data"]["id"]
    search_index.delete(pid)
    crm.audit.log(entity_id=pid, action="archived", source="storlaunch")
// Go
if event.Type == "storlaunch.product.archived.v1" {
    var d struct{ ID string `json:"id"` }
    _ = json.Unmarshal(event.Data, &d)
    search.Delete(ctx, d.ID)
}

What to do

  • Remove the product from your search index and public catalogue.
  • Cancel any scheduled marketing-automation tied to it (abandoned-cart emails, retargeting feeds).
  • Keep historical records (orders that included this product) accessible in your reporting.

Common pitfalls

  • Cascading deletes. Archiving a product does not archive its variants in your mirror automatically — you don't get separate variant.archived events. Cascade in your handler.
  • Treating archive as deletion. The product is still queryable via GET /v1/storefront/products/:id (returns it with archived: true). Keep it in your DB so old order lookups don't fail.
  • Missing the unarchive case. If the merchant restores, you'll get storlaunch.product.updated.v1 with archived: false. Treat that as the re-add signal.

Related events

Next