Search the law corpus
well_search_lawSearch the stored official law of one country by keywords, as of a date. FR: the LEGI codes, the BOFiP tax doctrine in force and the Service-Public.fr business fiches. US: the United States Code Title 26, the eCFR Title 26, the IRS documents of the Federal Register, the GovInfo editions and the IRS publications.
Write the query in the language the law is written in: French with its accents for FR ("frais de repas déductibles", not "frais de repas deductibles"), English for US.
A long text is stored in parts: each hit is the part that holds the words, and its title ends in (k/n), part k of n.
Every hit carries its source_id, its validity and its dates. Read an article with well_get_law_article before you rely on it. validity: "unknown" means the source gives no in-force dates, and observed_from is only the day the source published the text. end_unknown means the source says the text ends or has ended but gives no end date.
On beyond_coverage, say the stored law is verified only through covered_through, and ask again with an as_of on or before that date when a past date answers the question.
This is not legal advice and not a web search.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"country": "<country>",
"query": "<query>"
},
"name": "well_search_law"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| as_of | No | The day the law must be in force on. Omit for the latest verified day. | |
| query | Yes | The keywords, in the language of the country's law: French with accents for FR, English for US. | |
| country | Yes | The country whose law to search. | |
| sources | No | The sources to search. Omit to search every source of the country. | |
| workspace_id | No | Target workspace. Optional: this tool describes the token itself rather than one workspace's data, so omitting it returns the same answer. | |
| conversation_id | No | The conversation id returned by the previous Well result, in its meta under well/conversation_id, in its structuredContent, or in its JSON text block. Pass it back on every call in the same conversation, including a call a card makes, so the chosen workspace and the earlier answers still apply. It decides the conversation on its own: nothing the host states about the session replaces it. Omit it only on the first call of a conversation. | |
| workspace_scope | No | Restrict this call to the family: the token's primary workspace plus the company workspaces under it that you are a member of. Unrelated authorized workspaces drop out of the read; row reads merge across the family, while a per-workspace figure still reports exactly one workspace. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hits | No | ||
| as_of | No | ||
| status | Yes | ||
| message | No | ||
| refusal | No | ||
| success | Yes | ||
| coverage | No | ||
| hits_cut | No | ||
| conversation_id | No | The conversation this result belongs to. Pass it back as the conversation_id argument on every later Well call in the same conversation. | |
| newly_connected | No | Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. The connected-line rule says when to tell an entry; when it does, one line per entry, in the person's language: "<name> is connected.". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later. | |
| conversation_id_note | No | Present only when the server opened a fresh lane, stating that no choice recorded earlier was read. | |
| conversation_id_source | No | Where the conversation id came from: the host's own request meta, the caller's argument, or a fresh lane the server opened. |