Sharepoint Online Authentication for API Access using POSTMAN

Objective: We know most of the collaboration part of sharepoint has been pushed to Teams, with its planner, conversations, a dedicated site for document uploads and many other features.
So the sharepoint site is now used mostly for document management. Being said that how we can accomodate SPO API for other applications.

In this post we will use SP Online OOTB API to upload and download a file. We dont need to write a seperate application for this, instead we will use POSTMAN to interpret the calls.

When API is avilable OOTB why do we need this post?
Well Service API is available OOTB, but there is specific way we need to authenticate to use that API. That is what we are going to show here.

Let me give a highlevel overview of how authentication works in Office365 Sharepoint site in this case.