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

APPEND to Object Comments Field from API (not SET)

Votes:

0

Is there anyway I can append to the commends field via the API?

I know I can "get" the current value and then append my data and run a "set" but I think I have hit a limit somewhere which makes the encoded URL too large - or some other web server limit.

I am trying to append to a comment that might already have a 1000 lines. I have checked in the GUI and I created a 6000+ line comment and it saves OK - but I could not set it back again via the API.

Is there another "POST" or "PUT" web call I can make with the data?

Thanks for any help, Steve.

api comments prtg

Created on Nov 14, 2019 1:43:27 AM



3 Replies

Votes:

0

Hi,

Have you tried to execute the same API Call again and checked if the comments were set afterwards?

Kind regards

Created on Nov 14, 2019 1:27:17 PM by  Marijan Horsky [Paessler Support]



Votes:

0

I can successfully call the API to set the comments field if the value is 50 lines or so and encoded.

However, the API fails if I try to send an encoded 1000 multi-line value. The failure was an authentication error, and this seems to be caused by the (very long!) URL being truncated - as I had included the username and password parameters on the end of the URL.

So, the short answer is not he comments did not updated when I try to set a very large comment.

I was hoping that there would be some way to append to the comment field that did not involve reading the current value and then setting it back.

Cheers. Steve

Created on Nov 15, 2019 4:55:44 PM



Votes:

0

Hi,

I would ask you to contact the Paessler Technical Support [email protected] and provide us the used URL. Maybe we can find the reason when we can get a view on the URL.

Kind regards

Created on Nov 15, 2019 8:47:50 PM by  Marijan Horsky [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.