In this guide, you will set up a hardened, fully functional OAuth 2.0 (OAuth2) server. It will take you about ~15 minutes. This guide is for you, if you are looking to do something like in the gif on the right, or more specifically:
- You want to use OAuth2 for API security.
- You want to open up your API to third party developers like Dropbox, or GitHub.
- You want to become and identity provider like Google, Facebook, or Twitter.
- You need to federate (delegate) authentication or authorization.
We will use ORY Hydra (open source), a security-first OAuth2 and OpenID Connect server written in Golang.

https://www.ory.am/run-oauth2-server-open-source-api-security.html?