Search code examples
omniauth

What is a provider in terms of omniauth?


When the docs refer to provider, is it referring to the Resource Provider, or the Doorkeeper that provides the authorization code?


Solution

  • In the context of the OmniAuth docs, a provider is an entity that provides an OAuth endpoint, that your users can use to log in to your application. The list of OmniAuth providers includes the main players you'd expect: Facebook, Google and Twitter. This wiki page is actually a bit confusing since sometimes it uses the word "provider" and other times it uses the word "strategy".

    As for Doorkeeper, it's a gem that allows you to create your own OAuth endpoint. You generally use this gem if you have a microservices architecture. You have one application responsible for authentication that provides an OAuth endpoint and then you have other several applications that use this endpoint to authenticate their users.