Class JWTEncoder

  • All Implemented Interfaces:
    AdaptrisComponent, ComponentLifecycle, ComponentLifecycleExtension, MessageEventGenerator, Service, StateManagedComponent

    @ComponentProfile(summary="Encode a header and body to a JSON Web Token",
                      tag="jwt,encode,json,web,token",
                      since="3.11.1")
    public class JWTEncoder
    extends ServiceImp
    This service provides a way to encode data as a JSON Web Token.
    
        <jwt-encode>
          <unique-id>jwt-encode</unique-id>
          <header class="multi-payload-string-input-parameter">
            <payload-id>header</payload-id>
          </header>
          <claims class="multi-payload-string-input-parameter">
            <payload-id>claims</payload-id>
          </claims>
          <secret class="base64-encoded-secret">
            <secret>c64975ba3cf3f9cd58459710b0a42369f34b0759c9967fb5a47eea488e8bea79</secret>
          </secret>
          <jwt-output class="multi-payload-string-output-parameter">
            <payload-id>output</payload-id>
          </jwt-output>
        </jwt-encode>
     

    In the adapter configuration file this class is aliased as jwt-encode which is the preferred alternative to the fully qualified classname when building your configuration.