firebase / firebase-admin-go

Firebase Admin Go SDK
Apache License 2.0
1.13k stars 242 forks source link

FR: Allow for Auth Provider Configs to be set #440

Open ToeFungi opened 3 years ago

ToeFungi commented 3 years ago

At the moment it appears that only OIDC and SAML providers can be set via the Go client. Would be incredibly useful to add Firebase auth providers such as phone and email/password so that we can programmatically manage this with something like Terraform.

API

https://cloud.google.com/identity-platform/docs/reference/rest/v2/projects/updateConfig

Note

It appears that the Node SDK has this functionality available already.

google-oss-bot commented 3 years ago

I found a few problems with this issue:

hiranya911 commented 3 years ago

I think this was already implemented in #344

https://pkg.go.dev/firebase.google.com/go/v4/auth#UserToUpdate.ProviderToLink

@ToeFungi can you check if this meets your needs?

ToeFungi commented 3 years ago

@hiranya911 if I'm understanding the documentation correctly, that enables the provider against a specific user?

We're looking to enable Phone and Email/Password auth providers at the project level. I'm not sure if that implementation handles project level enabling of the providers?

hiranya911 commented 3 years ago

Ah, that's more of a project management operation.

@bojeil-google wdyt?

bojeil-google commented 3 years ago

I think this is part of bigger project to configure built-in providers (email/password, email link, phone, social providers, etc) at project level as well as tenant level. We have been wanting to do this for a while but this needs product approval.

ToeFungi commented 3 years ago

We created a custom client and Terraform provider to accomplish this as well as #441 in the mean time. Would be ideal if this was added officially though.

numbsafari commented 5 months ago

Customer here. Not sure why the go client isn't comprehensive of the REST API.