ma_search_sections

Pack: massachusetts-code · Connect: https://pipeworx.io/mcp (see Connect below for a single-pack URL)

No MCP client? Call it directly: GET https://gateway.pipeworx.io/v1/tools/ma_search_sections for the schema, then POST the same URL with its arguments for the data.

Search the Massachusetts General Laws BY TOPIC or keyword when you do not have a chapter and section, e.g. “gold dealers”, “fineness marks silver”, “landlord security deposit”. Matches the Legislature’s own section titles and chapter names across all chapters (not statute text; the site has no text search). Returns chapter, section, title and the arguments to pass to ma_general_law for the full text. Optional chapter narrows to one chapter. Keyless.

Parameters

NameTypeRequiredDescription
querystringyesTopic or keywords, e.g. “gold dealers”.
chapterstringnoOptional chapter to search within, e.g. “266” or “90A”.
limitnumbernoMax results, default 10, max 25.

Example call

Arguments

{
  "query": "gold dealers"
}

curl

curl -X POST https://gateway.pipeworx.io/massachusetts-code/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"ma_search_sections","arguments":{"query":"gold dealers"}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('ma_search_sections', {
  "query": "gold dealers"
});

More examples

{
  "query": "landlord security deposit",
  "limit": 5
}

Response shape

Always returns: found

FieldTypeDescription
foundbooleantrue when at least one section title matched
querystring
countnumberResults returned
total_matchednumberAll sections that matched before the limit
resultsarray
hintstring
match_levelstring
sourcestring
data_as_ofstring
reasonstringPresent when found is false
messagestring
sections_scannednumber
Full JSON Schema
{
  "type": "object",
  "properties": {
    "found": {
      "type": "boolean",
      "description": "true when at least one section title matched"
    },
    "query": {
      "type": "string"
    },
    "count": {
      "type": "number",
      "description": "Results returned"
    },
    "total_matched": {
      "type": "number",
      "description": "All sections that matched before the limit"
    },
    "results": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "citation": {
            "type": "string"
          },
          "chapter": {
            "type": [
              "string",
              "null"
            ]
          },
          "chapter_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "section": {
            "type": "string"
          },
          "section_title": {
            "type": "string"
          },
          "get_section": {
            "type": "object",
            "description": "Arguments for ma_general_law",
            "properties": {
              "tool": {
                "type": "string"
              },
              "arguments": {
                "type": "object",
                "properties": {
                  "chapter": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "section": {
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "required": [
          "citation",
          "chapter",
          "section",
          "section_title",
          "get_section"
        ]
      }
    },
    "hint": {
      "type": "string"
    },
    "match_level": {
      "type": "string"
    },
    "source": {
      "type": "string"
    },
    "data_as_of": {
      "type": "string"
    },
    "reason": {
      "type": "string",
      "description": "Present when found is false"
    },
    "message": {
      "type": "string"
    },
    "sections_scanned": {
      "type": "number"
    }
  },
  "required": [
    "found"
  ]
}

Connect

Add this to your MCP client config — every tool in the catalog, including this one — or use one-click install buttons:

{
  "mcpServers": {
    "pipeworx": {
      "url": "https://pipeworx.io/mcp"
    }
  }
}
Connect to just the massachusetts-code pack
{
  "mcpServers": {
    "massachusetts-code": {
      "url": "https://gateway.pipeworx.io/massachusetts-code/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build November 24, 2026