H5 page
Live H5 page usage instructions document
update records
2024-4-2 Simplified the format of passed parameters
videoList -> ids
1. Page overview
The device live stream page is used to display the real-time video stream of the specified device. Users can watch the real-time operation of the device through this page.
2. Access address
3. Parameter description
Parameter name | Parameter Type | Required/Optional | Describe |
---|---|---|---|
ids | array | Required | Used to specify the video stream list to be queried. The parameter value is an array containing multiple objects, each object contains the device ID and channel number. The format of each object is as follows: |
deviceId1-ch1,deviceId2-ch2... | |||
token | string | Required | Authentication token used to verify user permissions. Ensure that only authorized users can access the page by providing a valid token. |
display | string | Optional | Default: There are 2 videos per line; display=block:There will only be one video per line |
4. Instructions for use
- Enter the provided address into your browser.
- Enter parameters according to the page prompts. Make sure the
videoList
parameter contains the correctdevice ID
andchannel number
, as well as thetoken
parameter. - Click the query button or press the Enter key, and the page will display the device data within the specified time period.
- The page will display the real-time video stream of the specified channel of the specified device. Users can watch the real-time operation of the device.
5. Precautions
- Please ensure that the
device ID
andchannel number
in thevideoList
parameter are correct, otherwise the video stream may not be queried correctly or incorrect results may be displayed. - Do not disclose the
token
parameters to others, otherwise it may allow unauthorized users to access the page or obtain sensitive information. - Page loading and data query may take some time, please be patient.
- If you encounter other problems, please contact technical support for assistance.
Historical playback H5 page usage instructions document
1. Overview
This page provides a device history playback function. Users can view device data within a specified time period by specifying the device ID, channel number, start time, and end time.
2. Access address
3. Parameter description
Parameter | Required/Optional | Describe |
---|---|---|
deviceId | Required | Device ID, used to specify the device to be queried. |
channelId | Required | Channel number, used to specify the channel of the device to be queried. |
endTime | Required | End time, in the format YYYY-MM-DDHH:MM:SS, used to specify the time range of the query. |
startTime | Required | Start time, in the format YYYY-MM-DDHH:MM:SS, used to specify the time range of the query. |
token | Required | Authentication token, used to verify user permissions. |
4. Usage steps
- Open the specified address in a browser.
- Fill in the corresponding parameters as needed, including
device ID
,channel number
,start time
,end time
and authenticationtoken
. - Click the query button or press the Enter key, and the page will display the device data within the specified time period.
- The page will display the historical playback video of the specified channel of the specified device. Users can choose to watch historical replays for a specified period of time.
5. Precautions
- Please ensure that the parameter values provided are correct, otherwise the query results may be inaccurate or the data may not be queried.
- The authentication
token
is an important credential used to verify user permissions. Please keep it properly and do not disclose it to others. - Page loading and data query may take some time, please be patient.
- If you encounter other problems, please contact technical support for assistance.
How to get Token
To obtain the token
required to access the device history playback page, you need to perform the following steps:
- Enter the Developer project:First, you need to log in to your Developer project. Make sure you are logged into the correct account and project.
- View Account Info:In the project interface, find and click the "AccountInfo" section on the right. This will open a new page or panel.
- Get API key and API Secret:In the "AccountInfo" panel you will see the
APIkey
andAPISecret
fields. Be sure to record these two values carefully as they are the key credentials used to create the token. - Call createToken interface:Use the
APIkey
andAPISecret
you obtained in step 3 to generate a token by calling our createToken interface. You can do this using any tool or library that supports HTTP requests. The specific request method and parameters may vary according to the documentation of the interface, so please refer to the relevant documentation for details. - Replace token:Once you have obtained the token, replace it with the
token
part in the address of the device's history replay page. You should now be able to successfully access the page and view the desired device history replay.
important hint:Please make sure your APIkey
and APISecret
remain private and do not share them with others. They are sensitive information used to verify your identity and authorize access. If someone else obtains these credentials, they could take unauthorized actions on your behalf. Therefore, please keep this information in a safe place.
If you encounter any problems in obtaining or using tokens, or need further help and guidance, please contact our technical support team. They will be happy to provide you with support and service.
Last modified: 3 个月前