---
title: "Answer question"
method: POST
path: "/search/answer"
tags: ["gateway"]
---

# Answer question

`POST /search/answer`

## Request

- Base URL: `https://www.dench.com/api/v1`
- URL: `https://www.dench.com/api/v1/search/answer`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

Answer a question with web search.

## Request body

- object
  - `query` string, required: Question to answer with web search.
  - `text` boolean
  - `stream` boolean
  - `outputSchema` object

## Response `200`

Successful response

- object: An answer with citations. With stream: true the response is text/event-stream instead.
  - `answer` string, required
  - `citations` object[]
    - `url` string, required
    - `title` string
    - `publishedDate` string
    - `author` string
    - `score` number
    - `text` string
    - `summary` string
    - `highlights` string[]
    - `image` string
    - `favicon` string
    - `id` string
    - `entities` object[]: Structured entity metadata returned by category=people or category=company.

## Other responses

- `400`: Invalid request
- `401`: Missing or invalid authentication
- `404`: Operation or resource not found
- `500`: Server error

---

[API](https://skmtc.dev/dench/apis/dench-api.md) - [All operations](https://skmtc.dev/dench/apis/dench-api/llms.txt) - [OpenAPI document](https://skmtc.dev/dench/apis/dench-api/revisions/4a145b38f19c?raw)
