Skip to content
Skip to page content

Read one call

Fetch one complete session after session-list returns the session_id you want to inspect.

View as Markdown OpenAPI file

GET https://rpt-2.trellus.ai/session

Send the exact list-row ID in the x-session-id header. A query parameter or JSON body is not used. Add x-proto-as-json: true for camelCase JSON; otherwise the response is binary protobuf. JSON omits wordData.

Authentication: send Authorization: Bearer $TRELLUS_API_KEY. The key inherits the user’s existing permissions. See Authentication.

Request
curl https://rpt-2.trellus.ai/session \
  -H "Authorization: Bearer $TRELLUS_API_KEY" \
  -H "x-session-id: SESSION_ID" \
  -H "x-proto-as-json: true"
const response = await fetch("https://rpt-2.trellus.ai/session", {
  method: "GET",
  headers: {
    "Authorization": `Bearer ${process.env.TRELLUS_API_KEY}`,
    "x-session-id": "SESSION_ID",
    "x-proto-as-json": "true",
  },
});
console.log(await response.text());
import os
import requests

response = requests.get(
    "https://rpt-2.trellus.ai/session",
    headers={
        "Authorization": f"Bearer {os.environ['TRELLUS_API_KEY']}",
        "x-session-id": "SESSION_ID",
        "x-proto-as-json": "true",
    },
)
print(response.text)
Example response, shortened
{
  "sessionId": "CALL_ID",
  "customerData": { "name": "Example contact" },
  "turnData": { "texts": ["Hello"], "isCustomers": [true], "starts": [0] }
}

Headers

HeaderDescription
Authorization Required Bearer $TRELLUS_API_KEY
The API key belonging to your Trellus user.
x-session-id Required, string The exact session_id from a list row. A query parameter or JSON body is not used.
x-proto-as-json Optional, boolean, default false Send true for camelCase JSON; otherwise the response is binary protobuf.

Response

StatusWhat you receive
200 Protobuf by default; x-proto-as-json true returns camelCase proto JSON without wordData.
401 Inactive user, not found, not permissioned, or not on db; inspect the response body.
Any other status text/plain Read the HTTP status and response text; on 429 honor Retry-After seconds.
  • /session JSON uses camelCase keys and enum names; byte fields are base64. Default-valued fields may be omitted, and wordData is omitted. Without x-proto-as-json: true, the endpoint returns protobuf.
  • Unset proto values can appear as 0, false, empty strings or empty arrays. They do not prove an event was measured. Detection flags are signals, not verified outcomes.

More on rows, units and transcripts: Responses and transcripts.

Rate limit

1 request per second per user by default. See Rate limits and exports.

Errors

Error bodies can be plain text. Read the status and the response text.

List works, but /session returns 401 “not found”

Send the exact session_id from a list row in the x-session-id header, with the same Bearer key. A session_id query parameter or JSON body is ignored. “not found” means the session could not be located, not that you need a transcript scope. If correct headers still fail, contact support with the session ID, endpoint, status, response text and UTC time; never include your API key.

401 “not permissioned” or “not authorized”

The user behind the key cannot read that session or team. Check /visible and ask your team admin to review reporting access. A team_id parameter does not grant access. “inactive user” can also mean the key is invalid or the account is inactive.

401 “not on db”

The backend found the session record but could not load its stored detail. Report the session ID and response text to support. You can still use transcript columns from the list when available.

429 Too Many Requests

Wait the Retry-After number of seconds, then retry with a bounded retry policy. Coordinate workers using the same user key. Default backend limits are per user, not per IP. If only your shared cloud host is blocked despite pacing, give support the UTC time, endpoint and response headers so upstream limits can be investigated.

Every documented case is on Errors and troubleshooting.