tdx-people-search
Search for people in TeamDynamix using filters like name, email, username, and status to find specific individuals in the system.
Instructions
Search TDX people with filters
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| searchText | No | Full-text search query | |
| lastName | No | Filter by last name | |
| firstName | No | Filter by first name | |
| primaryEmail | No | Filter by primary email | |
| userName | No | Filter by username | |
| isActive | No | Filter by active status | |
| isEmployee | No | Filter by employee status | |
| accountIds | No | Filter by account IDs | |
| maxResults | No | Max results to return (default 25) |
Implementation Reference
- src/tools/people.ts:22-54 (handler)The handler function that executes the search against the TDX /people/search endpoint.
server.tool( "tdx-people-search", "Search TDX people with filters", { searchText: z.string().optional().describe("Full-text search query"), lastName: z.string().optional().describe("Filter by last name"), firstName: z.string().optional().describe("Filter by first name"), primaryEmail: z.string().optional().describe("Filter by primary email"), userName: z.string().optional().describe("Filter by username"), isActive: z.boolean().optional().describe("Filter by active status"), isEmployee: z.boolean().optional().describe("Filter by employee status"), accountIds: z.array(z.number()).optional().describe("Filter by account IDs"), maxResults: z.number().optional().describe("Max results to return (default 25)"), }, async (params) => { const body: Record<string, unknown> = {}; if (params.searchText !== undefined) body.SearchText = params.searchText; if (params.lastName !== undefined) body.LastName = params.lastName; if (params.firstName !== undefined) body.FirstName = params.firstName; if (params.primaryEmail !== undefined) body.PrimaryEmail = params.primaryEmail; if (params.userName !== undefined) body.UserName = params.userName; if (params.isActive !== undefined) body.IsActive = params.isActive; if (params.isEmployee !== undefined) body.IsEmployee = params.isEmployee; if (params.accountIds !== undefined) body.AccountIDs = params.accountIds; if (params.maxResults !== undefined) body.MaxResults = params.maxResults; try { const result = await client.post("/people/search", body); return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] }; } catch (e: unknown) { return { content: [{ type: "text", text: String(e) }], isError: true }; } } );