private static void exportAuditableEvents(final File dataPath) {
        var parentPath = new File(dataPath, "audits");
        var properties = new ArrayList<Map<?, ?>>();
        if (parentPath.exists()) {
            FileUtils.deleteQuietly(parentPath);
        }
        if (!parentPath.mkdirs()) {
            LOGGER.debug("Unable to create directory");
        }
        Arrays.stream(AuditableActions.class.getDeclaredFields())
            .filter(it -> Modifier.isStatic(it.getModifiers()) && Modifier.isFinal(it.getModifiers()))
            .forEach(it -> {
                var event = new LinkedHashMap();
                event.put("name", it.getName());
                LOGGER.debug("Adding audit [{}]", event);
                properties.add(event);
            });
        if (!properties.isEmpty()) {
            var configFile = new File(parentPath, "config.yml");
            CasConfigurationMetadataCatalog.export(configFile, properties);
        }
    }
This is {@link CasDocumentationApplication}.

@author Misagh Moayyed
@since 6.4.0
docs/cas-server-documentation-processor/src/main/java/org/apereo/cas/documentation/CasDocumentationApplication.java