@wix/auto_sdk_payments_payment-acceptance-configurations 1.0.18 → 1.0.20
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.
- package/build/cjs/index.d.ts +1 -1
- package/build/cjs/index.typings.d.ts +1 -0
- package/build/cjs/index.typings.js +518 -0
- package/build/cjs/index.typings.js.map +1 -0
- package/build/es/index.d.mts +1 -1
- package/build/es/index.typings.d.mts +1 -0
- package/build/es/index.typings.mjs +486 -0
- package/build/es/index.typings.mjs.map +1 -0
- package/build/internal/cjs/index.d.ts +2 -2
- package/build/internal/cjs/{payments-payment-acceptance-configurations-v1-payment-acceptance-configuration-payment-acceptance-configurations.universal-Bhkpm_q_.d.ts → index.typings.d.ts} +94 -1
- package/build/internal/cjs/index.typings.js +518 -0
- package/build/internal/cjs/index.typings.js.map +1 -0
- package/build/internal/cjs/meta.d.ts +2 -1
- package/build/internal/es/index.d.mts +2 -2
- package/build/internal/es/{payments-payment-acceptance-configurations-v1-payment-acceptance-configuration-payment-acceptance-configurations.universal-Bhkpm_q_.d.mts → index.typings.d.mts} +94 -1
- package/build/internal/es/index.typings.mjs +486 -0
- package/build/internal/es/index.typings.mjs.map +1 -0
- package/build/internal/es/meta.d.mts +2 -1
- package/package.json +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpClient, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
|
|
2
|
-
import {
|
|
3
|
-
export {
|
|
2
|
+
import { PaymentAcceptanceConfiguration, UpdatePaymentAcceptanceConfiguration, PaymentAcceptanceConfigurationsQueryBuilder, BulkUpdatePaymentAcceptanceConfigurationTagsOptions, BulkUpdatePaymentAcceptanceConfigurationTagsResponse, BulkUpdatePaymentAcceptanceConfigurationTagsByFilterOptions, BulkUpdatePaymentAcceptanceConfigurationTagsByFilterResponse } from './index.typings.mjs';
|
|
3
|
+
export { ActionEvent, ApplicationError, BulkActionMetadata, BulkUpdatePaymentAcceptanceConfigurationTagsByFilterRequest, BulkUpdatePaymentAcceptanceConfigurationTagsRequest, BulkUpdatePaymentAcceptanceConfigurationTagsResult, CreatePaymentAcceptanceConfigurationRequest, CreatePaymentAcceptanceConfigurationResponse, CursorPaging, CursorPagingMetadata, CursorQuery, CursorQueryPagingMethodOneOf, Cursors, DeletePaymentAcceptanceConfigurationRequest, DeletePaymentAcceptanceConfigurationResponse, DomainEvent, DomainEventBodyOneOf, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, ExtendedFields, GetPaymentAcceptanceConfigurationRequest, GetPaymentAcceptanceConfigurationResponse, IdentificationData, IdentificationDataIdOneOf, ItemMetadata, MessageEnvelope, PaymentAcceptanceConfigurationsQueryResult, PaymentAcceptanceRule, QueryPaymentAcceptanceConfigurationsRequest, QueryPaymentAcceptanceConfigurationsResponse, RestoreInfo, SortOrder, Sorting, TagList, Tags, UpdatePaymentAcceptanceConfigurationRequest, UpdatePaymentAcceptanceConfigurationResponse, WebhookIdentityType } from './index.typings.mjs';
|
|
4
4
|
|
|
5
5
|
/** @internal */
|
|
6
6
|
declare function createPaymentAcceptanceConfiguration$1(httpClient: HttpClient): CreatePaymentAcceptanceConfigurationSignature;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { NonNullablePaths } from '@wix/sdk-types';
|
|
2
|
+
|
|
1
3
|
/** PaymentAcceptanceConfiguration */
|
|
2
4
|
interface PaymentAcceptanceConfiguration {
|
|
3
5
|
/**
|
|
@@ -428,6 +430,49 @@ declare enum WebhookIdentityType {
|
|
|
428
430
|
}
|
|
429
431
|
/** @enumType */
|
|
430
432
|
type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
|
|
433
|
+
type PaymentAcceptanceConfigurationNonNullablePaths = `rules` | `rules.${number}.paymentMethodTypeId` | `rules.${number}.accountConnectionId` | `rules.${number}.merchantEnabled` | `tags.tags.tagIds`;
|
|
434
|
+
/**
|
|
435
|
+
* Creates a PaymentAcceptanceConfiguration.
|
|
436
|
+
* @param paymentAcceptanceConfiguration - PaymentAcceptanceConfiguration to be created.
|
|
437
|
+
* @internal
|
|
438
|
+
* @documentationMaturity preview
|
|
439
|
+
* @requiredField paymentAcceptanceConfiguration
|
|
440
|
+
* @permissionId PAYMENTS.PAYMENT_ACCEPTANCE_CONFIGURATION_CREATE
|
|
441
|
+
* @returns The created PaymentAcceptanceConfiguration.
|
|
442
|
+
* @fqn wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.CreatePaymentAcceptanceConfiguration
|
|
443
|
+
*/
|
|
444
|
+
declare function createPaymentAcceptanceConfiguration(paymentAcceptanceConfiguration: PaymentAcceptanceConfiguration): Promise<NonNullablePaths<PaymentAcceptanceConfiguration, PaymentAcceptanceConfigurationNonNullablePaths>>;
|
|
445
|
+
/**
|
|
446
|
+
* Retrieves a PaymentAcceptanceConfiguration.
|
|
447
|
+
* @param paymentAcceptanceConfigurationId - ID of the PaymentAcceptanceConfiguration to retrieve.
|
|
448
|
+
* @internal
|
|
449
|
+
* @documentationMaturity preview
|
|
450
|
+
* @requiredField paymentAcceptanceConfigurationId
|
|
451
|
+
* @permissionId PAYMENTS.PAYMENT_ACCEPTANCE_CONFIGURATION_READ
|
|
452
|
+
* @returns The requested PaymentAcceptanceConfiguration.
|
|
453
|
+
* @fqn wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.GetPaymentAcceptanceConfiguration
|
|
454
|
+
*/
|
|
455
|
+
declare function getPaymentAcceptanceConfiguration(paymentAcceptanceConfigurationId: string): Promise<NonNullablePaths<PaymentAcceptanceConfiguration, PaymentAcceptanceConfigurationNonNullablePaths>>;
|
|
456
|
+
/**
|
|
457
|
+
* Updates a PaymentAcceptanceConfiguration.
|
|
458
|
+
*
|
|
459
|
+
*
|
|
460
|
+
* Each time the PaymentAcceptanceConfiguration is updated,
|
|
461
|
+
* `revision` increments by 1.
|
|
462
|
+
* The current `revision` must be passed when updating the PaymentAcceptanceConfiguration.
|
|
463
|
+
* This ensures you're working with the latest PaymentAcceptanceConfiguration
|
|
464
|
+
* and prevents unintended overwrites.
|
|
465
|
+
* @param _id - id
|
|
466
|
+
* @internal
|
|
467
|
+
* @documentationMaturity preview
|
|
468
|
+
* @requiredField _id
|
|
469
|
+
* @requiredField paymentAcceptanceConfiguration
|
|
470
|
+
* @requiredField paymentAcceptanceConfiguration.revision
|
|
471
|
+
* @permissionId PAYMENTS.PAYMENT_ACCEPTANCE_CONFIGURATION_UPDATE
|
|
472
|
+
* @returns Updated PaymentAcceptanceConfiguration.
|
|
473
|
+
* @fqn wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.UpdatePaymentAcceptanceConfiguration
|
|
474
|
+
*/
|
|
475
|
+
declare function updatePaymentAcceptanceConfiguration(_id: string, paymentAcceptanceConfiguration: NonNullablePaths<UpdatePaymentAcceptanceConfiguration, `revision`>): Promise<NonNullablePaths<PaymentAcceptanceConfiguration, PaymentAcceptanceConfigurationNonNullablePaths>>;
|
|
431
476
|
interface UpdatePaymentAcceptanceConfiguration {
|
|
432
477
|
/**
|
|
433
478
|
* id
|
|
@@ -468,6 +513,31 @@ interface UpdatePaymentAcceptanceConfiguration {
|
|
|
468
513
|
/** Tags */
|
|
469
514
|
tags?: Tags;
|
|
470
515
|
}
|
|
516
|
+
/**
|
|
517
|
+
* Delete a PaymentAcceptanceConfiguration
|
|
518
|
+
* @param paymentAcceptanceConfigurationId - Id of payment acceptance configuration to delete
|
|
519
|
+
* @internal
|
|
520
|
+
* @documentationMaturity preview
|
|
521
|
+
* @requiredField paymentAcceptanceConfigurationId
|
|
522
|
+
* @permissionId PAYMENTS.PAYMENT_ACCEPTANCE_CONFIGURATION_DELETE
|
|
523
|
+
* @fqn wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.DeletePaymentAcceptanceConfiguration
|
|
524
|
+
*/
|
|
525
|
+
declare function deletePaymentAcceptanceConfiguration(paymentAcceptanceConfigurationId: string): Promise<void>;
|
|
526
|
+
/**
|
|
527
|
+
* Retrieves a list of PaymentAcceptanceConfigurations, given the provided [paging, filtering, and sorting][1].
|
|
528
|
+
*
|
|
529
|
+
* Up to 1,000 PaymentAcceptanceConfigurations can be returned per request.
|
|
530
|
+
*
|
|
531
|
+
* To learn how to query PaymentAcceptanceConfigurations, see [API Query Language][2].
|
|
532
|
+
*
|
|
533
|
+
* [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging
|
|
534
|
+
* [2]: https://dev.wix.com/api/rest/getting-started/api-query-language
|
|
535
|
+
* @internal
|
|
536
|
+
* @documentationMaturity preview
|
|
537
|
+
* @permissionId PAYMENTS.PAYMENT_ACCEPTANCE_CONFIGURATION_READ
|
|
538
|
+
* @fqn wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.QueryPaymentAcceptanceConfigurations
|
|
539
|
+
*/
|
|
540
|
+
declare function queryPaymentAcceptanceConfigurations(): PaymentAcceptanceConfigurationsQueryBuilder;
|
|
471
541
|
interface QueryCursorResult {
|
|
472
542
|
cursors: Cursors;
|
|
473
543
|
hasNext: () => boolean;
|
|
@@ -545,12 +615,35 @@ interface PaymentAcceptanceConfigurationsQueryBuilder {
|
|
|
545
615
|
/** @documentationMaturity preview */
|
|
546
616
|
find: () => Promise<PaymentAcceptanceConfigurationsQueryResult>;
|
|
547
617
|
}
|
|
618
|
+
/**
|
|
619
|
+
* Synchronously update tags on multiple PaymentAcceptanceConfigurations, by list of PaymentAcceptanceConfigurations ids
|
|
620
|
+
* A tag that appears both in the list of assign and unassign tags, will be assigned
|
|
621
|
+
* @param ids - List of NileProtoTagsEntities that their tags will update.
|
|
622
|
+
* @internal
|
|
623
|
+
* @documentationMaturity preview
|
|
624
|
+
* @requiredField ids
|
|
625
|
+
* @permissionId PAYMENTS.PAYMENT_ACCEPTANCE_CONFIGURATION_UPDATE_TAGS
|
|
626
|
+
* @fqn wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.BulkUpdatePaymentAcceptanceConfigurationTags
|
|
627
|
+
*/
|
|
628
|
+
declare function bulkUpdatePaymentAcceptanceConfigurationTags(ids: string[], options?: BulkUpdatePaymentAcceptanceConfigurationTagsOptions): Promise<NonNullablePaths<BulkUpdatePaymentAcceptanceConfigurationTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`>>;
|
|
548
629
|
interface BulkUpdatePaymentAcceptanceConfigurationTagsOptions {
|
|
549
630
|
/** List of Tags to assign */
|
|
550
631
|
assignTags?: Tags;
|
|
551
632
|
/** List of Tags to unAssign */
|
|
552
633
|
unassignTags?: Tags;
|
|
553
634
|
}
|
|
635
|
+
/**
|
|
636
|
+
* Asynchronously update tags on multiple PaymentAcceptanceConfigurations, by provided filter
|
|
637
|
+
* An empty filter will update all PaymentAcceptanceConfigurations
|
|
638
|
+
* A tag that appears both in the list of assign and unassign tags, will be assigned
|
|
639
|
+
* @param filter - Filter
|
|
640
|
+
* @internal
|
|
641
|
+
* @documentationMaturity preview
|
|
642
|
+
* @requiredField filter
|
|
643
|
+
* @permissionId PAYMENTS.PAYMENT_ACCEPTANCE_CONFIGURATION_UPDATE_TAGS
|
|
644
|
+
* @fqn wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.BulkUpdatePaymentAcceptanceConfigurationTagsByFilter
|
|
645
|
+
*/
|
|
646
|
+
declare function bulkUpdatePaymentAcceptanceConfigurationTagsByFilter(filter: Record<string, any>, options?: BulkUpdatePaymentAcceptanceConfigurationTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdatePaymentAcceptanceConfigurationTagsByFilterResponse, `jobId`>>;
|
|
554
647
|
interface BulkUpdatePaymentAcceptanceConfigurationTagsByFilterOptions {
|
|
555
648
|
/** List of Tags to assign */
|
|
556
649
|
assignTags?: Tags;
|
|
@@ -558,4 +651,4 @@ interface BulkUpdatePaymentAcceptanceConfigurationTagsByFilterOptions {
|
|
|
558
651
|
unassignTags?: Tags;
|
|
559
652
|
}
|
|
560
653
|
|
|
561
|
-
export { type
|
|
654
|
+
export { type ActionEvent, type ApplicationError, type BulkActionMetadata, type BulkUpdatePaymentAcceptanceConfigurationTagsByFilterOptions, type BulkUpdatePaymentAcceptanceConfigurationTagsByFilterRequest, type BulkUpdatePaymentAcceptanceConfigurationTagsByFilterResponse, type BulkUpdatePaymentAcceptanceConfigurationTagsOptions, type BulkUpdatePaymentAcceptanceConfigurationTagsRequest, type BulkUpdatePaymentAcceptanceConfigurationTagsResponse, type BulkUpdatePaymentAcceptanceConfigurationTagsResult, type CreatePaymentAcceptanceConfigurationRequest, type CreatePaymentAcceptanceConfigurationResponse, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type DeletePaymentAcceptanceConfigurationRequest, type DeletePaymentAcceptanceConfigurationResponse, type DomainEvent, type DomainEventBodyOneOf, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type ExtendedFields, type GetPaymentAcceptanceConfigurationRequest, type GetPaymentAcceptanceConfigurationResponse, type IdentificationData, type IdentificationDataIdOneOf, type ItemMetadata, type MessageEnvelope, type PaymentAcceptanceConfiguration, type PaymentAcceptanceConfigurationsQueryBuilder, type PaymentAcceptanceConfigurationsQueryResult, type PaymentAcceptanceRule, type QueryPaymentAcceptanceConfigurationsRequest, type QueryPaymentAcceptanceConfigurationsResponse, type RestoreInfo, SortOrder, type SortOrderWithLiterals, type Sorting, type TagList, type Tags, type UpdatePaymentAcceptanceConfiguration, type UpdatePaymentAcceptanceConfigurationRequest, type UpdatePaymentAcceptanceConfigurationResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, bulkUpdatePaymentAcceptanceConfigurationTags, bulkUpdatePaymentAcceptanceConfigurationTagsByFilter, createPaymentAcceptanceConfiguration, deletePaymentAcceptanceConfiguration, getPaymentAcceptanceConfiguration, queryPaymentAcceptanceConfigurations, updatePaymentAcceptanceConfiguration };
|
|
@@ -0,0 +1,486 @@
|
|
|
1
|
+
// src/payments-payment-acceptance-configurations-v1-payment-acceptance-configuration-payment-acceptance-configurations.universal.ts
|
|
2
|
+
import { transformError as sdkTransformError } from "@wix/sdk-runtime/transform-error";
|
|
3
|
+
import { queryBuilder } from "@wix/sdk-runtime/query-builder";
|
|
4
|
+
import {
|
|
5
|
+
renameKeysFromSDKRequestToRESTRequest,
|
|
6
|
+
renameKeysFromRESTResponseToSDKResponse
|
|
7
|
+
} from "@wix/sdk-runtime/rename-all-nested-keys";
|
|
8
|
+
|
|
9
|
+
// src/payments-payment-acceptance-configurations-v1-payment-acceptance-configuration-payment-acceptance-configurations.http.ts
|
|
10
|
+
import { toURLSearchParams } from "@wix/sdk-runtime/rest-modules";
|
|
11
|
+
import { transformSDKTimestampToRESTTimestamp } from "@wix/sdk-runtime/transformations/timestamp";
|
|
12
|
+
import { transformRESTTimestampToSDKTimestamp } from "@wix/sdk-runtime/transformations/timestamp";
|
|
13
|
+
import { transformSDKFieldMaskToRESTFieldMask } from "@wix/sdk-runtime/transformations/field-mask";
|
|
14
|
+
import { transformPaths } from "@wix/sdk-runtime/transformations/transform-paths";
|
|
15
|
+
import { resolveUrl } from "@wix/sdk-runtime/rest-modules";
|
|
16
|
+
function resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(opts) {
|
|
17
|
+
const domainToMappings = {};
|
|
18
|
+
return resolveUrl(Object.assign(opts, { domainToMappings }));
|
|
19
|
+
}
|
|
20
|
+
var PACKAGE_NAME = "@wix/auto_sdk_payments_payment-acceptance-configurations";
|
|
21
|
+
function createPaymentAcceptanceConfiguration(payload) {
|
|
22
|
+
function __createPaymentAcceptanceConfiguration({ host }) {
|
|
23
|
+
const serializedData = transformPaths(payload, [
|
|
24
|
+
{
|
|
25
|
+
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
26
|
+
paths: [
|
|
27
|
+
{ path: "paymentAcceptanceConfiguration.createdDate" },
|
|
28
|
+
{ path: "paymentAcceptanceConfiguration.updatedDate" }
|
|
29
|
+
]
|
|
30
|
+
}
|
|
31
|
+
]);
|
|
32
|
+
const metadata = {
|
|
33
|
+
entityFqdn: "wix.payments.payment_acceptance_configurations.v1.payment_acceptance_configuration",
|
|
34
|
+
method: "POST",
|
|
35
|
+
methodFqn: "wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.CreatePaymentAcceptanceConfiguration",
|
|
36
|
+
packageName: PACKAGE_NAME,
|
|
37
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
38
|
+
{
|
|
39
|
+
protoPath: "/v1/payment-acceptance-configurations",
|
|
40
|
+
data: serializedData,
|
|
41
|
+
host
|
|
42
|
+
}
|
|
43
|
+
),
|
|
44
|
+
data: serializedData,
|
|
45
|
+
transformResponse: (payload2) => transformPaths(payload2, [
|
|
46
|
+
{
|
|
47
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
48
|
+
paths: [
|
|
49
|
+
{ path: "paymentAcceptanceConfiguration.createdDate" },
|
|
50
|
+
{ path: "paymentAcceptanceConfiguration.updatedDate" }
|
|
51
|
+
]
|
|
52
|
+
}
|
|
53
|
+
])
|
|
54
|
+
};
|
|
55
|
+
return metadata;
|
|
56
|
+
}
|
|
57
|
+
return __createPaymentAcceptanceConfiguration;
|
|
58
|
+
}
|
|
59
|
+
function getPaymentAcceptanceConfiguration(payload) {
|
|
60
|
+
function __getPaymentAcceptanceConfiguration({ host }) {
|
|
61
|
+
const metadata = {
|
|
62
|
+
entityFqdn: "wix.payments.payment_acceptance_configurations.v1.payment_acceptance_configuration",
|
|
63
|
+
method: "GET",
|
|
64
|
+
methodFqn: "wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.GetPaymentAcceptanceConfiguration",
|
|
65
|
+
packageName: PACKAGE_NAME,
|
|
66
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
67
|
+
{
|
|
68
|
+
protoPath: "/v1/payment-acceptance-configurations/{paymentAcceptanceConfigurationId}",
|
|
69
|
+
data: payload,
|
|
70
|
+
host
|
|
71
|
+
}
|
|
72
|
+
),
|
|
73
|
+
params: toURLSearchParams(payload),
|
|
74
|
+
transformResponse: (payload2) => transformPaths(payload2, [
|
|
75
|
+
{
|
|
76
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
77
|
+
paths: [
|
|
78
|
+
{ path: "paymentAcceptanceConfiguration.createdDate" },
|
|
79
|
+
{ path: "paymentAcceptanceConfiguration.updatedDate" }
|
|
80
|
+
]
|
|
81
|
+
}
|
|
82
|
+
])
|
|
83
|
+
};
|
|
84
|
+
return metadata;
|
|
85
|
+
}
|
|
86
|
+
return __getPaymentAcceptanceConfiguration;
|
|
87
|
+
}
|
|
88
|
+
function updatePaymentAcceptanceConfiguration(payload) {
|
|
89
|
+
function __updatePaymentAcceptanceConfiguration({ host }) {
|
|
90
|
+
const serializedData = transformPaths(payload, [
|
|
91
|
+
{
|
|
92
|
+
transformFn: transformSDKFieldMaskToRESTFieldMask,
|
|
93
|
+
paths: [{ path: "fieldMask" }]
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
97
|
+
paths: [
|
|
98
|
+
{ path: "paymentAcceptanceConfiguration.createdDate" },
|
|
99
|
+
{ path: "paymentAcceptanceConfiguration.updatedDate" }
|
|
100
|
+
]
|
|
101
|
+
}
|
|
102
|
+
]);
|
|
103
|
+
const metadata = {
|
|
104
|
+
entityFqdn: "wix.payments.payment_acceptance_configurations.v1.payment_acceptance_configuration",
|
|
105
|
+
method: "PATCH",
|
|
106
|
+
methodFqn: "wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.UpdatePaymentAcceptanceConfiguration",
|
|
107
|
+
packageName: PACKAGE_NAME,
|
|
108
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
109
|
+
{
|
|
110
|
+
protoPath: "/v1/payment-acceptance-configurations/{paymentAcceptanceConfiguration.id}",
|
|
111
|
+
data: serializedData,
|
|
112
|
+
host
|
|
113
|
+
}
|
|
114
|
+
),
|
|
115
|
+
data: serializedData,
|
|
116
|
+
transformResponse: (payload2) => transformPaths(payload2, [
|
|
117
|
+
{
|
|
118
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
119
|
+
paths: [
|
|
120
|
+
{ path: "paymentAcceptanceConfiguration.createdDate" },
|
|
121
|
+
{ path: "paymentAcceptanceConfiguration.updatedDate" }
|
|
122
|
+
]
|
|
123
|
+
}
|
|
124
|
+
])
|
|
125
|
+
};
|
|
126
|
+
return metadata;
|
|
127
|
+
}
|
|
128
|
+
return __updatePaymentAcceptanceConfiguration;
|
|
129
|
+
}
|
|
130
|
+
function deletePaymentAcceptanceConfiguration(payload) {
|
|
131
|
+
function __deletePaymentAcceptanceConfiguration({ host }) {
|
|
132
|
+
const metadata = {
|
|
133
|
+
entityFqdn: "wix.payments.payment_acceptance_configurations.v1.payment_acceptance_configuration",
|
|
134
|
+
method: "DELETE",
|
|
135
|
+
methodFqn: "wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.DeletePaymentAcceptanceConfiguration",
|
|
136
|
+
packageName: PACKAGE_NAME,
|
|
137
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
138
|
+
{
|
|
139
|
+
protoPath: "/v1/payment-acceptance-configurations/{paymentAcceptanceConfigurationId}",
|
|
140
|
+
data: payload,
|
|
141
|
+
host
|
|
142
|
+
}
|
|
143
|
+
),
|
|
144
|
+
params: toURLSearchParams(payload)
|
|
145
|
+
};
|
|
146
|
+
return metadata;
|
|
147
|
+
}
|
|
148
|
+
return __deletePaymentAcceptanceConfiguration;
|
|
149
|
+
}
|
|
150
|
+
function queryPaymentAcceptanceConfigurations(payload) {
|
|
151
|
+
function __queryPaymentAcceptanceConfigurations({ host }) {
|
|
152
|
+
const metadata = {
|
|
153
|
+
entityFqdn: "wix.payments.payment_acceptance_configurations.v1.payment_acceptance_configuration",
|
|
154
|
+
method: "POST",
|
|
155
|
+
methodFqn: "wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.QueryPaymentAcceptanceConfigurations",
|
|
156
|
+
packageName: PACKAGE_NAME,
|
|
157
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
158
|
+
{
|
|
159
|
+
protoPath: "/v1/payment-acceptance-configurations/query",
|
|
160
|
+
data: payload,
|
|
161
|
+
host
|
|
162
|
+
}
|
|
163
|
+
),
|
|
164
|
+
data: payload,
|
|
165
|
+
transformResponse: (payload2) => transformPaths(payload2, [
|
|
166
|
+
{
|
|
167
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
168
|
+
paths: [
|
|
169
|
+
{ path: "paymentAcceptanceConfigurations.createdDate" },
|
|
170
|
+
{ path: "paymentAcceptanceConfigurations.updatedDate" }
|
|
171
|
+
]
|
|
172
|
+
}
|
|
173
|
+
]),
|
|
174
|
+
fallback: [
|
|
175
|
+
{
|
|
176
|
+
method: "POST",
|
|
177
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
178
|
+
{
|
|
179
|
+
protoPath: "/v1/payment-acceptance-configurations/query",
|
|
180
|
+
data: payload,
|
|
181
|
+
host
|
|
182
|
+
}
|
|
183
|
+
),
|
|
184
|
+
data: payload
|
|
185
|
+
}
|
|
186
|
+
]
|
|
187
|
+
};
|
|
188
|
+
return metadata;
|
|
189
|
+
}
|
|
190
|
+
return __queryPaymentAcceptanceConfigurations;
|
|
191
|
+
}
|
|
192
|
+
function bulkUpdatePaymentAcceptanceConfigurationTags(payload) {
|
|
193
|
+
function __bulkUpdatePaymentAcceptanceConfigurationTags({ host }) {
|
|
194
|
+
const metadata = {
|
|
195
|
+
entityFqdn: "wix.payments.payment_acceptance_configurations.v1.payment_acceptance_configuration",
|
|
196
|
+
method: "POST",
|
|
197
|
+
methodFqn: "wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.BulkUpdatePaymentAcceptanceConfigurationTags",
|
|
198
|
+
packageName: PACKAGE_NAME,
|
|
199
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
200
|
+
{
|
|
201
|
+
protoPath: "/v1/bulk/payment-acceptance-configurations/update-tags",
|
|
202
|
+
data: payload,
|
|
203
|
+
host
|
|
204
|
+
}
|
|
205
|
+
),
|
|
206
|
+
data: payload
|
|
207
|
+
};
|
|
208
|
+
return metadata;
|
|
209
|
+
}
|
|
210
|
+
return __bulkUpdatePaymentAcceptanceConfigurationTags;
|
|
211
|
+
}
|
|
212
|
+
function bulkUpdatePaymentAcceptanceConfigurationTagsByFilter(payload) {
|
|
213
|
+
function __bulkUpdatePaymentAcceptanceConfigurationTagsByFilter({
|
|
214
|
+
host
|
|
215
|
+
}) {
|
|
216
|
+
const metadata = {
|
|
217
|
+
entityFqdn: "wix.payments.payment_acceptance_configurations.v1.payment_acceptance_configuration",
|
|
218
|
+
method: "POST",
|
|
219
|
+
methodFqn: "wix.payments.payment_acceptance_configurations.v1.PaymentAcceptanceConfigurationService.BulkUpdatePaymentAcceptanceConfigurationTagsByFilter",
|
|
220
|
+
packageName: PACKAGE_NAME,
|
|
221
|
+
url: resolveWixPaymentsPaymentAcceptanceConfigurationsV1PaymentAcceptanceConfigurationServiceUrl(
|
|
222
|
+
{
|
|
223
|
+
protoPath: "/v1/bulk/payment-acceptance-configurations/update-tags-by-filter",
|
|
224
|
+
data: payload,
|
|
225
|
+
host
|
|
226
|
+
}
|
|
227
|
+
),
|
|
228
|
+
data: payload
|
|
229
|
+
};
|
|
230
|
+
return metadata;
|
|
231
|
+
}
|
|
232
|
+
return __bulkUpdatePaymentAcceptanceConfigurationTagsByFilter;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
// src/payments-payment-acceptance-configurations-v1-payment-acceptance-configuration-payment-acceptance-configurations.universal.ts
|
|
236
|
+
import { transformPaths as transformPaths2 } from "@wix/sdk-runtime/transformations/transform-paths";
|
|
237
|
+
var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
|
|
238
|
+
SortOrder2["ASC"] = "ASC";
|
|
239
|
+
SortOrder2["DESC"] = "DESC";
|
|
240
|
+
return SortOrder2;
|
|
241
|
+
})(SortOrder || {});
|
|
242
|
+
var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
243
|
+
WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
|
|
244
|
+
WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
|
|
245
|
+
WebhookIdentityType2["MEMBER"] = "MEMBER";
|
|
246
|
+
WebhookIdentityType2["WIX_USER"] = "WIX_USER";
|
|
247
|
+
WebhookIdentityType2["APP"] = "APP";
|
|
248
|
+
return WebhookIdentityType2;
|
|
249
|
+
})(WebhookIdentityType || {});
|
|
250
|
+
async function createPaymentAcceptanceConfiguration2(paymentAcceptanceConfiguration) {
|
|
251
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
252
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
253
|
+
paymentAcceptanceConfiguration
|
|
254
|
+
});
|
|
255
|
+
const reqOpts = createPaymentAcceptanceConfiguration(
|
|
256
|
+
payload
|
|
257
|
+
);
|
|
258
|
+
sideEffects?.onSiteCall?.();
|
|
259
|
+
try {
|
|
260
|
+
const result = await httpClient.request(reqOpts);
|
|
261
|
+
sideEffects?.onSuccess?.(result);
|
|
262
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data)?.paymentAcceptanceConfiguration;
|
|
263
|
+
} catch (err) {
|
|
264
|
+
const transformedError = sdkTransformError(
|
|
265
|
+
err,
|
|
266
|
+
{
|
|
267
|
+
spreadPathsToArguments: {},
|
|
268
|
+
explicitPathsToArguments: { paymentAcceptanceConfiguration: "$[0]" },
|
|
269
|
+
singleArgumentUnchanged: false
|
|
270
|
+
},
|
|
271
|
+
["paymentAcceptanceConfiguration"]
|
|
272
|
+
);
|
|
273
|
+
sideEffects?.onError?.(err);
|
|
274
|
+
throw transformedError;
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
async function getPaymentAcceptanceConfiguration2(paymentAcceptanceConfigurationId) {
|
|
278
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
279
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
280
|
+
paymentAcceptanceConfigurationId
|
|
281
|
+
});
|
|
282
|
+
const reqOpts = getPaymentAcceptanceConfiguration(
|
|
283
|
+
payload
|
|
284
|
+
);
|
|
285
|
+
sideEffects?.onSiteCall?.();
|
|
286
|
+
try {
|
|
287
|
+
const result = await httpClient.request(reqOpts);
|
|
288
|
+
sideEffects?.onSuccess?.(result);
|
|
289
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data)?.paymentAcceptanceConfiguration;
|
|
290
|
+
} catch (err) {
|
|
291
|
+
const transformedError = sdkTransformError(
|
|
292
|
+
err,
|
|
293
|
+
{
|
|
294
|
+
spreadPathsToArguments: {},
|
|
295
|
+
explicitPathsToArguments: { paymentAcceptanceConfigurationId: "$[0]" },
|
|
296
|
+
singleArgumentUnchanged: false
|
|
297
|
+
},
|
|
298
|
+
["paymentAcceptanceConfigurationId"]
|
|
299
|
+
);
|
|
300
|
+
sideEffects?.onError?.(err);
|
|
301
|
+
throw transformedError;
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
async function updatePaymentAcceptanceConfiguration2(_id, paymentAcceptanceConfiguration) {
|
|
305
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
306
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
307
|
+
paymentAcceptanceConfiguration: {
|
|
308
|
+
...paymentAcceptanceConfiguration,
|
|
309
|
+
id: _id
|
|
310
|
+
}
|
|
311
|
+
});
|
|
312
|
+
const reqOpts = updatePaymentAcceptanceConfiguration(
|
|
313
|
+
payload
|
|
314
|
+
);
|
|
315
|
+
sideEffects?.onSiteCall?.();
|
|
316
|
+
try {
|
|
317
|
+
const result = await httpClient.request(reqOpts);
|
|
318
|
+
sideEffects?.onSuccess?.(result);
|
|
319
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data)?.paymentAcceptanceConfiguration;
|
|
320
|
+
} catch (err) {
|
|
321
|
+
const transformedError = sdkTransformError(
|
|
322
|
+
err,
|
|
323
|
+
{
|
|
324
|
+
spreadPathsToArguments: { paymentAcceptanceConfiguration: "$[1]" },
|
|
325
|
+
explicitPathsToArguments: {
|
|
326
|
+
"paymentAcceptanceConfiguration.id": "$[0]"
|
|
327
|
+
},
|
|
328
|
+
singleArgumentUnchanged: false
|
|
329
|
+
},
|
|
330
|
+
["_id", "paymentAcceptanceConfiguration"]
|
|
331
|
+
);
|
|
332
|
+
sideEffects?.onError?.(err);
|
|
333
|
+
throw transformedError;
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
async function deletePaymentAcceptanceConfiguration2(paymentAcceptanceConfigurationId) {
|
|
337
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
338
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
339
|
+
paymentAcceptanceConfigurationId
|
|
340
|
+
});
|
|
341
|
+
const reqOpts = deletePaymentAcceptanceConfiguration(
|
|
342
|
+
payload
|
|
343
|
+
);
|
|
344
|
+
sideEffects?.onSiteCall?.();
|
|
345
|
+
try {
|
|
346
|
+
const result = await httpClient.request(reqOpts);
|
|
347
|
+
sideEffects?.onSuccess?.(result);
|
|
348
|
+
} catch (err) {
|
|
349
|
+
const transformedError = sdkTransformError(
|
|
350
|
+
err,
|
|
351
|
+
{
|
|
352
|
+
spreadPathsToArguments: {},
|
|
353
|
+
explicitPathsToArguments: { paymentAcceptanceConfigurationId: "$[0]" },
|
|
354
|
+
singleArgumentUnchanged: false
|
|
355
|
+
},
|
|
356
|
+
["paymentAcceptanceConfigurationId"]
|
|
357
|
+
);
|
|
358
|
+
sideEffects?.onError?.(err);
|
|
359
|
+
throw transformedError;
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
function queryPaymentAcceptanceConfigurations2() {
|
|
363
|
+
const { httpClient, sideEffects } = arguments[0];
|
|
364
|
+
return queryBuilder({
|
|
365
|
+
func: async (payload) => {
|
|
366
|
+
const reqOpts = queryPaymentAcceptanceConfigurations(
|
|
367
|
+
payload
|
|
368
|
+
);
|
|
369
|
+
sideEffects?.onSiteCall?.();
|
|
370
|
+
try {
|
|
371
|
+
const result = await httpClient.request(reqOpts);
|
|
372
|
+
sideEffects?.onSuccess?.(result);
|
|
373
|
+
return result;
|
|
374
|
+
} catch (err) {
|
|
375
|
+
sideEffects?.onError?.(err);
|
|
376
|
+
throw err;
|
|
377
|
+
}
|
|
378
|
+
},
|
|
379
|
+
requestTransformer: (query) => {
|
|
380
|
+
const args = [query, {}];
|
|
381
|
+
return renameKeysFromSDKRequestToRESTRequest({
|
|
382
|
+
...args?.[1],
|
|
383
|
+
query: args?.[0]
|
|
384
|
+
});
|
|
385
|
+
},
|
|
386
|
+
responseTransformer: ({
|
|
387
|
+
data
|
|
388
|
+
}) => {
|
|
389
|
+
const transformedData = renameKeysFromRESTResponseToSDKResponse(
|
|
390
|
+
transformPaths2(data, [])
|
|
391
|
+
);
|
|
392
|
+
return {
|
|
393
|
+
items: transformedData?.paymentAcceptanceConfigurations,
|
|
394
|
+
pagingMetadata: transformedData?.pagingMetadata
|
|
395
|
+
};
|
|
396
|
+
},
|
|
397
|
+
errorTransformer: (err) => {
|
|
398
|
+
const transformedError = sdkTransformError(err, {
|
|
399
|
+
spreadPathsToArguments: {},
|
|
400
|
+
explicitPathsToArguments: { query: "$[0]" },
|
|
401
|
+
singleArgumentUnchanged: false
|
|
402
|
+
});
|
|
403
|
+
throw transformedError;
|
|
404
|
+
},
|
|
405
|
+
pagingMethod: "CURSOR",
|
|
406
|
+
transformationPaths: {}
|
|
407
|
+
});
|
|
408
|
+
}
|
|
409
|
+
async function bulkUpdatePaymentAcceptanceConfigurationTags2(ids, options) {
|
|
410
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
411
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
412
|
+
ids,
|
|
413
|
+
assignTags: options?.assignTags,
|
|
414
|
+
unassignTags: options?.unassignTags
|
|
415
|
+
});
|
|
416
|
+
const reqOpts = bulkUpdatePaymentAcceptanceConfigurationTags(
|
|
417
|
+
payload
|
|
418
|
+
);
|
|
419
|
+
sideEffects?.onSiteCall?.();
|
|
420
|
+
try {
|
|
421
|
+
const result = await httpClient.request(reqOpts);
|
|
422
|
+
sideEffects?.onSuccess?.(result);
|
|
423
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
424
|
+
} catch (err) {
|
|
425
|
+
const transformedError = sdkTransformError(
|
|
426
|
+
err,
|
|
427
|
+
{
|
|
428
|
+
spreadPathsToArguments: {},
|
|
429
|
+
explicitPathsToArguments: {
|
|
430
|
+
ids: "$[0]",
|
|
431
|
+
assignTags: "$[1].assignTags",
|
|
432
|
+
unassignTags: "$[1].unassignTags"
|
|
433
|
+
},
|
|
434
|
+
singleArgumentUnchanged: false
|
|
435
|
+
},
|
|
436
|
+
["ids", "options"]
|
|
437
|
+
);
|
|
438
|
+
sideEffects?.onError?.(err);
|
|
439
|
+
throw transformedError;
|
|
440
|
+
}
|
|
441
|
+
}
|
|
442
|
+
async function bulkUpdatePaymentAcceptanceConfigurationTagsByFilter2(filter, options) {
|
|
443
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
444
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
445
|
+
filter,
|
|
446
|
+
assignTags: options?.assignTags,
|
|
447
|
+
unassignTags: options?.unassignTags
|
|
448
|
+
});
|
|
449
|
+
const reqOpts = bulkUpdatePaymentAcceptanceConfigurationTagsByFilter(
|
|
450
|
+
payload
|
|
451
|
+
);
|
|
452
|
+
sideEffects?.onSiteCall?.();
|
|
453
|
+
try {
|
|
454
|
+
const result = await httpClient.request(reqOpts);
|
|
455
|
+
sideEffects?.onSuccess?.(result);
|
|
456
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
457
|
+
} catch (err) {
|
|
458
|
+
const transformedError = sdkTransformError(
|
|
459
|
+
err,
|
|
460
|
+
{
|
|
461
|
+
spreadPathsToArguments: {},
|
|
462
|
+
explicitPathsToArguments: {
|
|
463
|
+
filter: "$[0]",
|
|
464
|
+
assignTags: "$[1].assignTags",
|
|
465
|
+
unassignTags: "$[1].unassignTags"
|
|
466
|
+
},
|
|
467
|
+
singleArgumentUnchanged: false
|
|
468
|
+
},
|
|
469
|
+
["filter", "options"]
|
|
470
|
+
);
|
|
471
|
+
sideEffects?.onError?.(err);
|
|
472
|
+
throw transformedError;
|
|
473
|
+
}
|
|
474
|
+
}
|
|
475
|
+
export {
|
|
476
|
+
SortOrder,
|
|
477
|
+
WebhookIdentityType,
|
|
478
|
+
bulkUpdatePaymentAcceptanceConfigurationTags2 as bulkUpdatePaymentAcceptanceConfigurationTags,
|
|
479
|
+
bulkUpdatePaymentAcceptanceConfigurationTagsByFilter2 as bulkUpdatePaymentAcceptanceConfigurationTagsByFilter,
|
|
480
|
+
createPaymentAcceptanceConfiguration2 as createPaymentAcceptanceConfiguration,
|
|
481
|
+
deletePaymentAcceptanceConfiguration2 as deletePaymentAcceptanceConfiguration,
|
|
482
|
+
getPaymentAcceptanceConfiguration2 as getPaymentAcceptanceConfiguration,
|
|
483
|
+
queryPaymentAcceptanceConfigurations2 as queryPaymentAcceptanceConfigurations,
|
|
484
|
+
updatePaymentAcceptanceConfiguration2 as updatePaymentAcceptanceConfiguration
|
|
485
|
+
};
|
|
486
|
+
//# sourceMappingURL=index.typings.mjs.map
|