Skip to main content
Glama

create_scheduled_task

Schedule JavaScript tasks on an iPhone using Cron expressions or fixed millisecond intervals, supporting single scripts or ESM packages exported as onSchedule(input).

Instructions

Creates a locally stored Cron or millisecond-interval JavaScript task. Use script_type=single with script for one file, or script_type=package with script_package for a validated ESM package. Packages must export onSchedule(input) from their manifest entry. Interval values must be 250..86400000 ms. It is enabled by default unless enabled=false is provided.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesTask name
scriptYesJavaScript source for a single task, or the entry source compatibility field for a package
enabledNoWhether the task starts enabled; defaults to true
cron_exprNoFive-field Cron expression; required for schedule_type=cron
interval_msNoFixed interval in milliseconds; required for schedule_type=interval
script_typeNoWhether the task uses one script file or an ESM script packagesingle
schedule_typeNoCron or fixed interval schedulingcron
script_packageNoComplete ESM package used when script_type=package

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.3/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and discloses several runtime behaviors: tasks are locally stored, enabled by default unless enabled=false, packages must export onSchedule(input), and interval bounds (250..86400000 ms). It does not describe permissions or sandboxing beyond the manifest object in the schema, leaving some operational context uncovered.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the main action, then branches into mode-specific rules and defaults in a logical order. It is a bit dense with multiple independent constraints packed into four sentences, but every sentence adds a distinct constraint.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter tool with a rich nested schema and no output schema, the description covers the critical creation-time constraints and mode branches. It omits some higher-level context like where tasks execute or how scheduled runs are observed, but those are arguably outside the scope of a create tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is already 100%, so the schema documents all 8 parameters. The description adds cross-parameter logic: script_type=single pairs with script, script_type=package pairs with script_package, and the onSchedule(input) export requirement for packages. This meaningfully supplements the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Creates a locally stored Cron or millisecond-interval JavaScript task.' It distinguishes itself from siblings like update_scheduled_task and list_scheduled_tasks by naming the exact creation action and execution model.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It clearly explains when to use each script_type mode and the schedule variants, but does not explicitly point to alternative tools for editing, enabling, or deleting tasks. The usage context for creation is well covered.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.