Trigger an on-demand agent run
POST
/api/v3/agents/{agentUuid}/actions/run-now
const url = 'https://api.tryletterhead.com/api/v3/agents/example/actions/run-now';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"api":true}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.tryletterhead.com/api/v3/agents/example/actions/run-now \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "api": true }'Trigger an on-demand run for an Analyze agent, bypassing its schedule. Analyze agents only; rate-limited to one trigger per agent every 60 seconds. The run is dispatched asynchronously — poll the activity feed or GET /api/v3/agents/runs/{runUniqueId} for its result.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” agentUuid
required
string
The agent’s unique identifier.
Request Body required
Section titled “Request Body required ” Media type application/json
object
api
required
Required. Set to true to authenticate with an API key.
boolean
Example
{ "api": true}Responses
Section titled “ Responses ”200 OK
Media type application/json
object
items
object
runUniqueId
Empty at dispatch time — the run hasn’t been created yet.
string
queued
boolean
message
string
total
integer
Example
{ "items": { "runUniqueId": "", "queued": true }, "message": "Run-now request accepted", "total": 1}Still can’t find what you need? Contact support.