firebase avatar

Extension To Functions Codebase

If you have a Firebase Extension installed and want to stop depending on it, this skill walks you through turning it into either a local `functions/src/` codebase or a publishable npm package. It maps `extension.yaml` params to `defineString` and `defineSecret`, swaps `requiresRole` and `requiresAPI` in for the manual IAM and API setup steps, and upgrades 1st Gen triggers to 2nd Gen with a destructuring shim so legacy handlers keep working. The part I'd pay closest attention to is the `cpu: "gcf_gen1"` setting, since V2's default concurrency will change your cost profile unless you pin it. It won't publish the package for you, which is a sensible guardrail.

skills.sh installs
63.5K
GitHub stars
508
last updated
Oct 26, 2026

Install

$ npx -y skills add firebase/agent-skills --skill extension-to-functions-codebase --agent claude-code

Installs into .claude/skills of the current project.

Files

Extension to Functions Codebase & npm Package Migration

Overview

Migrates a Firebase Extension into either:

  1. A local Cloud Functions codebase (functions/src/ for app integration).
  2. A publishable npm package (reusable open-source package exporting V2 functions).

Leverages native Cloud Functions features (declarative IAM, Parameterized Config, SDK Lifecycle Hooks) and modernizes 1st Gen triggers to 2nd Gen using the Destructuring Compatibility Shim.


Target Migration Workflows

  • Target A: Local Functions Codebase (End-User App Integration)

    • Output: Code under functions/src/. Config in .env.
    • Deployment: firebase deploy --only functions.
  • Target B: Publishable npm Package / Shareable Package

    • Output: Reusable npm package exporting V2 functions.
    • Configuration: package.json specifying exports map, engines: { "node": ">=22" }, and peerDependencies: { "firebase-functions": ">=6.0.0" }.
    • Usage: Consumers install package and re-export functions in index.ts (export * from "<package-name>").

Sponsors

Details

Repository
github.com/firebase/agent-skills
Categories
Frontend Development, Backend & APIs, Security, AI & Agent Building, Cloud & Infrastructure, Databases
First seen
Oct 26, 2026

More from firebase/agent-skills

All 23
1firecrawl avatarfirecrawl-build-scrapefirecrawl/skillsIntegrate Firecrawl `/scrape` into product code for single-page extraction. Use when an app already has a URL and needs markdown, HTML, links, screenshots, meta62.6Kskills.sh installs
2heygen-com avatarseam-craftheygen-com/hyperframesRender-correctness doctrine for scene-to-scene seams in HyperFrames launch videos — the prerequisites that make transitions composite correctly on the master ti61.1Kskills.sh installs
3pbakaus avatarextractpbakaus/impeccableExtract and consolidate reusable components, design tokens, and patterns into your design system. Identifies opportunities for systematic reuse and enriches you53.2Kskills.sh installs
4alchaincyf avatarhuashu-designalchaincyf/huashu-design花叔Design——用HTML做高保真原型、幻灯片、动画、可视化与专家评审。任何新设计100%先出三个方向初稿给用户选(指定风格/品牌也不豁免),选定后才执行。触发词:做原型、PPT、幻灯片、动画、设计风格、评审、做个HTML页面、UI mockup、导出MP4/GIF、做个好看的。生产级Web App/需后端的系统不52.8Kskills.sh installs
5firecrawl avatarfirecrawl-parsefirecrawl/cliEfficiently extract and convert the contents of any local file—such as PDF, DOCX, DOC, ODT, RTF, XLSX, XLS, or HTML—into clean, well-formatted markdown saved to51.5Kskills.sh installs
6expo avatarexpo-moduleexpo/skillsFramework (OSS). Guide for creating and writing Expo native modules and views using the Expo Modules API (Swift, Kotlin, TypeScript). Covers module definition D48.8Kskills.sh installs