Skip to content

Commit 8ba0baf

Browse files
committed
fix broken tool names
1 parent cf45994 commit 8ba0baf

File tree

3 files changed

+15
-15
lines changed

3 files changed

+15
-15
lines changed

examples/list_spaces.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ async function main() {
7373

7474
const response = (await client.callTool(
7575
{
76-
name: 'list_spaces',
76+
name: 'lightdash_list_spaces',
7777
arguments: {
7878
projectUuid,
7979
},

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "lightdash-mcp-server",
3-
"version": "0.0.9",
3+
"version": "0.0.10",
44
"description": "A MCP(Model Context Protocol) server that accesses to lightdash( https://www.lightdash.com/ )",
55
"main": "dist/index.js",
66
"type": "module",

src/index.ts

+13-13
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
124124
}
125125

126126
switch (request.params.name) {
127-
case 'list_projects': {
127+
case 'lightdash_list_projects': {
128128
const { data, error } = await lightdashClient.GET(
129129
'/api/v1/org/projects',
130130
{}
@@ -144,7 +144,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
144144
};
145145
}
146146

147-
case 'get_project': {
147+
case 'lightdash_get_project': {
148148
const args = GetProjectSchema.parse(request.params.arguments);
149149
const { data, error } = await lightdashClient.GET(
150150
'/api/v1/projects/{projectUuid}',
@@ -167,7 +167,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
167167
};
168168
}
169169

170-
case 'list_spaces': {
170+
case 'lightdash_list_spaces': {
171171
const args = ListSpacesSchema.parse(request.params.arguments);
172172
const { data, error } = await lightdashClient.GET(
173173
'/api/v1/projects/{projectUuid}/spaces',
@@ -190,7 +190,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
190190
};
191191
}
192192

193-
case 'list_charts': {
193+
case 'lightdash_list_charts': {
194194
const args = ListChartsSchema.parse(request.params.arguments);
195195
const { data, error } = await lightdashClient.GET(
196196
'/api/v1/projects/{projectUuid}/charts',
@@ -213,7 +213,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
213213
};
214214
}
215215

216-
case 'list_dashboards': {
216+
case 'lightdash_list_dashboards': {
217217
const args = ListDashboardsSchema.parse(request.params.arguments);
218218
const { data, error } = await lightdashClient.GET(
219219
'/api/v1/projects/{projectUuid}/dashboards',
@@ -236,7 +236,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
236236
};
237237
}
238238

239-
case 'get_custom_metrics': {
239+
case 'lightdash_get_custom_metrics': {
240240
const args = GetCustomMetricsSchema.parse(request.params.arguments);
241241
const { data, error } = await lightdashClient.GET(
242242
'/api/v1/projects/{projectUuid}/custom-metrics',
@@ -259,7 +259,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
259259
};
260260
}
261261

262-
case 'get_catalog': {
262+
case 'lightdash_get_catalog': {
263263
const args = GetCatalogSchema.parse(request.params.arguments);
264264
const { data, error } = await lightdashClient.GET(
265265
'/api/v1/projects/{projectUuid}/dataCatalog',
@@ -282,7 +282,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
282282
};
283283
}
284284

285-
case 'get_metrics_catalog': {
285+
case 'lightdash_get_metrics_catalog': {
286286
const args = GetMetricsCatalogSchema.parse(request.params.arguments);
287287
const { data, error } = await lightdashClient.GET(
288288
'/api/v1/projects/{projectUuid}/dataCatalog/metrics',
@@ -305,7 +305,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
305305
};
306306
}
307307

308-
case 'get_charts_as_code': {
308+
case 'lightdash_get_charts_as_code': {
309309
const args = GetChartsAsCodeSchema.parse(request.params.arguments);
310310
const { data, error } = await lightdashClient.GET(
311311
'/api/v1/projects/{projectUuid}/charts/code',
@@ -328,7 +328,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
328328
};
329329
}
330330

331-
case 'get_dashboards_as_code': {
331+
case 'lightdash_get_dashboards_as_code': {
332332
const args = GetDashboardsAsCodeSchema.parse(request.params.arguments);
333333
const { data, error } = await lightdashClient.GET(
334334
'/api/v1/projects/{projectUuid}/dashboards/code',
@@ -351,7 +351,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
351351
};
352352
}
353353

354-
case 'get_metadata': {
354+
case 'lightdash_get_metadata': {
355355
const args = GetMetadataSchema.parse(request.params.arguments);
356356
const { data, error } = await lightdashClient.GET(
357357
'/api/v1/projects/{projectUuid}/dataCatalog/{table}/metadata',
@@ -379,7 +379,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
379379
};
380380
}
381381

382-
case 'get_analytics': {
382+
case 'lightdash_get_analytics': {
383383
const args = GetAnalyticsSchema.parse(request.params.arguments);
384384
const { data, error } = await lightdashClient.GET(
385385
'/api/v1/projects/{projectUuid}/dataCatalog/{table}/analytics',
@@ -407,7 +407,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
407407
};
408408
}
409409

410-
case 'get_user_attributes': {
410+
case 'lightdash_get_user_attributes': {
411411
const { data, error } = await lightdashClient.GET(
412412
'/api/v1/org/attributes',
413413
{}

0 commit comments

Comments
 (0)