Skip to content

kindgi schedules

View as Markdown

Synopsis

Terminal window
kindgi schedules <command>
Signature

Run agents and flows on a schedule: create, list, get, update, pause, resume, run-now, fires, versions, take-ownership, unregister.

Commands

Command Description
kindgi schedules list List schedules.
kindgi schedules get Fetch a schedule as it is now, with its next occurrences when asked, or the version given.
kindgi schedules create Run an agent or a flow on a schedule, or start Improve runs on an agent (--improve).
kindgi schedules update Change a schedule: when it runs, what it runs, its policies, or the tools its runs may call unattended.
kindgi schedules pause Pause a schedule: it stops running until resumed.
kindgi schedules resume Resume a paused schedule from its next occurrence (the paused ones are not run).
kindgi schedules run-now Run a schedule now, outside its schedule (its next occurrence is unchanged).
kindgi schedules fires A schedule's history, newest first: each time it fired, the run it started, or why it was skipped, refused or failed.
kindgi schedules versions List a schedule's versions, newest first: when each was made, by whom, and why.
kindgi schedules take-ownership Become a schedule's owner, so its runs act as you from the next run that starts: for a schedule whose owner left, or to make it shared (--run-as=project, the project's own account becomes the owner; --run-as=<service-account-id>, that service account) or yours.
kindgi schedules unregister Remove a schedule: it stops running.

See also

Synopsis

Terminal window
kindgi schedules list [--project=<project-id>] [--status=active|paused] [--limit=<n>] [--cursor=<c>]
Signature

List schedules.

Options

Option Default Description
--cursor <value> none Resume after this cursor, from the previous page's nextCursor.
--limit <value> 25 (at most 100) The most to return (default 25, at most 100).
--project <value> none Only this project's schedules.
--status <value> none Only active or only paused schedules.

Every command also takes the global flags.

Examples

From Run on a schedule:

Terminal window
pnpm exec kindgi schedules list --status=active
pnpm exec kindgi schedules list --project=<project-id>

See also

Synopsis

Terminal window
kindgi schedules get <schedule-id> [<version>] [--upcoming=<n>]
Signature

Fetch a schedule as it is now, with its next occurrences when asked, or the version given.

Options

Option Default Description
--upcoming <value> none Also show the next N times it runs (1 to 20).

Every command also takes the global flags.

Examples

Fetch a schedule with its next five run times.

Terminal window
kindgi schedules get <schedule-id> --upcoming=5

Fetch version 2 of a schedule: what it ran, as whom, and when.

Terminal window
kindgi schedules get <schedule-id> 2

From Run on a schedule:

Terminal window
pnpm exec kindgi schedules get <schedule-id> --upcoming=3
pnpm exec kindgi schedules get <schedule-id> <version>

See also

Synopsis

Terminal window
kindgi schedules create --cron=<expr> (--agent=<id> [--agent-version=<v>] | --flow=<id> --flow-version=<v> | --improve=<agent-id> --project=<id> [--segment=<key:value>]…) [--timezone=<tz>] [--input=<json-or-@file>] [--project=<project-id>] [--catch-up=latest|skip] [--overlap=skip|allow] [--starting-deadline=<s>] [--label=<text>] [--run-as=<service-account-id>|project] [--allow-unattended=<tool-id>]…
Signature

Run an agent or a flow on a schedule, or start Improve runs on an agent (--improve). It's personal: its runs act as you, and only you or a project admin can change it. With --run-as=project, it's shared and acts as the project's own account; with --run-as=<service-account-id>, as that service account. Who it acts as is checked again at every run; its runs are in your project's runs, naming the schedule.

Options

Option Default Description
--agent <value> none Run this agent (at its live version, else the latest).
--agent-version <value> none With --agent: run this exact version.
--allow-unattended <value> none (a tool that waits for a person still waits) A tool, by id, whose calls in this schedule's runs needn't wait for a person's yes, though the tool asks for one when no person started the run (repeatable; only tools its agent or flow calls, no wildcard). Needs admin on the schedule's project. The tenant's and the agent's approval rules still apply. Repeatable.
--catch-up <value> latest After a gap (the runtime was down): latest runs once for the latest missed time (default); skip drops them.
--cron <value> required A cron expression: 0 7 * * 1-5 (07:00 on weekdays), @daily, …
--flow <value> none Run this flow (with --flow-version).
--flow-version <value> none With --flow: the flow version to run.
--improve <value> none Start Improve runs on this agent (instead of running it), when enough new corrections marking answers wrong have come in: for the project (--project), or a segment of it (--segment). --input takes the Improve options, threshold and monthlyCapUsd.
--input <value> {} The input each run gets, as JSON or @<file>. An agent needs {"userMessage": "…"}; a flow takes its own input (default {}); --improve takes its Improve options ({"tiers": ["settings"], "threshold": {"judgments": 5, "runs": 3, "judges": 2}, "monthlyCapUsd": 20}, the defaults).
--label <value> none A short label.
--overlap <value> skip While the previous run is still going: skip (default) or allow another run.
--project <value> the tenant's Default project The schedule's project, by id (default: the tenant's Default project).
--run-as <value> none (you own the schedule) A service account, by id, or project: the schedule's owner, so its runs act as that account from the next run that starts (not as you). project runs it as the project's own account, made the first time, and takes admin on the project. The project's own account runs only what the project's editors can. A named account takes act_as, and needs a role that runs what the schedule runs (editor on the target's project). Omit it to own the schedule yourself.
--segment <value> none With --improve and --project: a segment of the project, key:value; repeat it in order, coarse to fine. Repeatable.
--starting-deadline <value> 600 (seconds) Seconds a run may start late and still count as on time (default 600).
--timezone <value> UTC An IANA timezone, such as America/Toronto (default UTC).

Every command also takes the global flags.

Examples

From Run on a schedule:

Terminal window
pnpm exec kindgi schedules create --agent=acme.order-desk --cron="0 7 * * 1-5" --timezone=America/Toronto \
pnpm exec kindgi schedules create --cron="0 3 * * *" --improve=acme.rank.scorer --project=<project-id> --segment=company:acme \

See also

Synopsis

Terminal window
kindgi schedules update <schedule-id> [--cron=<expr>] [--timezone=<tz>] [--input=<json-or-@file>] [--agent=<id> [--agent-version=<v>] | --flow=<id> --flow-version=<v> | --improve=<agent-id> --project=<id> [--segment=<key:value>]…] [--catch-up=…] [--overlap=…] [--starting-deadline=<s>] [--label=<text>] [--allow-unattended=<tool-id>|none]…
Signature

Change a schedule: when it runs, what it runs, its policies, or the tools its runs may call unattended. A flag left out keeps the schedule's value.

Options

Option Default Description
--agent <value> unchanged Run this agent (at its live version, else the latest).
--agent-version <value> unchanged With --agent: run this exact version.
--allow-unattended <value> unchanged; a schedule that has a list and moves to another flow or agent must name it again, or none A tool, by id, whose calls in this schedule's runs needn't wait for a person's yes, though the tool asks for one when no person started the run (repeatable; only tools its agent or flow calls, no wildcard). Needs admin on the schedule's project. The tenant's and the agent's approval rules still apply. Replaces the list; none clears it; left out, the list is kept, and a new --agent or --flow must name it again (or none). Repeatable.
--catch-up <value> unchanged After a gap (the runtime was down): latest runs once for the latest missed time; skip drops them.
--cron <value> unchanged A new cron expression: 0 7 * * 1-5 (07:00 on weekdays), @daily, …
--flow <value> unchanged Run this flow (with --flow-version).
--flow-version <value> unchanged With --flow: the flow version to run.
--improve <value> unchanged Start Improve runs on this agent (instead of running it), when enough new corrections marking answers wrong have come in: for the project (--project), or a segment of it (--segment). --input takes the Improve options, threshold and monthlyCapUsd.
--input <value> unchanged The input each run gets from now on, as JSON or @<file>. An agent needs {"userMessage": "…"}; a flow takes its own input; --improve takes its Improve options.
--label <value> unchanged A new short label.
--overlap <value> unchanged While the previous run is still going: skip or allow another run.
--project <value> unchanged With --improve: the scope's project (the schedule's own).
--segment <value> none With --improve and --project: a segment of the project, key:value; repeat it in order, coarse to fine. Repeatable.
--starting-deadline <value> unchanged Seconds a run may start late and still count as on time.
--timezone <value> unchanged A new IANA timezone, such as America/Toronto.

Every command also takes the global flags.

Examples

Move a schedule to 08:00 on weekdays.

Terminal window
kindgi schedules update <schedule-id> --cron="0 8 * * 1-5"

Run an agent version on a schedule, and skip overlapping runs.

Terminal window
kindgi schedules update <schedule-id> --agent=acme.order-desk --agent-version=0.2.0 --overlap=skip

From Ask before a tool runs:

Terminal window
pnpm exec kindgi schedules update <schedule-id> --allow-unattended=acme-ops.post-update

From Run on a schedule:

Terminal window
pnpm exec kindgi schedules update <schedule-id> --input='{"tiers": ["settings"], "threshold": {"judgments": 5, "runs": 3, "judges": 1}, "monthlyCapUsd": 20}'

See also

Synopsis

Terminal window
kindgi schedules pause <schedule-id>
Signature

Pause a schedule: it stops running until resumed.

Options

Every command also takes the global flags.

Examples

Pause a schedule.

Terminal window
kindgi schedules pause <schedule-id>

See also

Synopsis

Terminal window
kindgi schedules resume <schedule-id>
Signature

Resume a paused schedule from its next occurrence (the paused ones are not run).

Options

Every command also takes the global flags.

Examples

Resume a paused schedule.

Terminal window
kindgi schedules resume <schedule-id>

See also

Synopsis

Terminal window
kindgi schedules run-now <schedule-id>
Signature

Run a schedule now, outside its schedule (its next occurrence is unchanged).

Options

Every command also takes the global flags.

Examples

Run a schedule now, outside its times.

Terminal window
kindgi schedules run-now <schedule-id>

See also

Synopsis

Terminal window
kindgi schedules fires <schedule-id> [--limit=<n>] [--cursor=<c>]
Signature

A schedule's history, newest first: each time it fired, the run it started, or why it was skipped, refused or failed.

Options

Option Default Description
--cursor <value> none Resume after this cursor, from the previous page's nextCursor.
--limit <value> 25 (at most 100) The most to return (default 25, at most 100).

Every command also takes the global flags.

Examples

From Run on a schedule:

Terminal window
pnpm exec kindgi schedules fires <schedule-id> --table

See also

Synopsis

Terminal window
kindgi schedules versions <schedule-id> [--limit=<n>] [--cursor=<c>]
Signature

List a schedule's versions, newest first: when each was made, by whom, and why. kindgi schedules get <schedule-id> <version> shows one.

Options

Option Default Description
--cursor <value> none Resume after this cursor, from the previous page's nextCursor.
--limit <value> 25 (at most 100) The most to return (default 25, at most 100).

Every command also takes the global flags.

Examples

List a schedule's versions as a table: when each was made, by whom, and why.

Terminal window
kindgi schedules versions <schedule-id> --table

From Run on a schedule:

Terminal window
pnpm exec kindgi schedules versions <schedule-id> --table

See also

Synopsis

Terminal window
kindgi schedules take-ownership <schedule-id> [--run-as=<service-account-id>|project]
Signature

Become a schedule's owner, so its runs act as you from the next run that starts: for a schedule whose owner left, or to make it shared (--run-as=project, the project's own account becomes the owner; --run-as=<service-account-id>, that service account) or yours. Takes a project admin.

Options

Option Default Description
--run-as <value> none (you own the schedule) A service account, by id, or project: the schedule's owner, so its runs act as that account from the next run that starts (not as you). project runs it as the project's own account, made the first time, and takes admin on the project. The project's own account runs only what the project's editors can. A named account takes act_as, and needs a role that runs what the schedule runs (editor on the target's project). Omit it to own the schedule yourself.

Every command also takes the global flags.

Examples

Take over a schedule whose owner left.

Terminal window
kindgi schedules take-ownership <schedule-id>

See also

Synopsis

Terminal window
kindgi schedules unregister <schedule-id>
Signature

Remove a schedule: it stops running.

Options

Every command also takes the global flags.

Examples

Remove a schedule.

Terminal window
kindgi schedules unregister <schedule-id>

See also