packages/serverpod/skills/serverpod-scheduling/SKILL.md
Schedule future work in Serverpod — FutureCall, callWithDelay, callAtTime, recurring tasks, cancellation. Use when scheduling one-off or recurring tasks.
npx skillsauth add serverpod/serverpod serverpod-schedulingInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Future calls run at a specified time, are stored in the database, and survive restarts. Each call is claimed for one execution across the cluster. Future calls require database support; execution is started by monolith/maintenance roles, not serverless role.
class ExampleFutureCall extends FutureCall {
Future<void> doWork(Session session) async {
// Work here.
}
Future<void> doOtherWork(Session session, MyModel data) async {
// Work with data.
}
}
Run serverpod generate for the type-safe API on pod.futureCalls.
The same parameters as for endpoint methods are supported:
bool, int, double, StringDuration, DateTime (UTC), ByteData, UuidValue, Uri, BigInt.spy.yaml)List, Map, Set, Record — strictly typed with the above// Delay
await pod.futureCalls
.callWithDelay(const Duration(hours: 1))
.example.doWork();
// At specific time (UTC)
await pod.futureCalls
.callAtTime(DateTime.utc(2026, 1, 1))
.example.doOtherWork(myModel);
// With identifier (for cancellation)
await pod.futureCalls
.callWithDelay(const Duration(hours: 1), identifier: 'my-job-id')
.example.doWork();
// Recurring task from `Duration` interval with an optional start time
await pod.futureCalls
.callRecurring()
.every(const Duration(hours: 1), start: DateTime.now())
.example.doWork();
// Recurring task from `cron` expression
await pod.futureCalls
.callRecurring()
.cron("0 * * * *")
.example.doWork();
await pod.futureCalls.cancel('my-job-id'); // Cancels all with that identifier
Handle failures inside the call and reschedule if the work must eventually succeed.
futureCallExecutionEnabled: true # SERVERPOD_FUTURE_CALL_EXECUTION_ENABLED
futureCall:
concurrencyLimit: 5 # SERVERPOD_FUTURE_CALL_CONCURRENCY_LIMIT (default 1, <1 maps to unlimited and is not recommended)
scanInterval: 2000 # SERVERPOD_FUTURE_CALL_SCAN_INTERVAL (ms, default 5000)
Keep future calls idempotent. A call should tolerate retries or restarts without duplicating irreversible side effects.
development
Build highly distinctive, production-ready Flutter interfaces with exceptional design fidelity. Include this skill whenever a user requests Flutter widgets, screens, or full apps.
testing
Serverpod Authentication — Signing in users, verify if they are authenticated, assinging scopes (e.g., admin). Use when adding features that require the user to be signed in.
development
Serverpod web server (Relic) — REST APIs, webhooks, middleware, static files, server-rendered HTML, SPAs, Flutter web. Use when adding HTTP routes, serving web pages or web apps, intercepting requests, or working with the Relic web server.
tools
Serverpod overview — what it is, project structure, how to work with. Always use at least once when working with projects that use Serverpod.