@databrainhq/mcp-server 0.2.3 → 0.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +25 -15
- package/dist/index.js +624 -458
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -163,6 +163,16 @@ Each of your customers gets their own dashboard with row-level security.
|
|
|
163
163
|
|
|
164
164
|
> "Create per-client dashboard embeds for my SaaS app"
|
|
165
165
|
|
|
166
|
+
### Tweak widgets on a customer dashboard
|
|
167
|
+
|
|
168
|
+
Add, remove, or modify widgets (metrics) on a specific customer's embed without opening the Databrain UI. Clone from a template widget, write a fresh SQL spec, or generate one from a prompt.
|
|
169
|
+
|
|
170
|
+
> "Add the 'Calls per day' widget from the standard template to Acme's dashboard"
|
|
171
|
+
|
|
172
|
+
> "Generate a widget showing disqualification reasons for Acme and add it to their embed"
|
|
173
|
+
|
|
174
|
+
> "Remove the billing widget from Acme's dashboard but keep it for other customers"
|
|
175
|
+
|
|
166
176
|
### Enable self-serve analytics
|
|
167
177
|
|
|
168
178
|
Let end-users build their own metrics with drag-and-drop or AI-powered chat.
|
|
@@ -197,12 +207,8 @@ Prompts are guided workflows your AI assistant can follow. Ask for them by name
|
|
|
197
207
|
|--------|-------------|
|
|
198
208
|
| `embed-existing-dashboard` | Embed a dashboard you've already built in the Databrain UI |
|
|
199
209
|
| `embed-blank-dashboard` | Multi-tenant setup — each client gets their own dashboard |
|
|
200
|
-
| `
|
|
210
|
+
| `customize-customer-dashboard` | Add, modify, or remove widgets on a specific customer's embed — per-client scope |
|
|
201
211
|
| `brand-my-embed` | Customize colors, fonts, charts, card styling, responsive layout |
|
|
202
|
-
| `localize-embed` | Multi-language support, translations, calendar format |
|
|
203
|
-
| `secure-my-embed` | Permissions, access controls, role-based guest tokens |
|
|
204
|
-
| `setup-filters` | Dashboard filters — dropdowns, date ranges, server-side filters |
|
|
205
|
-
| `manage-embeds` | List, compare, and review existing embed configurations |
|
|
206
212
|
| `query-data` | Query your data with natural language, manage the semantic layer |
|
|
207
213
|
| `populate-semantic-layer` | Auto-generate table/column descriptions to enable natural language querying |
|
|
208
214
|
|
|
@@ -210,7 +216,7 @@ Prompts are guided workflows your AI assistant can follow. Ask for them by name
|
|
|
210
216
|
|
|
211
217
|
## Tools Reference
|
|
212
218
|
|
|
213
|
-
|
|
219
|
+
26 tools organized by category. Your AI assistant picks the right tools automatically — you don't need to call them directly.
|
|
214
220
|
|
|
215
221
|
> **Note:** Infrastructure creation (datasources, datamarts, workspaces) is done in the **Databrain UI**. However, the **semantic layer** is populated via MCP tools (`get_semantic_layer`, `update_semantic_layer`) — the AI auto-generates descriptions from column names.
|
|
216
222
|
|
|
@@ -239,26 +245,24 @@ Prompts are guided workflows your AI assistant can follow. Ask for them by name
|
|
|
239
245
|
</details>
|
|
240
246
|
|
|
241
247
|
<details>
|
|
242
|
-
<summary><b>Embeds</b> (
|
|
248
|
+
<summary><b>Embeds</b> (5) — Create, configure, and customize embedded dashboards</summary>
|
|
243
249
|
|
|
244
250
|
| Tool | Description |
|
|
245
251
|
|------|-------------|
|
|
246
252
|
| `create_embed` | Create an embed (standard or multi-tenant with `clientId`) |
|
|
247
253
|
| `list_embeds` | List embed configurations |
|
|
248
254
|
| `get_embed_details` | Get full embed details by ID |
|
|
249
|
-
| `update_embed` | Update embed config (
|
|
255
|
+
| `update_embed` | Update embed config — access settings, options, filters, i18n (via `body` passthrough) |
|
|
250
256
|
| `customize_embed_theme` | Presets, colors, fonts, cards, chart appearance, responsive layout |
|
|
251
|
-
| `configure_embed` | UI options, filters (string/date/number/SQL), i18n, translations |
|
|
252
|
-
| `diagnose_embed_health` | Diagnose malformed embeds + validate runtime readiness |
|
|
253
257
|
</details>
|
|
254
258
|
|
|
255
259
|
<details>
|
|
256
|
-
<summary><b>
|
|
260
|
+
<summary><b>Runtime Integration</b> (2) — Guest tokens and frontend code</summary>
|
|
257
261
|
|
|
258
262
|
| Tool | Description |
|
|
259
263
|
|------|-------------|
|
|
260
264
|
| `generate_guest_token` | Generate a frontend guest token (server-side) |
|
|
261
|
-
| `generate_embed_code` | Generate integration code (React, Next.js, Vue, Angular, Svelte, vanilla JS) |
|
|
265
|
+
| `generate_embed_code` | Generate integration code (React, Next.js, Vue, Angular, Svelte, SolidJS, vanilla JS) |
|
|
262
266
|
</details>
|
|
263
267
|
|
|
264
268
|
<details>
|
|
@@ -272,12 +276,18 @@ Prompts are guided workflows your AI assistant can follow. Ask for them by name
|
|
|
272
276
|
</details>
|
|
273
277
|
|
|
274
278
|
<details>
|
|
275
|
-
<summary><b>
|
|
279
|
+
<summary><b>Dashboards & Widgets</b> (6) — Discover dashboards and CRUD widgets on customer embeds</summary>
|
|
276
280
|
|
|
277
281
|
| Tool | Description |
|
|
278
282
|
|------|-------------|
|
|
279
283
|
| `list_dashboards` | List dashboards (by data app, workspace, or globally) |
|
|
280
|
-
| `
|
|
284
|
+
| `list_widgets` | List widgets on an embed for a specific client |
|
|
285
|
+
| `add_widget` | Add a widget — clone from a template (`templateMetricId`), supply a full spec, or pass a raw body from `generate_widget` |
|
|
286
|
+
| `update_widget` | Patch a widget's fields (name, query, chartOptions, isPublished, etc.) |
|
|
287
|
+
| `remove_widget` | Per-client soft delete — hides the widget for one client only |
|
|
288
|
+
| `generate_widget` | AI-generate a widget draft from a natural-language prompt. Returns a draft; pass to `add_widget` to persist |
|
|
289
|
+
|
|
290
|
+
Widget mutation tools mint a guest token internally for `(clientId, dataAppName)`. Provide `embedId` + `clientId` — the tools resolve the rest.
|
|
281
291
|
</details>
|
|
282
292
|
|
|
283
293
|
---
|
|
@@ -320,7 +330,7 @@ This usually means no workspace was selected. Ask the assistant: *"List my works
|
|
|
320
330
|
|
|
321
331
|
1. Check that the guest token is generated **server-side** (never expose API tokens in frontend code)
|
|
322
332
|
2. Verify the embed ID and dashboard ID match
|
|
323
|
-
3. Ask: *"
|
|
333
|
+
3. Ask: *"Check my embed configuration for issues"* — the assistant inspects via `get_embed_details`
|
|
324
334
|
|
|
325
335
|
### Theme changes not showing
|
|
326
336
|
|