API / Developers
Build on Legislative Intelligence
The LocalCode API gives qualified platforms access to structured municipal code, legislative chain data, and amendment events. Built for serious integrations. Access is manually approved.
Explore the draft developer documentation and OpenAPI reference.
curl https://api.localcode.ai/v1/chain/25-2-773 \
-H "Authorization: Bearer lc_live_sk_..." \
-G -d "jurisdiction=tx-austin"
# → 200 OK
{
"section_id": "25-2-773",
"section_title": "Permitted Uses — MF-3",
"effective_date": "2022-03-14",
"adopting_ordinance": {
"number": "20220127-069",
"date": "2022-01-27",
"source_url": "..."
},
"amendments": [
{
"ordinance": "20231109-152",
"date": "2023-11-09",
"description": "Added 'short-term rental' to permitted use list"
}
],
"enabling_statute": "Texas Local Gov't Code § 211.003"
}What the API Exposes
The Full Legislative Intelligence Layer
Four data surfaces, all accessible via REST. Each one adds a layer of intelligence that doesn't exist anywhere else.
Legislative Chain
Ordinance linkage, amendment history, enabling statute, source documents.
Code Library
Structured section text, hierarchy, source attribution, effective date.
Jurisdiction Research
Coverage metadata, jurisdiction feed, change event log.
Amendment Events
Structured diff payloads via webhook. Know when any section changes.
Endpoints
Developer Preview API Surface
Draft v1 endpoint groups focused on jurisdictions, code sections, ordinances, legislative chain, source verification, sources, and search.
Jurisdictions
List supported jurisdictions and coverage metadata.
Code Sections
Retrieve structured code section text, hierarchy, status, and provenance fields.
Ordinances
Access ordinance metadata, source links, adoption details, and related code impacts.
Legislative Chain
Trace relationships between code sections, ordinances, authority, and source evidence.
Source Verification
Check official source references, verification status, confidence, and evidence links.
Sources
Retrieve source records for official code pages, ordinance PDFs, and jurisdiction materials.
Search
Search across supported jurisdictions, code sections, ordinances, and provenance metadata.
Integration Patterns
Three Ways Platforms Use LocalCode
From legislative intelligence layers to amendment monitoring to underwriting automation — the same API, different workflows.
Pattern 01 · Platform Integration
Add Legislative Intelligence to Your Data Stack
Platforms that serve attorneys, entitlement professionals, or real estate teams can integrate the LocalCode API to surface legislative chain data, amendment history, and structured code alongside their existing data layers.
- 01GET /chain/{section_id} to retrieve the full legislative chain
- 02Display adopting ordinance, amendments, and enabling statute in your UI
- 03Subscribe to /webhooks to receive amendment events automatically
- 04Use /code/{section_id} for structured section text with attribution
curl https://api.localcode.ai/v1/chain/25-2-773 \
-H "Authorization: Bearer lc_live_sk_..." \
-G -d "jurisdiction=tx-austin"
# → 200 OK
{
"section_id": "25-2-773",
"section_title": "Permitted Uses — MF-3",
"effective_date": "2022-03-14",
"adopting_ordinance": {
"number": "20220127-069",
"date": "2022-01-27",
"source_url": "..."
},
"amendments": [
{
"ordinance": "20231109-152",
"date": "2023-11-09",
"description": "Added 'short-term rental' to permitted use list"
}
],
"enabling_statute": "Texas Local Gov't Code § 211.003"
}Pattern 02 · Amendment Monitoring
Know About Code Changes Before Your Clients Do
Subscribe to webhook events for the jurisdictions that matter to your users. When a council publishes an amendment, you receive a structured diff payload with the exact changes — before anyone discovers it in a physical review.
- 01POST /webhooks with your endpoint URL and jurisdiction list
- 02Receive event payloads within 72hr of council publication
- 03Parse changes[] array for affected sections and attributes
- 04Surface alerts to users affected by the change
{
"event": "section.amended",
"jurisdiction": "tx-austin",
"section_id": "25-2-773",
"section_title": "Permitted Uses — MF-3",
"effective_date": "2023-11-09",
"ordinance_number": "20231109-152",
"changes": [
{
"attribute": "permitted_uses",
"prior_value": ["multifamily", "residential-care"],
"new_value": ["multifamily", "residential-care", "short-term-rental"],
"source_ref": "§ 25-2-773(B)(4)"
}
],
"diff_url": "https://api.localcode.ai/v1/diffs/tx-austin/20231109-152",
"timestamp": "2023-11-09T14:22:17Z"
}Pattern 03 · Underwriting & Site Selection
Flag Regulatory Risk at Deal Intake
Pull zoning attributes at the moment a parcel enters your underwriting pipeline. Surface non-conforming flags, permitted use gaps, and dimensional mismatches before your team touches the deal.
- 01POST /parcels/batch with APNs from your intake form
- 02Parse permitted_uses and non_conforming fields
- 03Compare against your target use requirements
- 04Auto-flag deals requiring land use review
curl -X POST https://api.localcode.ai/v1/parcels/batch \
-H "Authorization: Bearer lc_live_sk_..." \
-H "Content-Type: application/json" \
-d '{
"jurisdiction": "tx-austin",
"parcel_ids": ["APN-1001", "APN-1002", "APN-1003"]
}'Technical Specs
Built to the Standard You Expect
OpenAPI 3.1 Spec
Import directly into Postman, Insomnia, or any OpenAPI-compatible client. Full schema documentation included.
<100ms P95 Latency
Served from edge infrastructure, cached per jurisdiction. Batch endpoints optimized for high-volume workflows.
SDK (Coming Soon)
TypeScript and Python clients. Drop-in integration for analytics pipelines and PropTech platforms.
Webhook Retries
Automatic retry with exponential backoff. Delivery logs and event replay available in the dashboard.
Authentication
Bearer Token, Standard HTTP
All requests are authenticated with a Bearer token in the Authorization header. Keys are scoped per environment (sandbox vs. production) and per tier.
API access is manually approved. We review applications and issue keys to qualified platforms and integrators. See pricing →
# All API requests
curl https://api.localcode.ai/v1/... \
-H "Authorization: Bearer lc_live_sk_xxxxxxxxxxxx"
# Sandbox (no billing)
curl https://api.localcode.ai/v1/... \
-H "Authorization: Bearer lc_test_sk_xxxxxxxxxxxx"Ready to Integrate?
API access is manually approved. Tell us what you're building and we'll evaluate your application and follow up directly.