View Source Lightning.Tokens (Lightning v2.10.4)

Token generation, verification and validation.

Summary

Functions

Get the subject of a token. Currently support RunTokens and PersonalAccessTokens, which return Lightning.Runs and Lightning.Accounts.Users respectively.

Verify a token and return the claims if successful.

Functions

Get the subject of a token. Currently support RunTokens and PersonalAccessTokens, which return Lightning.Runs and Lightning.Accounts.Users respectively.

@spec verify(String.t()) :: {:ok, map()} | {:error, any()}

Verify a token and return the claims if successful.

This serves as a central point to verify and validate different types of tokens.