Python SDKFeature Clients

Crons ClientPython SDK

Bases: BaseRestClient

The cron client is a client for managing cron workflows within Hatchet.

Methods:

NameDescription
aio_createCreate a new workflow cron trigger.
aio_deleteDelete a workflow cron trigger.
aio_getRetrieve a specific workflow cron trigger by ID.
aio_listRetrieve a list of all workflow cron triggers matching the criteria.
createCreate a new workflow cron trigger.
deleteDelete a workflow cron trigger.
getRetrieve a specific workflow cron trigger by ID.
listRetrieve a list of all workflow cron triggers matching the criteria.

Functions

aio_create

Create a new workflow cron trigger.

Parameters:

NameTypeDescriptionDefault
workflow_namestrThe name of the workflow to trigger.required
cron_namestrThe name of the cron trigger.required
expressionstrThe cron expression defining the schedule.required
inputJSONSerializableMappingThe input data for the cron workflow.required
additional_metadataJSONSerializableMappingAdditional metadata associated with the cron trigger.required
priorityLiteral['LOW', 'MEDIUM', 'HIGH'] | NoneThe priority of the cron workflow trigger.None

Returns:

TypeDescription
CronTriggerThe created cron trigger.

aio_delete

Delete a workflow cron trigger.

Parameters:

NameTypeDescriptionDefault
cron_idstrThe ID of the cron trigger to delete.required

Returns:

TypeDescription
NoneNone

aio_get

Retrieve a specific workflow cron trigger by ID.

Parameters:

NameTypeDescriptionDefault
cron_idstrThe ID of the cron trigger to retrieve.required

Returns:

TypeDescription
CronTriggerThe requested cron trigger.

aio_list

Retrieve a list of all workflow cron triggers matching the criteria.

Parameters:

NameTypeDescriptionDefault
offsetint | NoneThe offset to start the list from.None
limitint | NoneThe maximum number of items to return.None
workflow_idstr | NoneThe ID of the workflow to filter by.None
additional_metadataJSONSerializableMapping | NoneFilter by additional metadata keys.None
order_by_fieldLiteral['name', 'created_at'] | NoneThe field to order the list by.None
order_by_directionLiteral['asc', 'desc'] | NoneThe direction to order the list by.None
workflow_namestr | NoneThe name of the workflow to filter by.None
cron_namestr | NoneThe name of the cron trigger to filter by.None

Returns:

TypeDescription
list[CronTrigger]A list of cron triggers.

create

Create a new workflow cron trigger.

Parameters:

NameTypeDescriptionDefault
workflow_namestrThe name of the workflow to trigger.required
cron_namestrThe name of the cron trigger.required
expressionstrThe cron expression defining the schedule.required
inputJSONSerializableMappingThe input data for the cron workflow.required
additional_metadataJSONSerializableMappingAdditional metadata associated with the cron trigger.required
priorityLiteral['LOW', 'MEDIUM', 'HIGH'] | NoneThe priority of the cron workflow trigger.None

Returns:

TypeDescription
CronTriggerThe created cron trigger.

delete

Delete a workflow cron trigger.

Parameters:

NameTypeDescriptionDefault
cron_idstrThe ID of the cron trigger to delete.required

Returns:

TypeDescription
NoneNone

get

Retrieve a specific workflow cron trigger by ID.

Parameters:

NameTypeDescriptionDefault
cron_idstrThe ID of the cron trigger to retrieve.required

Returns:

TypeDescription
CronTriggerThe requested cron trigger.

list

Retrieve a list of all workflow cron triggers matching the criteria.

Parameters:

NameTypeDescriptionDefault
offsetint | NoneThe offset to start the list from.None
limitint | NoneThe maximum number of items to return.None
workflow_idstr | NoneThe ID of the workflow to filter by.None
additional_metadataJSONSerializableMapping | NoneFilter by additional metadata keys.None
order_by_fieldLiteral['name', 'created_at'] | NoneThe field to order the list by.None
order_by_directionLiteral['asc', 'desc'] | NoneThe direction to order the list by.None
workflow_namestr | NoneThe name of the workflow to filter by.None
cron_namestr | NoneThe name of the cron trigger to filter by.None

Returns:

TypeDescription
list[CronTrigger]A list of cron triggers.

Last updated on November 13, 2026

On this page