I would like to create user account using rules, after anonymous user creates a node and inputs his email to a email field. Before that I need to run a condition if the email is already in use. What would be the easiest way of doing this? Using fetch entity by email or using custom php? I read about user_authenticate function but I do not know how to use it. Thank you for advice.
Add a Rules Component that takes a list of users as a parameter and put all the actions in this component. Add a list count comparison condition as less than 1. In the original rule Fetch entity by property of type User with the email address you need to check. Pass the list that is fetched to the Rules Component as the parameter. Only if no users exist with that email address will the actions of creating a new account happen.