Hi @Yash Gupta
Make sure your scope
value is set to https://{tenant-name}.sharepoint.com/.default
.
Here is an example call:
Hope this helps.
If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.