RoomKit
  • iOS : Objective-C
  • Android
  • Web
  • Flutter
  • Introduction
  • Demo app
  • Sample codes
  • Client SDKs
    • SDK downloads
    • Release notes
  • Getting started
    • Integration
    • Start a room
  • Guides
    • Customize room parameters
    • Customize the room UI
    • Listen for room callbacks
    • Screen rotation support
    • Screen sharing
    • Manage rooms with Education Cloud Service
    • Use server event callbacks
  • Server APIs
  • Error codes
  • Documentation
  • RoomKit
  • Server APIs
  • RoomKit Server APIs
  • Room statistics
  • Get room's highest participants count in specified time period

Get room's highest user count in specified time period

Last updated:2022-02-25 17:04

1 Description

Gets the highest number of users in a room in a certain time period.

2 Request method and endpoint

  • Request method: POST

  • Request endpoint:

    Service environment Rate limit Endpoint
    Production 1 request/second https://roomkit-api.zego.im/statistic/v2/room/get_max_online
  • Transmission protocol: HTTPS

3 Request parameters

Parameter Type Required Example Description
secret_id Int64 Yes 12580 The Secret ID assigned to your project by ZEGO.
access_token String Yes "CIE7hNPK6Y55DeUJBSDrInP" The server access token obtained via the get_access_token request.
pid Int64 Yes 1200 The Product ID assigned to your project by ZEGO.
room_id String Yes "123456789" Room ID.
begin_timestamp Int64 Yes 1590666065 Query start time, in seconds.
end_timestamp Int64 Yes 1590667065 Query end time, in seconds.
The query time period cannot exceed 72 hours.

4 Sample request

{
    "secret_id": 12580,
    "access_token": "access_token",
    "pid": 1200,
    "room_id":"123",
    "begin_timestamp": 1590666065,
    "end_timestamp": 1590667065
}

5 Response parameters

Parameter Type Example Description
ret Object - The returned status of the request.
ret.code Int 0 The returned code.
ret.message String "succeed" The returned message.
data Object - The returned data of the request.
data.max_online Int64 3 The highest number of users in the room in the given time period.
If the query time period is not within the valid time range of the room, the request returns a success status, and the returned data.max_online field is 0.

6 Sample response

{
    "ret": {
        "code": 0,
        "message": "succeed"
    },
    "data": {
        "max_online":3
    }
}
Page Directory