API¶
This part of the documentation covers all the interfaces of Mara Superset. For parts where the package depends on external libraries, we document the most important right here and provide links to the canonical documentation.
Metadata Synchronization¶
- mara_superset.metadata.update_metadata(update_strategy: Optional[mara_superset.metadata.UpdateStrategy] = None) bool ¶
Updates descriptions of tables & fields in Superset, creates metrics and flushes field caches
- Args:
update_strategy: How the metadata should be updated. If not defined the value from config.metadata_update_strategy().
- mara_superset.metadata.superset_description(entity: Union[mara_schema.entity.Entity, mara_schema.metric.SimpleMetric, mara_schema.metric.ComposedMetric, mara_schema.attribute.Attribute])¶
Returns the description of the item
- mara_superset.metadata.superset_metric_expression(metric: Union[mara_schema.metric.SimpleMetric, mara_schema.metric.ComposedMetric])¶
Turn a Mara Schema metric into a a sql formula
- mara_superset.metadata.superset_metric_d3format(metric: Union[mara_schema.metric.SimpleMetric, mara_schema.metric.ComposedMetric]) str ¶
Turns the metric number format into a D3 format.
Superset API Client¶
- class mara_superset.client.SupersetClient¶
A client class for interacting with the Superset API
See also: https://superset.apache.org/docs/api