API
Last updated
Last updated
All API calls use GET and or POST requests to retrieve and set values. Every response from a GET or POST request use the same structure. The response is in JSON format and includes a true / false field to indicate success, an error field to provide more detailed information if there is an error, and a content field that contains either the current value of the setting or a message detailing what action the request performed.
{"success":true,"error":null,"content":0}
In addition to this document, the web interface provides a full list of API calls and their use cases.
Figure 17: API GET URL Figure 18: API POST URL and Instructions
Figure 19: API Properties Figure 20: API JSON Response
When SSL is enabled you must include a valid API key in the header of your request. It key in the header should be named x-api-key
and the value should be the API key you issued starting with NDI-. Here is some example C# code for sending GET and POST requests with SSL where API KEY
is a string value containing the NDI- prefixed key:
The following subsections detail each API endpoint available in NDI Bridge Service.
Get or set whether to start join or host on service start-up. Will always return the latest auto start value. The service must be restarted to reflect this change.
GET URL: http://localhost:8080/api/auto_start POST URL: http://localhost:8080/api/auto_start
EXAMPLE POST CONTENT: {"value":"0"}
Gets the list of available GPUs.
GET URL: http://localhost:8080/api/gpu_list
Get the current host bandwidth message.
GET URL: http://localhost:8080/api/host/bandwidth_message
Get or set the host bridge name. Will always return the latest host bridge name.
GET URL: http://localhost:8080/api/host/bridge_name
POST URL: http://localhost:8080/api/host/bridge_name
EXAMPLE POST CONTENT: {"value":"My Bridge Host"}
Get or set the host buffer value. Will always return the latest host buffer value.
GET URL: http://localhost:8080/api/host/buffer POST URL: http://localhost:8080/api/host/buffer
EXAMPLE POST CONTENT: {"value":"0"}
Clears the host encryption key on POST.
POST URL: http://localhost:8080/api/host/clear_encryption_key EXAMPLE POST CONTENT: {}
Gets a boolean to represent if the host has reached its GPU encoding limits or not.
GET URL: http://localhost:8080/api/host/gpu_limit
Get or set the host groups to share. Will always return the latest host groups.
GET URL: http://localhost:8080/api/host/groups POST URL: http://localhost:8080/api/host/groups
EXAMPLE POST CONTENT: {"value":"public,test group"}
Get or set the host HX encoder. Will always return the latest host HX encoder value.
GET URL: http://localhost:8080/api/host/hx_encoder POST URL: http://localhost:8080/api/host/hx_encoder
EXAMPLE POST CONTENT: {"value":"0"}
Get or set the host HX GPU. Will always return the latest host HX GPU.
GET URL: http://localhost:8080/api/host/hx_gpu POST URL: http://localhost:8080/api/host/hx_gpu
EXAMPLE POST CONTENT: {"value":"Auto"}
Get or set the host HX NDI4 compatibility mode. Will always return the latest host HX NDI4 compatibility mode value.
GET URL: http://localhost:8080/api/host/hx_ndi4_compatibility_mode POST URL: http://localhost:8080/api/host/hx_ndi4_compatibility_mode
EXAMPLE POST CONTENT: {"value":"false"}
Get or set the host HX output. Will always return the latest host HX output value.
GET URL: http://localhost:8080/api/host/hx_output POST URL: http://localhost:8080/api/host/hx_output
EXAMPLE POST CONTENT: {"value":"0"}
Get or set the host HX quality setting. Will always return the latest host HX quality setting value.
GET URL: http://localhost:8080/api/host/hx_quality POST URL: http://localhost:8080/api/host/hx_quality
EXAMPLE POST CONTENT: {"value":"100"}
Get or set the host port value. Will always return the latest host port value.
GET URL: http://localhost:8080/api/host/port POST URL: http://localhost:8080/api/host/port
EXAMPLE POST CONTENT: {"value":"5990"}
Sets the host’s encryption key on POST.
POST URL: http://localhost:8080/api/host/set_encryption_key EXAMPLE POST CONTENT: {"value":"some encryption key"}
Starts the host and returns if the operation succeeded or not.
POST URL: http://localhost:8080/api/host/start EXAMPLE POST CONTENT: {}
Gets the current host status message.
GET URL: http://localhost:8080/api/host/status_message
Stops the host if the host was running. Returns if the operation succeeded or not.
POST URL: http://localhost:8080/api/host/stop EXAMPLE POST CONTENT: {}
Returns true if Bridge is running in Host or Join mode.
GET URL: http://localhost:8080/api/is_running
Get the current join bandwidth message.
GET URL: http://localhost:8080/api/join/bandwidth_message
Get or set the join bridge name. Will always return the latest join bridge name.
GET URL: http://localhost:8080/api/join/bridge_name POST URL: http://localhost:8080/api/join/bridge_name
EXAMPLE POST CONTENT: {"value":"My Bridge Name"}
Get or set the join buffer value. Will always return the latest join buffer value.
GET URL: http://localhost:8080/api/join/buffer POST URL: http://localhost:8080/api/join/buffer
EXAMPLE POST CONTENT: {"value":"100"}
Clears the join encryption key when called.
POST URL: http://localhost:8080/api/join/clear_encryption_key EXAMPLE POST CONTENT: {}
Gets a boolean to represent if the join has reached its GPU encoding limits or not.
GET URL: http://localhost:8080/api/join/gpu_limit
Get or set the join groups to share. Will always return the latest join groups.
GET URL: http://localhost:8080/api/join/groups POST URL: http://localhost:8080/api/join/groups
EXAMPLE POST CONTENT: {"value":"pubic,test"}
Get or set the join HX encoder. Will always return the latest join HX encoder value.
GET URL: http://localhost:8080/api/join/hx_encoder POST URL: http://localhost:8080/api/join/hx_encoder
EXAMPLE POST CONTENT: {"value":"0"}
Get or set the join HX GPU. Will always return the latest join HX GPU.
GET URL: http://localhost:8080/api/join/hx_gpu POST URL: http://localhost:8080/api/join/hx_gpu
EXAMPLE POST CONTENT: {"value":"Auto"}
Get or set the join HX NDI4 compatibility mode. Will always return the latest join HX NDI4 compatibility mode value.
GET URL: http://localhost:8080/api/join/hx_ndi4_compatibility_mode POST URL: http://localhost:8080/api/join/hx_ndi4_compatibility_mode
EXAMPLE POST CONTENT: {"value":"false"}
Get or set the join HX output. Will always return the latest join HX output value.
GET URL: http://localhost:8080/api/join/hx_output POST URL: http://localhost:8080/api/join/hx_output
EXAMPLE POST CONTENT: {"value":"0"}
Get or set the join HX quality setting. Will always return the latest join HX quality setting value.
GET URL: http://localhost:8080/api/join/hx_quality POST URL: http://localhost:8080/api/join/hx_quality
EXAMPLE POST CONTENT: {"value":"100"}
Get or set the join IP address. Will always return the latest join IP address.
GET URL: http://localhost:8080/api/join/ip_address POST URL: http://localhost:8080/api/join/ip_address
EXAMPLE POST CONTENT: {"value":"127.0.0.1"}
Get or set the join port value. Will always return the latest join port value.
GET URL: http://localhost:8080/api/join/port POST URL: http://localhost:8080/api/join/port
EXAMPLE POST CONTENT: {"value":"5990"}
Sets the join encryption key on POST.
POST URL: http://localhost:8080/api/join/set_encryption_key EXAMPLE POST CONTENT: {"value":"some encryption key"}
Starts the join and returns if the operation succeeded or not.
POST URL: http://localhost:8080/api/join/start EXAMPLE POST CONTENT: {}
Gets the current join status message.
GET URL: http://localhost:8080/api/join/status_message
Stops the join if the join was running. Returns if the operation succeeded or not.
POST URL: http://localhost:8080/api/join/stop EXAMPLE POST CONTENT: {}
Starts the connection test. You can use the connection test to help identify the best buffer setting for your chosen bitrate given your current network conditions. You must have at least one active connection to perform a connection test.
POST URL: http://localhost:8080/api/connection_test_start
Stops the connection test. The response to this request will include the recommended buffer setting.
POST URL: http://localhost:8080/api/connection_test_stop
Get or set the bitrate used in the connection test. Will always return the current bitrate value.
GET URL: http://localhost:8080/api/connection_test_bitrate POST URL: http://localhost:8080/api/connection_test_bitrate
Gets the current running mode.
GET URL: http://localhost:8080/api/runmode
Returns the timespan since the service started.
GET URL: http://localhost:8080/api/uptime
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | ||
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|
Key | Type | Description | Notes |
---|---|---|---|