Page 1 of 1

POST data to REST API using webinject

Posted: Mon Apr 23, 2018 10:11 am
by nagios_ant
Hi team,
we are using webinject of nagios for testing our webservices (REST)
we were able to test our GET services with the webinject plugin.
We are unable to find a method to test POST method using content type as application/json
Can you suggest any options.

Re: POST data to REST API using webinject

Posted: Mon Apr 23, 2018 12:16 pm
by tacolover101
you should be able to use check_http to verify your JSON endpoints.

an example that was worked through can be found here - https://support.nagios.com/forum/viewto ... 9&start=10 - note that the OP was originally missing -T "application/json"

Re: POST data to REST API using webinject

Posted: Mon Apr 23, 2018 1:38 pm
by npolovenko
Thanks, @tacolover101!
@nagios_ant, Let us know if check_http plugin works for you.