Skip to main content
TroopyDocs
Open Troopy
Troopy

API reference / Routines and triggers

List routines

The routines that teammates do by themselves on a schedule, with when each runs next and how the last run went. A routine that starts when something happens is a trigger: GET /triggers.

get/api/v1/routines

Authorization

HeaderAuthorization: Bearer <API key>
Or the headerX-API-Key: <API key>
API keyMake one in Troopy under Settings > API keys. It acts as you, in its workspace.

Other ways to call it

CLItroopy routines list
MCP tooltroopy_list_routines
Rate limit120 calls in 60 seconds, for each key

Query parameters

agentstring

The teammate's handle, like chief

At most 40 characters

Response

200 · application/json
data*array<object>
18 properties
id*string

A 24-character id

agent*string
name*string
task*string
days*array<integer>

Days of the week it runs on, 0 is Sunday. Empty for a routine on a cron expression

hour*integer
minute*integer
every*integer | null

Minutes between runs within a day; null runs once a day, at hour:minute

cron*string | null

Its cron expression, in its time zone. Then days, hour, minute and every say nothing. Null for a routine with days and a time

timezone*string
notify*boolean

Whether each result is posted to the routine's conversation. A quiet routine keeps its results in its runs only

paused*boolean
nextRunAt*string | null
lastRunAt*string | null
lastRunId*string | null
lastError*string | null

Why the last time couldn't start

threadId*string | null

The conversation each run's answer is posted to

createdAt*string

ISO 8601 date and time

Errors

400 invalid_inputFix the field named in detail. Each operation's schema is in /api/v1/openapi.json.
401 unauthorizedSend an API key as `Authorization: Bearer tr_live_...`. Create one in Troopy under Settings.
403 forbiddenThe key lacks a scope this operation needs, or its owner lacks the role. detail says which; create a key with the scope, or ask an organization owner or admin.
429 rate_limitedWait the number of seconds in Retry-After, then retry.