#
Introduction
This article presents how the Open iT License Monitor API can be utilized to connect to the Open iT data warehouse for reporting.
#
License Monitor Portal API
The License Monitor Portal (LMP) Application Programming Interface (API) provides an easier way to fetch and display data from the Analysis Server backend to a web interface. The data returned by the API follows the .json
format.
The License Monitor Portal API uses HTTP GET and POST requests with JSON arguments and responses. The commands in this document utilize the License Monitor API and, as such, require a web browser or any API tool that is connected to the network.
Each request is authenticated against NTLM authentication. Make sure to provide the needed authorization before using the API endpoints below.
#
GET /api/GetProducts
Retrieves the current usage information for vendor license(s).
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetProducts
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetProducts
[
{
"CollectionTime": 1628661137,
"DistinctUsers": 24,
"Active": 0,
"Inactive": 0,
"Indeterminate": 50,
"Mapped": 0,
"MinLicenseExpiration": 1688054400,
"MaxAvailable": 940,
"Product": "licserver03;ibmratl",
"MappingIcon": "ServerDown",
"ExpiredIcon": "",
"IsCurrent": false,
"LogActive": 0,
"LogInactive": 0
}
]
#
GET /api/GetFeatures
Retrieves the current features of users.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetFeatures
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http//:desktop-oit:80/analyzer/api/GetFeatures?product=PRODUCT_123
[[{"Feature":"ARMS_ID","TokenCost":"","TokenPool":"","TokenSource":"","ServerName":"dalpaveva02","Daemon":"undef","LicenseExpiration":1704002399,"DistinctUsers":0,"MaxAvailable":99999,"MaxInUse":0,"MaxBorrowed":0,"MaxQueued":0,"LicenseType":"Sentinel","FeatureType":"feature","Version":"","LicenseModel":"Online","Active":0,"Inactive":0,"BorrowedActive":0,"BorrowedInactive":0,"UnusedReserve":0,"UsedReserve":0,"MappedTo":null,"TokenCostValue":1,"Available":99999,"InUse":0,"ActiveUse":0,"InactiveUse":0,"BorrowedUse":0,"BorrowedActiveUse":0,"BorrowedInactiveUse":0,"AvailableUser":false,"Package":"","LogAvailable":100,"LogInUse":0,"LogUnusedReserve":0,"LogQueued":0,"LogUsedReserve":0,"LogBorrowed":0,"LogActive":NaN,"LogInactive":NaN,"LogBorrowedActive":NaN,"LogBorrowedInactive":NaN,"ShowExpired":true,"ShowWarning":false},{"Feature":"AVEVA_DLS","TokenCost":"","TokenPool":"","TokenSource":"","ServerName":"dalpaveva02","Daemon":"undef","LicenseExpiration":1704002399,"DistinctUsers":0,"MaxAvailable":99999,"MaxInUse":0,"MaxBorrowed":0,"MaxQueued":0,"LicenseType":"Sentinel","FeatureType":"feature","Version":"","LicenseModel":"Online","Active":0,"Inactive":0,"BorrowedActive":0,"BorrowedInactive":0,"UnusedReserve":0,"UsedReserve":0,"MappedTo":null,"TokenCostValue":1,"Available":99999,"InUse":0,"ActiveUse":0,"InactiveUse":0,"BorrowedUse":0,"BorrowedActiveUse":0,"BorrowedInactiveUse":0,"AvailableUser":false,"Package":"","LogAvailable":100,"LogInUse":0,"LogUnusedReserve":0,"LogQueued":0,"LogUsedReserve":0,"LogBorrowed":0,"LogActive":NaN,"LogInactive":NaN,"LogBorrowedActive":NaN,"LogBorrowedInactive":NaN,"ShowExpired":true,"ShowWarning":false}]
#
GET /api/GetUsers
Retrieves the current users of vendor license(s). This endpoint is not case-sensitive.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetUsers
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetUsers?format=sql&product=%&feature=%&sortdatafield=UserName
{
"totalCount": 11,
"data": [
{
"UserName": "user12",
"UserHost": "pc-16",
"UserDisplay": "pc-02 telelogic",
"UsageTime": 1602462480,
"LicenseHandle": "2207",
"ShareHandle": "undef",
"UsedLicenses": 1,
"QueuedLicenses": 0,
"BorrowedLicenses": 0,
"LicenseModelStatus": "active",
"app_status": null,
"app_duration": null,
"license_model": "Online",
"DisplayName": null,
"Mapped": null
},
{
"UserName": "user13",
"UserHost": "pc-107",
"UserDisplay": "pc-107 telelogic",
"UsageTime": 1602463560,
"LicenseHandle": "4536",
"ShareHandle": "undef",
"UsedLicenses": 1,
"QueuedLicenses": 0,
"BorrowedLicenses": 0,
"LicenseModelStatus": "active",
"app_status": null,
"app_duration": null,
"license_model": "Online",
"DisplayName": null,
"Mapped": null
}
]
}
#
GET /api/GetServerDown
This retrieves the list of servers that failed to send any data within the last 30 minutes of daemons that are down.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetServerDown
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetServerDown
[
{
"Label": "flex-sample_mnl1301lin_23933"
},
{
"Label": "lcn001,dsg,openit,local;slickeditinc"
},
{
"Label": "lcn001.dsg.openit.local;altium"
},
{
"Label": "lcn001.dsg.openit.local;dsls"
},
{
"Label": "lcn001.dsg.openit.local;fekete"
},
{
"Label": "lcn001.dsg.openit.local;parasoft"
},
{
"Label": "lcn001.dsg.openit.local;peloton;MasterView"
},
{
"Label": "lcn001.dsg.openit.local;rlm"
},
{
"Label": "lcn001.dsg.openit.local;sentinel"
},
{
"Label": "lcn001;arcgis"
},
{
"Label": "sasrd25073,sasrd25071,sasrd25072;mlm"
}
]
#
GET /api/GetExpirationFeatures
This retrieves the license expiration of the application features.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetExpirationFeatures
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetExpirationFeatures?product=PRODUCT_123
[
{
"Feature": "ADALangPack",
"Version": "8000.13",
"Package": "",
"LicenseExpiration": 2147483647,
"MinLicenseExpiration": 1688054400,
"ShowExpired": false,
"ShowWarning": false,
"LicenseType": "Flex",
"FeatureType": "package",
"LicenseExpirationToDate": "/Date(2147483647000)/"
}
]
#
GET /api/GetHistory
This retrieves the historical data of the application for utilization trend charts. Returns follow the MDX query format.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetHistory
. Replace <as_hostname>
with the actual hostname of the analysis server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetHistory?product=PRODUCT_123&feature=feature1
[
{
"name": "Max Available",
"data": [
[
1442275200000,
477
],
[
1442361600000,
477
],
[
1442448000000,
477
],
[
1442534400000,
477
],
[
1442620800000,
477
],
[
1442707200000,
477
],
[
1442793600000,
477
],
[
1442880000000,
442
],
[
1442966400000,
472
],
]
],
"type": "line",
"yAxis": 0
},
{
"name": "Elapsed Time",
"data": [
[
1442275200000,
2674.1666666666665
],
[
1442361600000,
3147.3333333333335
],
[
1442448000000,
3108.9166666666665
],
[
1442534400000,
3141.4166666666665
],
[
1442620800000,
1275.3333333333333
],
[
1442707200000,
580
],
[
1442793600000,
2671.0833333333335
],
[
1442880000000,
3238.5833333333335
],
[
1442966400000,
3872.5833333333335
],
[
1443052800000,
3235
],
],
"type": "column",
"yAxis": 1
},
{
"name": "Denials",
"data": [
[
1442275200000,
4
],
[
1442361600000,
4
],
[
1442448000000,
0
],
[
1442534400000,
0
],
[
1442620800000,
4
],
[
1442707200000,
5
],
[
1442793600000,
24
],
[
1442880000000,
35
],
],
"type": "column",
"yAxis": 2
}
]
#
GET /api/GetHistoryReserved
This retrieves the historical data of reserved license usage, distinct users, and max in use of selected vendor license/package/feature.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetHistoryReserved
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetHistoryReserved?product=PRODUCT_123&feature=feature1
[
{
"series": [
{
"name": "Reserved Licenses",
"data": []
},
{
"name": "Distinct Users",
"data": []
},
{
"name": "Max In Use",
"data": []
}
],
"categories": []
}
]
The data will contain array of values.
#
GET /api/GetEfficiency
This retrieves the historical data of the application for efficiency charts quick reports. Returns follow the MDX query format.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetEfficiency
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetEfficiency?product=PRODUCT_123&feature=feature1&last=107&package=&type=package&format=sql
[
{
"series": [
{
"name": "Total Duration",
"data": [
[
"5",
359.99999999999972
],
[
"13",
359.9166666666664
],
[
"19",
358.6666666666664
],
[
"21",
358.4166666666664
],
[
"23",
344.1666666666664
],
[
"25",
342.24999999999972
],
[
"27",
340.99999999999972
],
[
"29",
338.6666666666664
],
[
"31",
329.6666666666664
],
[
"33",
328.99999999999972
],
[
"34",
327.83333333333309
],
[
"35",
325.91666666666634
],
[
"37",
325.58333333333303
],
[
"39",
324.49999999999972
],
[
"40",
323.99999999999972
],
[
"41",
323.91666666666634
],
[
"42",
322.58333333333303
],
[
"43",
322.49999999999972
],
[
"44",
321.6666666666664
],
[
"45",
320.74999999999972
],
[
"46",
320.6666666666664
],
[
"48",
320.24999999999972
],
[
"49",
320.08333333333309
],
[
"51",
319.4166666666664
],
[
"52",
318.49999999999972
],
[
"53",
318.4166666666664
],
[
"54",
317.66666666666634
],
[
"55",
317.58333333333303
],
]
}
]
}
]
#
GET /api/GetHeatMap
This retrieves the historical data of the feature for heatmap report quick chart. Returns follow the MDX query format.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetHeatMap
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
http://desktop-oit:80/analyzer/api/GetHeatMap?product=PRODUCT_123&feature=feature1&last=107&package=&type=package&format=sql
[
{
"categories": [
[
"0",
"1",
"2",
"3",
"4",
"5",
"6",
"7",
"8",
"9",
"10",
"11",
"12",
"13",
"14",
"15",
"16",
"17",
"18",
"19",
"20",
"21",
"22",
"23"
],
[
"Sun",
"Mon",
"Tue",
"Wed",
"Thu",
"Fri",
"Sat"
]
],
"series": [
{
"name": "Max In Use",
"data": [
[
0,
0,
97
],
[
1,
0,
97
],
[
2,
0,
89
],
[
3,
0,
97
],
[
8,
0,
89
],
[
9,
0,
89
],
[
10,
0,
89
],
[
11,
0,
94
],
[
12,
0,
89
],
[
13,
0,
89
],
[
14,
0,
97
],
[
15,
0,
97
],
[
16,
0,
97
],
[
17,
0,
81
],
[
18,
0,
81
],
[
19,
0,
81
],
[
20,
0,
81
],
[
21,
0,
84
],
[
22,
0,
86
],
]
}
]
}
]
#
GET /api/GetHttpUserName
This retrieves the current user.
On a browser, go tohttp(s)://<as_hostname>:<port>/analyzer/api/GetHttpUserName
. Replace <as_hostname>
with the actual hostname of the Analysis Server and <port>
with the port number where the server is running.
https://desktop-oit:80/analyzer/api/GetHttpUserName
OIT\bob
#
POST /api/GetConcurrentUsers
Retrieves the count of distinct user aggregated over all vendor licenses.
You can use the instructions in the Postman API Documentation - Create a new request to learn how to properly create and send a request with the Postman API client.
For POST
commands, you can use applications such as Postman
to retrieve the needed result.
In Postman, go to your
Workspaces
and open a new request.Select
POST
from the drop-down then enter or paste the URL in the blank field. Click Send.Paste
http(s)://<as_hostname>:<port>/analyzer/api/GetConcurrentUsers
in the blank field. Replace<as_hostname>
with the actual hostname of the Analysis Server and<port>
with the port number where the server is running.Examplehttp://desktop-oit:80/analyzer/api/GetConcurrentUsers
The returned output should be seen below.
Example Return148