> 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 # BulkCancelEvent # Package: triggers # Namespace: EsbConfigResolver # Method link: https://dev.wix.com/docs/api-reference/business-management/automations/triggers/triggered-events/bulk-cancel-event.md ## Permission Scopes: Manage Your App: SCOPE.DC.MANAGE-YOUR-APP ## Introduction Bulk cancels any remaining actions for a trigger and external entities. --- ## REST API ### Schema ``` Method: bulkCancelEvent Description: Bulk cancels any remaining actions for a trigger and external entities. URL: https://www.wixapis.com/automations/v1/events/bulk-cancel Method: POST # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: triggerKey, externalEntityIds Method parameters: param name: externalEntityIds | type: array | description: Repeated list of external_entity_id, representing the related resources' GUIDs. | required: true param name: triggerKey | type: triggerKey | description: Trigger key whose events you want to cancel. For example, `form_submitted` or `invoice_due`. | required: true Return type: BulkCancelEventResponse - name: triggerKey | type: string | description: Trigger key related to the canceled event. - name: results | type: array | description: List of results for each item in the bulk cancel event request. - name: itemMetadata | type: ItemMetadata | description: Metadata of the item, including its GUID and success or failure status. - name: id | type: string | description: Item GUID. Should always be available, unless it's impossible (for example, when failing to create an item). - name: originalIndex | type: integer | description: Index of the item within the request array. Allows for correlation between request and response items. - name: success | type: boolean | description: Whether the requested action was successful for this item. When `false`, the `error` field is populated. - name: error | type: ApplicationError | description: Details about the error in case of failure. - name: code | type: string | description: Error code. - name: description | type: string | description: Description of the error. - name: data | type: object | description: Data related to the error. - name: externalEntityId | type: string | description: GUID of the related resource in GUGUID format. - name: bulkActionMetadata | type: BulkActionMetadata | description: Metadata for the overall bulk action, including success and failure counts. - name: totalSuccesses | type: integer | description: Number of items that were successfully processed. - name: totalFailures | type: integer | description: Number of items that couldn't be processed. - name: undetailedFailures | type: integer | description: Number of failures without details because detailed failure threshold was exceeded. ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.triggers.EsbConfigResolver.bulkCancelEvent(triggerKey, externalEntityIds) Description: Bulk cancels any remaining actions for a trigger and external entities. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: triggerKey, externalEntityIds Method parameters: param name: externalEntityIds | type: array | description: Repeated list of external_entity_id, representing the related resources' GUIDs. | required: true param name: triggerKey | type: string | description: Trigger key whose events you want to cancel. For example, `form_submitted` or `invoice_due`. | required: true Return type: PROMISE - name: triggerKey | type: string | description: Trigger key related to the canceled event. - name: results | type: array | description: List of results for each item in the bulk cancel event request. - name: itemMetadata | type: ItemMetadata | description: Metadata of the item, including its GUID and success or failure status. - name: _id | type: string | description: Item GUID. Should always be available, unless it's impossible (for example, when failing to create an item). - name: originalIndex | type: integer | description: Index of the item within the request array. Allows for correlation between request and response items. - name: success | type: boolean | description: Whether the requested action was successful for this item. When `false`, the `error` field is populated. - name: error | type: ApplicationError | description: Details about the error in case of failure. - name: code | type: string | description: Error code. - name: description | type: string | description: Description of the error. - name: data | type: object | description: Data related to the error. - name: externalEntityId | type: string | description: GUID of the related resource in GUGUID format. - name: bulkActionMetadata | type: BulkActionMetadata | description: Metadata for the overall bulk action, including success and failure counts. - name: totalSuccesses | type: integer | description: Number of items that were successfully processed. - name: totalFailures | type: integer | description: Number of items that couldn't be processed. - name: undetailedFailures | type: integer | description: Number of failures without details because detailed failure threshold was exceeded. ``` ### Examples ### bulkCancelEvent ```javascript import { activations } from '@wix/automations'; async function bulkCancelEvent(triggerKey,externalEntityIds) { const response = await activations.bulkCancelEvent(triggerKey,externalEntityIds); }; ``` ### bulkCancelEvent (with elevated permissions) ```javascript import { activations } from '@wix/automations'; import { auth } from '@wix/essentials'; async function myBulkCancelEventMethod(triggerKey,externalEntityIds) { const elevatedBulkCancelEvent = auth.elevate(activations.bulkCancelEvent); const response = await elevatedBulkCancelEvent(triggerKey,externalEntityIds); } ``` ### bulkCancelEvent (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 { activations } from '@wix/automations'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { activations }, // Include the auth strategy and host as relevant }); async function bulkCancelEvent(triggerKey,externalEntityIds) { const response = await myWixClient.activations.bulkCancelEvent(triggerKey,externalEntityIds); }; ``` ---