Idea for Central App Development for SAAS

Dear All,

I am serving via ERPNEXT SAAS.

now i want to build an app to make sumilar to clone.

Is it possible some one can share the ideas hera.


It is possible.

You can write your logic for the deployment of a new bench or new site based on customer subscription.

For automated deployment, you can use or any other python packages available which help you connect ssh and perform commands.

If anyone is building any application using frappe framework, first try to manage the SaaS/Tenancy using a tenant_id in same database.

Do not complicate the infrastructure setup and site creation for tenant initiation where you have a choice to add app-level multi-tenancy.

Initiating a tenant in single database is faster than initiating new database. If needed tenant (sub)domain(s) can be configured using nginx/ingress.

To build frappcloud like SaaS, you’ll need frappe tech like team.


Hi @revant_one,
Can you please elaborate?

Is this existing column/table in the frappe database?

Is this different than the “conventional” multi-tenancy (from the multi tenants bench command)?

But multi databases is the standard behaviour of bench new-site command. Are you suggesting to change this? How?

I’m asking these questions because you said “building any application using frappe framework”. So these might affect the multi-tenancy even if it is not for Saas?

Thank you


  • Add Tenant Doctype
  • Add tenant_id link field on each doctype part of app
  • Allow access based on tenant_id
  • Add tenant means : add instance of Tenant DocType and add docs linked to that tenant.

this approach is open for improvement and discussion.

as far I know there is no Tenant Doctype.

Yes. conventional way is db level multi tenency.
it’s another approach, none of these approaches are better than other. Both have their benefits.

I was just trying to be simple and add a doctype and link field. Probably first few lessons from library management teaches this.

I’m not even suggesting to change anything on bench.

I didn’t get you. I’m not changing any bench commands?

as far as the new frappe app is considered, it need not be aware there is bench level multi tenency.

and for the bench there are just set of frappe apps installed on a single frappe site.

check this video for ideas in general:

1 Like

You can create your own front-end website and use FrappeCloud as a backend to create your sites (If you are interested, we can share APIs for site creation, management etc)

1 Like

Yes sure, Please share that already we have done maximum things and only site creation makes some problems.


It would be great if the codes are shared like @rmehta mentioned.
But in the mean time you can use the codes from bench_manager app. Or install the bench manager and call the method to create sites from bench_manager.

@rmehta Dear can i have the API details asper your previous message.

@gsbaig We’ve published a minimal API on Frappe Cloud Documentation / API.

If you have any questions, then please create a support ticket.

1 Like