Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement listen for Firestore #23

Open
dwatrous opened this issue Nov 5, 2023 · 4 comments
Open

Implement listen for Firestore #23

dwatrous opened this issue Nov 5, 2023 · 4 comments
Labels
enhancement New feature or request

Comments

@dwatrous
Copy link

dwatrous commented Nov 5, 2023

Is your proposal related to a problem?

I would like to use firestore to listen to changes, as is possible with this REST endpoint:
https://firebase.google.com/docs/firestore/reference/rest/v1beta1/projects.databases.documents/listen

Similar functionality is available for the Firebase Realtime Database module of this library, but it would be more convenient to stay in Firestore

Describe the solution you'd like.

`fsdb.collection('messages').listen(callback)`

Describe alternatives you've considered.

I tried implementing this with realtime database, but implementing in my app on flutterflow isn't supported.

Additional context.

No response

@dwatrous dwatrous added the enhancement New feature or request label Nov 5, 2023
Copy link

github-actions bot commented Nov 5, 2023

Hello @dwatrous , thank you for submitting an issue! A project committer will shortly review the issue.

@AsifArmanRahman
Copy link
Owner

Could you provide me the source of the endpoint?

@dwatrous
Copy link
Author

dwatrous commented Dec 8, 2023

After further review, I don't believe that firestore offers a REST endpoint or other mechanism to listen for changes in realtime. This is possible using the admin sdk, but that requires a service account instead of using the user's id token jwt, so it won't work for my use case.

@AsifArmanRahman
Copy link
Owner

Yeah some endpoints are allocated to be used with admin creds only. But if you figure out proper conditions and user roles, you can make the service account work for specific user tokens.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants