andreasewering/protobuf-web-tokens/1.0.1

NOTE: the latest version is 1.0.2

Renamed to anmolitor/protobuf-web-tokens. It is published under that name, and new versions come out there.

Versions published as andreasewering/protobuf-web-tokens still install under that name. 2 versions of 3 come from the new location (see their notes).

Rerouted (renamed, verified). The GitHub user or repository was renamed. The tag is still there, at the new name. The Lamdera package server serves a copy recovered from https://github.com/anmolitor/protobuf-web-tokens.

What we checked: The repo moved to github.com/anmolitor/protobuf-web-tokens. Rebuilt with git archive from commit 51b9d3c4f67c of https://github.com/anmolitor/protobuf-web-tokens (zip prefix andreasewering-protobuf-web-tokens-661847b/, America/Los_Angeles times): the zip is byte-identical to the one package.elm-lang.org recorded, SHA-1 ff65abaf279e155ca048bed930dd9d6412a8afdc.

The Lamdera compiler uses this copy and prints a one-line notice saying so. elm itself fails to download this version.

Details · package.elm-lang.org's zip: https://github.com/andreasewering/protobuf-web-tokens/zipball/1.0.1/

Protobuf.Token

Decode Protobuf Web Tokens (PWT)

type alias TokenData t =
{ validUntil : Posix
, claims : t
}

Claims encoded in the token and some metadata

decode : Decoder t -> String -> Result Error (TokenData t)

Decodes a Protobuf Web Token using the given decoder.

type Error
= InvalidFormat
| InvalidBase64
| InvalidBytes
| NoValidUntilField

The ways a token decoding can fail