This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var payload = []; | |
| flow.users.forEach(function(user) { | |
| if ((((Date.now()/1000) - (user.last_activity/1000))/60) < 10) { | |
| payload.data.push( | |
| { title: | |
| { text: user.nick }} | |
| ); | |
| } | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Session = require('flowdock').Session; | |
| var session = new Session('personal-api-token'); | |
| var stream = session.stream('flow-id'); | |
| stream.on('message', function (message) { | |
| console.log(message.tags); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "item": 10, | |
| "min": { | |
| "value": 0 | |
| }, | |
| "max": { | |
| "value": 30 | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "api_key": "example-api-key", | |
| "data": | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "api_key": "example-api-key", | |
| "data": { | |
| "item": 10, | |
| "min": { | |
| "value": 0 | |
| }, | |
| "max": { | |
| "value": 30 | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var request = require('request'); | |
| var Session = require('flowdock').Session; | |
| var flowdocck_api_token = ''; | |
| var flowdock_flow_id = ''; | |
| var geckoboard_api_key = ''; | |
| var geckoboard_post_url = ''; | |
| var day = Date.now()/1000; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var request = require('request'); | |
| var app = require('express')(); | |
| app.set('port', (process.env.PORT || 5000)); | |
| app.get('/', function(req, res) { | |
| request('https://c4b38761eb82525d2b674bcb7bc2ca05@api.flowdock.com/flows/geckoboard/flowdock-api-tests', | |
| function (error, response, flow) { | |
| if (error) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var request = require('request'); | |
| var app = require('express')(); | |
| var flowdock_flow_url = ''; | |
| app.set('port', (process.env.PORT || 5000)); | |
| app.get('/', function(req, res) { | |
| request(flowdock_flow_url, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { event: 'activity.user', | |
| tags: ['production', 'awesome', 'development'], | |
| uuid: null, | |
| persist: false, | |
| id: 1783, | |
| flow: 'flow-id', | |
| content: 'This is a message with hashtags #production #awesome #development :)', | |
| sent: 1426043868052, | |
| app: null, | |
| created_at: '2015-03-11T03:17:48.052Z', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| curl -X POST https://push.geckoboard.com/v1/send/example-widget-key '{"api_key":"example-api-key","data":{"item":23,"min":{"value":0}, \"max":{"value":30}}}' -H "Content-Type:application/json" |
OlderNewer