Skip to content

Function: deleteWorklog() ​

ts
function deleteWorklog(
   client, 
   parameters, 
   options?
): Promise<void>;

Defined in: src/cloud/api/issueWorklogs.ts:243

Deletes a worklog from an issue.

Time tracking must be enabled in Jira, otherwise this operation returns an error. For more information, see Configuring time tracking.

This operation can be accessed anonymously.

Permissions required:

  • Browse projects project permission for the project that the issue is in.
  • If issue-level security is configured, issue-level security permission to view the issue.
  • Delete all worklogs project permission to delete any worklog or Delete own worklogs to delete worklogs created by the user,
  • If the worklog has visibility restrictions, belongs to the group or has the role visibility is restricted to.

Parameters ​

ParameterTypeDescription
clientClient-
parameters{ adjustEstimate?: "auto" | "manual" | "new" | string & object | "leave"; id: string; increaseBy?: string; issueIdOrKey: string; newEstimate?: string; notifyUsers?: boolean; overrideEditableFlag?: boolean; }-
parameters.adjustEstimate?"auto" | "manual" | "new" | string & object | "leave"Defines how to update the issue's time estimate, the options are: - new Sets the estimate to a specific value, defined in newEstimate. - leave Leaves the estimate unchanged. - manual Increases the estimate by amount specified in increaseBy. - auto Reduces the estimate by the value of timeSpent in the worklog.
parameters.id?stringThe ID of the worklog.
parameters.increaseBy?stringThe amount to increase the issue's remaining estimate by, as days (#d), hours (#h), or minutes (#m or #). For example, 2d. Required when adjustEstimate is manual.
parameters.issueIdOrKey?stringThe ID or key of the issue.
parameters.newEstimate?stringThe value to set as the issue's remaining time estimate, as days (#d), hours (#h), or minutes (#m or #). For example, 2d. Required when adjustEstimate is new.
parameters.notifyUsers?booleanWhether users watching the issue are notified by email.
parameters.overrideEditableFlag?booleanWhether the work log entry should be added to the issue even if the issue is not editable, because jira.issue.editable set to false or missing. For example, the issue is closed. Connect and Forge app users with admin permission can use this flag.
options?RequestOptions-

Returns ​

Promise<void>