@wix/auto_sdk_ecom_tax-groups 1.0.32 → 1.0.34

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.
@@ -90,6 +90,9 @@ function createTaxGroup(payload) {
90
90
  method: "POST",
91
91
  methodFqn: "wix.billing.v1.TaxGroups.CreateTaxGroup",
92
92
  packageName: PACKAGE_NAME,
93
+ migrationOptions: {
94
+ optInTransformResponse: true
95
+ },
93
96
  url: resolveWixBillingV1TaxGroupsUrl({
94
97
  protoPath: "/v1/tax-groups",
95
98
  data: serializedData,
@@ -117,6 +120,9 @@ function getTaxGroup(payload) {
117
120
  method: "GET",
118
121
  methodFqn: "wix.billing.v1.TaxGroups.GetTaxGroup",
119
122
  packageName: PACKAGE_NAME,
123
+ migrationOptions: {
124
+ optInTransformResponse: true
125
+ },
120
126
  url: resolveWixBillingV1TaxGroupsUrl({
121
127
  protoPath: "/v1/tax-groups/{taxGroupId}",
122
128
  data: payload,
@@ -157,6 +163,9 @@ function updateTaxGroup(payload) {
157
163
  method: "PATCH",
158
164
  methodFqn: "wix.billing.v1.TaxGroups.UpdateTaxGroup",
159
165
  packageName: PACKAGE_NAME,
166
+ migrationOptions: {
167
+ optInTransformResponse: true
168
+ },
160
169
  url: resolveWixBillingV1TaxGroupsUrl({
161
170
  protoPath: "/v1/tax-groups/{taxGroup.id}",
162
171
  data: serializedData,
@@ -184,6 +193,9 @@ function deleteTaxGroup(payload) {
184
193
  method: "DELETE",
185
194
  methodFqn: "wix.billing.v1.TaxGroups.DeleteTaxGroup",
186
195
  packageName: PACKAGE_NAME,
196
+ migrationOptions: {
197
+ optInTransformResponse: true
198
+ },
187
199
  url: resolveWixBillingV1TaxGroupsUrl({
188
200
  protoPath: "/v1/tax-groups/{taxGroupId}",
189
201
  data: payload,
@@ -202,6 +214,9 @@ function queryTaxGroups(payload) {
202
214
  method: "POST",
203
215
  methodFqn: "wix.billing.v1.TaxGroups.QueryTaxGroups",
204
216
  packageName: PACKAGE_NAME,
217
+ migrationOptions: {
218
+ optInTransformResponse: true
219
+ },
205
220
  url: resolveWixBillingV1TaxGroupsUrl({
206
221
  protoPath: "/v1/tax-groups/query",
207
222
  data: payload,
@@ -229,6 +244,9 @@ function listDefaultTaxGroups(payload) {
229
244
  method: "GET",
230
245
  methodFqn: "wix.billing.v1.TaxGroups.ListDefaultTaxGroups",
231
246
  packageName: PACKAGE_NAME,
247
+ migrationOptions: {
248
+ optInTransformResponse: true
249
+ },
232
250
  url: resolveWixBillingV1TaxGroupsUrl({
233
251
  protoPath: "/v1/tax-groups/default-tax-groups",
234
252
  data: payload,
@@ -256,6 +274,9 @@ function listDefaultTaxGroupsByAppIds(payload) {
256
274
  method: "POST",
257
275
  methodFqn: "wix.billing.v1.TaxGroups.ListDefaultTaxGroupsByAppIds",
258
276
  packageName: PACKAGE_NAME,
277
+ migrationOptions: {
278
+ optInTransformResponse: true
279
+ },
259
280
  url: resolveWixBillingV1TaxGroupsUrl({
260
281
  protoPath: "/v1/tax-groups/list-default-tax-groups-by-app-ids",
261
282
  data: payload,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../index.typings.ts","../../../src/billing-v1-tax-group-tax-groups.universal.ts","../../../src/billing-v1-tax-group-tax-groups.http.ts"],"sourcesContent":["export * from './src/billing-v1-tax-group-tax-groups.universal.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport { queryBuilder } from '@wix/sdk-runtime/query-builder';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, HttpResponse, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixBillingV1TaxGroup from './billing-v1-tax-group-tax-groups.http.js';\n// @ts-ignore\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\n\n/**\n * A tax group is a category of specific line items grouped together based on their tax treatment.\n * You can create new tax groups to apply distinct tax rates and rules.\n */\nexport interface TaxGroup {\n /**\n * Tax group ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Tax group name.\n * @minLength 1\n * @maxLength 200\n */\n name?: string;\n /**\n * Revision number, which increments by 1 each time the tax group is updated. To prevent conflicting changes,\n * the current revision must be passed when updating the tax group.\n *\n * Ignored when creating a tax group.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the tax group was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the tax group was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n}\n\nexport interface CreateTaxGroupRequest {\n /** Tax group to create. */\n taxGroup: TaxGroup;\n}\n\nexport interface CreateTaxGroupResponse {\n /** Created tax group. */\n taxGroup?: TaxGroup;\n}\n\nexport interface GetTaxGroupRequest {\n /**\n * ID of the tax group to retrieve.\n * @format GUID\n */\n taxGroupId: string;\n}\n\nexport interface GetTaxGroupResponse {\n /** Retrieved tax group. */\n taxGroup?: TaxGroup;\n}\n\nexport interface UpdateTaxGroupRequest {\n /** Tax group info to update. */\n taxGroup: TaxGroup;\n}\n\nexport interface UpdateTaxGroupResponse {\n /** Updated tax group. */\n taxGroup?: TaxGroup;\n}\n\nexport interface DeleteTaxGroupRequest {\n /**\n * ID of the tax group to delete.\n * @format GUID\n */\n taxGroupId: string;\n}\n\nexport interface DeleteTaxGroupResponse {}\n\nexport interface QueryTaxGroupsRequest {\n /** Query options. */\n query: QueryV2;\n}\n\nexport interface QueryV2 extends QueryV2PagingMethodOneOf {\n /** Paging options to limit and offset the number of items. */\n paging?: Paging;\n /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */\n cursorPaging?: CursorPaging;\n /**\n * Filter object.\n *\n * Learn more about [filtering](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#filters).\n */\n filter?: Record<string, any> | null;\n /**\n * Sort object.\n *\n * Learn more about [sorting](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#sorting).\n */\n sort?: Sorting[];\n /** Array of projected fields. A list of specific field names to return. If `fieldsets` are also specified, the union of `fieldsets` and `fields` is returned. */\n fields?: string[];\n /** Array of named, predefined sets of projected fields. A array of predefined named sets of fields to be returned. Specifying multiple `fieldsets` will return the union of fields from all sets. If `fields` are also specified, the union of `fieldsets` and `fields` is returned. */\n fieldsets?: string[];\n}\n\n/** @oneof */\nexport interface QueryV2PagingMethodOneOf {\n /** Paging options to limit and offset the number of items. */\n paging?: Paging;\n /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */\n cursorPaging?: CursorPaging;\n}\n\nexport interface Sorting {\n /**\n * Name of the field to sort by.\n * @maxLength 512\n */\n fieldName?: string;\n /** Sort order. */\n order?: SortOrderWithLiterals;\n}\n\nexport enum SortOrder {\n ASC = 'ASC',\n DESC = 'DESC',\n}\n\n/** @enumType */\nexport type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';\n\nexport interface Paging {\n /** Number of items to load. */\n limit?: number | null;\n /** Number of items to skip in the current sort order. */\n offset?: number | null;\n}\n\nexport interface CursorPaging {\n /**\n * Maximum number of items to return in the results.\n * @max 100\n */\n limit?: number | null;\n /**\n * Pointer to the next or previous page in the list of results.\n *\n * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n * Not relevant for the first request.\n * @maxLength 16000\n */\n cursor?: string | null;\n}\n\nexport interface QueryTaxGroupsResponse {\n /** Retrieved default tax groups. */\n taxGroups?: TaxGroup[];\n /** Paging metadata. */\n pagingMetadata?: CursorPagingMetadata;\n}\n\nexport interface CursorPagingMetadata {\n /** Number of items returned in current page. */\n count?: number | null;\n /** Cursor strings that point to the next page, previous page, or both. */\n cursors?: Cursors;\n /**\n * Whether there are more pages to retrieve following the current page.\n *\n * + `true`: Another page of results can be retrieved.\n * + `false`: This is the last page.\n */\n hasNext?: boolean | null;\n}\n\nexport interface Cursors {\n /**\n * Cursor string pointing to the next page in the list of results.\n * @maxLength 16000\n */\n next?: string | null;\n /**\n * Cursor pointing to the previous page in the list of results.\n * @maxLength 16000\n */\n prev?: string | null;\n}\n\nexport interface ListDefaultTaxGroupsRequest {}\n\nexport interface ListDefaultTaxGroupsResponse {\n /** Retrieved default tax groups. */\n taxGroups?: TaxGroup[];\n}\n\nexport interface ListDefaultTaxGroupsByAppIdsRequest {\n /**\n * App IDs to retrieve default tax groups for.\n * @minSize 1\n * @maxSize 300\n * @minLength 1\n */\n appIds: string[];\n}\n\nexport interface ListDefaultTaxGroupsByAppIdsResponse {\n /**\n * Retrieved default tax groups.\n * @minSize 1\n * @maxSize 300\n */\n results?: ListDefaultTaxGroupsByAppIdsResult[];\n /** Bulk action metadata. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ListDefaultTaxGroupsByAppIdsResult {\n /** Information about success or failure to retrieve default tax groups. */\n taxGroupMetadata?: ItemMetadata;\n /** Retrieved default tax groups. */\n taxGroup?: TaxGroup;\n}\n\nexport interface ItemMetadata {\n /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n/** @docsIgnore */\nexport type UpdateTaxGroupApplicationErrors = {\n code?: 'ILLEGAL_UPDATE_ON_SYSTEM_DEFINED_TAX_GROUP';\n description?: string;\n data?: Record<string, any>;\n};\n\nexport interface BaseEventMetadata {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n}\n\nexport interface EventMetadata extends BaseEventMetadata {\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\nexport interface TaxGroupCreatedEnvelope {\n entity: TaxGroup;\n metadata: EventMetadata;\n}\n\n/**\n * Triggered when a tax group is created.\n * @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Manage Stores\n * @permissionScopeId SCOPE.STORES.MANAGE-STORES\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionScope Manage Orders\n * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS\n * @permissionId BILLING.TAX_GROUP_READ\n * @webhook\n * @eventType wix.billing.v1.tax_group_created\n * @serviceIdentifier wix.billing.v1.TaxGroups\n * @slug created\n * @documentationMaturity preview\n */\nexport declare function onTaxGroupCreated(\n handler: (event: TaxGroupCreatedEnvelope) => void | Promise<void>\n): void;\n\nexport interface TaxGroupDeletedEnvelope {\n metadata: EventMetadata;\n}\n\n/**\n * Triggered when a tax group is deleted.\n * @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Manage Stores\n * @permissionScopeId SCOPE.STORES.MANAGE-STORES\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionScope Manage Orders\n * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS\n * @permissionId BILLING.TAX_GROUP_READ\n * @webhook\n * @eventType wix.billing.v1.tax_group_deleted\n * @serviceIdentifier wix.billing.v1.TaxGroups\n * @slug deleted\n * @documentationMaturity preview\n */\nexport declare function onTaxGroupDeleted(\n handler: (event: TaxGroupDeletedEnvelope) => void | Promise<void>\n): void;\n\nexport interface TaxGroupUpdatedEnvelope {\n entity: TaxGroup;\n metadata: EventMetadata;\n}\n\n/**\n * Triggered when a tax group is updated.\n * @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Manage Stores\n * @permissionScopeId SCOPE.STORES.MANAGE-STORES\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionScope Manage Orders\n * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS\n * @permissionId BILLING.TAX_GROUP_READ\n * @webhook\n * @eventType wix.billing.v1.tax_group_updated\n * @serviceIdentifier wix.billing.v1.TaxGroups\n * @slug updated\n * @documentationMaturity preview\n */\nexport declare function onTaxGroupUpdated(\n handler: (event: TaxGroupUpdatedEnvelope) => void | Promise<void>\n): void;\n\n/**\n * Creates a tax group.\n *\n * Call Stores Update Product to add the `taxGroupId` to specific products to categorize as a group based on distinct tax treatment.\n * Wix uses tax groups to calculate tax.\n *\n * In addition to tax groups you create, default tax groups are already included in all Wix catalogs.\n * Call List Default Tax Groups to retrieve them. You can also use the Tax Groups Integration service plugin (REST only)\n * to create new default tax groups that can be applied directly to an entire catalog of products.\n * @param taxGroup - Tax group to create.\n * @public\n * @documentationMaturity preview\n * @requiredField taxGroup\n * @requiredField taxGroup.name\n * @permissionId BILLING.TAX_GROUP_CREATE\n * @applicableIdentity APP\n * @returns Created tax group.\n * @fqn wix.billing.v1.TaxGroups.CreateTaxGroup\n */\nexport async function createTaxGroup(\n taxGroup: NonNullablePaths<TaxGroup, `name`, 2>\n): Promise<NonNullablePaths<TaxGroup, `name`, 2>> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({ taxGroup: taxGroup });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.createTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.taxGroup!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { taxGroup: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['taxGroup']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a tax group.\n * @param taxGroupId - ID of the tax group to retrieve.\n * @public\n * @documentationMaturity preview\n * @requiredField taxGroupId\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @returns Retrieved tax group.\n * @fqn wix.billing.v1.TaxGroups.GetTaxGroup\n */\nexport async function getTaxGroup(\n taxGroupId: string\n): Promise<NonNullablePaths<TaxGroup, `name`, 2>> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n taxGroupId: taxGroupId,\n });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.getTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.taxGroup!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { taxGroupId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['taxGroupId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Updates a tax group.\n *\n * Each time the tax group is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the tax group.\n * This ensures you're working with the latest tax group and prevents\n * unintended overwrites.\n * @param _id - Tax group ID.\n * @public\n * @documentationMaturity preview\n * @requiredField _id\n * @requiredField taxGroup\n * @requiredField taxGroup.name\n * @requiredField taxGroup.revision\n * @param taxGroup - Tax group info.\n * @permissionId BILLING.TAX_GROUP_UPDATE\n * @applicableIdentity APP\n * @returns Updated tax group.\n * @fqn wix.billing.v1.TaxGroups.UpdateTaxGroup\n */\nexport async function updateTaxGroup(\n _id: string,\n taxGroup: NonNullablePaths<UpdateTaxGroup, `name` | `revision`, 2>\n): Promise<\n NonNullablePaths<TaxGroup, `name`, 2> & {\n __applicationErrorsType?: UpdateTaxGroupApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n taxGroup: { ...taxGroup, id: _id },\n });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.updateTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.taxGroup!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: { taxGroup: '$[1]' },\n explicitPathsToArguments: { 'taxGroup.id': '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['_id', 'taxGroup']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface UpdateTaxGroup {\n /**\n * Tax group ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Tax group name.\n * @minLength 1\n * @maxLength 200\n */\n name?: string;\n /**\n * Revision number, which increments by 1 each time the tax group is updated. To prevent conflicting changes,\n * the current revision must be passed when updating the tax group.\n *\n * Ignored when creating a tax group.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the tax group was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the tax group was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n}\n\n/**\n * Deletes a tax group.\n *\n * If a tax group is deleted but the `taxGroupId` is still assigned to a product (see Stores Products API) then the default tax group is used to calculate tax.\n * @param taxGroupId - ID of the tax group to delete.\n * @public\n * @documentationMaturity preview\n * @requiredField taxGroupId\n * @permissionId BILLING.TAX_GROUP_DELETE\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.DeleteTaxGroup\n */\nexport async function deleteTaxGroup(taxGroupId: string): Promise<void> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n taxGroupId: taxGroupId,\n });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.deleteTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { taxGroupId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['taxGroupId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Creates a query to retrieve a list of tax groups.\n *\n * The `queryTaxGroups()` function builds a query to retrieve a list of tax groups and returns a `TaxGroupsQueryBuilder` object.\n *\n * The returned object contains the query definition, which is typically used to run the query using the `find()` function.\n *\n * You can refine the query by chaining `TaxGroupsQueryBuilder` functions onto the query. `TaxGroupsQueryBuilder` functions enable you to sort, filter, and control the results that `queryTaxGroups()` returns.\n *\n * `queryTaxGroups()` runs with the following `TaxGroupsQueryBuilder` default that you can override:\n * + `ascending(\"_id\")`\n *\n * The functions that are chained to `queryTaxGroups()` are applied in the order they are called. For example, if you apply `ascending(\"name\")` and then `ascending(\"_createdDate\")`, the results are sorted first by the `\"name\"`, and then, if there are multiple results with the same `\"name\"`, the items are sorted by `\"_createdDate\"`.\n *\n * The following `TaxGroupsQueryBuilder` functions are supported for the `queryTaxGroups()` function. For a full description of the tax group object, see the object returned for the `items` property in `TaxGroupsQueryResult`.\n * @public\n * @documentationMaturity preview\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.QueryTaxGroups\n */\nexport function queryTaxGroups(): TaxGroupsQueryBuilder {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n return queryBuilder<\n TaxGroup,\n 'CURSOR',\n QueryTaxGroupsRequest,\n QueryTaxGroupsResponse\n >({\n func: async (payload: QueryTaxGroupsRequest) => {\n const reqOpts = ambassadorWixBillingV1TaxGroup.queryTaxGroups(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n return result;\n } catch (err) {\n sideEffects?.onError?.(err);\n throw err;\n }\n },\n requestTransformer: (query: QueryTaxGroupsRequest['query']) => {\n const args = [query, {}] as [QueryTaxGroupsRequest['query'], {}];\n return renameKeysFromSDKRequestToRESTRequest({\n ...args?.[1],\n query: args?.[0],\n });\n },\n responseTransformer: ({ data }: HttpResponse<QueryTaxGroupsResponse>) => {\n const transformedData = renameKeysFromRESTResponseToSDKResponse(\n transformPaths(data, [])\n );\n\n return {\n items: transformedData?.taxGroups,\n pagingMetadata: transformedData?.pagingMetadata,\n };\n },\n errorTransformer: (err: unknown) => {\n const transformedError = sdkTransformError(err, {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { query: '$[0]' },\n singleArgumentUnchanged: false,\n });\n\n throw transformedError;\n },\n pagingMethod: 'CURSOR',\n transformationPaths: {},\n });\n}\n\ninterface QueryCursorResult {\n cursors: Cursors;\n hasNext: () => boolean;\n hasPrev: () => boolean;\n length: number;\n pageSize: number;\n}\n\nexport interface TaxGroupsQueryResult extends QueryCursorResult {\n items: TaxGroup[];\n query: TaxGroupsQueryBuilder;\n next: () => Promise<TaxGroupsQueryResult>;\n prev: () => Promise<TaxGroupsQueryResult>;\n}\n\nexport interface TaxGroupsQueryBuilder {\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n eq: (\n propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ne: (\n propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ge: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n gt: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n le: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n lt: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `values`.\n * @param values - List of values to compare against.\n * @documentationMaturity preview\n */\n hasSome: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any[]\n ) => TaxGroupsQueryBuilder;\n /** @documentationMaturity preview */\n in: (\n propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @documentationMaturity preview */\n exists: (\n propertyName: '_createdDate' | '_updatedDate',\n value: boolean\n ) => TaxGroupsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n ascending: (\n ...propertyNames: Array<'_id' | 'name' | '_createdDate' | '_updatedDate'>\n ) => TaxGroupsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n descending: (\n ...propertyNames: Array<'_id' | 'name' | '_createdDate' | '_updatedDate'>\n ) => TaxGroupsQueryBuilder;\n /** @param limit - Number of items to return, which is also the `pageSize` of the results object.\n * @documentationMaturity preview\n */\n limit: (limit: number) => TaxGroupsQueryBuilder;\n /** @param cursor - A pointer to specific record\n * @documentationMaturity preview\n */\n skipTo: (cursor: string) => TaxGroupsQueryBuilder;\n /** @documentationMaturity preview */\n find: () => Promise<TaxGroupsQueryResult>;\n}\n\n/**\n * Retrieves a list of default tax groups.\n *\n * The default tax groups for a site are inherited by the apps installed on the site.\n * For example, the Wix Stores app includes a `\"Products\"` tax group by default.\n *\n * Add additional default tax groups with the Tax Groups Integration service plugin (REST only).\n * @public\n * @documentationMaturity preview\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.ListDefaultTaxGroups\n */\nexport async function listDefaultTaxGroups(): Promise<\n NonNullablePaths<\n ListDefaultTaxGroupsResponse,\n `taxGroups` | `taxGroups.${number}.name`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({});\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.listDefaultTaxGroups(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {},\n singleArgumentUnchanged: false,\n },\n []\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves default tax groups for specific apps.\n * @param appIds - App IDs to retrieve default tax groups for.\n * @public\n * @documentationMaturity preview\n * @requiredField appIds\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.ListDefaultTaxGroupsByAppIds\n */\nexport async function listDefaultTaxGroupsByAppIds(\n appIds: string[]\n): Promise<\n NonNullablePaths<\n ListDefaultTaxGroupsByAppIdsResponse,\n | `results`\n | `results.${number}.taxGroupMetadata.originalIndex`\n | `results.${number}.taxGroupMetadata.success`\n | `results.${number}.taxGroupMetadata.error.code`\n | `results.${number}.taxGroupMetadata.error.description`\n | `results.${number}.taxGroup.name`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({ appIds: appIds });\n\n const reqOpts =\n ambassadorWixBillingV1TaxGroup.listDefaultTaxGroupsByAppIds(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appIds: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['appIds']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformSDKFieldMaskToRESTFieldMask } from '@wix/sdk-runtime/transformations/field-mask';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixBillingV1TaxGroupsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'www.wixapis.com': [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n 'manage._base_domain_': [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n _: [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_tax-groups';\n\n/**\n * Creates a tax group.\n *\n * Call Stores Update Product to add the `taxGroupId` to specific products to categorize as a group based on distinct tax treatment.\n * Wix uses tax groups to calculate tax.\n *\n * In addition to tax groups you create, default tax groups are already included in all Wix catalogs.\n * Call List Default Tax Groups to retrieve them. You can also use the Tax Groups Integration service plugin (REST only)\n * to create new default tax groups that can be applied directly to an entire catalog of products.\n */\nexport function createTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __createTaxGroup({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'POST' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.CreateTaxGroup',\n packageName: PACKAGE_NAME,\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __createTaxGroup;\n}\n\n/** Retrieves a tax group. */\nexport function getTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __getTaxGroup({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'GET' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.GetTaxGroup',\n packageName: PACKAGE_NAME,\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/{taxGroupId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getTaxGroup;\n}\n\n/**\n * Updates a tax group.\n *\n * Each time the tax group is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the tax group.\n * This ensures you're working with the latest tax group and prevents\n * unintended overwrites.\n */\nexport function updateTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __updateTaxGroup({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKFieldMaskToRESTFieldMask,\n paths: [{ path: 'fieldMask' }],\n },\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'PATCH' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.UpdateTaxGroup',\n packageName: PACKAGE_NAME,\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/{taxGroup.id}',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __updateTaxGroup;\n}\n\n/**\n * Deletes a tax group.\n *\n * If a tax group is deleted but the `taxGroupId` is still assigned to a product (see Stores Products API) then the default tax group is used to calculate tax.\n */\nexport function deleteTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __deleteTaxGroup({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'DELETE' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.DeleteTaxGroup',\n packageName: PACKAGE_NAME,\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/{taxGroupId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n };\n\n return metadata;\n }\n\n return __deleteTaxGroup;\n}\n\n/**\n * Creates a query to retrieve a list of tax groups.\n *\n * The `queryTaxGroups()` function builds a query to retrieve a list of tax groups and returns a `TaxGroupsQueryBuilder` object.\n *\n * The returned object contains the query definition, which is typically used to run the query using the `find()` function.\n *\n * You can refine the query by chaining `TaxGroupsQueryBuilder` functions onto the query. `TaxGroupsQueryBuilder` functions enable you to sort, filter, and control the results that `queryTaxGroups()` returns.\n *\n * `queryTaxGroups()` runs with the following `TaxGroupsQueryBuilder` default that you can override:\n * + `ascending(\"_id\")`\n *\n * The functions that are chained to `queryTaxGroups()` are applied in the order they are called. For example, if you apply `ascending(\"name\")` and then `ascending(\"_createdDate\")`, the results are sorted first by the `\"name\"`, and then, if there are multiple results with the same `\"name\"`, the items are sorted by `\"_createdDate\"`.\n *\n * The following `TaxGroupsQueryBuilder` functions are supported for the `queryTaxGroups()` function. For a full description of the tax group object, see the object returned for the `items` property in `TaxGroupsQueryResult`.\n */\nexport function queryTaxGroups(payload: object): RequestOptionsFactory<any> {\n function __queryTaxGroups({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'POST' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.QueryTaxGroups',\n packageName: PACKAGE_NAME,\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/query',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroups.createdDate' },\n { path: 'taxGroups.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __queryTaxGroups;\n}\n\n/**\n * Retrieves a list of default tax groups.\n *\n * The default tax groups for a site are inherited by the apps installed on the site.\n * For example, the Wix Stores app includes a `\"Products\"` tax group by default.\n *\n * Add additional default tax groups with the Tax Groups Integration service plugin (REST only).\n */\nexport function listDefaultTaxGroups(\n payload: object\n): RequestOptionsFactory<any> {\n function __listDefaultTaxGroups({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'GET' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.ListDefaultTaxGroups',\n packageName: PACKAGE_NAME,\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/default-tax-groups',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroups.createdDate' },\n { path: 'taxGroups.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __listDefaultTaxGroups;\n}\n\n/** Retrieves default tax groups for specific apps. */\nexport function listDefaultTaxGroupsByAppIds(\n payload: object\n): RequestOptionsFactory<any> {\n function __listDefaultTaxGroupsByAppIds({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'POST' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.ListDefaultTaxGroupsByAppIds',\n packageName: PACKAGE_NAME,\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/list-default-tax-groups-by-app-ids',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'results.taxGroup.createdDate' },\n { path: 'results.taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __listDefaultTaxGroupsByAppIds;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA,wBAAAA;AAAA,EAAA,sBAAAC;AAAA,EAAA,mBAAAC;AAAA,EAAA,4BAAAC;AAAA,EAAA,oCAAAC;AAAA,EAAA,sBAAAC;AAAA,EAAA,sBAAAC;AAAA;AAAA;;;ACAA,6BAAoD;AACpD,2BAA6B;AAC7B,oCAGO;;;ACLP,0BAAkC;AAClC,uBAAqD;AACrD,IAAAC,oBAAqD;AACrD,wBAAqD;AACrD,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Ae,CAAC;AAExE,QAAM,UAC2B,6BAA6B,OAAO;AAErE,eAAa,aAAa;AAC1B,MAAI;AACF,UAAM,SAAS,MAAM,WAAW,QAAQ,OAAO;AAC/C,iBAAa,YAAY,MAAM;AAE/B,eAAO,uEAAwC,OAAO,IAAI;AAAA,EAC5D,SAAS,KAAU;AACjB,UAAM,uBAAmB,uBAAAN;AAAA,MACvB;AAAA,MACA;AAAA,QACE,wBAAwB,CAAC;AAAA,QACzB,0BAA0B,EAAE,QAAQ,OAAO;AAAA,QAC3C,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,QAAQ;AAAA,IACX;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;","names":["createTaxGroup","deleteTaxGroup","getTaxGroup","listDefaultTaxGroups","listDefaultTaxGroupsByAppIds","queryTaxGroups","updateTaxGroup","import_timestamp","import_rest_modules","payload","import_transform_paths","SortOrder","WebhookIdentityType","createTaxGroup","sdkTransformError","getTaxGroup","updateTaxGroup","deleteTaxGroup","queryTaxGroups","listDefaultTaxGroups","listDefaultTaxGroupsByAppIds"]}
1
+ {"version":3,"sources":["../../../index.typings.ts","../../../src/billing-v1-tax-group-tax-groups.universal.ts","../../../src/billing-v1-tax-group-tax-groups.http.ts"],"sourcesContent":["export * from './src/billing-v1-tax-group-tax-groups.universal.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport { queryBuilder } from '@wix/sdk-runtime/query-builder';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, HttpResponse, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixBillingV1TaxGroup from './billing-v1-tax-group-tax-groups.http.js';\n// @ts-ignore\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\n\n/**\n * A tax group is a category of specific line items grouped together based on their tax treatment.\n * You can create new tax groups to apply distinct tax rates and rules.\n */\nexport interface TaxGroup {\n /**\n * Tax group ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Tax group name.\n * @minLength 1\n * @maxLength 200\n */\n name?: string;\n /**\n * Revision number, which increments by 1 each time the tax group is updated. To prevent conflicting changes,\n * the current revision must be passed when updating the tax group.\n *\n * Ignored when creating a tax group.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the tax group was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the tax group was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n}\n\nexport interface CreateTaxGroupRequest {\n /** Tax group to create. */\n taxGroup: TaxGroup;\n}\n\nexport interface CreateTaxGroupResponse {\n /** Created tax group. */\n taxGroup?: TaxGroup;\n}\n\nexport interface GetTaxGroupRequest {\n /**\n * ID of the tax group to retrieve.\n * @format GUID\n */\n taxGroupId: string;\n}\n\nexport interface GetTaxGroupResponse {\n /** Retrieved tax group. */\n taxGroup?: TaxGroup;\n}\n\nexport interface UpdateTaxGroupRequest {\n /** Tax group info to update. */\n taxGroup: TaxGroup;\n}\n\nexport interface UpdateTaxGroupResponse {\n /** Updated tax group. */\n taxGroup?: TaxGroup;\n}\n\nexport interface DeleteTaxGroupRequest {\n /**\n * ID of the tax group to delete.\n * @format GUID\n */\n taxGroupId: string;\n}\n\nexport interface DeleteTaxGroupResponse {}\n\nexport interface QueryTaxGroupsRequest {\n /** Query options. */\n query: QueryV2;\n}\n\nexport interface QueryV2 extends QueryV2PagingMethodOneOf {\n /** Paging options to limit and offset the number of items. */\n paging?: Paging;\n /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */\n cursorPaging?: CursorPaging;\n /**\n * Filter object.\n *\n * Learn more about [filtering](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#filters).\n */\n filter?: Record<string, any> | null;\n /**\n * Sort object.\n *\n * Learn more about [sorting](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#sorting).\n */\n sort?: Sorting[];\n /** Array of projected fields. A list of specific field names to return. If `fieldsets` are also specified, the union of `fieldsets` and `fields` is returned. */\n fields?: string[];\n /** Array of named, predefined sets of projected fields. A array of predefined named sets of fields to be returned. Specifying multiple `fieldsets` will return the union of fields from all sets. If `fields` are also specified, the union of `fieldsets` and `fields` is returned. */\n fieldsets?: string[];\n}\n\n/** @oneof */\nexport interface QueryV2PagingMethodOneOf {\n /** Paging options to limit and offset the number of items. */\n paging?: Paging;\n /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */\n cursorPaging?: CursorPaging;\n}\n\nexport interface Sorting {\n /**\n * Name of the field to sort by.\n * @maxLength 512\n */\n fieldName?: string;\n /** Sort order. */\n order?: SortOrderWithLiterals;\n}\n\nexport enum SortOrder {\n ASC = 'ASC',\n DESC = 'DESC',\n}\n\n/** @enumType */\nexport type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';\n\nexport interface Paging {\n /** Number of items to load. */\n limit?: number | null;\n /** Number of items to skip in the current sort order. */\n offset?: number | null;\n}\n\nexport interface CursorPaging {\n /**\n * Maximum number of items to return in the results.\n * @max 100\n */\n limit?: number | null;\n /**\n * Pointer to the next or previous page in the list of results.\n *\n * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n * Not relevant for the first request.\n * @maxLength 16000\n */\n cursor?: string | null;\n}\n\nexport interface QueryTaxGroupsResponse {\n /** Retrieved default tax groups. */\n taxGroups?: TaxGroup[];\n /** Paging metadata. */\n pagingMetadata?: CursorPagingMetadata;\n}\n\nexport interface CursorPagingMetadata {\n /** Number of items returned in current page. */\n count?: number | null;\n /** Cursor strings that point to the next page, previous page, or both. */\n cursors?: Cursors;\n /**\n * Whether there are more pages to retrieve following the current page.\n *\n * + `true`: Another page of results can be retrieved.\n * + `false`: This is the last page.\n */\n hasNext?: boolean | null;\n}\n\nexport interface Cursors {\n /**\n * Cursor string pointing to the next page in the list of results.\n * @maxLength 16000\n */\n next?: string | null;\n /**\n * Cursor pointing to the previous page in the list of results.\n * @maxLength 16000\n */\n prev?: string | null;\n}\n\nexport interface ListDefaultTaxGroupsRequest {}\n\nexport interface ListDefaultTaxGroupsResponse {\n /** Retrieved default tax groups. */\n taxGroups?: TaxGroup[];\n}\n\nexport interface ListDefaultTaxGroupsByAppIdsRequest {\n /**\n * App IDs to retrieve default tax groups for.\n * @minSize 1\n * @maxSize 300\n * @minLength 1\n */\n appIds: string[];\n}\n\nexport interface ListDefaultTaxGroupsByAppIdsResponse {\n /**\n * Retrieved default tax groups.\n * @minSize 1\n * @maxSize 300\n */\n results?: ListDefaultTaxGroupsByAppIdsResult[];\n /** Bulk action metadata. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ListDefaultTaxGroupsByAppIdsResult {\n /** Information about success or failure to retrieve default tax groups. */\n taxGroupMetadata?: ItemMetadata;\n /** Retrieved default tax groups. */\n taxGroup?: TaxGroup;\n}\n\nexport interface ItemMetadata {\n /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n/** @docsIgnore */\nexport type UpdateTaxGroupApplicationErrors = {\n code?: 'ILLEGAL_UPDATE_ON_SYSTEM_DEFINED_TAX_GROUP';\n description?: string;\n data?: Record<string, any>;\n};\n\nexport interface BaseEventMetadata {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n}\n\nexport interface EventMetadata extends BaseEventMetadata {\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\nexport interface TaxGroupCreatedEnvelope {\n entity: TaxGroup;\n metadata: EventMetadata;\n}\n\n/**\n * Triggered when a tax group is created.\n * @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Manage Stores\n * @permissionScopeId SCOPE.STORES.MANAGE-STORES\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionScope Manage Orders\n * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS\n * @permissionId BILLING.TAX_GROUP_READ\n * @webhook\n * @eventType wix.billing.v1.tax_group_created\n * @serviceIdentifier wix.billing.v1.TaxGroups\n * @slug created\n * @documentationMaturity preview\n */\nexport declare function onTaxGroupCreated(\n handler: (event: TaxGroupCreatedEnvelope) => void | Promise<void>\n): void;\n\nexport interface TaxGroupDeletedEnvelope {\n metadata: EventMetadata;\n}\n\n/**\n * Triggered when a tax group is deleted.\n * @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Manage Stores\n * @permissionScopeId SCOPE.STORES.MANAGE-STORES\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionScope Manage Orders\n * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS\n * @permissionId BILLING.TAX_GROUP_READ\n * @webhook\n * @eventType wix.billing.v1.tax_group_deleted\n * @serviceIdentifier wix.billing.v1.TaxGroups\n * @slug deleted\n * @documentationMaturity preview\n */\nexport declare function onTaxGroupDeleted(\n handler: (event: TaxGroupDeletedEnvelope) => void | Promise<void>\n): void;\n\nexport interface TaxGroupUpdatedEnvelope {\n entity: TaxGroup;\n metadata: EventMetadata;\n}\n\n/**\n * Triggered when a tax group is updated.\n * @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Manage Stores\n * @permissionScopeId SCOPE.STORES.MANAGE-STORES\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionScope Manage Orders\n * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS\n * @permissionId BILLING.TAX_GROUP_READ\n * @webhook\n * @eventType wix.billing.v1.tax_group_updated\n * @serviceIdentifier wix.billing.v1.TaxGroups\n * @slug updated\n * @documentationMaturity preview\n */\nexport declare function onTaxGroupUpdated(\n handler: (event: TaxGroupUpdatedEnvelope) => void | Promise<void>\n): void;\n\n/**\n * Creates a tax group.\n *\n * Call Stores Update Product to add the `taxGroupId` to specific products to categorize as a group based on distinct tax treatment.\n * Wix uses tax groups to calculate tax.\n *\n * In addition to tax groups you create, default tax groups are already included in all Wix catalogs.\n * Call List Default Tax Groups to retrieve them. You can also use the Tax Groups Integration service plugin (REST only)\n * to create new default tax groups that can be applied directly to an entire catalog of products.\n * @param taxGroup - Tax group to create.\n * @public\n * @documentationMaturity preview\n * @requiredField taxGroup\n * @requiredField taxGroup.name\n * @permissionId BILLING.TAX_GROUP_CREATE\n * @applicableIdentity APP\n * @returns Created tax group.\n * @fqn wix.billing.v1.TaxGroups.CreateTaxGroup\n */\nexport async function createTaxGroup(\n taxGroup: NonNullablePaths<TaxGroup, `name`, 2>\n): Promise<NonNullablePaths<TaxGroup, `name`, 2>> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({ taxGroup: taxGroup });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.createTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.taxGroup!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { taxGroup: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['taxGroup']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a tax group.\n * @param taxGroupId - ID of the tax group to retrieve.\n * @public\n * @documentationMaturity preview\n * @requiredField taxGroupId\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @returns Retrieved tax group.\n * @fqn wix.billing.v1.TaxGroups.GetTaxGroup\n */\nexport async function getTaxGroup(\n taxGroupId: string\n): Promise<NonNullablePaths<TaxGroup, `name`, 2>> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n taxGroupId: taxGroupId,\n });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.getTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.taxGroup!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { taxGroupId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['taxGroupId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Updates a tax group.\n *\n * Each time the tax group is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the tax group.\n * This ensures you're working with the latest tax group and prevents\n * unintended overwrites.\n * @param _id - Tax group ID.\n * @public\n * @documentationMaturity preview\n * @requiredField _id\n * @requiredField taxGroup\n * @requiredField taxGroup.name\n * @requiredField taxGroup.revision\n * @param taxGroup - Tax group info.\n * @permissionId BILLING.TAX_GROUP_UPDATE\n * @applicableIdentity APP\n * @returns Updated tax group.\n * @fqn wix.billing.v1.TaxGroups.UpdateTaxGroup\n */\nexport async function updateTaxGroup(\n _id: string,\n taxGroup: NonNullablePaths<UpdateTaxGroup, `name` | `revision`, 2>\n): Promise<\n NonNullablePaths<TaxGroup, `name`, 2> & {\n __applicationErrorsType?: UpdateTaxGroupApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n taxGroup: { ...taxGroup, id: _id },\n });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.updateTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.taxGroup!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: { taxGroup: '$[1]' },\n explicitPathsToArguments: { 'taxGroup.id': '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['_id', 'taxGroup']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface UpdateTaxGroup {\n /**\n * Tax group ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Tax group name.\n * @minLength 1\n * @maxLength 200\n */\n name?: string;\n /**\n * Revision number, which increments by 1 each time the tax group is updated. To prevent conflicting changes,\n * the current revision must be passed when updating the tax group.\n *\n * Ignored when creating a tax group.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the tax group was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the tax group was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n}\n\n/**\n * Deletes a tax group.\n *\n * If a tax group is deleted but the `taxGroupId` is still assigned to a product (see Stores Products API) then the default tax group is used to calculate tax.\n * @param taxGroupId - ID of the tax group to delete.\n * @public\n * @documentationMaturity preview\n * @requiredField taxGroupId\n * @permissionId BILLING.TAX_GROUP_DELETE\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.DeleteTaxGroup\n */\nexport async function deleteTaxGroup(taxGroupId: string): Promise<void> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n taxGroupId: taxGroupId,\n });\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.deleteTaxGroup(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { taxGroupId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['taxGroupId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Creates a query to retrieve a list of tax groups.\n *\n * The `queryTaxGroups()` function builds a query to retrieve a list of tax groups and returns a `TaxGroupsQueryBuilder` object.\n *\n * The returned object contains the query definition, which is typically used to run the query using the `find()` function.\n *\n * You can refine the query by chaining `TaxGroupsQueryBuilder` functions onto the query. `TaxGroupsQueryBuilder` functions enable you to sort, filter, and control the results that `queryTaxGroups()` returns.\n *\n * `queryTaxGroups()` runs with the following `TaxGroupsQueryBuilder` default that you can override:\n * + `ascending(\"_id\")`\n *\n * The functions that are chained to `queryTaxGroups()` are applied in the order they are called. For example, if you apply `ascending(\"name\")` and then `ascending(\"_createdDate\")`, the results are sorted first by the `\"name\"`, and then, if there are multiple results with the same `\"name\"`, the items are sorted by `\"_createdDate\"`.\n *\n * The following `TaxGroupsQueryBuilder` functions are supported for the `queryTaxGroups()` function. For a full description of the tax group object, see the object returned for the `items` property in `TaxGroupsQueryResult`.\n * @public\n * @documentationMaturity preview\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.QueryTaxGroups\n */\nexport function queryTaxGroups(): TaxGroupsQueryBuilder {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n return queryBuilder<\n TaxGroup,\n 'CURSOR',\n QueryTaxGroupsRequest,\n QueryTaxGroupsResponse\n >({\n func: async (payload: QueryTaxGroupsRequest) => {\n const reqOpts = ambassadorWixBillingV1TaxGroup.queryTaxGroups(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n return result;\n } catch (err) {\n sideEffects?.onError?.(err);\n throw err;\n }\n },\n requestTransformer: (query: QueryTaxGroupsRequest['query']) => {\n const args = [query, {}] as [QueryTaxGroupsRequest['query'], {}];\n return renameKeysFromSDKRequestToRESTRequest({\n ...args?.[1],\n query: args?.[0],\n });\n },\n responseTransformer: ({ data }: HttpResponse<QueryTaxGroupsResponse>) => {\n const transformedData = renameKeysFromRESTResponseToSDKResponse(\n transformPaths(data, [])\n );\n\n return {\n items: transformedData?.taxGroups,\n pagingMetadata: transformedData?.pagingMetadata,\n };\n },\n errorTransformer: (err: unknown) => {\n const transformedError = sdkTransformError(err, {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { query: '$[0]' },\n singleArgumentUnchanged: false,\n });\n\n throw transformedError;\n },\n pagingMethod: 'CURSOR',\n transformationPaths: {},\n });\n}\n\ninterface QueryCursorResult {\n cursors: Cursors;\n hasNext: () => boolean;\n hasPrev: () => boolean;\n length: number;\n pageSize: number;\n}\n\nexport interface TaxGroupsQueryResult extends QueryCursorResult {\n items: TaxGroup[];\n query: TaxGroupsQueryBuilder;\n next: () => Promise<TaxGroupsQueryResult>;\n prev: () => Promise<TaxGroupsQueryResult>;\n}\n\nexport interface TaxGroupsQueryBuilder {\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n eq: (\n propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ne: (\n propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ge: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n gt: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n le: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n lt: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `values`.\n * @param values - List of values to compare against.\n * @documentationMaturity preview\n */\n hasSome: (\n propertyName: '_createdDate' | '_updatedDate',\n value: any[]\n ) => TaxGroupsQueryBuilder;\n /** @documentationMaturity preview */\n in: (\n propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate',\n value: any\n ) => TaxGroupsQueryBuilder;\n /** @documentationMaturity preview */\n exists: (\n propertyName: '_createdDate' | '_updatedDate',\n value: boolean\n ) => TaxGroupsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n ascending: (\n ...propertyNames: Array<'_id' | 'name' | '_createdDate' | '_updatedDate'>\n ) => TaxGroupsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n descending: (\n ...propertyNames: Array<'_id' | 'name' | '_createdDate' | '_updatedDate'>\n ) => TaxGroupsQueryBuilder;\n /** @param limit - Number of items to return, which is also the `pageSize` of the results object.\n * @documentationMaturity preview\n */\n limit: (limit: number) => TaxGroupsQueryBuilder;\n /** @param cursor - A pointer to specific record\n * @documentationMaturity preview\n */\n skipTo: (cursor: string) => TaxGroupsQueryBuilder;\n /** @documentationMaturity preview */\n find: () => Promise<TaxGroupsQueryResult>;\n}\n\n/**\n * Retrieves a list of default tax groups.\n *\n * The default tax groups for a site are inherited by the apps installed on the site.\n * For example, the Wix Stores app includes a `\"Products\"` tax group by default.\n *\n * Add additional default tax groups with the Tax Groups Integration service plugin (REST only).\n * @public\n * @documentationMaturity preview\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.ListDefaultTaxGroups\n */\nexport async function listDefaultTaxGroups(): Promise<\n NonNullablePaths<\n ListDefaultTaxGroupsResponse,\n `taxGroups` | `taxGroups.${number}.name`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({});\n\n const reqOpts = ambassadorWixBillingV1TaxGroup.listDefaultTaxGroups(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {},\n singleArgumentUnchanged: false,\n },\n []\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves default tax groups for specific apps.\n * @param appIds - App IDs to retrieve default tax groups for.\n * @public\n * @documentationMaturity preview\n * @requiredField appIds\n * @permissionId BILLING.TAX_GROUP_READ\n * @applicableIdentity APP\n * @fqn wix.billing.v1.TaxGroups.ListDefaultTaxGroupsByAppIds\n */\nexport async function listDefaultTaxGroupsByAppIds(\n appIds: string[]\n): Promise<\n NonNullablePaths<\n ListDefaultTaxGroupsByAppIdsResponse,\n | `results`\n | `results.${number}.taxGroupMetadata.originalIndex`\n | `results.${number}.taxGroupMetadata.success`\n | `results.${number}.taxGroupMetadata.error.code`\n | `results.${number}.taxGroupMetadata.error.description`\n | `results.${number}.taxGroup.name`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({ appIds: appIds });\n\n const reqOpts =\n ambassadorWixBillingV1TaxGroup.listDefaultTaxGroupsByAppIds(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appIds: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['appIds']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformSDKFieldMaskToRESTFieldMask } from '@wix/sdk-runtime/transformations/field-mask';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixBillingV1TaxGroupsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'www.wixapis.com': [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n 'manage._base_domain_': [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n _: [\n {\n srcPath: '/billing/v1/tax-groups',\n destPath: '/v1/tax-groups',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_tax-groups';\n\n/**\n * Creates a tax group.\n *\n * Call Stores Update Product to add the `taxGroupId` to specific products to categorize as a group based on distinct tax treatment.\n * Wix uses tax groups to calculate tax.\n *\n * In addition to tax groups you create, default tax groups are already included in all Wix catalogs.\n * Call List Default Tax Groups to retrieve them. You can also use the Tax Groups Integration service plugin (REST only)\n * to create new default tax groups that can be applied directly to an entire catalog of products.\n */\nexport function createTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __createTaxGroup({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'POST' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.CreateTaxGroup',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __createTaxGroup;\n}\n\n/** Retrieves a tax group. */\nexport function getTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __getTaxGroup({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'GET' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.GetTaxGroup',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/{taxGroupId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getTaxGroup;\n}\n\n/**\n * Updates a tax group.\n *\n * Each time the tax group is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the tax group.\n * This ensures you're working with the latest tax group and prevents\n * unintended overwrites.\n */\nexport function updateTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __updateTaxGroup({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKFieldMaskToRESTFieldMask,\n paths: [{ path: 'fieldMask' }],\n },\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'PATCH' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.UpdateTaxGroup',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/{taxGroup.id}',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroup.createdDate' },\n { path: 'taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __updateTaxGroup;\n}\n\n/**\n * Deletes a tax group.\n *\n * If a tax group is deleted but the `taxGroupId` is still assigned to a product (see Stores Products API) then the default tax group is used to calculate tax.\n */\nexport function deleteTaxGroup(payload: object): RequestOptionsFactory<any> {\n function __deleteTaxGroup({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'DELETE' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.DeleteTaxGroup',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/{taxGroupId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n };\n\n return metadata;\n }\n\n return __deleteTaxGroup;\n}\n\n/**\n * Creates a query to retrieve a list of tax groups.\n *\n * The `queryTaxGroups()` function builds a query to retrieve a list of tax groups and returns a `TaxGroupsQueryBuilder` object.\n *\n * The returned object contains the query definition, which is typically used to run the query using the `find()` function.\n *\n * You can refine the query by chaining `TaxGroupsQueryBuilder` functions onto the query. `TaxGroupsQueryBuilder` functions enable you to sort, filter, and control the results that `queryTaxGroups()` returns.\n *\n * `queryTaxGroups()` runs with the following `TaxGroupsQueryBuilder` default that you can override:\n * + `ascending(\"_id\")`\n *\n * The functions that are chained to `queryTaxGroups()` are applied in the order they are called. For example, if you apply `ascending(\"name\")` and then `ascending(\"_createdDate\")`, the results are sorted first by the `\"name\"`, and then, if there are multiple results with the same `\"name\"`, the items are sorted by `\"_createdDate\"`.\n *\n * The following `TaxGroupsQueryBuilder` functions are supported for the `queryTaxGroups()` function. For a full description of the tax group object, see the object returned for the `items` property in `TaxGroupsQueryResult`.\n */\nexport function queryTaxGroups(payload: object): RequestOptionsFactory<any> {\n function __queryTaxGroups({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'POST' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.QueryTaxGroups',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/query',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroups.createdDate' },\n { path: 'taxGroups.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __queryTaxGroups;\n}\n\n/**\n * Retrieves a list of default tax groups.\n *\n * The default tax groups for a site are inherited by the apps installed on the site.\n * For example, the Wix Stores app includes a `\"Products\"` tax group by default.\n *\n * Add additional default tax groups with the Tax Groups Integration service plugin (REST only).\n */\nexport function listDefaultTaxGroups(\n payload: object\n): RequestOptionsFactory<any> {\n function __listDefaultTaxGroups({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'GET' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.ListDefaultTaxGroups',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/default-tax-groups',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'taxGroups.createdDate' },\n { path: 'taxGroups.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __listDefaultTaxGroups;\n}\n\n/** Retrieves default tax groups for specific apps. */\nexport function listDefaultTaxGroupsByAppIds(\n payload: object\n): RequestOptionsFactory<any> {\n function __listDefaultTaxGroupsByAppIds({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.billing.v1.tax_group',\n method: 'POST' as any,\n methodFqn: 'wix.billing.v1.TaxGroups.ListDefaultTaxGroupsByAppIds',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixBillingV1TaxGroupsUrl({\n protoPath: '/v1/tax-groups/list-default-tax-groups-by-app-ids',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'results.taxGroup.createdDate' },\n { path: 'results.taxGroup.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __listDefaultTaxGroupsByAppIds;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA,wBAAAA;AAAA,EAAA,sBAAAC;AAAA,EAAA,m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Y,YAAY,IAAI,UAAU,CAAC;AAK/C,QAAM,cAAU,qEAAsC,CAAC,CAAC;AAExD,QAAM,UAAyC,qBAAqB,OAAO;AAE3E,eAAa,aAAa;AAC1B,MAAI;AACF,UAAM,SAAS,MAAM,WAAW,QAAQ,OAAO;AAC/C,iBAAa,YAAY,MAAM;AAE/B,eAAO,uEAAwC,OAAO,IAAI;AAAA,EAC5D,SAAS,KAAU;AACjB,UAAM,uBAAmB,uBAAAL;AAAA,MACvB;AAAA,MACA;AAAA,QACE,wBAAwB,CAAC;AAAA,QACzB,0BAA0B,CAAC;AAAA,QAC3B,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC;AAAA,IACH;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;AAYA,eAAsBM,8BACpB,QAeA;AAEA,QAAM,EAAE,YAAY,YAAY,IAAI,UAAU,CAAC;AAK/C,QAAM,cAAU,qEAAsC,EAAE,OAAe,CAAC;AAExE,QAAM,UAC2B,6BAA6B,OAAO;AAErE,eAAa,aAAa;AAC1B,MAAI;AACF,UAAM,SAAS,MAAM,WAAW,QAAQ,OAAO;AAC/C,iBAAa,YAAY,MAAM;AAE/B,eAAO,uEAAwC,OAAO,IAAI;AAAA,EAC5D,SAAS,KAAU;AACjB,UAAM,uBAAmB,uBAAAN;AAAA,MACvB;AAAA,MACA;AAAA,QACE,wBAAwB,CAAC;AAAA,QACzB,0BAA0B,EAAE,QAAQ,OAAO;AAAA,QAC3C,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,QAAQ;AAAA,IACX;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;","names":["createTaxGroup","deleteTaxGroup","getTaxGroup","listDefaultTaxGroups","listDefaultTaxGroupsByAppIds","queryTaxGroups","updateTaxGroup","import_timestamp","import_rest_modules","payload","import_transform_paths","SortOrder","WebhookIdentityType","createTaxGroup","sdkTransformError","getTaxGroup","updateTaxGroup","deleteTaxGroup","queryTaxGroups","listDefaultTaxGroups","listDefaultTaxGroupsByAppIds"]}
@@ -230,6 +230,148 @@ interface BulkActionMetadata {
230
230
  /** Number of failures without details because detailed failure threshold was exceeded. */
231
231
  undetailedFailures?: number;
232
232
  }
233
+ interface DomainEvent extends DomainEventBodyOneOf {
234
+ createdEvent?: EntityCreatedEvent;
235
+ updatedEvent?: EntityUpdatedEvent;
236
+ deletedEvent?: EntityDeletedEvent;
237
+ actionEvent?: ActionEvent;
238
+ /** Event ID. With this ID you can easily spot duplicated events and ignore them. */
239
+ id?: string;
240
+ /**
241
+ * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
242
+ * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
243
+ */
244
+ entityFqdn?: string;
245
+ /**
246
+ * Event action name, placed at the top level to make it easier for users to dispatch messages.
247
+ * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
248
+ */
249
+ slug?: string;
250
+ /** ID of the entity associated with the event. */
251
+ entityId?: string;
252
+ /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
253
+ eventTime?: Date | null;
254
+ /**
255
+ * Whether the event was triggered as a result of a privacy regulation application
256
+ * (for example, GDPR).
257
+ */
258
+ triggeredByAnonymizeRequest?: boolean | null;
259
+ /** If present, indicates the action that triggered the event. */
260
+ originatedFrom?: string | null;
261
+ /**
262
+ * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.
263
+ * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
264
+ */
265
+ entityEventSequence?: string | null;
266
+ }
267
+ /** @oneof */
268
+ interface DomainEventBodyOneOf {
269
+ createdEvent?: EntityCreatedEvent;
270
+ updatedEvent?: EntityUpdatedEvent;
271
+ deletedEvent?: EntityDeletedEvent;
272
+ actionEvent?: ActionEvent;
273
+ }
274
+ interface EntityCreatedEvent {
275
+ entityAsJson?: string;
276
+ /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
277
+ restoreInfo?: RestoreInfo;
278
+ }
279
+ interface RestoreInfo {
280
+ deletedDate?: Date | null;
281
+ }
282
+ interface EntityUpdatedEvent {
283
+ /**
284
+ * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
285
+ * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
286
+ * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
287
+ */
288
+ currentEntityAsJson?: string;
289
+ }
290
+ interface EntityDeletedEvent {
291
+ /** Entity that was deleted. */
292
+ deletedEntityAsJson?: string | null;
293
+ }
294
+ interface ActionEvent {
295
+ bodyAsJson?: string;
296
+ }
297
+ interface MessageEnvelope {
298
+ /**
299
+ * App instance ID.
300
+ * @format GUID
301
+ */
302
+ instanceId?: string | null;
303
+ /**
304
+ * Event type.
305
+ * @maxLength 150
306
+ */
307
+ eventType?: string;
308
+ /** The identification type and identity data. */
309
+ identity?: IdentificationData;
310
+ /** Stringify payload. */
311
+ data?: string;
312
+ }
313
+ interface IdentificationData extends IdentificationDataIdOneOf {
314
+ /**
315
+ * ID of a site visitor that has not logged in to the site.
316
+ * @format GUID
317
+ */
318
+ anonymousVisitorId?: string;
319
+ /**
320
+ * ID of a site visitor that has logged in to the site.
321
+ * @format GUID
322
+ */
323
+ memberId?: string;
324
+ /**
325
+ * ID of a Wix user (site owner, contributor, etc.).
326
+ * @format GUID
327
+ */
328
+ wixUserId?: string;
329
+ /**
330
+ * ID of an app.
331
+ * @format GUID
332
+ */
333
+ appId?: string;
334
+ /** @readonly */
335
+ identityType?: WebhookIdentityTypeWithLiterals;
336
+ }
337
+ /** @oneof */
338
+ interface IdentificationDataIdOneOf {
339
+ /**
340
+ * ID of a site visitor that has not logged in to the site.
341
+ * @format GUID
342
+ */
343
+ anonymousVisitorId?: string;
344
+ /**
345
+ * ID of a site visitor that has logged in to the site.
346
+ * @format GUID
347
+ */
348
+ memberId?: string;
349
+ /**
350
+ * ID of a Wix user (site owner, contributor, etc.).
351
+ * @format GUID
352
+ */
353
+ wixUserId?: string;
354
+ /**
355
+ * ID of an app.
356
+ * @format GUID
357
+ */
358
+ appId?: string;
359
+ }
360
+ declare enum WebhookIdentityType {
361
+ UNKNOWN = "UNKNOWN",
362
+ ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
363
+ MEMBER = "MEMBER",
364
+ WIX_USER = "WIX_USER",
365
+ APP = "APP"
366
+ }
367
+ /** @enumType */
368
+ type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
369
+ /** @docsIgnore */
370
+ type UpdateTaxGroupApplicationErrors = {
371
+ code?: 'ILLEGAL_UPDATE_ON_SYSTEM_DEFINED_TAX_GROUP';
372
+ description?: string;
373
+ data?: Record<string, any>;
374
+ };
233
375
 
234
376
  type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
235
377
  getUrl: (context: any) => string;
@@ -255,4 +397,4 @@ declare function queryTaxGroups(): __PublicMethodMetaInfo<'POST', {}, QueryTaxGr
255
397
  declare function listDefaultTaxGroups(): __PublicMethodMetaInfo<'GET', {}, ListDefaultTaxGroupsRequest$1, ListDefaultTaxGroupsRequest, ListDefaultTaxGroupsResponse$1, ListDefaultTaxGroupsResponse>;
256
398
  declare function listDefaultTaxGroupsByAppIds(): __PublicMethodMetaInfo<'POST', {}, ListDefaultTaxGroupsByAppIdsRequest$1, ListDefaultTaxGroupsByAppIdsRequest, ListDefaultTaxGroupsByAppIdsResponse$1, ListDefaultTaxGroupsByAppIdsResponse>;
257
399
 
258
- export { type __PublicMethodMetaInfo, createTaxGroup, deleteTaxGroup, getTaxGroup, listDefaultTaxGroups, listDefaultTaxGroupsByAppIds, queryTaxGroups, updateTaxGroup };
400
+ export { type ActionEvent as ActionEventOriginal, type ApplicationError as ApplicationErrorOriginal, type BulkActionMetadata as BulkActionMetadataOriginal, type CreateTaxGroupRequest as CreateTaxGroupRequestOriginal, type CreateTaxGroupResponse as CreateTaxGroupResponseOriginal, type CursorPagingMetadata as CursorPagingMetadataOriginal, type CursorPaging as CursorPagingOriginal, type Cursors as CursorsOriginal, type DeleteTaxGroupRequest as DeleteTaxGroupRequestOriginal, type DeleteTaxGroupResponse as DeleteTaxGroupResponseOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type GetTaxGroupRequest as GetTaxGroupRequestOriginal, type GetTaxGroupResponse as GetTaxGroupResponseOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, type ItemMetadata as ItemMetadataOriginal, type ListDefaultTaxGroupsByAppIdsRequest as ListDefaultTaxGroupsByAppIdsRequestOriginal, type ListDefaultTaxGroupsByAppIdsResponse as ListDefaultTaxGroupsByAppIdsResponseOriginal, type ListDefaultTaxGroupsByAppIdsResult as ListDefaultTaxGroupsByAppIdsResultOriginal, type ListDefaultTaxGroupsRequest as ListDefaultTaxGroupsRequestOriginal, type ListDefaultTaxGroupsResponse as ListDefaultTaxGroupsResponseOriginal, type MessageEnvelope as MessageEnvelopeOriginal, type Paging as PagingOriginal, type QueryTaxGroupsRequest as QueryTaxGroupsRequestOriginal, type QueryTaxGroupsResponse as QueryTaxGroupsResponseOriginal, type QueryV2 as QueryV2Original, type QueryV2PagingMethodOneOf as QueryV2PagingMethodOneOfOriginal, type RestoreInfo as RestoreInfoOriginal, SortOrder as SortOrderOriginal, type SortOrderWithLiterals as SortOrderWithLiteralsOriginal, type Sorting as SortingOriginal, type TaxGroup as TaxGroupOriginal, type UpdateTaxGroupApplicationErrors as UpdateTaxGroupApplicationErrorsOriginal, type UpdateTaxGroupRequest as UpdateTaxGroupRequestOriginal, type UpdateTaxGroupResponse as UpdateTaxGroupResponseOriginal, WebhookIdentityType as WebhookIdentityTypeOriginal, type WebhookIdentityTypeWithLiterals as WebhookIdentityTypeWithLiteralsOriginal, type __PublicMethodMetaInfo, createTaxGroup, deleteTaxGroup, getTaxGroup, listDefaultTaxGroups, listDefaultTaxGroupsByAppIds, queryTaxGroups, updateTaxGroup };
@@ -20,6 +20,8 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
20
20
  // meta.ts
21
21
  var meta_exports = {};
22
22
  __export(meta_exports, {
23
+ SortOrderOriginal: () => SortOrder,
24
+ WebhookIdentityTypeOriginal: () => WebhookIdentityType,
23
25
  createTaxGroup: () => createTaxGroup2,
24
26
  deleteTaxGroup: () => deleteTaxGroup2,
25
27
  getTaxGroup: () => getTaxGroup2,
@@ -83,6 +85,9 @@ function createTaxGroup(payload) {
83
85
  method: "POST",
84
86
  methodFqn: "wix.billing.v1.TaxGroups.CreateTaxGroup",
85
87
  packageName: PACKAGE_NAME,
88
+ migrationOptions: {
89
+ optInTransformResponse: true
90
+ },
86
91
  url: resolveWixBillingV1TaxGroupsUrl({
87
92
  protoPath: "/v1/tax-groups",
88
93
  data: serializedData,
@@ -110,6 +115,9 @@ function getTaxGroup(payload) {
110
115
  method: "GET",
111
116
  methodFqn: "wix.billing.v1.TaxGroups.GetTaxGroup",
112
117
  packageName: PACKAGE_NAME,
118
+ migrationOptions: {
119
+ optInTransformResponse: true
120
+ },
113
121
  url: resolveWixBillingV1TaxGroupsUrl({
114
122
  protoPath: "/v1/tax-groups/{taxGroupId}",
115
123
  data: payload,
@@ -150,6 +158,9 @@ function updateTaxGroup(payload) {
150
158
  method: "PATCH",
151
159
  methodFqn: "wix.billing.v1.TaxGroups.UpdateTaxGroup",
152
160
  packageName: PACKAGE_NAME,
161
+ migrationOptions: {
162
+ optInTransformResponse: true
163
+ },
153
164
  url: resolveWixBillingV1TaxGroupsUrl({
154
165
  protoPath: "/v1/tax-groups/{taxGroup.id}",
155
166
  data: serializedData,
@@ -177,6 +188,9 @@ function deleteTaxGroup(payload) {
177
188
  method: "DELETE",
178
189
  methodFqn: "wix.billing.v1.TaxGroups.DeleteTaxGroup",
179
190
  packageName: PACKAGE_NAME,
191
+ migrationOptions: {
192
+ optInTransformResponse: true
193
+ },
180
194
  url: resolveWixBillingV1TaxGroupsUrl({
181
195
  protoPath: "/v1/tax-groups/{taxGroupId}",
182
196
  data: payload,
@@ -195,6 +209,9 @@ function queryTaxGroups(payload) {
195
209
  method: "POST",
196
210
  methodFqn: "wix.billing.v1.TaxGroups.QueryTaxGroups",
197
211
  packageName: PACKAGE_NAME,
212
+ migrationOptions: {
213
+ optInTransformResponse: true
214
+ },
198
215
  url: resolveWixBillingV1TaxGroupsUrl({
199
216
  protoPath: "/v1/tax-groups/query",
200
217
  data: payload,
@@ -222,6 +239,9 @@ function listDefaultTaxGroups(payload) {
222
239
  method: "GET",
223
240
  methodFqn: "wix.billing.v1.TaxGroups.ListDefaultTaxGroups",
224
241
  packageName: PACKAGE_NAME,
242
+ migrationOptions: {
243
+ optInTransformResponse: true
244
+ },
225
245
  url: resolveWixBillingV1TaxGroupsUrl({
226
246
  protoPath: "/v1/tax-groups/default-tax-groups",
227
247
  data: payload,
@@ -249,6 +269,9 @@ function listDefaultTaxGroupsByAppIds(payload) {
249
269
  method: "POST",
250
270
  methodFqn: "wix.billing.v1.TaxGroups.ListDefaultTaxGroupsByAppIds",
251
271
  packageName: PACKAGE_NAME,
272
+ migrationOptions: {
273
+ optInTransformResponse: true
274
+ },
252
275
  url: resolveWixBillingV1TaxGroupsUrl({
253
276
  protoPath: "/v1/tax-groups/list-default-tax-groups-by-app-ids",
254
277
  data: payload,
@@ -270,6 +293,21 @@ function listDefaultTaxGroupsByAppIds(payload) {
270
293
  return __listDefaultTaxGroupsByAppIds;
271
294
  }
272
295
 
296
+ // src/billing-v1-tax-group-tax-groups.types.ts
297
+ var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
298
+ SortOrder2["ASC"] = "ASC";
299
+ SortOrder2["DESC"] = "DESC";
300
+ return SortOrder2;
301
+ })(SortOrder || {});
302
+ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
303
+ WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
304
+ WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
305
+ WebhookIdentityType2["MEMBER"] = "MEMBER";
306
+ WebhookIdentityType2["WIX_USER"] = "WIX_USER";
307
+ WebhookIdentityType2["APP"] = "APP";
308
+ return WebhookIdentityType2;
309
+ })(WebhookIdentityType || {});
310
+
273
311
  // src/billing-v1-tax-group-tax-groups.meta.ts
274
312
  function createTaxGroup2() {
275
313
  const payload = {};
@@ -399,6 +437,8 @@ function listDefaultTaxGroupsByAppIds2() {
399
437
  }
400
438
  // Annotate the CommonJS export names for ESM import in node:
401
439
  0 && (module.exports = {
440
+ SortOrderOriginal,
441
+ WebhookIdentityTypeOriginal,
402
442
  createTaxGroup,
403
443
  deleteTaxGroup,
404
444
  getTaxGroup,