jwt-express.js
function(payload) {
        payload.stales = Date.now() + this.options.stales;
        
        this.payload = payload;
        this.token = utils.sign(this.payload, this.secret, this.options.signOptions);
        this.valid = true;
        this.expired = false;
        this.stale = false;
        
        return this;
    }
function(payload) {
        payload.stales = Date.now() + this.options.stales;
        
        this.payload = payload;
        this.token = utils.sign(this.payload, this.secret, this.options.signOptions);
        this.valid = true;
        this.expired = false;
        this.stale = false;
        
        return this;
    }
sign - generate a new token from the payload
@param object payload The payload to sign
@return this