0

Xymon 4.3.0-0.beta2

Ubuntu 10.04.04

I am looking to set up a hobbit test for an API call to an HTTP URL

I was given the following information, and all I can find is the ability to monitor HTTP URLS or PINGs and http Auth, but nothing like what I need.

https://sub.domain.com/groups/api/domain/user_exists

Then :

'http' => array(
             'method'  => 'POST',
             'content' => $data,
             'header'=>  "Content-Type: application/json\r\n" .
                                 "X-API-SECRET: 
Long-Hash-of-Letters-and-Numbers####\r\n" .
                                 "Accept: application/json"

);

1) Check for a valid user exists:

$data = {"username":"admin"};

Result should be an HTTP response code 200 and JSON for content

2) Check for a user that doesn't exist

$data = {"username":"0"};

Result should be an HTTP response code 200 and empty for content

Is this even possible? Any good reading to get me started? Or the Answer :P.

Thanks,

FreeSoftwareServers
  • 515
  • 1
  • 8
  • 26

0 Answers0