boj-exchange-rate 1.3.8 → 1.3.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -14
- package/package.json +11 -3
package/README.md
CHANGED
|
@@ -37,15 +37,17 @@ The open endpoint serves the *latest* table only and asks for a visible attribut
|
|
|
37
37
|
|
|
38
38
|
## 📈 Latest published table
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
[](https://allratestoday.com/central-bank-rates-api/boj/)
|
|
41
|
+
|
|
42
|
+
The image is rendered live from the keyless endpoint above, so it follows the central bank's publications on npm and on GitHub alike without a new release. The text copy below is there for search and copy-paste: on GitHub [a daily Action](.github/workflows/daily-table.yml) refreshes it whenever the central bank publishes a new table; on npm it is as of the package's publish date.
|
|
41
43
|
|
|
42
44
|
<!-- daily-table:start -->
|
|
43
|
-
Published **2026-10-
|
|
45
|
+
Published **2026-10-09** by Bank of Japan (the API currently flags this table as stale) — 2 rates. Updated 2026-10-14.
|
|
44
46
|
|
|
45
47
|
| Base | Quote | Type | Rate |
|
|
46
48
|
| --- | --- | --- | ---: |
|
|
47
|
-
| USD | JPY | middle | 158.
|
|
48
|
-
| USD | JPY | spot | 158.
|
|
49
|
+
| USD | JPY | middle | 158.1 |
|
|
50
|
+
| USD | JPY | spot | 158.34 |
|
|
49
51
|
|
|
50
52
|
Source: [Official rates published by BOJ, served by AllRatesToday](https://allratestoday.com/central-bank-rates-api/boj/). Rates are as printed by the central bank; AllRatesToday is not affiliated with it.
|
|
51
53
|
<!-- daily-table:end -->
|
|
@@ -102,10 +104,10 @@ const pair = await getRate('USD', 'JPY', { apiKey: 'art_live_...' });
|
|
|
102
104
|
{
|
|
103
105
|
bank: 'boj',
|
|
104
106
|
name: 'Bank of Japan',
|
|
105
|
-
rate_date: '2026-10-
|
|
107
|
+
rate_date: '2026-10-09', // Bank of Japan's own publication date
|
|
106
108
|
source: 'USD',
|
|
107
109
|
target: 'JPY',
|
|
108
|
-
rate: 158.
|
|
110
|
+
rate: 158.1,
|
|
109
111
|
rate_type: 'middle',
|
|
110
112
|
derived: false,
|
|
111
113
|
method: 'published',
|
|
@@ -130,10 +132,10 @@ console.log(table.rate_date, table.rates.length);
|
|
|
130
132
|
{
|
|
131
133
|
bank: 'boj',
|
|
132
134
|
name: 'Bank of Japan',
|
|
133
|
-
rate_date: '2026-10-
|
|
135
|
+
rate_date: '2026-10-09',
|
|
134
136
|
rates: [
|
|
135
|
-
{ "base": "USD", "quote": "JPY", "type": "middle", "value": 158.
|
|
136
|
-
{ "base": "USD", "quote": "JPY", "type": "spot", "value": 158.
|
|
137
|
+
{ "base": "USD", "quote": "JPY", "type": "middle", "value": 158.1 },
|
|
138
|
+
{ "base": "USD", "quote": "JPY", "type": "spot", "value": 158.34 },
|
|
137
139
|
// … the rest of the published table (1 currency vs JPY)
|
|
138
140
|
],
|
|
139
141
|
disclaimer: '…'
|
|
@@ -173,7 +175,7 @@ Paid plans. One resolved rate per publication date — ready for charting, reval
|
|
|
173
175
|
import { getHistory } from 'boj-exchange-rate';
|
|
174
176
|
|
|
175
177
|
const series = await getHistory(
|
|
176
|
-
{ source: 'USD', target: 'JPY', from: '2026-01-01', to: '2026-10-
|
|
178
|
+
{ source: 'USD', target: 'JPY', from: '2026-01-01', to: '2026-10-09' },
|
|
177
179
|
{ apiKey: 'art_live_...' }
|
|
178
180
|
);
|
|
179
181
|
```
|
|
@@ -186,11 +188,11 @@ const series = await getHistory(
|
|
|
186
188
|
source: 'USD',
|
|
187
189
|
target: 'JPY',
|
|
188
190
|
from: '2026-01-01',
|
|
189
|
-
to: '2026-10-
|
|
191
|
+
to: '2026-10-09',
|
|
190
192
|
count: 152,
|
|
191
193
|
rates: [
|
|
192
194
|
// one entry per publication date
|
|
193
|
-
{ date: '2026-10-
|
|
195
|
+
{ date: '2026-10-09', rate: 158.1, rate_type: 'middle', derived: false, method: 'published' },
|
|
194
196
|
// …
|
|
195
197
|
],
|
|
196
198
|
disclaimer: '…'
|
|
@@ -309,9 +311,9 @@ getRate('USD', 'JPY', { apiKey: 'art_live_...' }).then((pair) => console.log(pai
|
|
|
309
311
|
|
|
310
312
|
Need the whole archive rather than an API call? The same published tables are mirrored daily as open data:
|
|
311
313
|
|
|
312
|
-
- Hugging Face: [
|
|
314
|
+
- Hugging Face: [AllRatesToday/central-bank-exchange-rates](https://huggingface.co/datasets/AllRatesToday/central-bank-exchange-rates) — one CSV per institution (`rates/boj.csv`)
|
|
313
315
|
- Kaggle: [allratestoday/central-bank-exchange-rates](https://www.kaggle.com/datasets/allratestoday/central-bank-exchange-rates)
|
|
314
|
-
-
|
|
316
|
+
- Raw JSON on GitHub: `https://raw.githubusercontent.com/AllRates-Today/central-bank-exchange-rates/main/data/boj/latest.json`
|
|
315
317
|
|
|
316
318
|
## 🔗 Links
|
|
317
319
|
|
package/package.json
CHANGED
|
@@ -1,21 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "boj-exchange-rate",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.13",
|
|
4
4
|
"description": "Official Bank of Japan (Japan) daily exchange rates — 1 currency vs JPY, history since 1998. Zero-dependency Node.js/TypeScript client.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"boj",
|
|
7
|
+
"bank-of-japan",
|
|
7
8
|
"bank",
|
|
8
|
-
"of",
|
|
9
9
|
"japan",
|
|
10
10
|
"exchange-rate",
|
|
11
11
|
"exchange-rates",
|
|
12
|
+
"exchangerate",
|
|
13
|
+
"exchange rate",
|
|
14
|
+
"jpy-exchange-rate",
|
|
12
15
|
"currency",
|
|
13
16
|
"forex",
|
|
14
17
|
"fx",
|
|
15
18
|
"jpy",
|
|
19
|
+
"currency-api",
|
|
20
|
+
"currency-exchange-rates",
|
|
21
|
+
"forex-api",
|
|
22
|
+
"currency-conversion",
|
|
23
|
+
"currency-exchange",
|
|
24
|
+
"currency-rates",
|
|
16
25
|
"central-bank",
|
|
17
26
|
"official-rates",
|
|
18
|
-
"japan",
|
|
19
27
|
"api",
|
|
20
28
|
"typescript"
|
|
21
29
|
],
|