Skip to main content
Glama

Se Law Search

se_law_search
Read-onlyIdempotent

Search Swedish national legislation (Svensk forfattningssamling, SFS: laws, ordinances and balkar) by word, in Swedish, e.g. "dataskydd" or "arbetsmiljo". Matches the whole text of each statute, ranked by relevance, so a word in the title ranks first. By default only statutes not marked repealed; set include_repealed=true to see repealed ones. Optional year_from / year_to narrow by year of issue. Returns up to 10 matches with id ("2018:218" = year:number, the SFS number), title, issue date, issuing ministry, repealed flag, how far it is amended and link. Pair with se_law_get for the text.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "dataskydd"
    },
    "name": "se_law_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryYesSwedish word(s), e.g. "dataskydd"; a word from the title ranks best
year_toNoLatest year of issue, e.g. 2020
year_fromNoEarliest year of issue, e.g. 2000
include_repealedNoAlso return statutes marked repealed (default false)

Output Schema

NameRequiredDescriptionDefault
hintNo
noteNo
countYes
queryYes
sourceNo
resultsYes
data_as_ofNo
empty_reasonNo
more_possibleNo
total_matchesNo
include_repealedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive), and the description adds genuinely new behavior: relevance ranking with title matches weighted first, a default exclusion of repealed statutes, and a hard cap of 10 results. It also enumerates the returned fields and the SFS id format, so the agent knows exactly what comes back.

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

Conciseness4/5

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

The paragraph is dense and front-loaded with purpose, then defaults, then filters, then return shape, ending with the sibling handoff. The only redundancy is repeating the query examples ('dataskydd' / 'arbetsmiljo') already present in the schema.

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 single-resource search tool with four simple parameters, the definition covers purpose, defaults, ranking behavior, result cap, return fields, and the follow-up tool. Nothing an agent needs in order to call it correctly 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 baseline is 3, but the description adds meaning beyond the schema: queries must be in Swedish, a word drawn from the title ranks best, and year_from/year_to narrow by year of issue rather than filtering full text. It adds real semantic guidance without belaboring each parameter.

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 states a specific verb and resource ('Search Swedish national legislation (SFS: laws, ordinances and balkar)') and specifies the search domain (full statute text), which clearly differentiates it from se_law_get, the fetch-the-text sibling.

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

Usage Guidelines4/5

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

It explicitly says to 'Pair with se_law_get for the text', routing the agent to the right alternative once a statute is identified, and explains the default repealed-filter with the override. There is no explicit statement of when not to use it (e.g., searching case law or EU law), so it stops short of full when/when-not coverage.

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.