io.enterpriseai.resources.SchedulesClient
Source: sdks/java/enterprise-ai-java/src/main/java/io/enterpriseai/resources/SchedulesClient.java. Back to the Java SDK reference index.
This page is generated by tools/docs/gen_sdk_reference.py from the SDK sources and the OpenAPI text folders. Do not edit it by hand: change the source and regenerate.
Class SchedulesClient
Cron schedules (Temporal backed).
Constructor SchedulesClient
SchedulesClient(Transport transport)
Creates the client on the shared transport; EnterpriseAIClient builds it and exposes it through the accessor of the same name.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
transport | Transport | yes | Transport shared by the sub-clients of one client. |
SchedulesClient.create
JsonNode create(Object body)
Create a schedule. Schedules runs of an agent from a cron expression evaluated in a time zone; the first next_run_at is computed (422 invalid_cron). When Temporal is configured the schedule is created there (503 scheduler_unavailable on failure). Needs tenant_admin, developer or application_owner. 404 agent_not_found. Audited as schedule.create.
Route: /v1/schedules (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
body | Object | yes | Agent, cron expression, time zone, run input and enabled flag. |
Returns: JsonNode. Decoded JSON answer of the operation "Create a schedule".
Raises: the typed errors of the transport (Errors).
SchedulesClient.create
JsonNode create(Object body, RequestOptions options)
Create a schedule. Schedules runs of an agent from a cron expression evaluated in a time zone; the first next_run_at is computed (422 invalid_cron). When Temporal is configured the schedule is created there (503 scheduler_unavailable on failure). Needs tenant_admin, developer or application_owner. 404 agent_not_found. Audited as schedule.create.
Route: /v1/schedules (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
body | Object | yes | Agent, cron expression, time zone, run input and enabled flag. | |
options | RequestOptions | yes | Per call options (idempotency key, traceparent, headers, abort signal). |
Returns: JsonNode. Decoded JSON answer of the operation "Create a schedule".
Raises: the typed errors of the transport (Errors).
SchedulesClient.delete
void delete(String id)
Delete a schedule. Deletes the schedule; no new run is started by it. Needs tenant_admin, developer or application_owner. When the schedule is held by Temporal, it is deleted there too (503 scheduler_unavailable if Temporal cannot be reached). 404 schedule_not_found. Audited as schedule.delete.
Route: /v1/schedules/{schedule_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
id | String | yes | Identifier (UUID) of the schedule. |
Returns: void.
Raises: the typed errors of the transport (Errors).
SchedulesClient.list
Page<JsonNode> list()
List the schedules. Cron schedules of the tenant, oldest first, optionally for one agent. One page only.
Route: /v1/schedules (GET).
This element takes no parameter.
Returns: Page<JsonNode>. A Page: One page of a cursor paginated collection ({"items": [...], "next_cursor": "..."|null}).
Raises: the typed errors of the transport (Errors).
SchedulesClient.list
Page<JsonNode> list(Map<String, ?> query)
List the schedules. Cron schedules of the tenant, oldest first, optionally for one agent. One page only.
Route: /v1/schedules (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
query | Map<String, ?> | yes | Query string parameters of the route. |
Returns: Page<JsonNode>. A Page: One page of a cursor paginated collection ({"items": [...], "next_cursor": "..."|null}).
Raises: the typed errors of the transport (Errors).
SchedulesClient.update
JsonNode update(String id, Object body)
Update a schedule. Changes the cron expression, time zone, input or enabled flag. The next run time is computed again (422 invalid_cron for a bad expression or time zone) and the Temporal schedule is updated when Temporal holds it (503 scheduler_unavailable). Needs tenant_admin, developer or application_owner. Audited as schedule.update.
Route: /v1/schedules/{schedule_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
id | String | yes | Identifier (UUID) of the schedule. | |
body | Object | yes | Fields to change; the omitted ones are kept. |
Returns: JsonNode. Decoded JSON answer of the operation "Update a schedule".
Raises: the typed errors of the transport (Errors).
SchedulesClient.update
JsonNode update(String id, Object body, RequestOptions options)
Update a schedule. Changes the cron expression, time zone, input or enabled flag. The next run time is computed again (422 invalid_cron for a bad expression or time zone) and the Temporal schedule is updated when Temporal holds it (503 scheduler_unavailable). Needs tenant_admin, developer or application_owner. Audited as schedule.update.
Route: /v1/schedules/{schedule_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
id | String | yes | Identifier (UUID) of the schedule. | |
body | Object | yes | Fields to change; the omitted ones are kept. | |
options | RequestOptions | yes | Per call options (idempotency key, traceparent, headers, abort signal). |
Returns: JsonNode. Decoded JSON answer of the operation "Update a schedule".
Raises: the typed errors of the transport (Errors).