> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stateset.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Semantic search over the knowledge base

> Matches

### Request body

`object`

<ParamField body="question" type="string" required />

<ParamField body="top_k" type="integer" />

### Response

`object`

<ResponseField name="object" type="string" />

<ResponseField name="data" type="object[]" />

<ResponseField name="has_more" type="boolean" />

<ResponseField name="next_cursor" type="string">
  Keyset cursor for the next page — present only on cursor-capable lists with more rows.
</ResponseField>

### Status codes

| Code  | Meaning                                                 |
| ----- | ------------------------------------------------------- |
| `200` | Matches                                                 |
| `400` | Invalid request. `issues` names the offending field(s). |
| `401` | Missing, invalid, or expired API key.                   |
| `403` | The key lacks a required scope.                         |
| `429` | Rate limit exceeded.                                    |

### Access

|                |                        |
| -------------- | ---------------------- |
| Required scope | `knowledge:read`       |
| Rate limit     | 10 requests per minute |

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url 'https://response.stateset.com/api/v1/knowledge/search' \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
    "question": "string",
    "top_k": 1
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "object": "list",
    "data": [
      {}
    ],
    "has_more": true,
    "next_cursor": "string"
  }
  ```
</ResponseExample>
