Skip to content
OpenCode
Esc
navigateopen⌘Jpreview

List running shell commands

List currently running shell commands for a location. Exited commands are not included.

GET/api/shell
Query parameters
locationobject | any
Responses
200Success
locationLocation.Inforequired
Show properties
directorystringrequired
workspaceIDobject
Show properties
object
projectobjectrequired
Show properties
idstringrequired
directorystringrequired
dataShell.Info1[]required
Show properties
Array of Shell.Info1
idobjectrequired
Show properties
object
statusstringrequired
Allowed:runningexitedtimeoutkilled
commandstringrequired
cwdstringrequired
shellstringrequired
filestringrequired
pidobject
Show properties
object
exitnumber
metadataobjectrequired
timeobjectrequired
Show properties
startednumberrequired
completednumber
400InvalidRequestError
_tagstringrequired
Allowed:InvalidRequestError
messagestringrequired
kindstring | any
Show properties
Any of:
string
string
any
any
fieldstring | any
Show properties
Any of:
string
string
any
any
401UnauthorizedError
_tagstringrequired
Allowed:UnauthorizedError
messagestringrequired
Request
curl -X GET "/api/shell"
Response
{
  "location": {
    "directory": "string",
    "workspaceID": {},
    "project": {
      "id": "string",
      "directory": "string"
    }
  },
  "data": [
    {
      "id": {},
      "status": "running",
      "command": "string",
      "cwd": "string",
      "shell": "string",
      "file": "string",
      "pid": {},
      "exit": 0,
      "metadata": {},
      "time": {
        "started": 0,
        "completed": 0
      }
    }
  ]
}