Source connectors /

Source connectors

The GII-US source-connector framework: retrying transport with deterministic backoff, live rate-limit awareness, immutable-payload caching, and credential redaction — with declarative connector specs for every documented-API source, credentials by environment-variable name only.

19Connector specs
0Spec errors
0Unconnected APIsEvery documented-API source profile has a connector; CI fails if one does not.
0Credential valuesSpecs carry environment-variable names only.

The live half of the source inventory: for every documented-API source, a declarative connector spec — base URL, endpoints, pagination style, and how a credential is injected, by environment-variable name only. No credential value exists anywhere in this repository. The runner retries with deterministic backoff, honors Retry-After, treats returned rate-limit headers as authoritative over any documented quota, caches immutable payloads, persists every raw page before parsing, and redacts credentials from every surfaced line.

19 specs rendered live from @gii/connectors · validation errors 0 · unconnected documented-API profiles none.

credential discipline

Connectors by credential class

What each source requires to answer — a name, never a value. Provisioning the named environment variables turns a spec live with no code change.

  • Registration key737%
  • No credential737%
  • Token316%
  • API key211%

19 connectors in total · The registry

Connector registry#

SourcePaginationCredentialEndpoints
congress-gov
5,000 requests/hour (api.data.gov key) (advisory)
offsetregistration-key · $CONGRESS_GOV_API_KEYbills, law ◆
govinfocursorregistration-key · $GOVINFO_API_KEYcollections, package ◆
federal-register
no key; fair-use throttling (advisory)
pageno keydocuments, document ◆
ecfrnoneno keystructure, full ◆
regulations-gov
1,000 requests/hour (api.data.gov key) (advisory)
pageapi-key · $REGULATIONS_GOV_API_KEYdocuments, docket
courtlistener
5,000 queries/day (free tier) (advisory)
cursortoken · $COURTLISTENER_API_TOKENopinions, dockets
bls
500 queries/day (registered v2) (advisory)
noneregistration-key · $BLS_API_KEYseries
bea
100 requests & 100MB per minute (advisory)
noneregistration-key · $BEA_API_KEYdata
census
500 queries/day without key (advisory)
noneregistration-key · $CENSUS_API_KEYdataset
treasury-fiscal-datapageno keydataset
usaspendingpageno keyawards
usitc-datawebnonetoken · $USITC_DATAWEB_TOKENtrade
sec-edgar
10 requests/second (fair-access; declared User-Agent required) (advisory)
noneno keysubmissions, companyconcept
cmsoffsetno keydataset-list, dataset-data
openfemaoffsetno keydisaster-declarations
doloffsetregistration-key · $DOL_API_KEYdataset
fred
120 requests/minute (advisory)
offsetapi-key · $FRED_API_KEYseries-observations, series
eianoneregistration-key · $EIA_API_KEYroute-data
hudnonetoken · $HUD_API_TOKENfair-market-rents, income-limits

◆ immutable — cacheable by URL after first retrieval.

Walking demo#

The shipped federal-register spec, driven by the same runner a live transport would use — here against an in-memory transport at build time. Two pages; the second comes back short, so the bounded walk stops itself:

Run. 2 pages · 2 retrieval records · raw pages persisted before parsing · live rate limit 998/1000 remaining.
page 1: GET https://demo.invalid/api/v1/documents.json?per_page=3&page=1 → 200 in 1 attempt(s)
page 2: GET https://demo.invalid/api/v1/documents.json?per_page=3&page=2 → 200 in 1 attempt(s)

Each page yields a retrieval record with the fields — retrieval time, URI, publisher, content type, checksum, schema/extraction version, license, transformation history, and last validation — and lands in the append-only raw-evidence store.

Going live#

Turning a spec live requires no code change: provision the environment variable each credentialed spec names (e.g. CONGRESS_GOV_API_KEY, REGULATIONS_GOV_API_KEY), and the same runner, retries, caching, and redaction apply. The contract suite runs against a local mock server, and the PEPI adapter remains the walking-skeleton example of the full ingestion boundary.

Seven of these sources need no credential, and four of them retrieve real data today — the Federal Register, OpenFEMA, the eCFR, and SEC EDGAR, checked against the live APIs rather than against fixtures. Three do not: two return a 404 on a path that has moved since the spec was written, and one takes its query in a request body, which this spec format cannot express.

Retrieving a source is not scoring one. Retrieval is plumbing; a published score is a claim, and the withhold rule stands between them. GII-US is pre-pilot and publishes no score about any real government decision.

Whether a source works is checked one request at a time, by a command that writes nothing: a probe reports the status, whether the payload matches the shape the spec describes, and — when it does not — which of ten failure classes it is and what to do about it. A wrong key, an unactivated key, a key without entitlement, a spent quota, and a moved endpoint are five different problems, and only some of them are the operator’s.

Machine-readable at GET /api/v1/connectors · gii connectors.