---
title: "POST /assistants/{assistantId}/query"
method: POST
path: "/assistants/{assistantId}/query"
deprecated: true
---

# POST /assistants/{assistantId}/query

`POST /assistants/{assistantId}/query`

> **Deprecated.**

Performs a manual search against the specified assistant. To retrieve recommendations for an assistant, use <a href="https://docs.aws.amazon.com/wisdom/latest/APIReference/API_GetRecommendations.html">GetRecommendations</a>.

## Path parameters

- `assistantId` string, required

## Request body

- object
  - `maxResults` integer — The maximum number of results to return per page.
  - `nextToken` string — The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
  - `queryText` string, password, required — The text to search for.

## Response `200`

Success

- QueryAssistantResponse
  - `nextToken` string — If there are additional results, this is the token for the next set of results.
  - `results` ResultData[], required — The results of the query.
    - `document` object, required — The document.
      - `contentReference` object, required — A reference to the content resource.
        - `contentArn` string — The Amazon Resource Name (ARN) of the content.
        - `contentId` string — The identifier of the content.
        - `knowledgeBaseArn` string — The Amazon Resource Name (ARN) of the knowledge base.
        - `knowledgeBaseId` string — The identifier of the knowledge base. This should not be a QUICK_RESPONSES type knowledge base if you're storing Wisdom Content resource to it.
      - `excerpt` object — The excerpt from the document.
        - `highlights` Highlight[] — Highlights in the document text.
          - `beginOffsetInclusive` integer — The offset for the start of the highlight.
          - `endOffsetExclusive` integer — The offset for the end of the highlight.
        - `text` string, password — Text in the document.
      - `title` object — The title of the document.
        - `highlights` Highlight[] — Highlights in the document text.
          - `beginOffsetInclusive` integer — The offset for the start of the highlight.
          - `endOffsetExclusive` integer — The offset for the end of the highlight.
        - `text` string, password — Text in the document.
    - `relevanceScore` number, double — The relevance score of the results.
    - `resultId` string, required — The identifier of the result data.

## Other responses

- `480` — RequestTimeoutException
- `481` — ValidationException
- `482` — AccessDeniedException
- `483` — ResourceNotFoundException

---

[API](https://skmtc.net/aws/apis/wisdom.md) · [All operations](https://skmtc.net/aws/apis/wisdom/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/wisdom/versions/4a596e60c7d1/schema)
