code: function createToken(userId, channel, tokenList) {
      var profile, secret, expire, token;
      profile = {
          clientId: userId,
          session: channel.session
      };
  
      secret = channel.secret;
      expire = 60*60*5;
      // We are sending the profile in the token.
      token = jwt.sign(profile, secret, { expiresIn: expire});
  
      // Store the token somewhere.
      tokenList[token] = profile;
  
      return token;
  }
docs: ### createToken
  
  Creates a signed JSON web token
  
  @param {string} userId The id of the user
  @param {object} channel An object containing the channel's secret
  the channel's session id
  @param {object} tokenList An object used to map the tokens to user profiles
  
  @return {string} The signed JSON web token