Skip to main content
Needs Votes

Get state type from timelines via API

Related products:Infra Monitoring - MonitoringInfra Monitoring - API
  • Mar 2, 2026 2:56 PM UTC
  • 6 replies
  • 59 views

Forum|alt.badge.img+5

Hello,

Would it be possible to get the state type (SOFT/HARD) from the timelines retrieved by API ?

For the endpoint : /monitoring/hosts/{host_id}/services/{service_id}/timeline

We would like to get the field "state_type". It is present in /monitoring/services endpoint.

When a service gets critical, we have every tries in the timeline (also in the web interface). Having the state type would allow us sort each event in the timeline.

6 replies

rchauvel
Centreonian
Forum|alt.badge.img+18
  • Centreonian
  • Mar 6, 2026 1:11 PM UTC
New→Discussion ongoing

rchauvel
Centreonian
Forum|alt.badge.img+18
  • Centreonian
  • Mar 6, 2026 1:13 PM UTC

You’re right that state is missing from the timeline endpoint. Can you please explain your use case for leveraging this endpoint and in what circumstance the state would be helpful?


Forum|alt.badge.img+5
  • Author
  • Steward ***
  • Apr 15, 2026 12:32 PM UTC

Hello,
Sorry for the late answer.
We use this endpoint to fetch the data from Centreon and build KPIs. For example, it would help us determine how many alerts happened to a service for a day without the duplications due to the retries. Currently, we determine that with the n° of the try and the period with the last element but it is not precise information as both parameters can be modified.

Thank you.


lpinsivy
Centreonian
Forum|alt.badge.img+21
  • Centreonian
  • Apr 15, 2026 1:56 PM UTC

HI ​@mikail,

Can you explain in more detail what you mean by "build KPIs"?

Do you want to build something like the “State Breakdowns” table? 

 


Forum|alt.badge.img+5
  • Author
  • Steward ***
  • Apr 15, 2026 4:04 PM UTC

Hello ​@lpinsivy ,

Indeed, we would like to build something alike in a third party tool.
This allow us to make the data more modular, for example check the number of alerts in a list of hosts present in two or more hostgroups.


lpinsivy
Centreonian
Forum|alt.badge.img+21
  • Centreonian
  • Apr 17, 2026 12:05 PM UTC
Discussion ongoing→Needs Votes