The Firebase Realtime Database reference builder interface.

Access via functions.database.ref().

Index

Properties

Private apps

apps: Apps

Private options

Private triggerResource

triggerResource: () => string

Type declaration

    • (): string
    • Returns string

Methods

Private changeConstructor

onCreate

  • Event handler that fires every time new data is created in Firebase Realtime Database.

    Parameters

    Returns CloudFunction<DataSnapshot>

    A Cloud Function that you can export and deploy.

onDelete

  • Event handler that fires every time data is deleted from Firebase Realtime Database.

    Parameters

    Returns CloudFunction<DataSnapshot>

    A Cloud Function that you can export and deploy.

Private onOperation

  • onOperation<T>(handler: (data: T, context: EventContext) => PromiseLike<any> | any, eventType: string, dataConstructor: (raw: Event | Event) => any): CloudFunction<T>
  • Type parameters

    • T

    Parameters

    • handler: (data: T, context: EventContext) => PromiseLike<any> | any
        • Parameters

          Returns PromiseLike<any> | any

    • eventType: string
    • dataConstructor: (raw: Event | Event) => any
        • (raw: Event | Event): any
        • Parameters

          • raw: Event | Event

          Returns any

    Returns CloudFunction<T>

onUpdate

onWrite