How can i extract Sensitivity Labels Names from Azure Information Protection/Purview

Biju Mathew 481 Reputation points
2023-10-17T10:11:56.0466667+00:00

Hey, 

We have applied sensitivity labels on our PowerBI content like dataset, reports. 

When i use the PowerBI Scanner API, i see in the result json that the sensitivity label guids are returned(see below) - the corresponding names are not returned.

msprog_0-1697537212734.png

I need to get the sensitivity label guid to name mapping .

Is there any way to get this please?

thanks

Azure Information Protection
Azure Information Protection
An Azure service that is used to control and help secure email, documents, and sensitive data that are shared outside the company.
560 questions
Microsoft Security | Microsoft Purview
{count} votes

1 answer

Sort by: Most helpful
  1. Akshay-MSFT 17,956 Reputation points Microsoft Employee Moderator
    2023-10-17T11:00:25.53+00:00

    @Biju Mathew

    Thank you for posting your query on Microsoft Q&A, from above description I could understand that you are trying to get sensitivity label "Name" with ID in the output of when PowerBI Scanner API is called.

    Please do correct me if this is not the case by responding in the comments section.

    • The GetScan API would always return the labelID as info of sensitivity label as that is the only info captured in this parameter.

    User's image

    GET https://graph.microsoft.com/beta/users/******@contoso.com/security/informationProtection/sensitivityLabels
    
    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
      "@odata.context": "https://graph.microsoft.com/beta/$metadata#users('bob%40contoso.com')/security/informationProtection/sensitivityLabels",
      "value": [
        {
          "id": "0d39dc11-75ff-4309-8b32-ff94f0e41607",
          "name": "Any User (No Protection)",
          "description": "",
          "color": "",
          "sensitivity": 7,
          "tooltip": "The most sensitive information stored by Milt0rCorp; product plans, customer information, and other trade secrets. Data labeled for Any User will not be protected and should be used with caution and sparingly.",
          "isActive": true,
          "isAppliable": true,
          "contentFormats": [
            "file",
            "email",
            "schematizeddata"
          ],
          "hasProtection": false,
          "parent@odata.context": "https://graph.microsoft.com/beta/$metadata#users('bob%40constoso.com')/security/informationProtection/sensitivityLabels('0d39dc11-75ff-4309-8b32-ff94f0e41607')/parent/$entity",
          "parent": {
            "id": "566663c7-4d8d-4b8f-b280-784a31971dbe",
            "name": "Highly Confidential",
            "description": "",
            "color": "",
            "sensitivity": 7,
            "tooltip": "The most sensitive information at Milt0rCorp; product plans, customer information, data not shareable even under NDA.",
            "isActive": false,
            "isAppliable": false,
            "contentFormats": [
              "file",
              "email",
              "schematizeddata"
            ],
            "hasProtection": false,
            "parent@odata.context": "https://graph.microsoft.com/beta/$metadata#users('bob%40contoso.com')/security/informationProtection/sensitivityLabels('0d39dc11-75ff-4309-8b32-ff94f0e41607')/parent/parent/$entity",
            "parent": null
          }
        }
      ]
    }
    
    
    

    Thanks,

    Akshay Kaushik

    Please "Accept the answer" (Yes), and share your feedback if the suggestion answers you’re your query. This will help us and others in the community as well.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.