Find the list of tasks and their status using tickscript


I know there is an HTTP API for getting task details. Is there any way I can access the same information in tick script? As I want to store that information in influxdb?
Is there any other way I can save the same information like task name, status and other details in influxdb?