Skip to content
Get started

Delete a task

client.promptly.tasks.delete(stringtaskID, RequestOptionsoptions?): TaskDeleteResponse { success }
DELETE/api/promptly/tasks/{taskId}

Delete a task and all its run history

ParametersExpand Collapse
taskID: string
formatuuid
ReturnsExpand Collapse
TaskDeleteResponse { success }
success?: boolean

Delete a task

import _0ct from '0ct';

const client = new _0ct({
  apiKey: process.env['0CT_API_KEY'], // This is the default and can be omitted
});

const task = await client.promptly.tasks.delete('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');

console.log(task.success);
{
  "success": true
}
Returns Examples
{
  "success": true
}