View Source Avalanche.JWTs.JWTBehaviour behaviour (Avalanche v0.12.2)

Link to this section Summary

Link to this section Callbacks

Link to this callback

create_signer(binary, map)

View Source
@callback create_signer(binary(), map()) :: map()
Link to this callback

generate_claims(keyword, binary)

View Source
@callback generate_claims(
) :: {:ok, map()} | {:error, atom() | keyword()}
@callback peek_claims(binary()) :: {:ok, binary()} | {:error, atom() | keyword()}
@callback peek_header(binary()) :: {:ok, binary()} | {:error, atom() | keyword()}
@callback sign(map(), map()) :: {:ok, binary()} | {:error, binary()}