Search SEC Companies
search_sec_companiesSearch SEC-registered companies by name to retrieve CIK numbers, company names, and filing counts. Use the CIK to access company filings.
Instructions
Search for companies registered with the SEC by name. Returns CIK numbers, company names, and filing counts. Useful for finding a company's CIK before searching their filings.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| search | Yes | Company name to search for (at least 2 characters) |
Implementation Reference
- src/tools/sec.ts:158-198 (handler)The handler function for the 'search_sec_companies' tool. It takes a 'search' string input (min 2 chars), calls the Verilex API at /api/v1/sec/companies with the search parameter, and returns a formatted response listing matching SEC-registered companies with CIK numbers, names, and filing counts.
server.registerTool( "search_sec_companies", { title: "Search SEC Companies", description: "Search for companies registered with the SEC by name. Returns CIK numbers, " + "company names, and filing counts. Useful for finding a company's CIK before " + "searching their filings.", inputSchema: { search: z .string() .min(2) .describe("Company name to search for (at least 2 characters)"), }, }, async ({ search }) => { const res = await apiGet<SecCompaniesResponse>("/api/v1/sec/companies", { search, }); if (!res.ok) { return { content: [ { type: "text" as const, text: `API error (${res.status}): ${JSON.stringify(res.data)}`, }, ], isError: true, }; } const { count, data } = res.data; const summary = `Found ${count} compan${count === 1 ? "y" : "ies"}.`; const json = JSON.stringify(data, null, 2); return { content: [{ type: "text" as const, text: `${summary}\n\n${json}` }], }; }, ); - src/tools/sec.ts:166-172 (schema)Input schema for the search_sec_companies tool. Uses Zod validation requiring a string with at least 2 characters.
inputSchema: { search: z .string() .min(2) .describe("Company name to search for (at least 2 characters)"), }, }, - src/tools/sec.ts:25-29 (helper)TypeScript interface for the response from the SEC companies API endpoint, used as a generic type parameter in the apiGet call.
interface SecCompaniesResponse { dataset: string; count: number; data: Record<string, unknown>[]; } - src/index.ts:40-40 (registration)Registration of all SEC tools (including search_sec_companies) by calling registerSecTools(server) in the main server setup.
registerSecTools(server);