Added function to get the progress of a task in the apiquery