The Get Task utility allows you to retrieve information about the current task or specific tasks in your Lindy workflow. This is useful for accessing task metadata, status, and related information.
Get Task is a utility that provides access to task-related information within your Lindy workflows. It can retrieve details about the current task being executed or fetch information about other tasks in your system.
// Get information about the current taskconst currentTask = await getTask();// Access task propertiesconsole.log(currentTask.id);console.log(currentTask.status);console.log(currentTask.createdAt);
// Get a specific task by IDconst task = await getTask({ taskId: "task_123456"});// Get tasks with filtersconst tasks = await getTask({ status: "completed", limit: 10});
// Store task information in memory for later useconst task = await getTask();await setVariable("lastTaskId", task.id);await setVariable("lastTaskStatus", task.status);