Skip to Content
Keko
API reference

Terminals

A thread’s terminals

GET
/v1/threads/{threadId}/terminals

Authorization

bearer
headerAuthorizationBearer <token>

Path Parameters

threadId*string

Response Body

OK

application/json
  1. response
threadId*string
terminals*array<>
localUrls*array<string>
Example Request
curl -X GET 'https://engine.keko.run/v1/threads/string/terminals'
Example Response
{  "threadId": "string",  "terminals": [    {      "id": "string",      "threadId": "string",      "title": "string",      "status": "idle",      "foreground": "string",      "exitCode": 0    }  ],  "localUrls": [    "string"  ]}
POST
/v1/threads/{threadId}/terminals

Authorization

bearer
headerAuthorizationBearer <token>

Path Parameters

threadId*string

Request Body

application/json
  1. body
cols?integer
Range0 < value <= 9007199254740991
rows?integer
Range0 < value <= 9007199254740991

Response Body

OK

application/json
  1. response
terminal*
Example Request
curl -X POST 'https://engine.keko.run/v1/threads/string/terminals' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "terminal": {    "id": "string",    "threadId": "string",    "title": "string",    "status": "idle",    "foreground": "string",    "exitCode": 0  }}
GET
/v1/terminals/{terminalId}

Send write (keystrokes), resize and close. Several clients can follow one terminal at once.

Authorization

bearer
headerAuthorizationBearer <token>

Path Parameters

terminalId*string

Response Body

Switches to a WebSocket

Example Request
curl -X GET 'https://engine.keko.run/v1/terminals/string'
Example Response
Empty

Closes a terminal

DELETE
/v1/terminals/{terminalId}

Authorization

bearer
headerAuthorizationBearer <token>

Path Parameters

terminalId*string

Response Body

OK

application/json
  1. response
ok*boolean
Example Request
curl -X DELETE 'https://engine.keko.run/v1/terminals/string'
Example Response
{  "ok": true}