encore-cron

Installation
SKILL.md

Encore Cron Jobs

Instructions

A CronJob declaration in Encore.ts ties a schedule to an existing api(...) endpoint. The endpoint runs at the chosen cadence. Declare the CronJob at package level — not inside a function.

import { CronJob } from "encore.dev/cron";
import { api } from "encore.dev/api";

// 1. The endpoint to call (typically internal: expose: false)
export const aggregateDailyOrders = api(
  { expose: false },
  async (): Promise<void> => {
    // Aggregation logic
  }
);
Installs
64
GitHub Stars
24
First Seen
May 15, 2026
encore-cron — encoredev/skills