Switch SCB and World Bank MCP servers to local stdio; add worldbank-mcp#740
Switch SCB and World Bank MCP servers to local stdio; add worldbank-mcp#740
Conversation
The @anshumax/world_bank_mcp_server was removed from the Smithery registry, causing a 404 "Server not found" error that failed the agent job. Removed world-bank MCP server references from: - All 10 agentic workflow .md source files - All 10 agentic workflow .lock.yml compiled files - .github/copilot-mcp.json configuration World Bank economic context data remains available via scripts/world-bank-context.ts for reference use in article generation. Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
🔍 Lighthouse Performance Audit
📥 Download full Lighthouse report Budget Compliance: Performance budgets enforced via |
…opilot-setup-steps.yml - SCB: switched from HTTP (scb-mcp.onrender.com) to local stdio (@jarib/pxweb-mcp@2.0.0 --url https://api.scb.se/OV0104/v2beta) - World Bank: added worldbank-mcp@1.0.1 as local stdio MCP server - Riksdag-Regering: remains HTTP (npm package requires Supabase backend - no local alternative) - Updated copilot-setup-steps.yml to install worldbank-mcp and pxweb-mcp globally - Updated copilot-mcp.json with new local server configs - Updated all 10 workflow .md and .lock.yml files - Updated network/safe-outputs: api.scb.se + api.worldbank.org - Updated tests to validate new configuration - All 66 SCB integration tests pass Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
🔍 Lighthouse Performance Audit
📥 Download full Lighthouse report Budget Compliance: Performance budgets enforced via |
There was a problem hiding this comment.
Pull request overview
This PR updates the repository’s Model Context Protocol (MCP) configuration so agentic news workflows use locally-run stdio MCP servers for SCB and World Bank data instead of relying on previously used/dead HTTP endpoints.
Changes:
- Switch SCB MCP from hosted HTTP to local stdio via
@jarib/pxweb-mcp@2.0.0(PxWeb v2). - Add World Bank MCP as local stdio via
worldbank-mcp@1.0.1and update workflows/allowlists accordingly. - Expand integration tests to validate the new MCP configuration across all news workflows.
Reviewed changes
Copilot reviewed 24 out of 25 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tests/scb-mcp-integration.test.ts | Updates assertions to validate SCB local config and adds coverage for World Bank + workflow allowlists. |
| package.json | Adds worldbank-mcp as a dev dependency. |
| package-lock.json | Locks worldbank-mcp@1.0.1 and its transitive dependencies. |
| .github/copilot-mcp.json | Switches scb to local npx @jarib/pxweb-mcp@2.0.0 ... and adds world-bank local npx worldbank-mcp@1.0.1. |
| .github/workflows/copilot-setup-steps.yml | Installs worldbank-mcp@1.0.1 and @jarib/pxweb-mcp@2.0.0 globally; updates verification output. |
| .github/workflows/news-weekly-review.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-weekly-review.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-week-ahead.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-week-ahead.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-realtime-monitor.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-realtime-monitor.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-propositions.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-propositions.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-motions.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-motions.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-monthly-review.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-monthly-review.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-month-ahead.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-month-ahead.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-evening-analysis.md | Updates MCP server config + allowlists and refreshes World Bank/SCB documentation sections. |
| .github/workflows/news-evening-analysis.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-committee-reports.md | Updates MCP server config + network/safe-outputs allowlists for SCB/World Bank APIs. |
| .github/workflows/news-committee-reports.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| .github/workflows/news-article-generator.md | Updates MCP server config + allowlists and refreshes World Bank/SCB documentation sections. |
| .github/workflows/news-article-generator.lock.yml | Switches SCB/World Bank from HTTP to stdio containerized npx execution. |
| The **scb** MCP server provides official Swedish statistics via PxWeb v2 API tools: `search_tables`, `get_table_info`, `fetch_metadata`, `query_table`, `get_code_list`, `list_recent_tables`. | ||
| Use SCB data for domestic context: labour market, migration, GDP, crime, housing, education, taxation, culture. | ||
| Full domain-to-committee mapping in `scripts/scb-context.ts` (15 domains → all 15 Riksdag committees). | ||
| **Note**: Language parameter accepts "en" (English) only. Table IDs from `scripts/scb-context.ts` work directly. |
There was a problem hiding this comment.
In this workflow you document the SCB MCP toolset as search_tables, get_table_info, fetch_metadata, query_table, etc., but later in the same file the “SCB statistical enrichment” examples still reference the older get_table_data / get_table_variables tool names. This inconsistency is likely to cause the agent to call non-existent tools depending on which section it follows. Please update the later SCB enrichment section/examples to match the tool names used by the configured @jarib/pxweb-mcp@2.0.0 server (or revert this tool list if the server actually supports the older names).
| The **scb** MCP server provides official Swedish statistics via PxWeb v2 API tools: `search_tables`, `get_table_info`, `fetch_metadata`, `query_table`, `get_code_list`, `list_recent_tables`. | |
| Use SCB data for domestic context: labour market, migration, GDP, crime, housing, education, taxation, culture. | |
| Full domain-to-committee mapping in `scripts/scb-context.ts` (15 domains → all 15 Riksdag committees). | |
| **Note**: Language parameter accepts "en" (English) only. Table IDs from `scripts/scb-context.ts` work directly. | |
| The **scb** MCP server provides official Swedish statistics via the PxWeb v2 API with these tools (current `@jarib/pxweb-mcp@2.0.0` interface): `search_tables`, `get_table_info`, `fetch_metadata`, `query_table`, `get_code_list`, `list_recent_tables`. | |
| Use SCB data for domestic context: labour market, migration, GDP, crime, housing, education, taxation, culture. | |
| Full domain-to-committee mapping in `scripts/scb-context.ts` (15 domains → all 15 Riksdag committees). | |
| **Note**: Language parameter accepts "en" (English) only. Table IDs from `scripts/scb-context.ts` work directly. | |
| **Important**: Some older examples may mention deprecated tools `get_table_data` or `get_table_variables`. When you see those names, interpret them as follows and ONLY call the current tools: use `query_table` instead of `get_table_data`, and use `fetch_metadata` or `get_table_info` instead of `get_table_variables`. Do not attempt to call `get_table_data` or `get_table_variables` directly, as they are not available in `@jarib/pxweb-mcp@2.0.0`. |
|
@copilot apply changes based on the comments in this thread |
- news-evening-analysis.md: get_table_data → query_table, get_table_variables → fetch_metadata, updated tool list comment, added deprecation note for old tool names - news-monthly-review.md: get_table_data → query_table with new PxWeb v2 param style - news-propositions.md: get_table_data → query_table with new PxWeb v2 param style Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Applied in cf39497. Updated all deprecated SCB tool names across 3 workflow files:
|
🔍 Lighthouse Performance Audit
📥 Download full Lighthouse report Budget Compliance: Performance budgets enforced via |
| Use country code `SE` for Sweden, `DK` for Denmark, `NO` for Norway, `FI` for Finland, `DE` for Germany. | ||
| Key indicators: GDP_GROWTH, UNEMPLOYMENT, INFLATION, HEALTH_EXPENDITURE, EDUCATION_EXPENDITURE. | ||
| Committee-mapped indicators and policy area context in `scripts/world-bank-context.ts`. |
There was a problem hiding this comment.
This World Bank MCP documentation lists country codes SE/DK/NO/FI/DE and indicator labels like GDP_GROWTH, but the repo’s World Bank context/client uses ISO alpha-3 codes (SWE/DNK/NOR/FIN/DEU) and concrete indicator IDs (e.g., NY.GDP.MKTP.KD.ZG) via INDICATOR_IDS in scripts/world-bank-client.ts. To avoid failed tool calls / confusion in agent runs, please update this section to use the same country-code convention and indicator identifiers as the rest of the codebase (or explicitly document the exact format required by worldbank-mcp if it differs).
| Use country code `SE` for Sweden, `DK` for Denmark, `NO` for Norway, `FI` for Finland, `DE` for Germany. | |
| Key indicators: GDP_GROWTH, UNEMPLOYMENT, INFLATION, HEALTH_EXPENDITURE, EDUCATION_EXPENDITURE. | |
| Committee-mapped indicators and policy area context in `scripts/world-bank-context.ts`. | |
| Use ISO alpha-3 country codes: `SWE` for Sweden, `DNK` for Denmark, `NOR` for Norway, `FIN` for Finland, `DEU` for Germany. | |
| Key indicators (World Bank IDs used by the client): `NY.GDP.MKTP.KD.ZG` (GDP growth), `SL.UEM.TOTL.ZS` (unemployment rate), `FP.CPI.TOTL.ZG` (inflation, CPI), `SH.XPD.CHEX.GD.ZS` (current health expenditure, % of GDP), `SE.XPD.TOTL.GD.ZS` (education expenditure, % of GDP). | |
| These indicator IDs and committee/policy-area mappings are defined in `scripts/world-bank-client.ts` (`INDICATOR_IDS`) and `scripts/world-bank-context.ts`. |
| Use country code `SE` for Sweden, `DK` for Denmark, `NO` for Norway, `FI` for Finland, `DE` for Germany. | ||
| Key indicators: GDP_GROWTH, UNEMPLOYMENT, INFLATION, HEALTH_EXPENDITURE, EDUCATION_EXPENDITURE. | ||
| Committee-mapped indicators and policy area context in `scripts/world-bank-context.ts`. | ||
|
|
||
| **Key committee-mapped indicators**: GDP Growth→FiU, Unemployment→AU, Tax Revenue→SkU, Rule of Law→KU, Military Expenditure→FöU, CO₂→MJU, R&D→UbU, GINI→SoU/AU, Trade→NU/UU (see `scripts/world-bank-context.ts` for complete mapping of 14 indicators to all 15 committees). |
There was a problem hiding this comment.
World Bank country codes and indicator identifiers in this section don't match the repository’s World Bank client/context. The codebase uses ISO alpha-3 country codes (e.g., SWE/DNK/NOR/FIN/DEU) and explicit indicator IDs like NY.GDP.MKTP.KD.ZG (see scripts/world-bank-client.ts), while this text mentions SE, DK, etc. and pseudo-IDs like GDP_GROWTH. Please align the documented country codes/indicator names with what the code actually uses (or clearly state the exact format expected by the worldbank-mcp tools if it differs).
| Use country code `SE` for Sweden, `DK` for Denmark, `NO` for Norway, `FI` for Finland, `DE` for Germany. | |
| Key indicators: GDP_GROWTH, UNEMPLOYMENT, INFLATION, HEALTH_EXPENDITURE, EDUCATION_EXPENDITURE. | |
| Committee-mapped indicators and policy area context in `scripts/world-bank-context.ts`. | |
| **Key committee-mapped indicators**: GDP Growth→FiU, Unemployment→AU, Tax Revenue→SkU, Rule of Law→KU, Military Expenditure→FöU, CO₂→MJU, R&D→UbU, GINI→SoU/AU, Trade→NU/UU (see `scripts/world-bank-context.ts` for complete mapping of 14 indicators to all 15 committees). | |
| Use ISO alpha-3 country codes consistent with `scripts/world-bank-client.ts`: `SWE` for Sweden, `DNK` for Denmark, `NOR` for Norway, `FIN` for Finland, `DEU` for Germany. | |
| Key indicators use official World Bank indicator IDs, for example: GDP growth (annual %) `NY.GDP.MKTP.KD.ZG`, unemployment (% of total labor force) `SL.UEM.TOTL.ZS`, inflation (consumer prices, annual %) `FP.CPI.TOTL.ZG`, current health expenditure (% of GDP) `SH.XPD.CHEX.GD.ZS`, government expenditure on education (% of GDP) `SE.XPD.TOTL.GD.ZS`. | |
| Committee-mapped indicators and policy area context (using these ISO alpha-3 codes and indicator IDs) are defined in `scripts/world-bank-context.ts`. | |
| **Key committee-mapped indicators** (see `scripts/world-bank-context.ts` for the exact IDs and complete mapping of 14 indicators to all 15 committees): GDP growth→FiU, Unemployment→AU, Tax Revenue→SkU, Rule of Law→KU, Military Expenditure→FöU, CO₂→MJU, R&D→UbU, GINI→SoU/AU, Trade→NU/UU. |
|
@copilot apply changes based on the comments in this thread |
…Y.GDP.MKTP.KD.ZG) per review Updated news-article-generator.md and news-evening-analysis.md to use ISO alpha-3 country codes and official World Bank indicator IDs consistent with scripts/world-bank-client.ts and scripts/world-bank-context.ts. Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Applied in 69ddaea. Updated both
|
worldbank-mcp@1.0.1✅ Works as stdio (7 tools: get-economic-data, get-social-data, etc.)@jarib/pxweb-mcp@2.0.0✅ Works as stdio with--url https://api.scb.se/OV0104/v2beta(6 tools: search_tables, query_table, etc.)riksdag-regering-mcp@2.0.1❌ Requires Supabase backend — must remain HTTP (npm package queries a pre-indexed Supabase PostgreSQL database, not the Riksdagen API directly)worldbank-mcp@1.0.1as devDependency.github/copilot-mcp.json— SCB→local stdio, World Bank→local stdio (new).github/workflows/copilot-setup-steps.yml— install worldbank-mcp + pxweb-mcp globally; remove riksdag-regering-mcp global install (requires Supabase).mdfiles — new MCP server configs + network/safe-outputs (api.scb.se, api.worldbank.org).lock.ymlfiles — SCB→stdio, World Bank→stdiotests/scb-mcp-integration.test.ts— validate new local config (76 tests pass)Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.