tdx-kb-search
Search knowledge base articles in TeamDynamix (TDX) using text queries and filters to find solutions for IT service management issues.
Instructions
Search TDX knowledge base articles
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| appId | No | TDX app ID (defaults to env TDX_APP_ID) | |
| searchText | No | Full-text search query | |
| categoryIds | No | Filter by category IDs | |
| status | No | Filter by status (0=None, 1=Draft, 2=Approved, 3=Archived) | |
| ownerUids | No | Filter by owner UIDs | |
| maxResults | No | Max results to return (default 25) |
Implementation Reference
- src/tools/kb.ts:109-135 (handler)The handler implementation for the `tdx-kb-search` tool, which searches TDX knowledge base articles by posting to the `/{app}/knowledgebase/search` endpoint.
server.tool( "tdx-kb-search", "Search TDX knowledge base articles", { appId: z.number().optional().describe("TDX app ID (defaults to env TDX_APP_ID)"), searchText: z.string().optional().describe("Full-text search query"), categoryIds: z.array(z.number()).optional().describe("Filter by category IDs"), status: z.number().optional().describe("Filter by status (0=None, 1=Draft, 2=Approved, 3=Archived)"), ownerUids: z.array(z.string()).optional().describe("Filter by owner UIDs"), maxResults: z.number().optional().describe("Max results to return (default 25)"), }, async (params) => { const app = params.appId ?? defaultAppId; const body: Record<string, unknown> = {}; if (params.searchText !== undefined) body.SearchText = params.searchText; if (params.categoryIds !== undefined) body.CategoryIDs = params.categoryIds; if (params.status !== undefined) body.Status = params.status; if (params.ownerUids !== undefined) body.OwnerUids = params.ownerUids; if (params.maxResults !== undefined) body.MaxResults = params.maxResults; try { const result = await client.post(`/${app}/knowledgebase/search`, body); return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] }; } catch (e: unknown) { return { content: [{ type: "text", text: String(e) }], isError: true }; } } );