Microsoft One Drive Storage

Step 1:  If you have created an account with Microsoft Application Registration Portal(https://apps.dev.microsoft.com/?referrer=https:%2F%2Fdev.onedrive.com%2Fapp-registration.htm#/appList), login, else Signup

Step 2: Click on Add an App

https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965732/original/pwr_wv5kd4lzPoTnLdrYWCD2Sn-ghpIT_A.png?1610523408

Step 3: Enter your application name and click Create

https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965728/original/XJ91S-AL-riQMtmOcZTZpQAGpnUuO0Sjqw.png?1610523407

Step 4: For  Redirect URL  ‘https://app.empmonitor.com.in’

URL:

https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965731/original/1nfdltIP07p4jStw-J5NtZnxSCmJy1dkAA.png?1610523408

Step 5: Click on Register  button.

Step 6: Then you will get your your Client Secret Key
 https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965733/original/RNdOJvyAMHQRneo7-jKVm2hM6J40LtNyTw.png?1610523408

Step 7: Then go to Certificate and secret then click on New client id then you will get the secrete id

https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965735/original/JAY1m1KfzNvtEMuru_hu_Xvo-KcXFvrKJA.png?1610523408 

 

Step 8: Then open the link by replacing client ID: 
https://login.microsoftonline.com/common/oauth2/v2.0/authorize?client_id=b1feea46-d59c-4d65-bebe-4dabe2db766b&response_type=code&redirect_uri=https://app.empmonitor.com.in&scope=files.readwrite offline_access



https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965729/original/Owng4AxzJ9E5A42DAMmaYoHW-hY7g0n9JA.png?1610523407

 

 

Step 9: Then sign in again


https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965740/original/MXuPvURjy9yCeO6MOqmNknth8238Z6vXAA.png?1610523409

 

13. Click on Yes

 

https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965738/original/_PVq3Q4odFKxb7qIR2X6sHgvTFpsmRIglQ.png?1610523409

14. Then you will get the code and save it for further use.


https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965730/original/mtbam0wVkXjFdSFso6XyZJVyUxICbQYpMQ.png?1610523407

 

15.Open postman create a collection and create a get request

 1. For get method

===============>
 https://login.microsoftonline.com/common/oauth2/v2.0/authorize?client_id=$%7Bclient_id%7D&response_type=code&redirect_uri=https://app.empmonitor.com.in&scope=files.readwriteoffline_access
2.Then go to body x-www-form-urlencoded..Click on bulk edit and paste these parameters :-
------------------------>
client_id:${client_id}

response_type:code

redirect_uri:https://app.empmonitor.com.in

scope:files.readwrite,ofline_access


https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965734/original/7HeDt8AOC5-Xhd_gx9k12X3IPb09-xv8BQ.png?1610523408
 

16. For Post method

1. Use this link
https://login.microsoftonline.com/common/oauth2/v2.0/token
2.Then go to body x-www-form-urlencoded..Click on bulk edit and paste these parameters
     client_id:${client_id}

 client_secret:${the secure key }

    redirect_uri:https://app.empmonitor.com.in

   code:${code}

   grant_type:authorization_code


17.Edit the following data as shown

https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965736/original/v8UHLKJ_osjnpVYcv4C3OJAYws3Hq0tHOw.png?1610523408

18.Send the request.You will get a refresh token as shown
https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/42057965737/original/KFNOy1zWMjK7PSKaWUTOCl8ltcA5UrQjgg.png?1610523408

 

19. Again if you want to create refresh token .Create a post request.

POST: https://login.microsoftonline.com/common/oauth2/v2.0/token

 

— body x-www-form-urlencoded

 

client_id: ${client_id}

client_secret: ${the secure key }

redirect_uri: https://app.empmonitor.com.in

refresh_token: ${previous requested refresh token }

grant_type: refresh_token

 

19. Edit the above details in the parameters.

 20. Please fill in the client  id ,client secret id and refresh token in the storage in dashboard and activate the storage.

 

 

FYI :- After getting the code,you can directly go for the post method