Is it possible to use ERPNext solely as a backend API? I’m looking to avoid using all its functionalities because it includes a lot of features that I don’t need. Instead, I’d like to develop my own custom frontend.
To achieve this, I initially tried installing only the ERPNext repository. However, I soon realized that I also needed the Frappe repository since it’s the framework ERPNext relies on. So, I created a new directory with both repositories and attempted to run it using Docker. I set up a Dockerfile, requirements.txt, and other necessary files to initialize the API. Despite my efforts, I haven’t been able to get it running.
I have two questions:
Is it feasible to set up ERPNext as a backend API in the way I’m envisioning?
General practice with frappe frontends is packing static assets, service workers, login experience and all other things as frappe www route. That means the frontend and backend is served through same site, it is using cookies and session created on the same domain. Packing the js/css/html in www pages will only allow you to serve frontend tied with the backend. Check frappe/hrms, frappe/helpdesk.
If you are looking to serve the frontend from separate domain/sub-domain altogether and just expose /api/* routes for frappe site’s domain so no one can visit /desk or /app on frappe site, you will need something like following with oauth2/oidc.
Optionally you can expose full desk/app view under your VPN for your admins.