code: function (service, sid, timeout) {
      var self = this;
      this.service = service;
      this.sid = sid; // subscrioption id
      this.timeout = timeout; // timeout in seconds
  
      this.timer = setTimeout(function () {
          self._resubscribe();
      }, (this.timeout * 1000) - 5000);
  }
docs: A subscription