Get historical datas with API

**CMK version:Checkmk Free Edition 2.1.0p26
**OS version:Rocky Linux 9.1

Hello,

I’m currently new to checkmk. I am trying to get the historical data from the gui, like the bandwidth, the response time or even packet losses of a service.

I’ve read the doc, but it is nowhere to be found. It looks like there is no url endpoint to retreive those data. Could you help me find the correct url to send my api request if there is any ?

Nicolas

Hi @ndissoux

welcome to the forum!

How “historical” do you need them?

I assume that it’s clear that Checkmk can only provide data from the point in time when you started monitoring the device with Checkmk.

The default for Checkmk is to save that data for 4 years, with decreasing resolution. (Read more here: Performance data and graphing - Evaluating measured values in Checkmk quickly and easily)

The same article describes how you can get historic data into a table: Performance data and graphing - Evaluating measured values in Checkmk quickly and easily

Last but not least, you can export the metrics as a JSON file to use them somewhere else (this is an Enterprise only feature). See screenshot for where to find this option.

Hello,
Is it possible to retrieve this information through the APIs?

Cordially.

Nicolas

Hi Nicolas,

Host and Service status data can be retrieved via the API. Read more here: Configuration via the Checkmk REST API

For the metrics data, using the InfluxDB exporter is probably the easier option: Sending metrics to InfluxDB and Graphite - via InfluxDB v2 API or Carbon plaintext protocol

Best
Elias

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.