---
title: "Run a routine now"
method: POST
path: "/api/v1/ai/routines/{id}/trigger"
tags: ["AI Routines"]
---

# Run a routine now

`POST /api/v1/ai/routines/{id}/trigger`

Run a routine immediately, in addition to its schedule. The run executes once using the routine owner's permissions and delivers the AI response to every configured recipient — it is not a private preview. Because runs execute as the owner, the owner's per-connector AI toggles (set in the chat + menu) govern which integration tools the agent may use. Returns once the run has started; the result is delivered asynchronously. Organization API keys can pass `?userId=<membershipId>` to act on behalf of a specific organization member.

## Path parameters

- `id` string, uuid, required — The UUID of the routine.

## Query parameters

- `userId` string, uuid — Target user membership ID (for org-scoped API keys)

## Response `202`

The run has started.

- RoutineTriggerResponse
  - `id` string, uuid, required — The ID of the run (scheduled job) that was started.

## Other responses

- `400` — Invalid routine ID, or the routine cannot run as configured (e.g. its model, branch, or owner is no longer accessible).
- `401` — Missing or invalid API key.
- `403` — AI routines or AI query generation are not enabled for the organization, or a user-scoped API key tried to run another user's routine.
- `404` — The routine does not exist or cannot be triggered (deleted, paused, or disabled by Omni).
- `409` — A run is already in progress for this routine.

---

[API](https://skmtc.net/omniapp/apis/omni-api.md) · [All operations](https://skmtc.net/omniapp/apis/omni-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/omniapp/omni-api/versions/4701f292c621/schema)
