RESTful API

From VASCO
Jump to: navigation, search

The RESTful Api Plugin for VASCO provides an application program interface (API) that uses HTTP requests to GET, PUT, POST and DELETE data.

The Api documentation is created by Swagger UI[1] and can be accessed (after the successful start of the plugin) using http://localhost:4711/vasco/api-doc

Configuration

The default port for the API service is 4711. An different port can be specified in the registry with a dword value RESTApiPort under HKEY_CURRENT_USER\Software\Fraunhofer\VASCO

Example: The following RegEdit export will set the port to 4719:

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Fraunhofer\VASCO]
"RESTApiPort"=dword:0000126f

Since the plugin registers a service for a specified URL, the user needs to have the appropriate right to do this. The administrator can provide the VASCO user the necessary right using netsh http add urlacl.

Example:

netsh http add urlacl url=http://+:{port}/vasco user={DOMAIN\user}

Development

Once the Plugin is configured, it can be used by accessing http://localhost:4711/vasco/v1/version in your web browser.

{
  "OS": "Microsoft Windows NT 10.0.17763.0 Win32NT x86 ",
  "Plattform": "x86",
  "Product": "Visio 16,0",
  "Version": "1.0.6969.17412"
}

Examples for different progamming languages of how to use the API can be found in the Developer Corner.