Agent402 / tools / edgar-xbrl-frame

EDGAR XBRL frame (cross-company snapshot)

$0.025 per call · USDC via x402 · GET /api/edgar-xbrl-frame

All US public companies that reported a given XBRL tag for a given period, in one call. Killer endpoint for cross-sectional screens: 'every issuer's Revenues for CY2023Q1' or 'every issuer's Assets as of CY2023Q4I (instantaneous)'. Period format: CY{YYYY} (annual), CY{YYYY}Q{1-4} (quarterly), or CY{YYYY}Q{1-4}I (instantaneous balance-sheet items). Source: data.sec.gov/api/xbrl/frames. ?taxonomy=us-gaap&tag=Revenues&unit=USD&period=CY2023Q1

Input

FieldTypeDescription
taxonomystringXBRL taxonomy, default "us-gaap"
tag *stringXBRL concept tag, e.g. "Revenues", "Assets"
unit *stringUnit of measure, e.g. "USD", "shares", "USD/shares"
period *stringCY{YYYY} (annual), CY{YYYY}Q{1-4} (quarterly), or CY{YYYY}Q{1-4}I (instantaneous balance-sheet)
limitnumberMax companies to return, 1-2000 (default 200)

Example output

{
  "taxonomy": "us-gaap",
  "tag": "Revenues",
  "ccp": "CY2023Q1",
  "uom": "USD",
  "label": "Revenues",
  "totalCompanies": 1872,
  "returned": 1,
  "truncated": true,
  "data": [
    {
      "accn": "0000320193-23-000064",
      "cik": 320193,
      "entityName": "Apple Inc.",
      "loc": "US-CA",
      "end": "2023-04-01",
      "val": 94836000000
    }
  ]
}

Try it — see the 402 challenge (free)

curl -i "https://agent402.tools/api/edgar-xbrl-frame?taxonomy=us-gaap&tag=Revenues&unit=USD&period=CY2023Q1"

The response is HTTP 402 Payment Required with exact payment requirements. Any x402 v2 client pays automatically and retries:

Paid call (JavaScript agent)

import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";

const client = new x402Client();
registerExactEvmScheme(client, { signer: privateKeyToAccount(KEY) });
const payFetch = wrapFetchWithPayment(fetch, client);

const res = await payFetch("https://agent402.tools/api/edgar-xbrl-frame?taxonomy=us-gaap&tag=Revenues&unit=USD&period=CY2023Q1");

Wallet-only. This tool reaches the network/browser/storage, so it is paid in USDC via x402 (no proof-of-work tier).

Related tools

US gov dataset search

USDC $0.003 · GET /api/gov-data

Search 300,000+ US government datasets on catalog.data.gov (CKAN): titles, publishing org, formats, and direct resource …

US weather alerts

USDC $0.003 · GET /api/weather-alerts

Active National Weather Service alerts for a US state as clean JSON: event, severity, headline, affected areas, onset/ex…

Recent earthquakes (USGS)

USDC $0.003 · GET /api/earthquakes

Real-time USGS earthquake feed: magnitude, place, time, depth, coordinates. Live government data, no key. ?minMag=4.5&pe…