Skip to main content

FileWave Anywhere API (v2)

What

FileWave Anywhere (formerly WebAdmin) talks to FileWave Server through API calls. You can use the same style of calls from scripts or third-party tools when you need automation that matches what FileWave Anywhere does.

When/Why

Use this when a workflow needs to GET, POST, PATCH, or DELETE FileWave Server data from a script, integration, or managed device.

How

Most requests look similar to Command Line RESTful API requests. Use a base64 FileWave Administrator token, and review the Working with APIs KB article for token setup and general API guidance.

Read a current Inventory Report (formerly Query)

For example, to read an existing Inventory Report with an ID of 191, compare the Command Line API path with the FileWave Anywhere API path below.

Command Line:

curl -s  -H "Authorization: $auth" https://$server_dns:20445/inv/api/v1/query_result/191

FileWave Anywhere:

curl -s  -H "Authorization: $auth" https://$server_dns/api/inv/api/v1/query_result/191

FileWave Anywhere uses HTTPS on port 443 by default and adds /api at the beginning of the URL path.

In an example setup, both calls return the same output, which might look like this:

{
  "offset":0,
  "fields":
    [
      "Client_device_name"
  ],
  "values":
    [
      ["C02Z90WDLVDQ"],
      ["FW1063"],
      ["mac0001"],
      ["macadmin1"],
      ["mini"],
      ["ML1015VMNEWNAME"],
      ["ml1063"],
      ["Orac"],
      ["pro"]
  ],
  "filter_results":9,
  "total_results":9,
  "version":3
}

Send an MDM Command

FileWave Anywhere covers more than basic inventory-report reads. This example sends an MDM restart command to an Android device by device ID:

curl -X POST "https://${server}/api/android/restart_devices" \
  -H  "Content-Type: application/json" \
  -H "authorization: ${auth}" \
  -d '{"device_ids": ["3aa9cea3eb7ea992"]}'

Some FileWave Anywhere API workflows have limits that matter when choosing between API paths.

  • The legacy /api/inv/api/v1/query_result/{id} path reads an existing saved Inventory Query or Inventory Report.
  • Custom Field values for a device are available through an internal API path, and that method returns all Custom Field values associated with the device.
  • Setting Custom Field values through the FileWave Anywhere API does not include a timestamp.

For those cases, prefer the Command Line API when it gives you the needed object or value directly.

Use the FileWave 16.4+ Deployments API

FileWave Server 16.4 adds supported public endpoints for creating, listing, reading, updating, and deleting Deployments. Use Managing Deployments with the FileWave API (16.4+) for the endpoint table, authentication, Swagger discovery, a safe read-only example, write verification, and deletion safeguards.

Use the 15.5+ Reports and notifications endpoints

FileWave 15.5.0 added public FileWave Anywhere API endpoints for integrations that need FileWave inventory/report data or notification data as JSON without a manual export. Use the FileWave Anywhere API Documentation article and the Swagger page on your own FileWave Server for the exact request and response details.

  • GET /reports/v1/reports lists available saved Inventory Reports.
  • GET /reports/v1/reports/{id} returns the results for a saved Inventory Report ID.
  • Use the Reports Preview API when an integration needs ad-hoc Inventory Report results without saving the report first. The preview request body is documented in Swagger.
  • GET /notifications/v1/notifications returns FileWave notification data for integrations that need to display or process notifications outside FileWave.

For large report results, use the documented paging, sorting, limit, offset, page-size, or filter controls instead of pulling every row in one request. See Using the Command Line API to limit, sort, and offset values returned for the same general paging pattern.

Please see the FileWave Anywhere API Documentation for a more in-depth look at the possible API options available.

When referencing devices using the FileWave Anywhere API, the endpoint refers to the filewave_id.  This may differ from  the V1 Command Line API.

When FileWave runs API calls from scripts, you can pass inventory values as Launch Arguments or environment variables. This can include, for example, filewave_id.