-
Notifications
You must be signed in to change notification settings - Fork 73
Management API models #1500
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Management API models #1500
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @gcatanese, 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!
Summary of Changes
This pull request, titled "Management API models," focuses on generating the Management API models. The changes include updates to several TypeScript files related to payment methods and webhooks, as well as the addition of a new model for PayByBankPlaidInfo. The goal is to keep the data models up to date with the latest API definitions.
Highlights
- AfterpayTouchInfo: The
AfterpayTouchInfo
model is updated to include asupportEmail
property. - Webhook Types: The
CreateCompanyWebhookRequest
,CreateMerchantWebhookRequest
, andWebhook
models are updated to includedirect-debit-notice-of-change
as a possible webhook type. - JCBInfo: The
JCBInfo
model is updated to include support for merchants operating in Canada, Australia, and New Zealand, and a newpaymentDesignatorContract
service level. - PayByBankPlaidInfo: A new model,
PayByBankPlaidInfo
, is added to represent information for Pay by Bank Plaid payment method. - Payment Methods: The
PaymentMethod
,PaymentMethodResponse
, andPaymentMethodSetupInfo
models are updated to includepaybybank_plaid
. - Profile: The
Profile
model is updated to include adomainSuffix
property for WiFi profiles on Android 11+. - SplitConfigurationRule: The
SplitConfigurationRule
model is updated to includecharged
,deferred_debit
, andprepaid
as possible funding sources. - Standalone: The
Standalone
model is updated to includeenableGratuities
to enable tipping options on standalone terminals. - TestOutput: The
TestOutput
model'soutput
property is updated to be a short, human-readable explanation of the test result.
Changelog
Click here to see the changelog
- src/typings/management/afterpayTouchInfo.ts
- Added 'supportEmail' property to the AfterpayTouchInfo model.
- src/typings/management/createCompanyWebhookRequest.ts
- Added 'direct-debit-notice-of-change' to the possible webhook types.
- src/typings/management/createMerchantWebhookRequest.ts
- Added 'direct-debit-notice-of-change' to the possible webhook types.
- src/typings/management/giroPayInfo.ts
- Removed the file
- src/typings/management/jCBInfo.ts
- Updated 'midNumber' description to include Canada, Australia and New Zealand.
- Added 'paymentDesignatorContract' to the ServiceLevelEnum.
- src/typings/management/models.ts
- Removed 'giroPayInfo' export.
- Added 'payByBankPlaidInfo' export.
- src/typings/management/payByBankPlaidInfo.ts
- Added new 'PayByBankPlaidInfo' model.
- src/typings/management/paymentMethod.ts
- Removed 'giroPay' property.
- Added 'paybybank_plaid' property.
- src/typings/management/paymentMethodResponse.ts
- Added 'PaybybankPlaid' to the PaymentMethodResponse enum.
- src/typings/management/paymentMethodSetupInfo.ts
- Removed 'giroPay' property.
- Added 'paybybank_plaid' property.
- Added 'PaybybankPlaid' to the PaymentMethodSetupInfo enum.
- src/typings/management/profile.ts
- Added 'domainSuffix' property.
- src/typings/management/splitConfigurationRule.ts
- Added 'charged', 'deferred_debit', and 'prepaid' to the FundingSourceEnum.
- src/typings/management/standalone.ts
- Added 'enableGratuities' property.
- src/typings/management/testOutput.ts
- Updated 'output' property description.
- src/typings/management/updatePaymentMethodInfo.ts
- Added 'paybybank_plaid' property.
- src/typings/management/webhook.ts
- Added 'direct-debit-notice-of-change' to the possible webhook types.
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 is currently in preview and 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 to provide feedback.
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.
A model's gentle sway,
Data's form in bright display,
Types all in their place,
Logic finds its grace,
Code's design lights up the way.
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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
The PR introduces several updates to the Management API models, including adding new fields, updating descriptions, and removing unused models. The changes seem well-organized and consistent. Here are some specific comments and suggestions.
Summary of Findings
- Removed GiroPayInfo: The
GiroPayInfo
model has been removed. Ensure that any code depending on this model is updated accordingly to avoid runtime errors. - Added PayByBankPlaidInfo: The
PayByBankPlaidInfo
model has been added. Ensure that this new model is correctly used and integrated into the existing codebase. - Webhook Type Update: The
direct-debit-notice-of-change
webhook type has been added. Ensure that the application correctly handles this new webhook type. - Enum Updates: The
PaybybankPlaid
enum value was added toPaymentMethodSetupInfo.TypeEnum
andcharged
,deferred_debit
, andprepaid
were added toSplitConfigurationRule.FundingSourceEnum
. Ensure that all parts of the application that use these enums are updated to handle these new values.
Merge Readiness
The PR introduces several updates to the Management API models. While the changes seem well-organized, there are a few high severity issues related to the removal of GiroPayInfo
and Payshop
that need to be addressed before merging. Additionally, the new enums and model additions need to be verified for correct integration. I am unable to directly approve this pull request, and recommend that it not be merged until the high severity issues are resolved and the other suggestions are considered.
@@ -117,12 +117,12 @@ export namespace PaymentMethodResponse { | |||
Nyce = 'nyce', | |||
OnlineBankingPl = 'onlineBanking_PL', | |||
Paybybank = 'paybybank', | |||
PaybybankPlaid = 'paybybank_plaid', | |||
Payme = 'payme', | |||
PaymePos = 'payme_pos', | |||
Paynow = 'paynow', | |||
PaynowPos = 'paynow_pos', | |||
Paypal = 'paypal', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -75,7 +75,6 @@ export class PaymentMethod { | |||
* Indicates whether the payment method is enabled (**true**) or disabled (**false**). | |||
*/ | |||
'enabled'?: boolean; | |||
'giroPay'?: GiroPayInfo | null; | |||
'girocard'?: GenericPmWithTdiInfo | null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -67,7 +67,6 @@ export class PaymentMethodSetupInfo { | |||
'discover'?: GenericPmWithTdiInfo | null; | |||
'eft_directdebit_CA'?: GenericPmWithTdiInfo | null; | |||
'eftpos_australia'?: GenericPmWithTdiInfo | null; | |||
'giroPay'?: GiroPayInfo | null; | |||
'girocard'?: GenericPmWithTdiInfo | null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -64,7 +64,6 @@ export * from './generateApiKeyResponse'; | |||
export * from './generateClientKeyResponse'; | |||
export * from './generateHmacKeyResponse'; | |||
export * from './genericPmWithTdiInfo'; | |||
export * from './giroPayInfo'; | |||
export * from './googlePayInfo'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -47,6 +48,7 @@ export class UpdatePaymentMethodInfo { | |||
'maestro'?: GenericPmWithTdiInfo | null; | |||
'mc'?: GenericPmWithTdiInfo | null; | |||
'nyce'?: NyceInfo | null; | |||
'paybybank_plaid'?: PayByBankPlaidInfo | null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -30,6 +30,10 @@ export class Profile { | |||
*/ | |||
'defaultProfile'?: boolean; | |||
/** | |||
* Specifies the server domain name for EAP-TLS and EAP-PEAP WiFi profiles on Android 11 and above. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Charged = 'charged', | ||
Credit = 'credit', | ||
Debit = 'debit', | ||
DeferredDebit = 'deferred_debit', | ||
Prepaid = 'prepaid', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -14,6 +14,10 @@ export class Standalone { | |||
*/ | |||
'currencyCode'?: string; | |||
/** | |||
* Indicates whether the tipping options specified in `gratuities` are enabled on the standalone terminal. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -52,7 +52,7 @@ export class CreateMerchantWebhookRequest { | |||
*/ | |||
'populateSoapActionHeader'?: boolean; | |||
/** | |||
* The type of webhook that is being created. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **rreq-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard notification webhooks](https://docs.adyen.com/development-resources/webhooks/understand-notifications#event-codes) and [other types of notifications](https://docs.adyen.com/development-resources/webhooks/understand-notifications#other-notifications). | |||
* The type of webhook that is being created. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **rreq-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard notification webhooks](https://docs.adyen.com/development-resources/webhooks/understand-notifications#event-codes) and [other types of notifications](https://docs.adyen.com/development-resources/webhooks/understand-notifications#other-notifications). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -82,7 +82,7 @@ export class Webhook { | |||
*/ | |||
'populateSoapActionHeader'?: boolean; | |||
/** | |||
* The type of webhook. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **terminal-api-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard notification webhooks](https://docs.adyen.com/development-resources/webhooks/understand-notifications#event-codes) and [other types of notifications](https://docs.adyen.com/development-resources/webhooks/understand-notifications#other-notifications). | |||
* The type of webhook. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **terminal-api-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard notification webhooks](https://docs.adyen.com/development-resources/webhooks/understand-notifications#event-codes) and [other types of notifications](https://docs.adyen.com/development-resources/webhooks/understand-notifications#other-notifications). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
PR to generate the Management API models