chore: update generated files from PR #11481#39
Conversation
There was a problem hiding this comment.
The generated types mostly line up with the source contract changes, but the new country-aware filtering is not usable through this package's public createHeadlessApiClient wrapper yet. Consumers using the wrapper will continue to get site-default country behaviour even when they need shopper-country reward availability.
| 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 new country selector is only exposed in the low-level generated operation types. The public createHeadlessApiClient wrapper never sends params.query for getConfiguration, getCustomer, or initializeSession, and HeadlessApiClientOptions has no country option, while the backend source for this contract reads req.query.country when filtering rewards by country availability. That means merchants using the package's primary client cannot opt into the new country-specific configuration/customer responses; they will always fall back to the site default country. Please add a country option or per-call parameter to the wrapper and forward it in the affected requests.
Auto-generated by the CI pipeline.
Source: https://github.com/loyaltylion/hogwarts/pull/11481
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