Skip to content

fix(guests)!: remove code from the guest create payloads (AIRLST-6003) - #147

Open
mish-ka-mishka wants to merge 1 commit into
masterfrom
fix/AIRLST-6003-remove-guest-code
Open

mish-ka-mishka wants to merge 1 commit into
masterfrom
fix/AIRLST-6003-remove-guest-code

Conversation

@mish-ka-mishka

Copy link
Copy Markdown
Collaborator

Summary

The Suite always generates the guest code (AIRLST-6003). Core PR https://github.com/airlst/core/pull/6278 is merged into master.

The SDK no longer declares code on CreateCompanionBodyInterface. All create bodies extend that interface, so no create method accepts code now.

SDK method Endpoint code in core
create(), GuestManager.create() POST /events/{event}/guests 422
createRecommendation() POST /events/{event}/guests/{code}/recommendations 422
createCompanion() POST /events/{event}/guests/{code}/companions ignored (no validation rule)
inline companions[] in create() same as create() ignored (no validation rule)

The path parameter code (for example createCompanion('guest-code', …)) does not change.

Version

0.0.24 → 0.1.0. The latest release is stable, so the skill rule increments the minor. The change breaks TypeScript callers that pass code. Confirm the version before the release.

Verification

  • yarn run check, yarn run test --run (81 tests) and yarn run build pass.
  • A temporary tsc --strict file with @ts-expect-error on code in create(), createRecommendation(), createCompanion(), inline companions and GuestManager.create() exited 0. The valid calls without code compile.

Merge

Do not merge before core #6278 is on production. Do not release until then.

🤖 Generated with Claude Code

The Suite always generates the guest code. Core PR airlst/core#6278 makes
POST /events/{event}/guests and POST /guests/{code}/recommendations refuse
a code in the body with 422. The companion endpoints ignore it.

The SDK no longer declares code on CreateCompanionBodyInterface, so
create(), createCompanion(), createRecommendation(), inline companions and
GuestManager.create() do not accept it. The version is now 0.1.0.

BREAKING CHANGE: a TypeScript caller that passes code to a create method
gets a type error. Remove the field and read data.guest.code from the
response.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant