import { RequestOptionsFactory } from '@wix/sdk-types'; /** Retrieves an event. */ export declare function getEvent(payload: object): RequestOptionsFactory; /** Retrieves a list of events by their IDs. */ export declare function listEvents(payload: object): RequestOptionsFactory; /** * Creates a query to retrieve a list of events. * * The `queryEvents()` function builds a query to retrieve a list of events and returns an `EventsQueryBuilder` object. * * The returned object contains the query definition, which is typically used to run the query using the [find()](https://dev.wix.com/docs/sdk/backend-modules/calendar/events/events-query-builder/find) function. * * You can refine the query by chaining `EventsQueryBuilder` functions onto the query. `EventsQueryBuilder` functions enable you to sort, filter, and control the results that `queryEvents()` returns. * * `queryEvents()` runs with the following `EventsQueryBuilder` default that you can override: * * + `limit` is `50`. * + Sorted by `event.start` in ascending order. * * The functions that are chained to `queryEvents()` are applied in the order they are called. * * The following `EventsQueryBuilder` functions are supported for the `queryEvents()` function. For a full description of the events object, see the object returned for the [items](https://dev.wix.com/docs/sdk/backend-modules/calendar/events/events-query-result/items) property in `EventsQueryResult`. * */ export declare function queryEvents(payload: object): RequestOptionsFactory; /** * Creates an event. * * * If you provide `recurrenceRule`, an event with `{"recurrenceType": "MASTER"}` is created. Then, you can't set `start.localDate` to a past date, though the time can be earlier on the same day. You can, however, create single-occurrence events for past dates. * * You can't create an event with `recurrenceType` set to `INSTANCE` or `EXCEPTION`. `INSTANCE` events are generated automatically based on the recurrence rule in the relevant `MASTER` event. `EXCEPTION` events are automatically created when you [update](https://dev.wix.com/docs/sdk/backend-modules/calendar/events/update-event) an `INSTANCE` event, which changes its `recurrenceType` to `EXCEPTION`. */ export declare function createEvent(payload: object): RequestOptionsFactory; /** * Creates multiple events in bulk. * * * If you provide `recurrenceRule`, an event with `{"recurrenceType": "MASTER"}` is * created. Then, you can't set `start.localDate` to a past date, though the time can be * earlier on the same day. You can, however, create single-occurrence events for * past dates. * * You can't create an event with `recurrenceType` set to `INSTANCE` or `EXCEPTION`. * `INSTANCE` events are generated automatically based on the recurrence rule in the * relevant `MASTER` event. `EXCEPTION` events are automatically created when you * [update](https://dev.wix.com/docs/sdk/backend-modules/calendar/events/update-event) * an `INSTANCE` event, which changes its `recurrenceType` to `EXCEPTION`. */ export declare function bulkCreateEvent(payload: object): RequestOptionsFactory; /** * Updates an event. * * * When updating an event with `{"recurrenceType": "INSTANCE"}`, the * `recurrenceType` automatically changes to `EXCEPTION`. * * When updating an event with `{"recurrenceType": "MASTER"}`: * + Past `INSTANCE` and `EXCEPTION` events remain unchanged. * + For future `INSTANCE` events, all relevant fields are updated. * + For future `EXCEPTION` events, only changes to the `inheritedFields` are * applied, while other fields remain unchanged. */ export declare function updateEvent(payload: object): RequestOptionsFactory; /** * Updates multiple events in bulk. * * * When updating an event with `{"recurrenceType": "INSTANCE"}`, the * `recurrenceType` automatically changes to `EXCEPTION`. * * When updating an event with `{"recurrenceType": "MASTER"}`: * + Past `INSTANCE` and `EXCEPTION` events remain unchanged. * + For future `INSTANCE` events, all relevant fields are updated. * + For future `EXCEPTION` events, only changes to the `inheritedFields` are * applied, while other fields remain unchanged. */ export declare function bulkUpdateEvent(payload: object): RequestOptionsFactory; /** * Restores the event's default values from the relevant schedule or `MASTER` * event. * * * You must provide `fields` to specify which `inheritedFields` are restored. * * For example, if you've created an event that takes place in a non-default * location with a custom title and capacity, but you want to reset only title * and capacity to default values without affecting the location, provide the * event ID and set `fields` to `["TITLE", "CAPACITY"]`. * * Refer to the [default values article](https://dev.wix.com/docs/sdk/backend-modules/calendar/default-values) * for more information. */ export declare function restoreEventDefaults(payload: object): RequestOptionsFactory; /** * Splits a recurring `MASTER` event into 2 separate `MASTER` events. * * * You must provide a `splitLocalDate` that's in the future and after the `start` * date of the next `INSTANCE` or `EXCEPTION` event in the series. Additionally, * there must be another `INSTANCE` or `EXCEPTION` event following this next event, * as the changes wouldn't affect any event without a subsequent occurrence. * * If you want to modify a `MASTER` event with the changes already applying to * the very next event, use * [updateEvent()](https://dev.wix.com/docs/sdk/backend-modules/calendar/events/update-event) * instead, as this preserves past events and only modifies future events. * * The main consequences are: * - **The original `MASTER` event is shortened**. Its `recurrenceRule.until.localDate` * is updated to `end.localDate` of the latest `INSTANCE` or `EXCEPTION` * event starting before `splitLocalDate`. If an `INSTANCE` or `EXCEPTION` event * starts before but ends after `splitLocalDate`, `until.localDate` is set * to value that's later than `splitLocalDate`. * - **A new `MASTER` event is created**, starting from the first event that * begins after `splitLocalDate`. * - **Existing `INSTANCE` and `EXCEPTION` events that occur after the split are updated**. * Their `recurringEventId` is set to the ID of the newly created `MASTER` event. */ export declare function splitRecurringEvent(payload: object): RequestOptionsFactory; /** Cancels an event. */ export declare function cancelEvent(payload: object): RequestOptionsFactory; /** Cancels multiple events in bulk. */ export declare function bulkCancelEvent(payload: object): RequestOptionsFactory; /** * Retrieves a list of events filtered by the participant's * [contact](https://dev.wix.com/docs/sdk/backend-modules/crm/contacts/introduction) * ID. * * * You can't set `toLocalDate` to a value that's more than a full year after * `fromLocalDate`. */ export declare function listEventsByContactId(payload: object): RequestOptionsFactory; /** * Retrieves a list of events filtered by the participant's * [member](https://dev.wix.com/docs/sdk/backend-modules/members/members/introduction) * ID. * * * You can't set `toLocalDate` to a value that's more than a full year after * `fromLocalDate`. */ export declare function listEventsByMemberId(payload: object): RequestOptionsFactory;