Skip to main content
Glama

GoCodebook — California Building Codes

lookup_california_code_section

Read-onlyIdempotent

Look up the VERBATIM text of a California building, residential, fire, plumbing, mechanical, green (CALGreen), energy or existing-building code section, or a section of a California city or county zoning/municipal ordinance, by its section number. Use this whenever the user cites a section number ("CRC R602.10.2.3", "CBC 1004", "§ 17.60.090") or asks what a specific section says. Returns the official text with its citation, edition and a link to the full section. It does NOT determine whether a specific project complies — for that, send the user to the linked page.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sectionYesThe section number exactly as cited, without the code name. Examples: "R602.10.2.3", "1004", "507.2", "17.60.090", "11B-206".
code_editionNoOptional. Which Title 24 cycle to read. California enforces the edition in force when the permit application was submitted, so a project filed in 2024 is enforced under "2022". Defaults to "current" (the 2025 cycle, in force since 2026-01-01).
jurisdictionNoOptional. A California city or county slug to scope the lookup to its own municipal code — "los-angeles", "san-jose", "marin-county". Omit for statewide Title 24 codes.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, and destructiveHint, so the safety profile is covered. The description adds behavioral context beyond annotations by specifying the return format (official text with citation, edition, link), the exact input trigger, and the explicit caveat that it does not perform compliance determination. No contradiction with annotations.

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?

Four sentences, front-loaded with verb and resource, then trigger conditions, return value, and caveat. The example citations partly duplicate the schema's examples, but they add citation-format variety (CRC, CBC, §). Overall it earns its length without bloat.

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

Completeness4/5

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

For a read-only lookup with one required parameter and no output schema, the description covers trigger conditions, return format, scope of codes, and a key limitation (no compliance decisions). The main gap is that it doesn't mention the sibling listing tool or any not-found/error behavior, though neither is critical for calling this tool. It is sufficient for an agent to invoke correctly.

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

Parameters3/5

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

Schema description coverage is 100%, and each parameter (section, code_edition, jurisdiction) has a thorough description with examples and selection rules. The tool description adds little beyond restating that lookup is by section number; the edition-cycle rule and jurisdiction scoping are already in the schema, so the baseline 3 applies.

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 ('Look up') and a specific resource: the verbatim text of California Title 24 code sections and city/county municipal code sections, by section number. It also names the return payload (official text with citation, edition, link), which distinguishes it from the sibling list_california_code_documents. The scope is unambiguous.

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?

Explicitly states when to use: 'Use this whenever the user cites a section number ... or asks what a specific section says.' It also provides an exclusion: it does not determine compliance, and the user should be sent to the linked page. However, it never contrasts with the sibling list_california_code_documents, so the alternative-tool guidance is incomplete.

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.

Resources