@wix/auto_sdk_restaurants_recipients 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +2 -10
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +1 -5
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +2 -10
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +1 -5
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +2 -10
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +1 -5
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +2 -10
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +1 -5
- package/package.json +2 -2
package/build/es/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/restaurants-recipient-v1-recipient-recipients.public.ts","../../src/restaurants-recipient-v1-recipient-recipients.universal.ts","../../src/restaurants-recipient-v1-recipient-recipients.http.ts","../../src/restaurants-recipient-v1-recipient-recipients.context.ts"],"sourcesContent":["import { renameKeysFromRESTResponseToSDKResponse } from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { EventDefinition, HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n BulkUpdateRecipientTagsApplicationErrors,\n BulkUpdateRecipientTagsByFilterApplicationErrors,\n BulkUpdateRecipientTagsByFilterOptions,\n BulkUpdateRecipientTagsByFilterResponse,\n BulkUpdateRecipientTagsOptions,\n BulkUpdateRecipientTagsResponse,\n Recipient,\n RecipientCreatedEnvelope,\n RecipientDeletedEnvelope,\n RecipientUpdatedEnvelope,\n RecipientsQueryBuilder,\n UpdateRecipient,\n bulkUpdateRecipientTags as universalBulkUpdateRecipientTags,\n bulkUpdateRecipientTagsByFilter as universalBulkUpdateRecipientTagsByFilter,\n createRecipient as universalCreateRecipient,\n deleteRecipient as universalDeleteRecipient,\n getRecipient as universalGetRecipient,\n queryRecipients as universalQueryRecipients,\n updateRecipient as universalUpdateRecipient,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/restaurants' };\n\nexport function createRecipient(\n httpClient: HttpClient\n): CreateRecipientSignature {\n return (recipient: NonNullablePaths<Recipient, `channels`, 2>) =>\n universalCreateRecipient(\n recipient,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface CreateRecipientSignature {\n /**\n * Creates a recipient.\n * @param - Recipient to create.\n * @returns Created recipient.\n */\n (recipient: NonNullablePaths<Recipient, `channels`, 2>): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\nexport function getRecipient(httpClient: HttpClient): GetRecipientSignature {\n return (recipientId: string) =>\n universalGetRecipient(\n recipientId,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetRecipientSignature {\n /**\n * Retrieves a recipient by ID.\n * @param - ID of the recipient to retrieve.\n * @returns Retrieved recipient.\n */\n (recipientId: string): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\nexport function updateRecipient(\n httpClient: HttpClient\n): UpdateRecipientSignature {\n return (\n _id: string,\n recipient: NonNullablePaths<UpdateRecipient, `revision`, 2>\n ) =>\n universalUpdateRecipient(\n _id,\n recipient,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface UpdateRecipientSignature {\n /**\n * Updates a recipient's information.\n *\n * Each time the recipient is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the recipient.\n * This ensures you're working with the latest recipient and prevents unintended overwrites.\n * @param - Recipient ID.\n * @returns Updated recipient.\n */\n (\n _id: string,\n recipient: NonNullablePaths<UpdateRecipient, `revision`, 2>\n ): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\nexport function deleteRecipient(\n httpClient: HttpClient\n): DeleteRecipientSignature {\n return (recipientId: string) =>\n universalDeleteRecipient(\n recipientId,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface DeleteRecipientSignature {\n /**\n * Deletes a recipient.\n * @param - ID of the recipient to delete.\n */\n (recipientId: string): Promise<void>;\n}\n\nexport function queryRecipients(\n httpClient: HttpClient\n): QueryRecipientsSignature {\n return () =>\n universalQueryRecipients(\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface QueryRecipientsSignature {\n /**\n * Retrieves a list of recipients with optional filtering, sorting, and paging.\n *\n * Up to 100 recipients can be returned per request.\n *\n * For a detailed list of supported operations, see the [Supported Filters and Sorting](https://dev.wix.com/docs/api-reference/business-solutions/restaurants/wix-restaurants-new/online-orders/notification-recipients/supported-filters-and-sorting) article.\n * To learn how to query notification recipients, see [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).\n *\n * Supported properties for filtering and sorting:\n * `id`, `createdDate`, `updatedDate`, `channels`\n */\n (): RecipientsQueryBuilder;\n}\n\nexport function bulkUpdateRecipientTags(\n httpClient: HttpClient\n): BulkUpdateRecipientTagsSignature {\n return (recipientIds: string[], options?: BulkUpdateRecipientTagsOptions) =>\n universalBulkUpdateRecipientTags(\n recipientIds,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateRecipientTagsSignature {\n /**\n * Updates tags on multiple recipients by recipient IDs.\n *\n * This is a synchronous operation that updates up to 100 recipients at once.\n * If a tag appears in both assign and unassign lists, it will be assigned.\n * @param - IDs of recipients to update tags for.\n */\n (recipientIds: string[], options?: BulkUpdateRecipientTagsOptions): Promise<\n NonNullablePaths<\n BulkUpdateRecipientTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateRecipientTagsApplicationErrors;\n }\n >;\n}\n\nexport function bulkUpdateRecipientTagsByFilter(\n httpClient: HttpClient\n): BulkUpdateRecipientTagsByFilterSignature {\n return (\n filter: Record<string, any>,\n options?: BulkUpdateRecipientTagsByFilterOptions\n ) =>\n universalBulkUpdateRecipientTagsByFilter(\n filter,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateRecipientTagsByFilterSignature {\n /**\n * Updates tags on multiple recipients using filter criteria.\n *\n * This is an asynchronous operation that returns a job ID for tracking progress.\n * An empty filter will update all recipients. If a tag appears in both assign and unassign lists, it will be assigned.\n * @param - Filter.\n */\n (\n filter: Record<string, any>,\n options?: BulkUpdateRecipientTagsByFilterOptions\n ): Promise<\n NonNullablePaths<BulkUpdateRecipientTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateRecipientTagsByFilterApplicationErrors;\n }\n >;\n}\n\nexport const onRecipientCreated = EventDefinition(\n 'wix.restaurants.recipient.v1.recipient_created',\n true,\n (event: RecipientCreatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'metadata.eventTime' },\n ],\n },\n ])\n )\n)<RecipientCreatedEnvelope>();\nexport const onRecipientDeleted = EventDefinition(\n 'wix.restaurants.recipient.v1.recipient_deleted',\n true,\n (event: RecipientDeletedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'metadata.eventTime' },\n ],\n },\n ])\n )\n)<RecipientDeletedEnvelope>();\nexport const onRecipientUpdated = EventDefinition(\n 'wix.restaurants.recipient.v1.recipient_updated',\n true,\n (event: RecipientUpdatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'metadata.eventTime' },\n ],\n },\n ])\n )\n)<RecipientUpdatedEnvelope>();\n\nexport {\n ActionEvent,\n ApplicationError,\n BaseEventMetadata,\n BulkActionMetadata,\n BulkUpdateRecipientTagsByFilterOptions,\n BulkUpdateRecipientTagsByFilterRequest,\n BulkUpdateRecipientTagsByFilterResponse,\n BulkUpdateRecipientTagsOptions,\n BulkUpdateRecipientTagsRequest,\n BulkUpdateRecipientTagsResponse,\n BulkUpdateRecipientTagsResult,\n Channel,\n CreateRecipientRequest,\n CreateRecipientResponse,\n CursorPaging,\n CursorPagingMetadata,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Cursors,\n DeleteRecipientRequest,\n DeleteRecipientResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n EventMetadata,\n ExtendedFields,\n GetRecipientRequest,\n GetRecipientResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemMetadata,\n MessageEnvelope,\n QueryRecipientsRequest,\n QueryRecipientsResponse,\n Recipient,\n RecipientCreatedEnvelope,\n RecipientDeletedEnvelope,\n RecipientUpdatedEnvelope,\n RecipientsQueryBuilder,\n RecipientsQueryResult,\n RestoreInfo,\n SortOrder,\n Sorting,\n TagList,\n Tags,\n UpdateRecipient,\n UpdateRecipientRequest,\n UpdateRecipientResponse,\n WebhookIdentityType,\n} from './restaurants-recipient-v1-recipient-recipients.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 ambassadorWixRestaurantsRecipientV1Recipient from './restaurants-recipient-v1-recipient-recipients.http.js';\n// @ts-ignore\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\n\nexport interface Recipient {\n /**\n * Recipient ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Revision number, which increments by 1 each time the Recipient is updated.\n * To prevent conflicting changes,\n * the current revision must be passed when updating the Recipient.\n *\n * Ignored when creating a Recipient.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the Recipient was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the Recipient was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Recipient's phone number for receiving notifications.\n * @format PHONE\n */\n phone?: string;\n /**\n * IDs of the business locations this recipient should receive order creation notifications for.\n *\n * If this list is empty the recipient receives notifications for orders created at all locations.\n * @maxSize 100\n * @format GUID\n */\n businessLocationIds?: string[];\n /**\n * Communication channels for sending notifications to the recipient.\n *\n * At least 1 channel is required. Recipients can receive notifications\n * through multiple channels simultaneously.\n * @minSize 1\n * @maxSize 2\n */\n channels?: ChannelWithLiterals[];\n /**\n * Additional information about the recipient.\n *\n * Use this field to store notes about the recipient's role, availability,\n * or other relevant details for notification management.\n * @maxLength 500\n */\n note?: string | null;\n /**\n * Additional custom fields for the recipient.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/api-reference/business-solutions/wix-api/extended-fields).\n */\n extendedFields?: ExtendedFields;\n /**\n * Tags for categorizing and organizing recipients.\n *\n * Use tags to group recipients by role (manager, kitchen staff), shift (morning, evening), or other criteria for targeted notifications.\n */\n tags?: Tags;\n}\n\nexport enum Channel {\n UNKNOWN_CHANNEL = 'UNKNOWN_CHANNEL',\n /** Send notifications via SMS text messages. */\n SMS = 'SMS',\n /** Send notifications via phone calls. */\n PHONE = 'PHONE',\n}\n\n/** @enumType */\nexport type ChannelWithLiterals = Channel | 'UNKNOWN_CHANNEL' | 'SMS' | 'PHONE';\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\nexport interface CreateRecipientRequest {\n /** Recipient to create. */\n recipient: Recipient;\n}\n\nexport interface CreateRecipientResponse {\n /** Created recipient. */\n recipient?: Recipient;\n}\n\nexport interface GetRecipientRequest {\n /**\n * ID of the recipient to retrieve.\n * @format GUID\n */\n recipientId: string;\n}\n\nexport interface GetRecipientResponse {\n /** Retrieved recipient. */\n recipient?: Recipient;\n}\n\nexport interface UpdateRecipientRequest {\n /** Recipient to update. May be partial. */\n recipient: Recipient;\n}\n\nexport interface UpdateRecipientResponse {\n /** Updated recipient. */\n recipient?: Recipient;\n}\n\nexport interface DeleteRecipientRequest {\n /**\n * ID of the recipient to delete.\n * @format GUID\n */\n recipientId: string;\n}\n\nexport interface DeleteRecipientResponse {}\n\nexport interface QueryRecipientsRequest {\n /** WQL expression. */\n query?: CursorQuery;\n}\n\nexport interface CursorQuery extends CursorQueryPagingMethodOneOf {\n /**\n * Cursor paging options.\n *\n * Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging).\n */\n cursorPaging?: CursorPaging;\n /**\n * Filter object.\n *\n * Learn more about the [filter section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section).\n */\n filter?: Record<string, any> | null;\n /**\n * Sort object.\n *\n * Learn more about the [sort section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section).\n * @maxSize 5\n */\n sort?: Sorting[];\n}\n\n/** @oneof */\nexport interface CursorQueryPagingMethodOneOf {\n /**\n * Cursor paging options.\n *\n * Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging).\n */\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 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 QueryRecipientsResponse {\n /** Retrieved recipients. */\n recipients?: Recipient[];\n /** Paging metadata for the query results. */\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 BulkUpdateRecipientTagsRequest {\n /**\n * IDs of recipients to update tags for.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n recipientIds: string[];\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateRecipientTagsResponse {\n /**\n * Results of the bulk update operation.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateRecipientTagsResult[];\n /** Metadata regarding the bulk update operation. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\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 for this item was successful. When `false`, the `error` field is returned. */\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 BulkUpdateRecipientTagsResult {\n /** Metadata regarding the specific single update operation. */\n itemMetadata?: ItemMetadata;\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 BulkUpdateRecipientTagsByFilterRequest {\n /** Filter. */\n filter: Record<string, any> | null;\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateRecipientTagsByFilterResponse {\n /**\n * Job ID.\n * @format GUID\n */\n jobId?: string;\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 BulkUpdateRecipientTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateRecipientTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\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 RecipientCreatedEnvelope {\n entity: Recipient;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @webhook\n * @eventType wix.restaurants.recipient.v1.recipient_created\n * @slug created\n * @documentationMaturity preview\n */\nexport declare function onRecipientCreated(\n handler: (event: RecipientCreatedEnvelope) => void | Promise<void>\n): void;\n\nexport interface RecipientDeletedEnvelope {\n entity: Recipient;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @webhook\n * @eventType wix.restaurants.recipient.v1.recipient_deleted\n * @slug deleted\n * @documentationMaturity preview\n */\nexport declare function onRecipientDeleted(\n handler: (event: RecipientDeletedEnvelope) => void | Promise<void>\n): void;\n\nexport interface RecipientUpdatedEnvelope {\n entity: Recipient;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @webhook\n * @eventType wix.restaurants.recipient.v1.recipient_updated\n * @slug updated\n * @documentationMaturity preview\n */\nexport declare function onRecipientUpdated(\n handler: (event: RecipientUpdatedEnvelope) => void | Promise<void>\n): void;\n\n/**\n * Creates a recipient.\n * @param recipient - Recipient to create.\n * @public\n * @documentationMaturity preview\n * @requiredField recipient\n * @requiredField recipient.channels\n * @permissionId RESTAURANTS.RECIPIENT_CREATE\n * @applicableIdentity APP\n * @returns Created recipient.\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.CreateRecipient\n */\nexport async function createRecipient(\n recipient: NonNullablePaths<Recipient, `channels`, 2>\n): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n recipient: recipient,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.createRecipient(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.recipient!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { recipient: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['recipient']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a recipient by ID.\n * @param recipientId - ID of the recipient to retrieve.\n * @public\n * @documentationMaturity preview\n * @requiredField recipientId\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @applicableIdentity APP\n * @returns Retrieved recipient.\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.GetRecipient\n */\nexport async function getRecipient(\n recipientId: string\n): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n recipientId: recipientId,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.getRecipient(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.recipient!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { recipientId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['recipientId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Updates a recipient's information.\n *\n * Each time the recipient is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the recipient.\n * This ensures you're working with the latest recipient and prevents unintended overwrites.\n * @param _id - Recipient ID.\n * @public\n * @documentationMaturity preview\n * @requiredField _id\n * @requiredField recipient\n * @requiredField recipient.revision\n * @permissionId RESTAURANTS.RECIPIENT_UPDATE\n * @applicableIdentity APP\n * @returns Updated recipient.\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.UpdateRecipient\n */\nexport async function updateRecipient(\n _id: string,\n recipient: NonNullablePaths<UpdateRecipient, `revision`, 2>\n): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\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 recipient: { ...recipient, id: _id },\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.updateRecipient(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.recipient!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: { recipient: '$[1]' },\n explicitPathsToArguments: { 'recipient.id': '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['_id', 'recipient']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface UpdateRecipient {\n /**\n * Recipient ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Revision number, which increments by 1 each time the Recipient is updated.\n * To prevent conflicting changes,\n * the current revision must be passed when updating the Recipient.\n *\n * Ignored when creating a Recipient.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the Recipient was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the Recipient was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Recipient's phone number for receiving notifications.\n * @format PHONE\n */\n phone?: string;\n /**\n * IDs of the business locations this recipient should receive order creation notifications for.\n *\n * If this list is empty the recipient receives notifications for orders created at all locations.\n * @maxSize 100\n * @format GUID\n */\n businessLocationIds?: string[];\n /**\n * Communication channels for sending notifications to the recipient.\n *\n * At least 1 channel is required. Recipients can receive notifications\n * through multiple channels simultaneously.\n * @minSize 1\n * @maxSize 2\n */\n channels?: ChannelWithLiterals[];\n /**\n * Additional information about the recipient.\n *\n * Use this field to store notes about the recipient's role, availability,\n * or other relevant details for notification management.\n * @maxLength 500\n */\n note?: string | null;\n /**\n * Additional custom fields for the recipient.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/api-reference/business-solutions/wix-api/extended-fields).\n */\n extendedFields?: ExtendedFields;\n /**\n * Tags for categorizing and organizing recipients.\n *\n * Use tags to group recipients by role (manager, kitchen staff), shift (morning, evening), or other criteria for targeted notifications.\n */\n tags?: Tags;\n}\n\n/**\n * Deletes a recipient.\n * @param recipientId - ID of the recipient to delete.\n * @public\n * @documentationMaturity preview\n * @requiredField recipientId\n * @permissionId RESTAURANTS.RECIPIENT_DELETE\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.DeleteRecipient\n */\nexport async function deleteRecipient(recipientId: 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 recipientId: recipientId,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.deleteRecipient(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: { recipientId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['recipientId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a list of recipients with optional filtering, sorting, and paging.\n *\n * Up to 100 recipients can be returned per request.\n *\n * For a detailed list of supported operations, see the [Supported Filters and Sorting](https://dev.wix.com/docs/api-reference/business-solutions/restaurants/wix-restaurants-new/online-orders/notification-recipients/supported-filters-and-sorting) article.\n * To learn how to query notification recipients, see [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).\n *\n * Supported properties for filtering and sorting:\n * `id`, `createdDate`, `updatedDate`, `channels`\n * @public\n * @documentationMaturity preview\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.QueryRecipients\n */\nexport function queryRecipients(): RecipientsQueryBuilder {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n return queryBuilder<\n Recipient,\n 'CURSOR',\n QueryRecipientsRequest,\n QueryRecipientsResponse\n >({\n func: async (payload: QueryRecipientsRequest) => {\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.queryRecipients(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: QueryRecipientsRequest['query']) => {\n const args = [query, {}] as [QueryRecipientsRequest['query'], {}];\n return renameKeysFromSDKRequestToRESTRequest({\n ...args?.[1],\n query: args?.[0],\n });\n },\n responseTransformer: ({ data }: HttpResponse<QueryRecipientsResponse>) => {\n const transformedData = renameKeysFromRESTResponseToSDKResponse(\n transformPaths(data, [])\n );\n\n return {\n items: transformedData?.recipients,\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 RecipientsQueryResult extends QueryCursorResult {\n items: Recipient[];\n query: RecipientsQueryBuilder;\n next: () => Promise<RecipientsQueryResult>;\n prev: () => Promise<RecipientsQueryResult>;\n}\n\nexport interface RecipientsQueryBuilder {\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:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any\n ) => RecipientsQueryBuilder;\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:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `string`.\n * @param string - String to compare against. Case-insensitive.\n * @documentationMaturity preview\n */\n startsWith: (propertyName: '_id', value: string) => RecipientsQueryBuilder;\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:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any[]\n ) => RecipientsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `values`.\n * @param values - List of values to compare against.\n * @documentationMaturity preview\n */\n hasAll: (\n propertyName:\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any[]\n ) => RecipientsQueryBuilder;\n /** @documentationMaturity preview */\n in: (\n propertyName:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any\n ) => RecipientsQueryBuilder;\n /** @documentationMaturity preview */\n exists: (\n propertyName:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: boolean\n ) => RecipientsQueryBuilder;\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<\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'channels'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds'\n >\n ) => RecipientsQueryBuilder;\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<\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'channels'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds'\n >\n ) => RecipientsQueryBuilder;\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) => RecipientsQueryBuilder;\n /** @param cursor - A pointer to specific record\n * @documentationMaturity preview\n */\n skipTo: (cursor: string) => RecipientsQueryBuilder;\n /** @documentationMaturity preview */\n find: () => Promise<RecipientsQueryResult>;\n}\n\n/**\n * Updates tags on multiple recipients by recipient IDs.\n *\n * This is a synchronous operation that updates up to 100 recipients at once.\n * If a tag appears in both assign and unassign lists, it will be assigned.\n * @param recipientIds - IDs of recipients to update tags for.\n * @public\n * @documentationMaturity preview\n * @requiredField recipientIds\n * @permissionId RESTAURANTS.RECIPIENT_UPDATE_TAGS\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTags\n */\nexport async function bulkUpdateRecipientTags(\n recipientIds: string[],\n options?: BulkUpdateRecipientTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateRecipientTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateRecipientTagsApplicationErrors;\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 recipientIds: recipientIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.bulkUpdateRecipientTags(\n payload\n );\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 recipientIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['recipientIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateRecipientTagsOptions {\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\n}\n\n/**\n * Updates tags on multiple recipients using filter criteria.\n *\n * This is an asynchronous operation that returns a job ID for tracking progress.\n * An empty filter will update all recipients. If a tag appears in both assign and unassign lists, it will be assigned.\n * @param filter - Filter.\n * @public\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId RESTAURANTS.RECIPIENT_UPDATE_TAGS\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTagsByFilter\n */\nexport async function bulkUpdateRecipientTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateRecipientTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateRecipientTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateRecipientTagsByFilterApplicationErrors;\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 filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.bulkUpdateRecipientTagsByFilter(\n payload\n );\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 filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateRecipientTagsByFilterOptions {\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\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 resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'manage._base_domain_': [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n 'dev._base_domain_': [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/rest-notification-recipients/v1',\n destPath: '/v1',\n },\n {\n srcPath: '/restaurants/recipient/v1/recipients',\n destPath: '/v1/recipients',\n },\n ],\n _: [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_restaurants_recipients';\n\n/** Creates a recipient. */\nexport function createRecipient(payload: object): RequestOptionsFactory<any> {\n function __createRecipient({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'POST' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.CreateRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __createRecipient;\n}\n\n/** Retrieves a recipient by ID. */\nexport function getRecipient(payload: object): RequestOptionsFactory<any> {\n function __getRecipient({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'GET' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.GetRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/{recipientId}',\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: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getRecipient;\n}\n\n/**\n * Updates a recipient's information.\n *\n * Each time the recipient is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the recipient.\n * This ensures you're working with the latest recipient and prevents unintended overwrites.\n */\nexport function updateRecipient(payload: object): RequestOptionsFactory<any> {\n function __updateRecipient({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKFieldMaskToRESTFieldMask,\n paths: [{ path: 'fieldMask' }],\n },\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'PATCH' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.UpdateRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/{recipient.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: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __updateRecipient;\n}\n\n/** Deletes a recipient. */\nexport function deleteRecipient(payload: object): RequestOptionsFactory<any> {\n function __deleteRecipient({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'DELETE' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.DeleteRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/{recipientId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n };\n\n return metadata;\n }\n\n return __deleteRecipient;\n}\n\n/**\n * Retrieves a list of recipients with optional filtering, sorting, and paging.\n *\n * Up to 100 recipients can be returned per request.\n *\n * For a detailed list of supported operations, see the [Supported Filters and Sorting](https://dev.wix.com/docs/api-reference/business-solutions/restaurants/wix-restaurants-new/online-orders/notification-recipients/supported-filters-and-sorting) article.\n * To learn how to query notification recipients, see [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).\n *\n * Supported properties for filtering and sorting:\n * `id`, `createdDate`, `updatedDate`, `channels`\n */\nexport function queryRecipients(payload: object): RequestOptionsFactory<any> {\n function __queryRecipients({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'GET' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.QueryRecipients',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/query',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload, true),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'recipients.createdDate' },\n { path: 'recipients.updatedDate' },\n ],\n },\n ]),\n fallback: [\n {\n method: 'POST' as any,\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl(\n { protoPath: '/v1/recipients/query', data: payload, host }\n ),\n data: payload,\n },\n ],\n };\n\n return metadata;\n }\n\n return __queryRecipients;\n}\n\n/**\n * Updates tags on multiple recipients by recipient IDs.\n *\n * This is a synchronous operation that updates up to 100 recipients at once.\n * If a tag appears in both assign and unassign lists, it will be assigned.\n */\nexport function bulkUpdateRecipientTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateRecipientTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'POST' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/bulk/recipients/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateRecipientTags;\n}\n\n/**\n * Updates tags on multiple recipients using filter criteria.\n *\n * This is an asynchronous operation that returns a job ID for tracking progress.\n * An empty filter will update all recipients. If a tag appears in both assign and unassign lists, it will be assigned.\n */\nexport function bulkUpdateRecipientTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateRecipientTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'POST' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/bulk/recipients/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateRecipientTagsByFilter;\n}\n","import {\n createRecipient as publicCreateRecipient,\n getRecipient as publicGetRecipient,\n updateRecipient as publicUpdateRecipient,\n deleteRecipient as publicDeleteRecipient,\n queryRecipients as publicQueryRecipients,\n bulkUpdateRecipientTags as publicBulkUpdateRecipientTags,\n bulkUpdateRecipientTagsByFilter as publicBulkUpdateRecipientTagsByFilter,\n} from './restaurants-recipient-v1-recipient-recipients.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { createEventModule } from '@wix/sdk-runtime/event-definition-modules';\nimport {\n BuildRESTFunction,\n MaybeContext,\n BuildEventDefinition,\n} from '@wix/sdk-types';\nimport { onRecipientCreated as publicOnRecipientCreated } from './restaurants-recipient-v1-recipient-recipients.public.js';\nimport { onRecipientDeleted as publicOnRecipientDeleted } from './restaurants-recipient-v1-recipient-recipients.public.js';\nimport { onRecipientUpdated as publicOnRecipientUpdated } from './restaurants-recipient-v1-recipient-recipients.public.js';\n\nexport const createRecipient: MaybeContext<\n BuildRESTFunction<typeof publicCreateRecipient> & typeof publicCreateRecipient\n> = /*#__PURE__*/ createRESTModule(publicCreateRecipient);\nexport const getRecipient: MaybeContext<\n BuildRESTFunction<typeof publicGetRecipient> & typeof publicGetRecipient\n> = /*#__PURE__*/ createRESTModule(publicGetRecipient);\nexport const updateRecipient: MaybeContext<\n BuildRESTFunction<typeof publicUpdateRecipient> & typeof publicUpdateRecipient\n> = /*#__PURE__*/ createRESTModule(publicUpdateRecipient);\nexport const deleteRecipient: MaybeContext<\n BuildRESTFunction<typeof publicDeleteRecipient> & typeof publicDeleteRecipient\n> = /*#__PURE__*/ createRESTModule(publicDeleteRecipient);\nexport const queryRecipients: MaybeContext<\n BuildRESTFunction<typeof publicQueryRecipients> & typeof publicQueryRecipients\n> = /*#__PURE__*/ createRESTModule(publicQueryRecipients);\nexport const bulkUpdateRecipientTags: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateRecipientTags> &\n typeof publicBulkUpdateRecipientTags\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateRecipientTags);\nexport const bulkUpdateRecipientTagsByFilter: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateRecipientTagsByFilter> &\n typeof publicBulkUpdateRecipientTagsByFilter\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateRecipientTagsByFilter);\n/** */\nexport const onRecipientCreated: BuildEventDefinition<\n typeof publicOnRecipientCreated\n> &\n typeof publicOnRecipientCreated = createEventModule(publicOnRecipientCreated);\n/** */\nexport const onRecipientDeleted: BuildEventDefinition<\n typeof publicOnRecipientDeleted\n> &\n typeof publicOnRecipientDeleted = createEventModule(publicOnRecipientDeleted);\n/** */\nexport const onRecipientUpdated: BuildEventDefinition<\n typeof publicOnRecipientUpdated\n> &\n typeof publicOnRecipientUpdated = createEventModule(publicOnRecipientUpdated);\n\nexport {\n Channel,\n SortOrder,\n WebhookIdentityType,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\nexport {\n Recipient,\n ExtendedFields,\n Tags,\n TagList,\n CreateRecipientRequest,\n CreateRecipientResponse,\n GetRecipientRequest,\n GetRecipientResponse,\n UpdateRecipientRequest,\n UpdateRecipientResponse,\n DeleteRecipientRequest,\n DeleteRecipientResponse,\n QueryRecipientsRequest,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Sorting,\n CursorPaging,\n QueryRecipientsResponse,\n CursorPagingMetadata,\n Cursors,\n BulkUpdateRecipientTagsRequest,\n BulkUpdateRecipientTagsResponse,\n ItemMetadata,\n ApplicationError,\n BulkUpdateRecipientTagsResult,\n BulkActionMetadata,\n BulkUpdateRecipientTagsByFilterRequest,\n BulkUpdateRecipientTagsByFilterResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n BaseEventMetadata,\n EventMetadata,\n RecipientCreatedEnvelope,\n RecipientDeletedEnvelope,\n RecipientUpdatedEnvelope,\n UpdateRecipient,\n RecipientsQueryResult,\n RecipientsQueryBuilder,\n BulkUpdateRecipientTagsOptions,\n BulkUpdateRecipientTagsByFilterOptions,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\nexport {\n ChannelWithLiterals,\n SortOrderWithLiterals,\n WebhookIdentityTypeWithLiterals,\n BulkUpdateRecipientTagsApplicationErrors,\n BulkUpdateRecipientTagsByFilterApplicationErrors,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\n"],"mappings":";AAAA,SAAS,2CAAAA,gDAA+C;AACxD,SAAS,wCAAAC,6CAA4C;AACrD,SAAS,kBAAAC,uBAAsB;AAC/B,SAAS,uBAAqD;;;ACH9D,SAAS,kBAAkB,yBAAyB;AACpD,SAAS,oBAAoB;AAC7B;AAAA,EACE;AAAA,EACA;AAAA,OACK;;;ACLP,SAAS,yBAAyB;AAClC,SAAS,4CAA4C;AACrD,SAAS,4CAA4C;AACrD,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AA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rB,IAAM,qBAAqB;AAAA,EAChC;AAAA,EACA;AAAA,EACA,CAAC,UACCF;AAAA,IACEC,gBAAe,OAAO;AAAA,MACpB;AAAA,QACE,aAAaC;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,qBAAqB;AAAA,UAC7B,EAAE,MAAM,qBAAqB;AAAA,UAC7B,EAAE,MAAM,qBAAqB;AAAA,QAC/B;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AACJ,EAA4B;;;AG/Q5B,SAAS,wBAAwB;AACjC,SAAS,yBAAyB;AAU3B,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,gBAEK,iCAAiBA,aAAkB;AAC9C,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,2BAGK,iCAAiBA,wBAA6B;AACzD,IAAMC,mCAGK,iCAAiBA,gCAAqC;AAEjE,IAAMC,sBAGuB,kBAAkB,kBAAwB;AAEvE,IAAMC,sBAGuB,kBAAkB,kBAAwB;AAEvE,IAAMC,sBAGuB,kBAAkB,kBAAwB;","names":["renameKeysFromRESTResponseToSDKResponse","transformRESTTimestampToSDKTimestamp","transformPaths","payload","transformPaths","Channel","SortOrder","WebhookIdentityType","createRecipient","getRecipient","updateRecipient","deleteRecipient","queryRecipients","bulkUpdateRecipientTags","bulkUpdateRecipientTagsByFilter","createRecipient","getRecipient","updateRecipient","deleteRecipient","queryRecipients","bulkUpdateRecipientTags","bulkUpdateRecipientTagsByFilter","renameKeysFromRESTResponseToSDKResponse","transformPaths","transformRESTTimestampToSDKTimestamp","createRecipient","getRecipient","updateRecipient","deleteRecipient","queryRecipients","bulkUpdateRecipientTags","bulkUpdateRecipientTagsByFilter","onRecipientCreated","onRecipientDeleted","onRecipientUpdated"]}
|
|
1
|
+
{"version":3,"sources":["../../src/restaurants-recipient-v1-recipient-recipients.public.ts","../../src/restaurants-recipient-v1-recipient-recipients.universal.ts","../../src/restaurants-recipient-v1-recipient-recipients.http.ts","../../src/restaurants-recipient-v1-recipient-recipients.context.ts"],"sourcesContent":["import { renameKeysFromRESTResponseToSDKResponse } from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { EventDefinition, HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n BulkUpdateRecipientTagsApplicationErrors,\n BulkUpdateRecipientTagsByFilterApplicationErrors,\n BulkUpdateRecipientTagsByFilterOptions,\n BulkUpdateRecipientTagsByFilterResponse,\n BulkUpdateRecipientTagsOptions,\n BulkUpdateRecipientTagsResponse,\n Recipient,\n RecipientCreatedEnvelope,\n RecipientDeletedEnvelope,\n RecipientUpdatedEnvelope,\n RecipientsQueryBuilder,\n UpdateRecipient,\n bulkUpdateRecipientTags as universalBulkUpdateRecipientTags,\n bulkUpdateRecipientTagsByFilter as universalBulkUpdateRecipientTagsByFilter,\n createRecipient as universalCreateRecipient,\n deleteRecipient as universalDeleteRecipient,\n getRecipient as universalGetRecipient,\n queryRecipients as universalQueryRecipients,\n updateRecipient as universalUpdateRecipient,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/restaurants' };\n\nexport function createRecipient(\n httpClient: HttpClient\n): CreateRecipientSignature {\n return (recipient: NonNullablePaths<Recipient, `channels`, 2>) =>\n universalCreateRecipient(\n recipient,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface CreateRecipientSignature {\n /**\n * Creates a recipient.\n * @param - Recipient to create.\n * @returns Created recipient.\n */\n (recipient: NonNullablePaths<Recipient, `channels`, 2>): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\nexport function getRecipient(httpClient: HttpClient): GetRecipientSignature {\n return (recipientId: string) =>\n universalGetRecipient(\n recipientId,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetRecipientSignature {\n /**\n * Retrieves a recipient by ID.\n * @param - ID of the recipient to retrieve.\n * @returns Retrieved recipient.\n */\n (recipientId: string): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\nexport function updateRecipient(\n httpClient: HttpClient\n): UpdateRecipientSignature {\n return (\n _id: string,\n recipient: NonNullablePaths<UpdateRecipient, `revision`, 2>\n ) =>\n universalUpdateRecipient(\n _id,\n recipient,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface UpdateRecipientSignature {\n /**\n * Updates a recipient's information.\n *\n * Each time the recipient is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the recipient.\n * This ensures you're working with the latest recipient and prevents unintended overwrites.\n * @param - Recipient ID.\n * @returns Updated recipient.\n */\n (\n _id: string,\n recipient: NonNullablePaths<UpdateRecipient, `revision`, 2>\n ): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\nexport function deleteRecipient(\n httpClient: HttpClient\n): DeleteRecipientSignature {\n return (recipientId: string) =>\n universalDeleteRecipient(\n recipientId,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface DeleteRecipientSignature {\n /**\n * Deletes a recipient.\n * @param - ID of the recipient to delete.\n */\n (recipientId: string): Promise<void>;\n}\n\nexport function queryRecipients(\n httpClient: HttpClient\n): QueryRecipientsSignature {\n return () =>\n universalQueryRecipients(\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface QueryRecipientsSignature {\n /**\n * Retrieves a list of recipients with optional filtering, sorting, and paging.\n *\n * Up to 100 recipients can be returned per request.\n *\n * For a detailed list of supported operations, see the [Supported Filters and Sorting](https://dev.wix.com/docs/api-reference/business-solutions/restaurants/wix-restaurants-new/online-orders/notification-recipients/supported-filters-and-sorting) article.\n * To learn how to query notification recipients, see [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).\n *\n * Supported properties for filtering and sorting:\n * `id`, `createdDate`, `updatedDate`, `channels`\n */\n (): RecipientsQueryBuilder;\n}\n\nexport function bulkUpdateRecipientTags(\n httpClient: HttpClient\n): BulkUpdateRecipientTagsSignature {\n return (recipientIds: string[], options?: BulkUpdateRecipientTagsOptions) =>\n universalBulkUpdateRecipientTags(\n recipientIds,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateRecipientTagsSignature {\n /**\n * Updates tags on multiple recipients by recipient IDs.\n *\n * This is a synchronous operation that updates up to 100 recipients at once.\n * If a tag appears in both assign and unassign lists, it will be assigned.\n * @param - IDs of recipients to update tags for.\n */\n (recipientIds: string[], options?: BulkUpdateRecipientTagsOptions): Promise<\n NonNullablePaths<\n BulkUpdateRecipientTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateRecipientTagsApplicationErrors;\n }\n >;\n}\n\nexport function bulkUpdateRecipientTagsByFilter(\n httpClient: HttpClient\n): BulkUpdateRecipientTagsByFilterSignature {\n return (\n filter: Record<string, any>,\n options?: BulkUpdateRecipientTagsByFilterOptions\n ) =>\n universalBulkUpdateRecipientTagsByFilter(\n filter,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateRecipientTagsByFilterSignature {\n /**\n * Updates tags on multiple recipients using filter criteria.\n *\n * This is an asynchronous operation that returns a job ID for tracking progress.\n * An empty filter will update all recipients. If a tag appears in both assign and unassign lists, it will be assigned.\n * @param - Filter.\n */\n (\n filter: Record<string, any>,\n options?: BulkUpdateRecipientTagsByFilterOptions\n ): Promise<\n NonNullablePaths<BulkUpdateRecipientTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateRecipientTagsByFilterApplicationErrors;\n }\n >;\n}\n\nexport const onRecipientCreated = EventDefinition(\n 'wix.restaurants.recipient.v1.recipient_created',\n true,\n (event: RecipientCreatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'metadata.eventTime' },\n ],\n },\n ])\n )\n)<RecipientCreatedEnvelope>();\nexport const onRecipientDeleted = EventDefinition(\n 'wix.restaurants.recipient.v1.recipient_deleted',\n true,\n (event: RecipientDeletedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'metadata.eventTime' },\n ],\n },\n ])\n )\n)<RecipientDeletedEnvelope>();\nexport const onRecipientUpdated = EventDefinition(\n 'wix.restaurants.recipient.v1.recipient_updated',\n true,\n (event: RecipientUpdatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'metadata.eventTime' },\n ],\n },\n ])\n )\n)<RecipientUpdatedEnvelope>();\n\nexport {\n ActionEvent,\n ApplicationError,\n BaseEventMetadata,\n BulkActionMetadata,\n BulkUpdateRecipientTagsByFilterOptions,\n BulkUpdateRecipientTagsByFilterRequest,\n BulkUpdateRecipientTagsByFilterResponse,\n BulkUpdateRecipientTagsOptions,\n BulkUpdateRecipientTagsRequest,\n BulkUpdateRecipientTagsResponse,\n BulkUpdateRecipientTagsResult,\n Channel,\n CreateRecipientRequest,\n CreateRecipientResponse,\n CursorPaging,\n CursorPagingMetadata,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Cursors,\n DeleteRecipientRequest,\n DeleteRecipientResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n EventMetadata,\n ExtendedFields,\n GetRecipientRequest,\n GetRecipientResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemMetadata,\n MessageEnvelope,\n QueryRecipientsRequest,\n QueryRecipientsResponse,\n Recipient,\n RecipientCreatedEnvelope,\n RecipientDeletedEnvelope,\n RecipientUpdatedEnvelope,\n RecipientsQueryBuilder,\n RecipientsQueryResult,\n RestoreInfo,\n SortOrder,\n Sorting,\n TagList,\n Tags,\n UpdateRecipient,\n UpdateRecipientRequest,\n UpdateRecipientResponse,\n WebhookIdentityType,\n} from './restaurants-recipient-v1-recipient-recipients.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 ambassadorWixRestaurantsRecipientV1Recipient from './restaurants-recipient-v1-recipient-recipients.http.js';\n// @ts-ignore\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\n\nexport interface Recipient {\n /**\n * Recipient ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Revision number, which increments by 1 each time the Recipient is updated.\n * To prevent conflicting changes,\n * the current revision must be passed when updating the Recipient.\n *\n * Ignored when creating a Recipient.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the Recipient was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the Recipient was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Recipient's phone number for receiving notifications.\n * @format PHONE\n */\n phone?: string;\n /**\n * IDs of the business locations this recipient should receive order creation notifications for.\n *\n * If this list is empty the recipient receives notifications for orders created at all locations.\n * @maxSize 100\n * @format GUID\n */\n businessLocationIds?: string[];\n /**\n * Communication channels for sending notifications to the recipient.\n *\n * At least 1 channel is required. Recipients can receive notifications\n * through multiple channels simultaneously.\n * @minSize 1\n * @maxSize 2\n */\n channels?: ChannelWithLiterals[];\n /**\n * Additional information about the recipient.\n *\n * Use this field to store notes about the recipient's role, availability,\n * or other relevant details for notification management.\n * @maxLength 500\n */\n note?: string | null;\n /** Additional custom fields for the recipient. */\n extendedFields?: ExtendedFields;\n /**\n * Tags for categorizing and organizing recipients.\n *\n * Use tags to group recipients by role (manager, kitchen staff), shift (morning, evening), or other criteria for targeted notifications.\n */\n tags?: Tags;\n}\n\nexport enum Channel {\n UNKNOWN_CHANNEL = 'UNKNOWN_CHANNEL',\n /** Send notifications via SMS text messages. */\n SMS = 'SMS',\n /** Send notifications via phone calls. */\n PHONE = 'PHONE',\n}\n\n/** @enumType */\nexport type ChannelWithLiterals = Channel | 'UNKNOWN_CHANNEL' | 'SMS' | 'PHONE';\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\nexport interface CreateRecipientRequest {\n /** Recipient to create. */\n recipient: Recipient;\n}\n\nexport interface CreateRecipientResponse {\n /** Created recipient. */\n recipient?: Recipient;\n}\n\nexport interface GetRecipientRequest {\n /**\n * ID of the recipient to retrieve.\n * @format GUID\n */\n recipientId: string;\n}\n\nexport interface GetRecipientResponse {\n /** Retrieved recipient. */\n recipient?: Recipient;\n}\n\nexport interface UpdateRecipientRequest {\n /** Recipient to update. May be partial. */\n recipient: Recipient;\n}\n\nexport interface UpdateRecipientResponse {\n /** Updated recipient. */\n recipient?: Recipient;\n}\n\nexport interface DeleteRecipientRequest {\n /**\n * ID of the recipient to delete.\n * @format GUID\n */\n recipientId: string;\n}\n\nexport interface DeleteRecipientResponse {}\n\nexport interface QueryRecipientsRequest {\n /** WQL expression. */\n query?: CursorQuery;\n}\n\nexport interface CursorQuery extends CursorQueryPagingMethodOneOf {\n /**\n * Cursor paging options.\n *\n * Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging).\n */\n cursorPaging?: CursorPaging;\n /**\n * Filter object.\n *\n * Learn more about the [filter section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section).\n */\n filter?: Record<string, any> | null;\n /**\n * Sort object.\n *\n * Learn more about the [sort section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section).\n * @maxSize 5\n */\n sort?: Sorting[];\n}\n\n/** @oneof */\nexport interface CursorQueryPagingMethodOneOf {\n /**\n * Cursor paging options.\n *\n * Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging).\n */\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 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 QueryRecipientsResponse {\n /** Retrieved recipients. */\n recipients?: Recipient[];\n /** Paging metadata for the query results. */\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 BulkUpdateRecipientTagsRequest {\n /**\n * IDs of recipients to update tags for.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n recipientIds: string[];\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateRecipientTagsResponse {\n /**\n * Results of the bulk update operation.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateRecipientTagsResult[];\n /** Metadata regarding the bulk update operation. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\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 for this item was successful. When `false`, the `error` field is returned. */\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 BulkUpdateRecipientTagsResult {\n /** Metadata regarding the specific single update operation. */\n itemMetadata?: ItemMetadata;\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 BulkUpdateRecipientTagsByFilterRequest {\n /** Filter. */\n filter: Record<string, any> | null;\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateRecipientTagsByFilterResponse {\n /**\n * Job ID.\n * @format GUID\n */\n jobId?: string;\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 BulkUpdateRecipientTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateRecipientTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\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 RecipientCreatedEnvelope {\n entity: Recipient;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @webhook\n * @eventType wix.restaurants.recipient.v1.recipient_created\n * @slug created\n * @documentationMaturity preview\n */\nexport declare function onRecipientCreated(\n handler: (event: RecipientCreatedEnvelope) => void | Promise<void>\n): void;\n\nexport interface RecipientDeletedEnvelope {\n entity: Recipient;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @webhook\n * @eventType wix.restaurants.recipient.v1.recipient_deleted\n * @slug deleted\n * @documentationMaturity preview\n */\nexport declare function onRecipientDeleted(\n handler: (event: RecipientDeletedEnvelope) => void | Promise<void>\n): void;\n\nexport interface RecipientUpdatedEnvelope {\n entity: Recipient;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @webhook\n * @eventType wix.restaurants.recipient.v1.recipient_updated\n * @slug updated\n * @documentationMaturity preview\n */\nexport declare function onRecipientUpdated(\n handler: (event: RecipientUpdatedEnvelope) => void | Promise<void>\n): void;\n\n/**\n * Creates a recipient.\n * @param recipient - Recipient to create.\n * @public\n * @documentationMaturity preview\n * @requiredField recipient\n * @requiredField recipient.channels\n * @permissionId RESTAURANTS.RECIPIENT_CREATE\n * @applicableIdentity APP\n * @returns Created recipient.\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.CreateRecipient\n */\nexport async function createRecipient(\n recipient: NonNullablePaths<Recipient, `channels`, 2>\n): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n recipient: recipient,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.createRecipient(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.recipient!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { recipient: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['recipient']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a recipient by ID.\n * @param recipientId - ID of the recipient to retrieve.\n * @public\n * @documentationMaturity preview\n * @requiredField recipientId\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @applicableIdentity APP\n * @returns Retrieved recipient.\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.GetRecipient\n */\nexport async function getRecipient(\n recipientId: string\n): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n recipientId: recipientId,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.getRecipient(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.recipient!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { recipientId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['recipientId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Updates a recipient's information.\n *\n * Each time the recipient is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the recipient.\n * This ensures you're working with the latest recipient and prevents unintended overwrites.\n * @param _id - Recipient ID.\n * @public\n * @documentationMaturity preview\n * @requiredField _id\n * @requiredField recipient\n * @requiredField recipient.revision\n * @permissionId RESTAURANTS.RECIPIENT_UPDATE\n * @applicableIdentity APP\n * @returns Updated recipient.\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.UpdateRecipient\n */\nexport async function updateRecipient(\n _id: string,\n recipient: NonNullablePaths<UpdateRecipient, `revision`, 2>\n): Promise<\n NonNullablePaths<\n Recipient,\n `phone` | `businessLocationIds` | `channels` | `tags.privateTags.tagIds`,\n 4\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 recipient: { ...recipient, id: _id },\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.updateRecipient(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)?.recipient!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: { recipient: '$[1]' },\n explicitPathsToArguments: { 'recipient.id': '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['_id', 'recipient']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface UpdateRecipient {\n /**\n * Recipient ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Revision number, which increments by 1 each time the Recipient is updated.\n * To prevent conflicting changes,\n * the current revision must be passed when updating the Recipient.\n *\n * Ignored when creating a Recipient.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the Recipient was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the Recipient was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Recipient's phone number for receiving notifications.\n * @format PHONE\n */\n phone?: string;\n /**\n * IDs of the business locations this recipient should receive order creation notifications for.\n *\n * If this list is empty the recipient receives notifications for orders created at all locations.\n * @maxSize 100\n * @format GUID\n */\n businessLocationIds?: string[];\n /**\n * Communication channels for sending notifications to the recipient.\n *\n * At least 1 channel is required. Recipients can receive notifications\n * through multiple channels simultaneously.\n * @minSize 1\n * @maxSize 2\n */\n channels?: ChannelWithLiterals[];\n /**\n * Additional information about the recipient.\n *\n * Use this field to store notes about the recipient's role, availability,\n * or other relevant details for notification management.\n * @maxLength 500\n */\n note?: string | null;\n /** Additional custom fields for the recipient. */\n extendedFields?: ExtendedFields;\n /**\n * Tags for categorizing and organizing recipients.\n *\n * Use tags to group recipients by role (manager, kitchen staff), shift (morning, evening), or other criteria for targeted notifications.\n */\n tags?: Tags;\n}\n\n/**\n * Deletes a recipient.\n * @param recipientId - ID of the recipient to delete.\n * @public\n * @documentationMaturity preview\n * @requiredField recipientId\n * @permissionId RESTAURANTS.RECIPIENT_DELETE\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.DeleteRecipient\n */\nexport async function deleteRecipient(recipientId: 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 recipientId: recipientId,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.deleteRecipient(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: { recipientId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['recipientId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a list of recipients with optional filtering, sorting, and paging.\n *\n * Up to 100 recipients can be returned per request.\n *\n * For a detailed list of supported operations, see the [Supported Filters and Sorting](https://dev.wix.com/docs/api-reference/business-solutions/restaurants/wix-restaurants-new/online-orders/notification-recipients/supported-filters-and-sorting) article.\n * To learn how to query notification recipients, see [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).\n *\n * Supported properties for filtering and sorting:\n * `id`, `createdDate`, `updatedDate`, `channels`\n * @public\n * @documentationMaturity preview\n * @permissionId RESTAURANTS.RECIPIENT_READ\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.QueryRecipients\n */\nexport function queryRecipients(): RecipientsQueryBuilder {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n return queryBuilder<\n Recipient,\n 'CURSOR',\n QueryRecipientsRequest,\n QueryRecipientsResponse\n >({\n func: async (payload: QueryRecipientsRequest) => {\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.queryRecipients(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: QueryRecipientsRequest['query']) => {\n const args = [query, {}] as [QueryRecipientsRequest['query'], {}];\n return renameKeysFromSDKRequestToRESTRequest({\n ...args?.[1],\n query: args?.[0],\n });\n },\n responseTransformer: ({ data }: HttpResponse<QueryRecipientsResponse>) => {\n const transformedData = renameKeysFromRESTResponseToSDKResponse(\n transformPaths(data, [])\n );\n\n return {\n items: transformedData?.recipients,\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 RecipientsQueryResult extends QueryCursorResult {\n items: Recipient[];\n query: RecipientsQueryBuilder;\n next: () => Promise<RecipientsQueryResult>;\n prev: () => Promise<RecipientsQueryResult>;\n}\n\nexport interface RecipientsQueryBuilder {\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:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any\n ) => RecipientsQueryBuilder;\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:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\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: '_id' | '_createdDate' | '_updatedDate',\n value: any\n ) => RecipientsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `string`.\n * @param string - String to compare against. Case-insensitive.\n * @documentationMaturity preview\n */\n startsWith: (propertyName: '_id', value: string) => RecipientsQueryBuilder;\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:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any[]\n ) => RecipientsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `values`.\n * @param values - List of values to compare against.\n * @documentationMaturity preview\n */\n hasAll: (\n propertyName:\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any[]\n ) => RecipientsQueryBuilder;\n /** @documentationMaturity preview */\n in: (\n propertyName:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: any\n ) => RecipientsQueryBuilder;\n /** @documentationMaturity preview */\n exists: (\n propertyName:\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds',\n value: boolean\n ) => RecipientsQueryBuilder;\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<\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'channels'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds'\n >\n ) => RecipientsQueryBuilder;\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<\n | '_id'\n | '_createdDate'\n | '_updatedDate'\n | 'businessLocationIds'\n | 'channels'\n | 'tags.privateTags.tagIds'\n | 'tags.publicTags.tagIds'\n >\n ) => RecipientsQueryBuilder;\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) => RecipientsQueryBuilder;\n /** @param cursor - A pointer to specific record\n * @documentationMaturity preview\n */\n skipTo: (cursor: string) => RecipientsQueryBuilder;\n /** @documentationMaturity preview */\n find: () => Promise<RecipientsQueryResult>;\n}\n\n/**\n * Updates tags on multiple recipients by recipient IDs.\n *\n * This is a synchronous operation that updates up to 100 recipients at once.\n * If a tag appears in both assign and unassign lists, it will be assigned.\n * @param recipientIds - IDs of recipients to update tags for.\n * @public\n * @documentationMaturity preview\n * @requiredField recipientIds\n * @permissionId RESTAURANTS.RECIPIENT_UPDATE_TAGS\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTags\n */\nexport async function bulkUpdateRecipientTags(\n recipientIds: string[],\n options?: BulkUpdateRecipientTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateRecipientTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateRecipientTagsApplicationErrors;\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 recipientIds: recipientIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.bulkUpdateRecipientTags(\n payload\n );\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 recipientIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['recipientIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateRecipientTagsOptions {\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\n}\n\n/**\n * Updates tags on multiple recipients using filter criteria.\n *\n * This is an asynchronous operation that returns a job ID for tracking progress.\n * An empty filter will update all recipients. If a tag appears in both assign and unassign lists, it will be assigned.\n * @param filter - Filter.\n * @public\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId RESTAURANTS.RECIPIENT_UPDATE_TAGS\n * @applicableIdentity APP\n * @fqn wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTagsByFilter\n */\nexport async function bulkUpdateRecipientTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateRecipientTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateRecipientTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateRecipientTagsByFilterApplicationErrors;\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 filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixRestaurantsRecipientV1Recipient.bulkUpdateRecipientTagsByFilter(\n payload\n );\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 filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateRecipientTagsByFilterOptions {\n /** List of Tags to assign. */\n assignTags?: Tags;\n /** List of Tags to unassign. */\n unassignTags?: Tags;\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 resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'manage._base_domain_': [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n 'dev._base_domain_': [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/rest-notification-recipients/v1',\n destPath: '/v1',\n },\n {\n srcPath: '/restaurants/recipient/v1/recipients',\n destPath: '/v1/recipients',\n },\n ],\n _: [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/_api/rest-notification-recipients',\n destPath: '',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_restaurants_recipients';\n\n/** Creates a recipient. */\nexport function createRecipient(payload: object): RequestOptionsFactory<any> {\n function __createRecipient({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'POST' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.CreateRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __createRecipient;\n}\n\n/** Retrieves a recipient by ID. */\nexport function getRecipient(payload: object): RequestOptionsFactory<any> {\n function __getRecipient({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'GET' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.GetRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/{recipientId}',\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: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getRecipient;\n}\n\n/**\n * Updates a recipient's information.\n *\n * Each time the recipient is updated, `revision` increments by 1.\n * The current `revision` must be passed when updating the recipient.\n * This ensures you're working with the latest recipient and prevents unintended overwrites.\n */\nexport function updateRecipient(payload: object): RequestOptionsFactory<any> {\n function __updateRecipient({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKFieldMaskToRESTFieldMask,\n paths: [{ path: 'fieldMask' }],\n },\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n { path: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'PATCH' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.UpdateRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/{recipient.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: 'recipient.createdDate' },\n { path: 'recipient.updatedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __updateRecipient;\n}\n\n/** Deletes a recipient. */\nexport function deleteRecipient(payload: object): RequestOptionsFactory<any> {\n function __deleteRecipient({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'DELETE' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.DeleteRecipient',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/{recipientId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n };\n\n return metadata;\n }\n\n return __deleteRecipient;\n}\n\n/**\n * Retrieves a list of recipients with optional filtering, sorting, and paging.\n *\n * Up to 100 recipients can be returned per request.\n *\n * For a detailed list of supported operations, see the [Supported Filters and Sorting](https://dev.wix.com/docs/api-reference/business-solutions/restaurants/wix-restaurants-new/online-orders/notification-recipients/supported-filters-and-sorting) article.\n * To learn how to query notification recipients, see [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).\n *\n * Supported properties for filtering and sorting:\n * `id`, `createdDate`, `updatedDate`, `channels`\n */\nexport function queryRecipients(payload: object): RequestOptionsFactory<any> {\n function __queryRecipients({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'GET' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.QueryRecipients',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/recipients/query',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload, true),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'recipients.createdDate' },\n { path: 'recipients.updatedDate' },\n ],\n },\n ]),\n fallback: [\n {\n method: 'POST' as any,\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl(\n { protoPath: '/v1/recipients/query', data: payload, host }\n ),\n data: payload,\n },\n ],\n };\n\n return metadata;\n }\n\n return __queryRecipients;\n}\n\n/**\n * Updates tags on multiple recipients by recipient IDs.\n *\n * This is a synchronous operation that updates up to 100 recipients at once.\n * If a tag appears in both assign and unassign lists, it will be assigned.\n */\nexport function bulkUpdateRecipientTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateRecipientTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'POST' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/bulk/recipients/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateRecipientTags;\n}\n\n/**\n * Updates tags on multiple recipients using filter criteria.\n *\n * This is an asynchronous operation that returns a job ID for tracking progress.\n * An empty filter will update all recipients. If a tag appears in both assign and unassign lists, it will be assigned.\n */\nexport function bulkUpdateRecipientTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateRecipientTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.restaurants.recipient.v1.recipient',\n method: 'POST' as any,\n methodFqn:\n 'wix.restaurants.recipient.v1.NotificationRecipientsService.BulkUpdateRecipientTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixRestaurantsRecipientV1NotificationRecipientsServiceUrl({\n protoPath: '/v1/bulk/recipients/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateRecipientTagsByFilter;\n}\n","import {\n createRecipient as publicCreateRecipient,\n getRecipient as publicGetRecipient,\n updateRecipient as publicUpdateRecipient,\n deleteRecipient as publicDeleteRecipient,\n queryRecipients as publicQueryRecipients,\n bulkUpdateRecipientTags as publicBulkUpdateRecipientTags,\n bulkUpdateRecipientTagsByFilter as publicBulkUpdateRecipientTagsByFilter,\n} from './restaurants-recipient-v1-recipient-recipients.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { createEventModule } from '@wix/sdk-runtime/event-definition-modules';\nimport {\n BuildRESTFunction,\n MaybeContext,\n BuildEventDefinition,\n} from '@wix/sdk-types';\nimport { onRecipientCreated as publicOnRecipientCreated } from './restaurants-recipient-v1-recipient-recipients.public.js';\nimport { onRecipientDeleted as publicOnRecipientDeleted } from './restaurants-recipient-v1-recipient-recipients.public.js';\nimport { onRecipientUpdated as publicOnRecipientUpdated } from './restaurants-recipient-v1-recipient-recipients.public.js';\n\nexport const createRecipient: MaybeContext<\n BuildRESTFunction<typeof publicCreateRecipient> & typeof publicCreateRecipient\n> = /*#__PURE__*/ createRESTModule(publicCreateRecipient);\nexport const getRecipient: MaybeContext<\n BuildRESTFunction<typeof publicGetRecipient> & typeof publicGetRecipient\n> = /*#__PURE__*/ createRESTModule(publicGetRecipient);\nexport const updateRecipient: MaybeContext<\n BuildRESTFunction<typeof publicUpdateRecipient> & typeof publicUpdateRecipient\n> = /*#__PURE__*/ createRESTModule(publicUpdateRecipient);\nexport const deleteRecipient: MaybeContext<\n BuildRESTFunction<typeof publicDeleteRecipient> & typeof publicDeleteRecipient\n> = /*#__PURE__*/ createRESTModule(publicDeleteRecipient);\nexport const queryRecipients: MaybeContext<\n BuildRESTFunction<typeof publicQueryRecipients> & typeof publicQueryRecipients\n> = /*#__PURE__*/ createRESTModule(publicQueryRecipients);\nexport const bulkUpdateRecipientTags: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateRecipientTags> &\n typeof publicBulkUpdateRecipientTags\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateRecipientTags);\nexport const bulkUpdateRecipientTagsByFilter: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateRecipientTagsByFilter> &\n typeof publicBulkUpdateRecipientTagsByFilter\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateRecipientTagsByFilter);\n/** */\nexport const onRecipientCreated: BuildEventDefinition<\n typeof publicOnRecipientCreated\n> &\n typeof publicOnRecipientCreated = createEventModule(publicOnRecipientCreated);\n/** */\nexport const onRecipientDeleted: BuildEventDefinition<\n typeof publicOnRecipientDeleted\n> &\n typeof publicOnRecipientDeleted = createEventModule(publicOnRecipientDeleted);\n/** */\nexport const onRecipientUpdated: BuildEventDefinition<\n typeof publicOnRecipientUpdated\n> &\n typeof publicOnRecipientUpdated = createEventModule(publicOnRecipientUpdated);\n\nexport {\n Channel,\n SortOrder,\n WebhookIdentityType,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\nexport {\n Recipient,\n ExtendedFields,\n Tags,\n TagList,\n CreateRecipientRequest,\n CreateRecipientResponse,\n GetRecipientRequest,\n GetRecipientResponse,\n UpdateRecipientRequest,\n UpdateRecipientResponse,\n DeleteRecipientRequest,\n DeleteRecipientResponse,\n QueryRecipientsRequest,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Sorting,\n CursorPaging,\n QueryRecipientsResponse,\n CursorPagingMetadata,\n Cursors,\n BulkUpdateRecipientTagsRequest,\n BulkUpdateRecipientTagsResponse,\n ItemMetadata,\n ApplicationError,\n BulkUpdateRecipientTagsResult,\n BulkActionMetadata,\n BulkUpdateRecipientTagsByFilterRequest,\n BulkUpdateRecipientTagsByFilterResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n BaseEventMetadata,\n EventMetadata,\n RecipientCreatedEnvelope,\n RecipientDeletedEnvelope,\n RecipientUpdatedEnvelope,\n UpdateRecipient,\n RecipientsQueryResult,\n RecipientsQueryBuilder,\n BulkUpdateRecipientTagsOptions,\n BulkUpdateRecipientTagsByFilterOptions,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\nexport {\n ChannelWithLiterals,\n SortOrderWithLiterals,\n WebhookIdentityTypeWithLiterals,\n BulkUpdateRecipientTagsApplicationErrors,\n BulkUpdateRecipientTagsByFilterApplicationErrors,\n} from './restaurants-recipient-v1-recipient-recipients.universal.js';\n"],"mappings":";AAAA,SAAS,2CAAAA,gDAA+C;AACxD,SAAS,wCAAAC,6CAA4C;AACrD,SAAS,kBAAAC,uBAAsB;AAC/B,SAAS,uBAAqD;;;ACH9D,SAAS,kBAAkB,yBAAyB;AACpD,SAAS,oBAAoB;AAC7B;AAAA,EACE;AAAA,EACA;AAAA,OACK;;;ACLP,SAAS,yBAAyB;AAClC,SAAS,4CAA4C;AACrD,SAAS,4CAA4C;AACrD,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAI3B,SAAS,iEACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,qBAAqB;AAAA,MACnB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,mBAAmB;AAAA,MACjB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,MACA;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,sBAAsB;AAAA,MACpB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA,SAAO,WAAW,OAAO,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC7D;AAEA,IAAM,eAAe;AAGd,SAAS,gBAAgB,SAA6C;AAC3E,WAAS,kBAAkB,EAAE,KAAK,GAAQ;AACxC,UAAM,iBAAiB,eAAe,SAAS;AAAA,MAC7C;AAAA,QACE,aAAa;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,wBAAwB;AAAA,UAChC,EAAE,M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AA,UAC7B,EAAE,MAAM,qBAAqB;AAAA,QAC/B;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AACJ,EAA4B;AACrB,IAAM,qBAAqB;AAAA,EAChC;AAAA,EACA;AAAA,EACA,CAAC,UACCF;AAAA,IACEC,gBAAe,OAAO;AAAA,MACpB;AAAA,QACE,aAAaC;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,qBAAqB;AAAA,UAC7B,EAAE,MAAM,qBAAqB;AAAA,UAC7B,EAAE,MAAM,qBAAqB;AAAA,QAC/B;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AACJ,EAA4B;AACrB,IAAM,qBAAqB;AAAA,EAChC;AAAA,EACA;AAAA,EACA,CAAC,UACCF;AAAA,IACEC,gBAAe,OAAO;AAAA,MACpB;AAAA,QACE,aAAaC;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,qBAAqB;AAAA,UAC7B,EAAE,MAAM,qBAAqB;AAAA,UAC7B,EAAE,MAAM,qBAAqB;AAAA,QAC/B;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AACJ,EAA4B;;;AG/Q5B,SAAS,wBAAwB;AACjC,SAAS,yBAAyB;AAU3B,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,gBAEK,iCAAiBA,aAAkB;AAC9C,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,2BAGK,iCAAiBA,wBAA6B;AACzD,IAAMC,mCAGK,iCAAiBA,gCAAqC;AAEjE,IAAMC,sBAGuB,kBAAkB,kBAAwB;AAEvE,IAAMC,sBAGuB,kBAAkB,kBAAwB;AAEvE,IAAMC,sBAGuB,kBAAkB,kBAAwB;","names":["renameKeysFromRESTResponseToSDKResponse","transformRESTTimestampToSDKTimestamp","transformPaths","payload","transformPaths","Channel","SortOrder","WebhookIdentityType","createRecipient","getRecipient","updateRecipient","deleteRecipient","queryRecipients","bulkUpdateRecipientTags","bulkUpdateRecipientTagsByFilter","createRecipient","getRecipient","updateRecipient","deleteRecipient","queryRecipients","bulkUpdateRecipientTags","bulkUpdateRecipientTagsByFilter","renameKeysFromRESTResponseToSDKResponse","transformPaths","transformRESTTimestampToSDKTimestamp","createRecipient","getRecipient","updateRecipient","deleteRecipient","queryRecipients","bulkUpdateRecipientTags","bulkUpdateRecipientTagsByFilter","onRecipientCreated","onRecipientDeleted","onRecipientUpdated"]}
|
|
@@ -56,11 +56,7 @@ interface Recipient {
|
|
|
56
56
|
* @maxLength 500
|
|
57
57
|
*/
|
|
58
58
|
note?: string | null;
|
|
59
|
-
/**
|
|
60
|
-
* Additional custom fields for the recipient.
|
|
61
|
-
*
|
|
62
|
-
* Learn more about [extended fields](https://dev.wix.com/docs/api-reference/business-solutions/wix-api/extended-fields).
|
|
63
|
-
*/
|
|
59
|
+
/** Additional custom fields for the recipient. */
|
|
64
60
|
extendedFields?: ExtendedFields;
|
|
65
61
|
/**
|
|
66
62
|
* Tags for categorizing and organizing recipients.
|
|
@@ -656,11 +652,7 @@ interface UpdateRecipient {
|
|
|
656
652
|
* @maxLength 500
|
|
657
653
|
*/
|
|
658
654
|
note?: string | null;
|
|
659
|
-
/**
|
|
660
|
-
* Additional custom fields for the recipient.
|
|
661
|
-
*
|
|
662
|
-
* Learn more about [extended fields](https://dev.wix.com/docs/api-reference/business-solutions/wix-api/extended-fields).
|
|
663
|
-
*/
|
|
655
|
+
/** Additional custom fields for the recipient. */
|
|
664
656
|
extendedFields?: ExtendedFields;
|
|
665
657
|
/**
|
|
666
658
|
* Tags for categorizing and organizing recipients.
|