@Vinod G I'm glad that you were able to resolve your issue and thank you for posting your solution so that others experiencing the same thing can easily reference this! Since the Microsoft Q&A community has a policy that "The question author cannot accept their own answer. They can only accept answers by others ", I'll repost your solution in case you'd like to "Accept " the answer.
Issue: I am using below microsoft learn page to query some data using rest api calls, I tried to fetch glossary list by clicking try it button. I have an azure purview resource created in my subscription with data sources and the glossary exist.
API I am trying - GET {endpoint}/datamap/api/atlas/v2/glossary
whenever I login using my Azure account to which I have below access but I am still getting response code 404
I do not want to use service prinicipal want to use an AD user.
I have bleow permission on Purview collection
Role-NHA-Dev-Purview-Collection-Admin , Role-NHA-Dev-Purview-Data-Source-Admin, Role-NHA-Dev-Purview-Data-Reader, Role-NHA-Dev-Purview-Data-Curator
Resolution: Resolved by @Vinod G
I found that somehow in MS learn site the request sent were not getting response so instead I wrote Azure powershell task in yaml pipeline and generated the token for my managed identity. The same token I have used in bruno for testing Purview API and what I found is that it worked..!!!!
The managed identity should have necessary permission to work.
- Purview-Collection-Admin
- Purview-Data-Source-Admin
- Purview-Data-Reader
- Purview-Data-Curator
If you have any other questions or are still running into more issues, please let me know. Thank you again for your time and patience throughout this issue.
Please remember to "Accept Answer" if any answer/reply helped, so that others in the community facing similar issues can easily find the solution.