Tenant ID
Multi-Tenant Apps¶
Many modern apps are built as multi-tenant applications, and Gainly offers out-of-the-box support for searching data within these apps.
Tenant ID¶
A document added to Gainly semantic index can be associated with an optional tenant_id
. Then you can specify one or more tenant_id
values while performing searches.
B2B Apps¶
If your app is business-to-business (B2B), where your customers are companies, you can set the tenant_id
to the ID of the company that owns the document.
B2C Apps¶
If your app is business-to-consumer (B2C), where your customers are individual users, you can set the tenant_id
to the ID of the user that owns the document.
Apps for Internal Use¶
If your app is for internal use within your company/organization, and you want all users to access all documents, you can use a generic value like all-departments
as the tenant_id
for all documents.
On the other hand, if you want to silo documents based on departments, you can use tenant_id
values such as Engineering
, Sales
, and so on.
More Complex Needs¶
If your multi-tenancy requirements are more complex, you can address them using custom metadata instead of tenant_id
.
Feel free to reach out to us if you have additional questions on implementing search for your multi-tenant applications.