declare module "wix-dashboard-management.v2" { /** List of favorite dashboard pages. */ interface DashboardFavoriteList { /** * Dashboard favorite list ID. Automatically generated by Wix. * @readonly */ _id?: string | null; /** * Revision number. Increments automatically by 1 whenever the list is successfully updated. To prevent conflicting changes, pass the current revision number when updating the list. * @readonly */ revision?: string | null; /** * Date and time the dashboard favorite list was created. * @readonly */ _createdDate?: Date | null; /** * Date and time the dashboard favorite list was last updated. * @readonly */ _updatedDate?: Date | null; /** List of favorite dashboard pages. */ favorites?: Favorite[]; } interface Favorite { /** Favorite ID. Automatically generated by Wix. */ _id?: string | null; /** ID of the page added to the list. */ pageId?: string; /** Relative URL appended to the page's URL for customizing the navigation. It can include path segments, a query string, or a fragment identifier. */ relativeUrl?: string | null; /** Custom title displayed in the list of favorite pages. */ title?: string | null; } interface CreateUserFavoriteListRequest { /** Dashboard favorite list to create. */ favoriteList: DashboardFavoriteList; } interface CreateUserFavoriteListResponse { /** Created dashboard favorite list. */ favoriteList?: DashboardFavoriteList; } interface GetUserFavoriteListRequest { } interface GetUserFavoriteListResponse { /** Wix user's dashboard favorite list. */ favoriteList?: DashboardFavoriteList; } interface UpdateUserFavoriteListRequest { /** * Dashboard favorite list to update. The `favorites` array in the request replaces the existing `favorites` array. * * To prevent conflicting changes, include the current revision number. */ favoriteList: DashboardFavoriteList; /** * Fields to update. Only fields specified in `fieldMask.paths` are updated. * @internal */ fieldMask?: string[]; } interface UpdateUserFavoriteListResponse { /** Updated dashboard favorite list. */ favoriteList?: DashboardFavoriteList; } interface DeleteUserFavoriteListRequest { /** ID of the dashboard favorite list to delete. */ favoriteListId: string; } interface DeleteUserFavoriteListResponse { } interface AddUserFavoriteRequest { /** Favorite page to add to the list. */ favorite: Favorite; } interface AddUserFavoriteResponse { /** Updated dashboard favorite list. */ favoriteList?: DashboardFavoriteList; } interface DeleteUserFavoriteRequest { /** ID of the favorite page to delete from the list. */ favoriteId: string; } interface DeleteUserFavoriteResponse { /** Updated dashboard favorite list. */ favoriteList?: DashboardFavoriteList; } interface DomainEvent extends DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; /** * Unique event ID. * Allows clients to ignore duplicate webhooks. */ _id?: string; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** ID of the entity associated with the event. */ entityId?: string; /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */ eventTime?: Date | null; /** * Whether the event was triggered as a result of a privacy regulation application * (for example, GDPR). */ triggeredByAnonymizeRequest?: boolean | null; /** If present, indicates the action that triggered the event. */ originatedFrom?: string | null; /** * A sequence number defining the order of updates to the underlying entity. * For example, given that some entity was updated at 16:00 and than again at 16:01, * it is guaranteed that the sequence number of the second update is strictly higher than the first. * As the consumer, you can use this value to ensure that you handle messages in the correct order. * To do so, you will need to persist this number on your end, and compare the sequence number from the * message against the one you have stored. Given that the stored number is higher, you should ignore the message. */ entityEventSequence?: string | null; } /** @oneof */ interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; } interface EntityCreatedEvent { entityAsJson?: string; /** * Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity * @internal */ triggeredByUndelete?: boolean | null; /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */ restoreInfo?: RestoreInfo; /** * WIP * @internal */ additionalMetadataAsJson?: string | null; } interface RestoreInfo { deletedDate?: Date | null; } interface EntityUpdatedEvent { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; /** * This field is currently part of the of the EntityUpdatedEvent msg, but scala/node libraries which implements the domain events standard * wont populate it / have any reference to it in the API. * The main reason for it is that fetching the old entity from the DB will have a performance hit on an update operation so unless truly needed, * the developer should send only the new (current) entity. * An additional reason is not wanting to send this additional entity over the wire (kafka) since in some cases it can be really big * Developers that must reflect the old entity will have to implement their own domain event sender mechanism which will follow the DomainEvent proto message. * @internal * @deprecated */ previousEntityAsJson?: string | null; /** * WIP - This property will hold both names and previous values of the updated fields of the entity. * For more details please see [adr](https://docs.google.com/document/d/1PdqsOM20Ph2HAkmx8zvUnzzk3Sekp3BR9h34wSvsRnI/edit#heading=h.phlw87mh2imx) or [issue](https://github.com/wix-private/nile-tracker/issues/363) * @internal */ modifiedFields?: Record; /** * WIP * @internal */ additionalMetadataAsJson?: string | null; } interface EntityDeletedEvent { /** * Indicates if the entity is sent to trash-bin. only available when trash-bin is enabled * @internal */ movedToTrash?: boolean | null; /** Entity that was deleted */ deletedEntityAsJson?: string | null; /** * WIP * @internal */ additionalMetadataAsJson?: string | null; } interface ActionEvent { bodyAsJson?: string; } interface MessageEnvelope { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; } interface IdentificationData extends IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; /** @readonly */ identityType?: WebhookIdentityType; } /** @oneof */ interface IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; } enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } /** * Creates a list of favorite dashboard pages for the current Wix user. A Wix user can only have one such list. * * > **Note:** * > When first calling this method on behalf of a Wix user, you can create a list that contains one or more favorite dashboard pages. However, if a list already exists for that Wix user, calling this method generates an error. * @param favoriteList - Dashboard favorite list to create. * @public * @documentationMaturity preview * @requiredField favoriteList * @requiredField favoriteList.favorites * @permissionId DASHBOARD.FAVORITES_WRITE * @adminMethod * @returns Created dashboard favorite list. */ function createUserFavoriteList(favoriteList: DashboardFavoriteList): Promise; /** * Retrieves the Wix user's dashboard favorite list. * @public * @documentationMaturity preview * @permissionId DASHBOARD.FAVORITES_READ * @adminMethod */ function getUserFavoriteList(): Promise; /** * Updates the current Wix user's list of favorite dashboard pages. * * Make sure to include the current revision number when calling this method. * * > **Note:** * > Updating the list replaces the favorite pages it contains with those specified in the method. * @param _id - Dashboard favorite list ID. Automatically generated by Wix. * @public * @documentationMaturity preview * @requiredField _id * @requiredField favoriteList * @requiredField favoriteList.revision * @permissionId DASHBOARD.FAVORITES_WRITE * @adminMethod * @returns Updated dashboard favorite list. */ function updateUserFavoriteList(_id: string | null, favoriteList: UpdateUserFavoriteList, options?: UpdateUserFavoriteListOptions): Promise; interface UpdateUserFavoriteList { /** * Dashboard favorite list ID. Automatically generated by Wix. * @readonly */ _id?: string | null; /** * Revision number. Increments automatically by 1 whenever the list is successfully updated. To prevent conflicting changes, pass the current revision number when updating the list. * @readonly */ revision?: string | null; /** * Date and time the dashboard favorite list was created. * @readonly */ _createdDate?: Date | null; /** * Date and time the dashboard favorite list was last updated. * @readonly */ _updatedDate?: Date | null; /** List of favorite dashboard pages. */ favorites?: Favorite[]; } interface UpdateUserFavoriteListOptions { /** * Fields to update. Only fields specified in `fieldMask.paths` are updated. * @internal */ fieldMask?: string[]; } /** * Deletes the Wix user's list of favorite dashboard pages. * @param favoriteListId - ID of the dashboard favorite list to delete. * @public * @documentationMaturity preview * @requiredField favoriteListId * @permissionId DASHBOARD.FAVORITES_WRITE * @adminMethod */ function deleteUserFavoriteList(favoriteListId: string): Promise; /** * Adds a page to the current Wix user's list of favorite dashboard pages. If the Wix user doesn't have a list, the method creates a new list and adds the favorite page to it. * @param favorite - Favorite page to add to the list. * @public * @documentationMaturity preview * @requiredField favorite * @permissionId DASHBOARD.FAVORITES_WRITE * @adminMethod */ function addUserFavorite(favorite: Favorite): Promise; /** * Deletes the specified favorite page from the current Wix user's list of favorite dashboard pages. If no favorites remain in the list, it is deleted. * @param favoriteId - ID of the favorite page to delete from the list. * @public * @documentationMaturity preview * @requiredField favoriteId * @permissionId DASHBOARD.FAVORITES_WRITE * @adminMethod */ function deleteUserFavorite(favoriteId: string): Promise; type dashboardV1FavoriteList_universal_d_DashboardFavoriteList = DashboardFavoriteList; type dashboardV1FavoriteList_universal_d_Favorite = Favorite; type dashboardV1FavoriteList_universal_d_CreateUserFavoriteListRequest = CreateUserFavoriteListRequest; type dashboardV1FavoriteList_universal_d_CreateUserFavoriteListResponse = CreateUserFavoriteListResponse; type dashboardV1FavoriteList_universal_d_GetUserFavoriteListRequest = GetUserFavoriteListRequest; type dashboardV1FavoriteList_universal_d_GetUserFavoriteListResponse = GetUserFavoriteListResponse; type dashboardV1FavoriteList_universal_d_UpdateUserFavoriteListRequest = UpdateUserFavoriteListRequest; type dashboardV1FavoriteList_universal_d_UpdateUserFavoriteListResponse = UpdateUserFavoriteListResponse; type dashboardV1FavoriteList_universal_d_DeleteUserFavoriteListRequest = DeleteUserFavoriteListRequest; type dashboardV1FavoriteList_universal_d_DeleteUserFavoriteListResponse = DeleteUserFavoriteListResponse; type dashboardV1FavoriteList_universal_d_AddUserFavoriteRequest = AddUserFavoriteRequest; type dashboardV1FavoriteList_universal_d_AddUserFavoriteResponse = AddUserFavoriteResponse; type dashboardV1FavoriteList_universal_d_DeleteUserFavoriteRequest = DeleteUserFavoriteRequest; type dashboardV1FavoriteList_universal_d_DeleteUserFavoriteResponse = DeleteUserFavoriteResponse; type dashboardV1FavoriteList_universal_d_DomainEvent = DomainEvent; type dashboardV1FavoriteList_universal_d_DomainEventBodyOneOf = DomainEventBodyOneOf; type dashboardV1FavoriteList_universal_d_EntityCreatedEvent = EntityCreatedEvent; type dashboardV1FavoriteList_universal_d_RestoreInfo = RestoreInfo; type dashboardV1FavoriteList_universal_d_EntityUpdatedEvent = EntityUpdatedEvent; type dashboardV1FavoriteList_universal_d_EntityDeletedEvent = EntityDeletedEvent; type dashboardV1FavoriteList_universal_d_ActionEvent = ActionEvent; type dashboardV1FavoriteList_universal_d_MessageEnvelope = MessageEnvelope; type dashboardV1FavoriteList_universal_d_IdentificationData = IdentificationData; type dashboardV1FavoriteList_universal_d_IdentificationDataIdOneOf = IdentificationDataIdOneOf; type dashboardV1FavoriteList_universal_d_WebhookIdentityType = WebhookIdentityType; const dashboardV1FavoriteList_universal_d_WebhookIdentityType: typeof WebhookIdentityType; const dashboardV1FavoriteList_universal_d_createUserFavoriteList: typeof createUserFavoriteList; const dashboardV1FavoriteList_universal_d_getUserFavoriteList: typeof getUserFavoriteList; const dashboardV1FavoriteList_universal_d_updateUserFavoriteList: typeof updateUserFavoriteList; type dashboardV1FavoriteList_universal_d_UpdateUserFavoriteList = UpdateUserFavoriteList; type dashboardV1FavoriteList_universal_d_UpdateUserFavoriteListOptions = UpdateUserFavoriteListOptions; const dashboardV1FavoriteList_universal_d_deleteUserFavoriteList: typeof deleteUserFavoriteList; const dashboardV1FavoriteList_universal_d_addUserFavorite: typeof addUserFavorite; const dashboardV1FavoriteList_universal_d_deleteUserFavorite: typeof deleteUserFavorite; namespace dashboardV1FavoriteList_universal_d { export { dashboardV1FavoriteList_universal_d_DashboardFavoriteList as DashboardFavoriteList, dashboardV1FavoriteList_universal_d_Favorite as Favorite, dashboardV1FavoriteList_universal_d_CreateUserFavoriteListRequest as CreateUserFavoriteListRequest, dashboardV1FavoriteList_universal_d_CreateUserFavoriteListResponse as CreateUserFavoriteListResponse, dashboardV1FavoriteList_universal_d_GetUserFavoriteListRequest as GetUserFavoriteListRequest, dashboardV1FavoriteList_universal_d_GetUserFavoriteListResponse as GetUserFavoriteListResponse, dashboardV1FavoriteList_universal_d_UpdateUserFavoriteListRequest as UpdateUserFavoriteListRequest, dashboardV1FavoriteList_universal_d_UpdateUserFavoriteListResponse as UpdateUserFavoriteListResponse, dashboardV1FavoriteList_universal_d_DeleteUserFavoriteListRequest as DeleteUserFavoriteListRequest, dashboardV1FavoriteList_universal_d_DeleteUserFavoriteListResponse as DeleteUserFavoriteListResponse, dashboardV1FavoriteList_universal_d_AddUserFavoriteRequest as AddUserFavoriteRequest, dashboardV1FavoriteList_universal_d_AddUserFavoriteResponse as AddUserFavoriteResponse, dashboardV1FavoriteList_universal_d_DeleteUserFavoriteRequest as DeleteUserFavoriteRequest, dashboardV1FavoriteList_universal_d_DeleteUserFavoriteResponse as DeleteUserFavoriteResponse, dashboardV1FavoriteList_universal_d_DomainEvent as DomainEvent, dashboardV1FavoriteList_universal_d_DomainEventBodyOneOf as DomainEventBodyOneOf, dashboardV1FavoriteList_universal_d_EntityCreatedEvent as EntityCreatedEvent, dashboardV1FavoriteList_universal_d_RestoreInfo as RestoreInfo, dashboardV1FavoriteList_universal_d_EntityUpdatedEvent as EntityUpdatedEvent, dashboardV1FavoriteList_universal_d_EntityDeletedEvent as EntityDeletedEvent, dashboardV1FavoriteList_universal_d_ActionEvent as ActionEvent, dashboardV1FavoriteList_universal_d_MessageEnvelope as MessageEnvelope, dashboardV1FavoriteList_universal_d_IdentificationData as IdentificationData, dashboardV1FavoriteList_universal_d_IdentificationDataIdOneOf as IdentificationDataIdOneOf, dashboardV1FavoriteList_universal_d_WebhookIdentityType as WebhookIdentityType, dashboardV1FavoriteList_universal_d_createUserFavoriteList as createUserFavoriteList, dashboardV1FavoriteList_universal_d_getUserFavoriteList as getUserFavoriteList, dashboardV1FavoriteList_universal_d_updateUserFavoriteList as updateUserFavoriteList, dashboardV1FavoriteList_universal_d_UpdateUserFavoriteList as UpdateUserFavoriteList, dashboardV1FavoriteList_universal_d_UpdateUserFavoriteListOptions as UpdateUserFavoriteListOptions, dashboardV1FavoriteList_universal_d_deleteUserFavoriteList as deleteUserFavoriteList, dashboardV1FavoriteList_universal_d_addUserFavorite as addUserFavorite, dashboardV1FavoriteList_universal_d_deleteUserFavorite as deleteUserFavorite, }; } export { dashboardV1FavoriteList_universal_d as favoriteList }; }