Documentation Index Fetch the complete documentation index at: https://docs.tarvah.com/llms.txt
Use this file to discover all available pages before exploring further.
Single-shot dashboard creation. Accepts a declarative payload describing charts, data source, and layout — returns experiment and facade IDs.
This endpoint uses API key authentication . Pass your key via Authorization: Bearer trvh_sdk_... or x-api-key header.
Request Body
Dashboard name displayed in the UI.
Optional description for the dashboard.
The data source to query against. Show dataSource properties
Database connection ID (e.g., D2026A00002).
Virtual Data Mart ID. When provided, field names are validated against VDM columns.
Connection type. Use "VDM" for Virtual Data Mart sources.
Database schema name (e.g., "public").
Array of chart definitions. Use this for simple mode (single section). Display title of the chart.
Chart type — friendly name (e.g., column, pie, line, kpi) or CH code (e.g., CH00003). See Get Chart Types for all options. Array of measure definitions. Column name in the data source.
Aggregation function: sum, count, average / avg, min, max, distinct, as-is.
Shorthand: pass a string instead of an object to use the default aggregation (e.g., "revenue" is equivalent to {"field": "revenue", "aggregation": "sum"}). Using calculations: To reference a pre-computed calculation (percentage of total, weighted average, etc.) from the VDM, use "aggregation": "as-is" with the calculation’s label as the field. See Calculations for details.Array of dimension field names (strings) or dimension objects. Column name for grouping.
Whether this dimension is a date type.
Shorthand: pass a string instead of an object (e.g., "region"). Array of filter conditions applied to this chart.
Max number of rows to return. Defaults to 100 if not using filter.
Sort configuration. Each item: { "field": "columnName", "direction": "asc" | "desc" }.
Chart position and size within the experiment grid. If omitted, auto-generated (KPIs: width: 3 side-by-side, others: width: 12 stacked vertically). Grid column span (1–12). Default: 12 (full width), 3 for KPI cards.
Grid row span. Default: 13, 6 for KPI cards.
Column offset (0-based). Default: 0.
Row offset (0-based). Default: auto-calculated.
Chart visual settings. If omitted, sensible defaults are applied. Show data values on the chart.
Show horizontal scrollbar.
Title of another chart in the same section to use as a drill-down source. Clicking the source chart filters this chart. Resolved to internal chart IDs during import.
KPI metric card styling. Only applicable for kpi / kpi-card chart types. Icon component name (e.g., "BsCurrencyDollar", "ImCart").
Primary icon/value color (hex, e.g., "#237e11").
Trend-up color (hex, e.g., "#41d723").
Trend sparkline configuration for the KPI card. Measure field to trend (e.g., "Market Value").
Date dimension for the trend x-axis (e.g., "Position Date").
Trend grouping interval: "Day", "Week", "Month", "Quarter", "Year".
format
string
default: "percentage"
Trend display format: "percentage" (delta %), "absolute" (delta value), or "value".
Bubble chart configuration. Only applicable for bubble chart type. Field that controls bubble size.
X-axis field. Pass a string for the field name, or an object {"field": "...", "type": "dimension" | "measure"}.
Y-axis field. Same format as xAxis.
Field that controls bubble color intensity.
Two-element array of hex colors for the min/max color gradient (e.g., ["#98c1e7", "#1169bb"]).
Array of section definitions. Use this for multi-section mode (multiple experiments, category tabs). Section name — appears as the category tab label.
Same chart array format as the top-level charts field.
If true, this section’s charts render in the always-visible top section (ideal for KPI cards).
If true, this section appears as a navigable category tab.
Layout configuration for the dashboard grid. Number of columns in the grid.
Height for KPI cards in the top section.
Layout template type (e.g., "realEstate"). Used to resolve a layout template from the database.
Exact name of a layout template. Takes priority over templateType.
Dashboard categories (e.g., ["BI", "Sales"]).
Tags for the dashboard. "sdk-import" is always added automatically.
Whether the dashboard is publicly visible.
Response
Whether the import succeeded.
The created facade ID (e.g., F2026A00018). Use this to view the dashboard in the UI.
Array of created experiments. Experiment ID (e.g., E2026A00042).
Section name this experiment belongs to.
Charts created within this experiment. Chart identifier (e.g., chart_1).
Resolved chart type code (e.g., CH00003).
Simple Mode
Sections with Layout & Interactions
curl -X POST https:// < your-instanc e > /v1/sdk/import \
-H "Authorization: Bearer trvh_sdk_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"name": "Revenue Dashboard",
"dataSource": {
"dbId": "D2026A00002",
"vdmId": "VDM2026A00001",
"connType": "VDM"
},
"charts": [
{
"title": "Revenue by Region",
"type": "column",
"measures": [{"field": "revenue", "aggregation": "sum"}],
"dimensions": ["region"]
}
],
"category": ["Sales"],
"tags": ["quarterly"]
}'
201 Created
400 Bad Request
401 Unauthorized
{
"success" : true ,
"facadeId" : "F2026A00018" ,
"experiments" : [
{
"experimentId" : "E2026A00042" ,
"section" : "Revenue Dashboard" ,
"charts" : [
{
"chartId" : "chart_1" ,
"chartType" : "CH00003" ,
"chartTitle" : "Revenue by Region"
}
]
}
]
}