Skip to main content
Glama

extract_sec_filings

Fetch SEC 8-K filings to monitor material corporate events like CEO changes, acquisitions, data breaches, and regulatory actions for public companies using company names, tickers, or keywords.

Instructions

Fetch SEC 8-K filings for any public company from the SEC EDGAR full-text search API. 8-K filings are legally mandated disclosures of material corporate events — CEO changes, acquisitions, data breaches, major contracts, regulatory actions — filed within 4 business days. Free, no auth, real-time. Pass a company name, ticker, or keyword. Unique: not available in any other MCP server.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesCompany name, ticker, or keyword e.g. 'Palantir', 'PLTR', 'artificial intelligence'
max_lengthNo

Implementation Reference

  • The implementation of the 'secFilingsAdapter' function that acts as the handler for the 'extract_sec_filings' tool.
    export async function secFilingsAdapter(options: ExtractOptions): Promise<AdapterResult> {
      const query = (options.url ?? "").trim();
      const maxLength = options.maxLength ?? 6000;
    
      if (!query) throw new Error("Company name or keyword required");
    
      const data = await fetchSecFilings(query);
      return formatFilings(data, query, maxLength);
    }
  • src/server.ts:429-449 (registration)
    The registration of the 'extract_sec_filings' tool using 'server.registerTool' within 'src/server.ts'.
    server.registerTool(
      "extract_sec_filings",
      {
        description:
          "Fetch SEC 8-K filings for any public company from the SEC EDGAR full-text search API. 8-K filings are legally mandated disclosures of material corporate events — CEO changes, acquisitions, data breaches, major contracts, regulatory actions — filed within 4 business days. Free, no auth, real-time. Pass a company name, ticker, or keyword. Unique: not available in any other MCP server.",
        inputSchema: z.object({
          url: z.string().describe("Company name, ticker, or keyword e.g. 'Palantir', 'PLTR', 'artificial intelligence'"),
          max_length: z.number().optional().default(6000),
        }),
        annotations: { readOnlyHint: true, openWorldHint: true },
      },
      async ({ url, max_length }) => {
        try {
          const result = await secFilingsAdapter({ url, maxLength: max_length });
          const ctx = stampFreshness(result, { url, maxLength: max_length }, "sec_filings");
          return { content: [{ type: "text", text: formatForLLM(ctx) }] };
        } catch (err) {
          return { content: [{ type: "text", text: formatSecurityError(err) }] };
        }
      }
    );
  • The input schema definition for 'extract_sec_filings' tool, specifying 'url' and 'max_length' arguments.
    inputSchema: z.object({
      url: z.string().describe("Company name, ticker, or keyword e.g. 'Palantir', 'PLTR', 'artificial intelligence'"),
      max_length: z.number().optional().default(6000),
    }),

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/PrinceGabriel-lgtm/freshcontext-mcp'

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