From e909eccb1f5e4f26bedfe420bd425a64040f449b Mon Sep 17 00:00:00 2001 From: "mintlify-development[bot]" <109878554+mintlify-development[bot]@users.noreply.github.com> Date: Wed, 25 Feb 2026 22:00:47 +0000 Subject: [PATCH] Add currentPath parameter to assistant API docs Generated-By: mintlify-agent --- api/assistant/create-assistant-message-v2.mdx | 2 ++ api/assistant/create-assistant-message.mdx | 2 ++ discovery-openapi.json | 8 ++++++++ 3 files changed, 12 insertions(+) diff --git a/api/assistant/create-assistant-message-v2.mdx b/api/assistant/create-assistant-message-v2.mdx index 06c7bf7a2..abf710da5 100644 --- a/api/assistant/create-assistant-message-v2.mdx +++ b/api/assistant/create-assistant-message-v2.mdx @@ -49,6 +49,7 @@ function MyComponent({ domain }) { body: { fp: "anonymous", retrievalPageSize: 5, + currentPath: "/guides/getting-started", context: [ { type: "code", @@ -96,6 +97,7 @@ function MyComponent({ domain }) { **Optional configuration:** +- `body.currentPath` - The path of the page the user is currently viewing (e.g., `/guides/getting-started`). When provided, the assistant uses this context to provide more relevant answers. - `body.context` - Array of contextual information to provide to the assistant. Each context object contains: - `type` - Either `'code'` or `'textSelection'`. - `value` - The code snippet or selected text content. diff --git a/api/assistant/create-assistant-message.mdx b/api/assistant/create-assistant-message.mdx index d679dd584..204a96818 100644 --- a/api/assistant/create-assistant-message.mdx +++ b/api/assistant/create-assistant-message.mdx @@ -35,6 +35,7 @@ function MyComponent({ domain }) { body: { fp: 'anonymous', retrievalPageSize: 5, + currentPath: '/guides/getting-started', context: [ { type: 'code', @@ -71,6 +72,7 @@ function MyComponent({ domain }) { - `body.retrievalPageSize` - Number of search results to use (recommended: 5). **Optional configuration:** +- `body.currentPath` - The path of the page the user is currently viewing (e.g., `/guides/getting-started`). When provided, the assistant uses this context to provide more relevant answers. - `body.context` - Array of contextual information to provide to the assistant. Each context object contains: - `type` - Either `'code'` or `'textSelection'`. - `value` - The code snippet or selected text content. diff --git a/discovery-openapi.json b/discovery-openapi.json index 0dd00212b..aeef37ff6 100644 --- a/discovery-openapi.json +++ b/discovery-openapi.json @@ -394,6 +394,10 @@ } }, "description": "Optional filter criteria for the search." + }, + "currentPath": { + "type": "string", + "description": "The path of the page the user is currently viewing. When provided, the assistant includes this context in its system prompt, allowing it to provide more relevant answers based on the user's location in the documentation. Maximum 200 characters." } } } @@ -678,6 +682,10 @@ ] }, "description": "Optional array of contextual information to provide to the assistant." + }, + "currentPath": { + "type": "string", + "description": "The path of the page the user is currently viewing. When provided, the assistant includes this context in its system prompt, allowing it to provide more relevant answers based on the user's location in the documentation. Maximum 200 characters." } } }