magic-js
magic-js copied to clipboard
Get enabled OAuth providers
✅ Prerequisites
- [x] Did you perform a cursory search of open issues? Is this feature already requested elsewhere?
- [x] Are you reporting to the correct repository (
magic-sdk
)?
✨ Feature Request
Add OAuth SDK functionality to see which OAuth provider is enabled.
🧩 Context
As I can see, there is no way to see which OAuth providers are enabled. So, in our applications, we need to dynamically maintain a list of enabled providers. That's horrible. If I've enabled, let's say Google and Facebook, I would like to be able to get this information to show Google and Facebook buttons. It's really inconvenient.
💻 Examples
Add method to OAuthExtension to get enabled providers:
export declare class OAuthExtension extends Extension.Internal<'oauth'> {
name: "oauth";
// ...
getEnabledProviders(): import("magic-sdk").PromiEvent<OAuthProvider[], {
done: (result: OAuthProvider[]) => void;
error: (reason: any) => void;
settled: () => void;
}>;
}
@mightymatth Our apologies for the delay in responding to this great feature request! I'll make sure this gets brought up with our Product team.