VidyoGateway experimental features for on-premises

This section contains information for the use of experimental features for on-premises users.

Enable VidyoGateway experimental features

You must first use the VidyoGateway Admin portal to enable experimental features and obtain an API key. After obtaining the key, you can pass it in an API request to the VidyoGateway. By authenticating via the key in this way, you can then pass other API commands to the VidyoGateway.

Note

Currently, the API call must be sent via http.

To enable experimental features:

  • Log in to the Admin portal using your System Console account. The GENERAL > VidyoPortal page displays by default.
  • Click the Advanced subtab.
  • Select the API Interface checkbox in the "Experimental Features" section of the Advanced page.

By selecting this checkbox, you are allowing API requests to go through to the VidyoGateway (but only after you've authenticated using the API key as described below). Removing the checkmark prevents any API requests from going through to the VidyoGateway.

  • Click Generate to obtain an API key.
  • Click RTMP to enable RTMP streaming.
  • Click Save or Save and Apply as desired.

Use the API key

This section describes how to use the API key.

Now that you've obtained the API key, you can continue as described in this section.

Query the VidyoGateway status

Use the API key to query the status of the VidyoGateway via http. The following example uses Curl. 

Curl

curl --location --request GET 'http://GATEWAYIP/config/api/v1/status' \
--header 'apikey: APIKEY' \
--header 'Cookie: GATEWAYSID=6768AEC0A722417BAB3687281FE67264' \
--data-raw ''

  • Replace the GATEWAYIP with the local IP of your active VidyoGateway.
  • Replace the APIKEY with the key you have generated.

Sample output

{"version":"20.1.0.017","nodes":[{"id":"192.168.1.2:50611","version":"20.1.0.017","lastPing":"2020-04-03T17:46:28.372","status":"maintenance","role":"master"},{"id":"192.168.1.3:50611","version":"20.1.0.017","lastPing":"2020-04-03T17:46:26.723","status":"online","role":"master"}],"response":"getStatus","meminfo":{"ordblks":1364,"fordblks":3912848,"spaceinuse":2399088,"hblkhd":0,"hblks":0,"arena":6311936,"smblks":3811,"fsmblks":192848,"usmblks":0,"uordblks":2399088,"keepcost":101456},"balancers":[{"type":"SIP","name":"main","status":"online"},{"type":"H323","name":"main","status":"online"},{"type":"Portal","name":"main","status":"online"}]}

Use Postman

Add the API key to the request authorization

Use Postman to add the API key into the authorization for the request.

Configure the GET request

Next, configure the GET request with the local IP of the active VidyoGateway and the API call.

The following example uses "http(s)//ACTIVEGWIP/config/api/v1/status".

Query the nodes on a cluster and the calls on each node

Request

Example: http(s)://ACTIVEGWIP/config/api/v1/nodes

Response

{"nodes":[{"id":"10.51.35.155:50611","status":"maintenance","calls":[]},{"id":"10.51.35.156:50611","status":"online","calls":["aab63123-7e53-4ff3-ba8a-2651e87f3ae610a33239cc5b3"]}]}

Query only the nodes in maintenance mode

Request

Example http(s)//ACTIVEGWIP/config/api/v1/maintenance

Response

[{"id":"10.51.35.155:50611"}]

Establish an RTMP stream via VidyoGateway

Once RTMP is enabled on the VidyoGateway, configuration is enabled so that an RTMP stream can be established via the VidyoGateway to a Vidyo room. You must be in the room you plan to stream from before launching the API call.

When the call is established, you can view the RTMP stream live from the Vidyo room.

Sample request

Send requests to PIN-protected rooms

If you are sending a request to a PIN-protected room, you must first determine what the PIN delimiter is set to on your gateway.

To determine the PIN delimiter:

  1. Log in to the Admin portal using your System Console account. The GENERAL > VidyoPortal page displays by default.
  2. Click the Advanced subtab and view the PIN Delimiter field.

  1. The default delimiter on the gateway is Asterisk. 
  2. Append the delimiter and the room PIN after the room extension in the body of the request.

Terminate an active call

To terminate an active call:

  1. Obtain the call ID returned from the RTMP call request. For example, 6fdee18d-ea6d-46c4-8785-b31244c7bcfa10a33239bc5b3.
  2. Add the call ID to the end of config/api/v1/calls.

  1. Change the request to an HTTP DELETE.
  2. Send the request. This terminates the call.