Skip to main content

This package provides a command line interface to Azure Purview's REST API.

Project description

Azure Purview CLI

This package provides a command line interface to Azure Purview's REST API.

Pre-Requisites

  1. An Azure Purview account.
  2. A Service Principal (Azure AD application).
  3. Grant Service Principal role assignment (Azure Purview > Access Control (IAM) > Add role assignment > Purview Data Curator).

Installation

pip install purviewcli

Configuration

You will need the following to initialise the configuration file:

  • Client ID (aka Application ID)
  • Client Secret
  • Tenant ID (aka Directory ID)
  • Azure Purview Account Name
  • Output Path (e.g. Windows: C:/Users/username/Desktop Mac: /Users/username/Desktop)

To initiate the configuration, execute the following command.

purviewcli config

Usage

purviewcli command (mandatory parameters) [optional parameters]

Commands

config
getEntityAudit (--guid=<guid>) [--auditAction=<auditAction> --count=<count> --startKey=<startKey>]
getEntityBulk (--guid=<guid>...) [--ignoreRelationships --minExtInfo]
getEntityBulkHeaders [--tagUpdateStartTime=<tagUpdateStartTime>]
getEntityBulkUniqueAttributeType (--typeName=<typeName>) [--ignoreRelationships --minExtInfo]
getEntityBusinessmetadataImportTemplate
getEntityGuid (--guid=<guid>) [--ignoreRelationships --minExtInfo]
getEntityGuidClassification (--guid=<guid> --classificationName=<classificationName>)
getEntityGuidClassifications (--guid=<guid>)
getEntityGuidHeader (--guid=<guid>)
getEntityUniqueAttributeType (--typeName=<typeName> --attrKey=<attrKey> --attrVal=<attrVal>) [--ignoreRelationships --minExtInfo]
getEntityUniqueAttributeTypeHeader (--typeName=<typeName> --attrKey=<attrKey> --attrVal=<attrVal>)
getGlossary [--glossaryGuid=<glossaryGuid>] [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryCategories (--glossaryGuid=<glossaryGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryCategoriesHeaders (--glossaryGuid=<glossaryGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryCategory (--categoryGuid=<categoryGuid>)
getGlossaryCategoryRelated (--categoryGuid=<categoryGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryCategoryTerms (--categoryGuid=<categoryGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryDetailed (--glossaryGuid=<glossaryGuid>)
getGlossaryTerm (--termGuid=<termGuid>)
getGlossaryTerms (--glossaryGuid=<glossaryGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryTermsAssignedEntities (--termGuid=<termGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryTermsHeaders (--glossaryGuid=<glossaryGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getGlossaryTermsRelated (--termGuid=<termGuid>) [--limit=<limit> --offset=<offset> --sort=<sort>]
getLineage (--guid=<guid>) [--depth=<depth> --width=<width> --direction=<direction> --forceNewApi --includeParent --getDerivedLineage]
getLineageUniqueAttributeType (--typeName=<typeName>) [--depth=<depth> --direction=<direction>]
getRelationshipGuid (--guid=<guid>) [--extendedInfo]
getTypesBusinessmetadatadef (--guid=<guid> | --name=<name>)
getTypesClassificationdef (--guid=<guid> | --name=<name>)
getTypesEntitydef (--guid=<guid> | --name=<name>)
getTypesEnumdef (--guid=<guid> | --name=<name>)
getTypesRelationshipdef (--guid=<guid> | --name=<name>)
getTypesStructdef (--guid=<guid> | --name=<name>)
getTypesTypedef (--guid=<guid> | --name=<name>)
getTypesTypedefs
getTypesTypedefsHeaders

Options:

Option Description
-h --help Show this screen.
-v --version Show version.
--limit=<limit> Page size, by default there is no paging [default: -1].
--offset=<offset> Offset for pagination purpose [default: 0].
--sort=<sort> ASC or DESC [default: ASC].
--auditAction=<auditAction> BUSINESS_ATTRIBUTE_UPDATE or CLASSIFICATION_ADD or CLASSIFICATION_DELETE or C LASSIFICATION_UPDATE or ENTITY_CREATE or ENTITY_DELETE or ENTITY_IMPORT_CREATE or ENTITY_IMPORT_DELETE or ENTITY_IMPORT_UPDATE or ENTITY_PURGE or ENTITY_UPDATE or LABEL_ADD or LABEL_DELETE or PROPAGATED_CLASSIFICATION_ADD or PROPAGATED_CLASSIFICATION_DELETE or PROPAGATED_CLASSIFICATION_UPDATE or TERM_ADD or TERM_DELETE.
--count=<count> Number of events required [default: 100].
--startKey=<startKey> Used for pagination. Startkey is inclusive, the returned results contain the event with the given startkey.
--tagUpdateStartTime=<tagUpdateStartTime> DataType long.
--depth=<depth> Number of hops for lineage [default: 3].
--width=<width> Custom to Azure Purview [default: 6].
--direction=<direction> INPUT or OUTPUT or BOTH [default: BOTH].

Export to JSON

purviewcli json command (mandatory parameters) [optional parameters]

Export to CSV

purviewcli csv command (mandatory parameters) [optional parameters]

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

purviewcli-0.0.1.tar.gz (7.9 kB view hashes)

Uploaded Source

Built Distribution

purviewcli-0.0.1-py3-none-any.whl (10.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page