---
title: "Content search across books"
method: GET
path: "/v1/content-search"
tags: ["V1"]
---

# Content search across books

`GET /v1/content-search`

Perform a text or vector search across books. Optionally filter by specific book IDs and version IDs.

## Query parameters

- `q` string, required
- `type` 'text' | 'vector', required
- `books` string
- `include_chapters` 'true' | 'false'
- `include_details` 'true' | 'false'
- `page` integer
- `limit` integer

## Response `200`

Content search results retrieved successfully

- V1SearchResponse
  - `total` integer, required — Total number of matching results
  - `totalPages` integer, required — Total number of pages
  - `perPage` integer, required — Results per page
  - `currentPage` integer, required — Current page number
  - `hasNextPage` boolean, required — Whether there is a next page
  - `hasPreviousPage` boolean, required — Whether there is a previous page
  - `results` V1SearchResult[], required
    - `score` number — Relevance score of the result
    - `versionId` string — The version ID of the matched book
    - `node` object
      - `text` string — The matched text content (omitted when highlights are present for text search)
      - `highlights` object[] — Highlighted text snippets (only present for text search results)
      - `metadata` object
        - `bookId` string — The ID of the book
        - `page` integer — Page number in the book
        - `vol` string — Volume number
        - `chapters` object[] — Chapter information (only present when include_chapters=true)
    - `book` object — Book details (only present when include_details=true)
      - `id` string
      - `slug` string
      - `primaryName` string
      - `secondaryName` string
      - `author` object
        - `id` string
        - `slug` string
        - `primaryName` string
        - `secondaryName` string
        - `year` integer

---

[API](https://skmtc.dev/usul/apis/usul-api.md) · [All operations](https://skmtc.dev/usul/apis/usul-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/usul/usul-api/revisions/b4f2df3e5842/schema)
