- Introduction
- Logging and tracing
- Errors & Retrying
Wait
- Concurrency & Queues
- Versioning
- Machines
- Idempotency
- Reattempting & Replaying
- Notifications
Runs API
Schedules API
Writing tasks
API reference
List Schedules
List all schedules.
Use your Secret API key in the form 'Bearer <SECRET KEY>' (without the quotation marks)
Page number of the schedule listing
Number of schedules per page
curl --request GET \
--url https://api.trigger.dev/api/v1/schedules \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"id": "sched_1234",
"task": "my-scheduled-task",
"active": true,
"deduplicationKey": "dedup_key_1234",
"externalId": "user_1234",
"generator": {
"type": "CRON",
"expression": "0 0 * * *",
"description": "Every day at midnight"
},
"nextRun": "2024-04-01T00:00:00Z",
"environments": [
{
"id": "<string>",
"type": "<string>",
"userName": "<string>"
}
]
}
],
"pagination": {
"currentPage": 123,
"totalPages": 123,
"count": 123
}
}
Authorizations
Use your Secret API key in the form 'Bearer <SECRET KEY>' (without the quotation marks)
Query Parameters
Page number of the schedule listing
Number of schedules per page
Response
The unique ID of the schedule, prefixed with 'sched_'
The id of the scheduled task that will be triggered by this schedule
Whether the schedule is active or not
The deduplication key used to prevent creating duplicate schedules
The external ID of the schedule. Can be anything that is useful to you (e.g., user ID, org ID, etc.)
CRON
The cron expression used to generate the schedule
The description of the generator in plain english
The next time the schedule will run
Was this page helpful?
curl --request GET \
--url https://api.trigger.dev/api/v1/schedules \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"id": "sched_1234",
"task": "my-scheduled-task",
"active": true,
"deduplicationKey": "dedup_key_1234",
"externalId": "user_1234",
"generator": {
"type": "CRON",
"expression": "0 0 * * *",
"description": "Every day at midnight"
},
"nextRun": "2024-04-01T00:00:00Z",
"environments": [
{
"id": "<string>",
"type": "<string>",
"userName": "<string>"
}
]
}
],
"pagination": {
"currentPage": 123,
"totalPages": 123,
"count": 123
}
}