Built for Multitenancy: How Fastn UCL Manages Context and Isolation at Scale?
Last updated
Was this helpful?
Last updated
Was this helpful?
AI-native apps don’t run in a vacuum—they run across workspaces, users, and tenants. When your AI agent is expected to interact with Slack for one customer, Gmail for another, and Notion for a third, the system behind it must know whose data to fetch, which app to talk to, and how to do it securely.
That’s why Fastn UCL (Unified Command Layer) is built with multitenancy at its core—not as an afterthought.
Many early-stage tools—especially those using just the MCP protocol or a gateway vendor—are built around the assumption of a single tenant or user. That’s fine for personal use or prototyping.
But in a real SaaS product, your AI assistant might receive:
A command from Customer A to send a Slack reminder
A command from Customer B to retrieve a Google Doc
A command from Customer C to create a Jira task
Each of these customers has their own:
Workspace and tools
Auth tokens and permissions
Isolation and compliance requirements
Without multitenancy, you'd be forced to spin up and manage separate infrastructure for each customer. That doesn't scale.
Fastn UCL is designed to make multitenant integration seamless, with features like:
Each incoming command carries metadata—such as tenant ID, user ID, and workspace context—so Fastn knows exactly who made the request and which connector to use.
Fastn UCL dynamically routes each MCP command to the correct tool, tenant, and workspace based on your configuration. You don’t need to hardcode logic or write glue code.
OAuth tokens and API keys are securely stored and scoped to individual tenants and connectors. There’s no leakage between tenants, even when they use the same tools.
Fastn UCL provides per-tenant logs, metrics, and error reports—so you can debug and monitor integrations without crossing workspace boundaries.
You can define multiple workspaces per account, each with its own connector configuration, usage limits, and access controls. Switching context is seamless and automatic.
Let’s look at what this looks like when configuring Fastn UCL with Cursor:
The tenant_id
and space_id
here allow Fastn to isolate access per customer. Even if customers use the same underlying tools (e.g. Slack), each call is made using their tokens, with their scope.
This configuration supports:
Multiple customers using the same AI assistant
Each customer getting personalized results
Strict separation between workspaces and environments
Suppose you’re building a “Daily Summary” feature powered by an AI agent.
Customer A uses Slack to receive the summary
Customer B prefers email via Gmail
Customer C stores summaries in Notion
With Fastn UCL:
The assistant sends a single MCP command
Fastn UCL detects which tenant sent it
It selects the correct action (Send Slack message, Send Email, Create Notion Page)
It runs that action with tenant-specific credentials
No duplicated logic. No risk of cross-tenant data leaks.
Here’s how Fastn UCL simplifies multitenancy:
Token management
You build and store it
Automatically managed per tenant
Context detection
Manual via headers or custom code
Built-in per command
Error handling
Per-tenant logic required
Built-in retries and isolation
Tenant observability
DIY dashboards or logs
Real-time per-tenant dashboards
Scaling
Add infra manually
Fully managed backend infrastructure
Building AI-powered SaaS tools shouldn’t mean reinventing your integration infrastructure for each customer. With Fastn UCL, your AI agents can route, authenticate, and execute commands per tenant—with no extra logic or complexity on your side.
You define your actions. Your users connect their apps. Fastn UCL takes care of the rest.
Next Step: Explore the multitenant-aware integration guide on Want help building a real use case? Let us know, and we’ll show you how to embed your first multitenant agent.