From the UI, you can export one type of artifact at a time from a single category. You can use the Watson Data API to export all governance artifacts of a type. The information is exported to a CSV file that is written to your default download
folder. The default file name is <category_name>-<artifact_type>-csv-export.csv
. You can modify this file outside of the catalog and later import it.
- Exporting artifacts from a category
- Exporting all governance artifacts of a type at once
- Exporting all governance artifacts to a ZIP file
- Security considerations
For information about exporting categories, see Importing or exporting categories.
Exporting governance artifacts from a category
You can export one type of governance artifact at a time from a category or from a category and its subcategories. Only artifacts with a primary relationship to the category or its subcategories are exported.
- Required permissions
- You must be a collaborator with at least Viewer role in a category to export it, or with a custom role with the permission to export an artifact type.
To export one type of governance artifact from a category:
-
Choose Governance > Categories.
-
Click a category name to open it.
-
Click Export.
-
Select the type of governance artifact to export.
You can export up to 400 governance artifacts per type.
-
Optional. Select to export artifacts from subcategories of the current category.
When you select to export subcategories, you also have the option to include the current category into the export. By default, the current category is not included. To export full category hierarchy (the category and all subcategories in the tree) mark both checkboxes. To export all root categories at once, see Importing or exporting categories.
-
Click Export.
A CSV file is downloaded to your computer. The export file has the same structure as an import file. See The format of an import CSV file. If you export the system default category [uncategorized], the exported CSV file does not contain a category name for the selected type of governance artifact.
Exporting all governance artifacts of a type at once
You can export up to 400 governance artifacts of a selected type by using the REST API. Submit a GET /v3/governance_artifact_types/{artifact_type}/export
request. Replace {artifact_type}
with the artifact type that
you want to export. To export artifacts of the selected type from all categories, leave the category_id
field empty. For details, see the API documentation.
- Required permissions
- You must be a collaborator with at least Viewer role on all categories, or with a custom role with the permission to export an artifact type.
Exporting all governance artifacts to a ZIP file
You can export all governance artifacts to a single ZIP file by using REST API. Use this kind of export to move all governance artifacts from one IBM Knowledge Catalog service instance to another. The ZIP file contains folders for each artifact type, and each folder contains a CSV file with artifacts. You can export all artifact types or only selected ones. The maximum number of governance artifacts that you can export is 400. This method also allows to export and import category collaborators with their category roles.
Submit a GET /v3/governance_artifact_types/export
request. In the artifact_id_mode
field, leave the default value always
, because the artifact ID values are required for import. For details, see the
API documentation.
- Required permissions
-
- You must have a Manager service role.
Security considerations
Governance data exported to CSV files is sanitized against known CSV Injection attacks, to be safe for those spreadsheet programs which automatically interpret CSV data. As a result, any text values which start with one of following characters:
- equals to (=)
- plus (+)
- minus (-)
- at (@)
are prefixed by a single quote character ('). To make the functionality consistent, imported CSV files are additionally parsed to automatically remove the single quote character ('). Sanitizing also applies when importing and exporting governance artifacts to ZIP files, as they contain CSV files.
To disable this functionality:
-
Edit IBM Knowledge Catalog Glossary Service deployment:
oc edit deployment wkc-glossary-service
-
Set the environment variable
ESCAPE_FORMULAS_IN_CSV_FILES
to valuefalse
.
For more information, see CSV Injection.
Learn more
Parent topic: Managing governance artifacts