ERPNext Foundation ERPNext Cloud User Manual Blog Discuss Frappé* Donate

Setting Default Role on user sign up




Is there a way of setting a default Role e.g Customer with desk access and other access rights so that everyone who signs up get assigned to that Role by default.

Maybe even assigning that default role when posting a new user through REST API.



See Portal Settings


Where can I set the default role for users signing up with LDAP? It is currently “Blogger”. We want to have them as webshop customers, as all customers are in LDAP.

New LDAP users seem to be hardcoded to become a “Blogger” in

PROPOSAL: add “Default role for new user” to LDAP settings DocType

Workaround done: add to role blogger the permissions “Request” und “Invoice” and remove permission to use desktop


After migrating to v11, by adding all permissions of the role “Customer” to “Blogger” seems not to be sufficient anymore to allow a “Blogger” to finish an order in the webshop. It ends up with a window showing “Customer” - required to login. But the user had already logged in.


I finally made it working by patching frappe/integrations/doctype/ldap_settings/ and replacing Blogger with Customer


I’m just getting some ldap changes merged at the moment, but your idea is a good one, I’ll submit a pr with this as an option


@cjpit I submitted already a PR - maybe this simple one is then obsolete.

However, it turns out, that a new user with role “customer” has to exist in ERPnext before user can login. This restriction (which we do not have for the role “blogger”) does not allow to sign up. No idea where this is being configured, definetely not in the permissions list.

Remember, our use case is allowing LDAP users to sign up first time when ordering an item in the web shop.


Hi @rasos , I’d make the option generic, so you can choose what role you want the user to be on creation/login. We also have a requirement to map ldap roles to erpnext roles, so I’ll add that option as well.