Getting started
The Dockase API is a REST API over https://api.dockase.com. It speaks JSON, versioned under /v1. Create an account at /signup — your first API key is issued instantly — and you can make your first call in under a minute. Keys, usage, and billing all live in your developer dashboard right here on this site.
Authentication
Every request needs an API key in the Authorization header. Keys are prefixed dk_ and are created at /signup and revoked or regenerated from your dashboard. Keep keys server-side — never ship them in a browser or mobile client.
Authorization: Bearer dk_live_...Response envelope
Every successful response wraps its payload in data, with request metadata in meta. All responses are sent with Cache-Control: no-store.
{
"data": { "..." : "..." },
"meta": {
"request_id": "req_9u2h1k",
"plan": "PRO"
}
}Errors
Errors are Stripe-style: a single error object with a machine-readable type and a human-readable message.
{
"error": {
"type": "rate_limited",
"message": "Rate limit exceeded: 30 requests per minute on the FREE plan."
}
}| Field | Type | Description |
|---|---|---|
400 | invalid_request | Malformed JSON, missing required fields, or invalid parameters. |
401 | authentication_error | Missing, revoked, or invalid API key. |
403 | tier_required | The resource requires a higher plan (e.g. full_text on FREE). |
404 | not_found | No judgment, statute, or resource with that ID. |
429 | rate_limited | Per-minute rate limit exceeded. Back off and retry. |
500 | api_error | Something went wrong on our side. Retry with the request_id if it persists. |
Rate limits
Limits are per API key, per minute. Every response carries X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset (Unix timestamp for the next window).
| Field | Type | Description |
|---|---|---|
FREE | 30 req/min | 1,000 calls/month. Snippet-length judgment text. |
PRO | 120 req/min | 20,000 calls/month. Full judgment text. |
ENTERPRISE | 600 req/min | 100,000 calls/month. Full judgment text, priority support. |
/v1/judgments/searchNigeriaSearch judgments
Semantic search over 13,000+ Nigerian judgments. Send a natural-language description of the legal issue; get back ranked authorities with citations, ratios, and relevance scores.
curl https://api.dockase.com/v1/judgments/search \
-H "Authorization: Bearer dk_live_..." \
-H "Content-Type: application/json" \
-d '{
"query": "locus standi in election petitions",
"limit": 5,
"court_level": "SC",
"year_from": 2015
}'Request body
| Field | Type | Description |
|---|---|---|
queryrequired | string | Natural-language legal question or fact pattern. Semantic — describe the issue, not just keywords. |
limit | integer | Max results to return. Default 10, maximum 20. |
court_level | string | Filter by court level, e.g. "SC" (Supreme Court), "CA" (Court of Appeal), "HC" (High Courts). |
year_from | integer | Only judgments delivered on or after this year. |
year_to | integer | Only judgments delivered on or before this year. |
Response
data is an array of judgment results, ranked by relevance:
| Field | Type | Description |
|---|---|---|
id | string | Stable judgment identifier (jd_...). |
case_name | string | Party names as reported. |
citation | string | AELR citation with court suffix, e.g. "(2023) 12 AELR 45 (SC)". |
court | string | Court that delivered the judgment. |
judgment_date | string | ISO 8601 date (YYYY-MM-DD). |
ratio | string | The ratio decidendi — the binding legal principle of the decision. |
summary | string | Editorial summary of the facts and holding. |
authority_score | number | 0–1. How authoritative this judgment is, from court level and subsequent treatment. |
confidence | number | 0–1. Relevance confidence for this result against your query. |
snippet | string | FREE plan: a ~300-character excerpt around the most relevant passage. |
full_text | string | PRO and ENTERPRISE: the complete judgment text. Replaces snippet. |
{
"data": [
{
"id": "jd_8f3k2m1x",
"case_name": "Adeyemi v. INEC",
"citation": "(2023) 12 AELR 45 (SC)",
"court": "Supreme Court",
"judgment_date": "2023-09-14",
"ratio": "A petitioner who seeks to nullify an election must show that the alleged non-compliance substantially affected the result...",
"summary": "The Supreme Court restated the test for locus standi in election petitions and held that...",
"authority_score": 0.94,
"confidence": 0.98,
"snippet": "...the question of locus standi is a threshold issue that goes to the jurisdiction of the tribunal..."
}
],
"meta": {
"request_id": "req_9u2h1k",
"plan": "FREE"
}
}snippet (~300 characters). On PRO and ENTERPRISE, results include the complete full_text instead./v1/judgments/{id}NigeriaGet a judgment
Fetch a single judgment by ID. Same shape as a search result, with the same plan-based text tiering.
curl https://api.dockase.com/v1/judgments/jd_8f3k2m1x \
-H "Authorization: Bearer dk_live_..."Response
data is a single judgment object with the fields listed under Search judgments.
snippet. PRO and ENTERPRISE return full_text. Tiering never fails the request — FREE simply returns the snippet shape rather than an error./v1/judgments/{id}/citationsNigeriaCitation graph
The citation neighbourhood of a judgment: everything it cites, and everything that cites it. Each edge carries a treatment — followed, considered, distinguished, or overruled — with a confidence score and the passage it was extracted from.
curl https://api.dockase.com/v1/judgments/jd_8f3k2m1x/citations \
-H "Authorization: Bearer dk_live_..."Response
data.cites and data.cited_by are arrays of edges:
| Field | Type | Description |
|---|---|---|
id | string | Judgment identifier for the related case. |
case_name | string | Party names of the related case. |
citation | string | AELR citation of the related case. |
treatment | string | One of followed, considered, distinguished, overruled. |
confidence | number | 0–1. Confidence in the treatment classification. |
context_snippet | string | The passage in which the citation and treatment appear. |
{
"data": {
"id": "jd_8f3k2m1x",
"cites": [
{
"id": "jd_2p9q4r7w",
"case_name": "Okafor v. Attorney-General of Lagos State",
"citation": "(2019) 4 AELR 112 (SC)",
"treatment": "followed",
"confidence": 0.97,
"context_snippet": "...as this Court held in Okafor v. A-G Lagos State, the threshold question of standing must be resolved..."
}
],
"cited_by": [
{
"id": "jd_5t8y1u3i",
"case_name": "Bello v. Zamfara State Electoral Commission",
"citation": "(2025) 2 AELR 88 (CA)",
"treatment": "distinguished",
"confidence": 0.91,
"context_snippet": "...the facts before us differ materially from Adeyemi v. INEC, and we accordingly distinguish..."
}
]
},
"meta": {
"request_id": "req_3f7j0a",
"plan": "PRO"
}
}cited_by for overruled treatments before relying on an authority — that is the whole point./v1/citations/verifyNigeriaVerify a citation
Check whether a citation or case name exists in the record. Built for the anti-hallucination workflow: run every authority an LLM drafts through this endpoint before it reaches a brief, an opinion, or a filing.
curl https://api.dockase.com/v1/citations/verify \
-H "Authorization: Bearer dk_live_..." \
-H "Content-Type: application/json" \
-d '{"citation": "(2023) 12 AELR 45 (SC)"}'Request body
| Field | Type | Description |
|---|---|---|
citation | string | An AELR-style citation, e.g. "(2023) 12 AELR 45 (SC)". At least one of citation or case_name is required. |
case_name | string | Party names, e.g. "Adeyemi v. INEC". At least one of citation or case_name is required. |
Response
| Field | Type | Description |
|---|---|---|
status | string | VERIFIED when a matching judgment exists; NOT_VERIFIED otherwise. |
matched | object | null | The matched judgment (id, case_name, citation, court, judgment_date), or null when status is NOT_VERIFIED. |
{
"data": {
"status": "VERIFIED",
"matched": {
"id": "jd_8f3k2m1x",
"case_name": "Adeyemi v. INEC",
"citation": "(2023) 12 AELR 45 (SC)",
"court": "Supreme Court",
"judgment_date": "2023-09-14"
}
},
"meta": {
"request_id": "req_6m1z8q",
"plan": "PRO"
}
}/v1/statutesNigeriaList statutes
Nigerian statutes as structured records. Filter by category and jurisdiction (federal or a state).
curl "https://api.dockase.com/v1/statutes?category=electoral&jurisdiction=federal" \
-H "Authorization: Bearer dk_live_..."Query parameters
| Field | Type | Description |
|---|---|---|
category | string | Subject category, e.g. electoral, criminal, corporate, land. |
jurisdiction | string | federal or a state name, e.g. lagos. |
{
"data": [
{
"id": "st_electoral_act_2022",
"title": "Electoral Act, 2022",
"category": "electoral",
"jurisdiction": "federal",
"year": 2022,
"updated_at": "2026-08-30"
}
],
"meta": {
"request_id": "req_1x4v7n",
"plan": "FREE"
}
}/v1/statutes/{id}NigeriaGet a statute
The full statute, formatted as clean markdown — headings, sections, and subsections preserved. Ready to render or index.
curl https://api.dockase.com/v1/statutes/st_electoral_act_2022 \
-H "Authorization: Bearer dk_live_..."{
"data": {
"id": "st_electoral_act_2022",
"title": "Electoral Act, 2022",
"category": "electoral",
"jurisdiction": "federal",
"year": 2022,
"updated_at": "2026-08-30",
"body_markdown": "# Electoral Act, 2022\n\n## Part I – Establishment and Functions of INEC\n\n**1.** (1) The Independent National Electoral Commission..."
},
"meta": {
"request_id": "req_8b2c5d",
"plan": "FREE"
}
}/v1/embeddingsGlobalPro & Enterprise onlyEmbeddings
amicus-embed-ng-v1 is a legal-domain embedding model, trained on judgments, statutes, and legal commentary. It is a global primitive — use it to build retrieval over your own documents, contracts, briefs, or knowledge bases, in any jurisdiction. The request shape is OpenAI-compatible.
curl https://api.dockase.com/v1/embeddings \
-H "Authorization: Bearer dk_live_..." \
-H "Content-Type: application/json" \
-d '{
"model": "amicus-embed-ng-v1",
"input": "The ratio decidendi of the judgment concerns locus standi..."
}'Request body
| Field | Type | Description |
|---|---|---|
inputrequired | string | string[] | Text to embed. Pass an array to batch. |
modelrequired | string | Must be "amicus-embed-ng-v1". |
{
"data": {
"object": "list",
"data": [
{
"object": "embedding",
"index": 0,
"embedding": [0.0124, -0.0871, 0.0442, "..."]
}
],
"model": "amicus-embed-ng-v1",
"usage": {
"prompt_tokens": 14,
"total_tokens": 14
}
},
"meta": {
"request_id": "req_5k9p2t",
"plan": "PRO"
}
}402 payment_required — the error body points you to /dashboard to upgrade. Embeddings are token-metered: included usage comes from your plan's monthly call allowance; overage is billed per million tokens — $0.25/1M on PRO, $0.20/1M on ENTERPRISE.