Sessions API

The Airplane API is currently available to customers as a beta and is subject to change. Please reach out to us as hello@airplane.dev with any feedback!

A session represents an instance of a runbook's execution. See Runbooks API for how to execute runbooks.

Endpoints

Get Session

GET /v0/sessions/get

Get information about an existing session.

Get Session
Copied
1
curl https://api.airplane.dev/v0/sessions/get \
2
-H "X-Airplane-API-Key: $AIRPLANE_API_KEY" \
3
-d 'id=ses20220120za1pskd' \
4
-G

Query Parameters

idstringREQUIRED

ID of the session to retrieve.

Response
Copied
1
{
2
"createdAt": "2022-01-11 22:32:45.601486+00",
3
"createdBy": "usr20220103zlufhym",
4
"id": "ses20220120za1pskd",
5
"isPrivate": true,
6
"name": "MySession",
7
"paramValues": {
8
"limit": "20",
9
"user": "eric"
10
},
11
"params": [],
12
"permissions": [
13
{
14
"action": "sessions.get",
15
"roleID": "team_admin",
16
"subGroupID": "grp20220222zaigy4h2bw3",
17
"subUserID": "usr20211123zz1dv7z"
18
}
19
],
20
"runbookID": "rbk20220120z15kl79",
21
"status": "Succeeded",
22
"teamID": "tea20220103zvy4auu",
23
"updatedAt": "2022-01-11 22:35:45.238512+00",
24
"updatedBy": "ses20220120za1pskd"
25
}

Response

createdAtstring

When this session was created.

createdBystring

ID of the user that created this session.

idstring

Unique ID of this session.

isPrivateboolean

Whether or not the session is private.

namestring

Name of this session.

paramValueskey value

Mapping of parameter name to value used in this session's execution.

paramsarray of object

Schema for the set of values users can provide when executing this session. More details.

permissionsarray of object

Explicit permissions of this session if it is private. More details.

 Show child attributes
runbookIDstring

ID of the runbook this session was spawned from if triggered from a runbook.

statusenum

Status of this session.

Possible Values
Pending
Active
Waiting
Succeeded
Failed
Show more
teamIDstring

ID of the team that owns this session.

updatedAtstring

When this session was updated.

updatedBystring

ID of the user who updated this session.