updateSchedule
Change a schedule
Change a schedule: switch it on or off, or change its skill, time, time zone or time limit. Send only the fields to change. Confirm the change with the person first.
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
name | string | required | The schedule name: lowercase letters, digits and hyphens, for example coaching-posts-mon-6pm. |
skill | string | optional | The skill to run, by its name as in the Skill Library, for example weekly-report. |
when | string | optional | When it runs, as a five-part cron expression read in the schedule time zone: minute hour day-of-month month day-of-week. 0 18 * * 4 is Thursdays at 18:00; 0 9 * * 1-5 is weekdays at 09:00. |
timezone | string | optional | IANA time zone, for example Europe/London or UTC. The schedule follows summer time in that zone. |
enabled | boolean | optional | true switches it on, false switches it off. |
timeoutMinutes | integer | optional | Time limit for one run, in minutes. Leave it out to use the limit in the skill itself (else 5). |
Scopes
schedules:manage
Annotations
- Read only: no
- Destructive: no
When to use
Call updateSchedule to pause a schedule (enabled: false), restart it (enabled: true), or change when or how it runs. Confirm the change with the person first.
The schedule tools need the schedules:manage scope. Only admin and staff can hold it. Schedules belong to the whole organisation: every admin and staff user sees and changes the same list, which also shows in the Sasha web interface, in Menu → Tasks.
name (required) picks the schedule. Send only the fields that change: skill, when, timezone, enabled and timeoutMinutes, with the same rules as in createSchedule. A new timezone changes how the existing when is read. To rename a schedule, add a new one and delete the old one.
The result is the schedule after the change, with the fields that listSchedules returns.
Example
{ "name": "client-digest-thu-6pm", "enabled": false }
The structured result (structuredContent):
{
"name": "client-digest-thu-6pm",
"skill": "weekly-client-digest",
"when": "0 18 * * 4",
"timezone": "Europe/London",
"enabled": false,
"timeoutMinutes": 15,
"nextRunAt": null,
"lastRunAt": null,
"lastStatus": null,
"lastError": null
}
Refusals and what to do
A schedule tool refuses with an error result. Its text is Error in updateSchedule: <code>: <reason>.
schedule_not_found: no schedule has this name. CalllistSchedules.skill_not_found,unknown_time_zoneandinvalid_schedule: as increateSchedule.- If the connection does not hold
schedules:manage, the tool is not in your tool list, and a call to it returnsMCP error -32602: Tool updateSchedule not found. Only admin and staff can hold the scope, so a member's connection never has the schedule tools. A connection approved before the scope existed must reconnect, or the person mints a new token. Read thepermissionssection ofgetDocs. - Arguments that do not match the schema are refused before the tool runs, for example a
namewith capital letters or spaces, or an extra argument. internal:unexpected (request <id>): something failed inside Sasha. Quote the request id insuggestImprovement.
Related
listScheduleslists the schedules and their last result.createScheduleadds a schedule.updateSchedulechanges, pauses or restarts a schedule.deleteScheduleremoves a schedule.runScheduleruns a schedule once now.getDocshas aschedulessection with the same rules.