From 0a835c55bec53c9f5fa0708ee62c7635adb62e71 Mon Sep 17 00:00:00 2001 From: Wouter Boereboom <62436079+wboereboom@users.noreply.github.com> Date: Tue, 12 Jul 2022 10:47:09 +0200 Subject: [PATCH] update recurringService to v68 (#919) * update recurringService to v68 * remove actual api calls from unit tests and remove superfluous file headers --- README.md | 2 +- .../recurring/listRecurringDetailsSuccess.ts | 96 +++++++++---------- src/__tests__/recurring.spec.ts | 34 +------ src/client.ts | 2 +- src/services/recurring.ts | 19 ---- src/typings/recurring/address.ts | 20 ++-- src/typings/recurring/amount.ts | 22 ++--- src/typings/recurring/bankAccount.ts | 10 +- src/typings/recurring/card.ts | 10 +- src/typings/recurring/disableRequest.ts | 10 +- src/typings/recurring/disableResult.ts | 10 +- src/typings/recurring/models.ts | 75 ++++++--------- src/typings/recurring/name.ts | 19 +--- src/typings/recurring/notifyShopperRequest.ts | 11 +-- src/typings/recurring/notifyShopperResult.ts | 10 +- src/typings/recurring/recurring.ts | 10 +- src/typings/recurring/recurringDetail.ts | 33 +++++-- .../recurring/recurringDetailContainer.ts | 32 ------- .../recurring/recurringDetailsRequest.ts | 11 +-- .../recurring/recurringDetailsResult.ts | 15 ++- .../scheduleAccountUpdaterRequest.ts | 11 +-- .../recurring/scheduleAccountUpdaterResult.ts | 10 +- src/typings/recurring/serviceError.ts | 10 +- src/typings/recurring/tokenDetails.ts | 33 +++++++ 24 files changed, 211 insertions(+), 304 deletions(-) delete mode 100644 src/typings/recurring/recurringDetailContainer.ts create mode 100644 src/typings/recurring/tokenDetails.ts diff --git a/README.md b/README.md index 22f59ab..1e02340 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ The Library supports all APIs under the following services: * [Checkout API](https://docs.adyen.com/api-explorer/#/CheckoutService/v69/overview): Our latest integration for accepting online payments. Current supported version: **v69** * [Payments API](https://docs.adyen.com/api-explorer/#/Payment/v64/overview): Our classic integration for online payments. Current supported version: **v64** -* [Recurring API](https://docs.adyen.com/api-explorer/#/Recurring/v49/overview): Endpoints for managing saved payment details. Current supported version: **v49** +* [Recurring API](https://docs.adyen.com/api-explorer/#/Recurring/v49/overview): Endpoints for managing saved payment details. Current supported version: **68** * [Payouts API](https://docs.adyen.com/api-explorer/#/Payout/v64/overview): Endpoints for sending funds to your customers. Current supported version: **v64** * [Platforms APIs](https://docs.adyen.com/platforms/api): Set of APIs when using Adyen for Platforms. * [Account API](https://docs.adyen.com/api-explorer/#/Account/v6/overview) Current supported version: **v6** diff --git a/src/__mocks__/recurring/listRecurringDetailsSuccess.ts b/src/__mocks__/recurring/listRecurringDetailsSuccess.ts index 5d43bee..651a827 100644 --- a/src/__mocks__/recurring/listRecurringDetailsSuccess.ts +++ b/src/__mocks__/recurring/listRecurringDetailsSuccess.ts @@ -21,59 +21,55 @@ export const listRecurringDetailsSuccess = { "creationDate": "2017-03-01T11:53:11+01:00", "details": [ { - "RecurringDetail": { - "acquirer": "TestPmmAcquirer", - "acquirerAccount": "TestPmmAcquirerAccount", - "additionalData": { - "cardBin": "411111" - }, - "alias": "cardAlias", - "aliasType": "Default", - "card": { - "expiryMonth": "8", - "expiryYear": "2018", - "holderName": "Holder", - "number": "1111" - }, - "contractTypes": [ - "ONECLICK" - ], - "creationDate": "2017-03-07T09:43:33+01:00", - "firstPspReference": "8524888762135795", - "paymentMethodVariant": "visa", - "recurringDetailReference": "recurringReference", - "variant": "visa" - } + "acquirer": "TestPmmAcquirer", + "acquirerAccount": "TestPmmAcquirerAccount", + "additionalData": { + "cardBin": "411111" + }, + "alias": "cardAlias", + "aliasType": "Default", + "card": { + "expiryMonth": "8", + "expiryYear": "2018", + "holderName": "Holder", + "number": "1111" + }, + "contractTypes": [ + "ONECLICK" + ], + "creationDate": "2017-03-07T09:43:33+01:00", + "firstPspReference": "8524888762135795", + "paymentMethodVariant": "visa", + "recurringDetailReference": "recurringReference", + "variant": "visa" }, { - "RecurringDetail": { - "acquirer": "PayPalSandbox", - "acquirerAccount": "TestPmmAcquirerAccount", - "billingAddress": { - "city": "City", - "country": "NL", - "houseNumberOrName": "1", - "postalCode": "2312aa", - "stateOrProvince": "NA", - "street": "Street" + "acquirer": "PayPalSandbox", + "acquirerAccount": "TestPmmAcquirerAccount", + "billingAddress": { + "city": "City", + "country": "NL", + "houseNumberOrName": "1", + "postalCode": "2312aa", + "stateOrProvince": "NA", + "street": "Street" + }, + "contractTypes": [ + "RECURRING" + ], + "creationDate": "2017-10-10T08:50:02+02:00", + "firstPspReference": "8515076181707110", + "paymentMethodVariant": "paypal", + "recurringDetailReference": "8315076181982020", + "tokenDetails": { + "tokenData": { + "EmailId": "tedtest@test.nl", + "PayPal.PayerId": "H95EPL8B2KFE6", + "BillingAgreementId": "B-7MA42752FE774625C" }, - "contractTypes": [ - "RECURRING" - ], - "creationDate": "2017-10-10T08:50:02+02:00", - "firstPspReference": "8515076181707110", - "paymentMethodVariant": "paypal", - "recurringDetailReference": "8315076181982020", - "tokenDetails": { - "tokenData": { - "EmailId": "tedtest@test.nl", - "PayPal.PayerId": "H95EPL8B2KFE6", - "BillingAgreementId": "B-7MA42752FE774625C" - }, - "tokenDataType": "PayPal" - }, - "variant": "paypal" - } + "tokenDataType": "PayPal" + }, + "variant": "paypal" } ], "shopperReference": "test-123", diff --git a/src/__tests__/recurring.spec.ts b/src/__tests__/recurring.spec.ts index 70dbf7c..40edca8 100644 --- a/src/__tests__/recurring.spec.ts +++ b/src/__tests__/recurring.spec.ts @@ -1,22 +1,3 @@ -/* - * ###### - * ###### - * ############ ####( ###### #####. ###### ############ ############ - * ############# #####( ###### #####. ###### ############# ############# - * ###### #####( ###### #####. ###### ##### ###### ##### ###### - * ###### ###### #####( ###### #####. ###### ##### ##### ##### ###### - * ###### ###### #####( ###### #####. ###### ##### ##### ###### - * ############# ############# ############# ############# ##### ###### - * ############ ############ ############# ############ ##### ###### - * ###### - * ############# - * ############ - * Adyen NodeJS API Library - * Copyright (c) 2020 Adyen B.V. - * This file is open source and available under the MIT license. - * See the LICENSE file for more info. - */ - import nock from "nock"; import { createClient } from "../__mocks__/base"; import { disableSuccess } from "../__mocks__/recurring/disableSuccess"; @@ -44,7 +25,6 @@ const createRecurringDetailsRequest = (): RecurringDetailsRequest => { shopperReference: "shopperReference", }; }; -const isCI = process.env.CI === "true" || (typeof process.env.CI === "boolean" && process.env.CI); let client: Client; let recurring: RecurringService; @@ -66,7 +46,7 @@ afterEach(() => { }); describe("Recurring", (): void => { - test("should list recurring details ", async (): Promise => { + test("should list recurring details", async (): Promise => { scope.post("/listRecurringDetails") .reply(200, listRecurringDetailsSuccess); const request = createRecurringDetailsRequest(); @@ -74,11 +54,10 @@ describe("Recurring", (): void => { const result = await recurring.listRecurringDetails(request); expect(result).toBeTruthy(); - expect(result.details?.[0].RecurringDetail.recurringDetailReference).toBe("recurringReference"); + expect(result.details?.[0].recurringDetailReference).toBe("recurringReference"); }); - test.each([isCI, true])("should disable, isMock: %p", async (isMock): Promise => { - !isMock && nock.restore(); + test("should disable", async (): Promise => { scope.post("/payments") .reply(200, paymentsSuccess); @@ -102,8 +81,7 @@ describe("Recurring", (): void => { } }); - test.each([isCI, true])("should send pre-debit Notification, isMock %p", async (isMock): Promise => { - !isMock && nock.restore(); + test("should send pre-debit Notification", async (): Promise => { scope.post("/notifyShopper") .reply(200, notifyShopperSuccess); @@ -129,9 +107,7 @@ describe("Recurring", (): void => { }); - // TODO: register account for AccountUpdater and unmock test - test.each([true])("should schedule account updater, isMock: %p", async (isMock): Promise => { - !isMock && nock.restore(); + test("should schedule account updater", async (): Promise => { const scheduleAccountUpdaterSuccess: ScheduleAccountUpdaterResult = { pspReference: "mocked_psp", result: "SUCCESS" diff --git a/src/client.ts b/src/client.ts index a6c4820..66de65b 100644 --- a/src/client.ts +++ b/src/client.ts @@ -54,7 +54,7 @@ class Client { public static MARKETPAY_ENDPOINT_LIVE = "https://cal-live.adyen.com/cal/services"; public static CHECKOUT_API_VERSION = "v69"; public static API_VERSION = "v64"; - public static RECURRING_API_VERSION = "v49"; + public static RECURRING_API_VERSION = "v68"; public static MARKETPAY_ACCOUNT_API_VERSION = "v6"; public static MARKETPAY_FUND_API_VERSION = "v6"; public static MARKETPAY_HOP_API_VERSION = "v6"; diff --git a/src/services/recurring.ts b/src/services/recurring.ts index aaac367..a2f1742 100644 --- a/src/services/recurring.ts +++ b/src/services/recurring.ts @@ -1,22 +1,3 @@ -/* - * ###### - * ###### - * ############ ####( ###### #####. ###### ############ ############ - * ############# #####( ###### #####. ###### ############# ############# - * ###### #####( ###### #####. ###### ##### ###### ##### ###### - * ###### ###### #####( ###### #####. ###### ##### ##### ##### ###### - * ###### ###### #####( ###### #####. ###### ##### ##### ###### - * ############# ############# ############# ############# ##### ###### - * ############ ############ ############# ############ ##### ###### - * ###### - * ############# - * ############ - * Adyen NodeJS API Library - * Copyright (c) 2020 Adyen B.V. - * This file is open source and available under the MIT license. - * See the LICENSE file for more info. - */ - import Client from "../client"; import getJsonResponse from "../helpers/getJsonResponse"; import Service from "../service"; diff --git a/src/typings/recurring/address.ts b/src/typings/recurring/address.ts index b4ff459..41b5bf0 100644 --- a/src/typings/recurring/address.ts +++ b/src/typings/recurring/address.ts @@ -1,26 +1,24 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class Address { /** - * The name of the city. + * The name of the city. Maximum length: 3000 characters. */ 'city': string; /** - * The two-character country code as defined in ISO-3166-1 alpha-2. For example, **US**. > If you don\'t know the country or are not collecting the country from the shopper, provide `country` as `ZZ`. + * The two-character ISO-3166-1 alpha-2 country code. For example, **US**. > If you don\'t know the country or are not collecting the country from the shopper, provide `country` as `ZZ`. */ 'country': string; /** - * The number or name of the house. + * The number or name of the house. Maximum length: 3000 characters. */ 'houseNumberOrName': string; /** @@ -28,11 +26,11 @@ export class Address { */ 'postalCode': string; /** - * State or province codes as defined in ISO 3166-2. For example, **CA** in the US or **ON** in Canada. > Required for the US and Canada. + * The two-character ISO 3166-2 state or province code. For example, **CA** in the US or **ON** in Canada. > Required for the US and Canada. */ 'stateOrProvince'?: string; /** - * The name of the street. > The house number should not be included in this field; it should be separately provided via `houseNumberOrName`. + * The name of the street. Maximum length: 3000 characters. > The house number should not be included in this field; it should be separately provided via `houseNumberOrName`. */ 'street': string; diff --git a/src/typings/recurring/amount.ts b/src/typings/recurring/amount.ts index b4bdedc..4ef042f 100644 --- a/src/typings/recurring/amount.ts +++ b/src/typings/recurring/amount.ts @@ -1,28 +1,26 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class Amount { /** - * The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes). - */ + * The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes). + */ 'currency': string; /** - * The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes). - */ + * The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes). + */ 'value': number; static discriminator: string | undefined = undefined; - static attributeTypeMap: Array<{ name: string, baseName: string, type: string }> = [ + static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [ { "name": "currency", "baseName": "currency", @@ -32,7 +30,7 @@ export class Amount { "name": "value", "baseName": "value", "type": "number" - }]; + } ]; static getAttributeTypeMap() { return Amount.attributeTypeMap; diff --git a/src/typings/recurring/bankAccount.ts b/src/typings/recurring/bankAccount.ts index f184cc3..e9f6e28 100644 --- a/src/typings/recurring/bankAccount.ts +++ b/src/typings/recurring/bankAccount.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class BankAccount { /** * The bank account number (without separators). diff --git a/src/typings/recurring/card.ts b/src/typings/recurring/card.ts index 6f648d2..4faa202 100644 --- a/src/typings/recurring/card.ts +++ b/src/typings/recurring/card.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class Card { /** * The [card verification code](https://docs.adyen.com/payments-fundamentals/payment-glossary#card-security-code-cvc-cvv-cid) (1-20 characters). Depending on the card brand, it is known also as: * CVV2/CVC2 – length: 3 digits * CID – length: 4 digits > If you are using [Client-Side Encryption](https://docs.adyen.com/classic-integration/cse-integration-ecommerce), the CVC code is present in the encrypted data. You must never post the card details to the server. > This field must be always present in a [one-click payment request](https://docs.adyen.com/classic-integration/recurring-payments). > When this value is returned in a response, it is always empty because it is not stored. diff --git a/src/typings/recurring/disableRequest.ts b/src/typings/recurring/disableRequest.ts index 0aa3d47..aadb33f 100644 --- a/src/typings/recurring/disableRequest.ts +++ b/src/typings/recurring/disableRequest.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class DisableRequest { /** * Specify the contract if you only want to disable a specific use. This field can be set to one of the following values, or to their combination (comma-separated): * ONECLICK * RECURRING * PAYOUT diff --git a/src/typings/recurring/disableResult.ts b/src/typings/recurring/disableResult.ts index c7ea6bc..69714b5 100644 --- a/src/typings/recurring/disableResult.ts +++ b/src/typings/recurring/disableResult.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class DisableResult { /** * Depending on whether a specific recurring detail was in the request, result is either [detail-successfully-disabled] or [all-details-successfully-disabled]. diff --git a/src/typings/recurring/models.ts b/src/typings/recurring/models.ts index 80fc5bd..2836696 100644 --- a/src/typings/recurring/models.ts +++ b/src/typings/recurring/models.ts @@ -1,22 +1,13 @@ /* - * ###### - * ###### - * ############ ####( ###### #####. ###### ############ ############ - * ############# #####( ###### #####. ###### ############# ############# - * ###### #####( ###### #####. ###### ##### ###### ##### ###### - * ###### ###### #####( ###### #####. ###### ##### ##### ##### ###### - * ###### ###### #####( ###### #####. ###### ##### ##### ###### - * ############# ############# ############# ############# ##### ###### - * ############ ############ ############# ############ ##### ###### - * ###### - * ############# - * ############ - * Adyen NodeJS API Library - * Copyright (c) 2020 Adyen B.V. - * This file is open source and available under the MIT license. - * See the LICENSE file for more info. + * The version of the OpenAPI document: v68 + * Contact: developer-experience@adyen.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit this class manually. */ + export * from './address'; export * from './amount'; export * from './bankAccount'; @@ -33,37 +24,26 @@ export * from './recurringDetailsResult'; export * from './scheduleAccountUpdaterRequest'; export * from './scheduleAccountUpdaterResult'; export * from './serviceError'; -export * from './recurringDetailContainer'; +export * from './tokenDetails'; -import * as fs from 'fs'; -import {Address} from './address'; -import {Amount} from './amount'; -import {BankAccount} from './bankAccount'; -import {Card} from './card'; -import {DisableRequest} from './disableRequest'; -import {DisableResult} from './disableResult'; -import {Name} from './name'; -import {NotifyShopperRequest} from './notifyShopperRequest'; -import {NotifyShopperResult} from './notifyShopperResult'; -import {Recurring} from './recurring'; -import {RecurringDetail} from './recurringDetail'; -import {RecurringDetailsRequest} from './recurringDetailsRequest'; -import {RecurringDetailsResult} from './recurringDetailsResult'; -import {ScheduleAccountUpdaterRequest} from './scheduleAccountUpdaterRequest'; -import {ScheduleAccountUpdaterResult} from './scheduleAccountUpdaterResult'; -import {ServiceError} from './serviceError'; -import {RecurringDetailContainer} from "./recurringDetailContainer"; - -export interface RequestDetailedFile { - value: Buffer; - options?: { - filename?: string; - contentType?: string; - } -} - -export type RequestFile = string | Buffer | fs.ReadStream | RequestDetailedFile; +import { Address } from './address'; +import { Amount } from './amount'; +import { BankAccount } from './bankAccount'; +import { Card } from './card'; +import { DisableRequest } from './disableRequest'; +import { DisableResult } from './disableResult'; +import { Name } from './name'; +import { NotifyShopperRequest } from './notifyShopperRequest'; +import { NotifyShopperResult } from './notifyShopperResult'; +import { Recurring } from './recurring'; +import { RecurringDetail } from './recurringDetail'; +import { RecurringDetailsRequest } from './recurringDetailsRequest'; +import { RecurringDetailsResult } from './recurringDetailsResult'; +import { ScheduleAccountUpdaterRequest } from './scheduleAccountUpdaterRequest'; +import { ScheduleAccountUpdaterResult } from './scheduleAccountUpdaterResult'; +import { ServiceError } from './serviceError'; +import { TokenDetails } from './tokenDetails'; /* tslint:disable:no-unused-variable */ let primitives = [ @@ -96,10 +76,10 @@ let typeMap: {[index: string]: any} = { "RecurringDetail": RecurringDetail, "RecurringDetailsRequest": RecurringDetailsRequest, "RecurringDetailsResult": RecurringDetailsResult, - 'RecurringDetailContainer': RecurringDetailContainer, "ScheduleAccountUpdaterRequest": ScheduleAccountUpdaterRequest, "ScheduleAccountUpdaterResult": ScheduleAccountUpdaterResult, "ServiceError": ServiceError, + "TokenDetails": TokenDetails, } export class ObjectSerializer { @@ -154,6 +134,9 @@ export class ObjectSerializer { return transformedData; } else if (type === "Date") { return data.toISOString(); + } else if (type === "SaleToAcquirerData") { + const dataString = JSON.stringify(data); + return Buffer.from(dataString).toString("base64"); } else { if (enumsMap[type]) { return data; diff --git a/src/typings/recurring/name.ts b/src/typings/recurring/name.ts index 9a12c73..e0ca497 100644 --- a/src/typings/recurring/name.ts +++ b/src/typings/recurring/name.ts @@ -1,25 +1,19 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class Name { /** * The first name. */ 'firstName': string; /** - * The name\'s infix, if applicable. >A maximum length of twenty (20) characters is imposed. - */ - 'infix'?: string; - /** * The last name. */ 'lastName': string; @@ -32,11 +26,6 @@ export class Name { "baseName": "firstName", "type": "string" }, - { - "name": "infix", - "baseName": "infix", - "type": "string" - }, { "name": "lastName", "baseName": "lastName", diff --git a/src/typings/recurring/notifyShopperRequest.ts b/src/typings/recurring/notifyShopperRequest.ts index 1d1a880..306888c 100644 --- a/src/typings/recurring/notifyShopperRequest.ts +++ b/src/typings/recurring/notifyShopperRequest.ts @@ -1,16 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ -import {Amount} from './amount'; +import { Amount } from './amount'; export class NotifyShopperRequest { 'amount': Amount; diff --git a/src/typings/recurring/notifyShopperResult.ts b/src/typings/recurring/notifyShopperResult.ts index bb185ff..a68d0e8 100644 --- a/src/typings/recurring/notifyShopperResult.ts +++ b/src/typings/recurring/notifyShopperResult.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class NotifyShopperResult { /** * Reference of Pre-debit notification that is displayed to the shopper diff --git a/src/typings/recurring/recurring.ts b/src/typings/recurring/recurring.ts index f6248c8..1d80454 100644 --- a/src/typings/recurring/recurring.ts +++ b/src/typings/recurring/recurring.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class Recurring { /** * The type of recurring contract to be used. Possible values: * `ONECLICK` – Payment details can be used to initiate a one-click payment, where the shopper enters the [card security code (CVC/CVV)](https://docs.adyen.com/payments-fundamentals/payment-glossary#card-security-code-cvc-cvv-cid). * `RECURRING` – Payment details can be used without the card security code to initiate [card-not-present transactions](https://docs.adyen.com/payments-fundamentals/payment-glossary#card-not-present-cnp). * `ONECLICK,RECURRING` – Payment details can be used regardless of whether the shopper is on your site or not. * `PAYOUT` – Payment details can be used to [make a payout](https://docs.adyen.com/online-payments/online-payouts). diff --git a/src/typings/recurring/recurringDetail.ts b/src/typings/recurring/recurringDetail.ts index 9281f85..e9885e8 100644 --- a/src/typings/recurring/recurringDetail.ts +++ b/src/typings/recurring/recurringDetail.ts @@ -1,19 +1,17 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ -import {Address} from './address'; -import {BankAccount} from './bankAccount'; -import {Card} from './card'; -import {Name} from './name'; +import { Address } from './address'; +import { BankAccount } from './bankAccount'; +import { Card } from './card'; +import { Name } from './name'; +import { TokenDetails } from './tokenDetails'; export class RecurringDetail { /** @@ -48,6 +46,10 @@ export class RecurringDetail { */ 'name'?: string; /** + * Returned in the response if you are not tokenizing with Adyen and are using the Merchant-initiated transactions (MIT) framework from Mastercard or Visa. This contains either the Mastercard Trace ID or the Visa Transaction ID. + */ + 'networkTxReference'?: string; + /** * The type or sub-brand of a payment method used, e.g. Visa Debit, Visa Corporate, etc. For more information, refer to [PaymentMethodVariant](https://docs.adyen.com/development-resources/paymentmethodvariant). */ 'paymentMethodVariant'?: string; @@ -60,6 +62,7 @@ export class RecurringDetail { * A shopper\'s social security number (only in countries where it is legal to collect). */ 'socialSecurityNumber'?: string; + 'tokenDetails'?: TokenDetails; /** * The payment method, such as “mc\", \"visa\", \"ideal\", \"paypal\". */ @@ -118,6 +121,11 @@ export class RecurringDetail { "baseName": "name", "type": "string" }, + { + "name": "networkTxReference", + "baseName": "networkTxReference", + "type": "string" + }, { "name": "paymentMethodVariant", "baseName": "paymentMethodVariant", @@ -138,6 +146,11 @@ export class RecurringDetail { "baseName": "socialSecurityNumber", "type": "string" }, + { + "name": "tokenDetails", + "baseName": "tokenDetails", + "type": "TokenDetails" + }, { "name": "variant", "baseName": "variant", diff --git a/src/typings/recurring/recurringDetailContainer.ts b/src/typings/recurring/recurringDetailContainer.ts deleted file mode 100644 index ab2705e..0000000 --- a/src/typings/recurring/recurringDetailContainer.ts +++ /dev/null @@ -1,32 +0,0 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 - * Contact: developer-experience@adyen.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import {RecurringDetail} from "./recurringDetail"; - -export class RecurringDetailContainer { - 'RecurringDetail': RecurringDetail; - - static discriminator: string | undefined = undefined; - - static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [ - { - "name": "RecurringDetail", - "baseName": "RecurringDetail", - "type": "RecurringDetail" - } - ]; - - static getAttributeTypeMap() { - return RecurringDetail.attributeTypeMap; - } -} - diff --git a/src/typings/recurring/recurringDetailsRequest.ts b/src/typings/recurring/recurringDetailsRequest.ts index 2d55df3..a65d927 100644 --- a/src/typings/recurring/recurringDetailsRequest.ts +++ b/src/typings/recurring/recurringDetailsRequest.ts @@ -1,16 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ -import {Recurring} from './recurring'; +import { Recurring } from './recurring'; export class RecurringDetailsRequest { /** diff --git a/src/typings/recurring/recurringDetailsResult.ts b/src/typings/recurring/recurringDetailsResult.ts index 738f203..ad2bf02 100644 --- a/src/typings/recurring/recurringDetailsResult.ts +++ b/src/typings/recurring/recurringDetailsResult.ts @@ -1,16 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ -import {RecurringDetailContainer} from './recurringDetailContainer'; +import { RecurringDetail } from './recurringDetail'; export class RecurringDetailsResult { /** @@ -20,7 +17,7 @@ export class RecurringDetailsResult { /** * Payment details stored for recurring payments. */ - 'details'?: Array; + 'details'?: Array; /** * The most recent email for this shopper (if available). */ @@ -41,7 +38,7 @@ export class RecurringDetailsResult { { "name": "details", "baseName": "details", - "type": "Array" + "type": "Array" }, { "name": "lastKnownShopperEmail", diff --git a/src/typings/recurring/scheduleAccountUpdaterRequest.ts b/src/typings/recurring/scheduleAccountUpdaterRequest.ts index 78ee7c1..b39d73d 100644 --- a/src/typings/recurring/scheduleAccountUpdaterRequest.ts +++ b/src/typings/recurring/scheduleAccountUpdaterRequest.ts @@ -1,16 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ -import {Card} from './card'; +import { Card } from './card'; export class ScheduleAccountUpdaterRequest { /** diff --git a/src/typings/recurring/scheduleAccountUpdaterResult.ts b/src/typings/recurring/scheduleAccountUpdaterResult.ts index e1922f1..9922af7 100644 --- a/src/typings/recurring/scheduleAccountUpdaterResult.ts +++ b/src/typings/recurring/scheduleAccountUpdaterResult.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class ScheduleAccountUpdaterResult { /** * Adyen\'s 16-character unique reference associated with the transaction. This value is globally unique; quote it when communicating with us about this request. diff --git a/src/typings/recurring/serviceError.ts b/src/typings/recurring/serviceError.ts index 008a853..551936c 100644 --- a/src/typings/recurring/serviceError.ts +++ b/src/typings/recurring/serviceError.ts @@ -1,15 +1,13 @@ -/** - * Adyen Recurring API - * The Recurring APIs allow you to manage and remove your tokens or saved payment details. Tokens should be created with validation during a payment request. For more information, refer to our [Tokenization documentation](https://docs.adyen.com/online-payments/tokenization). ## Authentication To connect to the Recurring API, you must use your basic authentication credentials. For this, create your web service user, as described in [How to get the WS user password](https://docs.adyen.com/development-resources/api-credentials). Then use its credentials to authenticate your request, for example: ``` curl -U \"ws@Company.YourCompany\":\"YourWsPassword\" \\ -H \"Content-Type: application/json\" \\ ... ``` Note that when going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints). ## Versioning Recurring API supports versioning of its endpoints through a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number. For example: ``` https://pal-test.adyen.com/pal/servlet/Recurring/v49/disable ``` - * - * The version of the OpenAPI document: 49 +/* + * The version of the OpenAPI document: v68 * Contact: developer-experience@adyen.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech - * Do not edit the class manually. + * Do not edit this class manually. */ + export class ServiceError { /** * Contains additional information about the payment. Some data fields are included only if you select them first: Go to **Customer Area** > **Account** > **API URLs**. diff --git a/src/typings/recurring/tokenDetails.ts b/src/typings/recurring/tokenDetails.ts new file mode 100644 index 0000000..e3f9a02 --- /dev/null +++ b/src/typings/recurring/tokenDetails.ts @@ -0,0 +1,33 @@ +/* + * The version of the OpenAPI document: v68 + * Contact: developer-experience@adyen.com + * + * 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 TokenDetails { + 'tokenData'?: { [key: string]: string; }; + 'tokenDataType'?: string; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [ + { + "name": "tokenData", + "baseName": "tokenData", + "type": "{ [key: string]: string; }" + }, + { + "name": "tokenDataType", + "baseName": "tokenDataType", + "type": "string" + } ]; + + static getAttributeTypeMap() { + return TokenDetails.attributeTypeMap; + } +} +