---
slug: "api/filings-content-search"
eyebrow: "API · Filings"
title: "Semantic content search (RAG)"
description: "Semantic search across the full text of SEC and Nordic filings with the Clarifo Data API: cited passages with page_id for retrieval-augmented generation."
lastModified: "2026-11-05"
---

<EndpointHeader method="POST" path="/api/v1/data/filings/content-search" />

Returns the most relevant passages from filings ranked by vector similarity
to the query. Each result includes an excerpt of the page text, the source
filing (`docid`), a ready-made citation, and a `page_id` you can resolve
to cite the original PDF or EDGAR page.

## When to use this

- "What does Neste say about renewable-diesel capacity in 2024?"
- "Find any mention of supply-chain risk in Nokia's 2023 annual report."
- "Show me Apple's dividend policy language."

This is the right tool whenever the answer **lives in prose** rather than
in a financial line item.

<Callout tone="warning" title="Unscoped searches cover Nordic filings only">
  US filings are stored per company. Without a `company` (and without a
  company name the server can detect in the query text), the search runs
  across Nordic filings only. To search US filings, set `company` or name
  the company in the query.
</Callout>

<ParamTable
  title="Body"
  params={[
    { name: "query", type: "string", required: true, description: "Natural-language search query, in any major language." },
    { name: "company", type: "string", description: "Optionally restrict to a specific company (name or ticker)." },
    { name: "year", type: "integer", description: "Optionally restrict to a specific fiscal year." },
    { name: "quarter", type: "integer", description: "Optionally restrict to a fiscal quarter (1–4). The quarter field is not populated for every filing, so use it only for questions about one interim report." },
    { name: "document_type", type: "string", description: "annual_report | interim_report | stock_exchange_release | 10-K | 10-Q | 8-K. Related types are matched too (annual_report also matches 10-K and 20-F)." },
    { name: "topic_tags", type: "string[]", description: "Restrict to pages tagged with any of these topics, e.g. [\"leases\", \"goodwill\", \"risks_uncertainty\"]. Unknown tags are ignored and reported back." },
    { name: "ifrs_tags", type: "string[]", description: "Restrict to pages tagged with any of these standards, e.g. [\"IFRS 16\", \"IAS 36\"]. Nordic filings only; skipped on US searches." },
    { name: "auto_detect_tags", type: "boolean", defaultValue: "true", description: "When no tags are passed, detect them from the query text and apply them. Set false for a pure vector search." },
    { name: "limit", type: "integer", defaultValue: "5", description: "Number of passages to return (1–20)." },
  ]}
/>

## Example

<CodeGroup
  samples={[
    {
      label: "curl",
      language: "bash",
      code: `curl https://api.clarifo.com/api/v1/data/filings/content-search \\\n  -H "Authorization: Bearer $CLARIFO_API_KEY" \\\n  -H "Content-Type: application/json" \\\n  -d '{\n    "query": "renewable diesel production capacity 2024",\n    "company": "Neste",\n    "document_type": "annual_report",\n    "limit": 3\n  }'`,
    },
    {
      label: "Python",
      language: "python",
      code: `hits = httpx.post(\n    "https://api.clarifo.com/api/v1/data/filings/content-search",\n    headers={"Authorization": f"Bearer {KEY}"},\n    json={\n        "query": "renewable diesel production capacity 2024",\n        "company": "Neste",\n        "document_type": "annual_report",\n        "limit": 3,\n    },\n).json()\nfor h in hits["results"]:\n    print(h["score"], h["content_title"])`,
    },
  ]}
/>

## Response

```json
{
  "results": [
    {
      "company_name": "Neste Oyj",
      "year": "2023",
      "period": "FY2023",
      "document_title": "Neste Oyj 2023 Annual Report",
      "document_type": "annual_report",
      "content": "Renewable Products segment produced 3.3 million tonnes…",
      "content_title": "Renewable Products",
      "docid": "722df34e9f191a97518a8560755cb9e9",
      "page_id": "722df34e9f191a97518a8560755cb9e9_20",
      "page_number": 20,
      "page_number_kind": "pdf_render",
      "page_reference": "p. 20",
      "page_reference_type": "page",
      "source_url": "https://…",
      "citation_label": "Neste Oyj 2023 Annual Report (FY2023), p. 20",
      "citation_markdown": "[Neste Oyj 2023 Annual Report (FY2023), p. 20](https://…)",
      "evidence_type": "filing_passage",
      "supports": "direct",
      "confidence": "high",
      "evidence": {"excerpt": "…", "source_kind": "s3_pdf", "…": "…"},
      "score": 0.8921
    }
  ],
  "sources": [
    {"id": "src_1", "page_id": "722df34e9f191a97518a8560755cb9e9_20", "citation_markdown": "…", "…": "…"}
  ],
  "source_policy": {
    "citation_mode": "claim_level",
    "require_excerpt": true,
    "require_page_number": true,
    "require_source_url": true,
    "max_sources_per_claim": 3,
    "display": {"user_facing_citation": "citation_markdown", "…": "…"}
  },
  "total": 1,
  "has_more": false,
  "query": "renewable diesel production capacity 2024",
  "resolution": {"input_company": "Neste", "resolved_name": "Neste Oyj", "market": "nordic", "ticker": "NESTE"},
  "tag_filters": {"topic_tags": ["segment_performance"], "applied": true, "source": "auto_detected"}
}
```

## Response fields

| Field | Description |
|---|---|
| `results[].content` | Page text excerpt, up to 500 characters (1,500 for financial tables). Use [the snapshot endpoint](/docs/api/filings-snapshot) for the page itself. |
| `results[].citation_label`, `citation_markdown` | Ready-made citation. Show these to users instead of the raw `page_id`. |
| `results[].page_reference`, `page_reference_type` | Citation anchor: `"p. 20"` (`page`) for Nordic PDFs, a section heading such as `"Item 7. MD&A"` (`section`) for SEC filings, or the document type (`document`). |
| `results[].evidence` | Full evidence card for the hit (a longer `excerpt`, `source_kind`, `resource_uri`, ...). |
| `sources` | Deduplicated evidence cards, one per distinct page. |
| `source_policy` | How Clarifo expects citations to be rendered. |
| `has_more` | `true` when the result list filled `limit`, so more relevant passages may exist. |
| `resolution` | How `company` was resolved. |
| `tag_filters` | The topic/IFRS tag filter that was applied and whether it came from you (`caller`) or was auto-detected. `applied: false` means the tag filter matched nothing and the results come from an unfiltered retry. |
| `diagnostic` | Present when a company-scoped search returned no passages, with the reason. |
| `suggestion` | Present when a company name was detected in the query but `company` was not set. |

Empty fields are omitted rather than sent as `null`. If the search backend
fails, the response is HTTP 200 with `"error"`, `"failure_kind":
"search_upstream"` and an empty `results` list.

## Tips

- The query is **natural language** in any major language. A Finnish passage is retrievable with an English query and vice versa.
- Cap `limit` to what your downstream LLM context can handle. Five passages is usually enough.
- Combine with the filings search endpoint when you need a deterministic scope.
