Mocks the content provider's role in OAuth Echo
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app
config
db
doc
log
public
script
test
vendor
README
Rakefile

README

This is a very small Ruby on Rails app that mocks the content provider role in the unofficial OAuth Echo protocol. The responses it provides are reminiscent of the API for image providers like TwitPic, Lockerz, etc.

It requires no database and has no real view layer.

Usage:

* The server runs by default on port 3000:
   ./script/server

* It provides a /api/upload end point.
  * pass success=1 to force success without performing the echo'd request.
  * pass fail=1 to force failure without performing the echo'd request
  * pass media_id=xyz to change mock file name of the uploaded image
  * pass media_url=http://domain.com to change mock domain of the uploaded image
* Requests containing the appropriate OAuth Echo HTTP headers or parameters will be executed against the service provider indicated in those headers.
  * A XML 200 OK response will be returned if the OAuth Echo request was succesful
  * A XML 401 response will be returned if it was not.

* See app/controllers/api_controller.rb for the meaty bits.