index.d.ts 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. /*! firebase-admin v12.1.1 */
  2. /*!
  3. * @license
  4. * Copyright 2022 Google Inc.
  5. *
  6. * Licensed under the Apache License, Version 2.0 (the "License");
  7. * you may not use this file except in compliance with the License.
  8. * You may obtain a copy of the License at
  9. *
  10. * http://www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing, software
  13. * distributed under the License is distributed on an "AS IS" BASIS,
  14. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. * See the License for the specific language governing permissions and
  16. * limitations under the License.
  17. */
  18. /**
  19. * Firebase Eventarc.
  20. *
  21. * @packageDocumentation
  22. */
  23. import { App } from '../app';
  24. import { Eventarc } from './eventarc';
  25. export { CloudEvent, CloudEventVersion } from './cloudevent';
  26. export { Eventarc, Channel, ChannelOptions } from './eventarc';
  27. /**
  28. * Gets the {@link Eventarc} service for the default app or a given app.
  29. *
  30. * `getEventarc()` can be called with no arguments to access the default
  31. * app's `Eventarc` service or as `getEventarc(app)` to access the
  32. * `Eventarc` service associated with specific app.
  33. *
  34. * @example
  35. * ```javascript
  36. * // Get the Eventarc service for the default app
  37. * const defaultEventarc = getEventarc();
  38. * ```
  39. *
  40. * @example
  41. * ```javascript
  42. * // Get the Eventarc service for a given app
  43. * const otherEventarc = getEventarc(otherApp);
  44. * ```
  45. *
  46. * @param app - Optional app whose `Eventarc` service will be returned.
  47. * If not provided, the default `Eventarc` service will be returned.
  48. *
  49. * @returns The default `Eventarc` service if no
  50. * app is provided or the `Eventarc` service associated with the provided
  51. * app.
  52. */
  53. export declare function getEventarc(app?: App): Eventarc;