private static Pair<String, String> getEndpoint(final Class clazz) {
        if (Modifier.isAbstract(clazz.getModifiers())) {
            return null;
        }
        
        var endpoint = (Endpoint) clazz.getAnnotation(Endpoint.class);
        if (endpoint != null) {
            return Pair.of(endpoint.id(), endpoint.annotationType().getSimpleName());
        }
        LOGGER.debug("[{}] is not an Endpoint. Checking for WebEndpoint...", clazz.getName());
        var webEndpoint = (WebEndpoint) clazz.getAnnotation(WebEndpoint.class);
        if (webEndpoint != null) {
            return Pair.of(webEndpoint.id(), webEndpoint.annotationType().getSimpleName());
        }
        LOGGER.debug("[{}] is not an Endpoint. Checking for RestControllerEndpoint...", clazz.getName());
        var restEndpoint = (RestControllerEndpoint) clazz.getAnnotation(RestControllerEndpoint.class);
        if (restEndpoint != null) {
            return Pair.of(restEndpoint.id(), restEndpoint.annotationType().getSimpleName());
        }
        LOGGER.debug("[{}] is not an Endpoint. Checking for ControllerEndpoint...", clazz.getName());
        var ctrlEndpoint = (ControllerEndpoint) clazz.getAnnotation(ControllerEndpoint.class);
        if (ctrlEndpoint != null) {
            return Pair.of(ctrlEndpoint.id(), ctrlEndpoint.annotationType().getSimpleName());
        }
        LOGGER.warn("Unable to determine endpoint from [{}]", clazz.getName());
        return null;
    }
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