---
title: "Search collections"
method: GET
path: "/collections/search"
---

# Search collections

`GET /collections/search`

## Query parameters

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

## Response `200`

A list of collections.

- object
  - `ok` boolean
  - `results` SearchResult[]
    - `snippet` string — The text snippet that is relevant to the query.
    - `url` string — The url of the document you can use as source.
    - `sourceId` string
    - `source` 'web' | 'upload'
    - `collection` Collection
      - `id` string
      - `slug` string
      - `userId` string
      - `active` boolean
      - `createdAt` integer
      - `updatedAt` integer
      - `name` string
      - `description` string
      - `image` string
      - `privacy` 'public' | 'private' | 'team'
      - `namespace` string
      - `sources` Source[] — unresolved $ref
      - `status` string
    - `score` number — The relevance score of the result between 0 and 1. Higher is better.

---

[API](https://skmtc.net/openindex/apis/openindex-ai-api.md) · [All operations](https://skmtc.net/openindex/apis/openindex-ai-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/openindex/openindex-ai-api/revisions/c3a8b22ba407/schema)
