lib/services/facebook/stream.js
function(service, credentials, accounts, keywords) {
  Stream.call(this, service, credentials, accounts, keywords);
  
  // Initialize FBGraph
  fbgraph.setAccessToken(credentials.access_token);
  
  // Set api endpoint URL for subscriber
  this.api_endpoint = 'https://graph.facebook.com/'+ credentials.app_id +'/subscriptions/';
  
  // Initialize subscriber object
  this.subscriber = new Subscriber(credentials, this.callback_url(), this.api_endpoint);
  
  // Initialize responder
  this.responder = new Responder();
  
  // Start listening for incoming
  process.nextTick(function() {
      this.delegateResponder();
    }.bind(this));
  
}
function(service, credentials, accounts, keywords) {
  Stream.call(this, service, credentials, accounts, keywords);
  
  // Initialize FBGraph
  fbgraph.setAccessToken(credentials.access_token);
  
  // Set api endpoint URL for subscriber
  this.api_endpoint = 'https://graph.facebook.com/'+ credentials.app_id +'/subscriptions/';
  
  // Initialize subscriber object
  this.subscriber = new Subscriber(credentials, this.callback_url(), this.api_endpoint);
  
  // Initialize responder
  this.responder = new Responder();
  
  // Start listening for incoming
  process.nextTick(function() {
      this.delegateResponder();
    }.bind(this));
  
}
function ( service , credentials , accounts , keywords ) { Stream . call ( this , service , credentials , accounts , keywords ) ; // Initialize FBGraph fbgraph . setAccessToken ( credentials . access_token ) ; // Set api endpoint URL for subscriber this . api_endpoint = 'https://graph.facebook.com/' + credentials . app_id + '/subscriptions/' ; // Initialize subscriber object this . subscriber = new Subscriber ( credentials , this . callback_url ( ) , this . api_endpoint ) ; // Initialize responder this . responder = new Responder ( ) ; // Start listening for incoming process . nextTick ( function ( ) { this . delegateResponder ( ) ; } . bind ( this ) ) ; }
Manages the streaming connection to Facebook
@constructor
@extends Stream
Manages the streaming connection to Facebook