Ad

functions-samples: Cloud Functions for Firebase runtime examples

Cloud Functions for Firebase: A collection of sample applications demonstrating common use cases with Node.js and Python.
Screenshot of firebase/functions-samples homepage

Cloud Functions for Firebase enables serverless execution of backend code in response to events from various Firebase services. This repository provides curated samples illustrating common scenarios. It offers examples for both Node.js (1st and 2nd gen) and Python (2nd gen), covering triggers like Firestore, Realtime Database, PubSub, Storage, Authentication, and more. The samples demonstrate how to build scalable and event-driven applications without managing infrastructure.

The repository showcases a wide array of use cases, from simple data transformations to complex integrations with Firebase services and external APIs. It features clear and concise code implementations with detailed explanations, making it easy to understand and adapt to individual needs. The inclusion of both Node.js and Python examples supports developer flexibility. The code is well-organized and provides a practical starting point for building serverless solutions.

  • Firestore Uppercaser: Transforms text written to Firestore to uppercase using a Firestore trigger. - Callable Functions: Demonstrates functions accessible via HTTP requests for data manipulation. - HTTPS Time Server: Provides a simple HTTPS endpoint that returns the current server time. - Thumbnail Generator: Generates thumbnails from uploaded images to Firebase Storage. - Welcome Email: Sends welcome emails to new users upon account creation. - Auth Blocking Functions: Validates user email and checks user status before sign-in. - PubSub Hello World: Demonstrates handling messages triggered by PubSub events.

The repository is actively maintained, with recent commits and ongoing development. While some examples reference older function versions (1st gen), the focus is shifting towards 2nd generation functions. The provided documentation outlines key considerations for Python support, indicating a transitional phase. While regular updates are not specified, the active commit history suggests continuing support.

This repository is beneficial for developers looking to quickly prototype and understand how to use Cloud Functions for Firebase. It offers a practical collection of working examples for various use cases, enabling rapid development and deployment of serverless applications. It serves as a valuable resource for learning the capabilities of Cloud Functions and integrating them into Firebase projects.

Summarize:
Share:
Stars
12,217
Forks
3,839
Issues
199
Created
9 years ago
Commit
17 days ago
License
APACHE-2.0
Archived
No
Updated 6 days ago

Similar Repositories