Skip to content
Alban LEROUX edited this page Oct 3, 2011 · 10 revisions

QuickStart Guide

You can make all is possible with the API. API permit to communicate with it in XML format or JSON format.

Request are posted to the API url, generally http://www.something.com/photoblog/api/, all request and response have same headers like explain below.

You can also make direct request with HTTP query string, method GET and POST are both supported.
You just need to pass in the url the method you want to call and the result format you want in reply. (see: query string example)

JSON format

Request

{
	"method"  : "...",
	"request" : ...
}

Valid response

{
	"status"   : "valid",
	"response" : ...
}

Error response

{
	"status"  : "error",
	"code"    : "...",
	"message" : "..."
}

XML format

Request

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<xml>
	<method>...</method>
	<request>...</request>
</xml>

Valid response

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<xml>
	<status>valid</status>
	<response>...</response>
</xml>

Error response

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<xml>
	<status>error</status>
	<code>...</code>
	<message>...</message>
</xml>
Clone this wiki locally