Summary
This article provides instructions for sending an API call as an HTTP request to generate a generic event in the Wisenet WAVE Client, as well as how to configure a generic event and event action from the Wisenet WAVE VMS. By following these steps, you can trigger a generic event in the system from a third party system.
Configuring an Event
Creating a User Account
To create a user account for a Generic Event:
- Log in to the WAVE Client.
- Open the System Adminstration menu.
-
Navigate to Users and select New User.
- Complete the fields in the User Information window and select Advanced Viewer from the Role drop-down menu.
- Click the three dots next to the Enable toggle and click Allow digest authentication for this user.
- Click OK to complete adding the user.
Testing an API Call (HTTP Request)
You can test an API call with the web browser to generate a generic event.
- Open a web browser and enter the following WAVE API command to generate a Generic Event.
https://WAVEServerIP:7001/api/createEvent?caption=test
Example: https://127.0.0.1:7001/api/createEvent?caption=test -
Enter the username and password you created for the generic event.
Once you successfully send the API call, you will see the following result from your web browser:
{
"error": "0",
"errorId": "ok",
"errorString": ""
}
- From the WAVE Client, confirm that there is a new notification of a Generic Event in the NOTIFICATIONS tab.
Generating a Generic Event
To generate a Generic Event with a specific camera:
- Right click on the camera to use and select Camera Settings.
- Select the down arrow under Vendor to find and copy the Camera ID.
-
Open a web browser and enter the following WAVE API command:
http://WAVEServerIP:7001/api/createEvent?caption=test&metadata={"cameraRefs":["d22704a6-3d8b-4d2b-53c5-1c604fcf0363"]}
Once you successfully send the API call, the generic event is executed with that specific camera's snapshot.
NOTE: You can also add various parameters such as timestamp, source,
description, etc. Refer to the Wisenet WAVE API document for more
information about the Generic Event API at the following URL:
https://WAVE server IP:7001/#/api-tool/api-createevent-post?type=1
Configuring a Generic Event and Event Action
To configure a generic event and event action:
- Right click on the camera in the Resource Panel in the WAVE Client and navigate to Camera Rules.
- Click +Add to create a new event rule.
- Select Generic Event from the When drop-down menu (aka event trigger).
- Complete the Source contains, Caption contains, Description contains fields so the WAVE system can identify the event.
- Select the desired event action from the Do drop-down menu.
-
Once the generic event is triggered, the configured event action is performed in WAVE.