Docs / Concepts

Mirroring the market

If you keep your own copy of SEC or government data for thousands of companies, load it once, then fetch only what changed. Re-pulling every ticker every day burns credits, runs into your plan's speed limit, and is slower than being told when something new is filed.

1. Backfill once, at your plan's pace

Walk your ticker list once, keeping under your plan's speed limit. Read X-RateLimit-Remaining and pause when it reaches 0, and wait Retry-After seconds on a 429. A 429 costs nothing. Most fundamentals and filings change at most a few times a quarter, so one full pass is the expensive part, and you only do it once.

2. Stay in sync with webhooks

Register webhooks for the tickers you hold, and Edgrapi POSTs to your server when there's something new: insider trades, 8-K events, activist stakes, Congress trades, lobbying reports and federal contracts. Then re-fetch only that ticker.

curl -X POST https://api.edgrapi.com/v1/webhooks \
  -H "X-API-Key: $EDGRAPI_KEY" -H "Content-Type: application/json" \
  -d '{"url": "https://example.com/edgrapi-hook",
       "tickers": ["AAPL", "MSFT", "NVDA"],
       "events": ["insider", "8-k", "activist"]}'

Each webhook watches up to 50 tickers, so a large list is several webhooks. On Lite and Starter, events arrive a day late; Pro and above get them in real time. Plan limits are on the pricing page.

3. Poll the market-wide feeds

Some changes aren't tied to a ticker you already hold. These endpoints list recent filings across the whole market, so one call a day replaces thousands of per-ticker calls:

  • GET /v1/congress: the latest House member stock trades.
  • GET /v1/formd/latest: new Form D private placements.
  • GET /v1/events/restatements and GET /v1/events/auditor-changes: 8-K red flags.

The bulk-sync hint

When an account asks for more than 2,000 different tickers on one endpoint in a day, responses carry a meta.hint field and an X-Edgrapi-Hint header pointing here. It's only a hint: nothing is blocked. Need a full bulk feed instead? Talk to us about Enterprise.