26. August 2016
timer-icon 3 min

Collaboration with inspectIT RESTful services - spread your performance data

In this short blog post I'll show you how to use the inspectIT RESTful API and which data you will receive.

Last month we released the brand new inspectIT version 1.6.9 with a lot of new features, for example the new configuration interface and a JMX extension as well.
Next to the new features we also extended the inspectIT RESTful API. We decided to support the API First approach and develop an API to request data via HTTP protocol. With the API First approach it’s easy to access and integrate performance data into your existing monitoring system like Icinga 2.

Before the inspectIT 1.6.9 release we already had a REST API for the StorageService. With this service it’s possible to start/stop a recording and also to create, delete and get a storage with all the instrumentation data inside. For further information about the inspectIT storage you can read the following wiki page: “save to storage

How to access the data

However, lets talk about the new RESTful services, the platform and the invocation service.

All requests to a RESTful service returns the results in the JSON format, so it’s easy to read and you are able to parse the response very easily. The services are bounded to the IP of the CMR and port that is used for HTTP communication (defaults is 8182).
For example: http://localhost:8182

Platform services

What are the benefits of platform services? Overall you can retrieve information about the platform, also called agent. It’s possible to get information of all existing agents of the Central Repository Measurement (CMR), detailed information about the status of one agent are also available.
Furthermore you can retrieve a list of instrumented methods for an agent and a list of used sensors as well.

Platform overview

If you request http://localhost:8182/rest/data/platform/all you will get the following JSON response:

Platform details

To get agent information in detail you can specify a platform id: http://localhost:8182/rest/data/platform/status?platformId=5


Invocation services

As far as an agent is connected to the CMR and you did some requests to your application you can request the invocation data via the RESTful invocation service as follows:

Invocation overview

With this request you get an overview off all invocation sequences which are requested.

Here you can find the most important information of the invocations, including information about child invocation (childCount) and timer data as well.

This overview can be very heavy if many invocations happened in the past, so you can enclose the request with different parameters. For example, it’s possible to specify a “platformId” or to narrow the request with a “fromDate” and “toDate” parameter. With the “latestReadId” parameter it only requests all the invocations with a higher id than the submitted one. Last but not least the “limit” parameter will literally limit the request to a desired amount of invocations; default is 100.

Invocation details

If this is not enough for you and you are going to need more information about one invocation you can request detail information of one invocation by calling http://localhost:8182/rest/data/invocations/details?id=4611686018427387927

It shows the same information as seen in the overview part including all nested invocations. Now you’ve got information about the root invocation including the nested invocations in a hierarchal structure.

It’s so easy…

…to work with the inspectIT RESTful API and the performance data are utilizable in your monitoring solution as well – What is a great benefit!

If you like what you read please go ahead and star us on github.com/inspectIT.

Thanks a lot and stay tuned.

Comment article


  1. pulkit

    It’s really good to use the restful service of inspectIT but as for now it allows only limited data to be fetched through HTTP but if we need to get more data we have to use the InspectIT UI for that.
    I am hoping that you will add whole information to be fetched through restful services.
    If you can provide me tentative month when this update could be leveraged that will be great.