Multi-Tenancy Guide
Tenzro Platform is built with multi-tenancy as a core principle, providing complete isolation between organizations while enabling efficient resource sharing.
Architecture Overview
Each tenant operates in an isolated environment with dedicated:
- Database schemas and encryption keys
- API endpoints with custom domains
- Resource quotas and rate limits
- Audit logs and compliance controls
Tenant Provisioning
New tenants are provisioned through the Provision Service API:
POST /api/provision/tenant
Content-Type: application/json
{
"name": "acme-corp",
"plan": "enterprise",
"region": "us-central1",
"config": {
"customDomain": "api.acme.com",
"features": ["custody", "bridge", "ai"]
}
}Tenant Isolation
Data Isolation
All tenant data is stored in isolated database schemas with row-level security policies. Each tenant has unique encryption keys for data at rest.
Network Isolation
Tenants are deployed in separate Kubernetes namespaces with network policies preventing cross-tenant communication.
Authentication Isolation
Each tenant has isolated user directories. JWT tokens are scoped to specific tenants and cannot be used across organizations.
Tenant Context
The tenant context is automatically derived from:
- Custom domain (e.g., api.acme.com)
- X-Tenant-ID header
- JWT token claims
// All API requests are automatically scoped to the tenant
const response = await fetch('https://api.acme.com/api/wallet/list', {
headers: {
'Authorization': 'Bearer <token>',
// X-Tenant-ID is optional when using custom domain
}
});Resource Quotas
Each tenant has configurable resource quotas:
| Resource | Starter | Professional | Enterprise |
|---|---|---|---|
| API Requests/day | 10,000 | 100,000 | Unlimited |
| Wallets | 100 | 1,000 | Unlimited |
| Storage | 1 GB | 10 GB | Custom |
| Users | 10 | 100 | Unlimited |
Tenant Administration
Tenant administrators can manage their organization through the console:
- User and role management
- API key configuration
- Webhook subscriptions
- Usage monitoring and billing
Cross-Tenant Operations
Platform administrators can perform cross-tenant operations using admin credentials:
// Admin API - requires platform admin credentials
GET /admin/tenants
GET /admin/tenants/:id/usage
POST /admin/tenants/:id/suspend
DELETE /admin/tenants/:id