diff --git a/typescript/schedules.md b/typescript/schedules.md index afceb52..2b2b572 100644 --- a/typescript/schedules.md +++ b/typescript/schedules.md @@ -17,7 +17,7 @@ import { myWorkflow } from './workflows' const client = new ScheduleClient() const schedule = await client.create({ - id: 'biz-id', + id: 'schedule-biz-id', spec: { // every hour at minute 5 interval: { @@ -41,7 +41,7 @@ const schedule = await client.create({ action: { startWorkflow: { // type: WorkflowStartOptions & { workflowId: string } - workflowId: 'biz-id', + workflowId: 'wf-biz-id', type: myWorkflow, args: ['sorry this is the only thing reused, chad 😄'], // ... other WorkflowOptions @@ -73,6 +73,8 @@ const schedule = await client.create({ searchAttributes, }) +const schedule = await client.getHandle('schedule-biz-id') + const scheduleDescription = await schedule.describe() const matchingStartTimes = await schedule.listMatchingTimes({ start: new Date(), end: new Date() })