Replaying from the UI

1

Click the Replay button in the top right

Select a task, then in the bottom right
click "Replay"
2

Confirm replay settings

You can edit the payload (if available) and choose the environment to replay the run in.Select a task, then in the bottom right
click "Replay"

Replaying using the SDK

You can replay a run using the SDK:
const replayedRun = await runs.replay(run.id);
When you call trigger() or batchTrigger() on a task you receive back a run handle which has an id property. You can use that id to replay the run. You can also access the run id from inside a run. You could write this to your database and then replay it later.
export const simpleChildTask = task({
  id: "simple-child-task",
  run: async (payload, { ctx }) => {
    // the run ID (and other useful info) is in ctx
    const runId = ctx.run.id;
  },
});

Bulk replaying

See Bulk actions for more information.