---
title: "Word search over page-cited document text"
method: GET
path: "/v1/documents/search"
tags: ["Documents"]
---

# Word search over page-cited document text

`GET /v1/documents/search`

## Request

- Base URL: `https://api.openpublica.com`
- URL: `https://api.openpublica.com/v1/documents/search`
- Auth: none declared

`$text` matching, NOT semantic search. Retired and unreadable documents are not searchable, so an empty result is not evidence of absence — check the listing.

## Query parameters

- `q` string, required
- `government_id` string
- `limit` integer

## Response `200`

Page-cited excerpts

- object
  - `data` DocumentExcerpt[], required
    - `document_id` string
    - `government_id` string
    - `title` string
    - `text` string: A short passage around the match joined with `…`, not the whole page window.
    - `first_page` integer
    - `last_page` integer
    - `source_url` string, uri
    - `document_complete` boolean
  - `meta` object, required
    - `count` integer
    - `limit` integer

## Other responses

- `400`: Malformed or invalid parameters.
- `429`: Per-IP rate limit exceeded.
- `500`: Internal server error.

---

[API](https://skmtc.dev/openpublica/apis/openpublica-api.md) · [All operations](https://skmtc.dev/openpublica/apis/openpublica-api/llms.txt) · [OpenAPI document](https://skmtc.dev/openpublica/apis/openpublica-api/revisions/91a0635e7686?raw)
