API Evangelist API Evangelist
API Learnings
APIs
API Governance
API Solutions
API Discovery
API Building Blocks
API Evangelist LLC

OAuth 2.0

Secondary

OAuth 2.0 is an authorization framework that allows third-party applications to securely access a user’s resources without requiring the user to share their credentials. Instead, it uses access tokens, which are issued by an authorization server after the user grants permission. These tokens enable applications to make requests on behalf of the user, ensuring secure and limited access to protected resources, such as APIs or databases. OAuth 2.0 supports multiple grant types (flows), including Authorization Code, Client Credentials, and Device Authorization, making it adaptable to different use cases like web, mobile, and IoT applications. It has become the standard for enabling single sign-on (SSO) and delegated access in modern web and mobile applications.

The framework is token-based and eliminates the need for persistent server-side sessions, making it scalable and ideal for distributed systems and microservices architectures. OAuth 2.0 emphasizes security by using mechanisms like scopes to limit permissions, PKCE (Proof Key for Code Exchange) to protect public clients, and HTTPS for encrypted communication. It is widely adopted by major platforms like Google, Facebook, and GitHub, allowing developers to integrate third-party services seamlessly. Though OAuth 2.0 handles authorization, it can be extended with OpenID Connect (OIDC) to add authentication features, enabling applications to verify a users identity in addition to managing permissions.