firebase-admin-node icon indicating copy to clipboard operation
firebase-admin-node copied to clipboard

[FR] Support Edge and Deno runtime

Open oreqizer opened this issue 2 years ago • 15 comments

Is your feature request related to a problem? Please describe.

https://nextjs.org/docs/api-reference/edge-runtime

I'd like to use firebase-admin in an Edge environment and Deno. The package currently uses Node-specific APIs though, making that impossible.

Describe the solution you'd like

Would be awesome to support the Edge/Deno runtime, e.g. via firebase-admin/common.

oreqizer avatar Jul 06 '22 09:07 oreqizer

I found a few problems with this issue:

  • I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
  • This issue does not seem to follow the issue template. Make sure you provide all the required information.

google-oss-bot avatar Jul 06 '22 09:07 google-oss-bot

We currently do not have any specific plans to support Deno or Edge runtime. Although, I would encourage you to file a feature request through https://firebase.google.com/support to create more visibility on this within the team. It will also help us gauge the interest for these feature requests. Thank you!

lahirumaramba avatar Jul 08 '22 18:07 lahirumaramba

Duplicate of #1307

lahirumaramba avatar Jul 08 '22 18:07 lahirumaramba

@oreqizer This repo is open source. Do you think forking this repo and making firebase-admin-deno with the necessary changes is a possibility?

Disclaimer: I’m not a Deno user, and don’t suggest to contribute. It would be an interesting thing to follow, though…

akauppi avatar Jul 16 '22 18:07 akauppi

@akauppi it definitely would be to some extent, depending on related dependencies. out of my time capacity to gauge/attempt though

oreqizer avatar Jul 19 '22 08:07 oreqizer

We'd love to see nextjs edge support.

maccman avatar Jun 24 '23 02:06 maccman

If possible, we would like edge support as well, as firebase-admin is not working in Next.js middleware.

axelvaindal avatar Jul 06 '23 10:07 axelvaindal

Hey is there any progress with this PR?

Moe03 avatar Aug 26 '23 11:08 Moe03

Using the rest API was my workaround see the story https://m3hari.medium.com/firebase-database-using-rest-api-3b4c8982164e

m3hari avatar Nov 08 '23 04:11 m3hari

@m3hari the admin package does more than that. For example, I'd like to decode a firebase id token and get custom claims from it.

0x80 avatar Nov 08 '23 17:11 0x80

I'd like to do this exact same use case. Has anyone found a work around?

@m3hari the admin package does more than that. For example, I'd like to decode a firebase id token and get custom claims from it.

scottwittrock avatar Nov 12 '23 00:11 scottwittrock

just verifying token was my use case

m3hari avatar Nov 12 '23 05:11 m3hari

What about REST API? My issue here was closed today claiming that I can use AUTH REST API to manage users. Do you agree with lahirumaramba (Firebase employee)?

step135 avatar Jan 10 '24 19:01 step135

@step135 I don't think that is true. Decoding a token I wouldn't categorize as "managing users" and looking at the list on the right side of the API reference I don't see it either: https://firebase.google.com/docs/reference/rest/auth

0x80 avatar Jan 11 '24 08:01 0x80