13. REST APIs For Developers (BETA)

These APIs are marked as BETA for feedback. We may not be able to keep backward compatibility until it is officially released.

This chapter describes the REST API calls that can be used with MetaDefender Vault. Through the Application’s Interface, any 3rd party application can interact and communicate directly with MetaDefender Vault. This allows you to add MetaDefender Vault to your automated workflow. Each call should include an authentication key or user credentials (username and password) or use API Keys.

About this REST API

The exposed endpoint is located by default at http://localhost:8010/vault_rest/ (i.e. for 1. Initialize Group Transfer the endpoint is http://localhost:8010/vault_rest/transfer).

All endpoints require you to provide the Authorization header. The value for this header should be obtained by calling Request An API Key. Please note that an authentication key has a limited lifetime and it should be refreshed to avoid expiration policy.

In order to change the URL it is recommended to use the Protocol Configuration Tool (located by default in C:\Program Files\OPSWAT\MetaDefender Vault\Tools).

This URL can also be changed directly from the configuration file by following these steps:

  1. Go to the installation directory (by default C:\Program Files\OPSWAT\MetaDefender Vault)

  2. Navigate to the WebServer/conf folder

  3. Open the file called dynamic.conf using administrative privileges

  4. Edit the following section of the configuration file as you wish:

    listen <ip_address>:<port>;
    server_name "<machine_name>";

    Or, in case of TLS/SSL:

    listen <ip_address>:<port> ssl;
    server_name "<machine_name>";
    ssl_certificate "<certificate_path>";
    ssl_certificate_key "<certificate_key_path>";
    ssl_password_file "<password_file_path>";

  5. Restart MetaDefender Vault Helper Service (vaultHelper) for changes to apply.

Sample Postman Collection

Some of the REST APIs have been exported in the following collection that you can download and try: OPSWAT MetaDefender Vault Postman Collection.json