chore: update generated files from PR #11452#34
Conversation
There was a problem hiding this comment.
The generated schema updates are internally consistent with the upstream contracts I checked, but there is one integration gap to address before releasing this client: the new country context is exposed only in the generated operation types, while the package's documented client wrapper cannot send it.
| language?: unknown; | ||
| language?: string; | ||
| /** @description ISO 3166-1 alpha-2 country code for the customer. Used to filter rewards by country availability. If not provided, the site default is used */ | ||
| country?: string; |
There was a problem hiding this comment.
This adds country as a supported query parameter, but createHeadlessApiClient does not expose any way to send it. That matters because, unlike channel and language, the upstream headless contract does not define a corresponding X-LoyaltyLion-Country header, so every call made through the documented client wrapper will continue to use the site's default country and cannot exercise country-based reward availability. Please add a country option/per-call override and include it in params.query for the wrapper calls that return configuration/customer reward data, or users will have to bypass the client to use this newly generated API surface.
| currency: string; | ||
| /** @description `ISO 639-1` code indicating the language used for any text in this response */ | ||
| language: unknown; | ||
| language: string; |
There was a problem hiding this comment.
Respond to this comment to discuss this review with me
| patch?: never; | ||
| trace?: never; | ||
| }; | ||
| "/headless/2025-06/{site_id}/customers/{merchant_id}/enroll": { |
There was a problem hiding this comment.
This generated endpoint needs a matching createHeadlessApiClient wrapper method before this package is released. The documented client currently exposes the neighboring customer actions (getCustomer, initializeSession, setBirthday, and subscribeToEmailMarketing), but there is no customers.enroll method, so consumers using the package's main API cannot call this new endpoint without dropping down to their own fetch/openapi client. Please add the wrapper method alongside the generated type update.
| patch?: never; | ||
| trace?: never; | ||
| }; | ||
| "/headless/2025-06/{site_id}/customers/{merchant_id}/enroll": { |
There was a problem hiding this comment.
Respond to this comment to discuss this review with me
| patch?: never; | ||
| trace?: never; | ||
| }; | ||
| "/headless/2025-06/{site_id}/customers/{merchant_id}/enroll": { |
There was a problem hiding this comment.
Respond to this comment to discuss this review with me
| patch?: never; | ||
| trace?: never; | ||
| }; | ||
| "/headless/2025-06/{site_id}/customers/{merchant_id}/enroll": { |
There was a problem hiding this comment.
Respond to this comment to discuss this review with me
| @@ -63,6 +63,22 @@ export interface paths { | |||
| patch?: never; | |||
| trace?: never; | |||
| }; | |||
| "/headless/2025-06/{site_id}/customers/{merchant_id}/enroll": { | |||
There was a problem hiding this comment.
Respond to this comment to discuss this review with me
Auto-generated by the CI pipeline.
Source: https://github.com/loyaltylion/hogwarts/pull/11452
These files were regenerated from changes to the API contracts. Review and merge alongside the main PR.
Generated files:
src/types/api.tssrc/types/schemas.ts