Client Session
A client stream is started with two steps. First a new session is created. This session contains a websockets endpoint, the client should connect to. The websockets is then used to exchange the SDP, retrieve status information, and control the lifetime of the stream.
Create a new session.
POST /api/v2/session
This request requires a proper auth-token.
client_id
Type: STRING
(required)
ClientID of the supervisor.
Example request:
{
"client_id":"sup-0",
}
Returns 201 on success.
session_id
Type: String
ID of this supervisor session.
ice_credentials
Type: RTCIceServer
Ice server address and credentials.
ws_endpoint
Type: String
Address of the websockets endpoint.
Example response:
{
"ice_credentials": {
"iceServers": [
{
"urls": [
"stun:nuts.eyeson.com:3478"
],
"username": "",
"credential": ""
},
{
"urls": [
"turn:nuts.eyeson.com:3478",
"turn:nuts.eyeson.com:3478?transport=tcp",
"turn:nuts.eyeson.com:443?transport=tcp"
],
"username": "**********************",
"credential": "*******************"
}
]
},
"session_id": "5061fd09-834c-1efa-be18-4a08eb54996f",
"ws_endpoint": "wss://streamrec.test-visocon.com/api/v2/io"
}