mirror of
https://github.com/datahub-project/datahub.git
synced 2025-11-12 01:11:41 +00:00
13 lines
348 B
Python
13 lines
348 B
Python
from datahub.metadata.urns import GlossaryTermUrn
|
|
from datahub.sdk import ChartUrn, DataHubClient
|
|
|
|
client = DataHubClient.from_env()
|
|
|
|
chart = client.entities.get(ChartUrn("looker", "sales_dashboard"))
|
|
|
|
chart.add_term(GlossaryTermUrn("Revenue"))
|
|
|
|
client.entities.update(chart)
|
|
|
|
print(f"Added term {GlossaryTermUrn('Revenue')} to chart {chart.urn}")
|