# SEC Filings API: Insider Trades, 13F, 8-K, Form D (`pintostudio/sec-filings-api`) Actor

Standby REST API for SEC EDGAR: Form 4 insider trades, 13F holdings and quarter-over-quarter changes, 8-K events, Form D funding rounds, full-text search and XBRL financials as clean JSON. 23 endpoints. Support: Telegram @pintoflow

- **URL**: https://apify.com/pintostudio/sec-filings-api.md
- **Developed by:** [Pinto Studio](https://apify.com/pintostudio) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

## 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 Filings API

Form 4 insider trades, 13F institutional holdings, 8-K material events, and Form D funding rounds — pulled live from SEC EDGAR and returned as clean, typed JSON. Every endpoint resolves to a primary-source EDGAR filing; nothing here is scraped from a third-party aggregator.

This Actor works two ways:

1. **Operation input** — pick an operation from a dropdown (e.g. "13F: quarter-over-quarter position changes"), fill in a few fields, hit Start. The result lands in the run's dataset and in its `OUTPUT` key-value record, same as any other Actor. No need to touch Standby mode or write any code.
2. **Standby API** — if the Actor's Standby mode is enabled (see its Console page), it's instead a persistent REST API with ~25 endpoints you call directly over HTTP, with no run to start and no dataset to poll.

Both modes share the exact same route logic and return the exact same `{error, data, message}` JSON — pick whichever fits how you want to consume the data.

### Why this one's different

Most "SEC filings" APIs wrap a single data type (usually just a bare filing list) and go stale. This one:

- Covers **four** filing types end-to-end (Form 3/4/5, 13F-HR, 8-K, Form D), not one.
- Actually **parses the underlying XML** (ownership documents, 13F info tables, Form D offering data) into clean fields, instead of just handing you an accession number to go fetch yourself.
- Ships analysis endpoints you won't find elsewhere: **13F quarter-over-quarter position changes** (new/increased/decreased/sold-out positions, with % change), **insider cluster-buy detection** (multiple distinct insiders buying in the same window), and **insider buy/sell sentiment summaries**.
- Includes **full-text search** across all EDGAR filings since 2001.
- Bonus **XBRL financials** endpoint for raw fundamentals alongside the filings data.

### Running with operation input

Every operation name mirrors one endpoint from the table below (e.g. `thirteenf.changes` → `GET /v1/13f/:id/changes`). Set `operation`, plus whichever of `id` / `q` / `accession` / `limit` / `since` / `form` / `days` / `minInsiders` / `count` / `item` / `items` / `text` / `forms` / `startdt` / `enddt` / `ciks` / `tag` / `taxonomy` that operation needs — the input schema's field descriptions say which fields apply to which operation. Unused fields are simply ignored.

Example input to get Berkshire Hathaway's latest 13F holdings:

```json
{ "operation": "thirteenf.holdings", "id": "1067983" }
```

Example input for an insider-trading cluster-buy scan:

```json
{ "operation": "insiders.clusterBuys", "id": "AAPL", "days": 30, "minInsiders": 2 }
```

The run's dataset gets exactly one record: the same `{error, data, message}` envelope the Standby API would return for that call. If `error` comes back `true` (bad ticker, missing filing, etc.) the run is marked **Failed** with the reason in its log — check the dataset/`OUTPUT` for the full body either way.

### Calling the Standby API

This Actor's **Standby URL** is shown on its Console page (the "Standby" tab) — it looks like `https://<actor-name>.<your-username>.apify.actor`. Append any endpoint path from the table below to it, and authenticate with your Apify API token:

```bash
curl --request GET \
  --url 'https://sec-filings-api.your-username.apify.actor/v1/company/AAPL' \
  --header 'Authorization: Bearer YOUR_APIFY_TOKEN'
```

Or pass the token as a query parameter instead of a header:

```
https://sec-filings-api.your-username.apify.actor/v1/company/AAPL?token=YOUR_APIFY_TOKEN
```

Every example below omits the host and token for brevity — prepend your Standby URL and add your token to every call. Usage is billed the same way as any other Actor run on your Apify account (compute time while a request is in flight).

### Response format

Every response, success or failure, has the same three top-level keys — check `error` before trusting `data`:

```json
{ "error": false, "message": "Company profile for Apple Inc.", "data": { "...": "..." } }
```

```json
{ "error": true, "message": "Unknown ticker \"NOTATICKER\"", "data": null }
```

- `error` — `false` on success, `true` on failure. Always a boolean, never missing.
- `message` — short human-readable summary. Safe to log or display as-is.
- `data` — the payload on success; always `null` on failure.

HTTP status codes are still meaningful (`400` bad input, `404` not found, `429` rate-limited, `5xx` upstream SEC failure) — the envelope doesn't replace them, it just makes the body predictable regardless of status.

### Endpoints

All endpoints are under `/v1`. `:id` accepts either a ticker (`AAPL`) or a CIK (`320193` / `0000320193`), except where noted.

#### Company

| Endpoint | Description |
|---|---|
| `GET /v1/company/search?q=` | Search companies by name or ticker |
| `GET /v1/company/:id` | Company profile (name, CIK, SIC, exchange, address, former names) |
| `GET /v1/company/:id/filings?form=&limit=&since=` | Raw filing history, any form type |

#### Insider trades (Form 3/4/5)

| Endpoint | Description |
|---|---|
| `GET /v1/insiders/:id/trades?limit=&since=&form=` | Parsed insider transactions for a company |
| `GET /v1/insiders/:id/summary?days=90` | Buy/sell share totals, estimated $ volume, buy/sell ratio, distinct insiders |
| `GET /v1/insiders/:id/cluster-buys?days=30&minInsiders=2` | Dates where multiple distinct insiders bought in the same window — an early signal most APIs don't surface |
| `GET /v1/insiders/person/:cik` | All ownership filings by a specific insider (their own CIK), across every company they report for |
| `GET /v1/insiders/latest?count=40` | Market-wide stream of the newest Form 4 filings |

#### 13F institutional holdings

| Endpoint | Description |
|---|---|
| `GET /v1/13f/search?q=` | Find an institutional manager's CIK by name |
| `GET /v1/13f/:id/holdings` | Latest 13F-HR holdings, aggregated by CUSIP, with cover-page metadata |
| `GET /v1/13f/:id/history?limit=20` | Past 13F-HR filing periods on record |
| `GET /v1/13f/:id/changes` | **Quarter-over-quarter diff**: new positions, increased/decreased (with % change), sold-out, unchanged |
| `GET /v1/13f/latest?count=40` | Market-wide stream of the newest 13F-HR filings |

#### 8-K material events

| Endpoint | Description |
|---|---|
| `GET /v1/8k/:id?limit=&since=&item=` | 8-K filings for a company, with item codes decoded to plain English |
| `GET /v1/8k/:id/:accession?text=true` | Single filing: exhibit list + document URLs, optionally with extracted plain text |
| `GET /v1/8k/latest?items=5.02,2.02&count=40` | Market-wide stream, filterable by item code (e.g. `5.02` = exec changes, `2.02` = earnings) |

#### Form D private offerings

| Endpoint | Description |
|---|---|
| `GET /v1/form-d/search?q=` | Find an issuer's CIK by name |
| `GET /v1/form-d/:id?limit=` | Form D / D-A filings for an issuer |
| `GET /v1/form-d/:id/:accession` | Full parsed offering: amount raised, exemptions claimed, related persons, investor counts |
| `GET /v1/form-d/latest?count=40` | Market-wide stream of newly filed Form Ds (new funding rounds) |

#### Full-text search & financials

| Endpoint | Description |
|---|---|
| `GET /v1/search/filings?q=&forms=&startdt=&enddt=&ciks=` | Full-text search across all EDGAR filings since 2001 |
| `GET /v1/financials/:id/facts` | All XBRL facts reported by the company |
| `GET /v1/financials/:id/concept/:tag?taxonomy=us-gaap` | One XBRL concept over time (e.g. `Assets`, `Revenues`) |

### Examples

**Company profile by ticker**

```
GET /v1/company/AAPL
```

```json
{
  "error": false,
  "message": "Company profile for Apple Inc.",
  "data": { "cik": "0000320193", "name": "Apple Inc.", "tickers": ["AAPL"], "exchanges": ["Nasdaq"], "sic": "3571" }
}
```

**Latest insider trades for a company**

```
GET /v1/insiders/AAPL/trades?limit=1
```

```json
{
  "error": false,
  "message": "Found 1 insider transaction filings for Apple Inc.",
  "data": {
    "cik": "0000320193",
    "trades": [{
      "reportingOwners": [{ "name": "Newstead Jennifer", "isOfficer": true, "officerTitle": "SVP, GC and Government Affairs" }],
      "nonDerivativeTransactions": [{ "transactionCode": "S", "transactionCodeLabel": "Open market or private sale", "shares": 2399, "pricePerShare": 343.36 }]
    }]
  }
}
```

**Berkshire Hathaway's top 13F holdings**

```
GET /v1/13f/1067983/holdings
```

```json
{
  "error": false,
  "message": "Latest 13F-HR holdings for BERKSHIRE HATHAWAY INC (29 positions)",
  "data": {
    "holdings": [{ "cusip": "037833100", "nameOfIssuer": "APPLE INC", "shares": 227917808, "valueUsd": 65950296923 }]
  }
}
```

**What changed in Berkshire's portfolio since last quarter**

```
GET /v1/13f/1067983/changes
```

```json
{
  "error": false,
  "data": {
    "summary": { "newPositions": 1, "increased": 7, "decreased": 6, "soldOut": 1, "unchanged": 15 },
    "newPositions": [{ "cusip": "23331A109", "nameOfIssuer": "D R HORTON INC", "shares": 3564 }]
  }
}
```

**8-K filings market-wide, filtered to executive changes**

```
GET /v1/8k/latest?items=5.02&count=5
```

**A funding round's full details**

```
GET /v1/form-d/2162748/0001315863-26-000760
```

```json
{
  "error": false,
  "data": {
    "issuer": { "name": "Aliter Capital Annex, LP", "jurisdictionOfInc": "UNITED KINGDOM" },
    "offeringAmounts": { "totalOfferingAmount": "Indefinite", "totalAmountSold": 64006104 }
  }
}
```

### Do

- Check `error` first, then read `data`. Don't infer failure from HTTP status alone — always read the body.
- Use a ticker (`AAPL`) or a CIK (`320193`) interchangeably for `:id` — whichever you have on hand.
- Use the `search` endpoints (`/v1/company/search`, `/v1/13f/search`, `/v1/form-d/search`) to resolve a company/institution/issuer *name* to a CIK before calling the other endpoints, if you don't already have a ticker or CIK.
- URL-encode query parameters, especially `q=` on `/v1/search/filings` when it contains quotes or spaces.
- Cache filing data on your side for anything keyed by an accession number — a filed document never changes, so there's no reason to re-fetch it.
- Treat `cusip`, `cik`, and accession numbers as **strings**, not numbers — they carry meaningful leading zeros (e.g. CUSIP `037833100`, CIK `0000320193`).

### Don't

- Don't poll the `/latest` endpoints faster than once a minute. Filing feeds refresh on that cadence server-side, so hitting them more often just burns compute time for identical data.
- Don't treat this as a real-time market data feed. Filings show up on EDGAR on SEC's and the filer's own schedule (Form 4s within 2 business days of a trade, 13F-HR quarterly, etc.) — there's no live intraday component.
- Don't assume 13F `valueUsd` is in thousands. It's whole US dollars for periods after the SEC's 2023 rule change; only very old filings on record may still reflect the pre-2023 "thousands" convention as originally filed.
- Don't use this data as investment, legal, or compliance advice. It's raw, parsed filings data — not a recommendation engine.
- Don't assume every company has data for every endpoint. Most public companies never file a 13F (that's for institutional managers) or a Form D (that's for private offerings) — a `404` there is expected, not a bug.

### Support

Questions, bug reports, or feature requests: **Telegram [@pintoflow](https://t.me/pintoflow)**.

# Actor input Schema

## `operation` (type: `string`):

Which endpoint to call. This Actor can also run as an always-on Standby API with ~25 routes instead — see the README.

## `id` (type: `string`):

Company/issuer/institution identifier, e.g. "AAPL" or "320193". Used by: company.profile, company.filings, insiders.trades/summary/clusterBuys/person, thirteenf.holdings/history/changes, eightk.list/detail, formd.list/detail, financials.facts/concept.

## `q` (type: `string`):

Name/ticker to search for, or full-text query. Used by: company.search, thirteenf.search, formd.search, search.filings.

## `accession` (type: `string`):

A specific filing's accession number, e.g. "0000320193-26-000018". Used by: eightk.detail, formd.detail.

## `limit` (type: `integer`):

Max rows to return. Used by most list-type operations.

## `since` (type: `string`):

Only return filings on/after this date. Used by: company.filings, insiders.trades, eightk.list, formd.list.

## `form` (type: `string`):

e.g. "4" or "8-K". Used by: company.filings, insiders.trades.

## `days` (type: `integer`):

Lookback window in days. Used by: insiders.summary (default 90), insiders.clusterBuys (default 30).

## `minInsiders` (type: `integer`):

Used by: insiders.clusterBuys (default 2).

## `count` (type: `integer`):

How many of the latest market-wide filings to return. Used by: insiders.latest, thirteenf.latest, eightk.latest, formd.latest.

## `item` (type: `string`):

e.g. "5.02". Used by: eightk.list.

## `items` (type: `string`):

e.g. "5.02,2.02". Used by: eightk.latest.

## `text` (type: `boolean`):

Used by: eightk.detail.

## `forms` (type: `string`):

e.g. "8-K,10-K". Used by: search.filings.

## `startdt` (type: `string`):

Used by: search.filings.

## `enddt` (type: `string`):

Used by: search.filings.

## `ciks` (type: `string`):

Used by: search.filings.

## `tag` (type: `string`):

e.g. "Assets" or "Revenues". Used by: financials.concept.

## `taxonomy` (type: `string`):

Used by: financials.concept.

## Actor input object example

```json
{
  "operation": "company.profile",
  "id": "AAPL",
  "text": false,
  "taxonomy": "us-gaap"
}
```

# Actor output Schema

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

The JSON envelope returned by the selected operation, stored as a dataset item.

## `output` (type: `string`):

The same JSON envelope as a single key-value store record.

# 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 = {
    "operation": "company.profile",
    "id": "AAPL",
    "taxonomy": "us-gaap"
};

// Run the Actor and wait for it to finish
const run = await client.actor("pintostudio/sec-filings-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 = {
    "operation": "company.profile",
    "id": "AAPL",
    "taxonomy": "us-gaap",
}

# Run the Actor and wait for it to finish
run = client.actor("pintostudio/sec-filings-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 '{
  "operation": "company.profile",
  "id": "AAPL",
  "taxonomy": "us-gaap"
}' |
apify call pintostudio/sec-filings-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,pintostudio/sec-filings-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/sIA79nRa2VyXS2NJK/builds/pVHouE51cZBeDhom2/openapi.json
