diff options
author | franck cuny <franck@lumberjaph.net> | 2010-09-13 13:31:19 +0200 |
---|---|---|
committer | franck cuny <franck@lumberjaph.net> | 2010-09-13 13:31:19 +0200 |
commit | dad53039ca774b766c96309b21c893334195c51a (patch) | |
tree | 2f8255c7d0f98308777234b610302efbb8da42bb | |
download | api-description-dad53039ca774b766c96309b21c893334195c51a.tar.gz |
initial import
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | README | 13 | ||||
-rw-r--r-- | apps/couchdb.json | 77 | ||||
-rw-r--r-- | services/github.json | 33 | ||||
-rw-r--r-- | services/twitter.json | 27 |
5 files changed, 151 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..2a61605 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +*.yaml \ No newline at end of file diff --git a/README b/README new file mode 100644 index 0000000..76fd786 --- /dev/null +++ b/README @@ -0,0 +1,13 @@ +# SPORE - Specification to a POrtable Rest Environment + +## DESCRIPTION + +## SPECIFICATIONS + +### APPS + +Description for applications (couchdb, ...) + +### SERVICES + +Descriptions for services (twitter, github, ...) diff --git a/apps/couchdb.json b/apps/couchdb.json new file mode 100644 index 0000000..f7c44b2 --- /dev/null +++ b/apps/couchdb.json @@ -0,0 +1,77 @@ +{ + "version" : "0.1", + "methods" : { + "create_document_without_id" : { + "required" : [ + "database" + ], + "path" : "/:database", + "method" : "POST" + }, + "get_all_documents" : { + "params" : [ + "descending", + "startkey", + "endkey", + "limit", + "include_docs" + ], + "required" : [ + "database" + ], + "path" : "/:database/_all_docs", + "method" : "GET" + }, + "create_document_with_id" : { + "required" : [ + "database", + "doc_id" + ], + "path" : "/:database/:doc_id", + "method" : "POST" + }, + "get_document" : { + "params" : [ + "rev", + "revs" + ], + "required" : [ + "database", + "doc_id" + ], + "path" : "/:database/:doc_id", + "method" : "GET" + }, + "get_all_documents_by_seq" : { + "params" : [ + "startkey", + "endkey", + "limit", + "include_docs" + ], + "required" : [ + "database" + ], + "path" : "/:database/_all_docs_by_seq", + "method" : "GET" + }, + "delete_document" : { + "params" : [ + "rev" + ], + "required" : [ + "database", + "doc_id" + ], + "path" : "/:database/:doc_id", + "method" : "DELETE" + } + }, + "api_format" : [ + "json" + ], + "name" : "CouchDB", + "author" : [ + "franck cuny <franck@lumberjaph.net>" + ] +} diff --git a/services/github.json b/services/github.json new file mode 100644 index 0000000..44a295e --- /dev/null +++ b/services/github.json @@ -0,0 +1,33 @@ +{ + "declare" : { + "api_base_url" : "http://github.com/api/v2/", + "api_format_mode" : "content-type", + "api_format" : "json" + }, + "methods" : { + "user_information" : { + "params" : [ + "username", + "format" + ], + "required" : [ + "username", + "format" + ], + "path" : "/:format/user/show/:username", + "method" : "GET" + }, + "user_following" : { + "params" : [ + "user", + "format" + ], + "required" : [ + "user", + "format" + ], + "path" : "/:format/user/show/:user/followers", + "method" : "GET" + } + } +} diff --git a/services/twitter.json b/services/twitter.json new file mode 100644 index 0000000..f07470e --- /dev/null +++ b/services/twitter.json @@ -0,0 +1,27 @@ +{ + "declare" : { + "api_base_url" : "http://api.twitter.com/1", + "api_format_mode" : "append", + "api_format" : "json" + }, + "methods" : { + "public_timeline" : { + "params" : [ + "skip_user" + ], + "path" : "/statuses/public_timeline", + "method" : "GET" + }, + "home_timeline" : { + "params" : [ + "since_id", + "max_id", + "count", + "page", + "skip_user" + ], + "path" : "/statuses/home_timeline", + "method" : "GET" + } + } +} |