Connect to PTY session
Establish a WebSocket connection streaming PTY output and accepting terminal input.
GET
/api/pty/{ptyID}/connectPath parameters
ptyIDobjectrequiredQuery parameters
location[directory]stringlocation[workspace]stringcursorstringticketstringResponses
200Success
boolean400InvalidRequestError
_tagstringrequiredAllowed:
InvalidRequestErrormessagestringrequiredkindstring | anyShow propertiesHide properties
Any of:
string
stringany
anyfieldstring | anyShow propertiesHide properties
Any of:
string
stringany
any401UnauthorizedError
_tagstringrequiredAllowed:
UnauthorizedErrormessagestringrequired403ForbiddenError
_tagstringrequiredAllowed:
ForbiddenErrormessagestringrequired404PtyNotFoundError
_tagstringrequiredAllowed:
PtyNotFoundErrorptyIDstringrequiredmessagestringrequiredRequest
curl -X GET "/api/pty/%5Bobject%20Object%5D/connect"const response = await fetch("/api/pty/%5Bobject%20Object%5D/connect", {
method: "GET"
});import requests
response = requests.get(
"/api/pty/%5Bobject%20Object%5D/connect",
)Response
true{
"_tag": "InvalidRequestError",
"message": "string",
"kind": "string",
"field": "string"
}{
"_tag": "UnauthorizedError",
"message": "string"
}{
"_tag": "ForbiddenError",
"message": "string"
}{
"_tag": "PtyNotFoundError",
"ptyID": "string",
"message": "string"
}