Lists all of the assignments for a given task.
This operation is performed by calling function getTaskAssignments.
See the endpoint docs at API Reference.
await client.taskAssignments.getTaskAssignments(task.id!);
string
GetTaskAssignmentsOptionalsInputThis function returns a value of type TaskAssignments.
Returns a collection of task assignment defining what task on a file has been assigned to which users and by who.
Assigns a task to a user.
A task can be assigned to more than one user by creating multiple assignments.
This operation is performed by calling function createTaskAssignment.
See the endpoint docs at API Reference.
await client.taskAssignments.createTaskAssignment({
task: new CreateTaskAssignmentRequestBodyTaskField({
type: 'task' as CreateTaskAssignmentRequestBodyTaskTypeField,
id: task.id!,
}),
assignTo: {
id: currentUser.id,
} satisfies CreateTaskAssignmentRequestBodyAssignToField,
} satisfies CreateTaskAssignmentRequestBody);
CreateTaskAssignmentRequestBody
CreateTaskAssignmentOptionalsInputThis function returns a value of type TaskAssignment.
Returns a new task assignment object.
Retrieves information about a task assignment.
This operation is performed by calling function getTaskAssignmentById.
See the endpoint docs at API Reference.
await client.taskAssignments.getTaskAssignmentById(taskAssignment.id!);
string
GetTaskAssignmentByIdOptionalsInputThis function returns a value of type TaskAssignment.
Returns a task assignment, specifying who the task has been assigned to and by whom.
Updates a task assignment. This endpoint can be used to update the state of a task assigned to a user.
This operation is performed by calling function updateTaskAssignmentById.
See the endpoint docs at API Reference.
await client.taskAssignments.updateTaskAssignmentById(taskAssignment.id!, {
requestBody: {
message: 'updated message',
resolutionState:
'approved' as UpdateTaskAssignmentByIdRequestBodyResolutionStateField,
} satisfies UpdateTaskAssignmentByIdRequestBody,
} satisfies UpdateTaskAssignmentByIdOptionalsInput);
string
UpdateTaskAssignmentByIdOptionalsInputThis function returns a value of type TaskAssignment.
Returns the updated task assignment object.
Deletes a specific task assignment.
This operation is performed by calling function deleteTaskAssignmentById.
See the endpoint docs at API Reference.
await client.taskAssignments.deleteTaskAssignmentById(taskAssignment.id!);
string
DeleteTaskAssignmentByIdOptionalsInputThis function returns a value of type undefined.
Returns an empty response when the task assignment was successfully deleted.