Cloud Functions for Firebase is a serverless framework that lets you automatically run backend code in response to events triggered by Firebase features and HTTPS requests. Your JavaScript or TypeScript code is stored in Google's cloud and runs in a managed environment. There's no need to manage and scale your own servers.
Install-Package Plugin.Firebase.Functions
- Follow the instructions for the basic setup
- Enable Cloud Functions at your project in the Firebase Console
- Deploy your own function
- Call
CrossFirebaseFunctions.Initialize(string region)
if your functions are deployed outside the defaultus-central1
region
Take a look at the documentation for the official Firebase Cloud Function SKDs, because Plugin.Firebase's code is abstracted but still very similar.
Since code should be documenting itself you can also take a look at the following classes:
- src/.../IFirebaseFunctions.cs
- src/.../IHttpsCallable.cs
- tests/.../FunctionsFixture.cs
- tests/cloud-functions/.../index.ts
- Version 3.1.0
- Update to .net8
- Version 3.0.0
- Swapped Xamarin.Firebase.iOS.CloudFunctions (native SDK 8.10.0) for AdamE.Firebase.iOS.CloudFunctions (native SDK 10.24.0)
- Version 2.0.3
- Added support for non-default regions
- Version 2.0.2
- Bumped up Xamarin.Firebase.Functions package to version 120.3.1.3
- Version 2.0.1
- Remove unnecessary UseMaui property from csproj files
- Readd net6.0 tfm