5 releases (1 stable)

Uses old Rust 2015

1.0.0 Sep 14, 2022
0.3.0 Jul 31, 2018
0.2.0 Jul 31, 2018
0.1.1 Jul 31, 2018
0.1.0 Jul 31, 2018

#159 in #token

Download history 69/week @ 2024-07-29 1/week @ 2024-09-23 31/week @ 2024-09-30

87 downloads per month

MIT license

8KB
157 lines

Web token

Easy to use WebToken for rust

Build Status codecov

Usage

Features: ["serde_support", "diesel_support"]

// Create new random token
let new_token = WebToken::new();

// Get an existing token
let incoming_token: WebToken = request.header("X-Custom-Token").parse().unwrap();
assert_eq!(incoming_token, request.header("X-Custom-Token"));

Dependencies

~0.2–1MB
~19K SLoC