AILIVE文档
API 参考接口列表

读取当前场次

读取直播间当前进行中的场次;没有进行中的场次时返回 `null`。

GET
/v1/room/session

请求头参数

authorization?string|null

响应正文

Successful Response

application/json
  1. response
avatar*
balanceLow*Balancelow

Under 100 credits, or under 10 minutes at this session's rate

balanceMilli*|

Credits (milli) the workspace had left after the last hold (ADR 0013 §2)

balanceMinutes*|

Whole minutes that balance lasts

billedSeconds*|

Air time charged, once settled

chargedMilli*|

Credits (milli) charged, once settled

counters?

What the interaction source reported this session (ADR 0009 §10.3).

createdAt*Createdat
格式date-time
endReason*|null
endedAt*|null
error*|

Diagnostic detail from a provider, not for viewers

fundedSeconds*Fundedseconds

Air time the hold pays for

heat?|

How lively the room is by its recent comments (ADR 0016 §1); null until the live job has looked

id*Id
格式uuid
interactionPaused*Interactionpaused

While true, new comments are kept as received but none is picked or replied to, and scenes pause; what is queued still airs (ADR 0009 §3)

maxSeconds*Maxseconds
online?|

Viewers online at the latest report; approximate when only shown

onlineDisplay?|

The platform's own way of showing it, e.g. 1.2万

output*Output

video: avatar video and voice; audio: voice only

可选值"video""audio"
rateMilli*Ratemilli

Credits (milli) per minute of air time

reservedMilli*Reservedmilli

Credits (milli) currently or finally held

revisionNumber*Revisionnumber

The snapshot of the avatar's content taken at start

room*
startedAt*|null
status*Status

queued → starting → live → stopping → ended; failed from any running state

可选值"queued""starting""live""stopping""ended""failed"
stopRequested*Stoprequested
stopsAt*|

When the paid air time ends while the next minute could not be held

请求示例
curl -X GET 'https://api.ailive.studio/v1/room/session' \  -H 'Authorization: Bearer <ACCESS_TOKEN>'
响应示例
{  "avatar": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "name": "string",    "photoFileId": "9ede89cd-e90c-4eb4-b005-817856caa78c"  },  "balanceLow": true,  "balanceMilli": "string",  "balanceMinutes": 0,  "billedSeconds": 0,  "chargedMilli": "string",  "counters": {    "enters": 0,    "follows": 0,    "likes": 0,    "shares": 0  },  "createdAt": "2019-08-24T14:15:22Z",  "endReason": "stopped",  "endedAt": "2019-08-24T14:15:22Z",  "error": "string",  "fundedSeconds": 0,  "heat": "cold",  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "interactionPaused": true,  "maxSeconds": 0,  "online": 0,  "onlineDisplay": "string",  "output": "video",  "rateMilli": "string",  "reservedMilli": "string",  "revisionNumber": 0,  "room": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "name": "string"  },  "startedAt": "2019-08-24T14:15:22Z",  "status": "queued",  "stopRequested": true,  "stopsAt": "2019-08-24T14:15:22Z"}