The HTTP REST API
The Media Server API provides a standardized set of HTTP calls for integration with 3rd-party systems. Using the Media Server API, developers can access nearly every feature available in the Media Server, including:
Resources: Query and manage systems, servers, cameras, and users.
Permissions: Manage user roles and access levels.
Video: Pull live or recorded video streams from the system.
Logic: Generate events and create rules.
Control: Manage PTZ cameras and other hardware.
How to use the API
The APIs follow the REST standard, allowing developers to interact with the Media Server via standard HTTP requests (GET, POST, PUT, PATCH, and DELETE). Because it is language-agnostic, you can integrate your system using any programming language that supports HTTP requests.
Accessing the API Documentation
There are three ways to access the documentation. While an online version exist, using the local version is highly recommended for developers to ensure the documentation matches their specific server version.
Method 1: Online Documentation
You can navigate to the online REST API documentation through this link.
Method 2: WebAdmin Interface
If you have the Media Server installed, you can access the interactive REST API interface directly via your browser and got to:
http://<server_ip>:<server_port>/#/api-tool/main.
Method 3: Downloading the API Schema
For developers using tools like Postman, Insomnia, or Swagger Editor, you can download the raw JSON files directly from your local server. Also, for the use in AI agents, often this is the preferred source to use.
Login: Navigate to
https://localhost:7001(or your server's IP) and log in with your administrator credentials.Request the File: To bypass the authentication token, open a new tab and enter the following URL:
http://localhost:7001/web/static/openapi_v4.jsonSave: Right-click the resulting text in your browser and select "Save Page As...". Ensure the file is saved with the
.jsonextension.
Testing the API
To streamline your development, we provide an interactive environment to execute calls and inspect real-time response data directly in your browser.
Using the WebAdmin Interface
Every endpoint can be tested natively within the WebAdmin dashboard:
Interactive Testing: Click the Try it out button on any endpoint to unlock the input fields.
Execution: Enter your parameters and click Execute to send a live request to the server.
Inspection: The interface will display the full curl command, request URL, and the formatted JSON response body.
Performance
For endpoints that return large datasets, the web interface may experience (indefinite) delays while rendering the output. For a high-performance experience, we recommend testing the API endpoint into professional tools like Postman or Insomnia, which handle outputs more efficiently.
Comments
0 comments
Article is closed for comments.