Skip to content

chore: update generated files from PR #11479#38

Open
loyaltylion-bot wants to merge 1 commit into
mainfrom
codegen/pr-11479
Open

chore: update generated files from PR #11479#38
loyaltylion-bot wants to merge 1 commit into
mainfrom
codegen/pr-11479

Conversation

@loyaltylion-bot

Copy link
Copy Markdown
Collaborator

Auto-generated by the CI pipeline.

Source: https://github.com/loyaltylion/hogwarts/pull/11479

These files were regenerated from changes to the API contracts. Review and merge alongside the main PR.

Generated files:

  • src/types/api.ts
  • src/types/schemas.ts

@loyaltylion-minerva loyaltylion-minerva Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The generated types look internally consistent, but the new country-aware request parameter is not reachable through the package's public createHeadlessApiClient wrapper. Since the parameter controls reward country availability, publishing only the generated types would leave wrapper users on site-default filtering even when they know the shopper's country.

I reviewed this statically only, per the environment constraints.

Comment thread src/types/api.ts
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;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This adds country as a supported request parameter, and the description says it is used to filter rewards by country availability. However, the exported createHeadlessApiClient wrapper still has no country option and none of its methods accept or pass a country query parameter, so consumers using the advertised client API will keep omitting it and get site-default filtering. For shoppers outside the default country, that can expose or redeem rewards using the wrong availability rules. Please thread this through the client API before publishing these generated types.

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