Spreadsheet recipe

SEC API for Google Sheets

A self-serve Google Sheets Apps Script recipe for analysts and operators who want SEC filing watchlists in a spreadsheet without running a separate backend.

GET /v1/sec/watchlist/changes?tickers=AAPL,MSFT&since=2026-07-01&limit=10
const HOST = "https://sec-event-intelligence.p.rapidapi.com";

function SEC_FILINGS(tickers) {
  const key = PropertiesService
    .getScriptProperties()
    .getProperty("RAPIDAPI_KEY");
  if (!key) {
    throw new Error("Set RAPIDAPI_KEY in Apps Script project settings.");
  }

  const query = [
    ["tickers", tickers || "AAPL,MSFT"],
    ["since", "2026-07-01"],
    ["limit", "10"]
  ].map(([name, value]) => `${name}=${encodeURIComponent(value)}`).join("&");

  const response = UrlFetchApp.fetch(
    `${HOST}/v1/sec/watchlist/changes?${query}`,
    {
      headers: {
        "x-rapidapi-host": "sec-event-intelligence.p.rapidapi.com",
        "x-rapidapi-key": key
      },
      muteHttpExceptions: true
    }
  );

  if (response.getResponseCode() >= 300) {
    throw new Error(response.getContentText());
  }

  const payload = JSON.parse(response.getContentText());
  const rows = [["Ticker", "Form", "Filed At", "Company", "Accession"]];
  for (const group of payload.data) {
    for (const change of group.changes || []) {
      const filing = change.filing || {};
      rows.push([
        group.ticker,
        filing.form || "",
        filing.filedAt || "",
        filing.companyName || "",
        filing.accessionNo || ""
      ]);
    }
  }
  return rows;
}

Workflow Setup

This recipe validates whether buyers want SEC filing data inside automation tools before we build deeper app-specific support.

Endpoints Used

The integration uses live SEC Event Intelligence endpoints available through RapidAPI subscriptions.

Integration FAQ

Is this an official Google Sheets add-on?

No. It is a copy-ready Apps Script recipe that calls the RapidAPI endpoint from a spreadsheet.

Where should the RapidAPI key be stored?

Store it in Apps Script script properties and avoid putting the key directly in spreadsheet cells.

No investment advice. These recipes move public SEC filing metadata into automation tools. They do not provide recommendations, ratings, signals, or personalized financial guidance.