twitter-oauth-echo
v1.0.1
Published
Express Middleware for Twitter Oauth Echo
Downloads
1
Readme
Installation
npm install twitter-oauth-echo --save
Basic Usage
Request must contain x-auth-service-provider and x-verify-credentials-authorization headers.View resources for more info.
var express = require('express');
var app = express();
var twitterEcho = require('twitter-oauth-echo');
app.use(twitterEcho({ errorMessage : 'You are not authorized' }));
//errorMessage defaults to UnAuthorized
Sample usage with express.Router object.
var express = require('express');
var twitterEcho = require('twitter-oauth-echo');
var router = express.Router();
//check for all routes and methods of router
router.all('*' , twitterEcho());
router.get('/hello' , function(req , res ){
res.send('hello will be sent if req is authorized.');
});
module.exports = router ;
Resources
License
This repository is licensed under the MIT License