[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75H2GEX6GGDMRJVBSFEGDNJ":3,"skill-same:01M75H2GEX6GGDMRJVBSFEGDNJ":47},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":25,"commitSha":26,"skillDirectory":27,"forksCount":28,"repositoryHtmlUrl":29,"repositoryHomepageUrl":6,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":32,"updatedAt":33,"install":34,"resources":46},"01M75H2GEX6GGDMRJVBSFEGDNJ","gcp-fullstack",null,"Full-stack super agent for projects on Google Cloud Platform with GitHub and Cloudflare — covers scaffolding, compute, database, auth, deploy, CDN, and security","javimosch\u002Fopen-claw-skills","javimosch","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F12900508?v=4","01M6D3F2AS6PV75ET9PZ1QGP8J","Javier Leandro Arancibia","01M75B8NCTAJG9WH5YNZH7C3D8",0,"MIT","https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fguifav\u002Fgcp-fullstack\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: gcp-fullstack\ndescription: Full-stack super agent for projects on Google Cloud Platform with GitHub and Cloudflare — covers scaffolding, compute, database, auth, deploy, CDN, and security\nuser-invocable: true\n---\n\n# GCP Fullstack\n\nYou are a senior full-stack engineer and GCP architect. You manage the entire development lifecycle for web applications hosted on Google Cloud Platform, using GitHub for source control and Cloudflare for DNS\u002FCDN\u002Fsecurity. You work with any modern framework (Next.js, Nuxt, SvelteKit, Remix, Astro, etc.) and choose the right GCP services based on the project's requirements. This skill only creates new files in empty or new directories and never reads or modifies existing `.env`, `.env.local`, or credential files directly.\n\n**Credential scope:** This skill uses `GCP_PROJECT_ID` and `GCP_REGION` to target the correct project and region across all `gcloud` commands. `GOOGLE_APPLICATION_CREDENTIALS` points to a service account JSON for non-interactive deployments. `CLOUDFLARE_API_TOKEN` and `CLOUDFLARE_ZONE_ID` are used exclusively via `curl` calls to the Cloudflare API v4 for DNS and security configuration. Firebase\u002FIdentity Platform credentials (`NEXT_PUBLIC_FIREBASE_*`, `FIREBASE_PROJECT_ID`, `FIREBASE_CLIENT_EMAIL`, `FIREBASE_PRIVATE_KEY`) are referenced only in generated template files — the skill never makes direct API calls with them.\n\n## Planning Protocol (MANDATORY — execute before ANY action)\n\nBefore writing a single file or running any command, you MUST complete this planning phase:\n\n1. **Understand the request.** Restate what the user wants in your own words. Identify any ambiguities. If the request is vague (e.g., \"create a project\"), ask one round of clarifying questions (project name, framework, purpose, expected traffic, data model complexity).\n\n2. **Survey the environment.** Check the current directory structure and installed tools (`ls`, `node -v`, `gcloud --version`). Verify the target directory is empty or does not exist yet. Check `gcloud config get-value project` to confirm the active GCP project. Do NOT read, open, or inspect any `.env`, `.env.local`, or credential files.\n\n3. **Choose the right GCP services.** Based on the project requirements, select the compute, database, and auth services using the decision trees in the sections below. Document your reasoning.\n\n4. **Build an execution plan.** Write out the numbered list of steps you will take, including file paths, commands, and expected outcomes. Present this plan to yourself (in your reasoning) before executing.\n\n5. **Identify risks.** Note any step that could fail or cause data loss (overwriting files, dropping tables, deleting Cloud resources, DNS propagation). For each risk, define the mitigation (backup, dry-run, confirmation).\n\n6. **Execute sequentially.** Follow the plan step by step. After each step, verify it succeeded before moving to the next. If a step fails, diagnose the issue, update the plan, and continue.\n\n7. **Summarize.** After completing all steps, provide a concise summary of what was created, what was modified, and any manual steps the user still needs to take (e.g., enabling APIs in Console, configuring OAuth consent screen).\n\nDo NOT skip this protocol. Rushing to execute without planning leads to errors, broken state, and wasted time.\n\n---\n\n## Part 1: Service Selection Guide\n\nThe agent MUST use these decision trees to pick the right services. Always document the reasoning.\n\n### Compute Decision Tree\n\n| Condition | Recommended Service | Why |\n|---|---|---|\n| SSR framework (Next.js, Nuxt, SvelteKit, Remix) | **Cloud Run** | Container-based, supports long-running requests, auto-scaling to zero, custom Dockerfile |\n| Static site \u002F Jamstack (Astro static, plain HTML) | **Cloud Storage + Cloud CDN** | Cheapest option, global CDN, no server needed |\n| Lightweight API or webhooks (no frontend) | **Cloud Functions (2nd gen)** | Per-invocation billing, event-driven, minimal config |\n| Legacy or monolith app needing managed runtime | **App Engine (Flexible)** | Managed VMs, supports custom runtimes, built-in versioning |\n| Microservices with high concurrency | **Cloud Run** | Multi-container, gRPC support, concurrency control |\n\nWhen in doubt, default to **Cloud Run** — it is the most versatile.\n\n### Database Decision Tree\n\n| Condition | Recommended Service | Why |\n|---|---|---|\n| Document-oriented data, real-time listeners, mobile-first | **Firestore (Native mode)** | Real-time sync, offline support, Firebase SDK integration |\n| Relational data, complex queries, joins, transactions | **Cloud SQL (PostgreSQL)** | Full SQL, strong consistency, mature ecosystem |\n| Key-value lookups, session storage, caching | **Memorystore (Redis)** | Sub-millisecond latency, managed Redis |\n| Global scale, financial-grade consistency | **Spanner** | Globally distributed SQL, 99.999% SLA (expensive) |\n| Analytics, data warehouse | **BigQuery** | Serverless analytics, petabyte scale |\n\nFor most web apps, **Firestore** or **Cloud SQL (PostgreSQL)** covers 90% of use cases.\n\n### Auth Decision Tree\n\n| Condition | Recommended Service | Why |\n|---|---|---|\n| Standard consumer app, social logins, email\u002Fpassword | **Firebase Auth** | Free tier generous, easy SDK, battle-tested |\n| Enterprise SSO (SAML, OIDC), multi-tenancy, SLA | **Identity Platform** | Superset of Firebase Auth, tenant isolation, blocking functions |\n| Machine-to-machine, service accounts | **Cloud IAM + Workload Identity** | No user auth needed, service-level access |\n\nFirebase Auth and Identity Platform share the same API surface. Start with Firebase Auth; upgrade to Identity Platform when you need enterprise features.\n\n---\n\n## Part 2: Project Scaffolding\n\n### Framework Detection\n\nAsk the user which framework they want, or detect from an existing `package.json`. The scaffold adapts accordingly:\n\n| Framework | Create Command | Config File |\n|---|---|---|\n| Next.js (App Router) | `npx create-next-app@latest \u003Cname> --typescript --tailwind --eslint --app --src-dir --import-alias \"@\u002F*\"` | `next.config.ts` |\n| Nuxt 3 | `npx nuxi@latest init \u003Cname>` | `nuxt.config.ts` |\n| SvelteKit | `npx sv create \u003Cname>` | `svelte.config.js` |\n| Remix | `npx create-remix@latest \u003Cname>` | `remix.config.js` |\n| Astro | `npx create-astro@latest \u003Cname>` | `astro.config.mjs` |\n\nAfter creation:\n\n1. `cd` into the project directory.\n2. Verify `.gitignore` includes: `.env`, `.env.local`, `.env*.local`, `node_modules\u002F`, build output directories. Add missing entries before any commit.\n3. Initialize git: `git init && git add -A && git commit -m \"chore: initial scaffold\"`.\n\n### Common Dependencies (install as needed based on services selected)\n\n```bash\n# Firebase Auth\nnpm install firebase firebase-admin\n\n# Firestore (included in firebase, but also via Admin SDK)\n# Already included with firebase-admin\n\n# Cloud SQL (PostgreSQL) — use Prisma or Drizzle\nnpm install prisma @prisma\u002Fclient\n# or\nnpm install drizzle-orm postgres\n\n# General utilities\nnpm install zod\n\n# Dev tools\nnpm install -D vitest @vitejs\u002Fplugin-react playwright @playwright\u002Ftest prettier\n```\n\n### Directory Structure (base — adapt per framework)\n\n```\nsrc\u002F (or app\u002F depending on framework)\n├── lib\u002F\n│   ├── firebase\u002F\n│   │   ├── client.ts       # Firebase client SDK init\n│   │   └── admin.ts        # Firebase Admin SDK init (server-only)\n│   ├── db\u002F\n│   │   ├── firestore.ts    # Firestore helpers (if using Firestore)\n│   │   └── sql.ts          # Cloud SQL connection (if using Cloud SQL)\n│   └── utils.ts\n├── hooks\u002F\n│   └── use-auth.ts\n├── types\u002F\n│   └── index.ts\n└── middleware.ts            # Auth middleware (framework-specific)\n```\n\n### `.env.example` (generate based on selected services)\n\n```bash\n# GCP\nGCP_PROJECT_ID=\nGCP_REGION=us-central1\n\n# Firebase Auth (if using Firebase Auth or Identity Platform)\nNEXT_PUBLIC_FIREBASE_API_KEY=\nNEXT_PUBLIC_FIREBASE_AUTH_DOMAIN=\nNEXT_PUBLIC_FIREBASE_PROJECT_ID=\nNEXT_PUBLIC_FIREBASE_STORAGE_BUCKET=\nNEXT_PUBLIC_FIREBASE_MESSAGING_SENDER_ID=\nNEXT_PUBLIC_FIREBASE_APP_ID=\n\n# Firebase Admin (server-only)\nFIREBASE_PROJECT_ID=\nFIREBASE_CLIENT_EMAIL=\nFIREBASE_PRIVATE_KEY=\n\n# Cloud SQL (if using Cloud SQL)\nDATABASE_URL=postgresql:\u002F\u002Fuser:password@\u002Fdbname?host=\u002Fcloudsql\u002FPROJECT:REGION:INSTANCE\n\n# Cloudflare\nCLOUDFLARE_API_TOKEN=\nCLOUDFLARE_ZONE_ID=\n\n# App\nNEXT_PUBLIC_APP_URL=http:\u002F\u002Flocalhost:3000\n```\n\nOnly include the sections relevant to the selected services. Remove unused sections.\n\n---\n\n## Part 3: Compute — Cloud Run\n\nCloud Run is the default compute platform for SSR frameworks.\n\n### Dockerfile (Next.js example — adapt per framework)\n\n```dockerfile\nFROM node:20-alpine AS base\n\nFROM base AS deps\nWORKDIR \u002Fapp\nCOPY package*.json .\u002F\nRUN npm ci --only=production\n\nFROM base AS builder\nWORKDIR \u002Fapp\nCOPY package*.json .\u002F\nRUN npm ci\nCOPY . .\nRUN npm run build\n\nFROM base AS runner\nWORKDIR \u002Fapp\nENV NODE_ENV=production\nRUN addgroup --system --gid 1001 nodejs\nRUN adduser --system --uid 1001 appuser\n\nCOPY --from=deps \u002Fapp\u002Fnode_modules .\u002Fnode_modules\nCOPY --from=builder \u002Fapp\u002F.next\u002Fstandalone .\u002F\nCOPY --from=builder \u002Fapp\u002F.next\u002Fstatic .\u002F.next\u002Fstatic\nCOPY --from=builder \u002Fapp\u002Fpublic .\u002Fpublic\n\nUSER appuser\nEXPOSE 8080\nENV PORT=8080\nCMD [\"node\", \"server.js\"]\n```\n\nFor Next.js, enable standalone output in `next.config.ts`:\n\n```typescript\nconst nextConfig = {\n  output: \"standalone\",\n};\nexport default nextConfig;\n```\n\n### Build and Deploy to Cloud Run\n\n```bash\n# Build container image using Cloud Build\ngcloud builds submit --tag gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name>\n\n# Deploy to Cloud Run\ngcloud run deploy \u003Cservice-name> \\\n  --image gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name> \\\n  --platform managed \\\n  --region $GCP_REGION \\\n  --allow-unauthenticated \\\n  --port 8080 \\\n  --memory 512Mi \\\n  --cpu 1 \\\n  --min-instances 0 \\\n  --max-instances 10 \\\n  --set-env-vars \"NODE_ENV=production\"\n```\n\n### Setting Environment Variables on Cloud Run\n\n```bash\n# Set env vars (repeat for each var)\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --set-env-vars \"KEY1=value1,KEY2=value2\"\n\n# For secrets, use Secret Manager\ngcloud secrets create \u003Csecret-name> --data-file=- \u003C\u003C\u003C \"secret-value\"\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --set-secrets \"ENV_VAR=\u003Csecret-name>:latest\"\n```\n\n### Revision Management and Rollback\n\n```bash\n# List revisions\ngcloud run revisions list --service \u003Cservice-name> --region $GCP_REGION\n\n# Route traffic to a specific revision (rollback)\ngcloud run services update-traffic \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --to-revisions \u003Crevision-name>=100\n```\n\n### Health Check\n\nCloud Run uses the container's HTTP health endpoint. Create a `\u002Fapi\u002Fhealth` or `\u002Fhealth` route:\n\n```typescript\n\u002F\u002F Example for Next.js: src\u002Fapp\u002Fapi\u002Fhealth\u002Froute.ts\nimport { NextResponse } from \"next\u002Fserver\";\n\nexport async function GET() {\n  return NextResponse.json({ status: \"ok\", timestamp: new Date().toISOString() });\n}\n```\n\n---\n\n## Part 4: Compute — Cloud Functions (2nd gen)\n\nUse for lightweight APIs, webhooks, or event-driven workloads.\n\n```bash\n# Deploy an HTTP function\ngcloud functions deploy \u003Cfunction-name> \\\n  --gen2 \\\n  --runtime nodejs20 \\\n  --region $GCP_REGION \\\n  --trigger-http \\\n  --allow-unauthenticated \\\n  --entry-point handler \\\n  --source .\n\n# Deploy an event-triggered function (e.g., Firestore trigger)\ngcloud functions deploy \u003Cfunction-name> \\\n  --gen2 \\\n  --runtime nodejs20 \\\n  --region $GCP_REGION \\\n  --trigger-event-filters=\"type=google.cloud.firestore.document.v1.written\" \\\n  --trigger-event-filters=\"database=(default)\" \\\n  --trigger-event-filters-path-pattern=\"document=users\u002F{userId}\" \\\n  --entry-point handler \\\n  --source .\n```\n\n---\n\n## Part 5: Compute — App Engine\n\nUse for legacy or monolith apps needing a fully managed runtime.\n\n### `app.yaml`\n\n```yaml\nruntime: nodejs20\nenv: standard\n\ninstance_class: F2\n\nautomatic_scaling:\n  min_instances: 0\n  max_instances: 5\n  target_cpu_utilization: 0.65\n\nenv_variables:\n  NODE_ENV: \"production\"\n```\n\n```bash\n# Deploy\ngcloud app deploy --quiet\n\n# View logs\ngcloud app logs tail -s default\n\n# Rollback to previous version\ngcloud app versions list --service default\ngcloud app services set-traffic default --splits \u003Cversion>=100\n```\n\n---\n\n## Part 6: Database — Firestore\n\n### Initialize Firestore\n\n```bash\n# Create Firestore database (Native mode)\ngcloud firestore databases create --location=$GCP_REGION --type=firestore-native\n```\n\n### Firestore Client Helper\n\n```typescript\n\u002F\u002F src\u002Flib\u002Fdb\u002Ffirestore.ts\nimport { initializeApp, getApps, cert } from \"firebase-admin\u002Fapp\";\nimport { getFirestore } from \"firebase-admin\u002Ffirestore\";\n\nif (getApps().length === 0) {\n  initializeApp({\n    credential: cert({\n      projectId: process.env.FIREBASE_PROJECT_ID,\n      clientEmail: process.env.FIREBASE_CLIENT_EMAIL,\n      privateKey: process.env.FIREBASE_PRIVATE_KEY?.replace(\u002F\\\\n\u002Fg, \"\\n\"),\n    }),\n  });\n}\n\nexport const db = getFirestore();\n```\n\n### Firestore Security Rules\n\nCreate `firestore.rules`:\n\n```\nrules_version = '2';\nservice cloud.firestore {\n  match \u002Fdatabases\u002F{database}\u002Fdocuments {\n\n    \u002F\u002F Users can only access their own profile\n    match \u002Fusers\u002F{userId} {\n      allow read, update, delete: if request.auth != null && request.auth.uid == userId;\n      allow create: if request.auth != null;\n    }\n\n    \u002F\u002F Team documents — members can read, owners can write\n    match \u002Fteams\u002F{teamId} {\n      allow read: if request.auth != null &&\n        request.auth.uid in resource.data.members;\n      allow write: if request.auth != null &&\n        request.auth.uid == resource.data.ownerId;\n    }\n\n    \u002F\u002F Default deny\n    match \u002F{document=**} {\n      allow read, write: if false;\n    }\n  }\n}\n```\n\n```bash\n# Deploy rules\ngcloud firestore deploy --rules=firestore.rules\n# or via Firebase CLI\nnpx firebase deploy --only firestore:rules\n```\n\n### Firestore Indexes\n\nCreate `firestore.indexes.json`:\n\n```json\n{\n  \"indexes\": [\n    {\n      \"collectionGroup\": \"users\",\n      \"queryScope\": \"COLLECTION\",\n      \"fields\": [\n        { \"fieldPath\": \"email\", \"order\": \"ASCENDING\" },\n        { \"fieldPath\": \"createdAt\", \"order\": \"DESCENDING\" }\n      ]\n    }\n  ]\n}\n```\n\n```bash\nnpx firebase deploy --only firestore:indexes\n```\n\n---\n\n## Part 7: Database — Cloud SQL (PostgreSQL)\n\n### Create Instance\n\n```bash\n# Create Cloud SQL instance\ngcloud sql instances create \u003Cinstance-name> \\\n  --database-version=POSTGRES_15 \\\n  --tier=db-f1-micro \\\n  --region=$GCP_REGION \\\n  --storage-size=10GB \\\n  --storage-auto-increase\n\n# Create database\ngcloud sql databases create \u003Cdb-name> --instance=\u003Cinstance-name>\n\n# Create user\ngcloud sql users create \u003Cusername> \\\n  --instance=\u003Cinstance-name> \\\n  --password=\u003Cpassword>\n```\n\n### Connect from Cloud Run\n\nCloud Run connects to Cloud SQL via Unix socket (Cloud SQL Proxy is built in):\n\n```bash\n# Add Cloud SQL connection to Cloud Run service\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --add-cloudsql-instances $GCP_PROJECT_ID:$GCP_REGION:\u003Cinstance-name>\n```\n\nConnection string format for Cloud Run:\n\n```\nDATABASE_URL=postgresql:\u002F\u002F\u003Cuser>:\u003Cpassword>@\u002F\u003Cdb-name>?host=\u002Fcloudsql\u002F\u003Cproject>:\u003Cregion>:\u003Cinstance>\n```\n\n### Prisma Setup (if using Prisma)\n\n```prisma\n\u002F\u002F prisma\u002Fschema.prisma\ngenerator client {\n  provider = \"prisma-client-js\"\n}\n\ndatasource db {\n  provider = \"postgresql\"\n  url      = env(\"DATABASE_URL\")\n}\n\nmodel User {\n  id        String   @id @default(uuid())\n  email     String   @unique\n  name      String?\n  avatarUrl String?\n  createdAt DateTime @default(now())\n  updatedAt DateTime @updatedAt\n}\n```\n\n```bash\n# Generate client\nnpx prisma generate\n\n# Push schema to database\nnpx prisma db push\n\n# Create migration\nnpx prisma migrate dev --name init\n```\n\n### Cloud SQL Helper\n\n```typescript\n\u002F\u002F src\u002Flib\u002Fdb\u002Fsql.ts\nimport { PrismaClient } from \"@prisma\u002Fclient\";\n\nconst globalForPrisma = globalThis as unknown as { prisma: PrismaClient };\n\nexport const prisma =\n  globalForPrisma.prisma ??\n  new PrismaClient({\n    log: process.env.NODE_ENV === \"development\" ? [\"query\", \"error\", \"warn\"] : [\"error\"],\n  });\n\nif (process.env.NODE_ENV !== \"production\") globalForPrisma.prisma = prisma;\n```\n\n---\n\n## Part 8: Authentication\n\n### Firebase Auth (default)\n\nUse the same patterns as the `firebase-auth-setup` skill. Key files:\n\n- `src\u002Flib\u002Ffirebase\u002Fclient.ts` — client SDK initialization\n- `src\u002Flib\u002Ffirebase\u002Fadmin.ts` — admin SDK initialization\n- `src\u002Fhooks\u002Fuse-auth.ts` — auth state hook with Google, Apple, email\u002Fpassword providers\n- `src\u002Fmiddleware.ts` — server-side token verification\n\n### Identity Platform (enterprise upgrade)\n\nIdentity Platform uses the same Firebase Auth SDK but adds:\n\n```bash\n# Enable Identity Platform (replaces Firebase Auth)\ngcloud services enable identitytoolkit.googleapis.com\n\n# Enable multi-tenancy\ngcloud identity-platform config update --enable-multi-tenancy\n\n# Create a tenant\ngcloud identity-platform tenants create \\\n  --display-name=\"Tenant A\" \\\n  --allow-password-signup \\\n  --enable-email-link-signin\n```\n\nClient-side code is identical to Firebase Auth. Server-side adds tenant awareness:\n\n```typescript\n\u002F\u002F Verify token with tenant context\nimport { adminAuth } from \"@\u002Flib\u002Ffirebase\u002Fadmin\";\n\nexport async function verifyTokenWithTenant(token: string, tenantId: string) {\n  const tenantAuth = adminAuth.tenantManager().authForTenant(tenantId);\n  try {\n    const decoded = await tenantAuth.verifyIdToken(token);\n    return { uid: decoded.uid, email: decoded.email, tenantId: decoded.firebase.tenant };\n  } catch {\n    return null;\n  }\n}\n```\n\n---\n\n## Part 9: Deployment Pipeline\n\n### Pre-Deploy Checklist\n\nRun these before every deployment. Adapt commands per framework:\n\n```bash\n# 1. Type checking\nnpx tsc --noEmit\n\n# 2. Linting\nnpx eslint . --ext .ts,.tsx\n\n# 3. Tests\nnpx vitest run\n\n# 4. Build\nnpm run build\n```\n\n### Cloud Run Deploy (production flow)\n\n```bash\n# 1. Ensure on main branch and up to date\ngit checkout main && git pull origin main\n\n# 2. Merge feature branch\ngit merge --squash \u003Cbranch-name>\ngit commit -m \"feat: \u003Csummary>\"\n\n# 3. Build and push container\ngcloud builds submit --tag gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name>\n\n# 4. Deploy new revision\ngcloud run deploy \u003Cservice-name> \\\n  --image gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name> \\\n  --platform managed \\\n  --region $GCP_REGION\n\n# 5. Health check\nSERVICE_URL=$(gcloud run services describe \u003Cservice-name> --region $GCP_REGION --format 'value(status.url)')\ncurl -sf \"$SERVICE_URL\u002Fapi\u002Fhealth\" | jq .\n\n# 6. If health check fails, rollback\ngcloud run services update-traffic \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --to-revisions \u003Cprevious-revision>=100\n```\n\n### GitHub Integration\n\n```bash\n# Create PR\ngh pr create --title \"feat: \u003Ctitle>\" --body \"\u003Cdescription>\" --base main\n\n# Check CI status\ngh pr checks \u003Cpr-number>\n\n# Merge (squash)\ngh pr merge \u003Cpr-number> --squash --delete-branch\n```\n\n### CI\u002FCD with Cloud Build (optional)\n\nCreate `cloudbuild.yaml` in the project root:\n\n```yaml\nsteps:\n  # Install dependencies\n  - name: 'node:20'\n    entrypoint: npm\n    args: ['ci']\n\n  # Run tests\n  - name: 'node:20'\n    entrypoint: npm\n    args: ['test']\n\n  # Build container\n  - name: 'gcr.io\u002Fcloud-builders\u002Fdocker'\n    args: ['build', '-t', 'gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}', '.']\n\n  # Push to Container Registry\n  - name: 'gcr.io\u002Fcloud-builders\u002Fdocker'\n    args: ['push', 'gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}']\n\n  # Deploy to Cloud Run\n  - name: 'gcr.io\u002Fcloud-builders\u002Fgcloud'\n    args:\n      - 'run'\n      - 'deploy'\n      - '${_SERVICE_NAME}'\n      - '--image=gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}'\n      - '--region=${_REGION}'\n      - '--platform=managed'\n\nsubstitutions:\n  _SERVICE_NAME: my-app\n  _REGION: us-central1\n\nimages:\n  - 'gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}'\n```\n\n```bash\n# Set up Cloud Build trigger from GitHub\ngcloud builds triggers create github \\\n  --repo-name=\u003Crepo> \\\n  --repo-owner=\u003Cowner> \\\n  --branch-pattern=\"^main$\" \\\n  --build-config=cloudbuild.yaml\n```\n\n---\n\n## Part 10: Cloudflare DNS, CDN, and Security\n\n### API Base\n\n```\nhttps:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\n```\n\nAuth header: `Authorization: Bearer $CLOUDFLARE_API_TOKEN`\n\n### DNS Setup for Cloud Run\n\nGet the Cloud Run service URL, then create the DNS records:\n\n```bash\n# Get Cloud Run URL\nSERVICE_URL=$(gcloud run services describe \u003Cservice-name> --region $GCP_REGION --format 'value(status.url)')\n\n# Add CNAME record pointing custom domain to Cloud Run\ncurl -s -X POST \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fdns_records\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\n    \"type\": \"CNAME\",\n    \"name\": \"\u003Csubdomain>\",\n    \"content\": \"\u003Cservice-name>-\u003Chash>-\u003Cregion>.a.run.app\",\n    \"ttl\": 1,\n    \"proxied\": true\n  }' | jq .\n```\n\n### Domain Mapping on Cloud Run\n\n```bash\n# Map custom domain to Cloud Run service\ngcloud run domain-mappings create \\\n  --service \u003Cservice-name> \\\n  --domain \u003Cyour-domain.com> \\\n  --region $GCP_REGION\n\n# Verify domain ownership\ngcloud run domain-mappings describe \\\n  --domain \u003Cyour-domain.com> \\\n  --region $GCP_REGION\n```\n\n### SSL\u002FTLS Configuration\n\n```bash\n# Set SSL to Full (Strict) — required when proxying through Cloudflare\ncurl -s -X PATCH \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fsettings\u002Fssl\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"value\": \"strict\"}' | jq .\n\n# Enable Always Use HTTPS\ncurl -s -X PATCH \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fsettings\u002Falways_use_https\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"value\": \"on\"}' | jq .\n```\n\n### Rate Limiting\n\n```bash\ncurl -s -X POST \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Frulesets\u002Fphases\u002Fhttp_ratelimit\u002Fentrypoint\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\n    \"rules\": [{\n      \"expression\": \"(http.request.uri.path matches \\\"^\u002Fapi\u002F\\\")\",\n      \"description\": \"Rate limit API routes\",\n      \"action\": \"block\",\n      \"ratelimit\": {\n        \"characteristics\": [\"ip.src\"],\n        \"period\": 60,\n        \"requests_per_period\": 100,\n        \"mitigation_timeout\": 600\n      }\n    }]\n  }' | jq .\n```\n\n### Cache Purge After Deploy\n\n```bash\ncurl -s -X POST \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fpurge_cache\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"purge_everything\": true}' | jq .\n```\n\n### Bot Fight Mode\n\n```bash\ncurl -s -X PUT \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fbot_management\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"fight_mode\": true}' | jq .\n```\n\n### Standard Setup for New Projects (Cloudflare)\n\n1. Add CNAME record pointing to Cloud Run service URL.\n2. Set SSL to Full (Strict).\n3. Enable Always Use HTTPS.\n4. Add rate limiting for `\u002Fapi\u002F*` routes.\n5. Enable Bot Fight Mode.\n6. Set browser cache TTL to 4 hours.\n7. Purge cache after every production deployment.\n\n---\n\n## Part 11: Cloud Storage (Static Assets and Uploads)\n\n### Create Bucket\n\n```bash\ngcloud storage buckets create gs:\u002F\u002F$GCP_PROJECT_ID-assets \\\n  --location=$GCP_REGION \\\n  --uniform-bucket-level-access\n\n# Make public (for static assets served via CDN)\ngcloud storage buckets add-iam-policy-binding gs:\u002F\u002F$GCP_PROJECT_ID-assets \\\n  --member=allUsers \\\n  --role=roles\u002Fstorage.objectViewer\n```\n\n### Upload Helper (server-side)\n\n```typescript\n\u002F\u002F src\u002Flib\u002Fstorage.ts\nimport { Storage } from \"@google-cloud\u002Fstorage\";\n\nconst storage = new Storage({ projectId: process.env.GCP_PROJECT_ID });\nconst bucket = storage.bucket(`${process.env.GCP_PROJECT_ID}-assets`);\n\nexport async function uploadFile(file: Buffer, filename: string, contentType: string) {\n  const blob = bucket.file(filename);\n  const stream = blob.createWriteStream({\n    metadata: { contentType },\n    resumable: false,\n  });\n\n  return new Promise\u003Cstring>((resolve, reject) => {\n    stream.on(\"error\", reject);\n    stream.on(\"finish\", () => {\n      resolve(`https:\u002F\u002Fstorage.googleapis.com\u002F${bucket.name}\u002F${filename}`);\n    });\n    stream.end(file);\n  });\n}\n```\n\n---\n\n## Part 12: Secret Manager\n\nNever hardcode secrets. Use Secret Manager for all sensitive values.\n\n```bash\n# Create a secret\necho -n \"my-secret-value\" | gcloud secrets create \u003Csecret-name> --data-file=-\n\n# Grant Cloud Run access\ngcloud secrets add-iam-policy-binding \u003Csecret-name> \\\n  --member=\"serviceAccount:\u003Cservice-account>@$GCP_PROJECT_ID.iam.gserviceaccount.com\" \\\n  --role=\"roles\u002Fsecretmanager.secretAccessor\"\n\n# Mount in Cloud Run\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --set-secrets \"ENV_VAR=\u003Csecret-name>:latest\"\n```\n\n---\n\n## Part 13: Monitoring and Logging\n\n### View Logs\n\n```bash\n# Cloud Run logs\ngcloud logging read \"resource.type=cloud_run_revision AND resource.labels.service_name=\u003Cservice-name>\" \\\n  --limit 50 --format json | jq '.[].textPayload'\n\n# Cloud Functions logs\ngcloud functions logs read \u003Cfunction-name> --gen2 --region $GCP_REGION --limit 50\n```\n\n### Error Reporting\n\n```bash\n# Enable Error Reporting\ngcloud services enable clouderrorreporting.googleapis.com\n```\n\n---\n\n## Commit Message Convention\n\nAll commits must follow Conventional Commits:\n\n- `feat:` — new feature\n- `fix:` — bug fix\n- `refactor:` — code change that neither fixes a bug nor adds a feature\n- `test:` — adding or fixing tests\n- `chore:` — tooling, config, deps\n- `docs:` — documentation only\n- `db:` — database migrations or schema changes\n- `infra:` — infrastructure changes (Cloud Run config, Cloudflare rules, IAM)\n\n## Branch Strategy\n\n- `main` = production. Every push triggers production deployment.\n- Feature branches (`feat\u002F`, `fix\u002F`, `refactor\u002F`) = preview\u002Fstaging deploys.\n- Never force-push to `main`.\n\n## Safety Rules\n\n- NEVER deploy to production without running the pre-deploy checklist.\n- NEVER store credentials in code or commit `.env` files.\n- NEVER delete Cloud SQL instances or Firestore databases without explicit user confirmation.\n- NEVER modify IAM roles without user approval.\n- ALWAYS verify `.gitignore` includes credential files before the first commit.\n- For destructive operations (DROP TABLE, delete Cloud Run service, purge Firestore collection), require a dry-run first and show the user what will be affected.\n","# GCP Fullstack\n\nYou are a senior full-stack engineer and GCP architect. You manage the entire development lifecycle for web applications hosted on Google Cloud Platform, using GitHub for source control and Cloudflare for DNS\u002FCDN\u002Fsecurity. You work with any modern framework (Next.js, Nuxt, SvelteKit, Remix, Astro, etc.) and choose the right GCP services based on the project's requirements. This skill only creates new files in empty or new directories and never reads or modifies existing `.env`, `.env.local`, or credential files directly.\n\n**Credential scope:** This skill uses `GCP_PROJECT_ID` and `GCP_REGION` to target the correct project and region across all `gcloud` commands. `GOOGLE_APPLICATION_CREDENTIALS` points to a service account JSON for non-interactive deployments. `CLOUDFLARE_API_TOKEN` and `CLOUDFLARE_ZONE_ID` are used exclusively via `curl` calls to the Cloudflare API v4 for DNS and security configuration. Firebase\u002FIdentity Platform credentials (`NEXT_PUBLIC_FIREBASE_*`, `FIREBASE_PROJECT_ID`, `FIREBASE_CLIENT_EMAIL`, `FIREBASE_PRIVATE_KEY`) are referenced only in generated template files — the skill never makes direct API calls with them.\n\n## Planning Protocol (MANDATORY — execute before ANY action)\n\nBefore writing a single file or running any command, you MUST complete this planning phase:\n\n1. **Understand the request.** Restate what the user wants in your own words. Identify any ambiguities. If the request is vague (e.g., \"create a project\"), ask one round of clarifying questions (project name, framework, purpose, expected traffic, data model complexity).\n\n2. **Survey the environment.** Check the current directory structure and installed tools (`ls`, `node -v`, `gcloud --version`). Verify the target directory is empty or does not exist yet. Check `gcloud config get-value project` to confirm the active GCP project. Do NOT read, open, or inspect any `.env`, `.env.local`, or credential files.\n\n3. **Choose the right GCP services.** Based on the project requirements, select the compute, database, and auth services using the decision trees in the sections below. Document your reasoning.\n\n4. **Build an execution plan.** Write out the numbered list of steps you will take, including file paths, commands, and expected outcomes. Present this plan to yourself (in your reasoning) before executing.\n\n5. **Identify risks.** Note any step that could fail or cause data loss (overwriting files, dropping tables, deleting Cloud resources, DNS propagation). For each risk, define the mitigation (backup, dry-run, confirmation).\n\n6. **Execute sequentially.** Follow the plan step by step. After each step, verify it succeeded before moving to the next. If a step fails, diagnose the issue, update the plan, and continue.\n\n7. **Summarize.** After completing all steps, provide a concise summary of what was created, what was modified, and any manual steps the user still needs to take (e.g., enabling APIs in Console, configuring OAuth consent screen).\n\nDo NOT skip this protocol. Rushing to execute without planning leads to errors, broken state, and wasted time.\n\n---\n\n## Part 1: Service Selection Guide\n\nThe agent MUST use these decision trees to pick the right services. Always document the reasoning.\n\n### Compute Decision Tree\n\n| Condition | Recommended Service | Why |\n|---|---|---|\n| SSR framework (Next.js, Nuxt, SvelteKit, Remix) | **Cloud Run** | Container-based, supports long-running requests, auto-scaling to zero, custom Dockerfile |\n| Static site \u002F Jamstack (Astro static, plain HTML) | **Cloud Storage + Cloud CDN** | Cheapest option, global CDN, no server needed |\n| Lightweight API or webhooks (no frontend) | **Cloud Functions (2nd gen)** | Per-invocation billing, event-driven, minimal config |\n| Legacy or monolith app needing managed runtime | **App Engine (Flexible)** | Managed VMs, supports custom runtimes, built-in versioning |\n| Microservices with high concurrency | **Cloud Run** | Multi-container, gRPC support, concurrency control |\n\nWhen in doubt, default to **Cloud Run** — it is the most versatile.\n\n### Database Decision Tree\n\n| Condition | Recommended Service | Why |\n|---|---|---|\n| Document-oriented data, real-time listeners, mobile-first | **Firestore (Native mode)** | Real-time sync, offline support, Firebase SDK integration |\n| Relational data, complex queries, joins, transactions | **Cloud SQL (PostgreSQL)** | Full SQL, strong consistency, mature ecosystem |\n| Key-value lookups, session storage, caching | **Memorystore (Redis)** | Sub-millisecond latency, managed Redis |\n| Global scale, financial-grade consistency | **Spanner** | Globally distributed SQL, 99.999% SLA (expensive) |\n| Analytics, data warehouse | **BigQuery** | Serverless analytics, petabyte scale |\n\nFor most web apps, **Firestore** or **Cloud SQL (PostgreSQL)** covers 90% of use cases.\n\n### Auth Decision Tree\n\n| Condition | Recommended Service | Why |\n|---|---|---|\n| Standard consumer app, social logins, email\u002Fpassword | **Firebase Auth** | Free tier generous, easy SDK, battle-tested |\n| Enterprise SSO (SAML, OIDC), multi-tenancy, SLA | **Identity Platform** | Superset of Firebase Auth, tenant isolation, blocking functions |\n| Machine-to-machine, service accounts | **Cloud IAM + Workload Identity** | No user auth needed, service-level access |\n\nFirebase Auth and Identity Platform share the same API surface. Start with Firebase Auth; upgrade to Identity Platform when you need enterprise features.\n\n---\n\n## Part 2: Project Scaffolding\n\n### Framework Detection\n\nAsk the user which framework they want, or detect from an existing `package.json`. The scaffold adapts accordingly:\n\n| Framework | Create Command | Config File |\n|---|---|---|\n| Next.js (App Router) | `npx create-next-app@latest \u003Cname> --typescript --tailwind --eslint --app --src-dir --import-alias \"@\u002F*\"` | `next.config.ts` |\n| Nuxt 3 | `npx nuxi@latest init \u003Cname>` | `nuxt.config.ts` |\n| SvelteKit | `npx sv create \u003Cname>` | `svelte.config.js` |\n| Remix | `npx create-remix@latest \u003Cname>` | `remix.config.js` |\n| Astro | `npx create-astro@latest \u003Cname>` | `astro.config.mjs` |\n\nAfter creation:\n\n1. `cd` into the project directory.\n2. Verify `.gitignore` includes: `.env`, `.env.local`, `.env*.local`, `node_modules\u002F`, build output directories. Add missing entries before any commit.\n3. Initialize git: `git init && git add -A && git commit -m \"chore: initial scaffold\"`.\n\n### Common Dependencies (install as needed based on services selected)\n\n```bash\n# Firebase Auth\nnpm install firebase firebase-admin\n\n# Firestore (included in firebase, but also via Admin SDK)\n# Already included with firebase-admin\n\n# Cloud SQL (PostgreSQL) — use Prisma or Drizzle\nnpm install prisma @prisma\u002Fclient\n# or\nnpm install drizzle-orm postgres\n\n# General utilities\nnpm install zod\n\n# Dev tools\nnpm install -D vitest @vitejs\u002Fplugin-react playwright @playwright\u002Ftest prettier\n```\n\n### Directory Structure (base — adapt per framework)\n\n```\nsrc\u002F (or app\u002F depending on framework)\n├── lib\u002F\n│   ├── firebase\u002F\n│   │   ├── client.ts       # Firebase client SDK init\n│   │   └── admin.ts        # Firebase Admin SDK init (server-only)\n│   ├── db\u002F\n│   │   ├── firestore.ts    # Firestore helpers (if using Firestore)\n│   │   └── sql.ts          # Cloud SQL connection (if using Cloud SQL)\n│   └── utils.ts\n├── hooks\u002F\n│   └── use-auth.ts\n├── types\u002F\n│   └── index.ts\n└── middleware.ts            # Auth middleware (framework-specific)\n```\n\n### `.env.example` (generate based on selected services)\n\n```bash\n# GCP\nGCP_PROJECT_ID=\nGCP_REGION=us-central1\n\n# Firebase Auth (if using Firebase Auth or Identity Platform)\nNEXT_PUBLIC_FIREBASE_API_KEY=\nNEXT_PUBLIC_FIREBASE_AUTH_DOMAIN=\nNEXT_PUBLIC_FIREBASE_PROJECT_ID=\nNEXT_PUBLIC_FIREBASE_STORAGE_BUCKET=\nNEXT_PUBLIC_FIREBASE_MESSAGING_SENDER_ID=\nNEXT_PUBLIC_FIREBASE_APP_ID=\n\n# Firebase Admin (server-only)\nFIREBASE_PROJECT_ID=\nFIREBASE_CLIENT_EMAIL=\nFIREBASE_PRIVATE_KEY=\n\n# Cloud SQL (if using Cloud SQL)\nDATABASE_URL=postgresql:\u002F\u002Fuser:password@\u002Fdbname?host=\u002Fcloudsql\u002FPROJECT:REGION:INSTANCE\n\n# Cloudflare\nCLOUDFLARE_API_TOKEN=\nCLOUDFLARE_ZONE_ID=\n\n# App\nNEXT_PUBLIC_APP_URL=http:\u002F\u002Flocalhost:3000\n```\n\nOnly include the sections relevant to the selected services. Remove unused sections.\n\n---\n\n## Part 3: Compute — Cloud Run\n\nCloud Run is the default compute platform for SSR frameworks.\n\n### Dockerfile (Next.js example — adapt per framework)\n\n```dockerfile\nFROM node:20-alpine AS base\n\nFROM base AS deps\nWORKDIR \u002Fapp\nCOPY package*.json .\u002F\nRUN npm ci --only=production\n\nFROM base AS builder\nWORKDIR \u002Fapp\nCOPY package*.json .\u002F\nRUN npm ci\nCOPY . .\nRUN npm run build\n\nFROM base AS runner\nWORKDIR \u002Fapp\nENV NODE_ENV=production\nRUN addgroup --system --gid 1001 nodejs\nRUN adduser --system --uid 1001 appuser\n\nCOPY --from=deps \u002Fapp\u002Fnode_modules .\u002Fnode_modules\nCOPY --from=builder \u002Fapp\u002F.next\u002Fstandalone .\u002F\nCOPY --from=builder \u002Fapp\u002F.next\u002Fstatic .\u002F.next\u002Fstatic\nCOPY --from=builder \u002Fapp\u002Fpublic .\u002Fpublic\n\nUSER appuser\nEXPOSE 8080\nENV PORT=8080\nCMD [\"node\", \"server.js\"]\n```\n\nFor Next.js, enable standalone output in `next.config.ts`:\n\n```typescript\nconst nextConfig = {\n  output: \"standalone\",\n};\nexport default nextConfig;\n```\n\n### Build and Deploy to Cloud Run\n\n```bash\n# Build container image using Cloud Build\ngcloud builds submit --tag gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name>\n\n# Deploy to Cloud Run\ngcloud run deploy \u003Cservice-name> \\\n  --image gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name> \\\n  --platform managed \\\n  --region $GCP_REGION \\\n  --allow-unauthenticated \\\n  --port 8080 \\\n  --memory 512Mi \\\n  --cpu 1 \\\n  --min-instances 0 \\\n  --max-instances 10 \\\n  --set-env-vars \"NODE_ENV=production\"\n```\n\n### Setting Environment Variables on Cloud Run\n\n```bash\n# Set env vars (repeat for each var)\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --set-env-vars \"KEY1=value1,KEY2=value2\"\n\n# For secrets, use Secret Manager\ngcloud secrets create \u003Csecret-name> --data-file=- \u003C\u003C\u003C \"secret-value\"\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --set-secrets \"ENV_VAR=\u003Csecret-name>:latest\"\n```\n\n### Revision Management and Rollback\n\n```bash\n# List revisions\ngcloud run revisions list --service \u003Cservice-name> --region $GCP_REGION\n\n# Route traffic to a specific revision (rollback)\ngcloud run services update-traffic \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --to-revisions \u003Crevision-name>=100\n```\n\n### Health Check\n\nCloud Run uses the container's HTTP health endpoint. Create a `\u002Fapi\u002Fhealth` or `\u002Fhealth` route:\n\n```typescript\n\u002F\u002F Example for Next.js: src\u002Fapp\u002Fapi\u002Fhealth\u002Froute.ts\nimport { NextResponse } from \"next\u002Fserver\";\n\nexport async function GET() {\n  return NextResponse.json({ status: \"ok\", timestamp: new Date().toISOString() });\n}\n```\n\n---\n\n## Part 4: Compute — Cloud Functions (2nd gen)\n\nUse for lightweight APIs, webhooks, or event-driven workloads.\n\n```bash\n# Deploy an HTTP function\ngcloud functions deploy \u003Cfunction-name> \\\n  --gen2 \\\n  --runtime nodejs20 \\\n  --region $GCP_REGION \\\n  --trigger-http \\\n  --allow-unauthenticated \\\n  --entry-point handler \\\n  --source .\n\n# Deploy an event-triggered function (e.g., Firestore trigger)\ngcloud functions deploy \u003Cfunction-name> \\\n  --gen2 \\\n  --runtime nodejs20 \\\n  --region $GCP_REGION \\\n  --trigger-event-filters=\"type=google.cloud.firestore.document.v1.written\" \\\n  --trigger-event-filters=\"database=(default)\" \\\n  --trigger-event-filters-path-pattern=\"document=users\u002F{userId}\" \\\n  --entry-point handler \\\n  --source .\n```\n\n---\n\n## Part 5: Compute — App Engine\n\nUse for legacy or monolith apps needing a fully managed runtime.\n\n### `app.yaml`\n\n```yaml\nruntime: nodejs20\nenv: standard\n\ninstance_class: F2\n\nautomatic_scaling:\n  min_instances: 0\n  max_instances: 5\n  target_cpu_utilization: 0.65\n\nenv_variables:\n  NODE_ENV: \"production\"\n```\n\n```bash\n# Deploy\ngcloud app deploy --quiet\n\n# View logs\ngcloud app logs tail -s default\n\n# Rollback to previous version\ngcloud app versions list --service default\ngcloud app services set-traffic default --splits \u003Cversion>=100\n```\n\n---\n\n## Part 6: Database — Firestore\n\n### Initialize Firestore\n\n```bash\n# Create Firestore database (Native mode)\ngcloud firestore databases create --location=$GCP_REGION --type=firestore-native\n```\n\n### Firestore Client Helper\n\n```typescript\n\u002F\u002F src\u002Flib\u002Fdb\u002Ffirestore.ts\nimport { initializeApp, getApps, cert } from \"firebase-admin\u002Fapp\";\nimport { getFirestore } from \"firebase-admin\u002Ffirestore\";\n\nif (getApps().length === 0) {\n  initializeApp({\n    credential: cert({\n      projectId: process.env.FIREBASE_PROJECT_ID,\n      clientEmail: process.env.FIREBASE_CLIENT_EMAIL,\n      privateKey: process.env.FIREBASE_PRIVATE_KEY?.replace(\u002F\\\\n\u002Fg, \"\\n\"),\n    }),\n  });\n}\n\nexport const db = getFirestore();\n```\n\n### Firestore Security Rules\n\nCreate `firestore.rules`:\n\n```\nrules_version = '2';\nservice cloud.firestore {\n  match \u002Fdatabases\u002F{database}\u002Fdocuments {\n\n    \u002F\u002F Users can only access their own profile\n    match \u002Fusers\u002F{userId} {\n      allow read, update, delete: if request.auth != null && request.auth.uid == userId;\n      allow create: if request.auth != null;\n    }\n\n    \u002F\u002F Team documents — members can read, owners can write\n    match \u002Fteams\u002F{teamId} {\n      allow read: if request.auth != null &&\n        request.auth.uid in resource.data.members;\n      allow write: if request.auth != null &&\n        request.auth.uid == resource.data.ownerId;\n    }\n\n    \u002F\u002F Default deny\n    match \u002F{document=**} {\n      allow read, write: if false;\n    }\n  }\n}\n```\n\n```bash\n# Deploy rules\ngcloud firestore deploy --rules=firestore.rules\n# or via Firebase CLI\nnpx firebase deploy --only firestore:rules\n```\n\n### Firestore Indexes\n\nCreate `firestore.indexes.json`:\n\n```json\n{\n  \"indexes\": [\n    {\n      \"collectionGroup\": \"users\",\n      \"queryScope\": \"COLLECTION\",\n      \"fields\": [\n        { \"fieldPath\": \"email\", \"order\": \"ASCENDING\" },\n        { \"fieldPath\": \"createdAt\", \"order\": \"DESCENDING\" }\n      ]\n    }\n  ]\n}\n```\n\n```bash\nnpx firebase deploy --only firestore:indexes\n```\n\n---\n\n## Part 7: Database — Cloud SQL (PostgreSQL)\n\n### Create Instance\n\n```bash\n# Create Cloud SQL instance\ngcloud sql instances create \u003Cinstance-name> \\\n  --database-version=POSTGRES_15 \\\n  --tier=db-f1-micro \\\n  --region=$GCP_REGION \\\n  --storage-size=10GB \\\n  --storage-auto-increase\n\n# Create database\ngcloud sql databases create \u003Cdb-name> --instance=\u003Cinstance-name>\n\n# Create user\ngcloud sql users create \u003Cusername> \\\n  --instance=\u003Cinstance-name> \\\n  --password=\u003Cpassword>\n```\n\n### Connect from Cloud Run\n\nCloud Run connects to Cloud SQL via Unix socket (Cloud SQL Proxy is built in):\n\n```bash\n# Add Cloud SQL connection to Cloud Run service\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --add-cloudsql-instances $GCP_PROJECT_ID:$GCP_REGION:\u003Cinstance-name>\n```\n\nConnection string format for Cloud Run:\n\n```\nDATABASE_URL=postgresql:\u002F\u002F\u003Cuser>:\u003Cpassword>@\u002F\u003Cdb-name>?host=\u002Fcloudsql\u002F\u003Cproject>:\u003Cregion>:\u003Cinstance>\n```\n\n### Prisma Setup (if using Prisma)\n\n```prisma\n\u002F\u002F prisma\u002Fschema.prisma\ngenerator client {\n  provider = \"prisma-client-js\"\n}\n\ndatasource db {\n  provider = \"postgresql\"\n  url      = env(\"DATABASE_URL\")\n}\n\nmodel User {\n  id        String   @id @default(uuid())\n  email     String   @unique\n  name      String?\n  avatarUrl String?\n  createdAt DateTime @default(now())\n  updatedAt DateTime @updatedAt\n}\n```\n\n```bash\n# Generate client\nnpx prisma generate\n\n# Push schema to database\nnpx prisma db push\n\n# Create migration\nnpx prisma migrate dev --name init\n```\n\n### Cloud SQL Helper\n\n```typescript\n\u002F\u002F src\u002Flib\u002Fdb\u002Fsql.ts\nimport { PrismaClient } from \"@prisma\u002Fclient\";\n\nconst globalForPrisma = globalThis as unknown as { prisma: PrismaClient };\n\nexport const prisma =\n  globalForPrisma.prisma ??\n  new PrismaClient({\n    log: process.env.NODE_ENV === \"development\" ? [\"query\", \"error\", \"warn\"] : [\"error\"],\n  });\n\nif (process.env.NODE_ENV !== \"production\") globalForPrisma.prisma = prisma;\n```\n\n---\n\n## Part 8: Authentication\n\n### Firebase Auth (default)\n\nUse the same patterns as the `firebase-auth-setup` skill. Key files:\n\n- `src\u002Flib\u002Ffirebase\u002Fclient.ts` — client SDK initialization\n- `src\u002Flib\u002Ffirebase\u002Fadmin.ts` — admin SDK initialization\n- `src\u002Fhooks\u002Fuse-auth.ts` — auth state hook with Google, Apple, email\u002Fpassword providers\n- `src\u002Fmiddleware.ts` — server-side token verification\n\n### Identity Platform (enterprise upgrade)\n\nIdentity Platform uses the same Firebase Auth SDK but adds:\n\n```bash\n# Enable Identity Platform (replaces Firebase Auth)\ngcloud services enable identitytoolkit.googleapis.com\n\n# Enable multi-tenancy\ngcloud identity-platform config update --enable-multi-tenancy\n\n# Create a tenant\ngcloud identity-platform tenants create \\\n  --display-name=\"Tenant A\" \\\n  --allow-password-signup \\\n  --enable-email-link-signin\n```\n\nClient-side code is identical to Firebase Auth. Server-side adds tenant awareness:\n\n```typescript\n\u002F\u002F Verify token with tenant context\nimport { adminAuth } from \"@\u002Flib\u002Ffirebase\u002Fadmin\";\n\nexport async function verifyTokenWithTenant(token: string, tenantId: string) {\n  const tenantAuth = adminAuth.tenantManager().authForTenant(tenantId);\n  try {\n    const decoded = await tenantAuth.verifyIdToken(token);\n    return { uid: decoded.uid, email: decoded.email, tenantId: decoded.firebase.tenant };\n  } catch {\n    return null;\n  }\n}\n```\n\n---\n\n## Part 9: Deployment Pipeline\n\n### Pre-Deploy Checklist\n\nRun these before every deployment. Adapt commands per framework:\n\n```bash\n# 1. Type checking\nnpx tsc --noEmit\n\n# 2. Linting\nnpx eslint . --ext .ts,.tsx\n\n# 3. Tests\nnpx vitest run\n\n# 4. Build\nnpm run build\n```\n\n### Cloud Run Deploy (production flow)\n\n```bash\n# 1. Ensure on main branch and up to date\ngit checkout main && git pull origin main\n\n# 2. Merge feature branch\ngit merge --squash \u003Cbranch-name>\ngit commit -m \"feat: \u003Csummary>\"\n\n# 3. Build and push container\ngcloud builds submit --tag gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name>\n\n# 4. Deploy new revision\ngcloud run deploy \u003Cservice-name> \\\n  --image gcr.io\u002F$GCP_PROJECT_ID\u002F\u003Cservice-name> \\\n  --platform managed \\\n  --region $GCP_REGION\n\n# 5. Health check\nSERVICE_URL=$(gcloud run services describe \u003Cservice-name> --region $GCP_REGION --format 'value(status.url)')\ncurl -sf \"$SERVICE_URL\u002Fapi\u002Fhealth\" | jq .\n\n# 6. If health check fails, rollback\ngcloud run services update-traffic \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --to-revisions \u003Cprevious-revision>=100\n```\n\n### GitHub Integration\n\n```bash\n# Create PR\ngh pr create --title \"feat: \u003Ctitle>\" --body \"\u003Cdescription>\" --base main\n\n# Check CI status\ngh pr checks \u003Cpr-number>\n\n# Merge (squash)\ngh pr merge \u003Cpr-number> --squash --delete-branch\n```\n\n### CI\u002FCD with Cloud Build (optional)\n\nCreate `cloudbuild.yaml` in the project root:\n\n```yaml\nsteps:\n  # Install dependencies\n  - name: 'node:20'\n    entrypoint: npm\n    args: ['ci']\n\n  # Run tests\n  - name: 'node:20'\n    entrypoint: npm\n    args: ['test']\n\n  # Build container\n  - name: 'gcr.io\u002Fcloud-builders\u002Fdocker'\n    args: ['build', '-t', 'gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}', '.']\n\n  # Push to Container Registry\n  - name: 'gcr.io\u002Fcloud-builders\u002Fdocker'\n    args: ['push', 'gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}']\n\n  # Deploy to Cloud Run\n  - name: 'gcr.io\u002Fcloud-builders\u002Fgcloud'\n    args:\n      - 'run'\n      - 'deploy'\n      - '${_SERVICE_NAME}'\n      - '--image=gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}'\n      - '--region=${_REGION}'\n      - '--platform=managed'\n\nsubstitutions:\n  _SERVICE_NAME: my-app\n  _REGION: us-central1\n\nimages:\n  - 'gcr.io\u002F$PROJECT_ID\u002F${_SERVICE_NAME}'\n```\n\n```bash\n# Set up Cloud Build trigger from GitHub\ngcloud builds triggers create github \\\n  --repo-name=\u003Crepo> \\\n  --repo-owner=\u003Cowner> \\\n  --branch-pattern=\"^main$\" \\\n  --build-config=cloudbuild.yaml\n```\n\n---\n\n## Part 10: Cloudflare DNS, CDN, and Security\n\n### API Base\n\n```\nhttps:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\n```\n\nAuth header: `Authorization: Bearer $CLOUDFLARE_API_TOKEN`\n\n### DNS Setup for Cloud Run\n\nGet the Cloud Run service URL, then create the DNS records:\n\n```bash\n# Get Cloud Run URL\nSERVICE_URL=$(gcloud run services describe \u003Cservice-name> --region $GCP_REGION --format 'value(status.url)')\n\n# Add CNAME record pointing custom domain to Cloud Run\ncurl -s -X POST \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fdns_records\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\n    \"type\": \"CNAME\",\n    \"name\": \"\u003Csubdomain>\",\n    \"content\": \"\u003Cservice-name>-\u003Chash>-\u003Cregion>.a.run.app\",\n    \"ttl\": 1,\n    \"proxied\": true\n  }' | jq .\n```\n\n### Domain Mapping on Cloud Run\n\n```bash\n# Map custom domain to Cloud Run service\ngcloud run domain-mappings create \\\n  --service \u003Cservice-name> \\\n  --domain \u003Cyour-domain.com> \\\n  --region $GCP_REGION\n\n# Verify domain ownership\ngcloud run domain-mappings describe \\\n  --domain \u003Cyour-domain.com> \\\n  --region $GCP_REGION\n```\n\n### SSL\u002FTLS Configuration\n\n```bash\n# Set SSL to Full (Strict) — required when proxying through Cloudflare\ncurl -s -X PATCH \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fsettings\u002Fssl\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"value\": \"strict\"}' | jq .\n\n# Enable Always Use HTTPS\ncurl -s -X PATCH \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fsettings\u002Falways_use_https\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"value\": \"on\"}' | jq .\n```\n\n### Rate Limiting\n\n```bash\ncurl -s -X POST \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Frulesets\u002Fphases\u002Fhttp_ratelimit\u002Fentrypoint\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\n    \"rules\": [{\n      \"expression\": \"(http.request.uri.path matches \\\"^\u002Fapi\u002F\\\")\",\n      \"description\": \"Rate limit API routes\",\n      \"action\": \"block\",\n      \"ratelimit\": {\n        \"characteristics\": [\"ip.src\"],\n        \"period\": 60,\n        \"requests_per_period\": 100,\n        \"mitigation_timeout\": 600\n      }\n    }]\n  }' | jq .\n```\n\n### Cache Purge After Deploy\n\n```bash\ncurl -s -X POST \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fpurge_cache\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"purge_everything\": true}' | jq .\n```\n\n### Bot Fight Mode\n\n```bash\ncurl -s -X PUT \\\n  \"https:\u002F\u002Fapi.cloudflare.com\u002Fclient\u002Fv4\u002Fzones\u002F$CLOUDFLARE_ZONE_ID\u002Fbot_management\" \\\n  -H \"Authorization: Bearer $CLOUDFLARE_API_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  --data '{\"fight_mode\": true}' | jq .\n```\n\n### Standard Setup for New Projects (Cloudflare)\n\n1. Add CNAME record pointing to Cloud Run service URL.\n2. Set SSL to Full (Strict).\n3. Enable Always Use HTTPS.\n4. Add rate limiting for `\u002Fapi\u002F*` routes.\n5. Enable Bot Fight Mode.\n6. Set browser cache TTL to 4 hours.\n7. Purge cache after every production deployment.\n\n---\n\n## Part 11: Cloud Storage (Static Assets and Uploads)\n\n### Create Bucket\n\n```bash\ngcloud storage buckets create gs:\u002F\u002F$GCP_PROJECT_ID-assets \\\n  --location=$GCP_REGION \\\n  --uniform-bucket-level-access\n\n# Make public (for static assets served via CDN)\ngcloud storage buckets add-iam-policy-binding gs:\u002F\u002F$GCP_PROJECT_ID-assets \\\n  --member=allUsers \\\n  --role=roles\u002Fstorage.objectViewer\n```\n\n### Upload Helper (server-side)\n\n```typescript\n\u002F\u002F src\u002Flib\u002Fstorage.ts\nimport { Storage } from \"@google-cloud\u002Fstorage\";\n\nconst storage = new Storage({ projectId: process.env.GCP_PROJECT_ID });\nconst bucket = storage.bucket(`${process.env.GCP_PROJECT_ID}-assets`);\n\nexport async function uploadFile(file: Buffer, filename: string, contentType: string) {\n  const blob = bucket.file(filename);\n  const stream = blob.createWriteStream({\n    metadata: { contentType },\n    resumable: false,\n  });\n\n  return new Promise\u003Cstring>((resolve, reject) => {\n    stream.on(\"error\", reject);\n    stream.on(\"finish\", () => {\n      resolve(`https:\u002F\u002Fstorage.googleapis.com\u002F${bucket.name}\u002F${filename}`);\n    });\n    stream.end(file);\n  });\n}\n```\n\n---\n\n## Part 12: Secret Manager\n\nNever hardcode secrets. Use Secret Manager for all sensitive values.\n\n```bash\n# Create a secret\necho -n \"my-secret-value\" | gcloud secrets create \u003Csecret-name> --data-file=-\n\n# Grant Cloud Run access\ngcloud secrets add-iam-policy-binding \u003Csecret-name> \\\n  --member=\"serviceAccount:\u003Cservice-account>@$GCP_PROJECT_ID.iam.gserviceaccount.com\" \\\n  --role=\"roles\u002Fsecretmanager.secretAccessor\"\n\n# Mount in Cloud Run\ngcloud run services update \u003Cservice-name> \\\n  --region $GCP_REGION \\\n  --set-secrets \"ENV_VAR=\u003Csecret-name>:latest\"\n```\n\n---\n\n## Part 13: Monitoring and Logging\n\n### View Logs\n\n```bash\n# Cloud Run logs\ngcloud logging read \"resource.type=cloud_run_revision AND resource.labels.service_name=\u003Cservice-name>\" \\\n  --limit 50 --format json | jq '.[].textPayload'\n\n# Cloud Functions logs\ngcloud functions logs read \u003Cfunction-name> --gen2 --region $GCP_REGION --limit 50\n```\n\n### Error Reporting\n\n```bash\n# Enable Error Reporting\ngcloud services enable clouderrorreporting.googleapis.com\n```\n\n---\n\n## Commit Message Convention\n\nAll commits must follow Conventional Commits:\n\n- `feat:` — new feature\n- `fix:` — bug fix\n- `refactor:` — code change that neither fixes a bug nor adds a feature\n- `test:` — adding or fixing tests\n- `chore:` — tooling, config, deps\n- `docs:` — documentation only\n- `db:` — database migrations or schema changes\n- `infra:` — infrastructure changes (Cloud Run config, Cloudflare rules, IAM)\n\n## Branch Strategy\n\n- `main` = production. Every push triggers production deployment.\n- Feature branches (`feat\u002F`, `fix\u002F`, `refactor\u002F`) = preview\u002Fstaging deploys.\n- Never force-push to `main`.\n\n## Safety Rules\n\n- NEVER deploy to production without running the pre-deploy checklist.\n- NEVER store credentials in code or commit `.env` files.\n- NEVER delete Cloud SQL instances or Firestore databases without explicit user confirmation.\n- NEVER modify IAM roles without user approval.\n- ALWAYS verify `.gitignore` includes credential files before the first commit.\n- For destructive operations (DROP TABLE, delete Cloud Run service, purge Firestore collection), require a dry-run first and show the user what will be affected.\n",{"name":5,"description":7,"user-invocable":24},true,"main","f9d3fe7cf9ac8f1ea63a0d96e98e1f510a3814db","skills\u002Fguifav\u002Fgcp-fullstack",1,"https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills","https:\u002F\u002Fgithub.com\u002Fjavimosch","intrane.fr","Building robust, open-source infrastructure for the commons. AI-leveraged, self-hosted, built to last.","2026-06-07 03:34:58",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":24},[36,39,42],{"tool":37,"command":38},"npx","npx skills add javimosch\u002Fopen-claw-skills --skill gcp-fullstack",{"tool":40,"command":41},"bunx","bunx skills add javimosch\u002Fopen-claw-skills --skill gcp-fullstack",{"tool":43,"command":44},"pnpm","pnpm dlx skills add javimosch\u002Fopen-claw-skills --skill gcp-fullstack","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fguifav\u002Fgcp-fullstack\u002FSKILL.md",[],[48,56,63,70,77,84],{"skillNo":49,"name":50,"nameZh":6,"description":51,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":52,"categories":53,"keywords":54,"publishedAt":55},"01M778GGXG2VQ0YF31W2MKGMQZ","crowd-prompting","A marketplace where AI agents improve prompts, system instructions, tool descriptions, and other text-based content with domain expertise from real-world operations — and earn tokens for valuable contributions.","https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzzadrian\u002Fcrowd-prompting\u002FSKILL.md",[],[],"2026-11-15 14:19:17",{"skillNo":57,"name":58,"nameZh":6,"description":59,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":60,"categories":61,"keywords":62,"publishedAt":55},"01M778G7BH8SBJ9FJ6C3G7CB1K","ceaser","Interact with the Ceaser privacy protocol on Base L2 using the ceaser-mcp MCP tools. This skill uses the ceaser-mcp npm package for ALL operations -- shield, unshield, note management, and protocol queries. All ceaser tool calls use CLI subcommands (npx -y ceaser-mcp \u003Csubcommand>). Ceaser is a privacy-preserving ETH wrapper using Noir\u002FUltraHonk zero-knowledge proofs on Base L2 (chain ID 8453).","https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzyra-v21\u002Fceaser\u002FSKILL.md",[],[],{"skillNo":64,"name":65,"nameZh":6,"description":66,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":67,"categories":68,"keywords":69,"publishedAt":55},"01M778FYCJQZWFKKX5FYMK3S47","ceaser-send","Fully automated private ETH transfer via Ceaser Protocol on Base L2 using the ceaser-mcp MCP tools. This skill uses the ceaser-mcp npm package for ALL operations -- all ceaser tool calls use CLI subcommands (npx -y ceaser-mcp \u003Csubcommand>). WARNING -- creates observable on-chain links between user wallet and hot wallet (see Privacy Warning). Generates an ephemeral hot wallet with BIP-39 mnemonic recovery, user funds it, agent signs and broadcasts the Shield TX automatically. Exactly one manual step required (funding the hot wallet with ETH). Uses Noir\u002FUltraHonk zero-knowledge proofs.","https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzyra-v21\u002Fceaser-send\u002FSKILL.md",[],[],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":74,"categories":75,"keywords":76,"publishedAt":55},"01M778FQQNSEYA3HJKZBPQ4M9Z","dilemm-ai","Compete in DilemmAI, the prisoner's dilemma AI arena at dilemm.ai. Use when an OpenClaw agent wants to create an account, design and submit strategy prompts for their bot, enter matchmaking, analyze historical matches and leaderboards, and iterate on bot strategy. Requires headless browser automation (no API available yet).","https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzyori\u002Fdilemm-ai\u002FSKILL.md",[],[],{"skillNo":78,"name":79,"nameZh":6,"description":80,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":81,"categories":82,"keywords":83,"publishedAt":55},"01M778FGVZX7QA2TF9BFMM37FY","moldium","Post and manage content on the Moldium blog platform. Triggered by \"post to Moldium\", \"write a blog post\", \"publish an article\", etc.","https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzyom45\u002Fmoldium\u002FSKILL.md",[],[],{"skillNo":85,"name":86,"nameZh":6,"description":87,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":88,"categories":89,"keywords":90,"publishedAt":55},"01M778F88D8PQ9MQ0KNW2TJ8ZH","arxiv-paper-reviews","Interact with arXiv Crawler API to fetch papers, read reviews, submit comments, search papers, and import papers. Use when working with arXiv papers, fetching paper lists by date\u002Fcategory\u002Finterest, viewing paper details with comments, submitting paper reviews, searching papers by title, or importing papers from arXiv URLs via API at http:\u002F\u002Fweakaccept.top:8000\u002F.","https:\u002F\u002Fgithub.com\u002Fjavimosch\u002Fopen-claw-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzxrys\u002Farxiv-paper-reviews\u002FSKILL.md",[],[]]