> ## 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`

**question** `string` *required*

Maximum length: `10000`.

**top\_k** `integer`

Default: `5`. Minimum: `1`. Maximum: `100`.

### Response

`object`

**object** `string`

Allowed values: `'list'`.

**data** `object[]`

**has\_more** `boolean`

**next\_cursor** `string`

Keyset cursor for the next page — present only on cursor-capable lists with more rows.

### 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 |

### Using this contract

Read the [source OpenAPI document](https://docs.stateset.com/spec/responsecx.json) for declared schemas and alternatives.
This page also includes documented corrections from the [spec overlays](https://github.com/stateset/docs/tree/main/spec/overlays).
Example IDs and values are illustrative; replace them with records from your workspace.

```bash cURL theme={null}
curl --silent --show-error --fail-with-body --request POST \
  --url 'https://response.stateset.com/api/v1/knowledge/search' \
  --header "Authorization: Bearer $RESPONSECX_API_KEY" \
  --header 'Content-Type: application/json' \
  --data '{
  "question": "string",
  "top_k": 5
}'
```

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


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.