Athena::Mercure::TokenFactory::Interface
A token factory is responsible for creating the token used to authenticate requests to the Mercure hub.
Instance methods
create(subscribe : Array(String) | Nil = [] of String, publish : Array(String) | Nil = [] of String, additional_claims : Hash | Nil = nil) : String
Returns a JWT token that has access to subscribe and publish to the provided topics. Optionally, additional_claims may be added to the JWT.