@ethersphere/bee-js 1.2.1 → 3.0.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.
- package/CHANGELOG.md +135 -2
- package/README.md +3 -1
- package/dist/index.browser.min.js +1 -1
- package/dist/index.browser.min.js.LICENSE.txt +51 -0
- package/dist/index.browser.min.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.LICENSE.txt +42 -0
- package/dist/index.min.js.map +1 -1
- package/dist/src/bee-debug.d.ts +75 -38
- package/dist/src/bee.d.ts +88 -82
- package/dist/src/chunk/soc.d.ts +6 -6
- package/dist/src/feed/index.d.ts +7 -7
- package/dist/src/feed/json.d.ts +2 -2
- package/dist/src/modules/bytes.d.ts +8 -11
- package/dist/src/modules/bzz.d.ts +9 -14
- package/dist/src/modules/chunk.d.ts +7 -11
- package/dist/src/modules/debug/balance.d.ts +9 -9
- package/dist/src/modules/debug/chequebook.d.ts +17 -18
- package/dist/src/modules/debug/chunk.d.ts +5 -5
- package/dist/src/modules/debug/connectivity.d.ts +7 -7
- package/dist/src/modules/debug/settlements.d.ts +5 -5
- package/dist/src/modules/debug/stamps.d.ts +7 -5
- package/dist/src/modules/debug/states.d.ts +5 -5
- package/dist/src/modules/debug/status.d.ts +5 -4
- package/dist/src/modules/debug/tag.d.ts +3 -3
- package/dist/src/modules/debug/transactions.d.ts +9 -9
- package/dist/src/modules/feed.d.ts +5 -5
- package/dist/src/modules/pinning.d.ts +9 -9
- package/dist/src/modules/pss.d.ts +4 -3
- package/dist/src/modules/soc.d.ts +3 -3
- package/dist/src/modules/status.d.ts +3 -2
- package/dist/src/modules/stewardship.d.ts +4 -4
- package/dist/src/modules/tag.d.ts +6 -6
- package/dist/src/types/debug.d.ts +4 -2
- package/dist/src/types/index.d.ts +71 -19
- package/dist/src/utils/bytes.d.ts +1 -1
- package/dist/src/utils/data.browser.d.ts +3 -1
- package/dist/src/utils/data.d.ts +7 -4
- package/dist/src/utils/expose.d.ts +6 -9
- package/dist/src/utils/headers.d.ts +3 -3
- package/dist/src/utils/http.d.ts +25 -0
- package/dist/src/utils/merge.d.ts +8 -0
- package/dist/src/utils/pss.d.ts +9 -0
- package/dist/src/utils/stream.d.ts +37 -0
- package/dist/src/utils/type.d.ts +19 -9
- package/package.json +15 -8
- package/.babelrc.js +0 -33
- package/.depcheckrc.json +0 -27
- package/.editorconfig +0 -6
- package/.eslintignore +0 -1
- package/.eslintrc.js +0 -108
- package/.gitattributes +0 -1
- package/.github/config.yaml +0 -23
- package/.github/workflows/check.yaml +0 -57
- package/.github/workflows/publish_npmjs.yaml +0 -20
- package/.github/workflows/release_github.yaml +0 -20
- package/.github/workflows/tests.yaml +0 -128
- package/.huskyrc +0 -5
- package/.prettierrc +0 -13
- package/.vscode/launch.json +0 -49
- package/.vscode/settings.json +0 -39
- package/CODEOWNERS +0 -1
- package/CODE_OF_CONDUCT.md +0 -76
- package/commitlint.config.js +0 -3
- package/dist/src/modules/stamps.d.ts +0 -4
- package/dist/src/utils/hooks.d.ts +0 -31
- package/dist/src/utils/safe-axios.d.ts +0 -8
- package/jest-puppeteer.config.js +0 -5
- package/jest.config.ts +0 -170
- package/src/bee-debug.ts +0 -440
- package/src/bee.ts +0 -941
- package/src/chunk/bmt.ts +0 -55
- package/src/chunk/cac.ts +0 -79
- package/src/chunk/serialize.ts +0 -16
- package/src/chunk/signer.ts +0 -141
- package/src/chunk/soc.ts +0 -190
- package/src/chunk/span.ts +0 -33
- package/src/feed/index.ts +0 -221
- package/src/feed/json.ts +0 -32
- package/src/feed/topic.ts +0 -23
- package/src/feed/type.ts +0 -12
- package/src/index.ts +0 -24
- package/src/modules/bytes.ts +0 -75
- package/src/modules/bzz.ts +0 -184
- package/src/modules/chunk.ts +0 -75
- package/src/modules/debug/balance.ts +0 -63
- package/src/modules/debug/chequebook.ts +0 -174
- package/src/modules/debug/chunk.ts +0 -39
- package/src/modules/debug/connectivity.ts +0 -61
- package/src/modules/debug/settlements.ts +0 -33
- package/src/modules/debug/stamps.ts +0 -69
- package/src/modules/debug/states.ts +0 -35
- package/src/modules/debug/status.ts +0 -34
- package/src/modules/debug/tag.ts +0 -19
- package/src/modules/debug/transactions.ts +0 -79
- package/src/modules/feed.ts +0 -92
- package/src/modules/pinning.ts +0 -74
- package/src/modules/pss.ts +0 -48
- package/src/modules/soc.ts +0 -41
- package/src/modules/stamps.ts +0 -59
- package/src/modules/status.ts +0 -13
- package/src/modules/stewardship.ts +0 -21
- package/src/modules/tag.ts +0 -83
- package/src/types/axios/index.d.ts +0 -18
- package/src/types/debug.ts +0 -204
- package/src/types/index.ts +0 -497
- package/src/types/tar-js.d.ts +0 -1
- package/src/types/webpack-bundle-analyzer/index.d.ts +0 -13
- package/src/utils/bytes.ts +0 -144
- package/src/utils/collection.ts +0 -151
- package/src/utils/data.browser.ts +0 -24
- package/src/utils/data.ts +0 -35
- package/src/utils/error.ts +0 -23
- package/src/utils/eth.ts +0 -229
- package/src/utils/expose.ts +0 -10
- package/src/utils/file.ts +0 -40
- package/src/utils/hash.ts +0 -16
- package/src/utils/headers.ts +0 -63
- package/src/utils/hex.ts +0 -186
- package/src/utils/hooks.ts +0 -89
- package/src/utils/safe-axios.ts +0 -98
- package/src/utils/tar.ts +0 -30
- package/src/utils/type.ts +0 -302
- package/src/utils/uint64.ts +0 -31
- package/src/utils/url.ts +0 -52
- package/test/bee.sh +0 -187
- package/test/data/1.txt +0 -1
- package/test/data/2.txt +0 -0
- package/test/data/empty +0 -0
- package/test/data/sub/3.txt +0 -1
- package/test/data/sub//303/251 +0 -0
- package/test/data/sub//360/237/230/216 +0 -0
- package/test/integration/bee-class.browser.spec.ts +0 -215
- package/test/integration/bee-class.spec.ts +0 -595
- package/test/integration/bee-debug-class.spec.ts +0 -85
- package/test/integration/chunk/bmt.spec.ts +0 -33
- package/test/integration/chunk/cac.spec.ts +0 -27
- package/test/integration/chunk/soc.spec.ts +0 -38
- package/test/integration/feed/index.spec.ts +0 -84
- package/test/integration/modules/bytes.spec.ts +0 -23
- package/test/integration/modules/bzz.spec.ts +0 -270
- package/test/integration/modules/chunk.spec.ts +0 -29
- package/test/integration/modules/debug/balance.spec.ts +0 -70
- package/test/integration/modules/debug/chequebook.spec.ts +0 -64
- package/test/integration/modules/debug/connectivity.spec.ts +0 -69
- package/test/integration/modules/debug/settlements.spec.ts +0 -34
- package/test/integration/modules/debug/states.spec.ts +0 -34
- package/test/integration/modules/debug/status.spec.ts +0 -65
- package/test/integration/modules/debug/tag.spec.ts +0 -27
- package/test/integration/modules/feed.spec.ts +0 -61
- package/test/integration/modules/pinning.spec.ts +0 -155
- package/test/integration/modules/pss.spec.ts +0 -92
- package/test/integration/modules/status.spec.ts +0 -10
- package/test/integration/modules/stewardship.spec.ts +0 -32
- package/test/integration/modules/tag.spec.ts +0 -51
- package/test/test-type-sequencer.js +0 -36
- package/test/testpage/testpage.html +0 -20
- package/test/unit/assertions.ts +0 -376
- package/test/unit/bee-class.spec.ts +0 -685
- package/test/unit/bee-debug-class.spec.ts +0 -365
- package/test/unit/chunk/bmt.spec.ts +0 -16
- package/test/unit/chunk/cac.spec.ts +0 -29
- package/test/unit/chunk/serialize.spec.ts +0 -24
- package/test/unit/chunk/signer.spec.ts +0 -140
- package/test/unit/chunk/soc.spec.ts +0 -25
- package/test/unit/chunk/span.spec.ts +0 -38
- package/test/unit/feed/json.spec.ts +0 -73
- package/test/unit/nock.ts +0 -134
- package/test/unit/utils/bytes.spec.ts +0 -32
- package/test/unit/utils/collection.spec.ts +0 -22
- package/test/unit/utils/eth.spec.ts +0 -224
- package/test/unit/utils/hex.spec.ts +0 -115
- package/test/unit/utils/hooks.spec.ts +0 -179
- package/test/unit/utils/safe-axios.spec.ts +0 -20
- package/test/unit/utils/type.spec.ts +0 -32
- package/test/unit/utils/uint64.spec.ts +0 -102
- package/test/utils.ts +0 -292
- package/tsconfig.json +0 -18
- package/tsconfig.test.json +0 -11
- package/typedoc.json +0 -7
- package/webpack.config.ts +0 -141
package/dist/src/bee-debug.d.ts
CHANGED
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
import type { Address, Peer, BalanceResponse, PeerBalance, ChequebookAddressResponse, ChequebookBalanceResponse, LastChequesResponse, LastChequesForPeerResponse, LastCashoutActionResponse, Settlements, AllSettlements, RemovePeerResponse, Topology, PingResponse, Health, NodeAddresses, ReserveState, ChainState, NumberString, ExtendedTag, PostageBatchBuckets, DebugPostageBatch, TransactionInfo, TransactionHash } from './types';
|
|
2
|
-
import { BatchId, CashoutOptions, PostageBatchOptions, Tag } from './types';
|
|
3
|
-
/**
|
|
4
|
-
* The BeeDebug class provides a way of interacting with the Bee debug APIs based on the provided url
|
|
5
|
-
*
|
|
6
|
-
* @param url URL of a running Bee node
|
|
7
|
-
*/
|
|
2
|
+
import { BatchId, BeeOptions, CashoutOptions, PostageBatchOptions, RequestOptions, Tag } from './types';
|
|
8
3
|
export declare class BeeDebug {
|
|
4
|
+
/**
|
|
5
|
+
* URL on which is the Debug API of Bee node exposed
|
|
6
|
+
*/
|
|
9
7
|
readonly url: string;
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
/**
|
|
9
|
+
* Ky instance that defines connection to Bee node
|
|
10
|
+
* @private
|
|
11
|
+
*/
|
|
12
|
+
private readonly ky;
|
|
13
|
+
constructor(url: string, options?: BeeOptions);
|
|
14
|
+
getNodeAddresses(options?: RequestOptions): Promise<NodeAddresses>;
|
|
15
|
+
getBlocklist(options?: RequestOptions): Promise<Peer[]>;
|
|
13
16
|
/**
|
|
14
17
|
* Retrieve tag extended information from Bee node
|
|
15
18
|
*
|
|
@@ -20,61 +23,61 @@ export declare class BeeDebug {
|
|
|
20
23
|
* @see [Bee API reference - `GET /tags/{uid}`](https://docs.ethswarm.org/debug-api/#tag/Tag)
|
|
21
24
|
*
|
|
22
25
|
*/
|
|
23
|
-
retrieveExtendedTag(tagUid: number | Tag): Promise<ExtendedTag>;
|
|
26
|
+
retrieveExtendedTag(tagUid: number | Tag, options?: RequestOptions): Promise<ExtendedTag>;
|
|
24
27
|
/**
|
|
25
28
|
* Get list of peers for this node
|
|
26
29
|
*/
|
|
27
|
-
getPeers(): Promise<Peer[]>;
|
|
28
|
-
removePeer(peer: string | Address): Promise<RemovePeerResponse>;
|
|
29
|
-
getTopology(): Promise<Topology>;
|
|
30
|
-
pingPeer(peer: string | Address): Promise<PingResponse>;
|
|
30
|
+
getPeers(options?: RequestOptions): Promise<Peer[]>;
|
|
31
|
+
removePeer(peer: string | Address, options?: RequestOptions): Promise<RemovePeerResponse>;
|
|
32
|
+
getTopology(options?: RequestOptions): Promise<Topology>;
|
|
33
|
+
pingPeer(peer: string | Address, options?: RequestOptions): Promise<PingResponse>;
|
|
31
34
|
/**
|
|
32
35
|
* Get the balances with all known peers including prepaid services
|
|
33
36
|
*/
|
|
34
|
-
getAllBalances(): Promise<BalanceResponse>;
|
|
37
|
+
getAllBalances(options?: RequestOptions): Promise<BalanceResponse>;
|
|
35
38
|
/**
|
|
36
39
|
* Get the balances with a specific peer including prepaid services
|
|
37
40
|
*
|
|
38
41
|
* @param address Swarm address of peer
|
|
39
42
|
*/
|
|
40
|
-
getPeerBalance(address: Address | string): Promise<PeerBalance>;
|
|
43
|
+
getPeerBalance(address: Address | string, options?: RequestOptions): Promise<PeerBalance>;
|
|
41
44
|
/**
|
|
42
45
|
* Get the past due consumption balances with all known peers
|
|
43
46
|
*/
|
|
44
|
-
getPastDueConsumptionBalances(): Promise<BalanceResponse>;
|
|
47
|
+
getPastDueConsumptionBalances(options?: RequestOptions): Promise<BalanceResponse>;
|
|
45
48
|
/**
|
|
46
49
|
* Get the past due consumption balance with a specific peer
|
|
47
50
|
*
|
|
48
51
|
* @param address Swarm address of peer
|
|
49
52
|
*/
|
|
50
|
-
getPastDueConsumptionPeerBalance(address: Address | string): Promise<PeerBalance>;
|
|
53
|
+
getPastDueConsumptionPeerBalance(address: Address | string, options?: RequestOptions): Promise<PeerBalance>;
|
|
51
54
|
/**
|
|
52
55
|
* Get the address of the chequebook contract used.
|
|
53
56
|
*
|
|
54
57
|
* **Warning:** The address is returned with 0x prefix unlike all other calls.
|
|
55
58
|
* https://github.com/ethersphere/bee/issues/1443
|
|
56
59
|
*/
|
|
57
|
-
getChequebookAddress(): Promise<ChequebookAddressResponse>;
|
|
60
|
+
getChequebookAddress(options?: RequestOptions): Promise<ChequebookAddressResponse>;
|
|
58
61
|
/**
|
|
59
62
|
* Get the balance of the chequebook
|
|
60
63
|
*/
|
|
61
|
-
getChequebookBalance(): Promise<ChequebookBalanceResponse>;
|
|
64
|
+
getChequebookBalance(options?: RequestOptions): Promise<ChequebookBalanceResponse>;
|
|
62
65
|
/**
|
|
63
66
|
* Get last cheques for all peers
|
|
64
67
|
*/
|
|
65
|
-
getLastCheques(): Promise<LastChequesResponse>;
|
|
68
|
+
getLastCheques(options?: RequestOptions): Promise<LastChequesResponse>;
|
|
66
69
|
/**
|
|
67
70
|
* Get last cheques for the peer
|
|
68
71
|
*
|
|
69
72
|
* @param address Swarm address of peer
|
|
70
73
|
*/
|
|
71
|
-
getLastChequesForPeer(address: Address | string): Promise<LastChequesForPeerResponse>;
|
|
74
|
+
getLastChequesForPeer(address: Address | string, options?: RequestOptions): Promise<LastChequesForPeerResponse>;
|
|
72
75
|
/**
|
|
73
76
|
* Get last cashout action for the peer
|
|
74
77
|
*
|
|
75
78
|
* @param address Swarm address of peer
|
|
76
79
|
*/
|
|
77
|
-
getLastCashoutAction(address: Address | string): Promise<LastCashoutActionResponse>;
|
|
80
|
+
getLastCashoutAction(address: Address | string, options?: RequestOptions): Promise<LastCashoutActionResponse>;
|
|
78
81
|
/**
|
|
79
82
|
* Cashout the last cheque for the peer
|
|
80
83
|
*
|
|
@@ -91,7 +94,7 @@ export declare class BeeDebug {
|
|
|
91
94
|
* @param gasPrice Gas Price in WEI for the transaction call
|
|
92
95
|
* @return string Hash of the transaction
|
|
93
96
|
*/
|
|
94
|
-
depositTokens(amount: number | NumberString, gasPrice?: NumberString): Promise<string>;
|
|
97
|
+
depositTokens(amount: number | NumberString, gasPrice?: NumberString, options?: RequestOptions): Promise<string>;
|
|
95
98
|
/**
|
|
96
99
|
* Withdraw tokens from the chequebook to the overlay address
|
|
97
100
|
*
|
|
@@ -99,35 +102,35 @@ export declare class BeeDebug {
|
|
|
99
102
|
* @param gasPrice Gas Price in WEI for the transaction call
|
|
100
103
|
* @return string Hash of the transaction
|
|
101
104
|
*/
|
|
102
|
-
withdrawTokens(amount: number | NumberString, gasPrice?: NumberString): Promise<string>;
|
|
105
|
+
withdrawTokens(amount: number | NumberString, gasPrice?: NumberString, options?: RequestOptions): Promise<string>;
|
|
103
106
|
/**
|
|
104
107
|
* Get amount of sent and received from settlements with a peer
|
|
105
108
|
*
|
|
106
109
|
* @param address Swarm address of peer
|
|
107
110
|
*/
|
|
108
|
-
getSettlements(address: Address | string): Promise<Settlements>;
|
|
111
|
+
getSettlements(address: Address | string, options?: RequestOptions): Promise<Settlements>;
|
|
109
112
|
/**
|
|
110
113
|
* Get settlements with all known peers and total amount sent or received
|
|
111
114
|
*/
|
|
112
|
-
getAllSettlements(): Promise<AllSettlements>;
|
|
115
|
+
getAllSettlements(options?: RequestOptions): Promise<AllSettlements>;
|
|
113
116
|
/**
|
|
114
117
|
* Get health of node
|
|
115
118
|
*/
|
|
116
|
-
getHealth(): Promise<Health>;
|
|
119
|
+
getHealth(options?: RequestOptions): Promise<Health>;
|
|
117
120
|
/**
|
|
118
121
|
* Connnects to a node and checks if it is a supported Bee version by the bee-js
|
|
119
122
|
*
|
|
120
123
|
* @returns true if the Bee node version is supported
|
|
121
124
|
*/
|
|
122
|
-
isSupportedVersion(): Promise<boolean> | never;
|
|
125
|
+
isSupportedVersion(options?: RequestOptions): Promise<boolean> | never;
|
|
123
126
|
/**
|
|
124
127
|
* Get reserve state
|
|
125
128
|
*/
|
|
126
|
-
getReserveState(): Promise<ReserveState>;
|
|
129
|
+
getReserveState(options?: RequestOptions): Promise<ReserveState>;
|
|
127
130
|
/**
|
|
128
131
|
* Get chain state
|
|
129
132
|
*/
|
|
130
|
-
getChainState(): Promise<ChainState>;
|
|
133
|
+
getChainState(options?: RequestOptions): Promise<ChainState>;
|
|
131
134
|
/**
|
|
132
135
|
* Creates new postage batch from the funds that the node has available in its Ethereum account.
|
|
133
136
|
*
|
|
@@ -146,6 +149,39 @@ export declare class BeeDebug {
|
|
|
146
149
|
* @see [Bee Debug API reference - `POST /stamps`](https://docs.ethswarm.org/debug-api/#tag/Postage-Stamps/paths/~1stamps~1{amount}~1{depth}/post)
|
|
147
150
|
*/
|
|
148
151
|
createPostageBatch(amount: NumberString, depth: number, options?: PostageBatchOptions): Promise<BatchId>;
|
|
152
|
+
/**
|
|
153
|
+
* Topup a fresh amount of BZZ to given Postage Batch.
|
|
154
|
+
*
|
|
155
|
+
* For better understanding what each parameter means and what are the optimal values please see
|
|
156
|
+
* [Bee docs - Keep your data alive / Postage stamps](https://docs.ethswarm.org/docs/access-the-swarm/keep-your-data-alive).
|
|
157
|
+
*
|
|
158
|
+
* **WARNING: THIS CREATES TRANSACTIONS THAT SPENDS MONEY**
|
|
159
|
+
*
|
|
160
|
+
* @param postageBatchId Batch ID
|
|
161
|
+
* @param amount Amount to be added to the batch
|
|
162
|
+
* @param options Request options
|
|
163
|
+
*
|
|
164
|
+
* @see [Bee docs - Keep your data alive / Postage stamps](https://docs.ethswarm.org/docs/access-the-swarm/keep-your-data-alive)
|
|
165
|
+
* @see [Bee Debug API reference - `PATCH /stamps/topup/${id}/${amount}`](https://docs.ethswarm.org/debug-api/#tag/Postage-Stamps/paths/~1stamps~1topup~1{id}~1{amount}/patch)
|
|
166
|
+
*/
|
|
167
|
+
topUpBatch(postageBatchId: BatchId | string, amount: NumberString, options?: RequestOptions): Promise<void>;
|
|
168
|
+
/**
|
|
169
|
+
* Dilute given Postage Batch with new depth (that has to be bigger then the original depth), which allows
|
|
170
|
+
* the Postage Batch to be used for more chunks.
|
|
171
|
+
*
|
|
172
|
+
* For better understanding what each parameter means and what are the optimal values please see
|
|
173
|
+
* [Bee docs - Keep your data alive / Postage stamps](https://docs.ethswarm.org/docs/access-the-swarm/keep-your-data-alive).
|
|
174
|
+
*
|
|
175
|
+
* **WARNING: THIS CREATES TRANSACTIONS THAT SPENDS MONEY**
|
|
176
|
+
*
|
|
177
|
+
* @param postageBatchId Batch ID
|
|
178
|
+
* @param depth Amount to be added to the batch
|
|
179
|
+
* @param options Request options
|
|
180
|
+
*
|
|
181
|
+
* @see [Bee docs - Keep your data alive / Postage stamps](https://docs.ethswarm.org/docs/access-the-swarm/keep-your-data-alive)
|
|
182
|
+
* @see [Bee Debug API reference - `PATCH /stamps/topup/${id}/${amount}`](https://docs.ethswarm.org/debug-api/#tag/Postage-Stamps/paths/~1stamps~1topup~1{id}~1{amount}/patch)
|
|
183
|
+
*/
|
|
184
|
+
diluteBatch(postageBatchId: BatchId | string, depth: number, options?: RequestOptions): Promise<void>;
|
|
149
185
|
/**
|
|
150
186
|
* Return details for specific postage batch.
|
|
151
187
|
*
|
|
@@ -154,7 +190,7 @@ export declare class BeeDebug {
|
|
|
154
190
|
* @see [Bee docs - Keep your data alive / Postage stamps](https://docs.ethswarm.org/docs/access-the-swarm/keep-your-data-alive)
|
|
155
191
|
* @see [Bee Debug API reference - `GET /stamps/${id}`](https://docs.ethswarm.org/debug-api/#tag/Postage-Stamps/paths/~1stamps~1{id}/get)
|
|
156
192
|
*/
|
|
157
|
-
getPostageBatch(postageBatchId: BatchId | string): Promise<DebugPostageBatch>;
|
|
193
|
+
getPostageBatch(postageBatchId: BatchId | string, options?: RequestOptions): Promise<DebugPostageBatch>;
|
|
158
194
|
/**
|
|
159
195
|
* Return detailed information related to buckets for specific postage batch.
|
|
160
196
|
*
|
|
@@ -163,34 +199,35 @@ export declare class BeeDebug {
|
|
|
163
199
|
* @see [Bee docs - Keep your data alive / Postage stamps](https://docs.ethswarm.org/docs/access-the-swarm/keep-your-data-alive)
|
|
164
200
|
* @see [Bee Debug API reference - `GET /stamps/${id}/buckets`](https://docs.ethswarm.org/debug-api/#tag/Postage-Stamps/paths/~1stamps~1{id}~1buckets/get)
|
|
165
201
|
*/
|
|
166
|
-
getPostageBatchBuckets(postageBatchId: BatchId | string): Promise<PostageBatchBuckets>;
|
|
202
|
+
getPostageBatchBuckets(postageBatchId: BatchId | string, options?: RequestOptions): Promise<PostageBatchBuckets>;
|
|
167
203
|
/**
|
|
168
204
|
* Return all postage batches that has the node available.
|
|
169
205
|
*
|
|
170
206
|
* @see [Bee docs - Keep your data alive / Postage stamps](https://docs.ethswarm.org/docs/access-the-swarm/keep-your-data-alive)
|
|
171
207
|
* @see [Bee Debug API reference - `GET /stamps`](https://docs.ethswarm.org/debug-api/#tag/Postage-Stamps/paths/~1stamps/get)
|
|
172
208
|
*/
|
|
173
|
-
getAllPostageBatch(): Promise<DebugPostageBatch[]>;
|
|
209
|
+
getAllPostageBatch(options?: RequestOptions): Promise<DebugPostageBatch[]>;
|
|
174
210
|
/**
|
|
175
211
|
* Return lists of all current pending transactions that the Bee made
|
|
176
212
|
*/
|
|
177
|
-
getAllPendingTransactions(): Promise<TransactionInfo[]>;
|
|
213
|
+
getAllPendingTransactions(options?: RequestOptions): Promise<TransactionInfo[]>;
|
|
178
214
|
/**
|
|
179
215
|
* Return transaction information for specific transaction
|
|
180
216
|
* @param transactionHash
|
|
181
217
|
*/
|
|
182
|
-
getPendingTransaction(transactionHash: TransactionHash | string): Promise<TransactionInfo>;
|
|
218
|
+
getPendingTransaction(transactionHash: TransactionHash | string, options?: RequestOptions): Promise<TransactionInfo>;
|
|
183
219
|
/**
|
|
184
220
|
* Rebroadcast already created transaction.
|
|
185
221
|
* This is mainly needed when your transaction fall off mempool from other reason is not incorporated into block.
|
|
186
222
|
*
|
|
187
223
|
* @param transactionHash
|
|
188
224
|
*/
|
|
189
|
-
rebroadcastPendingTransaction(transactionHash: TransactionHash | string): Promise<TransactionHash>;
|
|
225
|
+
rebroadcastPendingTransaction(transactionHash: TransactionHash | string, options?: RequestOptions): Promise<TransactionHash>;
|
|
190
226
|
/**
|
|
191
227
|
* Cancel currently pending transaction
|
|
192
228
|
* @param transactionHash
|
|
193
229
|
* @param gasPrice
|
|
194
230
|
*/
|
|
195
|
-
cancelPendingTransaction(transactionHash: TransactionHash | string, gasPrice?: NumberString): Promise<TransactionHash>;
|
|
231
|
+
cancelPendingTransaction(transactionHash: TransactionHash | string, gasPrice?: NumberString, options?: RequestOptions): Promise<TransactionHash>;
|
|
232
|
+
private getKy;
|
|
196
233
|
}
|