Read session and refresh token
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.livefaces.ai/v1/sessions/{session_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://api.livefaces.ai/v1/sessions/{session_id} \
--header 'Authorization: Bearer <token>'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "created",
"room_name": "<string>",
"livekit_url": "<string>",
"participant_token": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"started_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z",
"workflow_run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}Sessions
Read session and refresh token
Requires sessions:read and the key that created this session. Returns a fresh token while connectable.
GET
/
v1
/
sessions
/
{session_id}
Read session and refresh token
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.livefaces.ai/v1/sessions/{session_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://api.livefaces.ai/v1/sessions/{session_id} \
--header 'Authorization: Bearer <token>'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "created",
"room_name": "<string>",
"livekit_url": "<string>",
"participant_token": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"started_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z",
"workflow_run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}{
"code": "<string>",
"detail": "<unknown>",
"request_id": "<string>"
}Authorizations
Organization API key. Keep it on your server.
Path Parameters
The session id returned by either launch endpoint.
Response
Successful response
Use this session ID for status, token refresh, end, and transcript requests.
Available options:
created, active, completed, failed, cancelled Room name for the connection.
LiveKit connection URL returned by the service.
Short-lived participant credential, or null after the session becomes terminal.
Present for a workflow session; identifies its workflow run.