What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

Can I use the HTTP API to send "I'm alive" message

Votes:

0

Can the API be used to change a sensor's status to "OK"? And if so, can that API call count as a "last scanned" time?

api custom http

Created on Oct 6, 2011 7:11:39 PM



4 Replies

Votes:

0

Hello,

only if the sensor (which you are targeting with the API-Call) is in a simulated error-state, then you could use an API Call to 'resume' the sensor. Otherwise not.

best regards.

Created on Oct 7, 2011 1:28:48 PM by  Torsten Lindner [Paessler Support]



Votes:

0

You can initiate a "scan now" on a specified sensor with the API, that will set the "last scanned time"

What exactly is it you are trying to accomplish?

Created on Oct 7, 2011 2:31:19 PM



Votes:

0

Trying to set up a sensor that is essentially a timer. We will have a process or program elsewhere that, when run successfully, will execute a "reset" on this timer. This way we will be able to know that when that sensor is green, the process has run successfully no more than X minutes ago.

Another scenario: We want a sensor whose state is entirely determined by an API call. That would be amazing. We could monitor anything that could be programmed to send a GET request. It would be a revelation in monitoring!! But the first paragraph is where we're at now. Many thanks to this company and the KB community.

Created on Oct 7, 2011 4:06:20 PM



Votes:

0

With PRTG 9 You can setup a "Green IT" sensor and have your program perform a "scan now" on this sensor using the API. Next you can write a custom sensor that calculates the number of seconds since the last run of the "Green IT" sensor.

As for the Other scenario: If you setup a File sensor and have it check for a file (that always exists) on the local probe, it will always be "green". Next have your application use the /api/setobjectproperty.htm call, to change the sensors filename property to a file that does not exist and the sensor will turn red.

Created on Oct 7, 2011 5:39:09 PM

Last change on Jul 18, 2018 12:57:20 PM by  Brandy Greger [Paessler Support]




Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.