Function simple_jwt::encode [] [src]

pub fn encode<T: JWTStringConvertable>(
    body: &T,
    secret: &str,
    alg: Algorithm
) -> Result<String>

encode a Claim to jwt string, if you are using RS256/384/512, secret should be your private key