Skip to main content
Glama

search_contact_people

Find people by name in Offorte Proposal Software contacts to locate team members or stakeholders for proposal collaboration.

Instructions

Search for people by name in the contacts

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
searchYes

Implementation Reference

  • Full implementation of the search_contact_people tool, including the name, input parameters schema, annotations, and the execute handler function that queries the API endpoint `/contacts/people/?query={search}`, parses with contactPeopleListSchema, and returns JSON string of results.
    export const searchContactPeopleTool: Tool<typeof parameters._type, typeof parameters> = { name: 'search_contact_people', description: `Search for people by name in the contacts`, parameters, annotations: { title: 'Search Contact People', openWorldHint: true, }, async execute({ search }) { const result = await get(`/contacts/people/?query=${encodeURIComponent(search)}`); const parsed = contactPeopleListSchema.safeParse(result); if (!parsed.success) { throwApiInvalidResponseError(parsed.error); } return JSON.stringify(parsed.data); }, };
  • Zod schemas defining the structure of person or organisation contacts (personOrOrganisationSchema) and the list schema (contactPeopleListSchema) used to validate the API response in the tool handler.
    const personOrOrganisationSchema = z .object({ id: z.number(), contact_id: optionalId, type: contactType, account_user_id: optionalId, account_user_name: z.string().optional(), organisation: z.string(), date_created: z.string(), proposals_open: z.number().optional(), proposals_won: z.number().optional(), ...addressFields, ...socialFields, ...contactFields, firstname: z.string(), lastname: z.string(), fullname: z.string(), salutation: z.string(), }) .passthrough(); export const contactPeopleListSchema = z.array(personOrOrganisationSchema);
  • The registerTools function registers all tools to the FastMCP server instance. The searchContactPeopleTool is imported on line 12 and added to the tools array on line 30.
    export function registerTools({ server }: { server: FastMCP }) { (tools as unknown as FastMCPTool<Record<string, unknown>, ToolParameters>[]).map(initialContextGuard).forEach((tool) => server.addTool(tool)); }
  • Inclusion of searchContactPeopleTool in the array of tools to be registered.
    searchContactPeopleTool,
  • Import of the searchContactPeopleTool for registration.
    import { searchContactPeopleTool } from './contacts/search-contact-people.js';

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/offorte/offorte-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server