---
title: "Search index"
method: POST
path: "/api/v3/search/{indexName}"
tags: ["Search"]
---

# Search index

`POST /api/v3/search/{indexName}`

Execute a search query against the specified index.
Note: annotation index requires admin privileges.

## Path parameters

- `indexName` 'encounter' | 'individual' | 'occurrence' | 'annotation' | 'sighting' | 'user', required

## Query parameters

- `from` integer
- `size` integer
- `sort` string
- `sortOrder` 'asc' | 'desc'

## Request body

- SearchQuery — OpenSearch/Elasticsearch query body

## Response `200`

Search results

- SearchResponse
  - `success` boolean
  - `searchQueryId` string, uuid
  - `hits` object[]
  - `query` SearchQuery — OpenSearch/Elasticsearch query body

## Other responses

- `401` — Authentication required or invalid session
- `403` — Forbidden (admin required for annotation index)
- `404` — Unknown index or invalid searchQueryId
- `405` — HTTP method not allowed for this endpoint
- `500` — Query execution failed

---

[API](https://skmtc.net/wildmeorg/apis/wildbook-v3-api.md) · [All operations](https://skmtc.net/wildmeorg/apis/wildbook-v3-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/wildmeorg/wildbook-v3-api/versions/cae3a14f7bed/schema)
