Add Data Quality Metrics via API?
Hi There,
I have configured a Data Quality Rule with the appropriate relationships to a Data Quality Metric and Data Quality Dimension, and target Data Asset.
In order to simulate an external DQ tool publishing metrics into Collibra, I’d like to add some metrics via the API.
It appears that the REST API only supports Data Quality Rule, and delving into the Java Core API:
/docs/javav2/com/collibra/dgc/core/api/dto/quality/DataQualityMetricRequest.Builder.html
however I’m a bit lost as to how to specify the target Data Asset (Column), the Data Quality Metric UUID, and the metric values (total rows, rows passing, etc.) for inserting metric data.
I’m assuming that this is possible given external DQ tooling would be using the API (e.g. Experian Aperture Data Studio uses the REST API).
Any thoughts appreciated.
Regards,
JPS
arthurburkhardt
The data quality metrics can be sent through the API just as any other asset/attribute.
So you can start by posting an asset of type " Data Quality Metric"
{ "name": "This is a quality metric", "domainId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "typeId": "00000000-0000-0000-0000-000000031107", "excludedFromAutoHyperlinking": true }Then you would retrieve the asset ID and post the attributes.
Or you can save yourself a LOOOT of time and just use the import API to ingest data quality metrics in batch.
https://developer.collibra.com/rest/import-api-documentation/
TL;DR: Use the import API to import data quality metrics like any other asset