# Application Monitor API

The Application Monitor API uses HTTP GET requests with JSON arguments and responses, using api/GetUserAppUsage as the API route.

Navigating to http(s)://<AS_hostname>:<port_number>/analyzer/api/GetUserAppUsage displays all available usage data. The following API query strings can be used for filtering:

Where:

Variable Description
AS_hostname The name of the machine where Open iT Analysis Server is hosted.
port_number The port number provided during the installation and will be used in the web service. The default value is 80.
Accessing Web Interface - Variables

# API Query Strings

# ?username=<user>

This query filters usage data based on a specific <user>.

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?username=jsmith

The example shows usage data of the user jsmith.

# ?application=<application>

This query filters usage data based on a specific <application>.

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?application=Petrel

The example shows usage data of Petrel.

# ?status=<0-4>

This query filters usage data according to its status. The possible status are:

  • 0 - Inactive
  • 1 - Active
  • 2 - Suspended
  • 3 - Terminated
  • 4 - Blocked

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?status=0

The example shows usage data of applications that are inactive.

# ?status_cond=<filter_condition>

This query works in conjunction with the status query, filtering the data based on the range set on the <filter_condition>. The possible filter condition to use along with the status filter are:

  • lt - less than (<)
  • gt - greater than (>)
  • lte - less than or equal to (<=)
  • gte - greater than or equal to (>=)

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?status_cond=gt&status=0

The example shows usage data of Active, Suspended, Terminated, and Blocked applications.

# ?host =<hostname>

This query filters usage data based on a specific .

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?host=mnl100win

The example shows usage data of applications hosted on mnl100win.

# ?features=<feature\name>

This query filters usage data based on a specific <feature\name>.

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?features=samplefeature

The example shows usage data of sample feature.

# ?collect_from=<epoch>&collect_to=<epoch>

This query filters usage data based on the specified data collection <epoch>. Filter the data using either one or both of the range selectors.

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?collect_from=1563960600&collect_to=1595583000

The example shows usage data from Wednesday, July 24, 2019 9:30:00 AM (GMT) to Friday, July 24, 2022 9:30:00 AM (GMT).

# ?start\from=<epoch>&start\to=<epoch>

The query filters usage data based on the <epoch> when the application started. Filter the data using either one or both of the range selectors.

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?start_from=1563960600&start_to=1595583000

The example shows usage data of applications that started on Wednesday, July 24, 2019 9:30:00AM (GMT) until Friday, July 24, 2022 9:30:00 AM (GMT).

# ?activity_change_from=<epoch>&activity_change_to=<epoch>

This query filters usage data based on the <epoch> when the application activity changed (from active to inactive and vice versa). Filter the data using either one or both of the range selectors.

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?activity_change_from=1563960600&activity_change_to=1595583000

The example shows usage data of applications whose activity changed from Wednesday, July 24,2019 9:30:00 AM (GMT) until Friday, July 24, 2022 9:30:00 AM (GMT).

# ?status_change_from =<epoch>&status_change_to=<epoch>

This query filters usage data based on the <epoch> when the application status changed (to suspended or terminated). Filter the data using either one or both of the range selectors.

Example URL structure:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?status_change_from=1563960600&status_change_to=1595583000

The example shows usage data of applications whose status changed from Wednesday, July 24,2019 9:30:00 AM (GMT) until Friday, July 24, 2022 9:30:00 AM (GMT).

# Joining Queries

Join query filters using the ampersand (&) symbol to further filter usage data.

# Example 1:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?username=jsmith&application=Petrel&host=mnl100win

This shows usage data for the application Petrel on the host mnl100win, whose user is jsmith.

# Example 2:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?username=jsmith&application=OpenWorks&status=3

This shows usage data for the application OpenWorks that are currently terminated, whose user is jsmith.

# Example 3:

http(s)://<AS_hostname>:<port_number>/api/GetUserAppUsage?username=jsmith&features=XTRACT&status_cond=gt&status=2

This shows jsmith usage data for the feature XTRACT that are currently terminated or blocked.

We value your feedback!

Please take a few minutes to complete our survey and share your thoughts on your recent experience with our documentation.

Take survey

Close