Run an agent
POST
/api/v3/agents/{agentUuid}/runs
const url = 'https://api.tryletterhead.com/api/v3/agents/example/runs';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"api":true,"resourceUniqueId":"35f725edbi"}'};
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/runs \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "api": true, "resourceUniqueId": "35f725edbi" }'Run an agent against a resource — currently a letter — identified by resourceUniqueId. Returns the created run.
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
resourceUniqueId
required
The unique identifier of the resource to run the agent against — currently a letter.
string
Example
{ "api": true, "resourceUniqueId": "35f725edbi"}Responses
Section titled “ Responses ”201 Created
Media type application/json
object
items
object
uniqueId
string
agentUniqueId
string
agentName
string
agentType
integer
letterTitle
string
contextLabel
string
resourceType
integer
resourceUniqueId
string
status
integer
summary
string
validationCode
integer
dispatchedAt
string
startedAt
string
completedAt
string
judgments
Array<object>
object
uniqueId
string
severity
integer
confidence
integer
category
string
finding
string
suggestion
string
state
integer
createdAt
string
updatedAt
string
isOutdated
boolean
createdAt
string
updatedAt
string
message
string
total
integer
Example
{ "items": { "uniqueId": "vq5rnof1op", "agentUniqueId": "mofuehvagv", "agentName": "House style checker", "agentType": 0, "letterTitle": "This week in the daily", "contextLabel": "the-daily", "resourceType": 0, "resourceUniqueId": "35f725edbi", "status": 0, "summary": null, "validationCode": 200, "dispatchedAt": null, "startedAt": null, "completedAt": null, "judgments": [], "createdAt": "2026-06-18T14:22:03+00:00", "updatedAt": "2026-06-18T14:22:03+00:00" }, "message": "", "total": 10}Still can’t find what you need? Contact support.