Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add luanpdd/kit-mcp --skill b2b-saas-architecturegit clone --depth 1 https://github.com/luanpdd/kit-mcpWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/luanpdd/kit-mcp/b2b-saas-architecture)<a href="https://agentmods.dev/skills/luanpdd/kit-mcp/b2b-saas-architecture"><img src="https://agentmods.dev/badge/skills/luanpdd/kit-mcp/b2b-saas-architecture/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/luanpdd/kit-mcp/b2b-saas-architecture"><img src="https://agentmods.dev/badge/skills/luanpdd/kit-mcp/b2b-saas-architecture.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00061 | $0.03334 |
| Opus 5 | $0.00030 | $0.01667 |
| Sonnet 5 | $0.00012 | $0.00667 |
| Haiku 4.5 | $0.00006 | $0.00333 |
Grade A, and why
b2b-saas-architecture scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 302 lines — stays where its author put it; the contents beside it link to each section on GitHub.
B2B SaaS Multi-Tenant — Arquitetura Canônica
Quando usar
LLM carrega esta skill ao desenhar arquitetura de app B2B SaaS multi-tenant em Supabase. Trigger phrases:
- "B2B SaaS multi-tenant", "arquitetura multi-tenant", "isolation strategy"
- "single schema vs schema-per-tenant"
- "schema canônico organizations", "departments table", "members"
- "JWT claims multi-tenant", "app_metadata orgs"
- "slug org imutável", "tenant routing"
Esta skill define o schema canônico que multi-tenant-rls-writer (Phase 108), org-onboarding-implementer (Phase 107), super-admin-implementer (Phase 111), audit-log-implementer (Phase 109), e demais agents da suíte v1.21 consomem como entrada.
Regras absolutas
REGRA #1 (estratégia default): Single Schema + org_id + RLS é o caminho canônico para 90% dos B2B SaaS. Schema-per-tenant é justificado apenas em compliance extremo (saúde/jurídico com auditoria isolacional). Database-per-tenant é inviável economicamente fora de contratos enterprise.
REGRA #2 (JWT minimal): APENAS super_admin: bool em app_metadata. Lista de orgs no JWT é anti-pattern — bloat linear no token + stale de 1h após mudança de role. O banco (helper functions PG) é fonte de verdade.
REGRA #3 (slug imutável): organizations.slug é append-only após criação. Mutação requer tabela slug_history + redirect 301 em rotas afetadas. Quebra silenciosa de bookmarks/webhooks/OAuth callbacks é o pior bug que cliente B2B encontra.
REGRA #4 (super_admin via service_role): app_metadata.super_admin = true é setado APENAS via auth.admin.updateUserById() (service role). Cliente NUNCA consegue mutá-lo (≠ user_metadata que é editável).
REGRA #5 (FKs com CASCADE explícito): Todas as FKs têm ON DELETE explícito (CASCADE para entidades dependentes da org, RESTRICT para evitar deleção acidental). Sem default — força decisão consciente.
Patterns canônicos
Estratégia de isolation — tabela comparativa
| Estratégia | Isolation | Custo ops | Compliance | Quando usar |
|---|---|---|---|---|
Single Schema + org_id + RLS ⭐ |
Lógico (RLS) | Baixo | Padrão B2B SaaS | DEFAULT 90% dos casos — Stripe, Linear, Vercel, Notion |
| Schema-per-tenant | Físico (PG schemas) | Médio (N migrations) | Compliance auditável | Saúde/jurídico/governo com requisito explícito de isolamento |
| Database-per-tenant | Físico (DB separadas) | Alto (N projects Supabase) | Compliance extremo | Apenas contratos enterprise com SLA de isolamento físico |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 6d ago First seen · 302 lines · 61 tokens per session scan A f10c2bf7bbec
b2b-saas-architecture is a skill published in the GitHub repository luanpdd/kit-mcp (1 stars, last pushed 3d ago), licensed MIT. It adds 61 tokens to every session and 3,334 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
azure-postgres-ts
Connect to Azure Database for PostgreSQL Flexible Server from Node.js/TypeScript using the pg (node-postgres) package. Use for PostgreSQL queries, connection pooling, transactions, and Microsoft Entra ID (passwordless) authentication. Triggers: "PostgreSQL", "postgres", "pg client", "node-postgres", "Azure PostgreSQL…
butterbase
AI-native, open-source backend-as-a-service with a built-in Model Context Protocol server. Postgres, auth, storage, functions, AI gateway.
supabase
Use when doing ANY task involving Supabase. Triggers: Supabase products (Database, Auth, Edge Functions, Realtime, Storage, Vectors, Cron, Queues); client libraries and SSR integrations (supabase-js, @supabase/ssr) in Next.js, React, SvelteKit, Astro, Remix; auth issues (login, logout, sessions, JWT, cookies…
supabase-cli
This skill should be used when user asks to "use supabase CLI", "supabase init", "supabase start", "run migrations", "deploy edge functions", "manage Supabase project", or works with the supabase command-line tool for local development and project management.
supabase-js
This skill should be used when user asks to "use supabase-js", "query Supabase database", "supabase auth", "supabase storage", "supabase realtime", "supabase edge functions", or works with the @supabase/supabase-js JavaScript/TypeScript SDK.
supabase-node
Express/Hono with Supabase and Drizzle ORM.