Create a trigger for Cloud Functions (2nd gen)

You can create an Eventarc trigger that enables a Cloud Function to be triggered by an event supported by Eventarc. Note that you must configure a trigger when you create or deploy a function using the Google Cloud CLI or the Google Cloud console.

You can also trigger Cloud Functions in response to custom events published to an Eventarc channel.

Create an Eventarc trigger

Create an Eventarc trigger so that your Cloud Functions service receives notifications of a specific event or set of events. By specifying filters for the trigger, you can configure the routing of the event, including the event type and source. For more information on how to configure an Eventarc trigger for Cloud Functions, see Eventarc triggers.

The following event types trigger requests to your service:

Trigger functions with custom events

You can trigger Cloud Functions in response to custom events. These are events produced by special or additional event providers, as opposed to the built-in Firebase events supported by the Firebase SDK for Cloud Functions, and that are published to an Eventarc channel. For more information, see Create and handle custom event triggers. Note that for custom events provided by Firebase Extensions, you should refer to the extension's documentation for a list of events (if any) that it publishes. For example, see the event types for the Run Payments with Stripe extension.