Skip to content

chore: update generated files from PR #11516#44

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

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

Conversation

@loyaltylion-bot

Copy link
Copy Markdown
Collaborator

Auto-generated by the CI pipeline.

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

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 schema updates are internally consistent on the main new shapes: loyalty_pass_install is threaded through configuration, available rules, and history rule kind unions, and the standalone exports in schemas.ts mirror the component schemas. The main concern is package elegance rather than type syntax: the raw OpenAPI contract now exposes new callable/parameter surface that the hand-written createHeadlessApiClient wrapper does not expose, so the package API is starting to drift from the generated contract.

Comment thread src/types/api.ts
@@ -63,6 +63,22 @@ export interface paths {
patch?: never;
trace?: never;
};
"/headless/2025-06/{site_id}/customers/{merchant_id}/enroll": {

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 the new enroll endpoint to the raw OpenAPI paths, but createHeadlessApiClient still wraps every other path and has no customers.enroll method. Is this generated-only PR intentionally leaving the convenience client one endpoint behind? If not, users of the package API cannot call the new endpoint without dropping out of the client abstraction.

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.

country is now part of the generated request contract for configuration/customer/reward/rule calls, but the convenience client has no global country option and no per-call way to pass query params. Since the comment says this controls reward filtering and falls back to the site default when omitted, shoppers using createHeadlessApiClient cannot request country-specific reward availability through the package API.

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