@cyanheads/eurostat-mcp-server 0.1.16 → 0.3.0
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/CLAUDE.md +1 -1
- package/README.md +9 -7
- package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.d.ts +7 -7
- package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.d.ts.map +1 -1
- package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.js +23 -7
- package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.js.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-browse-themes.tool.d.ts +1 -0
- package/dist/mcp-server/tools/definitions/eurostat-browse-themes.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-browse-themes.tool.js +9 -0
- package/dist/mcp-server/tools/definitions/eurostat-browse-themes.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.d.ts +9 -9
- package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.js +41 -19
- package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.d.ts +5 -0
- package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.js +14 -1
- package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.d.ts +2 -2
- package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.js +31 -17
- package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.js.map +1 -1
- package/dist/services/eurostat-catalogue/eurostat-catalogue-service.d.ts +20 -1
- package/dist/services/eurostat-catalogue/eurostat-catalogue-service.d.ts.map +1 -1
- package/dist/services/eurostat-catalogue/eurostat-catalogue-service.js +35 -3
- package/dist/services/eurostat-catalogue/eurostat-catalogue-service.js.map +1 -1
- package/dist/services/eurostat-data/eurostat-data-service.d.ts +50 -2
- package/dist/services/eurostat-data/eurostat-data-service.d.ts.map +1 -1
- package/dist/services/eurostat-data/eurostat-data-service.js +160 -43
- package/dist/services/eurostat-data/eurostat-data-service.js.map +1 -1
- package/dist/services/eurostat-data/types.d.ts +51 -11
- package/dist/services/eurostat-data/types.d.ts.map +1 -1
- package/dist/services/eurostat-data/types.js +7 -0
- package/dist/services/eurostat-data/types.js.map +1 -1
- package/package.json +1 -1
- package/server.json +3 -3
package/CLAUDE.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Agent Protocol
|
|
2
2
|
|
|
3
3
|
**Server:** @cyanheads/eurostat-mcp-server
|
|
4
|
-
**Version:** 0.
|
|
4
|
+
**Version:** 0.3.0
|
|
5
5
|
**Framework:** [@cyanheads/mcp-ts-core](https://www.npmjs.com/package/@cyanheads/mcp-ts-core) `^0.11.1`
|
|
6
6
|
**Engines:** Bun ≥1.3.0, Node ≥24.0.0
|
|
7
7
|
**Zod:** `^4.4.3`
|
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
[](./CHANGELOG.md) [](./LICENSE) [](https://github.com/users/cyanheads/packages/container/package/eurostat-mcp-server) [](https://modelcontextprotocol.io/) [](https://www.npmjs.com/package/@cyanheads/eurostat-mcp-server) [](https://www.typescriptlang.org/) [](https://bun.sh/)
|
|
13
13
|
|
|
14
14
|
</div>
|
|
15
15
|
|
|
@@ -63,6 +63,7 @@ Navigate the Eurostat theme tree.
|
|
|
63
63
|
- With `theme_code`: returns immediate children — subtheme folders and datasets in that branch
|
|
64
64
|
- Each entry includes code, label, type (folder/dataset/table), data period, and observation count where available
|
|
65
65
|
- Returns a breadcrumb path from root to the current node, plus a `nextStep` hint suited to the level (drill into folders or inspect a dataset)
|
|
66
|
+
- One branch per folder code — Eurostat files a few folder codes under several branches; a code resolves to the first one the catalogue lists, which never has fewer children than the branches it shadows, and `otherPlacements` names those so the ambiguity is visible
|
|
66
67
|
- Use for structured discovery when you know the domain but not the exact dataset code
|
|
67
68
|
|
|
68
69
|
---
|
|
@@ -72,8 +73,8 @@ Navigate the Eurostat theme tree.
|
|
|
72
73
|
Fetch metadata for a Eurostat dataset before querying it.
|
|
73
74
|
|
|
74
75
|
- Returns all dimensions with their codes, labels, and up to 10 sample values each
|
|
75
|
-
- Reports overall time range and total observation count across all periods
|
|
76
|
-
- Uses a minimal Statistics API call (most recent period only)
|
|
76
|
+
- Reports overall time range and total observation count across all periods, each omitted when Eurostat does not report it
|
|
77
|
+
- Uses a minimal Statistics API call (most recent period only), plus one bounded follow-up to count the dataset's periods when it has a `time` dimension. If that follow-up fails, the call still returns everything the first request produced, with the `time` dimension's value count omitted rather than reported as 1
|
|
77
78
|
- For dimensions with more than 10 values, use `eurostat_get_dimension_values` for the full list
|
|
78
79
|
- Provides a link to the ESMS metadata page when available
|
|
79
80
|
|
|
@@ -84,7 +85,7 @@ Fetch metadata for a Eurostat dataset before querying it.
|
|
|
84
85
|
List all valid values for a specific dataset dimension.
|
|
85
86
|
|
|
86
87
|
- Retrieves the complete set of valid codes and labels for any dimension (unit, na_item, geo, etc.)
|
|
87
|
-
- For the `geo` dimension, supports NUTS hierarchy filtering: `aggregate` (EU/EA totals), `country` (41 states), `nuts1` (127 major regions), `nuts2` (309 basic regions), `nuts3` (1,343 small regions)
|
|
88
|
+
- For the `geo` dimension, supports NUTS hierarchy filtering: `aggregate` (EU/EA totals), `country` (41 states), `nuts1` (127 major regions), `nuts2` (309 basic regions), `nuts3` (1,343 small regions). Pairing it with any other dimension is rejected rather than ignored
|
|
88
89
|
- Prevents silent no-data returns — invalid dimension values in `eurostat_query_dataset` return nothing without error; verify codes here first
|
|
89
90
|
|
|
90
91
|
---
|
|
@@ -94,11 +95,12 @@ List all valid values for a specific dataset dimension.
|
|
|
94
95
|
Fetch statistical data from a Eurostat dataset.
|
|
95
96
|
|
|
96
97
|
- Accepts dimension filters as a map of `{dimension_code: [value1, value2, ...]}`
|
|
97
|
-
- NUTS geo-level filter (`aggregate`, `country`, `nuts1`, `nuts2`, `nuts3`) — mutually exclusive with a `geo`
|
|
98
|
+
- NUTS geo-level filter (`aggregate`, `country`, `nuts1`, `nuts2`, `nuts3`) — mutually exclusive with a non-empty `geo` entry in filters; an empty array is treated as no filter and dropped
|
|
98
99
|
- Time range via `since_period`/`until_period` (e.g., `"2020"`, `"2023-Q1"`) or `last_n_periods` for the N most recent
|
|
99
100
|
- Returns decoded observations with dimension codes and labels, numeric values, and status flags (`p` = provisional, `e` = estimated, etc.)
|
|
100
|
-
- Reports total observation count, missing value count, and effective time range of the result
|
|
101
|
-
-
|
|
101
|
+
- Reports total observation count, missing value count, and the effective time range of the result, each period bound omitted when neither the observations nor Eurostat report it
|
|
102
|
+
- Returned rows are capped at 5,000, applied while decoding so a broad query never builds the rest; `obsCount`, `missingObsCount` and `timeRange` still describe the whole match, and `truncated` flags when rows were dropped. Filter the query to shrink what Eurostat sends — the cap bounds the decode, not the transfer
|
|
103
|
+
- Async-response detection — large unfiltered queries return an actionable, non-retryable error with filter guidance rather than silently timing out
|
|
102
104
|
|
|
103
105
|
## Resource
|
|
104
106
|
|
|
@@ -11,18 +11,18 @@ export declare const eurostatDatasetResource: import("@cyanheads/mcp-ts-core").R
|
|
|
11
11
|
dimensions: z.ZodArray<z.ZodObject<{
|
|
12
12
|
code: z.ZodString;
|
|
13
13
|
label: z.ZodString;
|
|
14
|
-
valuesCount: z.ZodNumber
|
|
15
|
-
sampleValues: z.ZodArray<z.ZodObject<{
|
|
14
|
+
valuesCount: z.ZodOptional<z.ZodNumber>;
|
|
15
|
+
sampleValues: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
16
16
|
code: z.ZodString;
|
|
17
17
|
label: z.ZodString;
|
|
18
|
-
}, z.core.$strip
|
|
18
|
+
}, z.core.$strip>>>;
|
|
19
19
|
}, z.core.$strip>>;
|
|
20
20
|
timeRange: z.ZodObject<{
|
|
21
|
-
start: z.ZodString
|
|
22
|
-
end: z.ZodString
|
|
21
|
+
start: z.ZodOptional<z.ZodString>;
|
|
22
|
+
end: z.ZodOptional<z.ZodString>;
|
|
23
23
|
}, z.core.$strip>;
|
|
24
|
-
obsCount: z.ZodNumber
|
|
25
|
-
lastUpdated: z.ZodString
|
|
24
|
+
obsCount: z.ZodOptional<z.ZodNumber>;
|
|
25
|
+
lastUpdated: z.ZodOptional<z.ZodString>;
|
|
26
26
|
metadataUrl: z.ZodOptional<z.ZodString>;
|
|
27
27
|
}, z.core.$strip>, undefined>;
|
|
28
28
|
//# sourceMappingURL=eurostat-dataset.resource.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-dataset.resource.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/eurostat-dataset.resource.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAY,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAGrD,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"eurostat-dataset.resource.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/eurostat-dataset.resource.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAY,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAGrD,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;6BAyElC,CAAC"}
|
|
@@ -19,7 +19,10 @@ export const eurostatDatasetResource = resource('eurostat://dataset/{dataset_cod
|
|
|
19
19
|
.object({
|
|
20
20
|
code: z.string().describe('Dimension code.'),
|
|
21
21
|
label: z.string().describe('Dimension name.'),
|
|
22
|
-
valuesCount: z
|
|
22
|
+
valuesCount: z
|
|
23
|
+
.number()
|
|
24
|
+
.optional()
|
|
25
|
+
.describe('Number of distinct values — the dataset\'s full period count for "time", the most recent period\'s codelist otherwise. Omitted when the value set could not be measured — only "time" can be, and an omitted count is unknown, not one.'),
|
|
23
26
|
sampleValues: z
|
|
24
27
|
.array(z
|
|
25
28
|
.object({
|
|
@@ -27,18 +30,31 @@ export const eurostatDatasetResource = resource('eurostat://dataset/{dataset_cod
|
|
|
27
30
|
label: z.string().describe('Value label.'),
|
|
28
31
|
})
|
|
29
32
|
.describe('A dimension value code and label pair.'))
|
|
30
|
-
.
|
|
33
|
+
.optional()
|
|
34
|
+
.describe('First 10 values for orientation. Omitted alongside valuesCount when the value set could not be measured.'),
|
|
31
35
|
})
|
|
32
36
|
.describe('A dataset dimension with its valid values.'))
|
|
33
37
|
.describe('Dataset dimensions.'),
|
|
34
38
|
timeRange: z
|
|
35
39
|
.object({
|
|
36
|
-
start: z
|
|
37
|
-
|
|
40
|
+
start: z
|
|
41
|
+
.string()
|
|
42
|
+
.optional()
|
|
43
|
+
.describe('Earliest available period. Omitted when Eurostat does not report it.'),
|
|
44
|
+
end: z
|
|
45
|
+
.string()
|
|
46
|
+
.optional()
|
|
47
|
+
.describe('Most recent available period. Omitted when Eurostat does not report it.'),
|
|
38
48
|
})
|
|
39
|
-
.describe('Overall data coverage period.'),
|
|
40
|
-
obsCount: z
|
|
41
|
-
|
|
49
|
+
.describe('Overall data coverage period. Each bound is omitted when Eurostat does not report it — an omitted bound is unknown, not empty.'),
|
|
50
|
+
obsCount: z
|
|
51
|
+
.number()
|
|
52
|
+
.optional()
|
|
53
|
+
.describe('Total number of observations. Omitted when Eurostat does not report it — an omitted count is unknown, not zero.'),
|
|
54
|
+
lastUpdated: z
|
|
55
|
+
.string()
|
|
56
|
+
.optional()
|
|
57
|
+
.describe('ISO 8601 timestamp of last data update. Omitted when Eurostat does not report it.'),
|
|
42
58
|
metadataUrl: z.string().optional().describe('Link to ESMS metadata page, when available.'),
|
|
43
59
|
}),
|
|
44
60
|
handler(params, ctx) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-dataset.resource.js","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/eurostat-dataset.resource.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,QAAQ,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,mDAAmD,CAAC;AAE3F,MAAM,CAAC,MAAM,uBAAuB,GAAG,QAAQ,CAAC,mCAAmC,EAAE;IACnF,IAAI,EAAE,uBAAuB;IAC7B,WAAW,EACT,oNAAoN;IACtN,QAAQ,EAAE,kBAAkB;IAC5B,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,qCAAqC,CAAC;KACzE,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,eAAe,CAAC;QAC1C,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,+BAA+B,CAAC;QAC3D,UAAU,EAAE,CAAC;aACV,KAAK,CACJ,CAAC;aACE,MAAM,CAAC;YACN,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iBAAiB,CAAC;YAC5C,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iBAAiB,CAAC;YAC7C,WAAW,EAAE,CAAC,
|
|
1
|
+
{"version":3,"file":"eurostat-dataset.resource.js","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/eurostat-dataset.resource.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,QAAQ,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAC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AC;QAClC,SAAS,EAAE,CAAC;aACT,MAAM,CAAC;YACN,KAAK,EAAE,CAAC;iBACL,MAAM,EAAE;iBACR,QAAQ,EAAE;iBACV,QAAQ,CAAC,sEAAsE,CAAC;YACnF,GAAG,EAAE,CAAC;iBACH,MAAM,EAAE;iBACR,QAAQ,EAAE;iBACV,QAAQ,CAAC,yEAAyE,CAAC;SACvF,CAAC;aACD,QAAQ,CACP,gIAAgI,CACjI;QACH,QAAQ,EAAE,CAAC;aACR,MAAM,EAAE;aACR,QAAQ,EAAE;aACV,QAAQ,CACP,iHAAiH,CAClH;QACH,WAAW,EAAE,CAAC;aACX,MAAM,EAAE;aACR,QAAQ,EAAE;aACV,QAAQ,CACP,mFAAmF,CACpF;QACH,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6CAA6C,CAAC;KAC3F,CAAC;IAEF,OAAO,CAAC,MAAM,EAAE,GAAG;QACjB,MAAM,GAAG,GAAG,sBAAsB,EAAE,CAAC;QACrC,OAAO,GAAG,CAAC,cAAc,CAAC,MAAM,CAAC,YAAY,EAAE,GAAG,CAAC,CAAC;IACtD,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -21,6 +21,7 @@ export declare const eurostatBrowseThemes: import("@cyanheads/mcp-ts-core").Tool
|
|
|
21
21
|
obsCount: z.ZodOptional<z.ZodNumber>;
|
|
22
22
|
}, z.core.$strip>>;
|
|
23
23
|
parentPath: z.ZodArray<z.ZodString>;
|
|
24
|
+
otherPlacements: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodString>>>;
|
|
24
25
|
nextStep: z.ZodOptional<z.ZodString>;
|
|
25
26
|
}, z.core.$strip>, readonly [{
|
|
26
27
|
readonly reason: "not_found";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-browse-themes.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-browse-themes.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAGhF,eAAO,MAAM,oBAAoB
|
|
1
|
+
{"version":3,"file":"eurostat-browse-themes.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-browse-themes.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAGhF,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkJ/B,CAAC"}
|
|
@@ -47,6 +47,12 @@ export const eurostatBrowseThemes = tool('eurostat_browse_themes', {
|
|
|
47
47
|
parentPath: z
|
|
48
48
|
.array(z.string())
|
|
49
49
|
.describe('Breadcrumb from root to the requested theme (e.g., ["Database by themes", "Economy and finance"]). Empty when browsing root.'),
|
|
50
|
+
otherPlacements: z
|
|
51
|
+
.array(z
|
|
52
|
+
.array(z.string())
|
|
53
|
+
.describe('Breadcrumb from root to one other folder carrying the requested code.'))
|
|
54
|
+
.optional()
|
|
55
|
+
.describe('Breadcrumbs of the other branches that file this same theme_code. Eurostat lists a few folder codes in more than one branch; the items above come from the first one the catalogue lists, which never has fewer children than the branches named here but can list different ones. theme_code takes a bare code, so those branches cannot be addressed directly — browse down to them from the root instead. Omitted when the code has a single placement — the normal case.'),
|
|
50
56
|
nextStep: z
|
|
51
57
|
.string()
|
|
52
58
|
.optional()
|
|
@@ -106,6 +112,9 @@ export const eurostatBrowseThemes = tool('eurostat_browse_themes', {
|
|
|
106
112
|
if (item.obsCount != null)
|
|
107
113
|
lines.push(` **Observations:** ${item.obsCount.toLocaleString()}`);
|
|
108
114
|
}
|
|
115
|
+
if (result.otherPlacements && result.otherPlacements.length > 0) {
|
|
116
|
+
lines.push(`\n**Also filed under:** this code appears in ${result.otherPlacements.length} other branch${result.otherPlacements.length !== 1 ? 'es' : ''} — ${result.otherPlacements.map((p) => p.join(' › ')).join('; ')}. The items above are from the branch listed first in the catalogue.`);
|
|
117
|
+
}
|
|
109
118
|
if (result.nextStep)
|
|
110
119
|
lines.push(`\n**Next step:** ${result.nextStep}`);
|
|
111
120
|
return [{ type: 'text', text: lines.join('\n') }];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-browse-themes.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-browse-themes.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAChF,OAAO,EAAE,2BAA2B,EAAE,MAAM,6DAA6D,CAAC;AAE1G,MAAM,CAAC,MAAM,oBAAoB,GAAG,IAAI,CAAC,wBAAwB,EAAE;IACjE,KAAK,EAAE,iCAAiC;IACxC,WAAW,EACT,kdAAkd;IACpd,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IAC9E,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC;QACd,UAAU,EAAE,CAAC;aACV,MAAM,EAAE;aACR,QAAQ,EAAE;aACV,QAAQ,CACP,2FAA2F,CAC5F;KACJ,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,KAAK,EAAE,CAAC;aACL,KAAK,CACJ,CAAC;aACE,MAAM,CAAC;YACN,IAAI,EAAE,CAAC;iBACJ,MAAM,EAAE;iBACR,QAAQ,CACP,0GAA0G,CAC3G;YACH,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sBAAsB,CAAC;YAClD,IAAI,EAAE,CAAC;iBACJ,IAAI,CA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AE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
|
|
1
|
+
{"version":3,"file":"eurostat-browse-themes.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-browse-themes.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAChF,OAAO,EAAE,2BAA2B,EAAE,MAAM,6DAA6D,CAAC;AAE1G,MAAM,CAAC,MAAM,oBAAoB,GAAG,IAAI,CAAC,wBAAwB,EAAE;IACjE,KAAK,EAAE,iCAAiC;IACxC,WAAW,EACT,kdAAkd;IACpd,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IAC9E,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC;QACd,UAAU,EAAE,CAAC;aACV,MAAM,EAAE;aACR,QAAQ,EAAE;aACV,QAAQ,CACP,2FAA2F,CAC5F;KACJ,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,KAAK,EAAE,CAAC;aACL,KAAK,CACJ,CAAC;aACE,MAAM,CAAC;YACN,IAAI,EAAE,CAAC;iBACJ,MAAM,EAAE;iBACR,QAAQ,CACP,0GAA0G,CAC3G;YACH,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sBAAsB,CAAC;YAClD,IAAI,EAAE,CAAC;iBACJ,IAAI,CAAC,CAAC,QAAQ,EAAE,SAAS,EAAE,OAAO,CAAC,CAAC;iBACpC,QAAQ,CACP,+EAA+E,CAChF;YACH,WAAW,EAAE,CAAC;iBACX,OAAO,EAAE;iBACT,QAAQ,CACP,8EAA8E,CAC/E;YACH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AAgD,MAAM,CAAC,eAAe,CAAC,MAAM,gBAAgB,MAAM,CAAC,eAAe,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,MAAM,MAAM,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,sEAAsE,CACpR,CAAC;QACJ,CAAC;QACD,IAAI,MAAM,CAAC,QAAQ;YAAE,KAAK,CAAC,IAAI,CAAC,oBAAoB,MAAM,CAAC,QAAQ,EAAE,CAAC,CAAC;QACvE,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -12,18 +12,18 @@ export declare const eurostatGetDatasetInfo: import("@cyanheads/mcp-ts-core").To
|
|
|
12
12
|
dimensions: z.ZodArray<z.ZodObject<{
|
|
13
13
|
code: z.ZodString;
|
|
14
14
|
label: z.ZodString;
|
|
15
|
-
valuesCount: z.ZodNumber
|
|
16
|
-
sampleValues: z.ZodArray<z.ZodObject<{
|
|
15
|
+
valuesCount: z.ZodOptional<z.ZodNumber>;
|
|
16
|
+
sampleValues: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
17
17
|
code: z.ZodString;
|
|
18
18
|
label: z.ZodString;
|
|
19
|
-
}, z.core.$strip
|
|
19
|
+
}, z.core.$strip>>>;
|
|
20
20
|
}, z.core.$strip>>;
|
|
21
21
|
timeRange: z.ZodObject<{
|
|
22
|
-
start: z.ZodString
|
|
23
|
-
end: z.ZodString
|
|
22
|
+
start: z.ZodOptional<z.ZodString>;
|
|
23
|
+
end: z.ZodOptional<z.ZodString>;
|
|
24
24
|
}, z.core.$strip>;
|
|
25
|
-
obsCount: z.ZodNumber
|
|
26
|
-
lastUpdated: z.ZodString
|
|
25
|
+
obsCount: z.ZodOptional<z.ZodNumber>;
|
|
26
|
+
lastUpdated: z.ZodOptional<z.ZodString>;
|
|
27
27
|
metadataUrl: z.ZodOptional<z.ZodString>;
|
|
28
28
|
}, z.core.$strip>, readonly [{
|
|
29
29
|
readonly reason: "not_found";
|
|
@@ -34,7 +34,7 @@ export declare const eurostatGetDatasetInfo: import("@cyanheads/mcp-ts-core").To
|
|
|
34
34
|
readonly reason: "async_response";
|
|
35
35
|
readonly code: JsonRpcErrorCode.ServiceUnavailable;
|
|
36
36
|
readonly when: "Eurostat returned an async response (query too large for the API).";
|
|
37
|
-
readonly retryable:
|
|
38
|
-
readonly recovery: "
|
|
37
|
+
readonly retryable: false;
|
|
38
|
+
readonly recovery: "The same call cannot succeed — this tool has no filters to narrow. Use eurostat_search_datasets or eurostat_browse_themes for catalogue-level coverage, or eurostat_get_dimension_values for one dimension at a time.";
|
|
39
39
|
}], undefined>;
|
|
40
40
|
//# sourceMappingURL=eurostat-get-dataset-info.tool.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-get-dataset-info.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAGhF,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"eurostat-get-dataset-info.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAGhF,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAyKjC,CAAC"}
|
|
@@ -27,7 +27,8 @@ export const eurostatGetDatasetInfo = tool('eurostat_get_dataset_info', {
|
|
|
27
27
|
label: z.string().describe('Human-readable dimension name (e.g., "Unit of measure").'),
|
|
28
28
|
valuesCount: z
|
|
29
29
|
.number()
|
|
30
|
-
.
|
|
30
|
+
.optional()
|
|
31
|
+
.describe('Number of distinct values in this dimension. For "time" this is the dataset\'s full period count; every other dimension is counted from the most recent period. Omitted when the value set could not be measured — only "time" can be, and an omitted count is unknown, not one. Call eurostat_get_dimension_values for that dimension to obtain it.'),
|
|
31
32
|
sampleValues: z
|
|
32
33
|
.array(z
|
|
33
34
|
.object({
|
|
@@ -35,20 +36,31 @@ export const eurostatGetDatasetInfo = tool('eurostat_get_dataset_info', {
|
|
|
35
36
|
label: z.string().describe('Human-readable label for this value.'),
|
|
36
37
|
})
|
|
37
38
|
.describe('A dimension value code and label pair.'))
|
|
38
|
-
.
|
|
39
|
+
.optional()
|
|
40
|
+
.describe('First 10 dimension values for orientation. Use eurostat_get_dimension_values for the full list. Omitted alongside valuesCount when the value set could not be measured.'),
|
|
39
41
|
})
|
|
40
42
|
.describe('A dataset dimension with its valid values.'))
|
|
41
43
|
.describe('All dimensions of the dataset with their valid codes and labels.'),
|
|
42
44
|
timeRange: z
|
|
43
45
|
.object({
|
|
44
|
-
start: z
|
|
45
|
-
|
|
46
|
+
start: z
|
|
47
|
+
.string()
|
|
48
|
+
.optional()
|
|
49
|
+
.describe('Earliest available period (e.g., "1975"). Omitted when Eurostat does not report it.'),
|
|
50
|
+
end: z
|
|
51
|
+
.string()
|
|
52
|
+
.optional()
|
|
53
|
+
.describe('Most recent available period (e.g., "2024"). Omitted when Eurostat does not report it.'),
|
|
46
54
|
})
|
|
47
|
-
.describe('Overall data coverage period for this dataset.'),
|
|
55
|
+
.describe('Overall data coverage period for this dataset. Each bound is omitted when Eurostat does not report it — an omitted bound is unknown, not empty.'),
|
|
48
56
|
obsCount: z
|
|
49
57
|
.number()
|
|
50
|
-
.
|
|
51
|
-
|
|
58
|
+
.optional()
|
|
59
|
+
.describe('Total number of observations in the full dataset (all periods). Omitted when Eurostat does not report it — an omitted count is unknown, not zero.'),
|
|
60
|
+
lastUpdated: z
|
|
61
|
+
.string()
|
|
62
|
+
.optional()
|
|
63
|
+
.describe('ISO 8601 timestamp of the most recent data update. Omitted when Eurostat does not report it.'),
|
|
52
64
|
metadataUrl: z
|
|
53
65
|
.string()
|
|
54
66
|
.optional()
|
|
@@ -65,8 +77,8 @@ export const eurostatGetDatasetInfo = tool('eurostat_get_dataset_info', {
|
|
|
65
77
|
reason: 'async_response',
|
|
66
78
|
code: JsonRpcErrorCode.ServiceUnavailable,
|
|
67
79
|
when: 'Eurostat returned an async response (query too large for the API).',
|
|
68
|
-
retryable:
|
|
69
|
-
recovery: '
|
|
80
|
+
retryable: false,
|
|
81
|
+
recovery: 'The same call cannot succeed — this tool has no filters to narrow. Use eurostat_search_datasets or eurostat_browse_themes for catalogue-level coverage, or eurostat_get_dimension_values for one dimension at a time.',
|
|
70
82
|
},
|
|
71
83
|
],
|
|
72
84
|
async handler(input, ctx) {
|
|
@@ -87,7 +99,7 @@ export const eurostatGetDatasetInfo = tool('eurostat_get_dataset_info', {
|
|
|
87
99
|
if (reason === 'async_response') {
|
|
88
100
|
throw ctx.fail('async_response', err.message, {
|
|
89
101
|
recovery: {
|
|
90
|
-
hint:
|
|
102
|
+
hint: `Eurostat returned an oversized-response warning for "${input.dataset_code}", and this call exposes no filters to narrow — the same request will fail the same way. Use eurostat_search_datasets or eurostat_browse_themes for catalogue-level coverage (period range, observation count), or eurostat_get_dimension_values to inspect one dimension at a time.`,
|
|
91
103
|
},
|
|
92
104
|
});
|
|
93
105
|
}
|
|
@@ -101,25 +113,35 @@ export const eurostatGetDatasetInfo = tool('eurostat_get_dataset_info', {
|
|
|
101
113
|
return meta;
|
|
102
114
|
},
|
|
103
115
|
format: (result) => {
|
|
116
|
+
// Absent annotation-derived values are named as unreported rather than rendered as a
|
|
117
|
+
// zero or a blank, so content[] carries the same uncertainty structuredContent does.
|
|
118
|
+
const UNREPORTED = 'not reported by Eurostat';
|
|
119
|
+
const { start, end } = result.timeRange;
|
|
104
120
|
const lines = [
|
|
105
121
|
`# ${result.label}`,
|
|
106
122
|
`**Code:** ${result.code}`,
|
|
107
|
-
`**Period:** ${
|
|
108
|
-
`**Observations:** ${result.obsCount
|
|
109
|
-
`**Last updated:** ${result.lastUpdated}`,
|
|
123
|
+
`**Period:** ${start || end ? `${start ?? UNREPORTED} – ${end ?? UNREPORTED}` : UNREPORTED}`,
|
|
124
|
+
`**Observations:** ${result.obsCount?.toLocaleString() ?? UNREPORTED}`,
|
|
125
|
+
`**Last updated:** ${result.lastUpdated ?? UNREPORTED}`,
|
|
110
126
|
];
|
|
111
127
|
if (result.metadataUrl)
|
|
112
128
|
lines.push(`**Metadata:** ${result.metadataUrl}`);
|
|
113
129
|
lines.push(`\n## Dimensions (${result.dimensions.length})`);
|
|
114
130
|
for (const dim of result.dimensions) {
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
131
|
+
const count = dim.valuesCount === undefined
|
|
132
|
+
? `value count ${UNREPORTED}`
|
|
133
|
+
: `${dim.valuesCount} value${dim.valuesCount !== 1 ? 's' : ''}`;
|
|
134
|
+
lines.push(`\n### ${dim.label} (\`${dim.code}\`) — ${count}`);
|
|
135
|
+
const samples = dim.sampleValues ?? [];
|
|
136
|
+
if (samples.length > 0) {
|
|
137
|
+
lines.push(`Sample: ${samples.map((v) => `\`${v.code}\` ${v.label}`).join(', ')}`);
|
|
138
|
+
if (dim.valuesCount !== undefined && dim.valuesCount > samples.length) {
|
|
139
|
+
lines.push(`_(${dim.valuesCount - samples.length} more — use eurostat_get_dimension_values for the full list)_`);
|
|
121
140
|
}
|
|
122
141
|
}
|
|
142
|
+
else if (dim.valuesCount === undefined) {
|
|
143
|
+
lines.push(`_(use eurostat_get_dimension_values to list this dimension's values)_`);
|
|
144
|
+
}
|
|
123
145
|
}
|
|
124
146
|
return [{ type: 'text', text: lines.join('\n') }];
|
|
125
147
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-get-dataset-info.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAChF,OAAO,EAAE,sBAAsB,EAAE,MAAM,mDAAmD,CAAC;AAE3F,MAAM,CAAC,MAAM,sBAAsB,GAAG,IAAI,CAAC,2BAA2B,EAAE;IACtE,KAAK,EAAE,2BAA2B;IAClC,WAAW,EACT,qXAAqX;IACvX,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IAC9E,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC;QACd,YAAY,EAAE,CAAC;aACZ,MAAM,EAAE;aACR,GAAG,CAAC,CAAC,CAAC;aACN,QAAQ,CACP,2GAA2G,CAC5G;KACJ,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,2BAA2B,CAAC;QACtD,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,+BAA+B,CAAC;QAC3D,UAAU,EAAE,CAAC;aACV,KAAK,CACJ,CAAC;aACE,MAAM,CAAC;YACN,IAAI,EAAE,CAAC;iBACJ,MAAM,EAAE;iBACR,QAAQ,CACP,sGAAsG,CACvG;YACH,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,0DAA0D,CAAC;YACtF,WAAW,EAAE,CAAC;iBACX,MAAM,EAAE;iBACR,QAAQ,
|
|
1
|
+
{"version":3,"file":"eurostat-get-dataset-info.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAChF,OAAO,EAAE,sBAAsB,EAAE,MAAM,mDAAmD,CAAC;AAE3F,MAAM,CAAC,MAAM,sBAAsB,GAAG,IAAI,CAAC,2BAA2B,EAAE;IACtE,KAAK,EAAE,2BAA2B;IAClC,WAAW,EACT,qXAAqX;IACvX,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IAC9E,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC;QACd,YAAY,EAAE,CAAC;aACZ,MAAM,EAAE;aACR,GAAG,CAAC,CAAC,CAAC;aACN,QAAQ,CACP,2GAA2G,CAC5G;KACJ,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,2BAA2B,CAAC;QACtD,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,+BAA+B,CAAC;QAC3D,UAAU,EAAE,CAAC;aACV,KAAK,CACJ,CAAC;aACE,MAAM,CAAC;YACN,IAAI,EAAE,CAAC;iBACJ,MAAM,EAAE;iBACR,QAAQ,CACP,sGAAsG,CACvG;YACH,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,0DAA0D,CAAC;YACtF,WAAW,EAAE,CAAC;iBACX,MAAM,EAAE;iBACR,QAAQ,EAAE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C,KAAK,CAAC,CAAC,IAAI,MAAM,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;gBACnF,IAAI,GAAG,CAAC,WAAW,KAAK,SAAS,IAAI,GAAG,CAAC,WAAW,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;oBACtE,KAAK,CAAC,IAAI,CACR,KAAK,GAAG,CAAC,WAAW,GAAG,OAAO,CAAC,MAAM,+DAA+D,CACrG,CAAC;gBACJ,CAAC;YACH,CAAC;iBAAM,IAAI,GAAG,CAAC,WAAW,KAAK,SAAS,EAAE,CAAC;gBACzC,KAAK,CAAC,IAAI,CAAC,uEAAuE,CAAC,CAAC;YACtF,CAAC;QACH,CAAC;QACD,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -33,5 +33,10 @@ export declare const eurostatGetDimensionValues: import("@cyanheads/mcp-ts-core"
|
|
|
33
33
|
readonly when: "Eurostat returned an async warning — the dimension query matched too many observations.";
|
|
34
34
|
readonly retryable: false;
|
|
35
35
|
readonly recovery: "Use eurostat_get_dataset_info for a sampled value set, or narrow the request with geo_level for the geo dimension.";
|
|
36
|
+
}, {
|
|
37
|
+
readonly reason: "conflicting_params";
|
|
38
|
+
readonly code: JsonRpcErrorCode.ValidationError;
|
|
39
|
+
readonly when: "geo_level was combined with a dimension other than \"geo\", where it has no effect.";
|
|
40
|
+
readonly recovery: "Drop geo_level to list that dimension, or set dimension to \"geo\" to filter by NUTS level.";
|
|
36
41
|
}], undefined>;
|
|
37
42
|
//# sourceMappingURL=eurostat-get-dimension-values.tool.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-get-dimension-values.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAIhF,eAAO,MAAM,0BAA0B
|
|
1
|
+
{"version":3,"file":"eurostat-get-dimension-values.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAIhF,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAqHrC,CAAC"}
|
|
@@ -19,7 +19,7 @@ export const eurostatGetDimensionValues = tool('eurostat_get_dimension_values',
|
|
|
19
19
|
geo_level: z
|
|
20
20
|
.enum(GEO_LEVEL_VALUES)
|
|
21
21
|
.optional()
|
|
22
|
-
.describe('NUTS hierarchy level filter — only
|
|
22
|
+
.describe('NUTS hierarchy level filter — applies only when dimension is "geo"; passing it with any other dimension is rejected. Options: "aggregate" (EU/EA codes), "country" (2-letter codes, default), "nuts1" (3-char), "nuts2" (4-char), "nuts3" (5-char).'),
|
|
23
23
|
}),
|
|
24
24
|
output: z.object({
|
|
25
25
|
dimensionCode: z.string().describe('The dimension code that was queried.'),
|
|
@@ -50,6 +50,12 @@ export const eurostatGetDimensionValues = tool('eurostat_get_dimension_values',
|
|
|
50
50
|
retryable: false,
|
|
51
51
|
recovery: 'Use eurostat_get_dataset_info for a sampled value set, or narrow the request with geo_level for the geo dimension.',
|
|
52
52
|
},
|
|
53
|
+
{
|
|
54
|
+
reason: 'conflicting_params',
|
|
55
|
+
code: JsonRpcErrorCode.ValidationError,
|
|
56
|
+
when: 'geo_level was combined with a dimension other than "geo", where it has no effect.',
|
|
57
|
+
recovery: 'Drop geo_level to list that dimension, or set dimension to "geo" to filter by NUTS level.',
|
|
58
|
+
},
|
|
53
59
|
],
|
|
54
60
|
async handler(input, ctx) {
|
|
55
61
|
const svc = getEurostatDataService();
|
|
@@ -73,6 +79,13 @@ export const eurostatGetDimensionValues = tool('eurostat_get_dimension_values',
|
|
|
73
79
|
},
|
|
74
80
|
});
|
|
75
81
|
}
|
|
82
|
+
if (reason === 'conflicting_params') {
|
|
83
|
+
throw ctx.fail('conflicting_params', err.message, {
|
|
84
|
+
recovery: {
|
|
85
|
+
hint: `geo_level applies only to the "geo" dimension and had no effect on "${input.dimension}". Re-send without geo_level, or set dimension to "geo".`,
|
|
86
|
+
},
|
|
87
|
+
});
|
|
88
|
+
}
|
|
76
89
|
throw err;
|
|
77
90
|
}
|
|
78
91
|
ctx.log.info('Dimension values fetched', {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-get-dimension-values.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAChF,OAAO,EAAE,sBAAsB,EAAE,MAAM,mDAAmD,CAAC;AAC3F,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAErE,MAAM,CAAC,MAAM,0BAA0B,GAAG,IAAI,CAAC,+BAA+B,EAAE;IAC9E,KAAK,EAAE,+BAA+B;IACtC,WAAW,EACT,ofAAof;IACtf,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IAC9E,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC;QACd,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,qCAAqC,CAAC;QAC/E,SAAS,EAAE,CAAC;aACT,MAAM,EAAE;aACR,GAAG,CAAC,CAAC,CAAC;aACN,QAAQ,CACP,oIAAoI,CACrI;QACH,SAAS,EAAE,CAAC;aACT,IAAI,CAAC,gBAAgB,CAAC;aACtB,QAAQ,EAAE;aACV,QAAQ,CACP,
|
|
1
|
+
{"version":3,"file":"eurostat-get-dimension-values.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAChF,OAAO,EAAE,sBAAsB,EAAE,MAAM,mDAAmD,CAAC;AAC3F,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAErE,MAAM,CAAC,MAAM,0BAA0B,GAAG,IAAI,CAAC,+BAA+B,EAAE;IAC9E,KAAK,EAAE,+BAA+B;IACtC,WAAW,EACT,ofAAof;IACtf,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IAC9E,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC;QACd,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,qCAAqC,CAAC;QAC/E,SAAS,EAAE,CAAC;aACT,MAAM,EAAE;aACR,GAAG,CAAC,CAAC,CAAC;aACN,QAAQ,CACP,oIAAoI,CACrI;QACH,SAAS,EAAE,CAAC;aACT,IAAI,CAAC,gBAAgB,CAAC;aACtB,QAAQ,EAAE;aACV,QAAQ,CACP,qPAAqP,CACtP;KACJ,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,aAAa,EAAE,CAAC,CAAC,MAAM,EA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KAAK,MAAM,CAAC,IAAI,MAAM,CAAC,MAAM,EAAE,CAAC;YAC9B,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,IAAI,QAAQ,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC;QAC7C,CAAC;QACD,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -37,8 +37,8 @@ export declare const eurostatQueryDataset: import("@cyanheads/mcp-ts-core").Tool
|
|
|
37
37
|
obsCount: z.ZodNumber;
|
|
38
38
|
truncated: z.ZodBoolean;
|
|
39
39
|
timeRange: z.ZodObject<{
|
|
40
|
-
start: z.ZodString
|
|
41
|
-
end: z.ZodString
|
|
40
|
+
start: z.ZodOptional<z.ZodString>;
|
|
41
|
+
end: z.ZodOptional<z.ZodString>;
|
|
42
42
|
}, z.core.$strip>;
|
|
43
43
|
missingObsCount: z.ZodNumber;
|
|
44
44
|
}, z.core.$strip>, readonly [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eurostat-query-dataset.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-query-dataset.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAIhF,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"eurostat-query-dataset.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/eurostat-query-dataset.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAiB,MAAM,+BAA+B,CAAC;AAIhF,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyT/B,CAAC"}
|