@allratestoday/bcb-exchange-rate 1.3.6 โ†’ 1.3.9

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.
Files changed (2) hide show
  1. package/README.md +86 -8
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -4,6 +4,8 @@
4
4
  [![license](https://img.shields.io/npm/l/@allratestoday%2Fbcb-exchange-rate.svg)](https://github.com/AllRates-Today/bcb-exchange-rate/blob/main/LICENSE)
5
5
  [![zero dependencies](https://img.shields.io/badge/dependencies-0-brightgreen.svg)](https://www.npmjs.com/package/@allratestoday/bcb-exchange-rate)
6
6
  [![TypeScript](https://img.shields.io/badge/TypeScript-types%20included-3178C6.svg)](https://www.typescriptlang.org/)
7
+ [![USD/BRL today](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fallratestoday.com%2Fapi%2Fopen%2Fcentral-bank%2Fbcb%3Fsource%3DUSD%26target%3DBRL&query=%24.rate&label=USD%2FBRL%20published%20by%20Banco%20Central%20do%20Brasil&color=0A7E8C&cacheSeconds=3600)](https://allratestoday.com/central-bank-rates-api/bcb/)
8
+ [![rate date](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fallratestoday.com%2Fapi%2Fopen%2Fcentral-bank%2Fbcb%3Fsource%3DUSD%26target%3DBRL&query=%24.rate_date&label=rate%20date&color=555&cacheSeconds=3600)](https://allratestoday.com/central-bank-rates-api/bcb/)
7
9
 
8
10
  **Official Banco Central do Brasil (Brazil) daily exchange rates for Node.js and TypeScript. The published central bank rates behind tax filings, customs valuations, audits, and compliant invoicing โ€” not market estimates, but the numbers Banco Central do Brasil itself prints, every business day.**
9
11
 
@@ -33,6 +35,81 @@ console.log(r.rate_date, r.rates.length); // the central bank's latest published
33
35
 
34
36
  The open endpoint serves the *latest* table only and asks for a visible attribution link. The client below uses the keyed API, which adds point-in-time tables, history, and CSV/XML/Excel output.
35
37
 
38
+ ## ๐Ÿ“ˆ Latest published table
39
+
40
+ [![Latest Banco Central do Brasil table](https://allratestoday.com/api/open/central-bank/bcb/table.svg)](https://allratestoday.com/central-bank-rates-api/bcb/)
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.
43
+
44
+ <!-- daily-table:start -->
45
+ Published **2026-10-09** by Banco Central do Brasil โ€” 312 rates, first 60 shown. Updated 2026-10-12.
46
+
47
+ | Base | Quote | Type | Rate |
48
+ | --- | --- | --- | ---: |
49
+ | AED | BRL | buy | 1.3582 |
50
+ | AED | BRL | sell | 1.3585 |
51
+ | AFN | BRL | buy | 0.0768 |
52
+ | AFN | BRL | sell | 0.07704 |
53
+ | ALL | BRL | buy | 0.06069 |
54
+ | ALL | BRL | sell | 0.06116 |
55
+ | AMD | BRL | buy | 0.01375 |
56
+ | AMD | BRL | sell | 0.01382 |
57
+ | AOA | BRL | buy | 0.005385 |
58
+ | AOA | BRL | sell | 0.005465 |
59
+ | ARS | BRL | buy | 0.003291 |
60
+ | ARS | BRL | sell | 0.003292 |
61
+ | AUD | BRL | buy | 3.4805 |
62
+ | AUD | BRL | sell | 3.483 |
63
+ | AWG | BRL | buy | 2.7714 |
64
+ | AWG | BRL | sell | 2.8029 |
65
+ | AZN | BRL | buy | 2.9259 |
66
+ | AZN | BRL | sell | 2.9435 |
67
+ | BBD | BRL | buy | 2.4573 |
68
+ | BBD | BRL | sell | 2.497 |
69
+ | BDT | BRL | buy | 0.04039 |
70
+ | BDT | BRL | sell | 0.04053 |
71
+ | BHD | BRL | buy | 13.2043 |
72
+ | BHD | BRL | sell | 13.2164 |
73
+ | BIF | BRL | buy | 0.001657 |
74
+ | BIF | BRL | sell | 0.001671 |
75
+ | BMD | BRL | buy | 4.9886 |
76
+ | BMD | BRL | sell | 4.9892 |
77
+ | BND | BRL | buy | 3.8949 |
78
+ | BND | BRL | sell | 3.8957 |
79
+ | BOB | BRL | buy | 0.4185 |
80
+ | BOB | BRL | sell | 0.4239 |
81
+ | BSD | BRL | buy | 4.9886 |
82
+ | BSD | BRL | sell | 4.9892 |
83
+ | BTN | BRL | buy | 0.05157 |
84
+ | BTN | BRL | sell | 0.05158 |
85
+ | BWP | BRL | buy | 0.3442 |
86
+ | BWP | BRL | sell | 0.3837 |
87
+ | BYN | BRL | buy | 1.6282 |
88
+ | BYN | BRL | sell | 1.6423 |
89
+ | BZD | BRL | buy | 2.4669 |
90
+ | BZD | BRL | sell | 2.4944 |
91
+ | CAD | BRL | buy | 3.4951 |
92
+ | CAD | BRL | sell | 3.4965 |
93
+ | CDF | BRL | buy | 0.00215 |
94
+ | CDF | BRL | sell | 0.002161 |
95
+ | CHF | BRL | buy | 6.0031 |
96
+ | CHF | BRL | sell | 6.0067 |
97
+ | CLF | BRL | buy | 209.5112 |
98
+ | CLF | BRL | sell | 209.5364 |
99
+ | CLP | BRL | buy | 0.005094 |
100
+ | CLP | BRL | sell | 0.0051 |
101
+ | CNH | BRL | buy | 0.7453 |
102
+ | CNH | BRL | sell | 0.7454 |
103
+ | CNY | BRL | buy | 0.7454 |
104
+ | CNY | BRL | sell | 0.7455 |
105
+ | COP | BRL | buy | 0.001564 |
106
+ | COP | BRL | sell | 0.001565 |
107
+ | COU | BRL | buy | 0.65 |
108
+ | COU | BRL | sell | 0.6501 |
109
+
110
+ [Full table on the Banco Central do Brasil rates page](https://allratestoday.com/central-bank-rates-api/bcb/) ยท Source: [Official rates published by BCB, served by AllRatesToday](https://allratestoday.com/central-bank-rates-api/bcb/). Rates are as printed by the central bank; AllRatesToday is not affiliated with it.
111
+ <!-- daily-table:end -->
112
+
36
113
  ## ๐Ÿ”‘ Get your API key
37
114
 
38
115
  Get a free API key at [allratestoday.com/register](https://allratestoday.com/register) โ€” no credit card required. Latest rates are on every plan, including free.
@@ -85,10 +162,10 @@ const pair = await getRate('USD', 'BRL', { apiKey: 'art_live_...' });
85
162
  {
86
163
  bank: 'bcb',
87
164
  name: 'Banco Central do Brasil',
88
- rate_date: '2026-10-08', // Banco Central do Brasil's own publication date
165
+ rate_date: '2026-10-09', // Banco Central do Brasil's own publication date
89
166
  source: 'USD',
90
167
  target: 'BRL',
91
- rate: 5.0119,
168
+ rate: 4.9892,
92
169
  rate_type: 'sell',
93
170
  derived: false,
94
171
  method: 'published',
@@ -113,10 +190,10 @@ console.log(table.rate_date, table.rates.length);
113
190
  {
114
191
  bank: 'bcb',
115
192
  name: 'Banco Central do Brasil',
116
- rate_date: '2026-10-08',
193
+ rate_date: '2026-10-09',
117
194
  rates: [
118
- { "base": "USD", "quote": "BRL", "type": "sell", "value": 5.0119 },
119
- { "base": "USD", "quote": "BRL", "type": "buy", "value": 5.0113 },
195
+ { "base": "USD", "quote": "BRL", "type": "sell", "value": 4.9892 },
196
+ { "base": "USD", "quote": "BRL", "type": "buy", "value": 4.9886 },
120
197
  // โ€ฆ the rest of the published table (156 currencies vs BRL)
121
198
  ],
122
199
  disclaimer: 'โ€ฆ'
@@ -156,7 +233,7 @@ Paid plans. One resolved rate per publication date โ€” ready for charting, reval
156
233
  import { getHistory } from '@allratestoday/bcb-exchange-rate';
157
234
 
158
235
  const series = await getHistory(
159
- { source: 'USD', target: 'BRL', from: '2026-01-01', to: '2026-10-08' },
236
+ { source: 'USD', target: 'BRL', from: '2026-01-01', to: '2026-10-09' },
160
237
  { apiKey: 'art_live_...' }
161
238
  );
162
239
  ```
@@ -169,11 +246,11 @@ const series = await getHistory(
169
246
  source: 'USD',
170
247
  target: 'BRL',
171
248
  from: '2026-01-01',
172
- to: '2026-10-08',
249
+ to: '2026-10-09',
173
250
  count: 152,
174
251
  rates: [
175
252
  // one entry per publication date
176
- { date: '2026-10-08', rate: 5.0119, rate_type: 'sell', derived: false, method: 'published' },
253
+ { date: '2026-10-09', rate: 4.9892, rate_type: 'sell', derived: false, method: 'published' },
177
254
  // โ€ฆ
178
255
  ],
179
256
  disclaimer: 'โ€ฆ'
@@ -224,6 +301,7 @@ curl "https://allratestoday.com/api/v1/central-bank/bcb/latest?format=xml&api_ke
224
301
  - MCP server: `npx -y @allratestoday/central-bank-mcp` (stdio) or the hosted endpoint `https://allratestoday.com/api/mcp` โ€” tools for official rates, history, cross-bank comparison and publication calendars
225
302
  - Already using the general SDK or MCP server? Since 2026-10-01 [`@allratestoday/sdk`](https://www.npmjs.com/package/@allratestoday/sdk) 1.4+ has `officialRates('bcb')` and [`@allratestoday/mcp-server`](https://www.npmjs.com/package/@allratestoday/mcp-server) 0.6+ has a `get_official_rates` tool โ€” both return this source's latest table with no key, so you can add it without a second dependency
226
303
  - Claude Code plugin (no key): `/plugin marketplace add AllRates-Today/claude-code-plugin` then `/plugin install allratestoday@allratestoday` โ€” bundles both MCP servers plus an `/official-rate bcb ...` command
304
+ - Need dated tables or history for an evaluation? Agents can self-issue a trial key with no signup: `POST https://allratestoday.com/api/agent/keys` (send `Content-Type: application/json`) returns a 100-call key valid 7 days; the MCP servers expose it as `request_trial_key`
227
305
  - Machine-readable site guide: [llms.txt](https://allratestoday.com/llms.txt) ยท [for-ai-agents](https://allratestoday.com/for-ai-agents/)
228
306
 
229
307
  ## โš–๏ธ Published vs derived rates
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@allratestoday/bcb-exchange-rate",
3
- "version": "1.3.6",
3
+ "version": "1.3.9",
4
4
  "description": "Official Banco Central do Brasil (Brazil) daily exchange rates โ€” 156 currencies vs BRL, history since 2016. Zero-dependency Node.js/TypeScript client.",
5
5
  "keywords": [
6
6
  "bcb",