liveBook · Manning

Authorization flow

As explained in Secure APIs

An authorization flow is a protocol sequence through which a client obtains permission and an access token to access protected resources.

An authorization flow is the sequence through which a client obtains permission and an access token to reach protected data. OAuth uses it to avoid sharing a user’s credentials while limiting access to selected scopes and a limited time. section 7.3

An OAuth flow connects four roles:

  • The resource owner owns the data. section 7.3
  • The client requests access on the owner’s behalf. section 7.3
  • The authorization server manages identities and issues access tokens. section 7.3
  • The resource server stores data and enforces access. section 7.3
Figure 7.5 OAuth describes flows through which users (resource owners) can authorize applications (clients) to access their data in an API (resource server). Every flow begins with an authorization request, followed by user login and consent and then by an access token grant.
figure

The sequence begins with an authorization request, continues through user login and consent, and ends with an access-token grant. section 7.3

Admin API flow

An admin login endpoint requests an authorization code for a specific audience using the admin client. A token endpoint exchanges that code with the client secret, then protected endpoints validate the token and require an admin permission. section 8.6

How Secure APIs covers it

How deep it goes
Explains roles, scopes, tokens, consent, and an authorization-code implementation, then stops short of comparing flow types.
Examples
Uses a LinkedIn profile import scenario and an Auth0-backed admin login, token exchange, and protected endpoint.
What you can do after
Operate an Auth0 authorization-code flow and restrict API endpoints using token claims and permissions.
How it connects
Connects authorization flows with OAuth, scopes, access tokens, authorization servers, resource servers, and role-based access control.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Secure APIs. The section links point to the parts of the book it draws on.