Early bird discounts live! Claim your offer

access_code.generated

Bulk-generate job completes.

Batch-level only — fires once per generation job, not per code. A 10,000-code batch produces one event.

When this fires

A bulk-generation run for access codes completes. The batch is materialized in the database and is now redeemable.

Required ability

project-access-code:view-any — token must carry this at mint time to subscribe an endpoint to this event.

Payload

{
  "id": "evt_01HX...",
  "type": "access_code.generated",
  "created_at": "2026-05-18T10:05:00Z",
  "api_version": "2026-05-01",
  "project_id": "prj_01HX...",
  "data": {
    "batch_id": "btc_01HX...",
    "plan_id": "pln_01HX...",
    "count": 250,
    "expires_at": "2026-08-18T00:00:00Z"
  }
}

Field reference

FieldTypeNotes
idstring ULIDUnique event id, prefixed evt_. Use for idempotent processing.
typestringAlways access_code.generated for this event.
created_atISO 8601 timestampServer-side emission time.
api_versionstringWebhook API contract version.
project_idstring ULIDProject this event belongs to.
data.batch_idstring ULIDBatch identifier the generated codes belong to.
data.plan_idstring ULIDPlan the codes are scoped to.
data.countintegerNumber of codes in the batch.
data.expires_atISO 8601 timestampCommon expiry timestamp for all codes in the batch.

Caveats

How is this guide?

On this page

MemberPass is a product designed by you — for you.

No boardroom full of executives deciding what we ships next. Our roadmap always shaped by you with your feedback.

Share feedback or a request