Sessions
List sessions
GET/api/v1/sessions
Sessions in the selected organization, visible to every member of it, newest first, with cursor pagination. The organization is chosen by the X-Organization-Id header, or the organization the API key is bound to, otherwise the caller's default organization.
Query parameters
limitintegerMaximum sessions to return (default 100, max 500)
beforestring · date-timeCursor: return sessions created strictly before this RFC3339 timestamp
daysintegerOnly sessions created in the last N days (1-90). Combines with before.
Header parameters
X-Organization-IdstringSelects which of the caller's organizations the request acts on. When omitted, the caller's default organization is used.
Returns
objectstringrequireddataarrayrequiredShow child attributes
idstring · uuidrequiredThe session's own id
titlestringnullableHuman-readable title; may be null
userstringrequiredUser who created this session
userNamestringnullableDisplay name of the user who created this session. Only on the organization listing.
userEmailstringEmail of the user who created this session. Only on the organization listing.
devicesarrayrequiredDevice allocations linked to this session, ordered by createdAt ascending
Show child attributes
idstring · uuidrequiredAllocation id. Stable and always present, including while the device is still provisioning and no physical device exists yet. This is not the device's own id — see info.serial.
statusstringrequiredDevice lifecycle status. `provisioning` means a device is being booted and has no info.serial yet; `in_use` means it is allocated and driveable; `released` means it has been returned to the pool. More values will be added.
infoobjectrequiredDescriptive attributes of the device.
Show child attributes
platformstringrequiredtypestringnamestringrequiredosVersionstringrequiredserialstringThe physical device's own id — a UDID on iOS, a serial on Android. Absent while the device is provisioning. This is the id accepted by the device endpoints and tools.
createdAtstring · date-timerequiredWhen the device was added to the session
releasedAtstring · date-timenullableWhen the device was released (billing end)
instancesarrayInstances linked to this session, ordered by createdAt ascending
Show child attributes
idstring · uuidrequiredThe instance's own id
statusstringrequiredLifecycle: provisioning -> ready, then released, or failed if provisioning could not complete
osstringrequiredInstance operating system. Only macos is supported today.
imagestringrequiredServer-assigned base image the instance booted from
machineobjectrequiredThe compute backing an instance.
Show child attributes
archstringrequiredCPU architecture. Only arm64 is supported today.
cpuCoresintegerrequiredmemoryMbintegerrequireddiskMbintegerrequiredcreatedAtstring · date-timerequiredWhen the instance was allocated (billing start)
readyAtstring · date-timenullableWhen the instance finished provisioning; null while provisioning
releasedAtstring · date-timenullableWhen the instance was released (billing end); null while active
chatsarrayChats in this session, oldest first. A client restoring a session's conversation reads the last one.
Show child attributes
idstringrequiredChat id
createdAtstring · date-timerequirednextCursorstringnullableCursor for the next page; absent when there are no more results
Create a session
POST/api/v1/sessions
Creates an empty session container. Attach resources to it separately: use fleet.allocate with sessionId to link a device, or allocate an instance with sessionId.
Header parameters
X-Organization-IdstringSelects which of the caller's organizations the request acts on. When omitted, the caller's default organization is used.
Returns
idstring · uuidrequiredThe session's own id
titlestringnullableHuman-readable title; may be null
userstringrequiredUser who created this session
userNamestringnullableDisplay name of the user who created this session. Only on the organization listing.
userEmailstringEmail of the user who created this session. Only on the organization listing.
devicesarrayrequiredDevice allocations linked to this session, ordered by createdAt ascending
Show child attributes
idstring · uuidrequiredAllocation id. Stable and always present, including while the device is still provisioning and no physical device exists yet. This is not the device's own id — see info.serial.
statusstringrequiredDevice lifecycle status. `provisioning` means a device is being booted and has no info.serial yet; `in_use` means it is allocated and driveable; `released` means it has been returned to the pool. More values will be added.
infoobjectrequiredDescriptive attributes of the device.
Show child attributes
platformstringrequiredtypestringnamestringrequiredosVersionstringrequiredserialstringThe physical device's own id — a UDID on iOS, a serial on Android. Absent while the device is provisioning. This is the id accepted by the device endpoints and tools.
createdAtstring · date-timerequiredWhen the device was added to the session
releasedAtstring · date-timenullableWhen the device was released (billing end)
instancesarrayInstances linked to this session, ordered by createdAt ascending
Show child attributes
idstring · uuidrequiredThe instance's own id
statusstringrequiredLifecycle: provisioning -> ready, then released, or failed if provisioning could not complete
osstringrequiredInstance operating system. Only macos is supported today.
imagestringrequiredServer-assigned base image the instance booted from
machineobjectrequiredThe compute backing an instance.
Show child attributes
archstringrequiredCPU architecture. Only arm64 is supported today.
cpuCoresintegerrequiredmemoryMbintegerrequireddiskMbintegerrequiredcreatedAtstring · date-timerequiredWhen the instance was allocated (billing start)
readyAtstring · date-timenullableWhen the instance finished provisioning; null while provisioning
releasedAtstring · date-timenullableWhen the instance was released (billing end); null while active
chatsarrayChats in this session, oldest first. A client restoring a session's conversation reads the last one.
Show child attributes
idstringrequiredChat id
createdAtstring · date-timerequiredGet a session
GET/api/v1/sessions/{sessionId}
Returns a session in the selected organization, visible to every member of it. The organization is chosen by the X-Organization-Id header, or the organization the API key is bound to, otherwise the caller's default organization.
Path parameters
sessionIdstring · uuidrequiredSession UUID
Header parameters
X-Organization-IdstringSelects which of the caller's organizations the request acts on. When omitted, the caller's default organization is used.
Returns
idstring · uuidrequiredThe session's own id
titlestringnullableHuman-readable title; may be null
userstringrequiredUser who created this session
userNamestringnullableDisplay name of the user who created this session. Only on the organization listing.
userEmailstringEmail of the user who created this session. Only on the organization listing.
devicesarrayrequiredDevice allocations linked to this session, ordered by createdAt ascending
Show child attributes
idstring · uuidrequiredAllocation id. Stable and always present, including while the device is still provisioning and no physical device exists yet. This is not the device's own id — see info.serial.
statusstringrequiredDevice lifecycle status. `provisioning` means a device is being booted and has no info.serial yet; `in_use` means it is allocated and driveable; `released` means it has been returned to the pool. More values will be added.
infoobjectrequiredDescriptive attributes of the device.
Show child attributes
platformstringrequiredtypestringnamestringrequiredosVersionstringrequiredserialstringThe physical device's own id — a UDID on iOS, a serial on Android. Absent while the device is provisioning. This is the id accepted by the device endpoints and tools.
createdAtstring · date-timerequiredWhen the device was added to the session
releasedAtstring · date-timenullableWhen the device was released (billing end)
instancesarrayInstances linked to this session, ordered by createdAt ascending
Show child attributes
idstring · uuidrequiredThe instance's own id
statusstringrequiredLifecycle: provisioning -> ready, then released, or failed if provisioning could not complete
osstringrequiredInstance operating system. Only macos is supported today.
imagestringrequiredServer-assigned base image the instance booted from
machineobjectrequiredThe compute backing an instance.
Show child attributes
archstringrequiredCPU architecture. Only arm64 is supported today.
cpuCoresintegerrequiredmemoryMbintegerrequireddiskMbintegerrequiredcreatedAtstring · date-timerequiredWhen the instance was allocated (billing start)
readyAtstring · date-timenullableWhen the instance finished provisioning; null while provisioning
releasedAtstring · date-timenullableWhen the instance was released (billing end); null while active
chatsarrayChats in this session, oldest first. A client restoring a session's conversation reads the last one.
Show child attributes
idstringrequiredChat id
createdAtstring · date-timerequiredWas this page helpful?