Skip to content
Back to skills

Multi Tenancy

ASecurity

Isolate tenant data in SaaS apps with enforced tenant scoping, per-tenant limits and safe migrations

  • 7 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 30, 2026
ai-agentsdatabasesecurity

Security analysis

A100/100

Scanned November 30, 2026

npx -y skills add ansh44233/forge --skill multi-tenancy --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Multi Tenancy?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Multi Tenancy
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/ansh44233-multi-tenancy/badge)](https://www.skillsdirectory.com/skills/ansh44233-multi-tenancy)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
description: Isolate tenant data in SaaS apps with enforced tenant scoping, per-tenant limits and safe migrations
profile: full
tags: saas, multi-tenancy, security, database
---

# Multi-tenancy

Cross-tenant data leaks are the worst SaaS bug. Make isolation structural, not remembered.

## Isolation model
- Choose: shared tables with `tenant_id`, schema-per-tenant, or database-per-tenant; document why.
- With shared tables, enforce scoping centrally (row-level security, ORM default scope, repository layer), not in each query by hand.

## Request handling
- Tenant comes from the authenticated session or verified subdomain, never from a request field alone.
- Every cache key, queue message, search query and file path includes the tenant.

## Operations
- Per-tenant rate limits and quotas; noisy-neighbor protection.
- Tenant deletion and export paths that reach every store.

## Verify
A test logs in as tenant A and tries to read, update and list tenant B's records by id and via search: all are denied or empty.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.