Added
Semantic Model Sub-Resource Endpoints
about 2 months ago
Manage semantic model tables and relationships through dedicated CRUD endpoints. These sub-resources allow API consumers to build and modify semantic models programmatically — defining table structures, column metadata, and join relationships without editing raw YAML.
What's New
- Full CRUD operations for semantic model tables: define columns, dimensions, measures, facts, time dimensions, metrics, and filters
- Full CRUD operations for semantic model relationships: configure join columns, join types, and cardinality between tables
- Available via REST API, MCP server, and CLI (
bobsled create/get/list/update/delete)
New Endpoints
Tables
GET /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/tables— List tablesPOST /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/tables— Create tableGET /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/tables/{tableId}— Get tablePUT /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/tables/{tableId}— Update tableDELETE /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/tables/{tableId}— Delete table
Relationships
GET /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/relationships— List relationshipsPOST /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/relationships— Create relationshipGET /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/relationships/{relationshipId}— Get relationshipPUT /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/relationships/{relationshipId}— Update relationshipDELETE /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/relationships/{relationshipId}— Delete relationship
Example: Create a Table
POST /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/tables
{
"name": "orders",
"description": "Customer order records",
"base_table": {
"database": "ANALYTICS",
"schema": "SALES",
"table": "ORDERS"
},
"dimensions": [
{ "name": "order_status", "data_type": "VARCHAR", "description": "Current order status" }
],
"measures": [
{ "name": "total_revenue", "expr": "SUM(amount)", "description": "Total revenue" }
]
}Example: Create a Relationship
POST /api/v1/accounts/{accountId}/data-products/{dataProductId}/semantic-models/{semanticModelId}/relationships
{
"name": "orders_to_customers",
"leftTable": "orders",
"rightTable": "customers",
"joinColumns": [
{ "leftColumn": "customer_id", "rightColumn": "id" }
],
"joinType": "left",
"relationshipType": "many_to_one"
}Getting Started
Use the data-products API path for all operations. The CLI supports these as resource types: semantic-model-table and semantic-model-relationship. Run bobsled create semantic-model-table --help for usage details.