---
title: "Ask Question Agentic"
method: POST
path: "/api/businesses/{business_id}/ask/agentic"
tags: ["Businesses"]
---

# Ask Question Agentic

`POST /api/businesses/{business_id}/ask/agentic`

## Request

- Base URL: `https://api.flagpost.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.flagpost.ai/api/businesses/{business_id}/ask/agentic`
- Auth: HTTP bearer

Ask a question using the agentic tool-calling loop.

The LLM decides which tools to call and in what order:
insights, manifests, sub-LLM document selection, file loading, etc.

## Path parameters

- `business_id` string, required

## Request body

- AskRequest: Request model for asking a question.
  - `question` string, required
  - `conversation_history` ConversationMessage[]
    - `role` string, required
    - `content` string, required
  - `session_id` string, nullable

## Response `200`

Successful Response

- AgenticAskResponse: Response model for agentic Q&A.
  - `answer` string, required
  - `reasoning` string
  - `sources_cited` SourceRef[]
    - `file_name` string, required
    - `document_id` string, nullable
    - `chunk` string, nullable
    - `page` integer, nullable
    - `page_id` string, nullable
    - `sheet` string, nullable
    - `source_locator` object, nullable
    - `citation` integer, nullable
  - `sources_searched` SourceRef[]
    - `file_name` string, required
    - `document_id` string, nullable
    - `chunk` string, nullable
    - `page` integer, nullable
    - `page_id` string, nullable
    - `sheet` string, nullable
    - `source_locator` object, nullable
    - `citation` integer, nullable
  - `files_retrieved` integer, required
  - `confidence` string, required
  - `agentic` boolean
  - `turns` integer
  - `session_id` string, nullable

## Other responses

- `422`: Validation Error

---

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