To check if a systemd service is up and running, I am using below expression in prometheus console/UI:
<code>node_systemd_unit_state{name="my.service",state="active"}
</code>
<code>node_systemd_unit_state{name="my.service",state="active"}
</code>
node_systemd_unit_state{name="my.service",state="active"}
Is there any rest API, to check the same?