@channelpayments/node-sdk 1.181.0 → 1.183.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/dist/cjs/apis/ChannelPaymentsApi.d.ts +9 -1
  2. package/dist/cjs/apis/ChannelPaymentsApi.js +70 -0
  3. package/dist/cjs/models/CreateMerchantDto.d.ts +7 -0
  4. package/dist/cjs/models/CreateMerchantDto.js +3 -0
  5. package/dist/cjs/models/FeeDetailsEntity.d.ts +53 -0
  6. package/dist/cjs/models/FeeDetailsEntity.js +66 -0
  7. package/dist/cjs/models/LogoUploadEntity.d.ts +32 -0
  8. package/dist/cjs/models/LogoUploadEntity.js +49 -0
  9. package/dist/cjs/models/MerchantColorsDto.d.ts +38 -0
  10. package/dist/cjs/models/MerchantColorsDto.js +49 -0
  11. package/dist/cjs/models/MerchantColorsEntity.d.ts +38 -0
  12. package/dist/cjs/models/MerchantColorsEntity.js +49 -0
  13. package/dist/cjs/models/MerchantEntity.d.ts +7 -0
  14. package/dist/cjs/models/MerchantEntity.js +3 -0
  15. package/dist/cjs/models/MerchantFeeDetailsEntity.d.ts +39 -0
  16. package/dist/cjs/models/MerchantFeeDetailsEntity.js +53 -0
  17. package/dist/cjs/models/MerchantServiceEntity.d.ts +7 -0
  18. package/dist/cjs/models/MerchantServiceEntity.js +3 -0
  19. package/dist/cjs/models/MerchantSettingsDto.d.ts +33 -0
  20. package/dist/cjs/models/MerchantSettingsDto.js +48 -0
  21. package/dist/cjs/models/MerchantSettingsEntity.d.ts +39 -0
  22. package/dist/cjs/models/MerchantSettingsEntity.js +52 -0
  23. package/dist/cjs/models/MerchantThemeDto.d.ts +40 -0
  24. package/dist/cjs/models/MerchantThemeDto.js +53 -0
  25. package/dist/cjs/models/MerchantThemeEntity.d.ts +40 -0
  26. package/dist/cjs/models/MerchantThemeEntity.js +53 -0
  27. package/dist/cjs/models/MerchantThemeLogoDto.d.ts +41 -0
  28. package/dist/cjs/models/MerchantThemeLogoDto.js +57 -0
  29. package/dist/cjs/models/MerchantThemeLogoEntity.d.ts +41 -0
  30. package/dist/cjs/models/MerchantThemeLogoEntity.js +57 -0
  31. package/dist/cjs/models/PaymentMethodFeeDetailsEntity.d.ts +54 -0
  32. package/dist/cjs/models/PaymentMethodFeeDetailsEntity.js +65 -0
  33. package/dist/cjs/models/TransactionEntity.d.ts +0 -6
  34. package/dist/cjs/models/TransactionEntity.js +0 -2
  35. package/dist/cjs/models/index.d.ts +12 -0
  36. package/dist/cjs/models/index.js +12 -0
  37. package/dist/cjs/runtime.js +1 -1
  38. package/dist/mjs/apis/ChannelPaymentsApi.d.ts +9 -1
  39. package/dist/mjs/apis/ChannelPaymentsApi.js +69 -1
  40. package/dist/mjs/models/CreateMerchantDto.d.ts +7 -0
  41. package/dist/mjs/models/CreateMerchantDto.js +3 -0
  42. package/dist/mjs/models/FeeDetailsEntity.d.ts +53 -0
  43. package/dist/mjs/models/FeeDetailsEntity.js +59 -0
  44. package/dist/mjs/models/LogoUploadEntity.d.ts +32 -0
  45. package/dist/mjs/models/LogoUploadEntity.js +43 -0
  46. package/dist/mjs/models/MerchantColorsDto.d.ts +38 -0
  47. package/dist/mjs/models/MerchantColorsDto.js +43 -0
  48. package/dist/mjs/models/MerchantColorsEntity.d.ts +38 -0
  49. package/dist/mjs/models/MerchantColorsEntity.js +43 -0
  50. package/dist/mjs/models/MerchantEntity.d.ts +7 -0
  51. package/dist/mjs/models/MerchantEntity.js +3 -0
  52. package/dist/mjs/models/MerchantFeeDetailsEntity.d.ts +39 -0
  53. package/dist/mjs/models/MerchantFeeDetailsEntity.js +47 -0
  54. package/dist/mjs/models/MerchantServiceEntity.d.ts +7 -0
  55. package/dist/mjs/models/MerchantServiceEntity.js +3 -0
  56. package/dist/mjs/models/MerchantSettingsDto.d.ts +33 -0
  57. package/dist/mjs/models/MerchantSettingsDto.js +42 -0
  58. package/dist/mjs/models/MerchantSettingsEntity.d.ts +39 -0
  59. package/dist/mjs/models/MerchantSettingsEntity.js +46 -0
  60. package/dist/mjs/models/MerchantThemeDto.d.ts +40 -0
  61. package/dist/mjs/models/MerchantThemeDto.js +47 -0
  62. package/dist/mjs/models/MerchantThemeEntity.d.ts +40 -0
  63. package/dist/mjs/models/MerchantThemeEntity.js +47 -0
  64. package/dist/mjs/models/MerchantThemeLogoDto.d.ts +41 -0
  65. package/dist/mjs/models/MerchantThemeLogoDto.js +50 -0
  66. package/dist/mjs/models/MerchantThemeLogoEntity.d.ts +41 -0
  67. package/dist/mjs/models/MerchantThemeLogoEntity.js +50 -0
  68. package/dist/mjs/models/PaymentMethodFeeDetailsEntity.d.ts +54 -0
  69. package/dist/mjs/models/PaymentMethodFeeDetailsEntity.js +58 -0
  70. package/dist/mjs/models/TransactionEntity.d.ts +0 -6
  71. package/dist/mjs/models/TransactionEntity.js +0 -2
  72. package/dist/mjs/models/index.d.ts +12 -0
  73. package/dist/mjs/models/index.js +12 -0
  74. package/dist/mjs/runtime.js +1 -1
  75. package/package.json +2 -2
@@ -5,7 +5,10 @@
5
5
  *
6
6
  */
7
7
  import * as runtime from '../runtime';
8
- import type { BuyersEntity, BuyersSearchEntity, CaptureTransactionDto, ChangeNotificationEntity, ChangeNotificationsSearchEntity, CheckoutSessionEntity, ConnectorServiceTokenEntity, CreateBuyerDto, CreateCheckoutSessionDto, CreatePaymentMethodDto, CreateProvisionedCardTokenDto, CreateTransactionRefundDto, CreateTransactionRequestDto, MerchantEntity, PaymentMethodEntity, PaymentMethodsSearchEntity, ReturnNotificationEntity, ReturnNotificationsSearchEntity, TagDto, TransactionEntity, TransactionRefundEntity, TransactionRefundsSearchEntity, TransactionsSearchEntity, UpdateBuyerDto } from '../models';
8
+ import type { BuyersEntity, BuyersSearchEntity, CaptureTransactionDto, ChangeNotificationEntity, ChangeNotificationsSearchEntity, CheckoutSessionEntity, ConnectorServiceTokenEntity, CreateBuyerDto, CreateCheckoutSessionDto, CreatePaymentMethodDto, CreateProvisionedCardTokenDto, CreateTransactionRefundDto, CreateTransactionRequestDto, MerchantEntity, MerchantFeeDetailsEntity, PaymentMethodEntity, PaymentMethodsSearchEntity, ReturnNotificationEntity, ReturnNotificationsSearchEntity, TagDto, TransactionEntity, TransactionRefundEntity, TransactionRefundsSearchEntity, TransactionsSearchEntity, UpdateBuyerDto } from '../models';
9
+ export interface GetFeeDetailsRequest {
10
+ amount: string;
11
+ }
9
12
  export interface SearchBuyersRequest {
10
13
  merchantId: string;
11
14
  buyerId?: string;
@@ -168,6 +171,11 @@ export declare class ChannelPaymentsApi extends runtime.BaseAPI {
168
171
  * Find connector service tokens.
169
172
  */
170
173
  getConnectorServiceTokens(paymentMethodId: string): Promise<Array<ConnectorServiceTokenEntity>>;
174
+ /**
175
+ * Get fee details by amount
176
+ * Get fee details
177
+ */
178
+ getFeeDetails(requestParameters: GetFeeDetailsRequest): Promise<MerchantFeeDetailsEntity>;
171
179
  /**
172
180
  * Retrieve the merchant associated with the user making the request.
173
181
  * Find merchant
@@ -1045,6 +1045,76 @@ class ChannelPaymentsApi extends runtime.BaseAPI {
1045
1045
  return yield response.value();
1046
1046
  });
1047
1047
  }
1048
+ /**
1049
+ * Get fee details by amount
1050
+ * Get fee details
1051
+ */
1052
+ getFeeDetails(requestParameters) {
1053
+ return __awaiter(this, void 0, void 0, function* () {
1054
+ if (requestParameters.amount === null || requestParameters.amount === undefined) {
1055
+ throw new runtime.RequiredError('amount', 'Required parameter \'amount\' was null or undefined when calling getFeeDetails.');
1056
+ }
1057
+ const queryParameters = {};
1058
+ if (requestParameters.amount !== undefined) {
1059
+ queryParameters['amount'] = requestParameters.amount;
1060
+ }
1061
+ const headerParameters = {};
1062
+ const rawResponse = yield this.request({
1063
+ path: `/transactions/fee-details`,
1064
+ method: 'GET',
1065
+ headers: headerParameters,
1066
+ query: queryParameters,
1067
+ });
1068
+ let response;
1069
+ if (rawResponse.status === 200) {
1070
+ response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.MerchantFeeDetailsEntityFromJSON)(jsonValue));
1071
+ }
1072
+ if (rawResponse.status === 400) {
1073
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1074
+ const error = yield errorResponse.value();
1075
+ throw error;
1076
+ }
1077
+ if (rawResponse.status === 401) {
1078
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1079
+ const error = yield errorResponse.value();
1080
+ throw error;
1081
+ }
1082
+ if (rawResponse.status === 403) {
1083
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1084
+ const error = yield errorResponse.value();
1085
+ throw error;
1086
+ }
1087
+ if (rawResponse.status === 404) {
1088
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1089
+ const error = yield errorResponse.value();
1090
+ throw error;
1091
+ }
1092
+ if (rawResponse.status === 500) {
1093
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1094
+ const error = yield errorResponse.value();
1095
+ throw error;
1096
+ }
1097
+ if (rawResponse.status === 502) {
1098
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1099
+ const error = yield errorResponse.value();
1100
+ throw error;
1101
+ }
1102
+ if (rawResponse.status === 503) {
1103
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1104
+ const error = yield errorResponse.value();
1105
+ throw error;
1106
+ }
1107
+ if (rawResponse.status === 504) {
1108
+ const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
1109
+ const error = yield errorResponse.value();
1110
+ throw error;
1111
+ }
1112
+ if (!response) {
1113
+ response = new runtime.TextApiResponse(rawResponse);
1114
+ }
1115
+ return yield response.value();
1116
+ });
1117
+ }
1048
1118
  /**
1049
1119
  * Retrieve the merchant associated with the user making the request.
1050
1120
  * Find merchant
@@ -6,6 +6,7 @@
6
6
  */
7
7
  import type { CreateMerchantAccountWithoutMerchantIdDto } from './CreateMerchantAccountWithoutMerchantIdDto';
8
8
  import type { CreateMerchantAddressDto } from './CreateMerchantAddressDto';
9
+ import type { MerchantSettingsDto } from './MerchantSettingsDto';
9
10
  /**
10
11
  *
11
12
  * @export
@@ -54,6 +55,12 @@ export interface CreateMerchantDto {
54
55
  * @memberof CreateMerchantDto
55
56
  */
56
57
  merchantAccounts?: Array<CreateMerchantAccountWithoutMerchantIdDto>;
58
+ /**
59
+ * The merchant settings.
60
+ * @type {MerchantSettingsDto}
61
+ * @memberof CreateMerchantDto
62
+ */
63
+ merchantSettings?: MerchantSettingsDto;
57
64
  }
58
65
  /**
59
66
  * Check if a given object implements the CreateMerchantDto interface.
@@ -15,6 +15,7 @@ exports.CreateMerchantDtoToJSON = CreateMerchantDtoToJSON;
15
15
  const runtime_1 = require("../runtime");
16
16
  const CreateMerchantAccountWithoutMerchantIdDto_1 = require("./CreateMerchantAccountWithoutMerchantIdDto");
17
17
  const CreateMerchantAddressDto_1 = require("./CreateMerchantAddressDto");
18
+ const MerchantSettingsDto_1 = require("./MerchantSettingsDto");
18
19
  /**
19
20
  * Check if a given object implements the CreateMerchantDto interface.
20
21
  */
@@ -41,6 +42,7 @@ function CreateMerchantDtoFromJSONTyped(json, ignoreDiscriminator) {
41
42
  'website': !(0, runtime_1.exists)(json, 'website') ? undefined : json['website'],
42
43
  'parentMerchantId': !(0, runtime_1.exists)(json, 'parentMerchantId') ? undefined : json['parentMerchantId'],
43
44
  'merchantAccounts': !(0, runtime_1.exists)(json, 'merchantAccounts') ? undefined : (json['merchantAccounts'].map(CreateMerchantAccountWithoutMerchantIdDto_1.CreateMerchantAccountWithoutMerchantIdDtoFromJSON)),
45
+ 'merchantSettings': !(0, runtime_1.exists)(json, 'merchantSettings') ? undefined : (0, MerchantSettingsDto_1.MerchantSettingsDtoFromJSON)(json['merchantSettings']),
44
46
  };
45
47
  return (0, runtime_1.removeNullUndefined)(typed);
46
48
  }
@@ -59,5 +61,6 @@ function CreateMerchantDtoToJSON(value) {
59
61
  'website': value.website,
60
62
  'parentMerchantId': value.parentMerchantId,
61
63
  'merchantAccounts': value.merchantAccounts === undefined ? undefined : (value.merchantAccounts.map(CreateMerchantAccountWithoutMerchantIdDto_1.CreateMerchantAccountWithoutMerchantIdDtoToJSON)),
64
+ 'merchantSettings': (0, MerchantSettingsDto_1.MerchantSettingsDtoToJSON)(value.merchantSettings),
62
65
  };
63
66
  }
@@ -0,0 +1,53 @@
1
+ /**
2
+ * Channel Payments API
3
+ *
4
+ * NOTE: This class is auto generated. Do not edit the class manually.
5
+ *
6
+ */
7
+ /**
8
+ *
9
+ * @export
10
+ * @interface FeeDetailsEntity
11
+ */
12
+ export interface FeeDetailsEntity {
13
+ /**
14
+ * The type of the transaction fee.
15
+ * @type {string}
16
+ * @memberof FeeDetailsEntity
17
+ */
18
+ type: FeeDetailsEntityTypeEnum;
19
+ /**
20
+ * The type of charge for the transaction fee.
21
+ * @type {string}
22
+ * @memberof FeeDetailsEntity
23
+ */
24
+ chargeType: FeeDetailsEntityChargeTypeEnum;
25
+ /**
26
+ * The amount of the transaction fee.
27
+ * @type {number}
28
+ * @memberof FeeDetailsEntity
29
+ */
30
+ amount: number;
31
+ }
32
+ /**
33
+ * @export
34
+ */
35
+ export declare const FeeDetailsEntityTypeEnum: {
36
+ readonly ConvenienceFee: "CONVENIENCE_FEE";
37
+ };
38
+ export type FeeDetailsEntityTypeEnum = typeof FeeDetailsEntityTypeEnum[keyof typeof FeeDetailsEntityTypeEnum];
39
+ /**
40
+ * @export
41
+ */
42
+ export declare const FeeDetailsEntityChargeTypeEnum: {
43
+ readonly IncludedInAmount: "INCLUDED_IN_AMOUNT";
44
+ readonly ChargedSeparately: "CHARGED_SEPARATELY";
45
+ };
46
+ export type FeeDetailsEntityChargeTypeEnum = typeof FeeDetailsEntityChargeTypeEnum[keyof typeof FeeDetailsEntityChargeTypeEnum];
47
+ /**
48
+ * Check if a given object implements the FeeDetailsEntity interface.
49
+ */
50
+ export declare function instanceOfFeeDetailsEntity(value: object): boolean;
51
+ export declare function FeeDetailsEntityFromJSON(json: any): FeeDetailsEntity;
52
+ export declare function FeeDetailsEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): FeeDetailsEntity;
53
+ export declare function FeeDetailsEntityToJSON(value?: FeeDetailsEntity | null): any;
@@ -0,0 +1,66 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Channel Payments API
6
+ *
7
+ * NOTE: This class is auto generated. Do not edit the class manually.
8
+ *
9
+ */
10
+ Object.defineProperty(exports, "__esModule", { value: true });
11
+ exports.FeeDetailsEntityChargeTypeEnum = exports.FeeDetailsEntityTypeEnum = void 0;
12
+ exports.instanceOfFeeDetailsEntity = instanceOfFeeDetailsEntity;
13
+ exports.FeeDetailsEntityFromJSON = FeeDetailsEntityFromJSON;
14
+ exports.FeeDetailsEntityFromJSONTyped = FeeDetailsEntityFromJSONTyped;
15
+ exports.FeeDetailsEntityToJSON = FeeDetailsEntityToJSON;
16
+ const runtime_1 = require("../runtime");
17
+ /**
18
+ * @export
19
+ */
20
+ exports.FeeDetailsEntityTypeEnum = {
21
+ ConvenienceFee: 'CONVENIENCE_FEE'
22
+ };
23
+ /**
24
+ * @export
25
+ */
26
+ exports.FeeDetailsEntityChargeTypeEnum = {
27
+ IncludedInAmount: 'INCLUDED_IN_AMOUNT',
28
+ ChargedSeparately: 'CHARGED_SEPARATELY'
29
+ };
30
+ /**
31
+ * Check if a given object implements the FeeDetailsEntity interface.
32
+ */
33
+ function instanceOfFeeDetailsEntity(value) {
34
+ let isInstance = true;
35
+ isInstance = isInstance && "type" in value;
36
+ isInstance = isInstance && "chargeType" in value;
37
+ isInstance = isInstance && "amount" in value;
38
+ return isInstance;
39
+ }
40
+ function FeeDetailsEntityFromJSON(json) {
41
+ return FeeDetailsEntityFromJSONTyped(json, false);
42
+ }
43
+ function FeeDetailsEntityFromJSONTyped(json, ignoreDiscriminator) {
44
+ if ((json === undefined) || (json === null)) {
45
+ return json;
46
+ }
47
+ const typed = {
48
+ 'type': json['type'],
49
+ 'chargeType': json['chargeType'],
50
+ 'amount': json['amount'],
51
+ };
52
+ return (0, runtime_1.removeNullUndefined)(typed);
53
+ }
54
+ function FeeDetailsEntityToJSON(value) {
55
+ if (value === undefined) {
56
+ return undefined;
57
+ }
58
+ if (value === null) {
59
+ return null;
60
+ }
61
+ return {
62
+ 'type': value.type,
63
+ 'chargeType': value.chargeType,
64
+ 'amount': value.amount,
65
+ };
66
+ }
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Channel Payments API
3
+ *
4
+ * NOTE: This class is auto generated. Do not edit the class manually.
5
+ *
6
+ */
7
+ /**
8
+ *
9
+ * @export
10
+ * @interface LogoUploadEntity
11
+ */
12
+ export interface LogoUploadEntity {
13
+ /**
14
+ * The public url to the image once uploaded.
15
+ * @type {string}
16
+ * @memberof LogoUploadEntity
17
+ */
18
+ imageUrl: string;
19
+ /**
20
+ * The temporary S3 url to upload the image to.
21
+ * @type {string}
22
+ * @memberof LogoUploadEntity
23
+ */
24
+ uploadUrl: string;
25
+ }
26
+ /**
27
+ * Check if a given object implements the LogoUploadEntity interface.
28
+ */
29
+ export declare function instanceOfLogoUploadEntity(value: object): boolean;
30
+ export declare function LogoUploadEntityFromJSON(json: any): LogoUploadEntity;
31
+ export declare function LogoUploadEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): LogoUploadEntity;
32
+ export declare function LogoUploadEntityToJSON(value?: LogoUploadEntity | null): any;
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Channel Payments API
6
+ *
7
+ * NOTE: This class is auto generated. Do not edit the class manually.
8
+ *
9
+ */
10
+ Object.defineProperty(exports, "__esModule", { value: true });
11
+ exports.instanceOfLogoUploadEntity = instanceOfLogoUploadEntity;
12
+ exports.LogoUploadEntityFromJSON = LogoUploadEntityFromJSON;
13
+ exports.LogoUploadEntityFromJSONTyped = LogoUploadEntityFromJSONTyped;
14
+ exports.LogoUploadEntityToJSON = LogoUploadEntityToJSON;
15
+ const runtime_1 = require("../runtime");
16
+ /**
17
+ * Check if a given object implements the LogoUploadEntity interface.
18
+ */
19
+ function instanceOfLogoUploadEntity(value) {
20
+ let isInstance = true;
21
+ isInstance = isInstance && "imageUrl" in value;
22
+ isInstance = isInstance && "uploadUrl" in value;
23
+ return isInstance;
24
+ }
25
+ function LogoUploadEntityFromJSON(json) {
26
+ return LogoUploadEntityFromJSONTyped(json, false);
27
+ }
28
+ function LogoUploadEntityFromJSONTyped(json, ignoreDiscriminator) {
29
+ if ((json === undefined) || (json === null)) {
30
+ return json;
31
+ }
32
+ const typed = {
33
+ 'imageUrl': json['imageUrl'],
34
+ 'uploadUrl': json['uploadUrl'],
35
+ };
36
+ return (0, runtime_1.removeNullUndefined)(typed);
37
+ }
38
+ function LogoUploadEntityToJSON(value) {
39
+ if (value === undefined) {
40
+ return undefined;
41
+ }
42
+ if (value === null) {
43
+ return null;
44
+ }
45
+ return {
46
+ 'imageUrl': value.imageUrl,
47
+ 'uploadUrl': value.uploadUrl,
48
+ };
49
+ }
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Channel Payments API
3
+ *
4
+ * NOTE: This class is auto generated. Do not edit the class manually.
5
+ *
6
+ */
7
+ /**
8
+ *
9
+ * @export
10
+ * @interface MerchantColorsDto
11
+ */
12
+ export interface MerchantColorsDto {
13
+ /**
14
+ * The palette's primary color
15
+ * @type {string}
16
+ * @memberof MerchantColorsDto
17
+ */
18
+ primary?: string;
19
+ /**
20
+ * The palette's secondary color
21
+ * @type {string}
22
+ * @memberof MerchantColorsDto
23
+ */
24
+ secondary?: string;
25
+ /**
26
+ * The palette's tertiary color
27
+ * @type {string}
28
+ * @memberof MerchantColorsDto
29
+ */
30
+ tertiary?: string;
31
+ }
32
+ /**
33
+ * Check if a given object implements the MerchantColorsDto interface.
34
+ */
35
+ export declare function instanceOfMerchantColorsDto(value: object): boolean;
36
+ export declare function MerchantColorsDtoFromJSON(json: any): MerchantColorsDto;
37
+ export declare function MerchantColorsDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): MerchantColorsDto;
38
+ export declare function MerchantColorsDtoToJSON(value?: MerchantColorsDto | null): any;
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Channel Payments API
6
+ *
7
+ * NOTE: This class is auto generated. Do not edit the class manually.
8
+ *
9
+ */
10
+ Object.defineProperty(exports, "__esModule", { value: true });
11
+ exports.instanceOfMerchantColorsDto = instanceOfMerchantColorsDto;
12
+ exports.MerchantColorsDtoFromJSON = MerchantColorsDtoFromJSON;
13
+ exports.MerchantColorsDtoFromJSONTyped = MerchantColorsDtoFromJSONTyped;
14
+ exports.MerchantColorsDtoToJSON = MerchantColorsDtoToJSON;
15
+ const runtime_1 = require("../runtime");
16
+ /**
17
+ * Check if a given object implements the MerchantColorsDto interface.
18
+ */
19
+ function instanceOfMerchantColorsDto(value) {
20
+ let isInstance = true;
21
+ return isInstance;
22
+ }
23
+ function MerchantColorsDtoFromJSON(json) {
24
+ return MerchantColorsDtoFromJSONTyped(json, false);
25
+ }
26
+ function MerchantColorsDtoFromJSONTyped(json, ignoreDiscriminator) {
27
+ if ((json === undefined) || (json === null)) {
28
+ return json;
29
+ }
30
+ const typed = {
31
+ 'primary': !(0, runtime_1.exists)(json, 'primary') ? undefined : json['primary'],
32
+ 'secondary': !(0, runtime_1.exists)(json, 'secondary') ? undefined : json['secondary'],
33
+ 'tertiary': !(0, runtime_1.exists)(json, 'tertiary') ? undefined : json['tertiary'],
34
+ };
35
+ return (0, runtime_1.removeNullUndefined)(typed);
36
+ }
37
+ function MerchantColorsDtoToJSON(value) {
38
+ if (value === undefined) {
39
+ return undefined;
40
+ }
41
+ if (value === null) {
42
+ return null;
43
+ }
44
+ return {
45
+ 'primary': value.primary,
46
+ 'secondary': value.secondary,
47
+ 'tertiary': value.tertiary,
48
+ };
49
+ }
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Channel Payments API
3
+ *
4
+ * NOTE: This class is auto generated. Do not edit the class manually.
5
+ *
6
+ */
7
+ /**
8
+ *
9
+ * @export
10
+ * @interface MerchantColorsEntity
11
+ */
12
+ export interface MerchantColorsEntity {
13
+ /**
14
+ * The palette's primary color
15
+ * @type {string}
16
+ * @memberof MerchantColorsEntity
17
+ */
18
+ primary?: string;
19
+ /**
20
+ * The palette's secondary color
21
+ * @type {string}
22
+ * @memberof MerchantColorsEntity
23
+ */
24
+ secondary?: string;
25
+ /**
26
+ * The palette's tertiary color
27
+ * @type {string}
28
+ * @memberof MerchantColorsEntity
29
+ */
30
+ tertiary?: string;
31
+ }
32
+ /**
33
+ * Check if a given object implements the MerchantColorsEntity interface.
34
+ */
35
+ export declare function instanceOfMerchantColorsEntity(value: object): boolean;
36
+ export declare function MerchantColorsEntityFromJSON(json: any): MerchantColorsEntity;
37
+ export declare function MerchantColorsEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): MerchantColorsEntity;
38
+ export declare function MerchantColorsEntityToJSON(value?: MerchantColorsEntity | null): any;
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Channel Payments API
6
+ *
7
+ * NOTE: This class is auto generated. Do not edit the class manually.
8
+ *
9
+ */
10
+ Object.defineProperty(exports, "__esModule", { value: true });
11
+ exports.instanceOfMerchantColorsEntity = instanceOfMerchantColorsEntity;
12
+ exports.MerchantColorsEntityFromJSON = MerchantColorsEntityFromJSON;
13
+ exports.MerchantColorsEntityFromJSONTyped = MerchantColorsEntityFromJSONTyped;
14
+ exports.MerchantColorsEntityToJSON = MerchantColorsEntityToJSON;
15
+ const runtime_1 = require("../runtime");
16
+ /**
17
+ * Check if a given object implements the MerchantColorsEntity interface.
18
+ */
19
+ function instanceOfMerchantColorsEntity(value) {
20
+ let isInstance = true;
21
+ return isInstance;
22
+ }
23
+ function MerchantColorsEntityFromJSON(json) {
24
+ return MerchantColorsEntityFromJSONTyped(json, false);
25
+ }
26
+ function MerchantColorsEntityFromJSONTyped(json, ignoreDiscriminator) {
27
+ if ((json === undefined) || (json === null)) {
28
+ return json;
29
+ }
30
+ const typed = {
31
+ 'primary': !(0, runtime_1.exists)(json, 'primary') ? undefined : json['primary'],
32
+ 'secondary': !(0, runtime_1.exists)(json, 'secondary') ? undefined : json['secondary'],
33
+ 'tertiary': !(0, runtime_1.exists)(json, 'tertiary') ? undefined : json['tertiary'],
34
+ };
35
+ return (0, runtime_1.removeNullUndefined)(typed);
36
+ }
37
+ function MerchantColorsEntityToJSON(value) {
38
+ if (value === undefined) {
39
+ return undefined;
40
+ }
41
+ if (value === null) {
42
+ return null;
43
+ }
44
+ return {
45
+ 'primary': value.primary,
46
+ 'secondary': value.secondary,
47
+ 'tertiary': value.tertiary,
48
+ };
49
+ }
@@ -6,6 +6,7 @@
6
6
  */
7
7
  import type { MerchantAccountServiceEntity } from './MerchantAccountServiceEntity';
8
8
  import type { MerchantAddressEntity } from './MerchantAddressEntity';
9
+ import type { MerchantSettingsEntity } from './MerchantSettingsEntity';
9
10
  /**
10
11
  *
11
12
  * @export
@@ -96,6 +97,12 @@ export interface MerchantEntity {
96
97
  * @memberof MerchantEntity
97
98
  */
98
99
  successRedirectUrl?: string;
100
+ /**
101
+ * The merchant settings.
102
+ * @type {MerchantSettingsEntity}
103
+ * @memberof MerchantEntity
104
+ */
105
+ merchantSettings?: MerchantSettingsEntity;
99
106
  }
100
107
  /**
101
108
  * Check if a given object implements the MerchantEntity interface.
@@ -15,6 +15,7 @@ exports.MerchantEntityToJSON = MerchantEntityToJSON;
15
15
  const runtime_1 = require("../runtime");
16
16
  const MerchantAccountServiceEntity_1 = require("./MerchantAccountServiceEntity");
17
17
  const MerchantAddressEntity_1 = require("./MerchantAddressEntity");
18
+ const MerchantSettingsEntity_1 = require("./MerchantSettingsEntity");
18
19
  /**
19
20
  * Check if a given object implements the MerchantEntity interface.
20
21
  */
@@ -52,6 +53,7 @@ function MerchantEntityFromJSONTyped(json, ignoreDiscriminator) {
52
53
  'merchantAccounts': !(0, runtime_1.exists)(json, 'merchantAccounts') ? undefined : (json['merchantAccounts'].map(MerchantAccountServiceEntity_1.MerchantAccountServiceEntityFromJSON)),
53
54
  'cancelRedirectUrl': !(0, runtime_1.exists)(json, 'cancelRedirectUrl') ? undefined : json['cancelRedirectUrl'],
54
55
  'successRedirectUrl': !(0, runtime_1.exists)(json, 'successRedirectUrl') ? undefined : json['successRedirectUrl'],
56
+ 'merchantSettings': !(0, runtime_1.exists)(json, 'merchantSettings') ? undefined : (0, MerchantSettingsEntity_1.MerchantSettingsEntityFromJSON)(json['merchantSettings']),
55
57
  };
56
58
  return (0, runtime_1.removeNullUndefined)(typed);
57
59
  }
@@ -77,5 +79,6 @@ function MerchantEntityToJSON(value) {
77
79
  'merchantAccounts': value.merchantAccounts === undefined ? undefined : (value.merchantAccounts.map(MerchantAccountServiceEntity_1.MerchantAccountServiceEntityToJSON)),
78
80
  'cancelRedirectUrl': value.cancelRedirectUrl,
79
81
  'successRedirectUrl': value.successRedirectUrl,
82
+ 'merchantSettings': (0, MerchantSettingsEntity_1.MerchantSettingsEntityToJSON)(value.merchantSettings),
80
83
  };
81
84
  }
@@ -0,0 +1,39 @@
1
+ /**
2
+ * Channel Payments API
3
+ *
4
+ * NOTE: This class is auto generated. Do not edit the class manually.
5
+ *
6
+ */
7
+ import type { PaymentMethodFeeDetailsEntity } from './PaymentMethodFeeDetailsEntity';
8
+ /**
9
+ *
10
+ * @export
11
+ * @interface MerchantFeeDetailsEntity
12
+ */
13
+ export interface MerchantFeeDetailsEntity {
14
+ /**
15
+ * The ID of the merchant.
16
+ * @type {string}
17
+ * @memberof MerchantFeeDetailsEntity
18
+ */
19
+ merchantId: string;
20
+ /**
21
+ * The merchant specified total of the transaction.
22
+ * @type {string}
23
+ * @memberof MerchantFeeDetailsEntity
24
+ */
25
+ subtotal: string;
26
+ /**
27
+ * The details of the payment method fees.
28
+ * @type {Array<PaymentMethodFeeDetailsEntity>}
29
+ * @memberof MerchantFeeDetailsEntity
30
+ */
31
+ feeDetails: Array<PaymentMethodFeeDetailsEntity>;
32
+ }
33
+ /**
34
+ * Check if a given object implements the MerchantFeeDetailsEntity interface.
35
+ */
36
+ export declare function instanceOfMerchantFeeDetailsEntity(value: object): boolean;
37
+ export declare function MerchantFeeDetailsEntityFromJSON(json: any): MerchantFeeDetailsEntity;
38
+ export declare function MerchantFeeDetailsEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): MerchantFeeDetailsEntity;
39
+ export declare function MerchantFeeDetailsEntityToJSON(value?: MerchantFeeDetailsEntity | null): any;
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Channel Payments API
6
+ *
7
+ * NOTE: This class is auto generated. Do not edit the class manually.
8
+ *
9
+ */
10
+ Object.defineProperty(exports, "__esModule", { value: true });
11
+ exports.instanceOfMerchantFeeDetailsEntity = instanceOfMerchantFeeDetailsEntity;
12
+ exports.MerchantFeeDetailsEntityFromJSON = MerchantFeeDetailsEntityFromJSON;
13
+ exports.MerchantFeeDetailsEntityFromJSONTyped = MerchantFeeDetailsEntityFromJSONTyped;
14
+ exports.MerchantFeeDetailsEntityToJSON = MerchantFeeDetailsEntityToJSON;
15
+ const runtime_1 = require("../runtime");
16
+ const PaymentMethodFeeDetailsEntity_1 = require("./PaymentMethodFeeDetailsEntity");
17
+ /**
18
+ * Check if a given object implements the MerchantFeeDetailsEntity interface.
19
+ */
20
+ function instanceOfMerchantFeeDetailsEntity(value) {
21
+ let isInstance = true;
22
+ isInstance = isInstance && "merchantId" in value;
23
+ isInstance = isInstance && "subtotal" in value;
24
+ isInstance = isInstance && "feeDetails" in value;
25
+ return isInstance;
26
+ }
27
+ function MerchantFeeDetailsEntityFromJSON(json) {
28
+ return MerchantFeeDetailsEntityFromJSONTyped(json, false);
29
+ }
30
+ function MerchantFeeDetailsEntityFromJSONTyped(json, ignoreDiscriminator) {
31
+ if ((json === undefined) || (json === null)) {
32
+ return json;
33
+ }
34
+ const typed = {
35
+ 'merchantId': json['merchantId'],
36
+ 'subtotal': json['subtotal'],
37
+ 'feeDetails': (json['feeDetails'].map(PaymentMethodFeeDetailsEntity_1.PaymentMethodFeeDetailsEntityFromJSON)),
38
+ };
39
+ return (0, runtime_1.removeNullUndefined)(typed);
40
+ }
41
+ function MerchantFeeDetailsEntityToJSON(value) {
42
+ if (value === undefined) {
43
+ return undefined;
44
+ }
45
+ if (value === null) {
46
+ return null;
47
+ }
48
+ return {
49
+ 'merchantId': value.merchantId,
50
+ 'subtotal': value.subtotal,
51
+ 'feeDetails': (value.feeDetails.map(PaymentMethodFeeDetailsEntity_1.PaymentMethodFeeDetailsEntityToJSON)),
52
+ };
53
+ }