Skip to main content
GET
/
agent
/
sessions
/
{id}
Get an agent session
curl --request GET \
  --url https://api.getmembrane.com/agent/sessions/{id} \
  --header 'Authorization: Bearer <token>'
{
  "id": "<string>",
  "workspaceId": "<string>",
  "workspaceElementType": "customer",
  "workspaceElementId": "<string>",
  "type": "<string>",
  "status": "queued",
  "prompt": "<string>",
  "lastActivityAt": "2023-11-07T05:31:56Z",
  "hasWorker": true,
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "userId": "<string>",
  "tenantId": "<string>",
  "orgWorkspaceId": "<string>",
  "error": {
    "message": "<string>",
    "type": "bad_request",
    "key": "<string>",
    "data": {},
    "stack": {},
    "causedByError": "<unknown>",
    "logs": [
      {}
    ]
  },
  "title": "<string>",
  "summary": "<string>",
  "cost": 123,
  "state": "busy",
  "isExternal": true,
  "agentName": "membrane",
  "output": {}
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

Query Parameters

wait
boolean
timeout
integer
default:30
Required range: 1 <= x <= 60

Response

200 - application/json
id
string
required
workspaceId
string
required
workspaceElementType
enum<string>
required
Available options:
customer,
app,
connector,
integration,
flow,
flow-instance,
flow-run,
action,
package,
action-instance,
connection,
field-mapping,
field-mapping-instance,
data-source,
data-source-instance,
data-link-table,
data-link-table-instance,
app-event-type,
app-event-subscription,
app-event-log-record,
app-data-schema,
app-data-schema-instance,
external-event-subscription,
external-event-log-record,
external-event-pull,
screen,
action-run-log-record,
external-api-log-record,
incoming-webhook-log-record,
connected-product
workspaceElementId
string
required
type
string
required
status
enum<string>
required
Available options:
queued,
starting,
running,
completed,
failed,
cancelled
prompt
string
required
lastActivityAt
string<date-time>
required

Last meaningful session progress timestamp used for inactivity timeout checks.

Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
hasWorker
boolean
required
createdAt
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
updatedAt
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
userId
string
tenantId
string
orgWorkspaceId
string
error
object
title
string
summary
string
cost
number
state
enum<string>
default:busy
Available options:
busy,
idle
isExternal
boolean
agentName
enum<string>
Available options:
membrane,
membrane-core,
self-integrating,
connection-building,
action-building,
universe
output
object