Deed JWT
General-purpose HS256 sign/verify, signed with a 32-byte key unique to your slice. You never see, set, or rotate it. The platform holds it and uses it on both sides. KeyAuth mints its tokens through this primitive, and Pocket verifies them.
token, _ := drift.Deed.JWT.Issue(drift.JWTClaims{Sub: user.ID, Exp: exp})
claims, err := drift.Deed.JWT.Verify(token, drift.JWTVerifyOptions{})Issue requires an exp in the future and refuses without one; iat, iss and jti are filled in for you. Verify checks the signature, the algorithm, exp, nbf, and that iss is this slice, plus aud when you pass an audience. A failure carries one of nine stable reasons: malformed, bad_signature, expired, not_yet_valid, wrong_algorithm, wrong_issuer, wrong_audience, invalid_claims, missing_exp.
Verify session tokens inside the function.
The runner recognises two
@atomic auth= values: none and apikey. Any other value deploys without complaint and then answers 403 unknown auth type to every caller, including one presenting a perfectly valid token from this slice. A route that needs a session reads the Authorization header itself and calls JWT.Verify.