stock_batch.completed

View as Markdown

Stock batch completed

Every unit of a stock batch has been made.

Sent as a signed POST to every endpoint subscribed to stock_batch.completed. Signing, retries and deduplication work the same for every event; see how delivery works.

Payload

The event.

  • idstring

    Unique identifier of the event, prefixed with evt_. Treat it as an opaque string: store it and compare it, never parse it.

  • objectstring

    Names the type of this object. Always event.

  • typestring
    Always stock_batch.completed
  • created_attimestamp

    When it happened.

  • dataobject

    The object as it is now, exactly as its GET endpoint returns it, and what changed.

Related events

Payload
{
  "id": "evt_bfP0GSqKoZFrD72H5Os0rc7HV9XP6eQJu",
  "object": "event",
  "type": "stock_batch.completed",
  "created_at": "2026-10-14T10:02:00Z",
  "data": {
    "object": {
      "id": "bat_bfP0GSqKoZFrD72H5Os0rc7HV9XP6eQJu",
      "object": "stock_batch",
      "stock": {
        "id": "stk_bfP0GSqKoZFrD72H5Os0rc7HV9XP6eQJu",
        "object": "stock",
        "name": "Clicker 50 pack"
      },
      "region": {
        "id": "reg_bfP0GSqKoZFrD72H5Os0rc7HV9XP6eQJu",
        "object": "region",
        "name": "Western Europe"
      },
      "status": "completed",
      "batches": 2,
      "units": {
        "purchased": 100,
        "made": 60,
        "used": 20,
        "available": 40
      },
      "price_paid": {
        "amount": 60000,
        "currency": "usd"
      },
      "unit_price": {
        "amount": 600,
        "currency": "usd"
      },
      "purchase_reference": "ST-8KD2X",
      "origin": "manual",
      "purchased_at": "2026-09-30T10:00:00Z",
      "completed_at": null
    },
    "previous": {
      "status": "in_production"
    },
    "region": null
  }
}