export interface Section { /** * Section ID. * @readonly */ _id?: string | null; /** * Revision number, which increments by 1 each time the section is updated. To prevent conflicting changes, the current revision must be passed when updating the section. Ignored when creating a section. * @readonly */ revision?: string | null; /** * Date and time the section was created. * @readonly */ _createdDate?: Date | null; /** * Date and time the section was updated. * @readonly */ _updatedDate?: Date | null; /** Section name. */ name?: string; /** Section description. */ description?: string | null; /** Main section image. */ image?: string; /** Additional section images. */ additionalImages?: string[]; /** Item IDs. */ itemIds?: string[]; /** Extended fields. */ extendedFields?: ExtendedFields; /** Whether the section is visible in the menu for site visitors. */ visible?: boolean | null; } export interface ExtendedFields { /** * Extended field data. Each key corresponds to the namespace of the app that created the extended fields. * The value of each key is structured according to the schema defined when the extended fields were configured. * * You can only access fields for which you have the appropriate permissions. * * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields). */ namespaces?: Record>; } export interface InvalidateCache extends InvalidateCacheGetByOneOf { /** Invalidate by msId. NOT recommended, as this will invalidate the entire site cache! */ metaSiteId?: string; /** Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache! */ siteId?: string; /** Invalidate by App */ app?: App; /** Invalidate by page id */ page?: Page; /** Invalidate by URI path */ uri?: URI; /** Invalidate by file (for media files such as PDFs) */ file?: File; /** tell us why you're invalidating the cache. You don't need to add your app name */ reason?: string | null; /** Is local DS */ localDc?: boolean; hardPurge?: boolean; } /** @oneof */ export interface InvalidateCacheGetByOneOf { /** Invalidate by msId. NOT recommended, as this will invalidate the entire site cache! */ metaSiteId?: string; /** Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache! */ siteId?: string; /** Invalidate by App */ app?: App; /** Invalidate by page id */ page?: Page; /** Invalidate by URI path */ uri?: URI; /** Invalidate by file (for media files such as PDFs) */ file?: File; } export interface App { /** The AppDefId */ appDefId?: string; /** The instance Id */ instanceId?: string; } export interface Page { /** the msid the page is on */ metaSiteId?: string; /** Invalidate by Page ID */ pageId?: string; } export interface URI { /** the msid the URI is on */ metaSiteId?: string; /** URI path to invalidate (e.g. page/my/path) - without leading/trailing slashes */ uriPath?: string; } export interface File { /** the msid the file is related to */ metaSiteId?: string; /** Invalidate by filename (for media files such as PDFs) */ fileName?: string; } export interface CreateSectionRequest { /** Section details. */ section: Section; } export interface CreateSectionResponse { /** Section. */ section?: Section; } export interface BulkCreateSectionsRequest { /** Sections details. */ sections: Section[]; /** Whether to receive the created sections in the response. */ returnEntity?: boolean; } export interface BulkCreateSectionsResponse { /** Information about the created sections. */ results?: BulkCreateSectionResult[]; /** Metadata for the API call. */ bulkActionMetadata?: BulkActionMetadata; } export interface BulkCreateSectionResult { /** Metadata for created sections. */ itemMetadata?: ItemMetadata; /** Created section. Only returned if `returnEntity` is set to `true`. */ item?: Section; } export interface ItemMetadata { /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */ _id?: string | null; /** Index of the item within the request array. Allows for correlation between request and response items. */ originalIndex?: number; /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */ success?: boolean; /** Details about the error in case of failure. */ error?: ApplicationError; } export interface ApplicationError { /** Error code. */ code?: string; /** Description of the error. */ description?: string; /** Data related to the error. */ data?: Record | null; } export interface BulkActionMetadata { /** Number of items that were successfully processed. */ totalSuccesses?: number; /** Number of items that couldn't be processed. */ totalFailures?: number; /** Number of failures without details because detailed failure threshold was exceeded. */ undetailedFailures?: number; } export interface GetSectionRequest { /** Section ID. */ sectionId: string; } export interface GetSectionResponse { /** Section. */ section?: Section; } export interface ListSectionsRequest { /** Section IDs. */ sectionIds?: string[]; /** The metadata of the paginated results. */ paging?: CursorPaging; /** Whether to return only sections that are visible to site visitors. */ onlyVisible?: boolean | null; } export interface CursorPaging { /** Number of items to load. */ limit?: number | null; /** * Pointer to the next or previous page in the list of results. * * You can get the relevant cursor token * from the `pagingMetadata` object in the previous call's response. * Not relevant for the first request. */ cursor?: string | null; } export interface ListSectionsResponse { /** Retrieved sections. */ sections?: Section[]; /** The metadata of the paginated results. */ pagingMetadata?: CursorPagingMetadata; } export interface CursorPagingMetadata { /** Number of items returned in the response. */ count?: number | null; /** Offset that was requested. */ cursors?: Cursors; /** * Indicates if there are more results after the current page. * If `true`, another page of results can be retrieved. * If `false`, this is the last page. */ hasNext?: boolean | null; } export interface Cursors { /** Cursor pointing to next page in the list of results. */ next?: string | null; /** Cursor pointing to previous page in the list of results. */ prev?: string | null; } export interface QuerySectionsRequest { /** Query options. */ query?: CursorQuery; } export interface CursorQuery extends CursorQueryPagingMethodOneOf { /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ cursorPaging?: CursorPaging; /** * Filter object in the following format: * `"filter" : { * "fieldName1": "value1", * "fieldName2":{"$operator":"value2"} * }` * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains` */ filter?: Record | null; /** * Sort object in the following format: * `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]` */ sort?: Sorting[]; } /** @oneof */ export interface CursorQueryPagingMethodOneOf { /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ cursorPaging?: CursorPaging; } export interface Sorting { /** Name of the field to sort by. */ fieldName?: string; /** Sort order. */ order?: SortOrder; } export declare enum SortOrder { ASC = "ASC", DESC = "DESC" } export interface QuerySectionsResponse { /** Retrieved sections. */ sections?: Section[]; /** The metadata of the paginated results. */ pagingMetadata?: CursorPagingMetadata; } export interface UpdateSectionRequest { /** Section update. */ section: Section; } export interface UpdateSectionResponse { /** Updated section. */ section?: Section; } export interface BulkUpdateSectionRequest { /** Sections to update. */ sections: MaskedSection[]; /** Whether to receive the updated sections in the response. */ returnEntity?: boolean; } export interface MaskedSection { /** Section update. */ section?: Section; /** Explicit list of fields to update. */ mask?: string[]; } export interface BulkUpdateSectionResponse { /** Information about the updated sections. */ results?: BulkSectionResult[]; /** Metadata for the API call. */ bulkActionMetadata?: BulkActionMetadata; } export interface BulkSectionResult { /** Whether to receive the updated sections in the response. */ sectionMetadata?: ItemMetadata; /** Updated section. Only returned if `returnEntity` is set to `true`. */ section?: Section; } export interface DeleteSectionRequest { /** Section ID. */ sectionId: string; } export interface DeleteSectionResponse { } export interface BulkDeleteSectionsRequest { /** Section IDs. */ ids: string[]; } export interface BulkDeleteSectionsResponse { /** Information about the deleted sections. */ results?: BulkDeleteSectionResult[]; /** Metadata for the API call. */ bulkActionMetadata?: BulkActionMetadata; } export interface BulkDeleteSectionResult { /** Metadata for deleted sections. */ itemMetadata?: ItemMetadata; } export interface CloneSectionsRequest { /** The MetaSiteId to clone from. */ metaSiteId?: string; } export interface CloneSectionsResponse { } export 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 */ export interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; } export interface EntityCreatedEvent { entity?: string; } export interface RestoreInfo { deletedDate?: Date | null; } export 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. */ currentEntity?: string; } export interface EntityDeletedEvent { /** Entity that was deleted */ deletedEntity?: string | null; } export interface ActionEvent { body?: string; } export interface Empty { } export interface MessageEnvelope { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; } export 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 */ export 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; } export declare enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } export interface SectionNonNullableFields { name: string; image: string; additionalImages: string[]; itemIds: string[]; } export interface CreateSectionResponseNonNullableFields { section?: SectionNonNullableFields; } interface ApplicationErrorNonNullableFields { code: string; description: string; } interface ItemMetadataNonNullableFields { originalIndex: number; success: boolean; error?: ApplicationErrorNonNullableFields; } interface BulkCreateSectionResultNonNullableFields { itemMetadata?: ItemMetadataNonNullableFields; item?: SectionNonNullableFields; } interface BulkActionMetadataNonNullableFields { totalSuccesses: number; totalFailures: number; undetailedFailures: number; } export interface BulkCreateSectionsResponseNonNullableFields { results: BulkCreateSectionResultNonNullableFields[]; bulkActionMetadata?: BulkActionMetadataNonNullableFields; } export interface GetSectionResponseNonNullableFields { section?: SectionNonNullableFields; } export interface ListSectionsResponseNonNullableFields { sections: SectionNonNullableFields[]; } export interface QuerySectionsResponseNonNullableFields { sections: SectionNonNullableFields[]; } export interface UpdateSectionResponseNonNullableFields { section?: SectionNonNullableFields; } interface BulkSectionResultNonNullableFields { sectionMetadata?: ItemMetadataNonNullableFields; section?: SectionNonNullableFields; } export interface BulkUpdateSectionResponseNonNullableFields { results: BulkSectionResultNonNullableFields[]; bulkActionMetadata?: BulkActionMetadataNonNullableFields; } interface BulkDeleteSectionResultNonNullableFields { itemMetadata?: ItemMetadataNonNullableFields; } export interface BulkDeleteSectionsResponseNonNullableFields { results: BulkDeleteSectionResultNonNullableFields[]; bulkActionMetadata?: BulkActionMetadataNonNullableFields; } export interface BaseEventMetadata { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; } export interface EventMetadata extends BaseEventMetadata { /** * 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; } export interface SectionCreatedEnvelope { entity: Section; metadata: EventMetadata; } /** @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @permissionId RESTAURANTS.SECTION_READ * @webhook * @eventType wix.restaurants.menus.v1.section_created * @documentationMaturity preview */ export declare function onSectionCreated(handler: (event: SectionCreatedEnvelope) => void | Promise): void; export interface SectionDeletedEnvelope { metadata: EventMetadata; } /** @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @permissionId RESTAURANTS.SECTION_READ * @webhook * @eventType wix.restaurants.menus.v1.section_deleted * @documentationMaturity preview */ export declare function onSectionDeleted(handler: (event: SectionDeletedEnvelope) => void | Promise): void; export interface SectionUpdatedEnvelope { entity: Section; metadata: EventMetadata; } /** * Triggered when a section is updated. * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @permissionId RESTAURANTS.SECTION_READ * @webhook * @eventType wix.restaurants.menus.v1.section_updated * @documentationMaturity preview */ export declare function onSectionUpdated(handler: (event: SectionUpdatedEnvelope) => void | Promise): void; /** * > **Note:** The Sections API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Creates a section. * * To create multiple sections at once, use [Bulk Create Sections](/sections/bulk-create-sections). * @param section - Section details. * @public * @documentationMaturity preview * @requiredField section * @permissionId RESTAURANTS.SECTION_CREATE * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @returns Section. * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.CreateSection */ export declare function createSection(section: Section): Promise
; /** * > **Note:** The Section API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Creates multiple sections at once. * @param sections - Sections details. * @public * @documentationMaturity preview * @requiredField sections * @permissionId RESTAURANTS.SECTION_CREATE * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.BulkCreateSections */ export declare function bulkCreateSections(sections: Section[], options?: BulkCreateSectionsOptions): Promise; export interface BulkCreateSectionsOptions { /** Whether to receive the created sections in the response. */ returnEntity?: boolean; } /** * > **Note:** The Section API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Retrieves a section by ID. * @param sectionId - Section ID. * @public * @documentationMaturity preview * @requiredField sectionId * @permissionId RESTAURANTS.SECTION_READ * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @applicableIdentity VISITOR * @returns Section. * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.GetSection */ export declare function getSection(sectionId: string): Promise
; /** * > **Note:** The Section API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Retrieves a list of up to 500 sections. * @public * @documentationMaturity preview * @permissionId RESTAURANTS.SECTION_READ * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @applicableIdentity VISITOR * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.ListSections */ export declare function listSections(options?: ListSectionsOptions): Promise; export interface ListSectionsOptions { /** Section IDs. */ sectionIds?: string[]; /** The metadata of the paginated results. */ paging?: CursorPaging; /** Whether to return only sections that are visible to site visitors. */ onlyVisible?: boolean | null; } /** * Creates a query to retrieve a list of sections. * * The `querySections()` function builds a query to retrieve a list of sections and returns a `SectionsQueryBuilder` object. * * The returned object contains the query definition, which is used to run the query using the [`find()`](/sections/sections-query-builder/find) function. * * You can refine the query by chaining `SectionsQueryBuilder` functions onto the query. `SectionsQueryBuilder` functions enable you to filter, sort, and control the results that `querySections()` returns. * * `querySections()` runs with the following `SectionsQueryBuilder` defaults, which you can override: * * * [`limit(100)`](/sections/sections-query-builder/limit) * * [`ascending('entityId')`](/sections/sections-query-builder/ascending) * * The following `SectionsQueryBuilder` functions are supported for `querySections()`. For a full description of the section object, see the object returned for the [`items`](/sections/sections-query-result/items) property in `SectionsQueryResult`. * @public * @documentationMaturity preview * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @permissionId RESTAURANTS.SECTION_READ * @applicableIdentity APP * @applicableIdentity VISITOR * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.QuerySections */ export declare function querySections(): SectionsQueryBuilder; interface QueryCursorResult { cursors: Cursors; hasNext: () => boolean; hasPrev: () => boolean; length: number; pageSize: number; } export interface SectionsQueryResult extends QueryCursorResult { items: Section[]; query: SectionsQueryBuilder; next: () => Promise; prev: () => Promise; } export interface SectionsQueryBuilder { /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ eq: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name' | 'description', value: any) => SectionsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ ne: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name' | 'description', value: any) => SectionsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ ge: (propertyName: '_createdDate' | '_updatedDate', value: any) => SectionsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ gt: (propertyName: '_createdDate' | '_updatedDate', value: any) => SectionsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ le: (propertyName: '_createdDate' | '_updatedDate', value: any) => SectionsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ lt: (propertyName: '_createdDate' | '_updatedDate', value: any) => SectionsQueryBuilder; /** @param propertyName - Property whose value is compared with `string`. * @param string - String to compare against. Case-insensitive. * @documentationMaturity preview */ startsWith: (propertyName: 'name' | 'description', value: string) => SectionsQueryBuilder; /** @documentationMaturity preview */ in: (propertyName: '_id' | 'name' | 'description', value: any) => SectionsQueryBuilder; /** @documentationMaturity preview */ exists: (propertyName: 'image' | 'itemIds', value: boolean) => SectionsQueryBuilder; /** @param limit - Number of items to return, which is also the `pageSize` of the results object. * @documentationMaturity preview */ limit: (limit: number) => SectionsQueryBuilder; /** @param cursor - A pointer to specific record * @documentationMaturity preview */ skipTo: (cursor: string) => SectionsQueryBuilder; /** @documentationMaturity preview */ find: () => Promise; } /** * > **Note:** The Section API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Updates a section. * * Each time a section is updated, its revision increments by 1. The existing revision must be included when updating a section. This ensures you're working with the latest section information, and it prevents unintended overwrites. * @param _id - Section ID. * @public * @documentationMaturity preview * @requiredField _id * @requiredField section * @requiredField section.revision * @permissionId RESTAURANTS.SECTION_UPDATE * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @returns Updated section. * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.UpdateSection */ export declare function updateSection(_id: string | null, section: UpdateSection): Promise
; export interface UpdateSection { /** * Section ID. * @readonly */ _id?: string | null; /** * Revision number, which increments by 1 each time the section is updated. To prevent conflicting changes, the current revision must be passed when updating the section. Ignored when creating a section. * @readonly */ revision?: string | null; /** * Date and time the section was created. * @readonly */ _createdDate?: Date | null; /** * Date and time the section was updated. * @readonly */ _updatedDate?: Date | null; /** Section name. */ name?: string; /** Section description. */ description?: string | null; /** Main section image. */ image?: string; /** Additional section images. */ additionalImages?: string[]; /** Item IDs. */ itemIds?: string[]; /** Extended fields. */ extendedFields?: ExtendedFields; /** Whether the section is visible in the menu for site visitors. */ visible?: boolean | null; } /** * > **Note:** The Section API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Updates multiple sections at once. * * Each time a section is updated, its revision increments by 1. The existing revision must be included when updating a section. This ensures you're working with the latest section information, and it prevents unintended overwrites. * @param sections - Sections to update. * @public * @documentationMaturity preview * @requiredField sections * @requiredField sections.section._id * @requiredField sections.section.revision * @permissionId RESTAURANTS.SECTION_UPDATE * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.BulkUpdateSection */ export declare function bulkUpdateSection(sections: MaskedSection[], options?: BulkUpdateSectionOptions): Promise; export interface BulkUpdateSectionOptions { /** Whether to receive the updated sections in the response. */ returnEntity?: boolean; } /** * > **Note:** The Section API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Deletes a section. * @param sectionId - Section ID. * @public * @documentationMaturity preview * @requiredField sectionId * @permissionId RESTAURANTS.SECTION_DELETE * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.DeleteSection */ export declare function deleteSection(sectionId: string): Promise; /** * > **Note:** The Section API only works with the Wix Restaurants Menus (New) app. Make sure you have installed this app from the [Wix App Market](https://www.wix.com/app-market/wix-restaurants-menus-new). * * Deletes multiple sections at once. * @param ids - Section IDs. * @public * @documentationMaturity preview * @requiredField ids * @permissionId RESTAURANTS.SECTION_DELETE * @permissionScope Manage Bookings Services and Settings * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION * @permissionScope Manage Portfolio * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @applicableIdentity APP * @fqn com.wixpress.restaurants.menus_section.v1.RestaurantsMenusSection.BulkDeleteSections */ export declare function bulkDeleteSections(ids: string[]): Promise; export {};