OAuthProvider
Enum class representing supported OAuth providers for authentication.
Each OAuth provider corresponds to a third-party authentication service that users can use to sign in to your application. The enum provides a type-safe way to reference OAuth providers and automatically handles the mapping to the appropriate strategy strings used in Clerk API requests.
Supported Providers
The enum includes support for major OAuth providers such as:
Social platforms: Facebook, Google, Twitter, Instagram, TikTok, Discord
Professional platforms: LinkedIn, Microsoft, Slack
Developer platforms: GitHub, GitLab, Bitbucket, Atlassian
Business platforms: HubSpot, Notion, Dropbox, Box, Xero
Entertainment platforms: Spotify, Twitch
AI platforms: Hugging Face
Custom providers: For enterprise or specialized OAuth implementations
Usage
OAuth providers are typically used when configuring sign-in flows or when processing authentication redirects from external services.
Example usage:
// Use with sign-in authentication
SignIn.authenticateWithRedirect(
AuthenticateWithRedirectParams.OAuth(strategy = OAuthProvider.GOOGLE)
)
// Convert from strategy string
val provider = OAuthProvider.fromStrategy("oauth_github")
See also
Entries
Properties
Returns a representation of an immutable list of all enum entries, in the order they're declared.
Extension property to get the logo URL for the OAuth provider.
Extension property to get the human-readable name of the OAuth provider.
Functions
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
Returns an array containing the constants of this enum type, in the order they're declared.