Search Japanese Law Text
jplaw_search_textSearch Japanese statutes across laws for highlighted previews grouped by law. Filter with sections and continue with next_offset and the same filters. Read exact text with jplaw_get_law or jplaw_get_provision. Supply law or law_revision_id for literal search of paragraphs, their inline tables and lists, and article captions. Reopen a scoped match with its selector as jplaw_get_law.part or, when present, its address as a jplaw_get_provision.provisions entry. Pin the returned revision for reads and paging. Restart if revision.updated changes.
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": {
"keyword": "<keyword>"
},
"name": "jplaw_search_text"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| law | No | Exact law ID, Japanese number, title, or abbreviation for scoped search. | |
| asof | No | Calendar date YYYY-MM-DD from 2017-04-01. Omit for the current version. | |
| limit | No | Maximum snippets or scoped matches per page. Values above 1000 are served at 1000. | |
| offset | No | Upstream snippet or scoped match offset. Pass the previous next_offset. | |
| keyword | Yes | Japanese body text. Across laws use space (AND), | (OR), ! (NOT), or * and ? wildcards. In one revision, join literal terms by whitespace (AND within one provision). | |
| sections | No | Cross-law snippet sections. The search scans later pages to fill the limit. | |
| law_types | No | Cross-law filter for law types. | |
| categories | No | Cross-law filter for category codes from jplaw_list_reference. | |
| law_revision_id | No | Exact revision ID for scoped search. Mutually exclusive with asof. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| count | No | Snippets or scoped matches on this page. | |
| error | No | Present when the call failed. Absent on success. | |
| limit | No | Effective page limit. | |
| query | No | Applied search expression, filters and date. | |
| groups | No | Cross-law previews grouped by law and revision in law-ID order. Empty in scoped mode. | |
| offset | No | Requested offset. | |
| scoped | No | Result when searching one law revision. | |
| notices | No | Guidance on search interpretation or continuation. | |
| truncated | No | Whether this search has a continuation. | |
| incomplete | No | True if a cross-law scan reached its deadline. Continue with next_offset and the same filters. | |
| attribution | No | Source credit and processing statement. | |
| next_offset | No | Next upstream snippet or scoped match offset, or null when exhausted. | |
| upstream_total_count | No | Total reported by e-Gov before section filtering. |