Socket
Socket
Sign inDemoInstall

firebase-functions

Package Overview
Dependencies
235
Maintainers
4
Versions
108
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    firebase-functions

Firebase SDK for Cloud Functions


Version published
Weekly downloads
480K
decreased by-5.03%
Maintainers
4
Install size
7.85 MB
Created
Weekly downloads
 

Readme

Source

Firebase SDK for Cloud Functions

The firebase-functions package provides an SDK for defining Cloud Functions for Firebase.

Cloud Functions is a hosted, private, and scalable Node.js environment where you can run JavaScript code. The Firebase SDK for Cloud Functions integrates the Firebase platform by letting you write code that responds to events and invokes functionality exposed by other Firebase features.

Learn more

Learn more about the Firebase SDK for Cloud Functions in the Firebase documentation or check out our samples.

Here are some resources to get help:

If the official documentation doesn't help, try asking through our official support channels: https://firebase.google.com/support/

Please avoid double posting across multiple channels!

Usage

// functions/index.js
const functions = require("firebase-functions");
const notifyUsers = require("./notify-users");

exports.newPost = functions.database.ref("/posts/{postId}").onCreate((snapshot, context) => {
  functions.logger.info("Received new post with ID:", context.params.postId);
  return notifyUsers(snapshot.val());
});

Contributing

To contribute a change, check out the contributing guide.

License

© Google, 2017. Licensed under The MIT License.

Keywords

FAQs

Last updated on 04 Apr 2024

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc