search_donors
Search FEC filings for individual donors by name, employer, or occupation to track donor patterns and identify industry contributions.
Instructions
Search for individual donors across all FEC filings by name, employer, or occupation. Essential for tracking donor patterns, identifying industry contributions, or researching specific individuals' political giving. Supports searching by employer (e.g., "Goldman Sachs") or occupation (e.g., "Lobbyist", "Government Affairs").
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| contributor_name | No | Donor name to search for (partial match supported) | |
| contributor_employer | No | Employer name to search for (e.g., "Google", "Goldman Sachs") | |
| contributor_occupation | No | Occupation to search for (e.g., "Attorney", "Government Affairs", "Lobbyist") | |
| contributor_state | No | Two-letter state code to filter by (e.g., "CA", "NY") | |
| min_amount | No | Minimum contribution amount to include | |
| cycle | No | Two-year election cycle (e.g., 2024) | |
| limit | No | Maximum number of results to return (default: 20) |
Implementation Reference
- Zod input schema (searchDonorsInputSchema) defining all parameters with descriptions, and searchDonorsParamsSchema with a superRefine ensuring at least one search criterion is provided (contributor_name, contributor_employer, or contributor_occupation).
export const searchDonorsInputSchema = { contributor_name: z .string() .optional() .describe('Donor name to search for (partial match supported)'), contributor_employer: z .string() .optional() .describe('Employer name to search for (e.g., "Google", "Goldman Sachs")'), contributor_occupation: z .string() .optional() .describe('Occupation to search for (e.g., "Attorney", "Government Affairs", "Lobbyist")'), contributor_state: z .string() .length(2) .optional() .describe('Two-letter state code to filter by (e.g., "CA", "NY")'), min_amount: z .number() .min(0) .optional() .describe('Minimum contribution amount to include'), cycle: z .number() .int() .min(2000) .max(2030) .optional() .describe('Two-year election cycle (e.g., 2024)'), limit: z .number() .int() .min(1) .max(100) .optional() .describe('Maximum number of results to return (default: 20)'), }; export const searchDonorsParamsSchema = z .object(searchDonorsInputSchema) .superRefine((value, ctx) => { if ( !value.contributor_name && !value.contributor_employer && !value.contributor_occupation ) { ctx.addIssue({ code: z.ZodIssueCode.custom, message: 'Please provide at least one search criterion: contributor_name, contributor_employer, or contributor_occupation.', }); } }); export type SearchDonorsInput = z.infer<typeof searchDonorsParamsSchema>; - src/api/client.ts:363-375 (helper)FECClient.searchDonors() method - the API client helper that calls the FEC Schedule A endpoint with contributor filters, sorting by amount descending, and limiting to individual donors (is_individual=true).
async searchDonors(params: SearchDonorsParams, timeout?: number): Promise<FECApiResponse<FECScheduleA>> { return this.get<FECScheduleA>(ENDPOINTS.SCHEDULE_A, { contributor_name: params.contributor_name, contributor_employer: params.contributor_employer, contributor_occupation: params.contributor_occupation, contributor_state: params.contributor_state, min_amount: params.min_amount, two_year_transaction_period: params.two_year_transaction_period, is_individual: true, // Only search individual donors sort: '-contribution_receipt_amount', per_page: params.limit || DEFAULT_PER_PAGE, }, timeout); }