@atomicfinance/bitcoin-esplora-batch-api-provider 3.4.7 → 3.5.0

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.
@@ -11,13 +11,13 @@ class BitcoinEsploraBatchApiProvider extends bitcoin_esplora_api_provider_1.Bitc
11
11
  this._batchAxios = new node_provider_1.NodeProvider({
12
12
  baseURL: options.batchUrl,
13
13
  responseType: 'text',
14
- transformResponse: undefined,
14
+ transformResponse: undefined, // https://github.com/axios/axios/issues/907,
15
15
  });
16
16
  }
17
17
  async getUnspentTransactions(_addresses) {
18
18
  const addresses = _addresses.map(utils_1.addressToString);
19
19
  const data = await this._batchAxios.nodePost('/addresses/utxo', {
20
- addresses: lodash_1.uniq(addresses),
20
+ addresses: (0, lodash_1.uniq)(addresses),
21
21
  });
22
22
  const utxos = data.map(({ address, utxo }) => {
23
23
  return utxo.map((obj) => ({
@@ -28,12 +28,12 @@ class BitcoinEsploraBatchApiProvider extends bitcoin_esplora_api_provider_1.Bitc
28
28
  blockHeight: obj.status.block_height,
29
29
  }));
30
30
  });
31
- return lodash_1.flatten(utxos);
31
+ return (0, lodash_1.flatten)(utxos);
32
32
  }
33
33
  async getAddressTransactionCounts(_addresses) {
34
34
  const addresses = _addresses.map(utils_1.addressToString);
35
35
  const data = await this._batchAxios.nodePost('/addresses', {
36
- addresses: lodash_1.uniq(addresses),
36
+ addresses: (0, lodash_1.uniq)(addresses),
37
37
  });
38
38
  return data.reduce((acc, obj) => {
39
39
  acc[obj.address] = obj.chain_stats.tx_count + obj.mempool_stats.tx_count;
@@ -1 +1 @@
1
- {"version":3,"file":"BitcoinEsploraBatchApiProvider.js","sourceRoot":"","sources":["../lib/BitcoinEsploraBatchApiProvider.ts"],"names":[],"mappings":";;AAAA,8FAIqD;AACrD,gEAA4D;AAC5D,gDAA0D;AAC1D,gDAAuD;AACvD,mCAAuC;AAQvC,MAAqB,8BAA+B,SAAQ,wDAAyB;IAGnF,YAAY,O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AI,iBAAS,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE;gBAC1D,WAAW,EAAE,GAAG,CAAC,MAAM,CAAC,YAAY;aACrC,CAAC,CAAC,CAAC;QACN,CAAC,CAAC,CAAC;QAEH,OAAO,IAAA,gBAAO,EAAC,KAAK,CAAC,CAAC;IACxB,CAAC;IAED,KAAK,CAAC,2BAA2B,CAAC,UAAgC;QAChE,MAAM,SAAS,GAAG,UAAU,CAAC,GAAG,CAAC,uBAAe,CAAC,CAAC;QAClD,MAAM,IAAI,GAAsB,MAAM,IAAI,CAAC,WAAW,CAAC,QAAQ,CAC7D,YAAY,EACZ;YACE,SAAS,EAAE,IAAA,aAAI,EAAC,SAAS,CAAC;SAC3B,CACF,CAAC;QAEF,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,GAAgC,EAAE,GAAG,EAAE,EAAE;YAC3D,GAAG,CAAC,GAAG,CAAC,OAAO,CAAC,GAAG,GAAG,CAAC,WAAW,CAAC,QAAQ,GAAG,GAAG,CAAC,aAAa,CAAC,QAAQ,CAAC;YACzE,OAAO,GAAG,CAAC;QACb,CAAC,EAAE,EAAE,CAAC,CAAC;IACT,CAAC;CACF;AAjDD,iDAiDC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atomicfinance/bitcoin-esplora-batch-api-provider",
3
- "version": "3.4.7",
3
+ "version": "3.5.0",
4
4
  "description": "",
5
5
  "module": "dist/index.js",
6
6
  "main": "dist/index.js",
@@ -24,10 +24,10 @@
24
24
  "node": ">=14"
25
25
  },
26
26
  "dependencies": {
27
- "@atomicfinance/bitcoin-esplora-api-provider": "^3.4.7",
28
- "@atomicfinance/node-provider": "^3.4.7",
29
- "@atomicfinance/types": "^3.4.7",
30
- "@atomicfinance/utils": "^3.4.7",
27
+ "@atomicfinance/bitcoin-esplora-api-provider": "^3.5.0",
28
+ "@atomicfinance/node-provider": "^3.5.0",
29
+ "@atomicfinance/types": "^3.5.0",
30
+ "@atomicfinance/utils": "^3.5.0",
31
31
  "@babel/runtime": "^7.12.1",
32
32
  "bignumber.js": "^9.0.0",
33
33
  "lodash": "^4.17.20"
package/CHANGELOG.md DELETED
@@ -1,219 +0,0 @@
1
- # @atomicfinance/bitcoin-esplora-batch-api-provider
2
-
3
- ## 3.4.7
4
-
5
- ### Patch Changes
6
-
7
- - 0ba01ef: Bump @node-dlc to 0.23.6
8
- - Updated dependencies [0ba01ef]
9
- - @atomicfinance/types@3.4.7
10
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.7
11
- - @atomicfinance/node-provider@3.4.7
12
- - @atomicfinance/utils@3.4.7
13
-
14
- ## 3.4.6
15
-
16
- ### Patch Changes
17
-
18
- - b765b9c: Bump nodep-dlc to 0.23.5
19
- - Updated dependencies [b765b9c]
20
- - @atomicfinance/types@3.4.6
21
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.6
22
- - @atomicfinance/node-provider@3.4.6
23
- - @atomicfinance/utils@3.4.6
24
-
25
- ## 3.4.5
26
-
27
- ### Patch Changes
28
-
29
- - 74b7a4f: Bump node-dlc to 0.23.4
30
- - Updated dependencies [74b7a4f]
31
- - @atomicfinance/types@3.4.5
32
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.5
33
- - @atomicfinance/node-provider@3.4.5
34
- - @atomicfinance/utils@3.4.5
35
-
36
- ## 3.4.4
37
-
38
- ### Patch Changes
39
-
40
- - cc8f06a: Bump node-dlc to 0.23.3
41
- - Updated dependencies [cc8f06a]
42
- - @atomicfinance/types@3.4.4
43
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.4
44
- - @atomicfinance/node-provider@3.4.4
45
- - @atomicfinance/utils@3.4.4
46
-
47
- ## 3.4.3
48
-
49
- ### Patch Changes
50
-
51
- - db49017: Bump node-dlc to 0.23.2 for all packages
52
- - Updated dependencies [db49017]
53
- - @atomicfinance/types@3.4.3
54
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.3
55
- - @atomicfinance/node-provider@3.4.3
56
- - @atomicfinance/utils@3.4.3
57
-
58
- ## 3.4.2
59
-
60
- ### Patch Changes
61
-
62
- - e701ba6: Bump node-dlc- to 0.23.1 and add node-dlc batch tx builder validation tests
63
- - Updated dependencies [e701ba6]
64
- - @atomicfinance/types@3.4.2
65
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.2
66
- - @atomicfinance/node-provider@3.4.2
67
- - @atomicfinance/utils@3.4.2
68
-
69
- ## 3.4.1
70
-
71
- ### Patch Changes
72
-
73
- - 9781efe: Add getInputsForDualFunding functionality and bump @node-dlc
74
- - Updated dependencies [9781efe]
75
- - @atomicfinance/types@3.4.1
76
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.1
77
- - @atomicfinance/node-provider@3.4.1
78
- - @atomicfinance/utils@3.4.1
79
-
80
- ## 3.4.0
81
-
82
- ### Minor Changes
83
-
84
- - 314d7d7: Add batch dlc funding transactions
85
-
86
- ### Patch Changes
87
-
88
- - Updated dependencies [314d7d7]
89
- - @atomicfinance/types@3.4.0
90
- - @atomicfinance/bitcoin-esplora-api-provider@3.4.0
91
- - @atomicfinance/node-provider@3.4.0
92
- - @atomicfinance/utils@3.4.0
93
-
94
- ## 3.3.1
95
-
96
- ### Patch Changes
97
-
98
- - 7f6f4a8: Fix rounding error with find payout
99
- - Updated dependencies [7f6f4a8]
100
- - @atomicfinance/bitcoin-esplora-api-provider@3.3.1
101
- - @atomicfinance/node-provider@3.3.1
102
- - @atomicfinance/types@3.3.1
103
- - @atomicfinance/utils@3.3.1
104
-
105
- ## 3.3.0
106
-
107
- ### Minor Changes
108
-
109
- - 4a512ee: Fix find outcome index for hyperbola payout curve edge case
110
-
111
- ### Patch Changes
112
-
113
- - Updated dependencies [4a512ee]
114
- - @atomicfinance/bitcoin-esplora-api-provider@3.3.0
115
- - @atomicfinance/node-provider@3.3.0
116
- - @atomicfinance/types@3.3.0
117
- - @atomicfinance/utils@3.3.0
118
-
119
- ## 3.2.5
120
-
121
- ### Patch Changes
122
-
123
- - Updated dependencies [a72c7b9]
124
- - @atomicfinance/types@3.2.5
125
- - @atomicfinance/bitcoin-esplora-api-provider@3.2.5
126
- - @atomicfinance/node-provider@3.2.5
127
- - @atomicfinance/utils@3.2.5
128
-
129
- ## 3.2.4
130
-
131
- ### Patch Changes
132
-
133
- - 177b76a: Upgrade node-dlc to 0.22.4
134
- - Updated dependencies [177b76a]
135
- - @atomicfinance/bitcoin-esplora-api-provider@3.2.4
136
- - @atomicfinance/node-provider@3.2.4
137
- - @atomicfinance/types@3.2.4
138
- - @atomicfinance/utils@3.2.4
139
-
140
- ## 3.2.3
141
-
142
- ### Patch Changes
143
-
144
- - @atomicfinance/bitcoin-esplora-api-provider@3.2.3
145
- - @atomicfinance/node-provider@3.2.3
146
- - @atomicfinance/types@3.2.3
147
- - @atomicfinance/utils@3.2.3
148
-
149
- ## 3.2.2
150
-
151
- ### Patch Changes
152
-
153
- - @atomicfinance/bitcoin-esplora-api-provider@3.2.2
154
- - @atomicfinance/node-provider@3.2.2
155
- - @atomicfinance/types@3.2.2
156
- - @atomicfinance/utils@3.2.2
157
-
158
- ## 3.2.1
159
-
160
- ### Patch Changes
161
-
162
- - Updated dependencies [f69141e]
163
- - @atomicfinance/types@3.2.1
164
- - @atomicfinance/bitcoin-esplora-api-provider@3.2.1
165
- - @atomicfinance/node-provider@3.2.1
166
- - @atomicfinance/utils@3.2.1
167
-
168
- ## 3.2.0
169
-
170
- ### Patch Changes
171
-
172
- - Updated dependencies [dc9ac8a]
173
- - @atomicfinance/types@3.2.0
174
- - @atomicfinance/bitcoin-esplora-api-provider@3.2.0
175
- - @atomicfinance/node-provider@3.2.0
176
- - @atomicfinance/utils@3.2.0
177
-
178
- ## 3.1.1
179
-
180
- ### Patch Changes
181
-
182
- - @atomicfinance/bitcoin-esplora-api-provider@3.1.1
183
- - @atomicfinance/node-provider@3.1.1
184
- - @atomicfinance/types@3.1.1
185
- - @atomicfinance/utils@3.1.1
186
-
187
- ## 3.1.0
188
-
189
- ### Patch Changes
190
-
191
- - Updated dependencies [c60033b]
192
- - @atomicfinance/types@3.1.0
193
- - @atomicfinance/bitcoin-esplora-api-provider@3.1.0
194
- - @atomicfinance/node-provider@3.1.0
195
- - @atomicfinance/utils@3.1.0
196
-
197
- ## 3.0.1
198
-
199
- ### Patch Changes
200
-
201
- - Updated dependencies [0ff98b5]
202
- - @atomicfinance/node-provider@3.0.1
203
- - @atomicfinance/bitcoin-esplora-api-provider@3.0.1
204
- - @atomicfinance/types@3.0.1
205
- - @atomicfinance/utils@3.0.1
206
-
207
- ## 3.0.0
208
-
209
- ### Major Changes
210
-
211
- - a06082e: Create unified standalone `bitcoin-abstraction-layer` package
212
-
213
- ### Patch Changes
214
-
215
- - Updated dependencies [a06082e]
216
- - @atomicfinance/types@3.0.0
217
- - @atomicfinance/bitcoin-esplora-api-provider@3.0.0
218
- - @atomicfinance/node-provider@3.0.0
219
- - @atomicfinance/utils@3.0.0