# TriggerSchedule

Represents a trigger schedule.

- Source: [`lib/triggers/trigger-options.ts`](https://github.com/aws/aws-cdk/blob/v2.274.0-alpha.0/packages/@aws-cdk/aws-glue-alpha/lib/triggers/trigger-options.ts#L135)
- Type last changed: v2.270.0-alpha.0 · 18 Sep 2026

## Example

```ts
import * as cdk from 'aws-cdk-lib';
import * as iam from 'aws-cdk-lib/aws-iam';
declare const stack: cdk.Stack;
declare const role: iam.IRole;
declare const script: glue.Code;
const job = new glue.PySparkEtlJob(stack, 'Job', { role, script });
const workflow = new glue.Workflow(stack, 'Workflow');

workflow.addScheduledTrigger('WeeklyTrigger', {
  actions: [glue.Action.job(job)],
  schedule: glue.TriggerSchedule.weekly(),
});
```

## Properties

- `expressionString`: string (required) — The expression string for the schedule.

## Methods

- `cron(options: CronOptions): TriggerSchedule // chainable` (static) — Creates a new TriggerSchedule instance with a cron expression.

  **Parameters**

  - `options` — The cron options for the schedule.

  **Returns:** A new TriggerSchedule instance.

- `daily(): TriggerSchedule // chainable` (static) — Creates a schedule that fires once a day, at midnight UTC.

  **Returns:** A new TriggerSchedule instance.

- `expression(expression: string): TriggerSchedule // chainable` (static) — Creates a new TriggerSchedule instance with a custom expression.

  **Parameters**

  - `expression` — The custom expression for the schedule.

  **Returns:** A new TriggerSchedule instance.

- `weekly(): TriggerSchedule // chainable` (static) — Creates a schedule that fires once a week, at midnight UTC on Sunday.

  **Returns:** A new TriggerSchedule instance.
