-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathextension.yaml
More file actions
95 lines (88 loc) · 3.05 KB
/
extension.yaml
File metadata and controls
95 lines (88 loc) · 3.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
name: firestore-activity-feeds
version: 0.2.7
specVersion: v1beta # Firebase Extensions specification version (do not edit)
displayName: Sync Firestore with Activity Feeds
description: Populates Stream Activity feeds using documents in a Firestore.
license: Apache-2.0 # The license you want for the extension
author:
authorName: Stream
url: https://getstream.io/
sourceUrl: https://github.com/GetStream/stream-firebase-extensions/tree/main/firestore-activity-feeds
billingRequired: true
params:
- param: LOCATION
label: Cloud Functions location
description: >-
Where do you want to deploy the functions created for this extension?
For help selecting a location, refer to the [location selection
guide](https://firebase.google.com/docs/functions/locations).
type: select
options:
- label: us-central1 (Iowa)
value: us-central1
- label: us-east1 (South Carolina)
value: us-east1
- label: us-east4 (Northern Virginia)
value: us-east4
- label: us-west2 (Los Angeles)
value: us-west2
- label: us-west3 (Salt Lake City)
value: us-west3
- label: us-west4 (Las Vegas)
value: us-west4
- label: asia-east2 (Hong Kong)
value: asia-east2
- label: asia-northeast1 (Tokyo)
value: asia-northeast1
- label: asia-northeast2 (Osaka)
value: asia-northeast2
- label: asia-northeast3 (Seoul)
value: asia-northeast3
- label: asia-south1 (Mumbai)
value: asia-south1
- label: asia-southeast2 (Jakarta)
value: asia-southeast2
- label: australia-southeast1 (Sydney)
value: australia-southeast1
- label: europe-central2 (Warsaw)
value: europe-central2
- label: europe-west1 (Belgium)
value: europe-west1
- label: europe-west2 (London)
value: europe-west2
- label: europe-west3 (Frankfurt)
value: europe-west3
- label: europe-west6 (Zurich)
value: europe-west6
- label: northamerica-northeast1 (Montreal)
value: northamerica-northeast1
- label: southamerica-east1 (Sao Paulo)
value: southamerica-east1
default: us-central1
required: true
immutable: true
- param: COLLECTION
label: Firestore collection name
description: In which collection do you want to store your activity data?
type: string
default: feeds
required: true
- param: STREAM_API_KEY
label: API key for the Stream API
description: What is your Stream API key?
type: secret
required: true
- param: STREAM_API_SECRET
label: API secret for the Stream API
description: What is your Stream API secret?
type: secret
required: true
resources:
- name: activitiesToFirestore
type: firebaseextensions.v1beta.function
properties:
location: ${LOCATION}
runtime: nodejs20
eventTrigger:
eventType: providers/cloud.firestore/eventTypes/document.write
resource: projects/${PROJECT_ID}/databases/(default)/documents/${COLLECTION}/{feedId}/{userId}/{foreignId}