photo-front/documentation/api/Readme.markdown

48 lines
1.3 KiB
Markdown

Open Photo API
=======================
#### OpenPhoto, a photo service for the masses
----------------------------------------
### How do I authenticate?
The Open Photo API uses [OAuth1.0a][oauth1.0a] for authentication. See the complete [guide on authentication][authentication] for details.
_NOTE:_ OAuth2 isn't yet enabled.
### What's the response format?
Every API endpoint returns a JSON response in a [standard envelope][Envelope].
{
message: "A string describing the response",
code: 200,
result: {
foo: "bar"
}
}
### API Endpoints
1. [GET /hello.json][GetHelloWorld]
Test endpoint.
1. [GET /photos/list.json][GetPhotos]
Get a list of the user's photos.
1. [GET /photo/:id/view.json][GetPhoto]
Get a user's photo.
1. [POST /photo/upload.json][PostPhotoUpload]
Upload a new photo.
1. [GET /tags/list.json][GetTags]
Get a user's tags.
1. [POST /tag/:id/update.json][PostTag]
Modify meta data for a user's tag.
[Envelope]: api/Envelope.markdown
[GetHelloWorld]: api/GetHelloWorld.markdown
[GetPhotos]: api/GetPhotos.markdown
[GetPhoto]: api/GetPhoto.markdown
[GetTags]: api/GetTags.markdown
[PostPhotoUpload]: api/PostPhotoUpload.markdown
[PostTag]: api/PostTag.markdown
[authentication]: api/Authentication.markdown
[oauth1.0a]: http://oauth.net/core/1.0a/