protected Event locateUserAndProcess(final RequestContext requestContext,
                                         final PasswordManagementQuery query) throws Throwable {
        val result = sendForgotUsernameEmailToAccount(query, requestContext);
        return FunctionUtils.doIf(result.isSuccess(),
                () -> success(result),
                () -> getErrorEvent("username.failed", "Cannot send the username to given email address", requestContext))
            .get();
    }
Parameter name to look up the user.
support/cas-server-support-pm-webflow/src/main/java/org/apereo/cas/pm/web/flow/actions/SendForgotUsernameInstructionsAction.java