code: public String toJwt() {
          Map<String, Object> headers = new HashMap<>();
          headers.put("typ", "JWT");
          headers.putAll(this.getHeaders());
  
          JwtBuilder builder =
              Jwts.builder()
                  .signWith(this.algorithm, this.secretKey)
                  .setHeaderParams(headers)
                  .setIssuer(this.issuer)
                  .setExpiration(expiration);
  
          if (this.getClaims() != null) {
              for (Map.Entry<String, Object> entry : this.getClaims().entrySet()) {
                  builder.claim(entry.getKey(), entry.getValue());
              }
          }
  
          if (this.getId() != null) {
              builder.setId(this.getId());
          }
  
          if (this.getSubject() != null) {
              builder.setSubject(this.getSubject());
          }
  
          if (this.getNbf() != null) {
              builder.setNotBefore(this.getNbf());
          }
  
          return builder.compact();
      }
docs: Encode a JWT.
  
  @return encoded JWT