create_kb_doc
Add one knowledge base source (VG agents). For many page URLs use create_kb_from_urls instead. For websites: sourceType=url with urls[] + scrapeContent=true (KB router scrapes). For whole-site: sourceType=sitemap + sitemapUrl + maxPages + scrapeContent=true. sourceType=doc only for raw text you already have — do not paste web-fetched HTML here.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"agentId": "<agentId>",
"name": "<name>",
"sourceType": "<sourceType>"
},
"name": "create_kb_doc"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Document name | |
| tags | No | Tags for organization | |
| urls | No | Array of URLs (for sourceType: url). Prefer create_kb_from_urls for many pages. | |
| agentId | Yes | The agent ID | |
| content | No | Document content (required for sourceType: doc) | |
| maxPages | No | Max pages from sitemap | |
| metadata | No | Additional metadata | |
| sitemapUrl | No | Sitemap URL (for sourceType: sitemap) | |
| sourceType | Yes | doc = text; url = KB router scrape urls[]; sitemap = crawl sitemap | |
| refreshRate | No | Auto re-crawl for URL/sitemap (API: 3d | 7d | never). Default never. | |
| scrapeContent | No | Let KB router scrape URLs/sitemap (set true for url/sitemap) |