Change an assignment's message
Change an assignment's message
To update a task assignment's message call the
PUT /tasks/:task_id/assignments
API, and
include the new message
for the task assignment.
Java
String assignmentID = "12345";
BoxTaskAssignment taskAssignment = new BoxTaskAssignment(api, assignmentID);
BoxTaskAssignment.Info info = taskAssignment.getInfo();
info.setMessage("Please review the meeting notes");
taskAssignment.updateInfo(info);
Python
updated_task = {'message': 'new message'}
updated_assignment = client.task_assignment(assignment_id='12345').update_info(data=updated_task)
print(f'Assignment ID is {updated_assignment.id} and message is {updated_task.message}')
.NET
var requestParams = new BoxTaskAssignmentUpdateRequest()
{
Id = "12345",
Message = "Updated message"
};
BoxTaskAssignment updatedAssignment = await client.TasksManager.UpdateTaskAssignmentAsync(requestParams);
Node
// Update the task assignment message
client.tasks.updateAssignment(
'12345',
{
message: 'This needs some more changes'
})
.then(assignment => {
// ...
});