Extracting the metadata from Purview in Json file using Purview CLI

Maria Diana 45 Reputation points
2023-10-26T10:57:49.98+00:00

I have successfully scanned few data sources in Purview UI. I would like to extract the metadata from purview in Json format so I can store the Json files in Jupyter 1.

So there are two things here, First one will be extracting the metadata from Purview. How can I do this. Is there any clear documentation somewhere? I have gone through some documentation and found that we can use purview cli to do it But I am not able access purview commands (pv commands) after installing purview cli through powershell. Powershell is not recognizing the pv commands (error “The term 'pv' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again”). 

Can you please help me to understand how can I extract the metadata using purview cli in json format so that it can be moved to Jupyter 1?

Microsoft Security | Microsoft Purview
{count} votes

Answer accepted by question author
  1. KranthiPakala-MSFT 46,737 Reputation points Microsoft Employee Moderator
    2023-10-30T21:10:18.26+00:00

    @Maria Diana Thanks for the additional details.

    All of the tayganr/purviewcli: Microsoft Purview CLI (github.com) are NOT powershell, it is its own shell command.

    Video: Could you please try Visual Studio Code instead of Powershell as demonstrated in this video: CLI wrapper to Microsoft Purview APIs (purviewcli)

    You should just call pv entity read --guid 'abc-123' and it will pull the content down in json.

    If you would like to explore Powershell cmdlet, it's a different pacakge: Azure/Azure-Purview-API-PowerShell (github.com)

    Hope this info helps. Let us know how it goes.

    Thank you


    Please don’t forget to Accept Answer and Yes for "was this answer helpful" wherever the information provided helps you, this can be beneficial to other community members.

    1 person found this answer helpful.
    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Ravineesh 80 Reputation points
    2023-11-09T13:57:35.6966667+00:00

    @Maria Diana , Have you tried running the command pv search query ? I think you can get the data for collection level by using pv search query

    Also have a look at this https://github.com/mdrakiburrahman/purview-collection-aggregator/blob/main/explore.ipynb it might be useful

    0 comments No comments

Your answer

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