LegalCals

LegalCals Enterprise API v1

Regulatory intelligence at scale. Risk scoring, forecasting, similarity analysis, and national reporting across all Canadian provinces and US states.

10 Intelligence Engines

From single-jurisdiction risk scoring to national quarterly reports — compose the exact intelligence you need.

Versioned & Stable

All enterprise endpoints live under /api/v1/ with backward-compatibility guarantees and semantic versioning.

Simple Auth

One header, no OAuth. Send x-legalcals-key with every request and get JSON back with rate-limit metadata.

Authentication

Include your API key in the x-legalcals-key header with every request.

POST /api/v1/risk
Host: legalcals.com
Content-Type: application/json
x-legalcals-key: lc_your_key_here

{
  "topic": "rent-increase",
  "jurisdiction": "bc",
  "scenario": "Proposed rent increase of 5% with 30 days notice."
}

Every response includes rate-limit headers so you can throttle client-side:

X-RateLimit-Limit: 60
X-RateLimit-Remaining: 42
X-RateLimit-Reset: 1714500000

Endpoints

Intelligence

POST
/api/v1/intelligence

Jurisdiction summary with citations and freshness warnings

Reasoning

POST
/api/v1/reasoning

Scenario analysis, compliance path, and outcome reasoning

Checklist

POST
/api/v1/checklist

Generate compliance checklists for a scenario

Risk

POST
/api/v1/risk

Structural, procedural, documentation, and overall risk scores

Heatmap

POST
/api/v1/heatmap

National compliance heatmap across all jurisdictions

Similarity

POST
/api/v1/similarity/matrix

Pairwise jurisdiction similarity vectors

POST
/api/v1/similarity/clusters

K-means clustering of jurisdictions

Trends

POST
/api/v1/trends/jurisdiction

Historical trend analysis for one jurisdiction

POST
/api/v1/trends/national

National trend report with volatility rankings

Forecast

POST
/api/v1/forecast/jurisdiction

Predicted risk levels for a jurisdiction

POST
/api/v1/forecast/national

National forecast with confidence and trend direction

Reports

POST
/api/v1/reports/quarterly

Quarterly regulatory intelligence report

POST
/api/v1/reports/annual

Annual year-over-year regulatory report

Topics

GET
/api/v1/topics

List all topics with coverage metadata

GET
/api/v1/topics/{topic}/coverage

Placeholder vs real rule coverage

Code Examples

JavaScript

const res = await fetch("https://legalcals.com/api/v1/risk", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "x-legalcals-key": "lc_your_key_here",
  },
  body: JSON.stringify({
    topic: "rent-increase",
    jurisdiction: "bc",
    scenario: "Proposed rent increase of 5% with 30 days notice.",
  }),
});
const data = await res.json();
console.log(data.data.overallRisk);

Python

import requests

res = requests.post(
    "https://legalcals.com/api/v1/risk",
    headers={
        "Content-Type": "application/json",
        "x-legalcals-key": "lc_your_key_here",
    },
    json={
        "topic": "rent-increase",
        "jurisdiction": "bc",
        "scenario": "Proposed rent increase of 5% with 30 days notice.",
    },
)
data = res.json()
print(data["data"]["overallRisk"])

cURL

curl -X POST https://legalcals.com/api/v1/risk \
  -H "Content-Type: application/json" \
  -H "x-legalcals-key: lc_your_key_here" \
  -d '{"topic":"rent-increase","jurisdiction":"bc","scenario":"Proposed rent increase of 5% with 30 days notice."}'

SDK Downloads

Auto-generated SDKs from the OpenAPI specification. Install or copy directly into your project.

JavaScript / TypeScript

sdk/js/index.ts

Download OpenAPI Spec
Python

sdk/python/legalcals.py

Download OpenAPI Spec

OpenAPI Specification

The complete v1 API is documented in OpenAPI 3.0.3 format. Use it to generate clients in any language, import into Postman, or serve with Swagger UI.

openapi: 3.0.3
info:
  title: LegalCals Enterprise API
  version: "1.0.0"
servers:
  - url: https://legalcals.com/api/v1
security:
  - ApiKeyAuth: []
paths:
  /intelligence:
    post:
      operationId: getIntelligence
      ...
View Full Spec

Ready to build?

Get your free API key in seconds and start querying regulatory intelligence at scale.