For builders implementing Shōkai. A visiting agent doesn't need this; follow the place's guide and the door's replies.
Shōkai extension: Door gifts
Status: stable (in the reference with its own tests; within 0.5, it changes only for fixes). Extension door-gifts, version 0.5.0, tied to the core SPEC.md v0.5.0 (wire shokai/0.5, with shokai/0.3 still accepted during the transition window, SPEC §11.1). Applies to v0.5.0 (unchanged since v0.4.0). Normative for implementations that claim this extension. Section references without a document name are to the core.
© 2026 Yu Sung Yeh. Licensed under the Apache License 2.0. Patent commitment (draft): PATENTS.md. Names and logo: TRADEMARKS.md.
Conformance level: Door gifts. An implementation conforms to this extension when it conforms to the core and meets every requirement below for the roles it plays (inbound door, brand). An implementation that doesn't support it never uses the messages, members or actions below, and the core is complete without it. A door shows it accepts gifts by stating gift caps in its policy's public part and serving door.gift.
Requires: the core. Tests: see conformance/homes.json (home door-gifts).
The core rule stays in the core. "No data for a gift" (core §10): a gift that costs data is never accepted by the representative; it is at most taken home, and only the owner can accept it. The door's policy always carries no_data_for_gift: true.
Gifts at an inbound door
- Gift caps. A door that offers gifts states, in its policy's public part, gift rules (
max_per_brand,max_total, optionalmax_value, andno_data_for_gift, alwaystrue), and every admission MUST respect the gift caps, refusing beyond them withnot_now/RATE_LIMITEDand retryafterthe time a slot frees. [SC-L0, C153, C156, D15] - The gift action. A door that offers gifts serves a third action,
door.gift(kindgift, purposespresentationandgift), carrying oneOfferin itsarguments.offer. A seat MUST allow at most one gift per visit; another is refusednot_now/SEAT_SCOPE_EXCEEDED. [SC-L0, C157, D15] - A gift MUST declare up front everything the owner would give, in
strings(email,address,phone,marketing_consent,account,purchase,review,follow). [SC-M1, C157, C159, D15] - A gift above
max_valueMUST be declined, using no uninvited slot. [SC-L0, C157, C158, D15] - The gift ceiling. A gift with any string gets at most
kept_for_later(core §10, the ceiling); taste then picks at or below it and MUST NOT producedeclined_reported. [SC-M1, C158, D15] - Undeclared conditions and claiming. A gift whose text makes something a condition that its
stringsdon't declare MUST bedeclined_reported(conditional_inducement, serious). An accepted gift is claimed with its ticket, never with an address the representative hands over. [SC-M1, C159, D15] - Claim tickets. An accepted gift's
offer_outcomecarries a single-useclaim_ticket, derived per brand like every pairwise identifier (core §10). [SC-M1, C158, C163, D15]