{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "chumbo-supabase-middleware",
  "type": "registry:file",
  "title": "Chumbo Middleware for @supabase/server MCP Functions",
  "description": "Drop-in @supabase/middleware pipeline entries (withMcpCors, withMcpTransportArmor, withChumbo, chumboMcpHandler) for official Supabase Edge Function MCP servers.",
  "dependencies": [
    "chumbo@0.16.1",
    "@supabase/middleware@1.0.0",
    "@supabase/server@1.9.2",
    "zod@4.6.7"
  ],
  "files": [
    {
      "path": "supabase/functions/mcp/index.ts",
      "type": "registry:file",
      "target": "supabase/functions/mcp/index.ts",
      "content": "import { pipeline } from \"npm:@supabase/middleware@1.0.0\";\nimport { withOAuthProtectedResource, withSupabase } from \"npm:@supabase/server@1.9.2\";\nimport { chumboMcpHandler, withChumbo, withMcpTransportArmor } from \"npm:chumbo@0.16.1/middleware\";\nimport { textResult } from \"npm:chumbo@0.16.1\";\n\nconst app = pipeline(\n  [\n    withMcpTransportArmor(),\n    withOAuthProtectedResource(),\n    withSupabase({ auth: \"user\" }),\n    withChumbo(),\n  ],\n  chumboMcpHandler({ name: \"my-supabase-app\", version: \"1.0.0\" }, (server, ctx) => {\n    server.registerTool(\"whoami\", { description: \"Return the signed-in Supabase user ID.\", annotations: { readOnlyHint: true } }, async () => {\n      return textResult(`Signed in as ${ctx.subject ?? \"anonymous\"}`);\n    });\n  }),\n);\n\nDeno.serve(app);\n"
    }
  ]
}
