Hi,

your query has two errors: 
1. the ? before service_status_summary doesn't belong there.
2. You haven't specified an output type like json or xml

From: https://wiki.icinga.org/display/Dev/Icinga-Web+REST+API

The structure of the URL
To access, the api, the URL should look as in the following (italics are 
optional, bold ones are required)

host.com/icinga-web/web/api/ %TARGET% / %COLUMNS% / %FILTER% / %ORDER% / 
%GROUPING% / %LIMIT% / %COUNTFIELD% /%OUTPUT_TYPE%

Columns isn't required anymore, but recommended.
Try:
> curl 
> 'http://localhost/icinga-web/web/api/service_status_summary/authkey=%authkeytoken%/json

Regards,

Jannis

Am 29.03.2011 um 14:56 schrieb Jens Bräuer:

> Hi there,
> 
> i run icinga 1.3 with the icinga-web frontend. I came across the Rest API 
> (https://wiki.icinga.org/display/Dev/Icinga-Web+REST+API) and wanted to try 
> it, but so far have been unsuccessfull.
> I created a user with auth via auth_key. And tried to use the API with curl, 
> eg.
> 
> curl 
> 'http://localhost/icinga-web/web/api/?service_status_summary/authkey=%authkeytoken%
> 
> But so far i only get "Invalid Arguments!".
> 
> Could anyone please provide me with an working example? No filters, etc just 
> a basic query? I am interested in the overall systems- and host-status.
> 
> Please feel free to point me to a blog/website/google, in case i missed the 
> obvious.
> 
> Regards,
> Jens
> 
> 
> ------------------------------------------------------------------------------
> Create and publish websites with WebMatrix
> Use the most popular FREE web apps or write code yourself; 
> WebMatrix provides all the features you need to develop and 
> publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
> _______________________________________________
> icinga-users mailing list
> icinga-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/icinga-users

--
Jannis Moßhammer
Software Developer

NETWAYS GmbH | Deutschherrnstr. 15-19 | D-90429 Nürnberg
Tel: +49 911 92885-0 | Fax: +49 911 92885-77
GF: Julian Hein | AG Nürnberg HRB18461 

http://www.netways.de 

** NETWAYS Open Source Data Center Conference 2011 | Nürnberg, 06. und 07. 
April 2011 | http://www.netways.de/osdc **




------------------------------------------------------------------------------
Create and publish websites with WebMatrix
Use the most popular FREE web apps or write code yourself; 
WebMatrix provides all the features you need to develop and 
publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
_______________________________________________
icinga-users mailing list
icinga-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/icinga-users

Reply via email to