Hi
This is what I have done to achieve my goal for multi tenancy in fusio ,
1. I already create a service let say "tenancy" service,
this service will support for member creation by tenant owner,
the principle is just create an user that have backend scope. and then in "tenancy" service, I create a function which will call to /backend/user route to help create a user (tenant member) on behalf of current tenant owner user.
by this way, the tenant owner is just a common user who registered it self from developer app (tenant owner have a consumer scope only, no admin access to backend app)
every tenant member that have been created, also own a custom user attributes ( tenant_id ) inherit from tenant owner (tenant_id)
2. I have changes developer app by adding 1 submenu for listing tenant member and button for member creation.
All request header from developer app, has been added by tenant_id header.
3. (TO DO), Monetization part. My challenges now is how to make a contract that has been selected by tenant owner will also apply to all of its members. And the points owned by the tenant owner will also decrease every time tenant member makes a request to API endpoints.
at least by this way, I reduce to touch the core of fusio for future update.