TrylleDocs
API ReferenceOpenAPI 3 reference

Automations

GET
/v1/automation-runs/by-target/{provider}/{owner}/{name}/{kind}/{number}

List the latest run per automation that targeted a specific PR or issue. Used by the PR/issue page to render a pill per automation. Returns empty when no automations have run against this target.

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

provider*string

Git provider, e.g. 'github'.

owner*string

Repository owner login.

name*string

Repository name.

kind*string

Target kind: 'pull' or 'issue'.

Value in

  • "pull"
  • "issue"
number*integer

PR or issue number.

Formatint64

Response Body

application/json

curl -X GET "https://example.com/v1/automation-runs/by-target/abc123/abc123/abc123/issue/1"
"abc123"
GET
/v1/automation-templates

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X GET "https://example.com/v1/automation-templates"
"abc123"
GET
/v1/automations

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Query Parameters

account?string

Filter to automations belonging to this account login.

Response Body

application/json

curl -X GET "https://example.com/v1/automations?account=abc123"
"abc123"
POST
/v1/automations

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/v1/automations" \  -H "Content-Type: application/json" \  -d '{    "accountKind": "org",    "accountLogin": "aa",    "botId": "aa",    "definition": "abc123",    "description": "abc123",    "id": "abc123",    "name": "aa",    "templateId": "abc123",    "triggers": [      {        "eventType": "abc123",        "id": "abc123",        "repositoryId": "abc123",        "scheduleCron": "abc123"      },      {        "eventType": "abc123",        "id": "abc123",        "repositoryId": "abc123",        "scheduleCron": "abc123"      }    ]  }'
"abc123"
GET
/v1/automations/{id}

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Automation id.

Length1 <= length

Response Body

application/json

curl -X GET "https://example.com/v1/automations/aa"
"abc123"
DELETE
/v1/automations/{id}

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Automation id.

Length1 <= length

Response Body

application/json

curl -X DELETE "https://example.com/v1/automations/aa"
"abc123"
PUT
/v1/automations/{id}

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Automation id.

Length1 <= length

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X PUT "https://example.com/v1/automations/aa" \  -H "Content-Type: application/json" \  -d '{    "botId": "aa",    "definition": "abc123",    "description": "abc123",    "enabled": false,    "name": "aa",    "triggers": [      {        "eventType": "abc123",        "id": "abc123",        "repositoryId": "abc123",        "scheduleCron": "abc123"      },      {        "eventType": "abc123",        "id": "abc123",        "repositoryId": "abc123",        "scheduleCron": "abc123"      }    ]  }'
"abc123"
GET
/v1/automations/{id}/runs

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Automation id.

Length1 <= length

Query Parameters

limit?integer

Maximum runs to return. Defaults to 50.

Formatint64
Default50

Response Body

application/json

curl -X GET "https://example.com/v1/automations/aa/runs?limit=1"
"abc123"