private void createAccount(final Namespace namespace, final String username) {
        final String password = namespace.getString(PASSWORD_ARG_NAME);
        final String email = namespace.getString(EMAIL_ARG_NAME);
        final String firstName = namespace.getString(FIRST_NAME_ARG_NAME);
        final String lastName = namespace.getString(LAST_NAME_ARG_NAME);
        final boolean noPasswordChange = namespace.getBoolean(NO_PASSWORD_CHANGE);
        final boolean neverExpires = namespace.getBoolean(NEVER_EXPIRES_CHANGE_ARG_NAME);
        final long now = System.currentTimeMillis();

        LOGGER.info("Creating account for user '{}'", username);

        CreateAccountRequest createAccountRequest = new CreateAccountRequest(
                firstName,
                lastName,
                username,
                email,
                null,
                password,
                password,
                !noPasswordChange,
                neverExpires);

        accountService.create(createAccountRequest);
    }
Creates an account in the internal identity provider
stroom-app/src/main/java/stroom/app/commands/CreateAccountCommand.java