public static String generateToken(final String userName, final String key, final String clientId, final Long expireSeconds) {
        try {
            return JWT.create()
                    .withClaim("userName", userName)
                    .withClaim("clientId", clientId)
                    .withExpiresAt(new Date(System.currentTimeMillis() + Optional.ofNullable(expireSeconds).orElse(TOKEN_EXPIRE_SECONDS)))
                    .sign(Algorithm.HMAC256(key));
        } catch (IllegalArgumentException | JWTCreationException e) {
            LOG.error("JWTToken generate fail ", e);
        }
        return StringUtils.EMPTY_STRING;
    }
generate jwt token.

@param userName      login's userName
@param key           secretKey
@param clientId      clientId
@param expireSeconds expireSeconds
@return token
shenyu-admin/src/main/java/org/apache/shenyu/admin/utils/JwtUtils.java