{ "mode": "hybrid", "results": [ { "node_id": "65f3a1b2c3d4e5f6a7b8c9d3", "title": "Política de devolución", "snippet": "Las devoluciones se aceptan dentro de los 10 días posteriores a la compra...", "score": 0.873, "source": "vector" }, { "node_id": "65f3a1b2c3d4e5f6a7b8c9d4", "title": "Cancelación de suscripciones", "snippet": "Para cancelar tu suscripción, ingresa a Mi cuenta > Suscripciones...", "score": 0.612, "source": "full" } ]}
Field
Type
Description
mode
string
Mode applied (same as in the request).
results[].node_id
string
ObjectId of the document in the knowledge base. Useful for cross-referencing with GET /v1/knowledge/tree.
results[].title
string
Document title (no full content).
results[].snippet
string
Fragment of the highest-scoring chunk, truncated to ~320 characters.
results[].score
number
Normalized score. The scale depends on the mode: in vector and hybrid it’s in [0,1]; in full it’s the raw Mongo textScore. Only comparable between items in the same response.
results[].source
string
vector or full, depending on which engine produced the top-scoring match (in hybrid it indicates which one won after combination).
400 BAD_REQUEST: query empty, mode not supported, or node_ids with invalid format.
403 FORBIDDEN with code: INSUFFICIENT_SCOPE: the PAT doesn’t have knowledge:query.
If you’re going to feed the results to an external LLM (RAG), prefer hybrid with top_k=5 as a starting point. It’s the setup that best balances recall (vector) with precision on exact terms (full-text).
{"docsConfig":{"theme":"almond","$schema":"https://mintlify.com/docs.json","name":"KeebAI","colors":{"primary":"#0A0A0A","light":"#47BBF5","dark":"#47BBF5"},"logo":{"light":"https://mintcdn.com/keebai/4fPpSJudv6COSabU/logo/light.svg?fit=max\u0026auto=format\u0026n=4fPpSJudv6COSabU\u0026q=85\u0026s=e9d57c894f15d41b379236cde0e91b72","dark":"https://mintcdn.com/keebai/4fPpSJudv6COSabU/logo/dark.svg?fit=max\u0026auto=format\u0026n=4fPpSJudv6COSabU\u0026q=85\u0026s=6c8eb0f812de19aa554c329a2d98729c"},"favicon":"https://mintcdn.com/keebai/4fPpSJudv6COSabU/favicon.svg?fit=max\u0026auto=format\u0026n=4fPpSJudv6COSabU\u0026q=85\u0026s=c946f52626818858ed67d6ab203e67f2","api":{"openapi":"https://api.keebai.com/v1/docs-json","playground":{"display":"interactive"},"examples":{"prefill":true}},"appearance":{"default":"dark"},"navbar":{"links":[{"href":"https://status.keebai.com","label":"Status"},{"href":"mailto:support@keebai.com","label":"Support"}],"primary":{"type":"button","label":"Open Keebai","href":"https://app.keebai.com"}},"footer":{"socials":{"x":"https://x.com/keebai","linkedin":"https://linkedin.com/company/keebai","github":"https://github.com/keebai"}},"fonts":{"family":"Inter"},"styling":{"eyebrows":"breadcrumbs","codeblocks":"system","latex":false},"contextual":{"options":["copy"],"display":"header"},"interaction":{"drilldown":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"keebai","hasAudioNarration":false,"actualSubdomain":"keebai","customDomains":["docs.keebai.com"],"gitSource":{"type":"github","owner":"keebai-ai","repo":"docs","deployBranch":"main","isPrivate":false,"contentDirectory":"","mountPath":"","label":""},"feedback":{"thumbs":true,"edits":true,"issues":true},"entitlements":{},"buildId":"6af52f991cc64d85fee5cef8","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"default","tag":"Agents","count":49},{"language":"default","tag":"Messaging","count":29},{"language":"default","tag":"CRM","count":24},{"language":"default","tag":"Guides","count":17},{"language":"default","tag":"Ecommerce","count":17},{"language":"default","tag":"Loyalty","count":14},{"language":"default","tag":"Scheduling","count":14},{"language":"default","tag":"Get started","count":12},{"language":"default","tag":"Agent tests","count":7},{"language":"default","tag":"WhatsApp Flows","count":7}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"#navbar div:has(>div>.nav-tabs){position:static}@media (min-width: 1024px){#navbar .nav-tabs{position:absolute;top:0;left:50%;transform:translateX(-50%);height:3.5rem}}"}],"page":{"pagePath":"dev/endpoints/knowledge-search","slug":"/dev/endpoints/knowledge-search","pageMetadata":{"title":"POST /v1/knowledge/search","sidebarTitle":"POST search","description":"Search the knowledge base by full-text, vector, or hybrid.","openapi":"POST /v1/knowledge/search","href":"/dev/endpoints/knowledge-search"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Search the knowledge base by full-text, vector, or hybrid.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,CodeGroup,Heading,Table,Tip}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!CodeGroup)_missingMdxReference(`CodeGroup`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Tip)_missingMdxReference(`Tip`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Runs a query over the indexed chunks of the knowledge base. Supports three search modes — pick the one that best fits the user’s query:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Mode`}),_jsx(_components.th,{children:`When to use it`}),_jsx(_components.th,{children:`How it works internally`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`full`})}),_jsx(_components.td,{children:`Exact terms, keywords, numbers, IDs.`}),_jsxs(_components.td,{children:[`MongoDB text index over `,_jsx(_components.code,{children:`page_content`}),` with Spanish stemming.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`vector`})}),_jsx(_components.td,{children:`Natural language questions, synonyms, paraphrasing.`}),_jsxs(_components.td,{children:[`MongoDB Atlas Vector Search with `,_jsx(_components.code,{children:`text-embedding-3-small`}),` embeddings.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`hybrid`})}),_jsx(_components.td,{children:`Sensible default when you don’t know what kind of query is coming.`}),_jsx(_components.td,{children:`Runs both in parallel, normalizes scores, and combines them with a 0.6 vector / 0.4 full-text weight.`})]})]})]}),`\n`,_jsxs(_components.p,{children:[`Results are grouped by `,_jsx(_components.code,{children:`node_id`}),` (the same document appears only once even if several chunks match) and sorted by descending score.`]}),`\n`,_jsx(Heading,{level:`2`,id:`endpoint`,children:`Endpoint`}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`POST https://api.keebai.com/v1/knowledge/search`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(Heading,{level:`2`,id:`required-scope`,children:`Required scope`}),`\n`,_jsx(_components.p,{children:_jsx(_components.code,{children:`knowledge:query`})}),`\n`,_jsx(Heading,{level:`2`,id:`headers`,children:`Headers`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Header`}),_jsx(_components.th,{children:`Required`}),_jsx(_components.th,{children:`Value`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Authorization`})}),_jsx(_components.td,{children:`Yes`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Bearer kbai_pk_\u003ctoken>`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Content-Type`})}),_jsx(_components.td,{children:`Yes`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`application/json`})})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`body`,children:`Body`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Field`}),_jsx(_components.th,{children:`Type`}),_jsx(_components.th,{children:`Required`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`query`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string`})}),_jsx(_components.td,{children:`Yes`}),_jsx(_components.td,{children:`Search text.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`mode`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string`})}),_jsx(_components.td,{children:`Yes`}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`full`}),`, `,_jsx(_components.code,{children:`vector`}),`, or `,_jsx(_components.code,{children:`hybrid`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`top_k`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`number`})}),_jsx(_components.td,{children:`No`}),_jsxs(_components.td,{children:[`Max number of results, between 1 and 25. Default `,_jsx(_components.code,{children:`5`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`node_ids`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string[]`})}),_jsx(_components.td,{children:`No`}),_jsxs(_components.td,{children:[`Restrict the search to these `,_jsx(_components.code,{children:`node_id`}),` values (folders or documents). Useful to scope to a domain within the tree. Max 100 ids.`]})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`example-request`,children:`Example request`}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`curl`,numberOfLines:`8`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`8`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.keebai.com/v1/knowledge/search`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer kbai_pk_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -d`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` '{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"query\": \"¿cómo cancelar mi suscripción?\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"mode\": \"hybrid\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"top_k\": 3`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`JavaScript`,numberOfLines:`13`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`13`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` resp`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` fetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://api.keebai.com/v1/knowledge/search\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` method:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"POST\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` headers:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` Authorization:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" `Bearer \"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`process`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`KEEBAI_API_TOKEN`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\"`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"application/json\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` body:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` JSON`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`stringify`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` query:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"¿cómo cancelar mi suscripción?\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` mode:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"hybrid\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` top_k:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 3`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }),`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`results`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` resp`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`json`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`Python`,numberOfLines:`17`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`17`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` os, requests`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`resp `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` requests.post(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"https://api.keebai.com/v1/knowledge/search\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` headers`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`f`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Bearer `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`{`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`os.environ[`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'KEEBAI_API_TOKEN'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"application/json\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` json`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"query\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"¿cómo cancelar mi suscripción?\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"mode\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"hybrid\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"top_k\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`3`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` timeout`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`15`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`resp.raise_for_status()`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`results `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` resp.json()[`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"results\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`]})})})]}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(Heading,{level:`3`,id:`200-ok`,children:`200 OK`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`19`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`19`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"mode\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"hybrid\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"results\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"node_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"65f3a1b2c3d4e5f6a7b8c9d3\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"title\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Política de devolución\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"snippet\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Las devoluciones se aceptan dentro de los 10 días posteriores a la compra...\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"score\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0.873`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"source\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"vector\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"node_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"65f3a1b2c3d4e5f6a7b8c9d4\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"title\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Cancelación de suscripciones\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"snippet\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Para cancelar tu suscripción, ingresa a Mi cuenta > Suscripciones...\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"score\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0.612`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"source\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"full\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Field`}),_jsx(_components.th,{children:`Type`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`mode`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string`})}),_jsx(_components.td,{children:`Mode applied (same as in the request).`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`results[].node_id`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`ObjectId`}),` of the document in the knowledge base. Useful for cross-referencing with `,_jsx(_components.a,{href:`/dev/endpoints/knowledge-tree`,children:_jsx(_components.code,{children:`GET /v1/knowledge/tree`})}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`results[].title`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string`})}),_jsx(_components.td,{children:`Document title (no full content).`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`results[].snippet`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string`})}),_jsx(_components.td,{children:`Fragment of the highest-scoring chunk, truncated to ~320 characters.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`results[].score`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`number`})}),_jsxs(_components.td,{children:[`Normalized score. The scale depends on the mode: in `,_jsx(_components.code,{children:`vector`}),` and `,_jsx(_components.code,{children:`hybrid`}),` it’s in [0,1]; in `,_jsx(_components.code,{children:`full`}),` it’s the raw Mongo `,_jsx(_components.code,{children:`textScore`}),`. Only comparable between items in the same response.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`results[].source`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`string`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`vector`}),` or `,_jsx(_components.code,{children:`full`}),`, depending on which engine produced the top-scoring match (in `,_jsx(_components.code,{children:`hybrid`}),` it indicates which one won after combination).`]})]})]})]}),`\n`,_jsx(Heading,{level:`3`,id:`400-/-401-/-403-/-429`,children:`400 / 401 / 403 / 429`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`400 BAD_REQUEST`}),`: `,_jsx(_components.code,{children:`query`}),` empty, `,_jsx(_components.code,{children:`mode`}),` not supported, or `,_jsx(_components.code,{children:`node_ids`}),` with invalid format.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`403 FORBIDDEN`}),` with `,_jsx(_components.code,{children:`code: INSUFFICIENT_SCOPE`}),`: the PAT doesn’t have `,_jsx(_components.code,{children:`knowledge:query`}),`.`]}),`\n`]}),`\n`,_jsx(Tip,{children:_jsxs(_components.p,{children:[`If you’re going to feed the results to an external LLM (RAG), prefer `,_jsx(_components.code,{children:`hybrid`}),` with `,_jsx(_components.code,{children:`top_k=5`}),` as a starting point. It’s the setup that best balances recall (vector) with precision on exact terms (full-text).`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"system","config":{},"pageMetadata":{"title":"POST /v1/knowledge/search","sidebarTitle":"POST search","description":"Search the knowledge base by full-text, vector, or hybrid.","openapi":"POST /v1/knowledge/search","href":"/dev/endpoints/knowledge-search"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Endpoint","slug":"endpoint","depth":2,"children":[]},{"title":"Required scope","slug":"required-scope","depth":2,"children":[]},{"title":"Headers","slug":"headers","depth":2,"children":[]},{"title":"Body","slug":"body","depth":2,"children":[]},{"title":"Example request","slug":"example-request","depth":2,"children":[]},{"title":"Response","slug":"response","depth":2,"children":[{"title":"200 OK","slug":"200-ok","depth":3,"children":[]},{"title":"400 / 401 / 403 / 429","slug":"400-/-401-/-403-/-429","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"operationId":"PublicKnowledgeController_search","parameters":[],"requestBody":"0a68ceba-6c5e-4460-920c-a8b04709792e","responses":{"200":"aeeddfea-dfee-43db-8517-3dffdfde1f85"},"security":["5acf3ea0-ddc9-47eb-98f2-929269198b76"],"summary":"Buscar en la base de conocimientos por full-text, vector o híbrido.","tags":["knowledge"],"method":"post","type":"path","servers":["d9585507-49d1-4ff3-9466-9dd0bab3a7d3"],"path":"/v1/knowledge/search","baseUrlOptions":["https://api.keebai.com"],"title":"Buscar en la base de conocimientos por full-text, vector o híbrido.","description":"Search the knowledge base by full-text, vector, or hybrid.","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated","prefillPlaygroundWithExample":true,"prefillPlaygroundExamples":[{"body.query":"¿cómo cancelar suscripción?","body.mode":"hybrid","body.top_k":5,"body.node_ids.items.0":"\u003cstring>"}]},"dependencies":{"parameters":{},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"query":{"type":"string","description":"Texto de búsqueda.","example":"¿cómo cancelar suscripción?","isRequired":true,"uniqueKey":"query","typeLabel":"string"},"mode":{"type":"string","description":"Modo de búsqueda: full (full-text), vector (semántica) o hybrid (combinación con re-ranking).","enum":["full","hybrid","vector"],"example":"hybrid","isRequired":true,"uniqueKey":"mode","typeLabel":"enum\u003cstring>"},"top_k":{"type":"number","description":"Cantidad máxima de resultados (1-25).","example":5,"default":5,"uniqueKey":"top_k","typeLabel":"number"},"node_ids":{"description":"Limita la búsqueda a estos node ids (carpetas o documentos).","type":"array","items":{"type":"string","uniqueKey":"node_ids.items.[INDEX]","typeLabel":"string"},"uniqueKey":"node_ids","typeLabel":"string[]"}},"required":["query","mode"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"query":"¿cómo cancelar suscripción?","mode":"hybrid","top_k":5,"node_ids":["\u003cstring>"]}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"aeeddfea-dfee-43db-8517-3dffdfde1f85":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"mode":{"type":"string","enum":["full","hybrid","vector"],"isRequired":true,"uniqueKey":"mode","typeLabel":"enum\u003cstring>"},"results":{"type":"array","items":{"type":"object","properties":{"node_id":{"type":"string","isRequired":true,"uniqueKey":"results.items.[INDEX].node_id","typeLabel":"string"},"score":{"type":"number","isRequired":true,"uniqueKey":"results.items.[INDEX].score","typeLabel":"number"},"source":{"type":"string","enum":["full","vector"],"isRequired":true,"uniqueKey":"results.items.[INDEX].source","typeLabel":"enum\u003cstring>"},"title":{"type":"string","uniqueKey":"results.items.[INDEX].title","typeLabel":"string"},"snippet":{"type":"string","uniqueKey":"results.items.[INDEX].snippet","typeLabel":"string"}},"required":["node_id","score","source"],"uniqueKey":"results.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"results","typeLabel":"object[]"}},"required":["mode","results"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"mode":"full","results":[{"node_id":"\u003cstring>","score":123,"source":"full","title":"\u003cstring>","snippet":"\u003cstring>"}]}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"5acf3ea0-ddc9-47eb-98f2-929269198b76":{"PAT":{"scheme":"bearer","bearerFormat":"kbai_pk_\u003chex>","type":"http","description":"Personal Access Token con prefijo `kbai_pk_`. Generar desde el portal con permiso `developer.manage_tokens`.","scopes":[],"schemeName":"PAT"}}},"servers":{"d9585507-49d1-4ff3-9466-9dd0bab3a7d3":{"url":"https://api.keebai.com","description":"Production"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"scheme":"bearer","bearerFormat":"kbai_pk_\u003chex>","type":"http","description":"Personal Access Token con prefijo `kbai_pk_`. Generar desde el portal con permiso `developer.manage_tokens`.","scopes":[],"schemeName":"PAT"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Personal Access Token con prefijo `kbai_pk_`. Generar desde el portal con permiso `developer.manage_tokens`.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"PAT","name":"Authorization"}],"title":"PAT"}]},"originalFileLocation":"https://api.keebai.com/v1/docs-json"},"subdomain":"keebai","siteName":"KeebAI","title":"POST /v1/knowledge/search - KeebAI","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-08-10T17:16:34.341Z","originalFileLocation":"dev/endpoints/knowledge-search.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Search the knowledge base by full-text, vector, or hybrid.\">\u003cmeta data-mint-head name=\"application-name\" content=\"KeebAI\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"POST /v1/knowledge/search - KeebAI\">\u003cmeta data-mint-head property=\"og:description\" content=\"Search the knowledge base by full-text, vector, or hybrid.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"KeebAI\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.keebai.com/dev/endpoints/knowledge-search\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://keebai.mintlify.site/_mintlify/api/og/v2?division=Knowledge+base\u0026amp;title=POST+%2Fv1%2Fknowledge%2Fsearch\u0026amp;description=Search+the+knowledge+base+by+full-text%2C+vector%2C+or+hybrid.\u0026amp;theme=5f8ef6626ccce718ef8625d0\u0026amp;signature=3dd9ec2858ceead9176406a7fcfaa2051882e0cdbb6b370a1a9e9dcd17dcc78a\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"POST /v1/knowledge/search - KeebAI\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Search the knowledge base by full-text, vector, or hybrid.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://keebai.mintlify.site/_mintlify/api/og/v2?division=Knowledge+base\u0026amp;title=POST+%2Fv1%2Fknowledge%2Fsearch\u0026amp;description=Search+the+knowledge+base+by+full-text%2C+vector%2C+or+hybrid.\u0026amp;theme=5f8ef6626ccce718ef8625d0\u0026amp;signature=3dd9ec2858ceead9176406a7fcfaa2051882e0cdbb6b370a1a9e9dcd17dcc78a\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/keebai/kihrOc7IVMcbU56A/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"KeebAI\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#0A0A0A\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.keebai.com/dev/endpoints/knowledge-search\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/dev/endpoints/knowledge-search.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.keebai.com/#organization\",\"name\":\"KeebAI\",\"url\":\"https://docs.keebai.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/keebai/4fPpSJudv6COSabU/logo/light.svg?fit=max\u0026auto=format\u0026n=4fPpSJudv6COSabU\u0026q=85\u0026s=e9d57c894f15d41b379236cde0e91b72\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.keebai.com#website\",\"name\":\"KeebAI\",\"url\":\"https://docs.keebai.com\",\"publisher\":{\"@id\":\"https://docs.keebai.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.keebai.com/dev/endpoints/knowledge-search#webpage\",\"url\":\"https://docs.keebai.com/dev/endpoints/knowledge-search\",\"name\":\"POST /v1/knowledge/search\",\"description\":\"Search the knowledge base by full-text, vector, or hybrid.\",\"dateModified\":\"2026-08-10T17:16:34.341Z\",\"isPartOf\":{\"@id\":\"https://docs.keebai.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.keebai.com/dev/endpoints/knowledge-search#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.keebai.com/dev/endpoints/knowledge-search#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Knowledge base\",\"item\":\"https://docs.keebai.com/dev/endpoints/knowledge-tree\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"POST /v1/knowledge/search\",\"item\":\"https://docs.keebai.com/dev/endpoints/knowledge-search\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.keebai.com/dev/endpoints/knowledge-search#apireference\",\"headline\":\"POST /v1/knowledge/search\",\"name\":\"POST /v1/knowledge/search\",\"description\":\"Search the knowledge base by full-text, vector, or hybrid.\",\"url\":\"https://docs.keebai.com/dev/endpoints/knowledge-search\",\"mainEntityOfPage\":{\"@id\":\"https://docs.keebai.com/dev/endpoints/knowledge-search#webpage\"},\"dateModified\":\"2026-08-10T17:16:34.341Z\",\"publisher\":{\"@id\":\"https://docs.keebai.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.keebai.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"KeebAI\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"KeebAI\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/dev/endpoints/knowledge-search.md","siteName":"KeebAI","nav":{"global":null,"tabs":[{"tab":"Guides","icon":"book-open","pages":[{"title":"Guides","href":""}]},{"tab":"Messaging","icon":"paper-plane","pages":[{"title":"Messaging","href":"/dev/messaging/overview"}]},{"tab":"Knowledge","icon":"book-bookmark","groups":[{"group":"Get started","pages":[{"title":"Knowledge overview","sidebarTitle":"Overview","href":"/dev/knowledge/overview"}]},{"group":"Knowledge base","pages":[{"title":"GET /v1/knowledge/tree","sidebarTitle":"GET tree","openapi":"GET /v1/knowledge/tree","href":"/dev/endpoints/knowledge-tree"},{"title":"POST /v1/knowledge/folders","sidebarTitle":"POST folder","openapi":"POST /v1/knowledge/folders","href":"/dev/endpoints/knowledge-folder-create"},{"title":"POST /v1/knowledge/documents","sidebarTitle":"POST document","openapi":"POST /v1/knowledge/documents","href":"/dev/endpoints/knowledge-document-create"},{"title":"DELETE /v1/knowledge/nodes/:id","sidebarTitle":"DELETE node","description":"Delete a node (folder or document). If it's a folder, all of its descendants are deleted too.","openapi":"DELETE /v1/knowledge/nodes/{id}","href":"/dev/endpoints/knowledge-node-delete"},{"title":"POST /v1/knowledge/search","sidebarTitle":"POST search","openapi":"POST /v1/knowledge/search","href":"/dev/endpoints/knowledge-search"},{"title":"POST /v1/knowledge/assignments","sidebarTitle":"POST assign","description":"Assign knowledge base nodes to all of an agent's workers.","openapi":"POST /v1/knowledge/assignments","href":"/dev/endpoints/knowledge-assign"}]}]},{"tab":"CRM","icon":"address-book","pages":[{"title":"CRM","href":"/dev/crm/overview"}]},{"tab":"Scheduling","icon":"calendar-check","pages":[{"title":"Scheduling","href":"/dev/scheduling/overview"}]},{"tab":"Ecommerce","icon":"cart-shopping","pages":[{"title":"Ecommerce","href":"/dev/ecommerce/overview"}]},{"tab":"Loyalty","icon":"wallet","pages":[{"title":"Loyalty","href":"/dev/loyalty/overview"}]},{"tab":"Agents","icon":"robot","pages":[{"title":"Agents","href":"/dev/agents/overview"}]},{"tab":"Webhooks","icon":"bell","pages":[{"title":"Webhooks","href":"/dev/webhooks/overview"}]}]},"basePath":"","title":"POST /v1/knowledge/search - KeebAI","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":["c2aa737661","b0f84f53ff","a9bb46feb3","2b790eda92"],"chunks":["OpenApiReferenceProvider-CybtLBIt.js","utils-BMLj2fvV.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-B6In562Y.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-Dr8Mfhp9.js","snippetPresets-2rmQvMVl.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","Page-C4GwDT3_.js","ApiExamples-WMqJYdZj.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-CJ-MlPHu.js","shallow-dY3TMRCk.js","getApiPlaygroundDisplay-v-1B2bKm.js","CodeSnippet-BDhiTB7U.js","CodeSnippets-D9hnzQcS.js","getPastedJson-Th2V45jI.js","icon-BQXch1W9.js","MethodPill-BCqUneP3.js","DuplicateIcon-Q_-bhurZ.js","createIcon-DUjLHRqp.js","DynamicMarkdown-B-f2cqXQ.js","SectionHeading-Da5NsV4v.js","axios-vUo_bRtp.js","Markdown-D13FWkIM.js","clsx-D3Isdib3.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-C-XZBk9h.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink--qIqmmVG.js"]}