API documentation
get_photo
Usage
http://www.dumpyourphoto.com/api/get_photo/[id]/[hash]/[format]
URL Parameters
-
[id]
- Required
- Value: numerical photo ID
-
[hash]
- Required
- Value: photo hash
-
[format]
- Required
- Value: json or xml
Sample XML response
<?xml version="1.0" encoding="UTF-8"?> <photo status="ok"> <id>23322</id> <hash>FJpLEZ</hash> <title>Title!!</title> <datetime>2009-10-31 13:53:41</datetime> <views>15</views> <url>http://www.dumpyourphoto.com/photo/view/1/FJpLEZ</url> <short_url>http://dyp.im/FJpLEZ</short_url> <sources> <small>http://www.dumpyourphoto.com/files/1/thumbnail/FJpLEZ.jpg</small> <medium>http://www.dumpyourphoto.com/files/1/medium/FJpLEZ.jpg</medium> <large>http://www.dumpyourphoto.com/files/1/FJpLEZ.jpg</large> </sources> </photo>
Sample error
<?xml version="1.0" encoding="UTF-8"?> <error status="error"> <message>The photo cannot be found.</message> </error>
upload_photo
Note that before you can use this method, you must be signed up and activated the developer status in your user panel.
Usage
http://www.dumpyourphoto.com/api/upload_photo/[format]
URL Parameters
-
[format]
- Required
- Value: json or xml
POST Parameters
-
photo[]
- Required
- Note: this must be an array
- title
-
key
- Required
- Value: this is the developer key
Note that the POST data must be formatted as multipart/form-data.
Sample XML response
<?xml version="1.0" encoding="UTF-8"?> <photo status="ok"> <id>23322</id> <hash>FJpLEZ</hash> <title>Title!!</title> <datetime>2009-10-31 13:53:41</datetime> <views>15</views> <url>http://www.dumpyourphoto.com/photo/view/1/FJpLEZ</url> <short_url>http://dyp.im/FJpLEZ</short_url> <sources> <small>http://www.dumpyourphoto.com/files/1/thumbnail/FJpLEZ.jpg</small> <medium>http://www.dumpyourphoto.com/files/1/medium/FJpLEZ.jpg</medium> <large>http://www.dumpyourphoto.com/files/1/FJpLEZ.jpg</large> </sources> </photo>
Sample error
<?xml version="1.0" encoding="UTF-8"?> <error status="error"> <message>The photo cannot be found.</message> </error>
get_all_albums
Note that before you can use this method, you must be signed up and activated the developer status in your user panel.
Usage
http://www.dumpyourphoto.com/api/get_all_albums/[key]/[format]
URL Parameters
-
[key]
- Required
- Value: this is the developer key
-
[format]
- Required
- Value: json or xml
Sample XML response
<?xml version="1.0" encoding="UTF-8"?> <albums status="ok"> <album id="17">Wallpapers</album> </albums>
Sample error
<?xml version="1.0" encoding="UTF-8"?> <error status="error"> <message>The album cannot be found.</message> </error>

