Skip to content
UneeqUneeqUneeq Docs

Export a summary of training sessions

GET
/external/v1/organization/{organizationID}/export/sessions/summary
curl --request GET \
--url "$UNEEQ_API_URL/external/v1/organization/$UNEEQ_ORG_ID/export/sessions/summary" \
--header "Authorization: Bearer $UNEEQ_API_KEY"

Returns one compact record per training session in the organization: who trained, which scenario, status, overall score, duration, endorsement, manager overrides, integrity rating, CRM origin and (for Q&A scenarios) how many questions were answered.

Output format. format=json (the default) returns an envelope {"version": "1.0", "sessions": [...], "total": N} where sessions holds session summary records and total is the number of sessions matching the filters across all pages. format=xapi returns a bare JSON array of xAPI statements (one per session, no envelope and no total); use the X-Total-Count header for the overall count. Both formats are served as application/json and as a file download (Content-Disposition: attachment, file name sessions-summary_YYYY-MM-DD.json).

Filtering. By default only completed sessions are returned. Pass status as a comma-separated list (no spaces) of statuses, or all on its own for every status. time_from / time_to filter on the session start time and are both inclusive. source_system restricts to sessions of scenarios started from that CRM.

Paging and order. Sessions are ordered by start time, oldest first (ties broken by session ID), and paged with limit / offset. limit defaults to 1000 and may be at most 10000; a limit of 0 or less falls back to 1000 and a negative offset is treated as 0. total (and X-Total-Count) is counted in a separate query from the page, so it can differ slightly from the page contents if sessions change between the two.

Sessions of private practice scenarios are included. The response is streamed: if a failure happens after the first byte has been sent, the response stays 200 and the body is truncated (invalid JSON).

organizationID
required
string

ID of the organization the API key belongs to, for example org_HYPCX67vaupjhdTn.

Example

org_HYPCX67vaupjhdTn
format
string
default: json
Allowed values: json xapi

Output format. json returns the envelope; xapi returns an array of xAPI statements. Case-sensitive.

time_from
string format: date-time

Only sessions started at or after this instant. RFC 3339 date-time with a time zone offset, e.g. 2026-01-01T00:00:00Z; a date alone is rejected.

time_to
string format: date-time

Only sessions started at or before this instant. RFC 3339 date-time with a time zone offset, e.g. 2026-01-31T23:59:59Z.

limit
integer
default: 1000 <= 10000

Maximum number of sessions to return. Values of 0 or less fall back to the default; values above 10000 are rejected.

offset
integer
0

Number of matching sessions to skip before the page starts. Negative values are treated as 0.

status
string
default: completed

Comma-separated session statuses to include, with no spaces (e.g. completed,abandoned), or all on its own for every status. Defaults to completed. Allowed statuses: started, generating, analyzing, completed, invalid, abandoned, fatal, error.

Examples

completed
source_system
string
Allowed values: salesforce

Only sessions of scenarios that were started from this CRM.

The export. With format=json (or no format) the body is an ExportSessionSummaryResponse envelope; with format=xapi it is an array of ExportXAPIStatement.

Media typeapplication/json
One of:

JSON envelope of the session summary export (format=json).

object
version
required

Envelope format version. Currently always 1.0.

string
Allowed values: 1.0
sessions
required

The page of sessions, oldest first. Empty array when nothing matches.

Array<object>

Compact view of one training session.

object
session_id
required

Session ID.

string format: uuid
user_email
required

Email of the learner. Empty string if the user record no longer exists.

string
user_name
required

Display name of the learner. Empty string if unknown.

string
training_name
required

Name of the scenario, also when it has since been deleted. Empty string if the session has no scenario.

string
training_id
required

ID of the scenario the session ran.

string
scenario_type
required

Kind of scenario. ROLE_PLAY for a conversation, TECHNICAL_ACUMEN for Q&A, PRACTICE for a private practice role-play. ROLE_PLAY when the scenario no longer exists.

string
Allowed values: ROLE_PLAY TECHNICAL_ACUMEN PRACTICE
status
required

Session status.

string
Allowed values: started generating analyzing completed invalid abandoned fatal error
score_percentage
required

Overall score from 0 to 100, rounded to 2 decimals, including any manager override. 0 when not scored.

number
duration_seconds
required

Session length in seconds, rounded to 2 decimals. Uses the recording length when plausible, otherwise the time from start to finish; 0 while the session is unfinished.

number
started_at
required

When the session started. Set for every session in practice.

string | null format: date-time
completed_at
required

When the session finished; null while unfinished.

string | null format: date-time
endorsement_level
required

Endorsement the learner currently holds for this scenario (not specific to this session). NONE if not endorsed.

string
Allowed values: NONE STANDARD
endorsed_at
required

When the learner’s best-scoring endorsing session for this scenario was scored (not necessarily when the endorsement was first earned); null if not endorsed.

string | null format: date-time
manually_overridden
required

True when a manager override of section scores is currently active on this session.

boolean
overridden_by

Email of the manager who applied the active override. Present only while an override is active.

string
override_reason

The manager’s justification for the active override. Present only while an override is active and a reason was given.

string
override_date_time

When the active override was applied. Present only while an override is active.

string format: date-time
integrity_level

Traffic-light session-integrity rating. Omitted when the session captured no integrity data.

string
Allowed values: GREEN ORANGE RED
source_system

CRM the scenario was started from. Omitted when the scenario did not come from a CRM.

string
Allowed values: salesforce
source_record_id

ID of the CRM record (e.g. a Salesforce Opportunity) the scenario was started from. Omitted when none.

string
questions_answered

Q&A scenarios only. Number of questions the learner gave a non-blank answer to. Omitted for role-play sessions and for Q&A sessions with no questions recorded.

integer
questions_total

Q&A scenarios only. Number of questions asked in the session. Omitted for role-play sessions and for Q&A sessions with no questions recorded.

integer
failure_criteria_triggered
required

True when one of the scenario’s failure conditions was met and a manager has not dismissed it, in which case score_percentage is 0 (section scores in assessments are not changed). False when the scenario has no failure conditions, none was met, a manager dismissed it, or the check could not run. A dismissal or a re-analysis can change this, so a later export of the same session can differ.

boolean
total
required

Number of sessions matching the filters across all pages (ignores limit and offset).

integer

Example

{
"version": "1.0",
"sessions": [
{
"scenario_type": "ROLE_PLAY",
"status": "started",
"endorsement_level": "NONE",
"integrity_level": "GREEN",
"source_system": "salesforce"
}
]
}
X-Total-Count
integer

Number of sessions matching the filters across all pages (ignores limit and offset).

Content-Disposition
string

Always attachment with a file name of the form sessions-summary_YYYY-MM-DD.json (server date), unquoted, for example attachment; filename=sessions-summary_2026-03-06.json.

Invalid query parameter. Messages: invalid time_from: must be RFC 3339 format (e.g. 2026-01-01T00:00:00Z), invalid time_to: must be RFC 3339 format (e.g. 2026-01-01T00:00:00Z), invalid limit: must be an integer, invalid offset: must be an integer, invalid source_system: must be salesforce, unsupported export format (unknown format), limit must be between 1 and 10000 (limit above 10000), invalid session status filter (unknown status, spaces in the list, or all combined with other values). No error_code is set.

Media typeapplication/json

The body of an error returned by an endpoint.

object
message
required

Human-readable explanation of what went wrong.

string
error_code

Stable machine-readable cause. Present only for errors that have one.

string

Example generated

{
"message": "example",
"error_code": "example"
}

The Authorization header is missing, or the API key is not valid for this organization. A key check that fails on the server is also reported as 401.

Media typeapplication/json

The body of an error returned before the request reaches an endpoint (authentication and rate limiting).

object
error
required

Human-readable explanation of what went wrong.

string

Example generated

{
"error": "example"
}

The API key has sent too many requests. Wait for the number of seconds in Retry-After, then retry.

Media typeapplication/json

The body of an error returned before the request reaches an endpoint (authentication and rate limiting).

object
error
required

Human-readable explanation of what went wrong.

string

Example generated

{
"error": "example"
}
Retry-After
integer
>= 1

Seconds to wait before retrying.

The export could not be produced: unable to export data (query failed) or unable to serialize export data (serialization failed before any byte was sent). No error_code is set.

Media typeapplication/json

The body of an error returned by an endpoint.

object
message
required

Human-readable explanation of what went wrong.

string
error_code

Stable machine-readable cause. Present only for errors that have one.

string

Example generated

{
"message": "example",
"error_code": "example"
}