Utility API
This section covers some of the utility APIs that will come in handy for IT administrators or users who depend on scripting with Zoom APIs
Login Details
For purposes of scripting, or even in general, it is vital to know details about the deployment. By issuing the command “getcredentials” via the Web API framework, you can gather generic details like the address of the Zoom Preview Server, Zoom Admin Server, availability of support for SSL connections, etc. and also user-specific details like the current valid authentication cookie for the user, the roles he / she belongs in, the projects he / she belongs in etc.
Request URL:
Response JSON:
{
-
zm_cookie: “37-338dda46558ee05f6e0840cac3e0d2ca7bab79e0”,
-
ssl_webmin_desktop: “false”,
-
has_admin_right: “true”,
-
ssl_rv_desktop: “false”,
-
projects: “defproj, Señál, Website-WP, Android-Apps”,
-
rv_server: “http://192.168.56.1:8873“,
-
svr_realm: “ZoomRealm”,
-
roles: “superadmin”,
-
zm_username: “joe”,
-
success: true,
-
wbm_realm: “http://192.168.56.1:8443/jsp/index.jsp“,
-
upload_to_preview_server: “true”,
-
wbm_server: “http://192.168.56.1:8443“
}
FUID <=> PATH Conversion
The API can be used to convert a Zoom FUID (File Unique Identifier aka Asset ID visible in Asset browser) to a fully qualified path for the asset stored on the Zoom server and vice versa.
Install
If util.jsp is not already installed (post 5.2 releases) in the the Zoom server folder located at <zoom-server-install-folder>/web/app/webmin/, then do the following steps:
- Download and copy util.jsp from Evolphin Support to <zoom-server-install-folder>/web/app/webmin/
- Modify the J2EE web.xml file in <zoom-server-install-folder>/web/app/webmin/WEB-INF/ folder to add an entry for util.jsp under the following security-constraint tag:<security-constraint>
<web-resource-collection>
<web-resource-name>Access to all</web-resource-name>
<url-pattern>/firsttime.jsp</url-pattern>
………….
<url-pattern>/util.jsp</url-pattern>
</web-resource-collection>
</security-constraint> - Restart the Zoom server
Syntax
The syntax of URL on which to make the JSON call is:
URL GET Request to convert Asset ID to Path:
Response:
path=”/fq/path”
URL GET Request to convert Asset ID to Path in JSON:
JSON Response:
{
“path”: “/Advertising/From Hot Folder/VH ñ.png”,
“fuid”: “10”
}
URL GET Request to convert Path to Asset ID:
Response:
Response: fuid=”10″
URL GET Request to convert Path to Asset ID in JSON:
JSON response
{
“path”: “/Advertising/From Hot Folder/VH ñ.png”,
“fuid”: “10”
}