API for Developers

Free public API providing access to U.S. legal data. JSON responses with filtering, pagination, and no authentication required.

Quick Start

No API key required. Make a GET request to any endpoint:

curl "https://megalawusa.com/api/v1/statutes?jurisdiction=federal&limit=5"

Endpoints

GET/api/v1/statutes

Search and filter U.S. federal and state statutes.

Query Parameters

ParameterTypeDescription
jurisdictionstringFilter by jurisdiction ID or abbreviation (e.g., 'federal', 'CA')
topicstringFilter by topic keyword (e.g., 'civil-rights', 'labor')
limitnumberResults per page (default: 20, max: 100)
offsetnumberNumber of results to skip for pagination
GET/api/v1/cases

Search and filter U.S. court cases.

Query Parameters

ParameterTypeDescription
jurisdictionstringFilter by jurisdiction ID or name
topicstringFilter by topic keyword
courtstringFilter by court name or level (e.g., 'supreme', 'appeals')
limitnumberResults per page (default: 20, max: 100)
offsetnumberNumber of results to skip
GET/api/v1/bills

Search and filter legislative bills.

Query Parameters

ParameterTypeDescription
jurisdictionstringFilter by jurisdiction ID or name
topicstringFilter by topic keyword
statusstringFilter by status (e.g., 'in_committee', 'passed_chamber', 'signed')
chamberstringFilter by chamber ('senate' or 'house')
limitnumberResults per page (default: 20, max: 100)
offsetnumberNumber of results to skip
GET/api/v1/jurisdictions

List all available jurisdictions (federal, 50 states, territories).

Response Format

All endpoints return JSON with a consistent structure:

{
  "data": [ ... ],
  "meta": {
    "total": 150,
    "limit": 20,
    "offset": 0,
    "hasMore": true
  }
}