> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # BulkDeleteEventsByFilter # Package: eventManagement # Namespace: EventManagement # Method link: https://dev.wix.com/docs/api-reference/business-solutions/events/event-management/events-v3/bulk-delete-events-by-filter.md ## Permission Scopes: Manage Events: SCOPE.DC-EVENTS.MANAGE-EVENTS ## Introduction Deletes multiple events that meet the specified criteria.

You can retrieve the deleted events through a GDPR access request. --- ## REST API ### Schema ``` Method: bulkDeleteEventsByFilter Description: Deletes multiple events that meet the specified criteria.

You can retrieve the deleted events through a GDPR access request. URL: https://www.wixapis.com/events/v3/bulk/events/delete-by-filter Method: POST # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: filter.filter Method parameters: param name: filter | type: QueryV2 - name: paging | type: Paging | description: Paging options. Can't be used together with `cursorPaging`. - name: limit | type: integer | description: Number of items to return. See [Paging](https://dev.wix.com/api/rest/getting-started/sorting-and-paging#getting-started_sorting-and-paging_paging) for more information. - name: offset | type: integer | description: Number of items to skip in the current sort order. - name: filter | type: object | description: Filter object in the following format: `"filter" : { "fieldName1": "value1", "fieldName2":{"$operator":"value2"} }` | required: true - name: sort | type: array | description: Sort object in the following format: `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]` - name: fieldName | type: string | description: Name of the field to sort by. - name: order | type: SortOrder | description: Sort order. Use `ASC` for ascending order or `DESC` for descending order. Default: `ASC`. - enum: ASC, DESC Return type: BulkDeleteEventsByFilterResponse EMPTY-OBJECT {} ``` ### Examples ### Bulk delete events by status ```curl curl -X POST 'https://www.wixapis.com/events/v3/bulk/events/delete-by-filter' \ -H 'Content-Type: application/json' \ -H 'Authorization: ' \ -d '{ "filter": { "status": "CANCELED" } }' ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.eventManagement.EventManagement.bulkDeleteEventsByFilter(options) Description: Deletes multiple events that meet the specified criteria.

You can retrieve the deleted events through a GDPR access request. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: options.filter.filter Method parameters: param name: options | type: BulkDeleteEventsByFilterOptions none - name: filter | type: QueryV2 | description: Query options. See [API Query Language](https://dev.wix.com/docs/rest/articles/get-started/api-query-language.md) for more details. - ONE-OF: - name: paging | type: Paging | description: Paging options. Can't be used together with `cursorPaging`. - name: limit | type: integer | description: Number of items to return. See [Paging](https://dev.wix.com/api/rest/getting-started/sorting-and-paging#getting-started_sorting-and-paging_paging) for more information. - name: offset | type: integer | description: Number of items to skip in the current sort order. - name: filter | type: object | description: Filter object in the following format: `"filter" : { "fieldName1": "value1", "fieldName2":{"$operator":"value2"} }` | required: true - name: sort | type: array | description: Sort object in the following format: `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]` - name: fieldName | type: string | description: Name of the field to sort by. - name: order | type: SortOrder | description: Sort order. Use `ASC` for ascending order or `DESC` for descending order. Default: `ASC`. - enum: ASC, DESC Return type: PROMISE EMPTY-OBJECT {} ``` ### Examples ### bulkDeleteEventsByFilter ```javascript import { wixEventsV2 } from '@wix/events'; async function bulkDeleteEventsByFilter(options) { const response = await wixEventsV2.bulkDeleteEventsByFilter(options); }; ``` ### bulkDeleteEventsByFilter (with elevated permissions) ```javascript import { wixEventsV2 } from '@wix/events'; import { auth } from '@wix/essentials'; async function myBulkDeleteEventsByFilterMethod(options) { const elevatedBulkDeleteEventsByFilter = auth.elevate(wixEventsV2.bulkDeleteEventsByFilter); const response = await elevatedBulkDeleteEventsByFilter(options); } ``` ### bulkDeleteEventsByFilter (self-hosted) Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md). ```javascript import { createClient } from '@wix/sdk'; import { wixEventsV2 } from '@wix/events'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { wixEventsV2 }, // Include the auth strategy and host as relevant }); async function bulkDeleteEventsByFilter(options) { const response = await myWixClient.wixEventsV2.bulkDeleteEventsByFilter(options); }; ``` ---