@go-labs-sg/event-tech 1.28.0 → 1.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -418,15 +418,14 @@ Collections CSV. Reverse one ledger serving with `stamp correct --stamped false
418
418
  --collection-id <id>`; it returns that serving's stock. Undo an erroneous reversal with `--stamped true
419
419
  --collection-id <id>`: the original item and building must have stock, and a
420
420
  repeat serving restores no stamp credit. Do not supply item, site or points with
421
- a collection ID. Legacy menu stamps still
422
- appear once in stock/history and can be corrected through the existing stamp
423
- workflow. Manager corrections that create a new menu collection also need `--site`
421
+ a collection ID. Stock, counts and history read the ledger only; every menu
422
+ stamp has a ledger row, so a stamp item without one is not counted. Manager corrections that create a new menu collection also need `--site`
424
423
  for building pools. Corrections cannot change an active collection's item.
425
424
 
426
425
  Release prerequisite: apply the additive Event Tech schema before deploying the
427
426
  new runtime (separate authorization). The ledger leaves the unique participant /
428
- station stamp row intact. Do not enable building pools while unattributed legacy
429
- consumption exists; the API rejects stock pool changes it cannot safely attribute.
427
+ station stamp row intact. Do not enable building pools while active collections
428
+ exist; the API rejects stock pool changes it cannot safely attribute.
430
429
  Configure sites before service begins, or keep the original pool until existing
431
430
  collections can be reconciled. Roll back to a runtime that understands the ledger
432
431
  after taking collections: older runtimes cannot account for ledger-only repeats.
@@ -511,7 +510,7 @@ et passport skin clear --event-id <id> --appearance-version 5
511
510
  - `colors.graphic` paints shapes only, never text. `colors.dark` needs 4.5:1 contrast with white.
512
511
  - `skin clear` returns the event to the Go Labs default look (the reverse of `skin set`). Appearance saves that omit `passport`, including `event appearance update`, keep the stored skin.
513
512
  - Uploads accept JPEG, PNG, WebP or GIF up to 25 MB. SVG is not allowed.
514
- - The same commands theme a Staff Redemption event: `colors.graphic`, `colors.dark` and `emphasis`, together with the event theme (`et event appearance`), also colour the crew counter and its prize wheel (Settings > Appearance > Counter look in the web app). `heroImage` and `logo` are used only by Event Passport; the Staff Redemption counter ignores them. `skin set` leaves a stored `heroImage` or `logo` as it is unless the patch names it; `skin clear` resets the whole block, including them. To match the Micron Passport look: theme `accentColor` `#06befe`, `backgroundColor` `#e3f7ff`, `textColor` `#0b2d5b` (`et event appearance update`), then `skin set --skin-json '{"colors":{"graphic":"#e8483b","dark":"#0b2d5b"},"emphasis":"ink"}'`.
513
+ - The same commands theme a Staff Redemption event: `colors.graphic`, `colors.dark` and `emphasis`, together with the event theme (`et event appearance`), also colour the crew counter and its prize wheel (Settings > Appearance > Counter look in the web app). `heroImage` and `logo` also show on the Staff Redemption employee sign-in and QR page (the same layout as the Event Passport sign-in), but not on the crew counter. `skin set` leaves a stored `heroImage` or `logo` as it is unless the patch names it; `skin clear` resets the whole block, including them. To match the Micron Passport look: theme `accentColor` `#06befe`, `backgroundColor` `#e3f7ff`, `textColor` `#0b2d5b` (`et event appearance update`), then `skin set --skin-json '{"colors":{"graphic":"#e8483b","dark":"#0b2d5b"},"emphasis":"ink"}'`.
515
514
 
516
515
  Station cover art uses the station's existing `imageKey`:
517
516
 
@@ -585,11 +584,22 @@ et event create --organization-id <org-id> --name "Example Staff Appreciation" \
585
584
  # AT_MOST_ONE_PER_GROUP_OR_NONE), what happens at the wrong site (REFUSE or
586
585
  # SERVE_FROM_COUNTER) and the draw (REMAINING_HEADCOUNT, or FIXED_RATE with
587
586
  # fixedWinRatePercent). sessionRule is optional: OWN_SHIFT (the default) serves people
588
- # only during their own shift's session; ANY_OPEN_SESSION serves them during whichever
589
- # session is open now, from that session's sets and prizes. Both draws work with either
590
- # session rule; under REMAINING_HEADCOUNT a walk-in from another shift or site draws from
591
- # the open session's prizes as one extra person, so heavy walk-in traffic can use up
592
- # prizes before that session's last arrivals. counterOrder is optional too:
587
+ # only during their own shift's session, from its sets and prizes. ANY_OPEN_SESSION
588
+ # ("any open session: own shift's stock first", as of 19 Nov 2026): a person rostered at
589
+ # the counter's site gets the set from their own shift's slot there, from their
590
+ # session's (Singapore) day onwards whatever the hour (on an earlier day they are
591
+ # served like a walk-in), while it has sets left, else from the open session's slot at the same site with the
592
+ # most sets left (NO_SETS_LEFT when none has; never NO_OPEN_SESSION), and always draws
593
+ # from their own shift's slot's prizes there. A walk-in rostered at another site (or
594
+ # none) is served only while a session is open (NO_OPEN_SESSION otherwise), from their
595
+ # own shift's slot at the counter's site while their session is open and it has sets
596
+ # left, else the open session's slot there with the most sets left, and always spins for
597
+ # no prize. card.setSession and card.setsFromOtherSession say which slot gives the set,
598
+ # card.prizesHere whether the spin can win, and card.ownSessionTiming warns NOT_STARTED
599
+ # or ENDED when their own session is not open. Session times decide which other
600
+ # sessions' stock is usable: set them correctly. Both draws work with either session
601
+ # rule; under REMAINING_HEADCOUNT a site's prizes are shared only over its own people,
602
+ # as walk-ins never draw them. counterOrder is optional too:
593
603
  # FOOD_THEN_DRAW (the default when unset: items first, then the wheel) or DRAW_THEN_FOOD
594
604
  # (spin first, record the food afterwards). They lock once the first redemption exists;
595
605
  # changing them then needs overrideReason.
@@ -645,14 +655,14 @@ et staff-redemption roster import --event-id <event-id> --file ./roster.csv \
645
655
  et staff-redemption roster counts --input '{"eventId":"<event-id>"}'
646
656
  et staff-redemption setup get --input '{"eventId":"<event-id>"}' # missingPolicies must be []
647
657
 
648
- # 8. Day of: look an Employee ID up, then redeem. lookup writes nothing but failed-lookup
649
- # throttle records. Generate one clientRequestId per redemption; retrying with the same
650
- # UUID returns the stored receipt and never redeems twice.
658
+ # 8. Day of: look an Employee ID up, then redeem. lookup writes nothing; Employee IDs not on
659
+ # the roster never lock a counter out. Generate one clientRequestId per redemption;
660
+ # retrying with the same UUID returns the stored receipt and never redeems twice.
651
661
  et staff-redemption lookup \
652
662
  --input '{"eventId":"<event-id>","siteId":"<site-id>","employeeId":"E1001"}'
653
663
  # Or look a person up by the QR code from their employee page: send "code" instead of
654
664
  # "employeeId" (exactly one of the two). The code is valid for 10 minutes plus 1 minute of
655
- # grace after expiry; an invalid, expired or other-event code is refused and costs no failed-lookup attempt. The card then has
665
+ # grace after expiry; an invalid, expired or other-event code is refused. The card then has
656
666
  # awayFromRosterSite and rosterSiteId, and counter context returns wrongSite, wrongSiteMessage
657
667
  # and staffIdLabel.
658
668
  et staff-redemption lookup \
@@ -763,14 +773,38 @@ it with the filters.
763
773
  whose roster site and shift are the slot's), `collected` (how many of them have an active claim
764
774
  anywhere), `items` (`[{ "itemId", "handedOut" }]`, only items handed out in that slot; voided
765
775
  claims are not counted), `walkIns` (unreleased draws in the slot by people whose roster site or
766
- shift, as the roster reads now, is not the slot's) and `walkInPrizes` (how many of those won).
767
- Under `REMAINING_HEADCOUNT` each walk-in draws as one extra person, so `walkInPrizes` is roughly
768
- how many fewer prizes the slot's own people share.
776
+ shift, as the roster reads now, is not the slot's, leaving out no-prize draws by another shift:
777
+ those are placeholders recorded where the set came from when no prize slot could be used) and
778
+ `walkInPrizes` (how many of those won).
779
+ Under `ANY_OPEN_SESSION`, since 19 Nov 2026 a walk-in from another site always spins for no
780
+ prize, so `walkInPrizes` only counts draws made before that change (under `OWN_SHIFT` a person
781
+ served away from their roster site still draws from the counter site's prizes, and under
782
+ `REMAINING_HEADCOUNT` counts there as one extra person).
783
+ `stock summary` and `roster counts` are cached for up to 5 seconds and are not refreshed by
784
+ every counter claim, so during a burst of claims they can lag by up to 5 seconds; a void,
785
+ release, setup change or roster change refreshes them at once. `claims list` and `claims counts`
786
+ are not delayed.
769
787
  - `claims list` and `export` rows carry `groupName` on each item and `awayFromRosterSite` (true
770
788
  when the person was served at a site other than their roster site; false when their roster
771
789
  site matches no site). The CSV export adds "Roster site" and "Away from roster site" columns
772
790
  and writes items as `Group: Item`.
773
791
  - `counter context` adds `event` (`{ id, name, status, startDateTime, endDateTime }`) and `counterOrder`.
792
+ - `counter context` adds `openSessionIds` (under `ANY_OPEN_SESSION`, every session open now; `[]`
793
+ under `OWN_SHIFT`). `openSession` stays but is informational only: since 19 Nov 2026 no single
794
+ session serves everyone under `ANY_OPEN_SESSION`.
795
+ - `lookup` cards add `setSession` (`{ id, name, shift }` or null: the session whose sets at
796
+ this site a redemption would use now; null, with `setsFromOtherSession` false, on a card refused
797
+ before sets are counted), `setsFromOtherSession`, `prizesHere` (false when the spin here can only
798
+ be no prize: no slot for their shift at this site, or under `ANY_OPEN_SESSION` they are rostered
799
+ at another site) and `ownSessionTiming` (`NOT_STARTED`, `ENDED` or null; `ANY_OPEN_SESSION` only, a
800
+ warning: a person rostered here still uses their own shift's sets and prizes, a walk-in gets an
801
+ open session's set and a no-prize spin).
802
+ `card.session` is now always the person's own shift's session (their prizes), and
803
+ `slotSetsLeft` is what is left in `setSession`'s slot.
804
+ - Receipts (`redeem`, `counter claims`) add `session.shift` and `draw.slot` (`{ id, session: { id,
805
+ name, shift }, site: { id, name } }`: where the draw was made). `claims list` and `export` rows
806
+ add `draw.slot` (`{ id, site, session }`), where a released prize returns; it differs from the
807
+ claim's site and session when the set came from another session or the draw was reused.
774
808
  - Draw-first claims: `claims list`, `export` and `counter claims` rows and receipts carry `itemsPending` (true until the food is recorded) and `itemsRecordedAt` (null until then; also null on food-first claims). `claims counts` returns `totalCount`, `activeCount`, `itemsPendingCount` and `voidedCount`. Voiding a claim that is still pending releases its set; a redo reuses the same prize outcome and is pending again.
775
809
  - `counter claims` takes `scope`: `mine` (default) is the claims made by you at the site (a crew
776
810
  device sees its own crew session's), `site` is every claim at the site whoever served it.
@@ -310,7 +310,7 @@ Run `et <command> --help` for the full input JSON Schema.
310
310
  - `et staff-redemption setup get` → `event.staffRedemption.getStaffRedemptionSetup` (query)
311
311
  - Get the whole staff redemption setup: settings (including counterOrder, always resolved: FOOD_THEN_DRAW when never set, and the employee sign-in settings loginMethods, staffIdLabel and wrongSiteMessage, the two texts null while unset), employeeLogin.googleAvailable (whether Google sign-in can be turned on), missingPolicies and policiesLocked, sites (with crew access status), sessions, slots with setsIssued, item groups and items, prizes and prize stock. readiness lists what is still missing before counters can serve people (ready, and items of code plus short text); truncated is true when a list was cut at its cap. Archived rows are included with archivedAt; holds no personal data. Needs event.operate.
312
312
  - `et staff-redemption settings update` → `event.staffRedemption.updateStaffRedemptionSettings` (mutation)
313
- - Update eligibleShifts, itemRule, wrongSite, sessionRule, drawPolicy, fixedWinRatePercent, counterOrder and the employee sign-in settings loginMethods (emailOtp, google, guest, staffId, staffIdRequiresLastName; every method is off until turned on; google needs the server's Google sign-in), staffIdLabel (what the roster identifier is called, default 'Employee ID') and wrongSiteMessage (the warning both counters show for a person rostered at another site, max 300 characters); null or blank resets a text to its default. Omitted fields are unchanged. sessionRule is OWN_SHIFT (the default when unset: only during the person's own shift's session) or ANY_OPEN_SESSION (whichever session is open now, from that session's sets and prizes; works with either drawPolicy, and under REMAINING_HEADCOUNT a walk-in from another shift or site draws from the open session's prizes as one extra person, so heavy walk-in traffic can use up prizes before that session's last arrivals). counterOrder is FOOD_THEN_DRAW (the default when never set) or DRAW_THEN_FOOD (the person spins first and the food is recorded afterwards); it is not a required policy (never in missingPolicies). Policies, sessionRule and counterOrder included, lock once a redemption exists (setup get shows policiesLocked): then a change needs overrideReason, recorded in the activity log. loginMethods, staffIdLabel and wrongSiteMessage are not policies: they never lock and never need overrideReason.
313
+ - Update eligibleShifts, itemRule, wrongSite, sessionRule, drawPolicy, fixedWinRatePercent, counterOrder and the employee sign-in settings loginMethods (emailOtp, google, guest, staffId, staffIdRequiresLastName; every method is off until turned on; google needs the server's Google sign-in), staffIdLabel (what the roster identifier is called, default 'Employee ID') and wrongSiteMessage (the warning both counters show for a person rostered at another site, max 300 characters); null or blank resets a text to its default. Omitted fields are unchanged. sessionRule is OWN_SHIFT (the default when unset: only during the person's own shift's session, from its sets and prizes) or ANY_OPEN_SESSION ('any open session: own shift's stock first'. A person rostered at the counter's site gets their set, from their session's (Singapore) day onwards whatever the hour (on an earlier day they are served like a walk-in), from their own shift's slot there while it has sets left, else from the slot at the same site of the open session with the most sets left (NO_SETS_LEFT when none has), and always draws from their own shift's slot's prizes there; they are never refused NO_OPEN_SESSION. A walk-in rostered at another site (or none) is served only while a session is open (NO_OPEN_SESSION otherwise), from their own shift's slot at the counter's site while their session is open and it has sets left, else from the open session's slot there with the most sets left, and their spin is always no prize; works with either drawPolicy, and under REMAINING_HEADCOUNT a site's prizes are shared only over its own people). counterOrder is FOOD_THEN_DRAW (the default when never set) or DRAW_THEN_FOOD (the person spins first and the food is recorded afterwards); it is not a required policy (never in missingPolicies). Policies, sessionRule and counterOrder included, lock once a redemption exists (setup get shows policiesLocked): then a change needs overrideReason, recorded in the activity log. loginMethods, staffIdLabel and wrongSiteMessage are not policies: they never lock and never need overrideReason.
314
314
  - Confirm: `--allow-state-change` `--target <input.eventId>`
315
315
  - `et staff-redemption site upsert` → `event.staffRedemption.upsertStaffRedemptionSite` (mutation)
316
316
  - Create a site (omit siteId) or rename and reorder one (give siteId). Use staff-redemption archive set to archive or unarchive it.
@@ -322,7 +322,7 @@ Run `et <command> --help` for the full input JSON Schema.
322
322
  - Clear a site's crew password, which turns its crew link off and ends every crew session at that site.
323
323
  - Confirm: `--allow-state-change` `--target <input.eventId>`
324
324
  - `et staff-redemption session upsert` → `event.staffRedemption.upsertStaffRedemptionSession` (mutation)
325
- - Create a session (omit sessionId) or update one: name, shift letter, and optional startsAt and endsAt (ISO date-times; null or omitted means the session is open whenever the event is). Each shift has one session; a session with redemptions keeps its shift. Under sessionRule ANY_OPEN_SESSION, counters serve everyone from the open session that started most recently, so a session with no endsAt is used until a later one starts.
325
+ - Create a session (omit sessionId) or update one: name, shift letter, and optional startsAt and endsAt (ISO date-times; null or omitted means the session is open whenever the event is). Each shift has one session; a session with redemptions or unreleased draws in its slots keeps its shift. Under sessionRule ANY_OPEN_SESSION the times decide which other sessions' stock counters may use: only sessions open now (started, or no startsAt, and not ended, or no endsAt). A person rostered at the counter's site uses their own shift's slot there from their session's (Singapore) day onwards, whatever the hour, (the set while it has sets left, prizes always), then the open session's slot there with the most sets left. A walk-in from another site gets a set only from sessions open now (their own shift's slot there while their session is open and it has sets left, else the open session's slot with the most sets left; NO_OPEN_SESSION when none is open) and always spins for no prize. Set the times correctly.
326
326
  - Confirm: `--allow-state-change` `--target <input.eventId>`
327
327
  - Date fields: `startsAt`, `endsAt`
328
328
  - `et staff-redemption slot set` → `event.staffRedemption.setStaffRedemptionSlot` (mutation)
@@ -361,23 +361,23 @@ Run `et <command> --help` for the full input JSON Schema.
361
361
  - Add or update one roster entry by employeeId (name, siteName, shift and workShift are required and can be null; allowance is optional). The site is matched by name, and allowance cannot go below the sets the person already collected. The archived state is unchanged (use staff-redemption archive set).
362
362
  - Confirm: `--allow-state-change` `--target <input.eventId>`
363
363
  - `et staff-redemption claims list` → `event.staffRedemption.getStaffRedemptionClaims` (query)
364
- - List redemption claims, newest first (cursor paged), with items (with groupName), draw outcome, site, awayFromRosterSite (served at a site other than the roster site), session and void state; each row also has itemsPending (true while the prize was drawn but the food is not recorded yet) and itemsRecordedAt; filter by search, siteId, sessionId and status (active, items-pending, voided, all). items-pending is active claims that still wait for their food.
364
+ - List redemption claims, newest first (cursor paged), with items (with groupName), draw outcome (draw.slot is the site and session the draw was made in, where a released prize returns; it can differ from the claim's when the set came from another session or the draw was reused), site, awayFromRosterSite (served at a site other than the roster site), session and void state; each row also has itemsPending (true while the prize was drawn but the food is not recorded yet) and itemsRecordedAt; filter by search, siteId, sessionId and status (active, items-pending, voided, all). items-pending is active claims that still wait for their food.
365
365
  - `et staff-redemption claims counts` → `event.staffRedemption.getStaffRedemptionClaimCounts` (query)
366
366
  - Count claims matching the same filters as claims list : returns totalCount (all filters, status included), then activeCount, itemsPendingCount (active claims whose food is not recorded yet) and voidedCount, which ignore the status filter.
367
367
  - `et staff-redemption claims void` → `event.staffRedemption.voidStaffRedemptionClaim` (mutation)
368
- - Void a claim with a reason (a claim still waiting for its food too). The set returns to the person and the slot; the prize draw is kept, so a redo shows the same outcome until staff-redemption draw release. Claims list shows each draw's activeClaimCount.
368
+ - Void a claim with a reason (a claim still waiting for its food too). The set returns to the person and the slot; the prize draw is kept, so a redo shows the same outcome (even a draw made in another slot or a no-prize draw) until staff-redemption draw release. Claims list shows each draw's activeClaimCount.
369
369
  - Confirm: `--allow-state-change` `--target <input.eventId>`
370
370
  - `et staff-redemption draw release` → `event.staffRedemption.releaseStaffRedemptionDraw` (mutation)
371
- - Release a person's prize draw (draw.id from claims list) with a reason: a won prize returns to its slot's stock and the person draws again on their next redemption. Refused (CONFLICT) while an active, not voided redemption still shows the draw (claims list draw.activeClaimCount > 0); void it first, or pass the explicit override allowWhileClaimActive: true to release a prize while its redemption stays recorded (for example a paper entry). The override is recorded in the activity log.
371
+ - Release a person's prize draw (draw.id from claims list) with a reason: a won prize returns to the stock of the slot it was drawn in (claims list draw.slot) and the person draws again on their next redemption. Refused (CONFLICT) while an active, not voided redemption still shows the draw (claims list draw.activeClaimCount > 0); void it first, or pass the explicit override allowWhileClaimActive: true to release a prize while its redemption stays recorded (for example a paper entry). The override is recorded in the activity log.
372
372
  - Confirm: `--allow-state-change` `--target <input.eventId>`
373
373
  - `et staff-redemption stock summary` → `event.staffRedemption.getStaffRedemptionStockSummary` (query)
374
- - Show sets and prizes issued and left per site and session, with per-slot item counts (items), roster headcount and how many of them collected, walk-ins (walkIns: unreleased draws in the slot by people whose roster site or shift is not the slot's) and how many of them won (walkInPrizes), plus event-wide item totals.
374
+ - Show sets and prizes issued and left per site and session, with per-slot item counts (items), roster headcount and how many of them collected, walk-ins (walkIns: unreleased draws in the slot by people whose roster site or shift is not the slot's, leaving out no-prize draws by another shift, which are the placeholders recorded where a set came from when no prize slot could be used) and how many of them won (walkInPrizes; under ANY_OPEN_SESSION walk-ins from another site spin for no prize since 19 Nov 2026, so it only counts earlier draws there), plus event-wide item totals.
375
375
  - `et staff-redemption counter context` → `event.staffRedemption.getStaffRedemptionCounterContext` (query)
376
- - Counter view for one site (siteId): the event (name, status, dates), counterOrder (FOOD_THEN_DRAW or DRAW_THEN_FOOD, the order crew follow), items to choose from, the site's sessions with sets and prizes left, and any missing policies. wrongSite is the policy for people rostered at another site (null while unset), wrongSiteMessage the warning to show for them and staffIdLabel what the roster identifier is called (defaults applied). sessionRule is the session policy; under ANY_OPEN_SESSION, openSession is the session every counter serves from now (null when none is open) and openSessionChangesAt when that next changes (serverTime is the server clock at the read). Needs event.operate.
376
+ - Counter view for one site (siteId): the event (name, status, dates), counterOrder (FOOD_THEN_DRAW or DRAW_THEN_FOOD, the order crew follow), items to choose from, the site's sessions with sets and prizes left, and any missing policies. wrongSite is the policy for people rostered at another site (null while unset), wrongSiteMessage the warning to show for them and staffIdLabel what the roster identifier is called (defaults applied). sessionRule is the session policy; under ANY_OPEN_SESSION, openSessionIds are the sessions open now and openSessionChangesAt when that next changes (serverTime is the server clock at the read); openSession (the open session that started most recently) is informational only, as no single session serves everyone (a person rostered at the site uses their own shift's slot from that session's Singapore day onwards, whatever the hour; walk-ins and people whose session is on a later day use only open sessions' stock). Needs event.operate.
377
377
  - `et staff-redemption lookup` → `event.staffRedemption.lookupStaffRedemptionEmployee` (mutation)
378
- - Look up an Employee ID (employeeId) or a scanned employee QR code (code, from the employee page; valid for ten minutes, refused with a message to refresh when expired or forged) at a site, giving exactly one of the two: who they are, the card's awayFromRosterSite and rosterSiteId (true when their roster site is not this site), what they already collected (a collected card's receipt carries itemsPending and itemsRecordedAt), the session whose sets would be used (card.session; under ANY_OPEN_SESSION with none open, the next to open or else the last to close) and whether a redemption would go ahead (refusal code otherwise). Writes nothing but failed-lookup throttle records, so it needs no confirmation flags. Needs event.operate.
378
+ - Look up an Employee ID (employeeId) or a scanned employee QR code (code, from the employee page; valid for ten minutes, refused with a message to refresh when expired or forged) at a site, giving exactly one of the two: who they are, the card's awayFromRosterSite and rosterSiteId (true when their roster site is not this site), what they already collected (a collected card's receipt carries itemsPending and itemsRecordedAt), their own shift's session (card.session, the only one whose prizes they can draw from), the session whose sets at this site a redemption would use now (card.setSession, with card.setsFromOtherSession true when it is not their own; both null and false on a card refused before sets are counted; card.slotSetsLeft is what is left in it), card.prizesHere (false when the spin here can only be no prize: no slot for their shift at this site, or under ANY_OPEN_SESSION they are rostered at another site or their own session is on a later Singapore day), card.heldDraw (their unreleased draw from an earlier, voided redemption, shown again instead of a new spin; null when the next redemption draws afresh), card.ownSessionTiming (ANY_OPEN_SESSION only: NOT_STARTED or ENDED when their own session is not open, a warning; a person rostered here whose session has started or is due that Singapore day still uses their own shift's sets and prizes, while a walk-in or a person whose session is on a later day gets an open session's set and a no-prize spin; null otherwise) and whether a redemption would go ahead (refusal code otherwise). Writes nothing and is not rate-limited, so it needs no confirmation flags. Needs event.operate.
379
379
  - `et staff-redemption redeem` → `event.staffRedemption.redeemStaffRedemption` (mutation)
380
- - Redeem for an Employee ID at a site: records the chosen itemIds and reveals the prize outcome the server decides in the same transaction. clientRequestId is a UUID you generate; retry with the same one and you get the stored receipt, never a second redemption. When the event's counterOrder is DRAW_THEN_FOOD, itemIds must be [] (anything else is BAD_REQUEST): the claim, the set and the prize draw are recorded together and the receipt has itemsPending true until staff-redemption claims record-items. The item rule is not checked at the spin. Needs event.operate.
380
+ - Redeem for an Employee ID at a site: records the chosen itemIds and reveals the prize outcome the server decides in the same transaction. clientRequestId is a UUID you generate; retry with the same one and you get the stored receipt, never a second redemption. The set and the draw follow the event's sessionRule. Under ANY_OPEN_SESSION a person rostered at this site gets the set, from their session's (Singapore) day onwards whatever the hour (on an earlier day they are served like a walk-in), from their own shift's slot here while it has sets left, else the open session's slot here with the most sets left (receipt.session names it; NO_SETS_LEFT when none has), and always draws from their own shift's slot's prizes here; a walk-in rostered at another site is served only while a session is open (NO_OPEN_SESSION otherwise), from their own shift's slot here while their session is open and it has sets left, else the open session's slot here with the most sets left, and always gets no prize. receipt.draw.slot is the slot, session and site the draw was made in (a reused draw keeps its own). When the event's counterOrder is DRAW_THEN_FOOD, itemIds must be [] (anything else is BAD_REQUEST): the claim, the set and the prize draw are recorded together and the receipt has itemsPending true until staff-redemption claims record-items. The item rule is not checked at the spin. Needs event.operate.
381
381
  - Confirm: `--allow-state-change` `--target <input.eventId>`
382
382
  - `et staff-redemption claims record-items` → `event.staffRedemption.recordStaffRedemptionClaimItems` (mutation)
383
383
  - Record the food (itemIds, checked against the item rule) for a claim that was drawn first (itemsPending true, counterOrder DRAW_THEN_FOOD). siteId must be the claim's own site (claims list shows it). Writes the items, sets itemsPending false and itemsRecordedAt, and logs it; it deducts no set and makes no draw. Idempotent: the same items again return replayed true with the stored receipt. CONFLICT when different items were already recorded, when the claim is voided, or when the claim was food-first (nothing pending). Needs event.operate at that site (a manager has it). Returns status recorded, replayed and the receipt.