@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
  /**
@@ -2101,6 +2101,8 @@ interface ContactCreatedEnvelope {
2101
2101
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2102
2102
  * @permissionScope Read Members and Contacts - all read permissions
2103
2103
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2104
+ * @permissionScope Manage Restaurants - all permissions
2105
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2104
2106
  * @permissionScope Manage Contacts
2105
2107
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2106
2108
  * @permissionScope Set Up Automations
@@ -2132,6 +2134,8 @@ interface ContactDeletedEnvelope {
2132
2134
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2133
2135
  * @permissionScope Read Members and Contacts - all read permissions
2134
2136
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2137
+ * @permissionScope Manage Restaurants - all permissions
2138
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2135
2139
  * @permissionScope Manage Contacts
2136
2140
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2137
2141
  * @permissionScope Set Up Automations
@@ -2161,6 +2165,8 @@ interface ContactMergedEnvelope {
2161
2165
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2162
2166
  * @permissionScope Read Members and Contacts - all read permissions
2163
2167
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2168
+ * @permissionScope Manage Restaurants - all permissions
2169
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2164
2170
  * @permissionScope Manage Contacts
2165
2171
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2166
2172
  * @permissionScope Set Up Automations
@@ -2190,6 +2196,8 @@ interface ContactUpdatedEnvelope {
2190
2196
  * @permissionScopeId SCOPE.DC-CONTACTS.READ-CONTACTS
2191
2197
  * @permissionScope Read Members and Contacts - all read permissions
2192
2198
  * @permissionScopeId SCOPE.DC-CONTACTS-MEGA.READ-MEMBERS-CONTACTS
2199
+ * @permissionScope Manage Restaurants - all permissions
2200
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2193
2201
  * @permissionScope Manage Contacts
2194
2202
  * @permissionScopeId SCOPE.DC-CONTACTS.MANAGE-CONTACTS
2195
2203
  * @permissionScope Set Up Automations
@@ -2574,9 +2582,105 @@ interface ContactsQueryBuilder {
2574
2582
  * @requiredField query
2575
2583
  * @returns List of contacts.
2576
2584
  */
2577
- 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> & {
2585
+ 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> & {
2578
2586
  __applicationErrorsType?: QueryContactsApplicationErrors;
2579
2587
  }>;
2588
+ interface ContactQuerySpec extends QuerySpec {
2589
+ paging: 'offset';
2590
+ wql: [
2591
+ {
2592
+ fields: ['_id', 'info.locale'];
2593
+ operators: ['$eq', '$exists', '$in', '$ne'];
2594
+ sort: 'NONE';
2595
+ },
2596
+ {
2597
+ fields: ['_createdDate', 'info.birthdate', 'lastActivity.activityDate'];
2598
+ operators: ['$eq', '$gt', '$gte', '$lt', '$lte', '$ne'];
2599
+ sort: 'BOTH';
2600
+ },
2601
+ {
2602
+ fields: ['_updatedDate'];
2603
+ operators: ['$eq', '$gt', '$gte', '$lt', '$lte', '$ne'];
2604
+ sort: 'NONE';
2605
+ },
2606
+ {
2607
+ fields: [
2608
+ 'info.company',
2609
+ 'info.jobTitle',
2610
+ 'info.name.first',
2611
+ 'info.name.last',
2612
+ 'primaryInfo.email'
2613
+ ];
2614
+ operators: ['$begins', '$eq', '$exists', '$in', '$ne'];
2615
+ sort: 'BOTH';
2616
+ },
2617
+ {
2618
+ fields: ['primaryInfo.phone'];
2619
+ operators: ['$begins', '$eq', '$exists', '$in', '$ne'];
2620
+ sort: 'NONE';
2621
+ },
2622
+ {
2623
+ fields: ['info.labelKeys'];
2624
+ operators: ['$hasAll', '$hasSome'];
2625
+ sort: 'NONE';
2626
+ }
2627
+ ];
2628
+ }
2629
+ type CommonQueryWithEntityContext = Query$1<Contact, ContactQuerySpec>;
2630
+ type ContactQuery = {
2631
+ /**
2632
+ Filter object.
2633
+ See [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language)
2634
+ for more information.
2635
+
2636
+ For a detailed list of supported filters, see
2637
+ [Supported Filters](https://dev.wix.com/api/rest/contacts/contacts/supported-filters).
2638
+ */
2639
+ filter?: CommonQueryWithEntityContext['filter'] | null;
2640
+ /**
2641
+ Sorting options.
2642
+ See [Sorting and Paging](https://dev.wix.com/api/rest/getting-started/pagination)
2643
+ for more information.
2644
+
2645
+ Max: 1 sort object
2646
+ @maxSize: 1
2647
+ */
2648
+ sort?: {
2649
+ /**
2650
+ Field to sort by.
2651
+
2652
+ Supported properties:
2653
+ `createdDate`, `lastActivity.activityDate`, `primaryInfo.email`, `info.name.first`, `info.name.last`, `info.company`,
2654
+ `info.jobTitle`, `info.birthdate`
2655
+ @maxLength: 100
2656
+ */
2657
+ fieldName?: NonNullable<CommonQueryWithEntityContext['sort']>[number]['fieldName'];
2658
+ /**
2659
+ Sort order.
2660
+ Use `ASC` for ascending order or `DESC` for descending order.
2661
+
2662
+ Defaults to `ASC`.
2663
+ */
2664
+ order?: NonNullable<CommonQueryWithEntityContext['sort']>[number]['order'];
2665
+ }[];
2666
+ /**
2667
+ Pagination options.
2668
+ */
2669
+ paging?: {
2670
+ /**
2671
+ 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).
2672
+
2673
+ Default: `50`. <br>
2674
+ Maximum: `1000`.
2675
+ @max: 1000
2676
+ */
2677
+ limit?: NonNullable<CommonQueryWithEntityContext['paging']>['limit'] | null;
2678
+ /**
2679
+ Number of items to skip in the current sort order.
2680
+ */
2681
+ offset?: NonNullable<CommonQueryWithEntityContext['paging']>['offset'] | null;
2682
+ };
2683
+ };
2580
2684
  /**
2581
2685
  * Lists facets from the site’s contact list.
2582
2686
  * Facets include labels and subscription statuses.
@@ -2839,4 +2943,4 @@ interface GetContactOptions {
2839
2943
  fieldsets?: ContactFieldSetWithLiterals[];
2840
2944
  }
2841
2945
 
2842
- 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 };
2946
+ 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 };