---
title: "Download the knowledgebase."
method: GET
path: "/knowledgebases/{kbId}/{environment}/qna"
tags: ["Knowledgebases"]
---

# Download the knowledgebase.

`GET /knowledgebases/{kbId}/{environment}/qna`

## Path parameters

- `kbId` string, required
- `environment` 'Prod' | 'Test', required

## Query parameters

- `source` string
- `changedSince` string

## Response `200`

Collection of all Q-A in the knowledgebase.

- QnADocumentsDTO — List of QnADTO
  - `qnaDocuments` QnADTO[] — List of answers.
    - `id` integer — Unique id for the Q-A.
    - `answer` string, required — Answer text
    - `source` string — Source from which Q-A was indexed. eg. https://docs.microsoft.com/en-us/azure/cognitive-services/QnAMaker/FAQs
    - `questions` string[], required — List of questions associated with the answer.
    - `metadata` MetadataDTO[] — List of metadata associated with the answer.
      - `name` string, required — Metadata name.
      - `value` string, required — Metadata value.
    - `context` ContextDTO — Context associated with Qna.
      - `isContextOnly` boolean — To mark if a prompt is relevant only with a previous question or not. true - Do not include this QnA as search result for queries without context false - ignores context and includes this QnA in search result
      - `prompts` PromptDTO[] — List of prompts associated with the answer.
        - `displayOrder` integer — Index of the prompt - used in ordering of the prompts
        - `qnaId` integer — Qna id corresponding to the prompt - if QnaId is present, QnADTO object is ignored.
        - `qna` QnADTO — recursive
        - `displayText` string — Text displayed to represent a follow up question prompt

## Other responses

- `default` — Error response.

---

[API](https://skmtc.net/azure/apis/qnamaker-client.md) · [All operations](https://skmtc.net/azure/apis/qnamaker-client/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/azure/qnamaker-client/versions/75b50ce22fbe/schema)
