CM evolveIT Dashboard APIs

CM evolveIT Dashboard APIs

This document will cover the basics of the CM evolveIT Dashboard Configuration Tool. There will be a discussion about what APIs are available, how to use the APIs and how to test results from the APIs. The last section of the document will walk you through an example API call.  

After completing this document, you should be able to find the APIs available to connect with the CM evolveIT Dashboard data.  You will be able to find documentation on the APIs and how to use the APIs to make your connections to the dashboard data.  

All of the data access for CM evolveIT dashboard uses Web APIs. Therefore, you can use the same APIs to do some work that the Dashboard doesn’t provide to you. 

You can Automatically do: 

  • Retrieve Trend information to do your analysis or generate a report 
  • Create User Group and associate certain Users 
  • Create Role and associate with certain Users 
  • Create Object Group and define Inventory Data Unit 

NOTE: 

  • Certain API execution calls require certain permissions. The login user you used to get the token is used for permission check. When you don’t have the Permission, you get the Response Code: 401.  

http://<hostname>:32670/swagger/ui/index 


 


1.  How to use the CM evolveIT API 

The Common steps to Invoke CM evolveIT API:   

  • Obtain Token by Login AP 
  • Prepare the input parameter  
  • Invoke the API with parameter and Token 
  • Please use Swagger API document to get parameters and Token 
  • http://<hostname>:32670/swagger/ui/index 

Invoke API with Swagger 

      This section explains how to invoke CM evolveIT APIs from Swagger documentation page 

  • Get Token via Login API 
  • The first step to invoke most of APIs is to obtain a token and use it for the API call. 
  • Open http://<hostname>:32670/swagger/ui/index 
  • Expand User 
  • Expand POST /api/User/Login 
  • Click Example Value section to copy the input parameter value 
  • Set UserID and Password 
  • Click “Try it out!” button 

 


 

 

 

Successful Response image 


 

Sample Response Body 

Please copy “Token” value. It is required to execute most of APIs 

{"UserID":"Administrator","FirstName":"System","LastName":"Admin","MiddleName":null,"Email":"admin@evolveit.com","IsActive":true,"RegisteredOn":"2018-06-27T10:41:09Z","Token":"uwGuF2XTx8rdbslBS1oBKg5sds0EsDexa96KrCSwRrwS","ImageData":null,"NeedPasswordReset":false,"FromAD":false,"ID":"#17:0"} 

 

TIP: 

  • Request URL, (API signature) 

You can use the same Request URL from your custom application 

 


 

  • Input parameter 

Parameter type query 

 


 

Parameter type body 

 


 

  • API execution Permission 

In case you don’t provide Token or the User doesn’t have Permission to execute the API, you will get Response Code: 401. 

 


 

  1. Call APIs with Token 

Invoke Get/User API 

 


 


 2. Scenario base Sample 

Create a new User Group then, assign User(s) to the User Group  

  • CM evolveIT Active Directory supports User records synchronization. However, it doesn’t support automatically sync User with User Group you wish. There are many different ways to define the User and User group so using the API provides the most flexibility. Your organization might use OU (organization unit) or CN (Common Name) in Active Directory to group users or other master data management system in your organization. 
  • This scenario is that User records are created already in CM evolveIT database via Active Directory Sync (or manually). You have information outside of CM evolveIT about User and User Group association information.   

 Pre-requirement 

  • List of User Group Name you wish to have. (It can be OU, CN or your team name.)  
  • Sync Active Directory User to CM evolveIT User database or manually create User records 
  • Information about which user(s) belongs to which User Group  
  • An engineer who can code basic API consumption  

Implementation 

  • Obtain Toke by Login with User who has UserManagement and UsergroupManagement permission.  
  • POST /api/User/Login 

Create all User Group record(s)  

POST /api/Usergroup 

{ 

  "Name": "Team B", 

  "CreatedOn": "" 

} 

  1. List All User Groups 

GET /api/Usergroup 

{ 

    "Name": "Team A", 

    "CreatedOn": "2018-06-26T13:41:10.757Z", 

    "ID": "#41:1" 

  }, 

{ 

    "Name": "Team B", 

    "CreatedOn": "2018-06-26T13:41:10.757Z", 

    "ID": "#41:2" 

  } 

 

  1. List All Users  

GET /api/User 

{ 

    "UserID": "RogerH", 

    "FirstName": "Roger", 

    "LastName": "Hammer", 

    "MiddleName": "", 

    "Email": "", 

    "IsActive": true, 

    "RegisteredOn": "2018-06-28T18:08:12.073Z", 

    "Token": "", 

    "ImageData": null, 

    "NeedPasswordReset": false, 

    "FromAD": true, 

    "ID": "#17:1" 

  }, 

{ 

    "UserID": "KiyoshiT", 

    "FirstName": "Kiyoshi", 

    "LastName": "Terasawa", 

    "MiddleName": "", 

    "Email": "", 

    "IsActive": true, 

    "RegisteredOn": "2018-06-28T18:08:12.073Z", 

    "Token": "", 

    "ImageData": null, 

    "NeedPasswordReset": false, 

    "FromAD": true, 

    "ID": "#17:2" 

  } 

 

  1. Create User and User Group mapping data to invoke AssignUsersToUsergroup API 
  • Using your User(s) and User Group mapping information, create a mapping model 
  • Use List User and List Usergroup ID property  

 

This sample data is for Associates User “RogerH” (#17:1) and “KiyoshiT” (#17:2) with User Group “Team B” (#41:2) 

{ 

  "ParrentId": "#41:2", 

  "ChildIds": [ 

    "#17:1", 

    "#17:2" 

  ] 

 

  1. Associates User(s) with User Group with this API using the model created by prior step 
  • POST /api/Usergroup/AssignUsersToUsergroup  

{ 

  "ParrentId": "#41:2", 

  "ChildIds": [ 

    "#17:1", 

    "#17:2" 

  ] 

 


    • Related Articles

    • Dashboard Overview

      This document will cover the basics of the CM evolveIT Dashboard. There will be a review of the different parts of the dashboard, how to customize the dashboard for personal viewing.   After completing this document, you should have a basic ...
    • CM evolveIT API Interface

      Overview Information managed in an evolveIT Inventory is available for access by 3rd Party applications via simple messaging architecture and a straightforward data access API. evolveIT provides a Service-Oriented Architecture. “Client” applications ...
    • Dashboard Statistics View

      This document will cover the basics of the CM evolveIT Dashboard Statistics View. There will be a discussion of how to display statistics and interact with the statistics graph.    After completing this document, you should have a basic understanding ...
    • Dashboard Metrics Application View

      This document will cover the basics of the CM evolveIT Dashboard Metrix. There will be a discussion of the different views available in the dashboard metrics.   After completing this document, you should have a basic understanding of the CM evolveIT ...
    • Dashboard Metrics JCL View

      This document will cover the basics of the CM evolveIT Dashboard Metrix. There will be a discussion of the different JCL views available in the dashboard metrics.   After completing this document, you should have a basic understanding of the CM ...