Sveriges Riksbank connector for parsimony — all five public APIs (SWEA, SWESTR, Monetary Policy, Turnover, Holdings)
Project description
parsimony-riksbank
Sveriges Riksbank (Sweden's central bank) connector plugin for parsimony. Surfaces all five of the Riksbank's public REST APIs: interest & exchange rates (SWEA), the Swedish Krona Short-Term Rate (SWESTR), Monetary Policy forecasts & outcomes, market Turnover Statistics, and securities Holdings. Keyless — no API credentials required.
Part of the parsimony-connectors
monorepo. Distributed standalone on PyPI as parsimony-riksbank.
Connectors
| Name | Kind | Description |
|---|---|---|
riksbank_fetch |
connector | Fetch a SWEA interest/exchange-rate series by id (e.g. SEKEURPMI), windowed or latest. |
riksbank_swestr_fetch |
connector | Fetch a SWESTR series — the overnight fixing, a compounded average (1W–6M) or the index. |
riksbank_monetary_policy_fetch |
connector | Fetch a Monetary Policy forecast/outcome series (e.g. SEQGDPNAYSA); pick one policy_round vintage or get all. |
riksbank_turnover_fetch |
connector | Fetch aggregated turnover for a market (fi/fx/ird) at a frequency (daily/monthly). |
riksbank_holdings_fetch |
connector | Fetch the Riksbank's securities holdings (swedish_securities per-ISIN, or swedish_securities_aggregated). |
enumerate_riksbank |
enumerator | Enumerate every addressable unit across all five products for catalog indexing. |
riksbank_search |
connector | Semantic-search the published riksbank catalog and return matching code + title + score. |
Install
pip install parsimony-riksbank
Pulls in a compatible parsimony-core automatically. Verify discovery:
python -c "from parsimony import discover; print([p.name for p in discover.iter_providers()])"
Quick start
from parsimony_riksbank import CONNECTORS
# The Riksbank's GDP forecast (annual % change), latest policy round.
result = CONNECTORS["riksbank_monetary_policy_fetch"](
series="SEQGDPNAYSA",
policy_round="2026:1",
)
print(result.data.head())
Catalogs
This plugin ships a riksbank catalog (~156 entries) driven by enumerate_riksbank.
riksbank_search loads a published snapshot (overridable via the
PARSIMONY_RIKSBANK_CATALOG_URL env var) and falls back to building one in-process when no
snapshot is reachable. Maintainers build and push the snapshot with scripts/build_catalog.py.
The catalog code routes the follow-up fetch:
- bare SWEA id (e.g.
SEKEURPMI) →riksbank_fetch(series_id=...) - bare SWESTR id (e.g.
SWESTR,SWESTRAVG1M) →riksbank_swestr_fetch(series=...) monetary_policy/<id>→riksbank_monetary_policy_fetch(series=<id>)turnover/<market>/<frequency>→riksbank_turnover_fetch(market=, frequency=)holdings/<dataset>→riksbank_holdings_fetch(dataset=<dataset>)
Coverage
The Riksbank publishes five public REST APIs (confirmed against the developer portal's API list); this plugin covers all five.
Catalog covers ALL: yes for the series-shaped products — SWEA /Series and Monetary
Policy /forecasts/series_ids are authoritative live enumerations, and SWESTR / Turnover /
Holdings have small, stable dimensions enumerated as registries. Connectors cover ALL
accessible data: yes — every product has a fetch verb. Notes on deliberate scope:
- SWESTR
PRESWESTR(preliminary 2021 test-period values) is excluded as superseded test data. - SWEA derived endpoints —
CrossRates,ObservationAggregates,CalendarDays— are computed conveniences over the same 117 series (cross-rate calculation, resampling, banking-day lookups), not new addressable series, so they are not catalogued. - Turnover is catalogued at the
(market, frequency)dataset granularity; the asset/contract/counterparty facets are returned inside each dataset. The Excel-report endpoints duplicate the JSON content and are not wrapped.
Authentication & rate limits
All five products are open / keyless. An optional Ocp-Apim-Subscription-Key (set
RIKSBANK_API_KEY or pass api_key=) only raises the keyless quota of 5 requests/minute,
1000/day per IP — recommended for full catalog builds.
Provider
- API portal: https://developer.api.riksbank.se/apis
- Statistics: https://www.riksbank.se/en-gb/statistics/
License
See LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file parsimony_riksbank-0.0.1.tar.gz.
File metadata
- Download URL: parsimony_riksbank-0.0.1.tar.gz
- Upload date:
- Size: 27.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e615c2f4a13520f8d957f41b28160e0bfe3a00db3bbbd633b0f5e6104a128647
|
|
| MD5 |
a70008620780c19df8b939ee7fdaa446
|
|
| BLAKE2b-256 |
10ce8e1cf8dbe2efcb496183991c66da08ee527d4a04ac5062e7f674aa5c9fac
|
Provenance
The following attestation bundles were made for parsimony_riksbank-0.0.1.tar.gz:
Publisher:
release.yml on ockham-sh/parsimony-connectors
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
parsimony_riksbank-0.0.1.tar.gz -
Subject digest:
e615c2f4a13520f8d957f41b28160e0bfe3a00db3bbbd633b0f5e6104a128647 - Sigstore transparency entry: 1971026048
- Sigstore integration time:
-
Permalink:
ockham-sh/parsimony-connectors@517cb5874f97ffede7738611ed75bb3ed27e26a0 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/ockham-sh
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@517cb5874f97ffede7738611ed75bb3ed27e26a0 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file parsimony_riksbank-0.0.1-py3-none-any.whl.
File metadata
- Download URL: parsimony_riksbank-0.0.1-py3-none-any.whl
- Upload date:
- Size: 33.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
286a00d931ecab01e28eb3a79e210c238d0d525bcb97b5013f9b0242354d27c1
|
|
| MD5 |
522316faf7044bc4594b64a4c901ffd5
|
|
| BLAKE2b-256 |
22b1732f0c3b838b21cbd247e0024eef0073c60f27545abc3817e438fe90ddd2
|
Provenance
The following attestation bundles were made for parsimony_riksbank-0.0.1-py3-none-any.whl:
Publisher:
release.yml on ockham-sh/parsimony-connectors
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
parsimony_riksbank-0.0.1-py3-none-any.whl -
Subject digest:
286a00d931ecab01e28eb3a79e210c238d0d525bcb97b5013f9b0242354d27c1 - Sigstore transparency entry: 1971026096
- Sigstore integration time:
-
Permalink:
ockham-sh/parsimony-connectors@517cb5874f97ffede7738611ed75bb3ed27e26a0 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/ockham-sh
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@517cb5874f97ffede7738611ed75bb3ed27e26a0 -
Trigger Event:
workflow_dispatch
-
Statement type: