Data model representation example library

The Sigma programmatic data model API endpoints, including Create a data model from a code representation, Update a data model from a code representation, and Get the code representation of a data model require a specific format for the representation of the data model. This example library shows examples of data model representations for various configurations, using different element types and features in Sigma.

Consult these examples to:

  • Troubleshoot the formatting of a particular feature in a code representation
  • Relate a feature from the Sigma UI to its representation in code
  • Provide context to AI tools used to create data models from code

Example representations

To review a specific representation, search or browse the following examples:

FeatureLink
Data model with a single tableView example
Data model with a table and a calculated columnView example
Data model with a table and a metricView example
Data model with a metric timelineView example
Data model with a table and a relationshipView example
Data model with a custom SQL elementView example
💡

To see the representation for a specific configuration or combination of features, you can create the data model in the UI and then retrieve the representation using the Get the code representation of a data model endpoint.