For app publishers

Scheduled tasks

Calls cyantula makes to the app on a schedule.

What this is

A scheduled task is a job your app does by itself at set times, for example sending a report every Monday morning. cyantula keeps the clock. At each time you set, cyantula knocks on a door of your app, and your app does the work. Your app needs no clock of its own.

This page is where you set the times, run a task by hand, and see what ran.

Where to find it

  1. Open the Apps page and click your app.
  2. Click the card Integrations, then Scheduled tasks.

Scheduled tasks is an Advanced theme. Switch to Advanced at the top of the app page. If your app already has tasks, the Simple view lists Scheduled tasks under Also in use on this app, and you can open it there.

What you see

Run tasks on a schedule. The main block. A line says which time zone the times follow.

  • Add a task: three boxes and a button. The first is the task name, for example weekly-report. The second is the schedule. The third, what it does (optional), is a note for yourself. Then Add task.
  • A table with Task, Schedule, Next run and Last run. Each task has the buttons Run now, Edit, Pause (or Resume) and Remove. A paused task is greyed out and says paused.
  • A line of limits at the bottom: how many tasks an app may have, how often a task may run at most, how long a run may take before it counts as failed. Tasks always run against the published app, never against a dev address.

What ran. A table with When, Task, Trigger, Status and Details. The trigger is schedule, run now or people changed. The status is ok, missed or a failure.

How to write a schedule

A schedule is written as five parts: minute, hour, day of the month, month and weekday. Some examples:

  • 0 8 * * 1: Mondays at 08:00.
  • @hourly, @daily, @weekly and @monthly: ready-made shortcuts.

Times follow the time zone written on the page.

How to add a task

  1. In Add a task, type a name, a schedule and, if you like, a note.
  2. Click Add task.
  3. A green message says Scheduled. It also tells you which address your app must answer. Your app has to be built to answer it, so give that message to your AI agent or developer. The "For your AI agent" page of the app explains it.

You know it worked when the task appears in the table with a Next run time.

How to run a task now

  1. Click Run now next to the task.
  2. The button says Running…. When done, a message says the task worked, with how long it took, or says it failed and why.
  3. The run is added to What ran with the trigger run now.

How to change a task

  1. Click Edit. The form title becomes Change followed by the task name.
  2. Change the schedule or the note, and click Save.
  3. A message says Saved. The new schedule starts counting from now. Click Cancel to leave without saving.

How to pause or resume a task

  1. Click Pause. A message says the task is paused: the schedule stays, nothing runs.
  2. Click Resume to start it again.

How to remove a task

  1. Click Remove.
  2. A window asks Remove the schedule ...? It says the app's route stays and nothing will call it any more. Click Remove schedule.
  3. A message says Removed.

When something looks wrong

  • The app is not running right now — scheduled times will be recorded as failed runs until it is back up. Fix the app first. See Deploys & logs.
  • Nothing scheduled yet. Normal before you add a task.
  • never ran in Last run: the first time has not come yet.
  • ... failures in a row: the app keeps answering with an error. Open the Details column of What ran to see the reason and the app's answer.
  • A missed status: the time came but the call could not be made.
  • No runs yet in What ran: runs of the last days show up here. The page says how many days.
  • A red message after you click a button: the change was not saved. Try again.

Good to know

  • Only people who manage the app can see and change tasks.
  • Remove cannot be undone. The task and its schedule are gone, and you must add it again. The app itself is not changed.
  • The shortest time between two runs of a task is written at the bottom of the block.
  • A task's code lives in your app. This page only keeps the clock.
  • When the licence does not cover scheduled tasks for this app, a note says paused: not in your plan. Nothing is deleted and the schedules stay as they are; the tasks run again as soon as the licence covers the app. Run now says the same instead of running.