export interface AvailabilityException { /** * Availability exception ID. * @readonly */ id?: string | null; /** * Revision number, which increments by 1 each time the availability exception is updated. * To prevent conflicting changes, the current revision must be specified when updating the availability exception. * @readonly */ revision?: string | null; /** * Date and time the availability exception was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format. * @readonly */ createdDate?: Date | null; /** * Date and time the availability exception was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format. * @readonly */ updatedDate?: Date | null; /** The start time of the availability exception in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format. */ startTime?: Date | null; /** The end time of the availability exception in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format. */ endTime?: Date | null; /** * Whether the exception makes the [`start_time`, `end_time`] range available. * If `true`, the exception makes the restaurant available for online ordering during the time range. If `false`, the exception makes the restaurant unavailable for ordering during the time range. * Currently, only `false` is supported. * @readonly */ available?: boolean | null; /** Exception name. */ name?: string | null; /** Fulfillment methods for which this exception applies. */ affectedFulfillmentMethods?: AffectedFulfillmentMethods; /** ID of the restaurant operation this exception is associated with. (See the Restaurants Operations API for more information.) */ operationId?: string | null; /** Extended fields. */ extendedFields?: ExtendedFields; } export interface AffectedFulfillmentMethods extends AffectedFulfillmentMethodsAffectedMethodsOptionsOneOf { /** Settings for specific fulfillment methods. */ specificFulfillmentMethodsOptions?: SpecificFulfillmentMethodsImpactScope; /** The type of the fulfillment methods this exception applies to. */ affectedMethods?: AffectedMethods; } /** @oneof */ export interface AffectedFulfillmentMethodsAffectedMethodsOptionsOneOf { /** Settings for specific fulfillment methods. */ specificFulfillmentMethodsOptions?: SpecificFulfillmentMethodsImpactScope; } /** The scope the exception applied. */ export declare enum AffectedMethods { /** Unknown impact scope. */ UNKNOWN_AFFECTED_METHODS = "UNKNOWN_AFFECTED_METHODS", /** All fulfillment methods of this operation applied for this exception. */ ALL_FULFILLMENT_METHODS = "ALL_FULFILLMENT_METHODS", /** Specific fulfillment methods applied for this exception. */ SPECIFIC_FULFILLMENT_METHODS = "SPECIFIC_FULFILLMENT_METHODS", /** All pickup fulfillment methods applied for this exception. */ ALL_PICKUP_FULFILLMENT_METHODS = "ALL_PICKUP_FULFILLMENT_METHODS", /** All delivery fulfillment methods applied for this exception. */ ALL_DELIVERY_FULFILLMENT_METHODS = "ALL_DELIVERY_FULFILLMENT_METHODS" } /** Details of the specific fulfillment methods this exception applies to. */ export interface SpecificFulfillmentMethodsImpactScope { /** IDs of the fulfillment methods this exception applies to. */ fulfillmentMethodIds?: string[] | 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 CreateAvailabilityExceptionRequest { /** Availability exception details. */ availabilityException: AvailabilityException; } export interface CreateAvailabilityExceptionResponse { /** The created availability exception. */ availabilityException?: AvailabilityException; } export interface GetAvailabilityExceptionRequest { /** ID of the availability exception to retrieve. */ availabilityExceptionId: string; } export interface GetAvailabilityExceptionResponse { /** The requested availability exception. */ availabilityException?: AvailabilityException; } export interface UpdateAvailabilityExceptionRequest { /** Availability exception to update. */ availabilityException: AvailabilityException; } export interface UpdateAvailabilityExceptionResponse { /** Updated availability exception. */ availabilityException?: AvailabilityException; } export interface DeleteAvailabilityExceptionRequest { /** ID of the availability exception to delete. */ availabilityExceptionId: string; } export interface DeleteAvailabilityExceptionResponse { } export interface QueryAvailabilityExceptionsRequest { /** WQL expression. */ 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 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 QueryAvailabilityExceptionsResponse { /** List of availability exceptions. */ availabilityExceptions?: AvailabilityException[]; /** Paging metadata */ 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 BulkCreateAvailabilityExceptionsRequest { /** Availability exception details. */ availabilityExceptions?: AvailabilityException[]; /** Whether the full availability exception entity is returned. Defaults to `true`. */ returnEntity?: boolean; } export interface BulkCreateAvailabilityExceptionsResponse { /** Information about the created availability exception. */ results?: BulkCreateAvailabilityExceptionsResult[]; /** Metadata for the API call. */ bulkActionMetadata?: BulkActionMetadata; } export interface BulkCreateAvailabilityExceptionsResult { /** Metadata for availability exception creation. */ itemMetadata?: ItemMetadata; /** Created availability exception. */ availabilityException?: AvailabilityException; } 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 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 { entityAsJson?: string; /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */ restoreInfo?: RestoreInfo; } 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. */ currentEntityAsJson?: string; } export interface EntityDeletedEvent { /** Entity that was deleted */ deletedEntityAsJson?: string | null; } export interface ActionEvent { bodyAsJson?: 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" } interface AffectedFulfillmentMethodsNonNullableFields { affectedMethods: AffectedMethods; } interface AvailabilityExceptionNonNullableFields { affectedFulfillmentMethods?: AffectedFulfillmentMethodsNonNullableFields; } export interface CreateAvailabilityExceptionResponseNonNullableFields { availabilityException?: AvailabilityExceptionNonNullableFields; } export interface GetAvailabilityExceptionResponseNonNullableFields { availabilityException?: AvailabilityExceptionNonNullableFields; } export interface UpdateAvailabilityExceptionResponseNonNullableFields { availabilityException?: AvailabilityExceptionNonNullableFields; } export interface QueryAvailabilityExceptionsResponseNonNullableFields { availabilityExceptions: AvailabilityExceptionNonNullableFields[]; } export {};