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

API

photo.set

Update photo data.

require write grant access

Request example

GET http://example.com/api/get/photo.set/json/?id=123456&fields[title]=My+new+photo+name&fields[description]=My+new+photo+description&fields[publish-date]=2010-05-13T19:03:48+02:00
{
	"method"  : "photo.set",
	"request" : 
	{
		"id"     : 123456,
		"fields" : 
		{
			"title"        : "My new photo name",
			"description"  : "My new photo description",
			"publish-date" : "2010-05-13T19:03:48+02:00"
		}
	}
}
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<xml>
	<method>photo.set</method>
	<request>
		<id>123456</id>
		<fields>
			<title>My new photo name</title>
			<description>My new photo description</description>
			<publish-date>2010-05-13T19:03:48+02:00</publish-date>
		</fields>
	</request>
</xml>

Response example

{
	"status"   : "valid",
	"response" : { "message" : "photo updated" }
}
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<xml>
	<status>valid</status>
	<response>
		<message>photo updated</message>
	</response>
</xml>

Arguments

  • id: The photo ID.
  • fields: an array of field: title | description | publish-date | visible.

NOTE: publish-date : follow RFC 3339
visible : is a boolean (use true | false for JSON and 0 | 1 for XML).

Clone this wiki locally