get_politician_interests
Retrieve declared interests and mandates for Swiss parliament members, including board memberships, consulting roles, and organizational affiliations.
Instructions
Get declared interests and mandates of a Swiss parliament member — board memberships, consulting roles, organizations.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| person_id | Yes | OpenParlData person ID (get from get_parliament_members results) |
Implementation Reference
- src/modules/parliament.ts:515-541 (handler)The `getPoliticianInterests` function fetches and parses interests of a Swiss parliament member from OpenParlData.
async function getPoliticianInterests(args: { person_id: number; }): Promise<string> { const url = buildUrl(`/persons/${args.person_id}/interests`, { lang: "de", lang_format: "flat", }); const resp = await apiFetch<InterestRecord>(url); const interests = resp.data.map((i) => ({ id: i.id, name: i.name_de, type: i.type_de, role: i.role_name_de, payment: i.type_payment_de, category: i.group_de, url: i.url, })); return truncate( JSON.stringify({ count: interests.length, personId: args.person_id, interests, }) ); } - src/modules/parliament.ts:154-168 (schema)The input schema definition for the `get_politician_interests` tool.
name: "get_politician_interests", description: "Get declared interests and mandates of a Swiss parliament member — board memberships, consulting roles, organizations.", inputSchema: { type: "object" as const, required: ["person_id"], properties: { person_id: { type: "number", description: "OpenParlData person ID (get from get_parliament_members results)", }, }, }, }, - src/modules/parliament.ts:692-693 (registration)The tool registration and dispatch logic for `get_politician_interests` in the `handleParliament` function.
case "get_politician_interests": return getPoliticianInterests(args as { person_id: number });