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

PRTG API - How to know a which value are waiting by PRTG Server/possible for an propert's object

Votes:

0

Hello there,

I'm using PRTGApi from lordmilko to manage a bulk sensors creation. I'm trying to automatically configure a new HTTP advanced sensor with a sentence verification into the web page.

I use this PS command :

$HttpSensorParams = $PRTGDevice | New-SensorParameters -RawType httpadvanced 
$HttpSensorParams.httpurl = "http://"+$IPAddress
$HttpSensorParams.includemust = "my verif text"
$HttpSensorParams.includemusttype = ???? <= Valid value that I'm looking for !
$HttpSensor = $HttpSensorParams | Add-Sensor 

However, I don't know how to set up $HttpSensorParams.includemusttype which is 0 by default. I would like to directly check "Set sensor to error if keyword is missing" option. I tried multiple integer 1, 2, -1 but it never checks the option.

How can I know possible value for this object property ?

Thanks a lot !

api help httpadvanced

Created on May 13, 2022 9:23:17 AM

Last change on May 16, 2022 5:07:07 AM by  Felix Wiesneth [Paessler Support]



2 Replies

Votes:

0

This question was also asked on GitHub, where the resolution was provided:

By inspecting the HTML of the webpage, we see that the property "httpmustneeded" must be set to 1

Please note that PrtgAPI is a third party piece of software, and as such is not supported by Paessler. Please direct all queries regarding PrtgAPI to the GitHub repo (which in this case you have also done)

Created on May 16, 2022 5:48:32 AM



Votes:

0

Duly noted. thanks!

Created on May 16, 2022 6:17:59 AM




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.