-
Notifications
You must be signed in to change notification settings - Fork 88
[configurationwebhooks] Code generation: update services and models #1643
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,109 @@ | ||
| /* | ||
| * The version of the OpenAPI document: v2 | ||
| * | ||
| * | ||
| * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). | ||
| * https://openapi-generator.tech | ||
| * Do not edit this class manually. | ||
| */ | ||
|
|
||
| import { MandateBankAccount } from "./mandateBankAccount"; | ||
|
|
||
|
|
||
| export class Mandate { | ||
| /** | ||
| * The unique identifier of the balance account linked to the payment instrument. | ||
| */ | ||
| "balanceAccountId"?: string; | ||
| "counterparty"?: MandateBankAccount | null; | ||
| "createdAt"?: any; | ||
| /** | ||
| * The unique identifier of the mandate. | ||
| */ | ||
| "id"?: string; | ||
| /** | ||
| * The unique identifier of the payment instrument linked to the mandate. | ||
| */ | ||
| "paymentInstrumentId"?: string; | ||
| /** | ||
| * The status of the mandate. Possible values: **pending**, **approved**, **cancelled**. | ||
| */ | ||
| "status"?: Mandate.StatusEnum; | ||
| /** | ||
| * The type of mandate. Possible value: **bacs**. | ||
| */ | ||
| "type"?: Mandate.TypeEnum; | ||
| "updatedAt"?: any; | ||
|
|
||
| static readonly discriminator: string | undefined = undefined; | ||
|
|
||
| static readonly mapping: {[index: string]: string} | undefined = undefined; | ||
|
|
||
| static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [ | ||
| { | ||
| "name": "balanceAccountId", | ||
| "baseName": "balanceAccountId", | ||
| "type": "string", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "counterparty", | ||
| "baseName": "counterparty", | ||
| "type": "MandateBankAccount | null", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "createdAt", | ||
| "baseName": "createdAt", | ||
| "type": "any", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "id", | ||
| "baseName": "id", | ||
| "type": "string", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "paymentInstrumentId", | ||
| "baseName": "paymentInstrumentId", | ||
| "type": "string", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "status", | ||
| "baseName": "status", | ||
| "type": "Mandate.StatusEnum", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "type", | ||
| "baseName": "type", | ||
| "type": "Mandate.TypeEnum", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "updatedAt", | ||
| "baseName": "updatedAt", | ||
| "type": "any", | ||
| "format": "" | ||
| } ]; | ||
|
|
||
| static getAttributeTypeMap() { | ||
| return Mandate.attributeTypeMap; | ||
| } | ||
|
|
||
| public constructor() { | ||
| } | ||
| } | ||
|
|
||
| export namespace Mandate { | ||
| export enum StatusEnum { | ||
| Approved = 'approved', | ||
| Cancelled = 'cancelled', | ||
| Pending = 'pending' | ||
| } | ||
| export enum TypeEnum { | ||
| Bacs = 'bacs' | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| /* | ||
| * The version of the OpenAPI document: v2 | ||
| * | ||
| * | ||
| * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). | ||
| * https://openapi-generator.tech | ||
| * Do not edit this class manually. | ||
| */ | ||
|
|
||
| import { MandatePartyIdentification } from "./mandatePartyIdentification"; | ||
| import { UKLocalMandateAccountIdentification } from "./uKLocalMandateAccountIdentification"; | ||
|
|
||
|
|
||
| export class MandateBankAccount { | ||
| "accountHolder": MandatePartyIdentification; | ||
| "accountIdentification": UKLocalMandateAccountIdentification; | ||
|
Comment on lines
+15
to
+16
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The properties |
||
|
|
||
| static readonly discriminator: string | undefined = undefined; | ||
|
|
||
| static readonly mapping: {[index: string]: string} | undefined = undefined; | ||
|
|
||
| static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [ | ||
| { | ||
| "name": "accountHolder", | ||
| "baseName": "accountHolder", | ||
| "type": "MandatePartyIdentification", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "accountIdentification", | ||
| "baseName": "accountIdentification", | ||
| "type": "UKLocalMandateAccountIdentification", | ||
| "format": "" | ||
| } ]; | ||
|
|
||
| static getAttributeTypeMap() { | ||
| return MandateBankAccount.attributeTypeMap; | ||
| } | ||
|
|
||
| public constructor() { | ||
| } | ||
| } | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| /* | ||
| * The version of the OpenAPI document: v2 | ||
| * | ||
| * | ||
| * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). | ||
| * https://openapi-generator.tech | ||
| * Do not edit this class manually. | ||
| */ | ||
|
|
||
| import { Mandate } from "./mandate"; | ||
|
|
||
|
|
||
| export class MandateNotificationData { | ||
| /** | ||
| * The unique identifier of the balance platform. | ||
| */ | ||
| "balancePlatform"?: string; | ||
| "mandate"?: Mandate | null; | ||
|
|
||
| static readonly discriminator: string | undefined = undefined; | ||
|
|
||
| static readonly mapping: {[index: string]: string} | undefined = undefined; | ||
|
|
||
| static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [ | ||
| { | ||
| "name": "balancePlatform", | ||
| "baseName": "balancePlatform", | ||
| "type": "string", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "mandate", | ||
| "baseName": "mandate", | ||
| "type": "Mandate | null", | ||
| "format": "" | ||
| } ]; | ||
|
|
||
| static getAttributeTypeMap() { | ||
| return MandateNotificationData.attributeTypeMap; | ||
| } | ||
|
|
||
| public constructor() { | ||
| } | ||
| } | ||
|
|
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,71 @@ | ||
| /* | ||
| * The version of the OpenAPI document: v2 | ||
| * | ||
| * | ||
| * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). | ||
| * https://openapi-generator.tech | ||
| * Do not edit this class manually. | ||
| */ | ||
|
|
||
| import { MandateNotificationData } from "./mandateNotificationData"; | ||
|
|
||
|
|
||
| export class MandateNotificationRequest { | ||
| "data": MandateNotificationData; | ||
| /** | ||
| * The environment from which the webhook originated. Possible values: **test**, **live**. | ||
| */ | ||
| "environment": string; | ||
| /** | ||
| * When the event was queued. | ||
| */ | ||
| "timestamp"?: Date; | ||
| /** | ||
| * Type of webhook. | ||
| */ | ||
| "type": MandateNotificationRequest.TypeEnum; | ||
|
Comment on lines
+14
to
+26
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The properties |
||
|
|
||
| static readonly discriminator: string | undefined = undefined; | ||
|
|
||
| static readonly mapping: {[index: string]: string} | undefined = undefined; | ||
|
|
||
| static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [ | ||
| { | ||
| "name": "data", | ||
| "baseName": "data", | ||
| "type": "MandateNotificationData", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "environment", | ||
| "baseName": "environment", | ||
| "type": "string", | ||
| "format": "" | ||
| }, | ||
| { | ||
| "name": "timestamp", | ||
| "baseName": "timestamp", | ||
| "type": "Date", | ||
| "format": "date-time" | ||
| }, | ||
| { | ||
| "name": "type", | ||
| "baseName": "type", | ||
| "type": "MandateNotificationRequest.TypeEnum", | ||
| "format": "" | ||
| } ]; | ||
|
|
||
| static getAttributeTypeMap() { | ||
| return MandateNotificationRequest.attributeTypeMap; | ||
| } | ||
|
|
||
| public constructor() { | ||
| } | ||
| } | ||
|
|
||
| export namespace MandateNotificationRequest { | ||
| export enum TypeEnum { | ||
| BalancePlatformMandateCreated = 'balancePlatform.mandate.created', | ||
| BalancePlatformMandateUpdated = 'balancePlatform.mandate.updated' | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| /* | ||
| * The version of the OpenAPI document: v2 | ||
| * | ||
| * | ||
| * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). | ||
| * https://openapi-generator.tech | ||
| * Do not edit this class manually. | ||
| */ | ||
|
|
||
|
|
||
| export class MandatePartyIdentification { | ||
| /** | ||
| * The full name of the entity that owns the bank account. Supported characters: [a-z] [A-Z] [0-9] , . ; : - — / \\ + & ! ? @ ( ) \" \' and space. | ||
| */ | ||
| "fullName"?: string; | ||
|
|
||
| static readonly discriminator: string | undefined = undefined; | ||
|
|
||
| static readonly mapping: {[index: string]: string} | undefined = undefined; | ||
|
|
||
| static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [ | ||
| { | ||
| "name": "fullName", | ||
| "baseName": "fullName", | ||
| "type": "string", | ||
| "format": "" | ||
| } ]; | ||
|
|
||
| static getAttributeTypeMap() { | ||
| return MandatePartyIdentification.attributeTypeMap; | ||
| } | ||
|
|
||
| public constructor() { | ||
| } | ||
| } | ||
|
|
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.
The type of
createdAtisany, which is not type-safe. For better type safety and consistency with other timestamp fields (liketimestampinMandateNotificationRequest), this should be typed asDate. The same applies toupdatedAton line 36. You will also need to update theattributeTypeMapfor both properties to use"type": "Date"and"format": "date-time"(see lines 58-59 and 88-89).