@wix/auto_sdk_crm_contacts 1.0.1035 → 1.0.1036

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.
@@ -1,4 +1,4 @@
1
- import { NonNullablePaths } from '@wix/sdk-types';
1
+ import { QuerySpec, Query as Query$1, NonNullablePaths } from '@wix/sdk-types';
2
2
 
3
3
  interface Contact {
4
4
  /**
@@ -2095,6 +2095,8 @@ interface ContactCreatedEnvelope {
2095
2095
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2096
2096
  * @permissionScope Read Members and Contacts - all read permissions
2097
2097
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2098
+ * @permissionScope Manage Restaurants - all permissions
2099
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2098
2100
  * @permissionScope Manage Contacts
2099
2101
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2100
2102
  * @permissionScope Set Up Automations
@@ -2126,6 +2128,8 @@ interface ContactDeletedEnvelope {
2126
2128
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2127
2129
  * @permissionScope Read Members and Contacts - all read permissions
2128
2130
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2131
+ * @permissionScope Manage Restaurants - all permissions
2132
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2129
2133
  * @permissionScope Manage Contacts
2130
2134
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2131
2135
  * @permissionScope Set Up Automations
@@ -2155,6 +2159,8 @@ interface ContactMergedEnvelope {
2155
2159
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2156
2160
  * @permissionScope Read Members and Contacts - all read permissions
2157
2161
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2162
+ * @permissionScope Manage Restaurants - all permissions
2163
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2158
2164
  * @permissionScope Manage Contacts
2159
2165
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2160
2166
  * @permissionScope Set Up Automations
@@ -2184,6 +2190,8 @@ interface ContactUpdatedEnvelope {
2184
2190
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2185
2191
  * @permissionScope Read Members and Contacts - all read permissions
2186
2192
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2193
+ * @permissionScope Manage Restaurants - all permissions
2194
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2187
2195
  * @permissionScope Manage Contacts
2188
2196
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2189
2197
  * @permissionScope Set Up Automations
@@ -2563,9 +2571,105 @@ interface ContactsQueryBuilder {
2563
2571
  * @requiredField query
2564
2572
  * @returns List of contacts.
2565
2573
  */
2566
- declare function typedQueryContacts(query: Query, options?: QueryContactsOptions): Promise<NonNullablePaths<QueryContactsResponse, `contacts` | `contacts.${number}._id` | `contacts.${number}.revision` | `contacts.${number}.source.sourceType` | `contacts.${number}.lastActivity.activityType` | `contacts.${number}.primaryEmail.subscriptionStatus` | `contacts.${number}.primaryEmail.deliverabilityStatus` | `contacts.${number}.primaryPhone.subscriptionStatus`, 5> & {
2574
+ declare function typedQueryContacts(query: ContactQuery, options?: QueryContactsOptions): Promise<NonNullablePaths<QueryContactsResponse, `contacts` | `contacts.${number}._id` | `contacts.${number}.revision` | `contacts.${number}.source.sourceType` | `contacts.${number}.lastActivity.activityType` | `contacts.${number}.primaryEmail.subscriptionStatus` | `contacts.${number}.primaryEmail.deliverabilityStatus` | `contacts.${number}.primaryPhone.subscriptionStatus`, 5> & {
2567
2575
  __applicationErrorsType?: QueryContactsApplicationErrors;
2568
2576
  }>;
2577
+ interface ContactQuerySpec extends QuerySpec {
2578
+ paging: 'offset';
2579
+ wql: [
2580
+ {
2581
+ fields: ['_id', 'info.locale'];
2582
+ operators: ['$eq', '$exists', '$in', '$ne'];
2583
+ sort: 'NONE';
2584
+ },
2585
+ {
2586
+ fields: ['_createdDate', 'info.birthdate', 'lastActivity.activityDate'];
2587
+ operators: ['$eq', '$gt', '$gte', '$lt', '$lte', '$ne'];
2588
+ sort: 'BOTH';
2589
+ },
2590
+ {
2591
+ fields: ['_updatedDate'];
2592
+ operators: ['$eq', '$gt', '$gte', '$lt', '$lte', '$ne'];
2593
+ sort: 'NONE';
2594
+ },
2595
+ {
2596
+ fields: [
2597
+ 'info.company',
2598
+ 'info.jobTitle',
2599
+ 'info.name.first',
2600
+ 'info.name.last',
2601
+ 'primaryInfo.email'
2602
+ ];
2603
+ operators: ['$begins', '$eq', '$exists', '$in', '$ne'];
2604
+ sort: 'BOTH';
2605
+ },
2606
+ {
2607
+ fields: ['primaryInfo.phone'];
2608
+ operators: ['$begins', '$eq', '$exists', '$in', '$ne'];
2609
+ sort: 'NONE';
2610
+ },
2611
+ {
2612
+ fields: ['info.labelKeys'];
2613
+ operators: ['$hasAll', '$hasSome'];
2614
+ sort: 'NONE';
2615
+ }
2616
+ ];
2617
+ }
2618
+ type CommonQueryWithEntityContext = Query$1<Contact, ContactQuerySpec>;
2619
+ type ContactQuery = {
2620
+ /**
2621
+ Filter object.
2622
+ See [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language)
2623
+ for more information.
2624
+
2625
+ For a detailed list of supported filters, see
2626
+ [Supported Filters](https://dev.wix.com/api/rest/contacts/contacts/supported-filters).
2627
+ */
2628
+ filter?: CommonQueryWithEntityContext['filter'] | null;
2629
+ /**
2630
+ Sorting options.
2631
+ See [Sorting and Paging](https://dev.wix.com/api/rest/getting-started/pagination)
2632
+ for more information.
2633
+
2634
+ Max: 1 sort object
2635
+ @maxSize: 1
2636
+ */
2637
+ sort?: {
2638
+ /**
2639
+ Field to sort by.
2640
+
2641
+ Supported properties:
2642
+ `createdDate`, `lastActivity.activityDate`, `primaryInfo.email`, `info.name.first`, `info.name.last`, `info.company`,
2643
+ `info.jobTitle`, `info.birthdate`
2644
+ @maxLength: 100
2645
+ */
2646
+ fieldName?: NonNullable<CommonQueryWithEntityContext['sort']>[number]['fieldName'];
2647
+ /**
2648
+ Sort order.
2649
+ Use `ASC` for ascending order or `DESC` for descending order.
2650
+
2651
+ Defaults to `ASC`.
2652
+ */
2653
+ order?: NonNullable<CommonQueryWithEntityContext['sort']>[number]['order'];
2654
+ }[];
2655
+ /**
2656
+ Pagination options.
2657
+ */
2658
+ paging?: {
2659
+ /**
2660
+ Number of items to return. Learn more about pagination in [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#paging).
2661
+
2662
+ Default: `50`. <br>
2663
+ Maximum: `1000`.
2664
+ @max: 1000
2665
+ */
2666
+ limit?: NonNullable<CommonQueryWithEntityContext['paging']>['limit'] | null;
2667
+ /**
2668
+ Number of items to skip in the current sort order.
2669
+ */
2670
+ offset?: NonNullable<CommonQueryWithEntityContext['paging']>['offset'] | null;
2671
+ };
2672
+ };
2569
2673
  /**
2570
2674
  * Lists facets from the site’s contact list.
2571
2675
  * Facets include labels and subscription statuses.
@@ -2828,4 +2932,4 @@ interface GetContactOptions {
2828
2932
  fieldsets?: ContactFieldSetWithLiterals[];
2829
2933
  }
2830
2934
 
2831
- export { Action, type ActionEvent, type ActionWithLiterals, type ActivityIcon, type Address, type AddressLocation, type AddressStreetOneOf, AddressTag, type AddressTagWithLiterals, type ApplicationError, type AssigneesWrapper, type BaseEventMetadata, type BulkActionMetadata, type BulkAddSegmentToContactsRequest, type BulkAddSegmentToContactsResponse, type BulkDeleteContactsApplicationErrors, type BulkDeleteContactsOptions, type BulkDeleteContactsRequest, type BulkDeleteContactsResponse, type BulkLabelAndUnlabelContactsApplicationErrors, type BulkLabelAndUnlabelContactsOptions, type BulkLabelAndUnlabelContactsRequest, type BulkLabelAndUnlabelContactsResponse, type BulkRemoveSegmentFromContactsRequest, type BulkRemoveSegmentFromContactsResponse, type BulkUpdateContactsOptions, type BulkUpdateContactsRequest, type BulkUpdateContactsResponse, type BulkUpsertContactsRequest, type BulkUpsertContactsResponse, type BulkUpsertContactsResponseMetadata, type Contact, type ContactActivity, ContactActivityType, type ContactActivityTypeWithLiterals, type ContactAddedToSegment, type ContactAddress, type ContactAddressesWrapper, type ContactChanged, type ContactCreatedEnvelope, type ContactDeletedEnvelope, type ContactEmail, type ContactEmailSubscriptionUpdated, type ContactEmailsWrapper, ContactFieldSet, type ContactFieldSetWithLiterals, type ContactInfo, type ContactMerged, type ContactMergedEnvelope, type ContactName, type ContactPhone, type ContactPhoneSubscriptionUpdated, type ContactPhonesWrapper, type ContactPicture, type ContactPrimaryInfoUpdated, type ContactRemovedFromSegment, type ContactSource, ContactSourceType, type ContactSourceTypeWithLiterals, type ContactSubmitted, type ContactUpdatedEnvelope, type ContactsFacet, ContactsFacetType, type ContactsFacetTypeWithLiterals, type ContactsQueryBuilder, type ContactsQueryResult, type CountContactsRequest, type CountContactsResponse, type CreateContactApplicationErrors, type CreateContactOptions, type CreateContactRequest, type CreateContactResponse, type CursorPaging, type CursorPagingMetadata, type Cursors, type DeleteContactApplicationErrors, type DeleteContactRequest, type DeleteContactResponse, type DomainEvent, type DomainEventBodyOneOf, type DuplicateContactExists, EmailDeliverabilityStatus, type EmailDeliverabilityStatusWithLiterals, EmailTag, type EmailTagWithLiterals, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type Error, type EventMetadata, type ExtendedFieldsWrapper, type GeneratePictureUploadUrlRequest, type GeneratePictureUploadUrlResponse, type GetContactApplicationErrors, type GetContactOptions, type GetContactRequest, type GetContactResponse, GetContactResponseType, type GetContactResponseTypeWithLiterals, type GroupInfo, type IdentificationData, type IdentificationDataIdOneOf, ImageProvider, type ImageProviderWithLiterals, type Item, type ItemMetadata, type LabelAndUnlabelContactRequest, type LabelAndUnlabelContactResponse, type LabelContactApplicationErrors, type LabelContactRequest, type LabelContactResponse, type LabelsWrapper, type LastActivityUpdate, type ListContactIdsBySegmentRequest, type ListContactIdsBySegmentResponse, type ListContactsApplicationErrors, type ListContactsOptions, type ListContactsRequest, type ListContactsResponse, type ListFacetsOptions, type ListFacetsRequest, type ListFacetsResponse, type LocationsWrapper, type MemberInfo, MemberStatus, type MemberStatusWithLiterals, type MergeContactsApplicationErrors, type MergeContactsOptions, type MergeContactsRequest, type MergeContactsResponse, type MessageEnvelope, type Metadata, Mode, type ModeWithLiterals, type Paging, type PagingMetadata, PhoneDeliverabilityStatus, type PhoneDeliverabilityStatusWithLiterals, PhoneTag, type PhoneTagWithLiterals, type PreviewMergeContactsApplicationErrors, type PreviewMergeContactsOptions, type PreviewMergeContactsRequest, type PreviewMergeContactsResponse, type PrimaryContactInfo, type PrimaryEmail, type PrimaryPhone, type PrimarySubscriptionStatus, PrivacyStatus, type PrivacyStatusWithLiterals, type ProfileInfo, type Query, type QueryContactsApplicationErrors, type QueryContactsOptions, type QueryContactsRequest, type QueryContactsResponse, type QueryFacetsOptions, type QueryFacetsRequest, type QueryFacetsResponse, type RestoreInfo, Role, type RoleWithLiterals, type Search, type SearchContactsRequest, type SearchContactsResponse, type SearchDetails, type SearchPagingMethodOneOf, type SegmentsWrapper, type SessionInfo, SortOrder, type SortOrderWithLiterals, type Sorting, type StreetAddress, type Subdivision, SubdivisionType, type SubdivisionTypeWithLiterals, SubmitOperation, type SubmitOperationWithLiterals, SubscriptionStatus, type SubscriptionStatusWithLiterals, type SyncSubmitContactRequest, type SyncSubmitContactResponse, type UnlabelContactApplicationErrors, type UnlabelContactRequest, type UnlabelContactResponse, type UpdateContactApplicationErrors, type UpdateContactOptions, type UpdateContactRequest, type UpdateContactResponse, type UpsertContactRequest, type UpsertContactResponse, UpsertContactResponseAction, type UpsertContactResponseActionWithLiterals, type UserInfo, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, bulkDeleteContacts, bulkLabelAndUnlabelContacts, bulkUpdateContacts, createContact, deleteContact, getContact, labelContact, listContacts, listFacets, mergeContacts, onContactCreated, onContactDeleted, onContactMerged, onContactUpdated, previewMergeContacts, queryContacts, queryFacets, typedQueryContacts, unlabelContact, updateContact };
2935
+ export { Action, type ActionEvent, type ActionWithLiterals, type ActivityIcon, type Address, type AddressLocation, type AddressStreetOneOf, AddressTag, type AddressTagWithLiterals, type ApplicationError, type AssigneesWrapper, type BaseEventMetadata, type BulkActionMetadata, type BulkAddSegmentToContactsRequest, type BulkAddSegmentToContactsResponse, type BulkDeleteContactsApplicationErrors, type BulkDeleteContactsOptions, type BulkDeleteContactsRequest, type BulkDeleteContactsResponse, type BulkLabelAndUnlabelContactsApplicationErrors, type BulkLabelAndUnlabelContactsOptions, type BulkLabelAndUnlabelContactsRequest, type BulkLabelAndUnlabelContactsResponse, type BulkRemoveSegmentFromContactsRequest, type BulkRemoveSegmentFromContactsResponse, type BulkUpdateContactsOptions, type BulkUpdateContactsRequest, type BulkUpdateContactsResponse, type BulkUpsertContactsRequest, type BulkUpsertContactsResponse, type BulkUpsertContactsResponseMetadata, type CommonQueryWithEntityContext, type Contact, type ContactActivity, ContactActivityType, type ContactActivityTypeWithLiterals, type ContactAddedToSegment, type ContactAddress, type ContactAddressesWrapper, type ContactChanged, type ContactCreatedEnvelope, type ContactDeletedEnvelope, type ContactEmail, type ContactEmailSubscriptionUpdated, type ContactEmailsWrapper, ContactFieldSet, type ContactFieldSetWithLiterals, type ContactInfo, type ContactMerged, type ContactMergedEnvelope, type ContactName, type ContactPhone, type ContactPhoneSubscriptionUpdated, type ContactPhonesWrapper, type ContactPicture, type ContactPrimaryInfoUpdated, type ContactQuery, type ContactQuerySpec, type ContactRemovedFromSegment, type ContactSource, ContactSourceType, type ContactSourceTypeWithLiterals, type ContactSubmitted, type ContactUpdatedEnvelope, type ContactsFacet, ContactsFacetType, type ContactsFacetTypeWithLiterals, type ContactsQueryBuilder, type ContactsQueryResult, type CountContactsRequest, type CountContactsResponse, type CreateContactApplicationErrors, type CreateContactOptions, type CreateContactRequest, type CreateContactResponse, type CursorPaging, type CursorPagingMetadata, type Cursors, type DeleteContactApplicationErrors, type DeleteContactRequest, type DeleteContactResponse, type DomainEvent, type DomainEventBodyOneOf, type DuplicateContactExists, EmailDeliverabilityStatus, type EmailDeliverabilityStatusWithLiterals, EmailTag, type EmailTagWithLiterals, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type Error, type EventMetadata, type ExtendedFieldsWrapper, type GeneratePictureUploadUrlRequest, type GeneratePictureUploadUrlResponse, type GetContactApplicationErrors, type GetContactOptions, type GetContactRequest, type GetContactResponse, GetContactResponseType, type GetContactResponseTypeWithLiterals, type GroupInfo, type IdentificationData, type IdentificationDataIdOneOf, ImageProvider, type ImageProviderWithLiterals, type Item, type ItemMetadata, type LabelAndUnlabelContactRequest, type LabelAndUnlabelContactResponse, type LabelContactApplicationErrors, type LabelContactRequest, type LabelContactResponse, type LabelsWrapper, type LastActivityUpdate, type ListContactIdsBySegmentRequest, type ListContactIdsBySegmentResponse, type ListContactsApplicationErrors, type ListContactsOptions, type ListContactsRequest, type ListContactsResponse, type ListFacetsOptions, type ListFacetsRequest, type ListFacetsResponse, type LocationsWrapper, type MemberInfo, MemberStatus, type MemberStatusWithLiterals, type MergeContactsApplicationErrors, type MergeContactsOptions, type MergeContactsRequest, type MergeContactsResponse, type MessageEnvelope, type Metadata, Mode, type ModeWithLiterals, type Paging, type PagingMetadata, PhoneDeliverabilityStatus, type PhoneDeliverabilityStatusWithLiterals, PhoneTag, type PhoneTagWithLiterals, type PreviewMergeContactsApplicationErrors, type PreviewMergeContactsOptions, type PreviewMergeContactsRequest, type PreviewMergeContactsResponse, type PrimaryContactInfo, type PrimaryEmail, type PrimaryPhone, type PrimarySubscriptionStatus, PrivacyStatus, type PrivacyStatusWithLiterals, type ProfileInfo, type Query, type QueryContactsApplicationErrors, type QueryContactsOptions, type QueryContactsRequest, type QueryContactsResponse, type QueryFacetsOptions, type QueryFacetsRequest, type QueryFacetsResponse, type RestoreInfo, Role, type RoleWithLiterals, type Search, type SearchContactsRequest, type SearchContactsResponse, type SearchDetails, type SearchPagingMethodOneOf, type SegmentsWrapper, type SessionInfo, SortOrder, type SortOrderWithLiterals, type Sorting, type StreetAddress, type Subdivision, SubdivisionType, type SubdivisionTypeWithLiterals, SubmitOperation, type SubmitOperationWithLiterals, SubscriptionStatus, type SubscriptionStatusWithLiterals, type SyncSubmitContactRequest, type SyncSubmitContactResponse, type UnlabelContactApplicationErrors, type UnlabelContactRequest, type UnlabelContactResponse, type UpdateContactApplicationErrors, type UpdateContactOptions, type UpdateContactRequest, type UpdateContactResponse, type UpsertContactRequest, type UpsertContactResponse, UpsertContactResponseAction, type UpsertContactResponseActionWithLiterals, type UserInfo, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, bulkDeleteContacts, bulkLabelAndUnlabelContacts, bulkUpdateContacts, createContact, deleteContact, getContact, labelContact, listContacts, listFacets, mergeContacts, onContactCreated, onContactDeleted, onContactMerged, onContactUpdated, previewMergeContacts, queryContacts, queryFacets, typedQueryContacts, unlabelContact, updateContact };