Skip to main content
Glama

SSB Norway Table Data

ssbnorway.data.query
Read-onlyIdempotent

Fetch statistical data from a specific SSB Norway table using dimension filters. Returns a JSON-stat2 dataset with dimension labels, value arrays, and metadata (updated timestamp, source, notes). Use ssbnorway.data.search to find the table ID, ssbnorway.data.metadata to get valid dimension codes and values, then pass them here as a query array. Each filter specifies a dimension code and selected values. Use filter="item" with specific value codes to select rows, filter="top" with count to get the N most recent years. Unfiltered dimensions with elimination=true are aggregated into totals. Covers 1,900+ statistical domains across Norway.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesArray of dimension filters. Each filter selects specific values for one variable. Unfiltered dimensions are aggregated (eliminated) if elimination=true, or omitted. Example: [{code:'ContentsCode',selection:{filter:'item',values:['Personer1']}}, {code:'Tid',selection:{filter:'top',values:['3']}}]. Response is JSON-stat2 with label, updated, dimension map, and values array.
table_idYesSSB table ID to query — the numeric ID from ssbnorway.search or ssbnorway.metadata. Example: "07459" for population, "09842" for GDP.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNoPresent only when the call failed. Includes error code, message, request_id, and any provider-specific extras.
resultNoTool response payload. Shape varies per tool — consult the tool description and inputSchema. May be an object, array, string, or number depending on the upstream provider response.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover safety (readOnlyHint, idempotentHint, destructiveHint), so the bar is lower. The description adds useful behavioral context beyond annotations: response format (JSON-stat2 with labels, values, metadata), handling of unfiltered dimensions via elimination, and filter semantics for item/top. It doesn't mention rate limits or response size, but those are not critical for this read-only query tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but every sentence earns its place: purpose, return shape, workflow, filter semantics, and aggregation behavior. It is front-loaded with the core action and output before procedural details.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-parameter read-only query tool with a rich schema, output schema, and helpful annotations, this description covers all the practical guidance an agent needs: how to discover inputs, how to construct filters, what the response looks like, and how unfiltered dimensions behave. Nothing essential is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema documents both parameters thoroughly. The description adds extra semantic value by explaining filter types in context, especially 'top' for recent time periods and the aggregation behavior of unfiltered dimensions. This goes beyond the raw schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Fetch statistical data from a specific SSB Norway table using dimension filters.' It also names the sibling tools (search, metadata) and clarifies this tool is the query step, so an agent can distinguish it immediately.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly prescribes the workflow: use ssbnorway.data.search to find the table ID, ssbnorway.data.metadata to get valid dimension codes, then pass them here as a query array. This is clear when-to-use guidance with named alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.