# SEC EDGAR API: Filings, Financials, Insider Trades (`fernandosord/sec-edgar-api`) Actor

Get SEC EDGAR data as clean rows: company profiles and filings, XBRL financials per fiscal year or quarter, Form 4 insider trades, 13F fund holdings, 10-K/10-Q sections as text, and alerts for new filings. Official sec.gov sources, no API key.

- **URL**: https://apify.com/fernandosord/sec-edgar-api.md
- **Developed by:** [Plainsource](https://apify.com/fernandosord) (community)
- **Categories:** Business, Developer tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 companies

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

SEC EDGAR API turns U.S. SEC EDGAR data into flat JSON rows: company profiles and filing lists, XBRL financial statements per fiscal year or quarter, Form 4 insider trading transactions, 13F fund holdings, the text of 10-K and 10-Q sections, and alerts for new filings. Everything comes from official sec.gov endpoints, and you do not need an SEC account or an API key.

You pick one `mode` and a few fields with defaults, so the Actor works the same way in the Apify Console, through the API, on a schedule, in Make, Zapier or n8n, and as a tool for AI agents through the Apify MCP server.

### What data can SEC EDGAR API extract?

| `mode` | Give it | One row per | Main fields | Source on sec.gov |
|---|---|---|---|---|
| `company` | tickers, CIKs or names | company | profile, SIC code, addresses, former names, latest filings with document links | `data.sec.gov/submissions` |
| `financials` | tickers | company and fiscal period | revenue, gross profit, operating income, net income, EPS, assets, liabilities, equity, cash, operating cash flow, capex, free cash flow, share counts, and the XBRL tag used for each value | `data.sec.gov/api/xbrl/companyfacts` |
| `insider-trades` | tickers, or nothing for the newest filings market-wide | Form 4 transaction | insider name and role, transaction code, shares, price, value, shares owned after, 10b5-1 flag, footnotes | Form 4 XML in the EDGAR archive |
| `13f-holdings` | fund manager names or CIKs | position in the 13F information table | issuer, CUSIP, shares, value, percent of portfolio, put or call, manager, report period | 13F XML in the EDGAR archive |
| `filing-text` | filing URLs, accession numbers, or tickers and form | document, or one 10-K or 10-Q Item | clean text, section name, length, truncation flag | the filing's main HTML document |
| `watch` | tickers and form types | filing that is new since the last run | form, filing date, 8-K items, document links | `data.sec.gov/submissions` |

Rows have a `recordType` field. Inputs that return nothing produce a free row with `recordType` `info` or `error` that says why, so a run never ends with an empty dataset and no explanation.

### How to use SEC EDGAR API

1. Open the Actor on Apify and click **Try for free**.
2. Choose **What to get** (`mode`). The default is the company profile and filings list.
3. Enter tickers, CIKs or names in **Companies or funds**. For 13F holdings, enter the fund managers. A name takes EDGAR company search's top match, so tickers or CIKs are safer.
4. Set the options for your mode, such as **Form types**, **Periods** or **Max holdings per fund**.
5. Click **Start** and read the rows from the dataset as JSON, CSV or Excel.
6. For recurring data, put the same input on a schedule. In `watch` mode, each run returns only the filings that earlier runs with the same `stateKey` have not returned.

### How much does the EDGAR API cost?

You pay per event.

| Event | Price |
|---|---|
| Actor start | $0.001 per GB of run memory (the default is 512 MB, so $0.001 per run) |
| Company row | $0.003 |
| Financial row (one fiscal period, or one raw XBRL fact) | $0.002 |
| Insider trade (one Form 4 transaction) | $0.001 |
| 13F holding (one position) | $0.0005 |
| Filing text (one document or one 10-K or 10-Q section) | $0.01 |
| New filing (watch mode) | $0.003 |

`info` and `error` rows are free, and so are watch-mode repeats.

Worked examples, from the prices above:

- The prefilled example, two company profiles: $0.001 + 2 x $0.003 = $0.007.
- Eight fiscal years of annual financials for one company: $0.001 + 8 x $0.002 = $0.017.
- 1,000 Form 4 insider transactions: $0.001 + 1,000 x $0.001 = $1.001.
- The top 100 positions of one 13F filing: $0.001 + 100 x $0.0005 = $0.051. A filing with 5,000 positions and `maxHoldings` set to 0: $2.501.
- The Risk Factors section of one 10-K: $0.001 + $0.01 = $0.011.

You can cap a run with the maximum cost setting. The run stops cleanly when it is reached.

### Input

The prefilled example, which returned two company profiles with their latest filings on 2026-10-28:

```json
{ "mode": "company", "companies": ["AAPL", "MSFT"], "formTypes": ["10-K", "10-Q", "8-K"] }
```

Other inputs, one per mode:

```json
{ "mode": "financials", "companies": ["NVDA"], "periodType": "annual", "maxPeriods": 1 }
{ "mode": "insider-trades", "companies": ["NVDA"], "maxFilings": 3, "transactionCodes": ["S"] }
{ "mode": "13f-holdings", "companies": ["Berkshire Hathaway"], "maxHoldings": 3 }
{ "mode": "filing-text", "companies": ["NVDA"], "formTypes": ["10-K"], "sections": ["1A"], "maxChars": 1000 }
{ "mode": "watch", "companies": ["NVDA", "TSLA"], "formTypes": ["8-K"], "stateKey": "my-watchlist" }
```

All fields:

| Field | Default | Used by |
|---|---|---|
| `mode` | `company` | all |
| `companies` | `[]` | all; tickers, CIKs or names |
| `formTypes` | `[]` | company, insider-trades (`4` and `4/A` when empty), filing-text (`10-K` when empty), watch (all forms when empty) |
| `dateFrom`, `dateTo` | empty | company, insider-trades for listed companies |
| `maxFilings` | 10 | company, insider-trades |
| `periodType` | `annual` | financials: `annual`, `quarterly` or `both` |
| `maxPeriods` | 8 | financials |
| `valueSource` | `as-reported` | financials: `as-reported` or `latest` |
| `rawTags` | `[]` | financials |
| `transactionCodes` | `[]` | insider-trades |
| `quarter` | empty (latest) | 13f-holdings |
| `maxHoldings` | 100 (0 = all) | 13f-holdings |
| `combineSameSecurity` | `true` | 13f-holdings |
| `filingUrls` | `[]` | filing-text |
| `sections` | `[]` (whole document) | filing-text |
| `maxChars` | 50000 | filing-text |
| `includeTables` | `true` | filing-text |
| `stateKey` | `default` | watch |
| `initialLookbackDays` | 7 | watch |

### Output

All rows below are real, from runs on 2026-10-28, with some fields left out to keep them short.

#### Company profile and filings

```json
{
  "recordType": "company",
  "input": "AAPL",
  "ticker": "AAPL",
  "cik": "0000320193",
  "companyName": "Apple Inc.",
  "exchanges": [
    "Nasdaq"
  ],
  "sic": "3571",
  "sicDescription": "Electronic Computers",
  "filerCategory": "Large accelerated filer",
  "stateOfIncorporation": "CA",
  "fiscalYearEnd": "09-26",
  "businessAddress": {
    "street1": "ONE APPLE PARK WAY",
    "street2": null,
    "city": "CUPERTINO",
    "stateOrCountry": "CA",
    "zipCode": "95014"
  },
  "filingsReturned": 10,
  "latestFilings": [
    {
      "form": "10-Q",
      "filingDate": "2026-07-31",
      "reportDate": "2026-06-27",
      "accessionNumber": "0000320193-26-000020",
      "description": "10-Q",
      "items": null,
      "filingUrl": "https://www.sec.gov/Archives/edgar/data/320193/000032019326000020/0000320193-26-000020-index.htm",
      "documentUrl": "https://www.sec.gov/Archives/edgar/data/320193/000032019326000020/aapl-20260627.htm"
    },
    {
      "form": "8-K",
      "filingDate": "2026-07-30",
      "reportDate": "2026-07-30",
      "accessionNumber": "0000320193-26-000018",
      "description": "8-K",
      "items": "2.02,9.01",
      "filingUrl": "https://www.sec.gov/Archives/edgar/data/320193/000032019326000018/0000320193-26-000018-index.htm",
      "documentUrl": "https://www.sec.gov/Archives/edgar/data/320193/000032019326000018/aapl-20260730.htm"
    }
  ]
}
```

`dateFrom` and `dateTo` narrow the filings list. `fiscalYearEnd` is month and day as the SEC stores it.

#### XBRL financials

```json
{
  "recordType": "financials",
  "input": "NVDA",
  "ticker": "NVDA",
  "cik": "0001045810",
  "companyName": "NVIDIA CORP",
  "periodType": "annual",
  "fiscalYear": 2026,
  "fiscalPeriod": "FY",
  "periodStart": "2025-01-27",
  "periodEnd": "2026-01-25",
  "currency": "USD",
  "form": "10-K",
  "filedDate": "2026-02-25",
  "accessionNumber": "0001045810-26-000021",
  "amendedBy": null,
  "revenue": 215938000000,
  "grossProfit": 153463000000,
  "operatingIncome": 130387000000,
  "netIncome": 120067000000,
  "epsBasic": 4.93,
  "epsDiluted": 4.9,
  "totalAssets": 206803000000,
  "totalLiabilities": 49510000000,
  "totalEquity": 157293000000,
  "cashAndEquivalents": 10605000000,
  "operatingCashFlow": 102718000000,
  "capex": 6042000000,
  "weightedDilutedShares": 24514000000,
  "sharesOutstanding": 24300000000,
  "sharesOutstandingDate": "2026-02-20",
  "freeCashFlow": 96676000000,
  "sourceTags": {
    "revenue": "us-gaap:Revenues",
    "capex": "us-gaap:PaymentsToAcquireProductiveAssets"
  },
  "derivedFields": [],
  "filingUrl": "https://www.sec.gov/Archives/edgar/data/1045810/000104581026000021/0001045810-26-000021-index.htm"
}
```

- Periods are matched on each fact's start and end dates, not on the filing's `fy` and `fp` labels, because a 10-K repeats two or three earlier years.
- Each metric tries a list of US-GAAP tags, then IFRS tags for 20-F and 40-F filers. `sourceTags` shows which tag was used for each value.
- Most companies never report Q4 on its own, and 10-Q cash flow statements are year-to-date. Those quarters are computed by subtraction and listed in `derivedFields`. EPS is not additive, so it is left empty for Q4.
- `valueSource: "as-reported"` (default) gives each figure as first filed. `"latest"` uses the most recent filing for that period.
- `rawTags`, for example `["us-gaap:AccountsPayableCurrent", "dei:EntityPublicFloat"]`, returns those tags one row per period with unit, form, filed date, accession and SEC frame.

#### Form 4 insider trading

```json
{
  "recordType": "insider-trade",
  "formType": "4",
  "periodOfReport": "2026-09-21",
  "issuerName": "NVIDIA CORP",
  "issuerTicker": "NVDA",
  "insiderName": "Teter Timothy S.",
  "insiderRole": "Officer (EVP, General Counsel and Sec)",
  "isDirector": false,
  "isOfficer": true,
  "rule10b5One": true,
  "isDerivative": false,
  "securityTitle": "Common Stock",
  "transactionDate": "2026-09-21",
  "transactionCode": "S",
  "transactionDescription": "Open market or private sale",
  "acquiredDisposed": "D",
  "shares": 12483,
  "pricePerShare": 222.1932,
  "valueUsd": 2773637.72,
  "sharesOwnedAfter": 2705637,
  "directOrIndirect": "I",
  "natureOfOwnership": "By Trust",
  "filingDate": "2026-09-23",
  "accessionNumber": "0001696841-26-000014",
  "filingUrl": "https://www.sec.gov/Archives/edgar/data/1045810/000169684126000014/0001696841-26-000014-index.htm",
  "xmlUrl": "https://www.sec.gov/Archives/edgar/data/1045810/000169684126000014/wk-form4_1790196985.xml"
}
```

- Leave `companies` empty to read the newest Form 4 filings from EDGAR's "Latest Filings" feed across the market. `maxFilings` is then the number of filings read, and one filing often holds several transactions.
- Derivative transactions (options, RSUs) are included with `isDerivative: true` and the underlying security. Holdings-only rows are not returned.
- `transactionCodes` keeps only some codes. `P` is an open-market purchase, `S` a sale.

#### 13F holdings

```json
{
  "recordType": "holding",
  "rank": 1,
  "issuer": "APPLE INC",
  "titleOfClass": "COM",
  "cusip": "037833100",
  "valueUsd": 65950296923,
  "shares": 227917808,
  "sharesType": "SH",
  "putCall": null,
  "investmentDiscretion": "DFND",
  "filedRows": 12,
  "percentOfPortfolio": 22.04,
  "managerName": "Berkshire Hathaway Inc",
  "managerCik": "0001067983",
  "periodOfReport": "2026-06-30",
  "form": "13F-HR",
  "filedDate": "2026-08-14",
  "accessionNumber": "0001193125-26-352200",
  "portfolioValueUsd": 299253556246,
  "positionsInFiling": 89,
  "filingUrl": "https://www.sec.gov/Archives/edgar/data/1067983/000119312526352200/0001193125-26-352200-index.htm",
  "infoTableUrl": "https://www.sec.gov/Archives/edgar/data/1067983/000119312526352200/56757.xml"
}
```

- Without `quarter` you get the latest 13F-HR. Use `quarter: "2025-Q4"` for an earlier one.
- With `combineSameSecurity` on (default), rows for the same CUSIP are summed, as in the `filedRows` field. Turn it off to get rows exactly as filed.
- Values are in dollars. Filings made before 2023-01-03 reported thousands of dollars, and those are multiplied by 1,000.

#### Filing text and 10-K sections

```json
{
  "recordType": "filing-text",
  "ticker": "NVDA",
  "cik": "0001045810",
  "companyName": "NVIDIA CORP",
  "form": "10-K",
  "filingDate": "2026-02-25",
  "reportDate": "2026-01-25",
  "accessionNumber": "0001045810-26-000021",
  "filingUrl": "https://www.sec.gov/Archives/edgar/data/1045810/000104581026000021/0001045810-26-000021-index.htm",
  "documentUrl": "https://www.sec.gov/Archives/edgar/data/1045810/000104581026000021/nvda-20260125.htm",
  "section": "1A",
  "sectionTitle": "Risk Factors",
  "text": "Item 1A. Risk Factors\n\nThe following risk factors should be considered in addition to the other information in this Annual Report on Form 10-K. The following risks could harm our business, financial condition, results of operations or reputation, which could cause our stock price to decline. Additional risks, trends and uncertainties not presently known to us or that we currently believe are immaterial may also harm our business, financial condition, results of operations or reputation.\n\nRisk Factors Summary\n\nRisks Related to Our Industry and Markets\n\n•Failure to meet the evolving needs of our industry and markets may adversely impact our financial results.\n\n•Competition could adversely impact our market share and financial results.\n\nRisks Related to Demand, Supply, and Manufacturing",
  "chars": 794,
  "totalChars": 114640,
  "truncated": true
}
```

- `sections` takes Item numbers (`1`, `1A`, `7`, `7A`, `8`) or names (`business`, `risk-factors`, `mda`, `market-risk`, `financial-statements`, `legal-proceedings`, `controls`). For a 10-Q, `mda` maps to Part I Item 2 and `risk-factors` to Part II Item 1A. You can also write `P2-1A`. 8-K items look like `2.02`.
- Text longer than `maxChars` is cut at a paragraph break and marked `truncated`, with `totalChars` giving the full length. A 10-K is about 200,000 to 600,000 characters.
- Tables come out as one line per row with `|` between cells. With `includeTables` off, numeric tables are dropped.
- `filingUrls` accepts EDGAR document URLs, index-page URLs, `ix?doc=` viewer URLs and bare accession numbers.

#### New filing alerts

```json
{
  "recordType": "new-filing",
  "input": "TSLA",
  "ticker": "TSLA",
  "cik": "0001318605",
  "companyName": "Tesla, Inc.",
  "form": "8-K",
  "filingDate": "2026-10-21",
  "reportDate": "2026-10-21",
  "acceptanceDateTime": "2026-10-21T20:41:42.000Z",
  "items": "2.02,9.01",
  "description": "8-K",
  "filingUrl": "https://www.sec.gov/Archives/edgar/data/1318605/000162828026066738/0001628280-26-066738-index.htm",
  "documentUrl": "https://www.sec.gov/Archives/edgar/data/1318605/000162828026066738/tsla-20261021.htm",
  "firstRun": true,
  "detectedAt": "2026-10-28T22:02:45.709Z"
}
```

- Run the same input hourly or daily. Each run returns only filings that runs with the same `stateKey` have not returned yet.
- The first run for a company reports the last `initialLookbackDays` days (default 7). Set it to 0 to start from now.
- State is kept in a key-value store named `sec-edgar-watch-state` in your Apify account.
- If there is nothing new, you get one free `info` row.

Each run also writes a `SUMMARY` record to the default key-value store with the rows charged per event, the number of SEC requests and any warnings, such as a filing that had no ownership XML.

### What people use the SEC EDGAR API for

- Financial models: standardized annual or quarterly statements without parsing XBRL by hand.
- Insider trading screens: open-market purchases (`P`) and sales (`S`) at a list of tickers.
- Fund tracking: 13F holdings for the managers you follow, quarter by quarter.
- Research: Risk Factors or MD\&A text pulled from 10-K and 10-Q filings for summarizing or search.
- Alerts: a note in Slack or a spreadsheet when a company files an 8-K.

### FAQ

#### Do I need an SEC API key?

No. The Actor reads public sec.gov endpoints and the EDGAR archive.

#### Is this the same as the SEC's own EDGAR API?

It uses the SEC's own data (the submissions and companyfacts endpoints, and filing documents from the archive) and reshapes it into rows. The 13F, Form 4 and filing-text modes parse the filing files themselves.

#### How current is the data?

New filings show up in EDGAR within minutes. The XBRL companyfacts data can lag behind, and for some foreign filers it lags a lot. When that happens the newest annual row is the previous year.

#### Why are some financial fields empty?

XBRL tags are not consistent across companies. One company tags revenue `Revenues`, another `RevenueFromContractWithCustomerExcludingAssessedTax`, and some switch tags between years. The fallback lists cover common cases, not all of them, so check `sourceTags` before comparing companies. Banks, insurers and REITs often have no tag for some metrics, and those fields are `null`. Derived quarters, `freeCashFlow` and a `totalLiabilities` computed from total liabilities and equity minus equity are calculations, listed in `derivedFields`. For companies with several share classes, `sharesOutstanding` can be empty; `weightedDilutedShares` is usually filled.

#### Why did section extraction find nothing?

It needs "Item N." headings at the start of a line. Filings with unusual layouts, scanned exhibits or PDF main documents can come back with no sections, and the `info` row then lists what was found.

#### Are old 13F filings covered?

13F filings before mid-2013 used text tables and are not parsed.

#### How do I run it on a schedule or send results to Make, Zapier or n8n?

Add a schedule in Apify Console with your input. In Make, Zapier or n8n, use the Apify integration to run the Actor and read its dataset, or add a webhook to the task. With the JavaScript client: `client.actor("fernandosord/sec-edgar-api").call({ mode: "13f-holdings", companies: ["Berkshire Hathaway"] })`.

#### Can an AI agent use it?

Yes. Add the Actor to the Apify MCP server (`https://mcp.apify.com`, with the Actor listed in the `tools` parameter). The agent sees the input schema, so field names and allowed values come from there. Prompts that work well:

- "Latest 10-K risk factors for AMD": `{"mode":"filing-text","companies":["AMD"],"sections":["risk-factors"],"maxChars":20000}`
- "Microsoft revenue and free cash flow for the last 8 quarters": `{"mode":"financials","companies":["MSFT"],"periodType":"quarterly"}`
- "Open-market insider buys at Intel this year": `{"mode":"insider-trades","companies":["INTC"],"transactionCodes":["P"],"dateFrom":"2026-01-01","maxFilings":100}`

Keep `maxChars` within the model's context budget. Rows carry `filingUrl` or `documentUrl`, so an agent can cite the filing.

#### Does it follow the SEC's access rules?

Yes. Every request declares a User-Agent that links to this Actor's page. Each run stays at or below 5 requests per second, half the SEC's limit of 10, because several runs can share one Apify IP address. If the SEC slows a run down, it waits and retries. See the SEC's [fair access rules](https://www.sec.gov/search-filings/edgar-search-assistance/accessing-edgar-data). Every row links back to its sec.gov source.

#### Is this investment advice?

No. The Actor reformats public SEC filings. It does not check them for accuracy, and filers sometimes make tagging errors that only a later amendment fixes.

### Other Actors by this developer

- [Website Change Monitor](https://apify.com/fernandosord/website-change-monitor): watch an investor-relations or press page and get the lines that changed.
- [PDF to Text & Markdown](https://apify.com/fernandosord/document-to-markdown): turns PDFs, Office files and scans into text, useful for exhibits that EDGAR serves as PDF.
- [Google Trends API](https://apify.com/fernandosord/google-trends-reliable): search interest by region and query.
- [Career Site Jobs API](https://apify.com/fernandosord/career-site-jobs): open jobs from Greenhouse, Lever and Ashby, a hiring signal for the companies you research.
- [WHOIS & DNS Lookup](https://apify.com/fernandosord/domain-profile-whois-dns): domain age, SSL and email security.

# Actor input Schema

## `mode` (type: `string`):

company: profile and latest filings. financials: XBRL figures per fiscal period. insider-trades: Form 4 transactions (leave companies empty for the newest filings market-wide). 13f-holdings: a fund's 13F positions. filing-text: clean text of a filing or its 10-K/10-Q Items. watch: only filings new since the last run with the same stateKey.

## `companies` (type: `array`):

Tickers (AAPL, BRK.B), CIK numbers (320193) or registered names ("Berkshire Hathaway"). Names use EDGAR's company search and take the top match, so tickers or CIKs are safer. For 13f-holdings, list the fund managers.

## `formTypes` (type: `array`):

Only these SEC forms, e.g. 10-K, 10-Q, 8-K, 4, S-1, 13F-HR, SC 13D. Empty means all forms (company, watch), 4 and 4/A (insider-trades) or 10-K (filing-text, which reads the latest filing of each form listed).

## `dateFrom` (type: `string`):

YYYY-MM-DD. Filters the filings list (company) and Form 4 filings for listed companies (insider-trades).

## `dateTo` (type: `string`):

YYYY-MM-DD. Same modes as "Filed on or after".

## `maxFilings` (type: `integer`):

company: filings listed per company. insider-trades: Form 4 filings read per company, or in total when companies is empty. One filing often holds several transactions.

## `periodType` (type: `string`):

annual: one row per fiscal year from 10-K/20-F/40-F. quarterly: one row per fiscal quarter; Q4 and cash-flow quarters are derived by subtraction where the filing only gives year-to-date totals. both: annual and quarterly rows.

## `maxPeriods` (type: `integer`):

Newest N fiscal periods per company (per period type when both).

## `valueSource` (type: `string`):

as-reported: each figure as first filed for that period. latest: the most recent figure for that period, which includes later restatements and reclassifications.

## `rawTags` (type: `array`):

Return raw facts for these tags instead of the normalized rows, e.g. us-gaap:Revenues, AccountsPayableCurrent (us-gaap is assumed), dei:EntityPublicFloat.

## `transactionCodes` (type: `array`):

Keep only these Form 4 codes. P = open market purchase, S = sale, A = grant, M = option exercise, F = tax withholding, G = gift. Empty keeps all.

## `quarter` (type: `string`):

Report quarter like 2026-Q2 or 2026-06-30. Empty means the latest 13F-HR each manager filed.

## `maxHoldings` (type: `integer`):

Largest N positions by value. 0 returns every position.

## `combineSameSecurity` (type: `boolean`):

Managers often split one stock across several rows (by sub-manager or discretion). On: one row per CUSIP and put/call with values summed. Off: rows exactly as filed.

## `filingUrls` (type: `array`):

EDGAR document or index URLs, or accession numbers like 0000320193-25-000079. Used together with companies.

## `sections` (type: `array`):

10-K/10-Q Items to extract, one row each: 1, 1A, 7, 7A, 8, or names: business, risk-factors, mda, market-risk, financial-statements, legal-proceedings, controls. 10-Q Part II items: P2-1A. 8-K: 2.02. Empty returns the whole document.

## `maxChars` (type: `integer`):

Longer text is cut at a paragraph break and marked truncated: true, with totalChars giving the full length. A 10-K is about 200,000 to 600,000 characters.

## `includeTables` (type: `boolean`):

Tables come out as one line per row with cells separated by " | ". Turn off for prose only.

## `stateKey` (type: `string`):

Name of the watch list. Runs with the same key share memory of filings already returned, which are never returned or charged again.

## `initialLookbackDays` (type: `integer`):

On the first run for a company, filings from the last N days count as new. 0 starts silently from now.

## Actor input object example

```json
{
  "mode": "company",
  "companies": [
    "AAPL",
    "MSFT"
  ],
  "formTypes": [
    "10-K",
    "10-Q",
    "8-K"
  ],
  "dateFrom": "",
  "dateTo": "",
  "maxFilings": 10,
  "periodType": "annual",
  "maxPeriods": 8,
  "valueSource": "as-reported",
  "rawTags": [],
  "transactionCodes": [],
  "quarter": "",
  "maxHoldings": 100,
  "combineSameSecurity": true,
  "filingUrls": [],
  "sections": [],
  "maxChars": 50000,
  "includeTables": true,
  "stateKey": "default",
  "initialLookbackDays": 7
}
```

# Actor output Schema

## `results` (type: `string`):

One row per company, financial period, insider transaction, holding, filing section or new filing, depending on the mode. Rows with recordType info or error explain inputs that returned nothing.

## `summary` (type: `string`):

Mode, rows charged per event, SEC request count and warnings.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "mode": "company",
    "companies": [
        "AAPL",
        "MSFT"
    ],
    "formTypes": [
        "10-K",
        "10-Q",
        "8-K"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("fernandosord/sec-edgar-api").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "mode": "company",
    "companies": [
        "AAPL",
        "MSFT",
    ],
    "formTypes": [
        "10-K",
        "10-Q",
        "8-K",
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("fernandosord/sec-edgar-api").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "mode": "company",
  "companies": [
    "AAPL",
    "MSFT"
  ],
  "formTypes": [
    "10-K",
    "10-Q",
    "8-K"
  ]
}' |
apify call fernandosord/sec-edgar-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fernandosord/sec-edgar-api"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/wY4hkRjbcRYore8cs/builds/If2x7ttu4zQqQgW8Y/openapi.json
