Search.../

deletePhase( )

Deprecated. This function is being discontinued in the upcoming months. We are working to provide alternatives, and we'll provide timely updates before implementing any changes. We understand that this transition might present challenges, and we appreciate your patience and understanding.

Description

Deletes a workflow phase.

The deletePhase() function returns a Promise when the specified phase has been deleted.

This function requires you to specify the ID of a phase. To learn about retrieving IDs in the Workflow API, see Retrieving IDs.

Syntax

function deletePhase(phaseId: string): Promise<void>

deletePhase Parameters

NAME
TYPE
DESCRIPTION
phaseId
string

ID of the phase to delete.

Returns

Return Type:

Promise<void>

Was this helpful?

Delete a phase

Copy Code
1import { Permissions, webMethod } from 'wix-web-module';
2import { workflows } from 'wix-crm-backend';
3
4export const deletePhase = webMethod(Permissions.Anyone, (phaseId) => {
5 return workflows.deletePhase(phaseId);
6});
7
8// Returns a promise that resolves to void.