I'm creating an inbox replacement to deal with the massive number of asyncrollout messages we get. Unfortunately the url the existing inbox uses,. /libs/granite/taskmanager/updatetask , looks like it's restricted to what can call it and throws a 403 Forbidden when called outside of the AEM inboxes. Are there any APIs to modify the status of a task in the same way there are ones to modify a workflow? Anything I can do to open up access to the taskmanager calls?
Instead of directly accessing the /libs/granite/taskmanager/updatetask URL, you can use the TaskManager API provided by AEM.
Task task = taskManager.getTask(taskId);
if (task != null) {
// Update the task's state
task.setState(newState);
// Save the changes
taskManager.updateTask(task);
}
Does AEM provide an actual implementation of the TaskManager API out of the box? All I can see is the interface. Anyway our answer ended up being to just write a servlet to change a task's status.