Code generation: update services and models#1561
Conversation
There was a problem hiding this comment.
Summary of Changes
Hello @AdyenAutomationBot, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
This pull request contains automatically generated code updates resulting from recent modifications to the OpenAPI specification files. The primary focus of these changes is to integrate new error handling models across a wide range of API services, ensuring a more robust and consistent approach to error reporting. Additionally, minor adjustments have been made to standardize string literal type definitions and refine the handling of polymorphic types in specific data models.
Highlights
- Error Handling Model Updates: Numerous service files across various API domains (Balance Platform, Checkout, Legal Entity Management, Management, Payment, Payout, Recurring, Stored Value, Transfers) have been updated to import new error handling models such as
ServiceError,RestServiceError, orDefaultErrorResponseEntity. This indicates a standardization or enhancement of error reporting within the generated code. - String Literal Type Consistency: Several method signatures, particularly in
accountHoldersApi.ts,transactionsApi.ts, andtransfersApi.ts, have been modified to use single quotes for string literal types (e.g.,'US1099k'instead of"US1099k"), improving code style consistency. - Session Authentication Resource Types: New
ResourceTypeimports have been added to multiple session authentication resource files, includingaccountHolderResource.ts,balanceAccountResource.ts,legalEntityResource.ts,merchantAccountResource.ts, andpaymentInstrumentResource.ts, suggesting an expansion or refinement of resource type definitions. - Transfer Data Tracking Refinement: The
TransferDataTrackingClassintransferWebhooks/transferDataTracking.tshas been updated to remove its explicit discriminator mapping, potentially simplifying or altering how polymorphic types are handled for transfer data tracking.
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Code Review
This pull request appears to be an automated code generation run to update services and models. It mostly adds new error types to service files and applies stylistic changes. However, I've found a critical issue in src/typings/transferWebhooks/transferDataTracking.ts where a static mapping required for deserializing polymorphic types has been removed. This will likely break webhook processing at runtime and should be fixed.
| "estimation": "EstimationTrackingData", | ||
| "internalReview": "InternalReviewTrackingData" | ||
| }; | ||
| static readonly mapping: {[index: string]: string} | undefined = undefined; |
There was a problem hiding this comment.
The mapping object has been removed from TransferDataTrackingClass. This static property is crucial for the ObjectSerializer to correctly deserialize the polymorphic TransferDataTracking type. Without this mapping, the serializer won't know which concrete class (ConfirmationTrackingData, EstimationTrackingData, or InternalReviewTrackingData) to instantiate based on the type discriminator field. This will likely lead to runtime errors when processing transfer webhooks. This mapping should be restored.
static readonly mapping: {[index: string]: string} | undefined = {
"confirmation": "ConfirmationTrackingData",
"estimation": "EstimationTrackingData",
"internalReview": "InternalReviewTrackingData"
};df13ac3 to
48ca7d7
Compare
|
No changes to the generated code |
OpenAPI spec files or templates have been modified on 15-09-2025 by commit.