{"_id":"flutter","_rev":"13-9022651e677de324476c17fb4b66d000","name":"flutter","description":"Twitter oAuth Module for the 1.1 API","dist-tags":{"latest":"0.0.5"},"versions":{"0.0.1":{"name":"flutter","version":"0.0.1","description":"Twitter oAuth Module for the 1.1 API","main":"src/Flutter.js","repository":{"type":"git","url":"git://github.com/gosquared/flutter.git"},"keywords":["twitter","oauth"],"author":{"name":"GoSquared","email":"support+npm@gosquared.com"},"contributors":[{"name":"Simon Tabor","email":"simon@gosquared.com"},{"name":"James Taylor","email":"jt@gosquared.com"}],"license":"MIT","bugs":{"url":"https://github.com/gosquared/flutter/issues"},"dependencies":{"oauth":"~0.9.10","debug":"~0.7.2","redis":"~0.9.0"},"homepage":"https://github.com/gosquared/flutter","_id":"flutter@0.0.1","dist":{"shasum":"0462765073fa4b6418196589fe52d8ee3200410b","tarball":"https://registry.npmjs.org/flutter/-/flutter-0.0.1.tgz","integrity":"sha512-L0AZtlfp8glVY68+oMCV7HbQWVNl5oezDnwYTLyHMYRYRpoB6/HaBaO0lS/xb7pHs/WbU/3I1cHYfLA6sMC7Hg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIE+n1H6ARL7StBw79WH8HY4XdRSQWJkCwx7hYOHGmpWhAiA7CER3qJM6L7v4zmIQEfpChxT+evl33//uBve0xyTpBA=="}]},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"jt","email":"jt@gosquared.com"},"maintainers":[{"name":"jt","email":"jt@gosquared.com"}],"directories":{}},"0.0.2":{"name":"flutter","version":"0.0.2","description":"Twitter oAuth Module for the 1.1 API","main":"src/Flutter.js","repository":{"type":"git","url":"git://github.com/gosquared/flutter.git"},"keywords":["twitter","oauth"],"author":{"name":"GoSquared","email":"support+npm@gosquared.com"},"contributors":[{"name":"Simon Tabor","email":"simon@gosquared.com"},{"name":"James Taylor","email":"jt@gosquared.com"}],"license":"MIT","bugs":{"url":"https://github.com/gosquared/flutter/issues"},"dependencies":{"oauth":"~0.9.10","debug":"~0.7.2","redis":"~0.9.0"},"homepage":"https://github.com/gosquared/flutter","_id":"flutter@0.0.2","_shasum":"5e9c3df9152a52c363f7be9ef81fb4e82f29ed7e","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"simontabor","email":"me@simontabor.com"},"maintainers":[{"name":"jt","email":"jt@gosquared.com"},{"name":"simontabor","email":"me@simontabor.com"}],"dist":{"shasum":"5e9c3df9152a52c363f7be9ef81fb4e82f29ed7e","tarball":"https://registry.npmjs.org/flutter/-/flutter-0.0.2.tgz","integrity":"sha512-5vccrsV+HmeCJwkhZPhqYhEzkbn5XFddvLfhVZgXjVdGQhwxNgJD6Pkg33fy0R+d1/VGb8wHDJmx8DxFethkxQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD4SlVdcuu5hHfVeh7LTHF83Pufru8Ou+xeC4122uV0IAIhAJl7OxG4p1lu9tQKTBVIW8h056qqjHfu73niv16ry9IG"}]},"directories":{}},"0.0.3":{"name":"flutter","version":"0.0.3","description":"Twitter oAuth Module for the 1.1 API","main":"src/Flutter.js","repository":{"type":"git","url":"git://github.com/gosquared/flutter.git"},"keywords":["twitter","oauth"],"author":{"name":"GoSquared","email":"support+npm@gosquared.com"},"contributors":[{"name":"Simon Tabor","email":"simon@gosquared.com"},{"name":"James Taylor","email":"jt@gosquared.com"}],"license":"MIT","bugs":{"url":"https://github.com/gosquared/flutter/issues"},"dependencies":{"oauth":"^0.9.13","debug":"^2.2.0","redis":"^0.12.1"},"gitHead":"4516ea63ccfaca69d4f0ccc85390013c51067aae","homepage":"https://github.com/gosquared/flutter","_id":"flutter@0.0.3","scripts":{},"_shasum":"8aaa3a99bf100be42d423256844f59b354a850e6","_from":".","_npmVersion":"1.4.28","_npmUser":{"name":"simontabor","email":"me@simontabor.com"},"maintainers":[{"name":"jt","email":"jt@gosquared.com"},{"name":"simontabor","email":"me@simontabor.com"}],"dist":{"shasum":"8aaa3a99bf100be42d423256844f59b354a850e6","tarball":"https://registry.npmjs.org/flutter/-/flutter-0.0.3.tgz","integrity":"sha512-ob/zh5hNCfbAyAA8AbFigGYldTKfYYLZYyTXsYpf/6Ee5ceo+ryWO6oqiss5MzFMvRLM5zK8Y+xq0mLIhbtwvw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDxz+w4OsZM51EAn0qFuoSxr7S0kTHgnSFP+verAzprBAiEA44/seEzQQ3z6aLx9C8flRx4D4KQzVPVdLg3HPQcp3sw="}]},"directories":{}},"0.0.4":{"name":"flutter","version":"0.0.4","description":"Twitter oAuth Module for the 1.1 API","main":"src/Flutter.js","repository":{"type":"git","url":"git://github.com/gosquared/flutter.git"},"keywords":["twitter","oauth"],"author":{"name":"GoSquared","email":"support+npm@gosquared.com"},"contributors":[{"name":"Simon Tabor","email":"simon@gosquared.com"},{"name":"James Taylor","email":"jt@gosquared.com"}],"license":"MIT","bugs":{"url":"https://github.com/gosquared/flutter/issues"},"dependencies":{"oauth":"^0.9.13","debug":"^2.2.0","redis":"^0.12.1"},"gitHead":"68d5902a0693b307ee3e87ae5f8c175c953777ee","homepage":"https://github.com/gosquared/flutter","_id":"flutter@0.0.4","scripts":{},"_shasum":"0ba99c6d0d4b0f1b97b4e567730e3544d8106f9c","_from":".","_npmVersion":"1.4.28","_npmUser":{"name":"simontabor","email":"me@simontabor.com"},"maintainers":[{"name":"jt","email":"jt@gosquared.com"},{"name":"simontabor","email":"me@simontabor.com"}],"dist":{"shasum":"0ba99c6d0d4b0f1b97b4e567730e3544d8106f9c","tarball":"https://registry.npmjs.org/flutter/-/flutter-0.0.4.tgz","integrity":"sha512-QA4rEihWNitoI6nWBpBPM1v3uHojNnyaQJ4GmOBMtVQnyuy3M3MLH2wT8lLsd54ihblJEJIO0BxjcPvGAgxJXA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCAkNvyOvSPHrZizaAm3UgxAaeXYtsymsK2JW5NLRwSdwIgJHFDOhy2EhDO4jOIvDom9n2aLpp6L/dYD9nJXSYaPEM="}]},"directories":{}},"0.0.5":{"name":"flutter","version":"0.0.5","description":"Twitter oAuth Module for the 1.1 API","main":"src/Flutter.js","repository":{"type":"git","url":"git://github.com/gosquared/flutter.git"},"keywords":["twitter","oauth"],"author":{"name":"GoSquared","email":"support+npm@gosquared.com"},"contributors":[{"name":"Simon Tabor","email":"simon@gosquared.com"},{"name":"James Taylor","email":"jt@gosquared.com"}],"license":"MIT","bugs":{"url":"https://github.com/gosquared/flutter/issues"},"dependencies":{"oauth":"^0.9.13","debug":"^2.2.0","redis":"^0.12.1"},"gitHead":"2958ade1b1d5cf7a57d6fedda844eedf60b1e616","homepage":"https://github.com/gosquared/flutter","_id":"flutter@0.0.5","scripts":{},"_shasum":"545573ba7d4ba93dcd0f8f339b55f5ef7e6d525b","_from":".","_npmVersion":"1.4.28","_npmUser":{"name":"simontabor","email":"me@simontabor.com"},"maintainers":[{"name":"jt","email":"jt@gosquared.com"},{"name":"simontabor","email":"me@simontabor.com"}],"dist":{"shasum":"545573ba7d4ba93dcd0f8f339b55f5ef7e6d525b","tarball":"https://registry.npmjs.org/flutter/-/flutter-0.0.5.tgz","integrity":"sha512-tPqt4+RdIJgmR6pbVtupVUlyPgIAWhOizGtn8gAMHUcKu98tHrUY/l9Ozpb7EEgvgxMUCEjYcU1SipcgZP8egw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAYSctHIxWb4qXelnxl2rQ2/3aBfa99BFFnB9EYLbhCRAiBC+Wqyff8xt9x1pNVIKd+xiUh6eKoytYZqG2p/rSxCbQ=="}]},"directories":{}}},"readme":"# Flutter\n\n[![Dependencies](https://david-dm.org/gosquared/flutter.svg)](https://david-dm.org/gosquared/flutter)\n[![Join the chat at https://gitter.im/gosquared/flutter](https://img.shields.io/badge/gitter-join%20chat-blue.svg)](https://gitter.im/gosquared/flutter)\n\n[![NPM](https://nodei.co/npm/flutter.png?downloads=true&downloadRank=true&stars=true)](https://www.npmjs.com/package/flutter)\n\n## Twitter API authentication and fetching helpers\n\nManaging oauth flow can be a pain and involve a lot of messy code. Flutter helps with that.\n\n## Auth flow example\n\n```js\nvar express = require('express');\nvar Flutter = require('flutter');\n\nvar flutter = new Flutter({\n  consumerKey: 'MY CONSUMER KEY',\n  consumerSecret: 'MY CONSUMER SECRET',\n  loginCallback: 'http://my-host/twitter/callback',\n\n  authCallback: function(req, res, next) {\n    if (req.error) {\n      // Authentication failed, req.error contains details\n      return;\n    }\n\n    var accessToken = req.session.oauthAccessToken;\n    var secret = req.session.oauthAccessTokenSecret;\n\n    // Store away oauth credentials here\n\n    // Redirect user back to your app\n    res.redirect('/back/to/app');\n  }\n});\n\nvar app = express();\n\napp.get('/twitter/connect', flutter.connect);\n\n// URL used in loginCallback above\napp.get('/twitter/callback', flutter.auth);\n\n\n// Direct users to /twitter/connect to initiate oauth flow.\n```\n\n\n## Querying Twitter API\n\nCurrently only `GET` functions are supported\n\n```js\n// var {accessToken, secret} = retrieve credentials for request\n\nflutter.API.get('search/tweets.json', { q: 'bacon' }, accessToken, secret, function(err, results) {\n  console.log(results); // { statuses: [ { ...etc } ] }\n});\n```\n\n## Options\n\n```js\nvar flutter = new Flutter({\n\n  // Pass this to log messages inside Flutter\n  debug: function(msg){ ... },\n\n  // Twitter API app credentials\n  consumerKey: 'foo',\n  consumerSecret: 'bar',\n\n  // Twitter API login callback\n  loginCallback: 'http://foo.com/authCallback',\n\n  // the URL to redirect to after authorisation is complete and we have tokens\n  // will not be used if authCallback is overridden\n  completeCallback: 'http://foo.com/completeCallback',\n\n  // called immediately before the user is redirected to Twitter's authorize\n  // screen, used this to stash parameters etc on the request session\n  connectCallback: function(req, res, next){},\n\n  // Called on successful auth.\n  // req.session contains auth parameters (see above)\n  // if not defined, Flutter will redirect to completeCallback specified above\n  authCallback: function(req, res, next){},\n\n  // Cache lifetime to use for API requests. Set to something falsy to disable cache\n  cache: 60000,\n\n  // Redis config. Used for caching api responses.\n  // `options` is passed to redis.createClient (https://github.com/NodeRedis/node_redis#rediscreateclient)\n  redis: { host: 'localhost', port: 6379, database: 0, options: {} },\n\n  // set this to a redis client to use instead of creating a new one\n  cacheClient: redisClient,\n\n  // Key prefix used on all cache keys in redis\n  prefix: 'flutter:'\n\n});\n```\n","maintainers":[{"email":"me@simontabor.com","name":"simontabor"},{"email":"jt@gosquared.com","name":"jt"}],"time":{"modified":"2022-06-18T02:27:45.019Z","created":"2014-04-10T10:29:20.746Z","0.0.1":"2014-04-10T10:29:20.746Z","0.0.2":"2014-08-07T16:33:06.058Z","0.0.3":"2015-07-22T14:09:10.886Z","0.0.4":"2015-08-12T09:27:55.280Z","0.0.5":"2015-08-13T17:30:44.658Z"},"homepage":"https://github.com/gosquared/flutter","keywords":["twitter","oauth"],"repository":{"type":"git","url":"git://github.com/gosquared/flutter.git"},"contributors":[{"name":"Simon Tabor","email":"simon@gosquared.com"},{"name":"James Taylor","email":"jt@gosquared.com"}],"author":{"name":"GoSquared","email":"support+npm@gosquared.com"},"bugs":{"url":"https://github.com/gosquared/flutter/issues"},"license":"MIT","readmeFilename":"README.md","users":{}}