Skip to content

Commit def89e2

Browse files
authored
Merge pull request #1536 from Adyen/sdk-automation/models
Code generation: update services and models
2 parents 2c8a8e0 + ac40fad commit def89e2

File tree

77 files changed

+943
-146
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+943
-146
lines changed

src/services/checkout/modificationsApi.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ export class ModificationsApi extends Service {
6363

6464
/**
6565
* @summary Cancel an authorised payment
66-
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the payment that you want to cancel.
66+
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#responses-200-pspReference) of the payment that you want to cancel.
6767
* @param paymentCancelRequest {@link PaymentCancelRequest }
6868
* @param requestOptions {@link IRequest.Options }
6969
* @return {@link PaymentCancelResponse }
@@ -85,7 +85,7 @@ export class ModificationsApi extends Service {
8585

8686
/**
8787
* @summary Capture an authorised payment
88-
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the payment that you want to capture.
88+
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#responses-200-pspReference) of the payment that you want to capture.
8989
* @param paymentCaptureRequest {@link PaymentCaptureRequest }
9090
* @param requestOptions {@link IRequest.Options }
9191
* @return {@link PaymentCaptureResponse }
@@ -107,7 +107,7 @@ export class ModificationsApi extends Service {
107107

108108
/**
109109
* @summary Refund a captured payment
110-
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the payment that you want to refund.
110+
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#responses-200-pspReference) of the payment that you want to refund.
111111
* @param paymentRefundRequest {@link PaymentRefundRequest }
112112
* @param requestOptions {@link IRequest.Options }
113113
* @return {@link PaymentRefundResponse }
@@ -129,7 +129,7 @@ export class ModificationsApi extends Service {
129129

130130
/**
131131
* @summary Refund or cancel a payment
132-
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the payment that you want to reverse.
132+
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#responses-200-pspReference) of the payment that you want to reverse.
133133
* @param paymentReversalRequest {@link PaymentReversalRequest }
134134
* @param requestOptions {@link IRequest.Options }
135135
* @return {@link PaymentReversalResponse }
@@ -151,7 +151,7 @@ export class ModificationsApi extends Service {
151151

152152
/**
153153
* @summary Update an authorised amount
154-
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the payment.
154+
* @param paymentPspReference {@link string } The [`pspReference`](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#responses-200-pspReference) of the payment.
155155
* @param paymentAmountUpdateRequest {@link PaymentAmountUpdateRequest }
156156
* @param requestOptions {@link IRequest.Options }
157157
* @return {@link PaymentAmountUpdateResponse }

src/services/checkout/utilityApi.ts

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ import { PaypalUpdateOrderRequest } from "../../typings/checkout/models";
2121
import { PaypalUpdateOrderResponse } from "../../typings/checkout/models";
2222
import { UtilityRequest } from "../../typings/checkout/models";
2323
import { UtilityResponse } from "../../typings/checkout/models";
24+
import { ValidateShopperIdRequest } from "../../typings/checkout/models";
25+
import { ValidateShopperIdResponse } from "../../typings/checkout/models";
2426

2527
/**
2628
* API handler for UtilityApi
@@ -97,4 +99,24 @@ export class UtilityApi extends Service {
9799
return ObjectSerializer.deserialize(response, "PaypalUpdateOrderResponse");
98100
}
99101

102+
/**
103+
* @summary Validates shopper Id
104+
* @param validateShopperIdRequest {@link ValidateShopperIdRequest }
105+
* @param requestOptions {@link IRequest.Options }
106+
* @return {@link ValidateShopperIdResponse }
107+
*/
108+
public async validateShopperId(validateShopperIdRequest: ValidateShopperIdRequest, requestOptions?: IRequest.Options): Promise<ValidateShopperIdResponse> {
109+
const endpoint = `${this.baseUrl}/validateShopperId`;
110+
const resource = new Resource(this, endpoint);
111+
112+
const request: ValidateShopperIdRequest = ObjectSerializer.serialize(validateShopperIdRequest, "ValidateShopperIdRequest");
113+
const response = await getJsonResponse<ValidateShopperIdRequest, ValidateShopperIdResponse>(
114+
resource,
115+
request,
116+
{ ...requestOptions, method: "POST" }
117+
);
118+
119+
return ObjectSerializer.deserialize(response, "ValidateShopperIdResponse");
120+
}
121+
100122
}

src/typings/balancePlatform/deliveryAddress.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export class DeliveryAddress {
3434
*/
3535
"postalCode"?: string;
3636
/**
37-
* The two-letter ISO 3166-2 state or province code. For example, **CA** in the US or **ON** in Canada. > Required for the US and Canada.
37+
* The state or province code, maximum 3 characters. For example, **CA** for California in the US or **ON** for Ontario in Canada. > Required for the US and Canada.
3838
*/
3939
"stateOrProvince"?: string;
4040

src/typings/balancePlatform/models.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,7 @@ export * from "./transferRouteResponse"
168168
export * from "./uKLocalAccountIdentification"
169169
export * from "./uSInstantPayoutAddressRequirement"
170170
export * from "./uSInternationalAchAddressRequirement"
171+
export * from "./uSInternationalAchPriorityRequirement"
171172
export * from "./uSLocalAccountIdentification"
172173
export * from "./updateNetworkTokenRequest"
173174
export * from "./updatePaymentInstrument"

src/typings/balancePlatform/objectSerializer.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,7 @@ import { TransferRouteResponse } from "./transferRouteResponse";
170170
import { UKLocalAccountIdentification } from "./uKLocalAccountIdentification";
171171
import { USInstantPayoutAddressRequirement } from "./uSInstantPayoutAddressRequirement";
172172
import { USInternationalAchAddressRequirement } from "./uSInternationalAchAddressRequirement";
173+
import { USInternationalAchPriorityRequirement } from "./uSInternationalAchPriorityRequirement";
173174
import { USLocalAccountIdentification } from "./uSLocalAccountIdentification";
174175
import { UpdateNetworkTokenRequest } from "./updateNetworkTokenRequest";
175176
import { UpdatePaymentInstrument } from "./updatePaymentInstrument";
@@ -317,6 +318,7 @@ let enumsMap: Set<string> = new Set<string>([
317318
"UKLocalAccountIdentification.TypeEnum",
318319
"USInstantPayoutAddressRequirement.TypeEnum",
319320
"USInternationalAchAddressRequirement.TypeEnum",
321+
"USInternationalAchPriorityRequirement.TypeEnum",
320322
"USLocalAccountIdentification.AccountTypeEnum",
321323
"USLocalAccountIdentification.TypeEnum",
322324
"UpdateNetworkTokenRequest.StatusEnum",
@@ -506,6 +508,7 @@ let typeMap: {[index: string]: any} = {
506508
"UKLocalAccountIdentification": UKLocalAccountIdentification,
507509
"USInstantPayoutAddressRequirement": USInstantPayoutAddressRequirement,
508510
"USInternationalAchAddressRequirement": USInternationalAchAddressRequirement,
511+
"USInternationalAchPriorityRequirement": USInternationalAchPriorityRequirement,
509512
"USLocalAccountIdentification": USLocalAccountIdentification,
510513
"UpdateNetworkTokenRequest": UpdateNetworkTokenRequest,
511514
"UpdatePaymentInstrument": UpdatePaymentInstrument,

src/typings/balancePlatform/transferRouteRequirementsInner.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,15 @@ import { IbanAccountIdentificationRequirement } from "./ibanAccountIdentificatio
1616
import { PaymentInstrumentRequirement } from "./paymentInstrumentRequirement";
1717
import { USInstantPayoutAddressRequirement } from "./uSInstantPayoutAddressRequirement";
1818
import { USInternationalAchAddressRequirement } from "./uSInternationalAchAddressRequirement";
19+
import { USInternationalAchPriorityRequirement } from "./uSInternationalAchPriorityRequirement";
1920

2021

2122
/**
2223
* @type TransferRouteRequirementsInner
2324
* Type
2425
* @export
2526
*/
26-
export type TransferRouteRequirementsInner = AdditionalBankIdentificationRequirement | AddressRequirement | AmountMinMaxRequirement | AmountNonZeroDecimalsRequirement | BankAccountIdentificationTypeRequirement | IbanAccountIdentificationRequirement | PaymentInstrumentRequirement | USInstantPayoutAddressRequirement | USInternationalAchAddressRequirement;
27+
export type TransferRouteRequirementsInner = AdditionalBankIdentificationRequirement | AddressRequirement | AmountMinMaxRequirement | AmountNonZeroDecimalsRequirement | BankAccountIdentificationTypeRequirement | IbanAccountIdentificationRequirement | PaymentInstrumentRequirement | USInstantPayoutAddressRequirement | USInternationalAchAddressRequirement | USInternationalAchPriorityRequirement;
2728

2829
/**
2930
* @type TransferRouteRequirementsInnerClass
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
/*
2+
* The version of the OpenAPI document: v2
3+
*
4+
*
5+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
6+
* https://openapi-generator.tech
7+
* Do not edit this class manually.
8+
*/
9+
10+
11+
export class USInternationalAchPriorityRequirement {
12+
/**
13+
* Specifies that transactions deemed to be International ACH (IAT) per OFAC/NACHA rules cannot have fast priority.
14+
*/
15+
"description"?: string;
16+
/**
17+
* **usInternationalAchPriorityRequirement**
18+
*/
19+
"type": USInternationalAchPriorityRequirement.TypeEnum;
20+
21+
static readonly discriminator: string | undefined = undefined;
22+
23+
static readonly mapping: {[index: string]: string} | undefined = undefined;
24+
25+
static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
26+
{
27+
"name": "description",
28+
"baseName": "description",
29+
"type": "string",
30+
"format": ""
31+
},
32+
{
33+
"name": "type",
34+
"baseName": "type",
35+
"type": "USInternationalAchPriorityRequirement.TypeEnum",
36+
"format": ""
37+
} ];
38+
39+
static getAttributeTypeMap() {
40+
return USInternationalAchPriorityRequirement.attributeTypeMap;
41+
}
42+
43+
public constructor() {
44+
}
45+
}
46+
47+
export namespace USInternationalAchPriorityRequirement {
48+
export enum TypeEnum {
49+
UsInternationalAchPriorityRequirement = 'usInternationalAchPriorityRequirement'
50+
}
51+
}

src/typings/checkout/additionalDataAirline.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ export class AdditionalDataAirline {
7474
*/
7575
"airline_leg_destination_code"?: string;
7676
/**
77-
* The [fare basis code](https://en.wikipedia.org/wiki/Fare_basis_code), alphanumeric. * minLength: 1 character * maxLength: 6 characters * Must not be all spaces * Must not be all zeros.
77+
* The [fare basis code](https://en.wikipedia.org/wiki/Fare_basis_code), alphanumeric. * minLength: 1 character * maxLength: 15 characters * Must not be all spaces * Must not be all zeros.
7878
*/
7979
"airline_leg_fare_base_code"?: string;
8080
/**

src/typings/checkout/additionalDataLevel23.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export class AdditionalDataLevel23 {
3838
*/
3939
"enhancedSchemeData_itemDetailLine_itemNr_commodityCode"?: string;
4040
/**
41-
* A description of the item. * Encoding: ASCII * Max length: 26 characters * Must not be a single character. * Must not be blank. * Must not start with a space or be all spaces. * Must not be all zeros.
41+
* A description of the item, that provides details about the purchase. For Visa transactions with level 3 ESD, the description must not be the same or very similar to your merchant name, or, consist only of common words like \"product\", or \"service\". * Encoding: ASCII * Max length: 26 characters * Must not be a single character. * Must not be blank. * Must not be all special characters. * Must not be blank. * Must not start with a space or be all spaces. * Must not be all zeros.
4242
*/
4343
"enhancedSchemeData_itemDetailLine_itemNr_description"?: string;
4444
/**

src/typings/checkout/balanceCheckRequest.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ export class BalanceCheckRequest {
110110
*/
111111
"shopperEmail"?: string;
112112
/**
113-
* The shopper\'s IP address. We recommend that you provide this data, as it is used in a number of risk checks (for instance, number of payment attempts or location-based checks).> Required for Visa and JCB transactions that require 3D Secure 2 authentication for all web and mobile integrations, if you did not include the `shopperEmail`. For native mobile integrations, the field is required to support cases where authentication is routed to the redirect flow. This field is also mandatory for some merchants depending on your business model. For more information, [contact Support](https://www.adyen.help/hc/en-us/requests/new).
113+
* The shopper\'s IP address. We recommend that you provide this data, as it is used in a number of risk checks (for instance, number of payment attempts or location-based checks). > Required for Visa and JCB transactions that require 3D Secure 2 authentication for all web and mobile integrations, if you did not include the `shopperEmail`. For native mobile integrations, the field is required to support cases where authentication is routed to the redirect flow. This field is also mandatory for some merchants depending on your business model. For more information, [contact Support](https://www.adyen.help/hc/en-us/requests/new).
114114
*/
115115
"shopperIP"?: string;
116116
/**
@@ -143,7 +143,7 @@ export class BalanceCheckRequest {
143143
*/
144144
"store"?: string;
145145
/**
146-
* The shopper\'s telephone number. > Required for Visa and JCB transactions that require 3D Secure 2 authentication, if you did not include the `shopperEmail`. The phone number must include a plus sign (+) and a country code (1-3 digits), followed by the number (4-15 digits). If the value you provide does not follow the guidelines, we drop the value and do not submit it for authentication.
146+
* The shopper\'s telephone number. The phone number must include a plus sign (+) and a country code (1-3 digits), followed by the number (4-15 digits). If the value you provide does not follow the guidelines, we do not submit it for authentication. > Required for Visa and JCB transactions that require 3D Secure 2 authentication, if you did not include the `shopperEmail`.
147147
*/
148148
"telephoneNumber"?: string;
149149
"threeDS2RequestData"?: ThreeDS2RequestData | null;

0 commit comments

Comments
 (0)