Skip to content

Commit 4645ea3

Browse files
authored
Merge pull request #730 from jonathangrinstead/docs/alternatives-section
📝 Add Alternatives section to README (closes #674)
2 parents 1286917 + 049a634 commit 4645ea3

1 file changed

Lines changed: 20 additions & 4 deletions

File tree

README.md

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,15 +117,31 @@ Notes
117117

118118
</details>
119119

120-
If it seems like you are in the wrong place, you might try one of these:
120+
### Alternatives
121121

122-
* [OAuth 2.0 Spec][oauth2-spec]
123-
* [doorkeeper gem][doorkeeper-gem] for OAuth 2.0 server/provider implementation.
124-
* [oauth sibling gem][sibling-gem] for OAuth 1.0a implementations in Ruby.
122+
This gem is a low-level OAuth 2.0 **client** (it talks _to_ an authorization server to obtain and use tokens).
123+
If that isn't quite what you need, one of the following libraries may be a better fit (the first row is this gem for comparison):
124+
125+
| Library | Role | When to use it |
126+
|------------------------------------------------|-------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
127+
| **this gem** ([oauth2][📜src-gh]) | OAuth 2.0 / 2.1 + OIDC **client** | You are calling an OAuth 2.0 API, or signing in against a provider, and want a small, dependency-light, spec-faithful client with fine-grained control over the request/response cycle. |
128+
| [omniauth][omniauth-gem] + [omniauth-oauth2][omniauth-oauth2-gem] | "Log in with…" **client** (Rack) | You primarily want user _authentication_ ("Log in with GitHub/GitLab/Google") wired into a Rack/Rails app via a strategy, rather than driving the token flow yourself. |
129+
| [openid_connect][openid-connect-gem] | OpenID Connect client & server | You need full [OpenID Connect][oidc-spec] (ID-token validation, discovery, userinfo, etc.) with batteries included. Maintained by [@nov][nov]. |
130+
| [rack-oauth2][rack-oauth2-gem] | OAuth 2.0 client **and** server | You want lower-level Rack primitives, need both client and server pieces, or are building on top of `openid_connect`. Maintained by [@nov][nov]. |
131+
| [doorkeeper][doorkeeper-gem] | OAuth 2.0 **server / provider** | You want to _be_ the authorization server — issuing tokens to other apps — in a Rails/Grape/Sinatra application, rather than acting as a client. |
132+
| [oauth][sibling-gem] | OAuth **1.0a** client & server | The provider you integrate with only speaks the older OAuth 1.0a protocol. This is our sibling gem. |
133+
134+
See also the [OAuth 2.0 Spec][oauth2-spec] and the [OpenID Connect Spec][oidc-spec].
125135

126136
[oauth2-spec]: https://oauth.net/2/
137+
[oidc-spec]: https://openid.net/developers/how-connect-works/
127138
[sibling-gem]: https://gitlab.com/ruby-oauth/oauth
128139
[doorkeeper-gem]: https://github.com/doorkeeper-gem/doorkeeper
140+
[omniauth-gem]: https://github.com/omniauth/omniauth
141+
[omniauth-oauth2-gem]: https://github.com/omniauth/omniauth-oauth2
142+
[openid-connect-gem]: https://github.com/nov/openid_connect
143+
[rack-oauth2-gem]: https://github.com/nov/rack-oauth2
144+
[nov]: https://github.com/nov
129145

130146
## 💡 Info you can shake a stick at
131147

0 commit comments

Comments
 (0)