docs/context.mdx
Context (ctx) is a way to get information about a run.
import { task } from "@trigger.dev/sdk";
export const parentTask = task({
id: "parent-task",
run: async (payload: { message: string }, { ctx }) => {
if (ctx.environment.type === "DEVELOPMENT") {
return;
}
},
});