@bitgo-beta/sdk-coin-eth 4.4.1-beta.99 → 4.4.1-beta.990

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 (67) hide show
  1. package/CHANGELOG.md +1460 -0
  2. package/dist/src/erc20Token.d.ts +13 -5
  3. package/dist/src/erc20Token.d.ts.map +1 -1
  4. package/dist/src/erc20Token.js +61 -23
  5. package/dist/src/eth.d.ts +22 -533
  6. package/dist/src/eth.d.ts.map +1 -1
  7. package/dist/src/eth.js +198 -1613
  8. package/dist/src/gteth.d.ts +0 -4
  9. package/dist/src/gteth.d.ts.map +1 -1
  10. package/dist/src/gteth.js +1 -11
  11. package/dist/src/hteth.d.ts +8 -0
  12. package/dist/src/hteth.d.ts.map +1 -0
  13. package/dist/src/hteth.js +14 -0
  14. package/dist/src/index.d.ts +1 -0
  15. package/dist/src/index.d.ts.map +1 -1
  16. package/dist/src/index.js +7 -2
  17. package/dist/src/lib/index.d.ts +5 -13
  18. package/dist/src/lib/index.d.ts.map +1 -1
  19. package/dist/src/lib/index.js +18 -30
  20. package/dist/src/lib/messages/index.d.ts +3 -0
  21. package/dist/src/lib/messages/index.d.ts.map +1 -0
  22. package/dist/src/lib/messages/index.js +6 -0
  23. package/dist/src/lib/transactionBuilder.d.ts +9 -213
  24. package/dist/src/lib/transactionBuilder.d.ts.map +1 -1
  25. package/dist/src/lib/transactionBuilder.js +18 -677
  26. package/dist/src/lib/transferBuilder.d.ts +2 -50
  27. package/dist/src/lib/transferBuilder.d.ts.map +1 -1
  28. package/dist/src/lib/transferBuilder.js +3 -199
  29. package/dist/src/lib/transferBuilders/index.d.ts +2 -3
  30. package/dist/src/lib/transferBuilders/index.d.ts.map +1 -1
  31. package/dist/src/lib/transferBuilders/index.js +6 -14
  32. package/dist/src/lib/walletUtil.d.ts +0 -25
  33. package/dist/src/lib/walletUtil.d.ts.map +1 -1
  34. package/dist/src/lib/walletUtil.js +2 -27
  35. package/dist/src/register.d.ts.map +1 -1
  36. package/dist/src/register.js +3 -1
  37. package/dist/src/teth.d.ts +0 -3
  38. package/dist/src/teth.d.ts.map +1 -1
  39. package/dist/src/teth.js +1 -8
  40. package/package.json +12 -17
  41. package/dist/src/lib/contractCall.d.ts +0 -8
  42. package/dist/src/lib/contractCall.d.ts.map +0 -1
  43. package/dist/src/lib/contractCall.js +0 -17
  44. package/dist/src/lib/iface.d.ts +0 -130
  45. package/dist/src/lib/iface.d.ts.map +0 -1
  46. package/dist/src/lib/iface.js +0 -8
  47. package/dist/src/lib/keyPair.d.ts +0 -26
  48. package/dist/src/lib/keyPair.d.ts.map +0 -1
  49. package/dist/src/lib/keyPair.js +0 -66
  50. package/dist/src/lib/transaction.d.ts +0 -64
  51. package/dist/src/lib/transaction.d.ts.map +0 -1
  52. package/dist/src/lib/transaction.js +0 -137
  53. package/dist/src/lib/transferBuilders/baseNFTTransferBuilder.d.ts +0 -47
  54. package/dist/src/lib/transferBuilders/baseNFTTransferBuilder.d.ts.map +0 -1
  55. package/dist/src/lib/transferBuilders/baseNFTTransferBuilder.js +0 -113
  56. package/dist/src/lib/transferBuilders/transferBuilderERC1155.d.ts +0 -14
  57. package/dist/src/lib/transferBuilders/transferBuilderERC1155.d.ts.map +0 -1
  58. package/dist/src/lib/transferBuilders/transferBuilderERC1155.js +0 -83
  59. package/dist/src/lib/transferBuilders/transferBuilderERC721.d.ts +0 -13
  60. package/dist/src/lib/transferBuilders/transferBuilderERC721.d.ts.map +0 -1
  61. package/dist/src/lib/transferBuilders/transferBuilderERC721.js +0 -68
  62. package/dist/src/lib/types.d.ts +0 -39
  63. package/dist/src/lib/types.d.ts.map +0 -1
  64. package/dist/src/lib/types.js +0 -137
  65. package/dist/src/lib/utils.d.ts +0 -227
  66. package/dist/src/lib/utils.d.ts.map +0 -1
  67. package/dist/src/lib/utils.js +0 -577
package/dist/src/eth.d.ts CHANGED
@@ -1,243 +1,18 @@
1
- /// <reference types="node" />
2
- import { AddressCoinSpecific, BaseCoin, BitGoBase, FeeEstimateOptions, FullySignedTransaction, HalfSignedTransaction, IWallet, KeyPair, MPCAlgorithm, ParsedTransaction, ParseTransactionOptions, PrebuildTransactionResult, PresignTransactionOptions as BasePresignTransactionOptions, Recipient, SignTransactionOptions as BaseSignTransactionOptions, TransactionParams, TransactionPrebuild as BaseTransactionPrebuild, TransactionRecipient, TypedData, VerifyAddressOptions as BaseVerifyAddressOptions, VerifyTransactionOptions, Wallet } from '@bitgo-beta/sdk-core';
3
- import { BaseCoin as StaticsBaseCoin, EthereumNetwork } from '@bitgo-beta/statics';
1
+ import { BaseCoin, BitGoBase, FullySignedTransaction, HalfSignedTransaction, MPCAlgorithm, Recipient, MultisigType } from '@bitgo-beta/sdk-core';
2
+ import { AbstractEthLikeNewCoins, BuildOptions, BuildTransactionParams, FeesUsed, GetBatchExecutionInfoRT, GetSendMethodArgsOptions, RecoveryInfo, RecoverOptions, SendMethodArgs, SignedTransaction, SignFinalOptions, SignTransactionOptions, TransactionPrebuild, OfflineVaultTxInfo, optionalDeps, UnsignedSweepTxMPCv2 } from '@bitgo-beta/abstract-eth';
3
+ import { BaseCoin as StaticsBaseCoin } from '@bitgo-beta/statics';
4
4
  import type * as EthTxLib from '@ethereumjs/tx';
5
- import type * as EthCommon from '@ethereumjs/common';
6
5
  import { TransactionBuilder } from './lib';
7
- export { Recipient, HalfSignedTransaction, FullySignedTransaction };
8
- export declare const optionalDeps: {
9
- readonly ethAbi: any;
10
- readonly ethUtil: any;
11
- readonly EthTx: typeof EthTxLib;
12
- readonly EthCommon: typeof EthCommon;
13
- };
14
- /**
15
- * The extra parameters to send to platform build route for hop transactions
16
- */
17
- interface HopParams {
18
- hopParams: {
19
- gasPriceMax: number;
20
- userReqSig: string;
21
- paymentId: string;
22
- };
23
- gasLimit: number;
24
- }
25
- /**
26
- * The prebuilt hop transaction returned from the HSM
27
- */
28
- interface HopPrebuild {
29
- tx: string;
30
- id: string;
31
- signature: string;
32
- paymentId: string;
33
- gasPrice: number;
34
- gasLimit: number;
35
- amount: number;
36
- recipient: string;
37
- nonce: number;
38
- userReqSig: string;
39
- gasPriceMax: number;
40
- }
41
- interface EIP1559 {
42
- maxPriorityFeePerGas: number;
43
- maxFeePerGas: number;
44
- }
45
- interface ReplayProtectionOptions {
46
- chain: string | number;
47
- hardfork: string;
48
- }
49
- export interface SignFinalOptions {
50
- txPrebuild: {
51
- eip1559?: EIP1559;
52
- replayProtectionOptions?: ReplayProtectionOptions;
53
- gasPrice?: string;
54
- gasLimit: string;
55
- recipients: Recipient[];
56
- halfSigned: {
57
- expireTime: number;
58
- contractSequenceId: number;
59
- backupKeyNonce?: number;
60
- signature: string;
61
- txHex?: string;
62
- };
63
- nextContractSequenceId?: number;
64
- hopTransaction?: string;
65
- backupKeyNonce?: number;
66
- isBatch?: boolean;
67
- txHex?: string;
68
- expireTime?: number;
69
- };
70
- signingKeyNonce: number;
71
- walletContractAddress: string;
72
- prv: string;
73
- recipients: Recipient[];
74
- }
75
- export interface SignTransactionOptions extends BaseSignTransactionOptions, SignFinalOptions {
76
- isLastSignature?: boolean;
77
- expireTime: number;
78
- sequenceId: number;
79
- gasLimit: number;
80
- gasPrice: number;
81
- custodianTransactionId?: string;
82
- }
83
- export declare type SignedTransaction = HalfSignedTransaction | FullySignedTransaction;
84
- export interface FeesUsed {
85
- gasPrice: number;
86
- gasLimit: number;
87
- }
88
- interface PrecreateBitGoOptions {
89
- enterprise?: string;
90
- newFeeAddress?: string;
91
- }
92
- export interface OfflineVaultTxInfo {
93
- nextContractSequenceId?: string;
94
- contractSequenceId?: string;
95
- tx?: string;
96
- txHex?: string;
97
- userKey?: string;
98
- backupKey?: string;
99
- coin: string;
100
- gasPrice: number;
101
- gasLimit: number;
102
- recipients: Recipient[];
103
- walletContractAddress: string;
104
- amount: string;
105
- backupKeyNonce: number;
106
- eip1559?: EIP1559;
107
- replayProtectionOptions?: ReplayProtectionOptions;
108
- halfSigned?: HalfSignedTransaction;
109
- feesUsed?: FeesUsed;
110
- isEvmBasedCrossChainRecovery?: boolean;
111
- }
112
- interface UnformattedTxInfo {
113
- recipient: Recipient;
114
- }
115
- export interface RecoverOptions {
116
- userKey: string;
117
- backupKey: string;
118
- walletPassphrase?: string;
119
- walletContractAddress: string;
120
- recoveryDestination: string;
121
- krsProvider?: string;
122
- gasPrice?: number;
123
- gasLimit?: number;
124
- eip1559?: EIP1559;
125
- replayProtectionOptions?: ReplayProtectionOptions;
126
- isTss?: boolean;
127
- bitgoFeeAddress?: string;
128
- bitgoDestinationAddress?: string;
129
- tokenContractAddress?: string;
130
- }
131
- export declare type GetBatchExecutionInfoRT = {
132
- values: [string[], string[]];
133
- totalAmount: string;
134
- };
135
- export interface BuildTransactionParams {
136
- to: string;
137
- nonce?: number;
138
- value: number;
139
- data?: Buffer;
140
- gasPrice?: number;
141
- gasLimit?: number;
142
- eip1559?: EIP1559;
143
- replayProtectionOptions?: ReplayProtectionOptions;
144
- }
145
- export interface RecoveryInfo {
146
- id: string;
147
- tx: string;
148
- backupKey?: string;
149
- coin?: string;
150
- }
151
- interface RecoverTokenOptions {
152
- tokenContractAddress: string;
153
- wallet: Wallet;
154
- recipient: string;
155
- broadcast?: boolean;
156
- walletPassphrase?: string;
157
- prv?: string;
158
- }
159
- export interface GetSendMethodArgsOptions {
160
- recipient: Recipient;
161
- expireTime: number;
162
- contractSequenceId: number;
163
- signature: string;
164
- }
165
- export interface SendMethodArgs {
166
- name: string;
167
- type: string;
168
- value: any;
169
- }
170
- interface HopTransactionBuildOptions {
171
- wallet: Wallet;
172
- recipients: Recipient[];
173
- walletPassphrase: string;
174
- }
175
- interface BuildOptions {
176
- hop?: boolean;
177
- wallet?: Wallet;
178
- recipients?: Recipient[];
179
- walletPassphrase?: string;
180
- [index: string]: unknown;
181
- }
182
- interface FeeEstimate {
183
- gasLimitEstimate: number;
184
- feeEstimate: number;
185
- }
186
- export interface TransactionPrebuild extends BaseTransactionPrebuild {
187
- hopTransaction?: HopPrebuild;
188
- buildParams: {
189
- recipients: Recipient[];
190
- };
191
- recipients: TransactionRecipient[];
192
- nextContractSequenceId: string;
193
- gasPrice: number;
194
- gasLimit: number;
195
- isBatch: boolean;
196
- coin: string;
197
- token?: string;
198
- }
199
- interface EthTransactionParams extends TransactionParams {
200
- gasPrice?: number;
201
- gasLimit?: number;
202
- hopParams?: HopParams;
203
- hop?: boolean;
204
- prebuildTx?: PrebuildTransactionResult;
205
- }
206
- interface VerifyEthTransactionOptions extends VerifyTransactionOptions {
207
- txPrebuild: TransactionPrebuild;
208
- txParams: EthTransactionParams;
209
- }
210
- interface PresignTransactionOptions extends TransactionPrebuild, BasePresignTransactionOptions {
211
- wallet: Wallet;
212
- }
213
- interface RecoverTokenTransaction {
214
- halfSigned: {
215
- recipient: Recipient;
216
- expireTime: number;
217
- contractSequenceId: number;
218
- operationHash: string;
219
- signature: string;
220
- gasLimit: number;
221
- gasPrice: number;
222
- tokenContractAddress: string;
223
- walletId: string;
224
- };
225
- }
226
- interface EthAddressCoinSpecifics extends AddressCoinSpecific {
227
- forwarderVersion: number;
228
- salt?: string;
229
- }
230
- interface VerifyEthAddressOptions extends BaseVerifyAddressOptions {
231
- baseAddress: string;
232
- coinSpecific: EthAddressCoinSpecifics;
233
- forwarderVersion: number;
234
- }
235
- export declare class Eth extends BaseCoin {
236
- static hopTransactionSalt: string;
237
- protected readonly sendMethodName: 'sendMultiSig' | 'sendMultiSigToken';
238
- readonly staticsCoin?: Readonly<StaticsBaseCoin>;
6
+ export { BuildTransactionParams, Recipient, HalfSignedTransaction, FeesUsed, FullySignedTransaction, GetBatchExecutionInfoRT, GetSendMethodArgsOptions, TransactionPrebuild, OfflineVaultTxInfo, optionalDeps, RecoverOptions, RecoveryInfo, SendMethodArgs, SignFinalOptions, SignedTransaction, SignTransactionOptions, };
7
+ export declare class Eth extends AbstractEthLikeNewCoins {
239
8
  protected constructor(bitgo: BitGoBase, staticsCoin?: Readonly<StaticsBaseCoin>);
240
9
  static createInstance(bitgo: BitGoBase, staticsCoin?: Readonly<StaticsBaseCoin>): BaseCoin;
10
+ allowsAccountConsolidations(): boolean;
11
+ /** @inheritDoc */
12
+ supportsTss(): boolean;
13
+ /** inherited doc */
14
+ getDefaultMultisigType(): MultisigType;
15
+ getMPCAlgorithm(): MPCAlgorithm;
241
16
  /**
242
17
  * Gets correct Eth Common object based on params from either recovery or tx building
243
18
  * @param eip1559 {EIP1559} configs that specify whether we should construct an eip1559 tx
@@ -245,35 +20,18 @@ export declare class Eth extends BaseCoin {
245
20
  */
246
21
  private static getEthCommon;
247
22
  static buildTransaction(params: BuildTransactionParams): EthTxLib.FeeMarketEIP1559Transaction | EthTxLib.Transaction;
248
- /** @inheritDoc */
249
- supportsTss(): boolean;
250
- /** @inheritDoc */
251
- isEVM(): boolean;
252
- getMPCAlgorithm(): MPCAlgorithm;
253
- /**
254
- * Returns the factor between the base unit and its smallest subdivison
255
- * @return {number}
256
- */
257
- getBaseFactor(): string;
258
- getChain(): string;
259
- getFamily(): string;
260
- getNetwork(): EthereumNetwork | undefined;
261
- getFullName(): string;
262
- /**
263
- * Flag for sending value of 0
264
- * @returns {boolean} True if okay to send 0 value, false otherwise
265
- */
266
- valuelessTransferAllowed(): boolean;
267
23
  /**
268
- * Flag for sending data along with transactions
269
- * @returns {boolean} True if okay to send tx data (ETH), false otherwise
24
+ * Make a query to Etherscan for information such as balance, token balance, solidity calls
25
+ * @param query {Object} key-value pairs of parameters to append after /api
26
+ * @returns {Object} response from Etherscan
270
27
  */
271
- transactionDataAllowed(): boolean;
28
+ recoveryBlockchainExplorerQuery(query: Record<string, string>): Promise<any>;
272
29
  /**
273
- * Evaluates whether an address string is valid for this coin
274
- * @param address
30
+ * Recovers a tx with non-TSS keys
31
+ * same expected arguments as recover method (original logic before adding TSS recover path)
275
32
  */
276
- isValidAddress(address: string): boolean;
33
+ protected recoverEthLike(params: RecoverOptions): Promise<RecoveryInfo | OfflineVaultTxInfo>;
34
+ protected buildUnsignedSweepTxnTSS(params: RecoverOptions): Promise<OfflineVaultTxInfo | UnsignedSweepTxMPCv2>;
277
35
  /**
278
36
  * Return boolean indicating whether input is valid public key for the coin.
279
37
  *
@@ -281,49 +39,6 @@ export declare class Eth extends BaseCoin {
281
39
  * @returns {Boolean} is it valid?
282
40
  */
283
41
  isValidPub(pub: string): boolean;
284
- /**
285
- * Default gas price from platform
286
- * @returns {BigNumber}
287
- */
288
- getRecoveryGasPrice(): any;
289
- /**
290
- * Default gas limit from platform
291
- * @returns {BigNumber}
292
- */
293
- getRecoveryGasLimit(): any;
294
- /**
295
- * Default expire time for a contract call (1 week)
296
- * @returns {number} Time in seconds
297
- */
298
- getDefaultExpireTime(): number;
299
- /**
300
- * Query Etherscan for the balance of an address
301
- * @param address {String} the ETH address
302
- * @returns {BigNumber} address balance
303
- */
304
- queryAddressBalance(address: string): Promise<any>;
305
- /**
306
- * Query Etherscan for the balance of an address for a token
307
- * @param tokenContractAddress {String} address where the token smart contract is hosted
308
- * @param walletContractAddress {String} address of the wallet
309
- * @returns {BigNumber} token balaance in base units
310
- */
311
- queryAddressTokenBalance(tokenContractAddress: string, walletContractAddress: string): Promise<any>;
312
- /**
313
- * Get transfer operation for coin
314
- * @param recipient recipient info
315
- * @param expireTime expiry time
316
- * @param contractSequenceId sequence id
317
- * @returns {Array} operation array
318
- */
319
- getOperation(recipient: Recipient, expireTime: number, contractSequenceId: number): (string | Buffer)[][];
320
- getOperationSha3ForExecuteAndConfirm(recipients: Recipient[], expireTime: number, contractSequenceId: number): string;
321
- /**
322
- * Queries the contract (via Etherscan) for the next sequence ID
323
- * @param address {String} address of the contract
324
- * @returns {Number} sequence ID
325
- */
326
- querySequenceId(address: string): Promise<number>;
327
42
  /**
328
43
  * Helper function for signTransaction for the rare case that SDK is doing the second signature
329
44
  * Note: we are expecting this to be called from the offline vault
@@ -342,174 +57,6 @@ export declare class Eth extends BaseCoin {
342
57
  * @returns {Promise<SignedTransaction>}
343
58
  */
344
59
  signTransaction(params: SignTransactionOptions): Promise<SignedTransaction>;
345
- /**
346
- * Ensure either enterprise or newFeeAddress is passed, to know whether to create new key or use enterprise key
347
- * @param params
348
- * @param params.enterprise {String} the enterprise id to associate with this key
349
- * @param params.newFeeAddress {Boolean} create a new fee address (enterprise not needed in this case)
350
- */
351
- preCreateBitGo(params: PrecreateBitGoOptions): void;
352
- /**
353
- * Queries public block explorer to get the next ETH nonce that should be used for the given ETH address
354
- * @param address
355
- * @returns {*}
356
- */
357
- getAddressNonce(address: string): Promise<number>;
358
- /**
359
- * Helper function for recover()
360
- * This transforms the unsigned transaction information into a format the BitGo offline vault expects
361
- * @param txInfo
362
- * @param ethTx
363
- * @param userKey
364
- * @param backupKey
365
- * @param gasPrice
366
- * @param gasLimit
367
- * @param eip1559
368
- * @param replayProtectionOptions
369
- * @returns {Promise<OfflineVaultTxInfo>}
370
- */
371
- formatForOfflineVault(txInfo: UnformattedTxInfo, ethTx: EthTxLib.Transaction | EthTxLib.FeeMarketEIP1559Transaction, userKey: string, backupKey: string, gasPrice: Buffer, gasLimit: number, eip1559?: EIP1559, replayProtectionOptions?: ReplayProtectionOptions): Promise<OfflineVaultTxInfo>;
372
- /**
373
- * Helper function for recover()
374
- * This transforms the unsigned transaction information into a format the BitGo offline vault expects
375
- * @param txInfo
376
- * @param ethTx
377
- * @param userKey
378
- * @param backupKey
379
- * @param gasPrice
380
- * @param gasLimit
381
- * @param eip1559
382
- * @param replayProtectionOptions
383
- * @returns {Promise<OfflineVaultTxInfo>}
384
- */
385
- formatForOfflineVaultTSS(txInfo: UnformattedTxInfo, ethTx: EthTxLib.Transaction | EthTxLib.FeeMarketEIP1559Transaction, userKey: string, backupKey: string, gasPrice: Buffer, gasLimit: number, backupKeyNonce: number, eip1559?: EIP1559, replayProtectionOptions?: ReplayProtectionOptions): OfflineVaultTxInfo;
386
- /**
387
- * Check whether the gas price passed in by user are within our max and min bounds
388
- * If they are not set, set them to the defaults
389
- * @param userGasPrice user defined gas price
390
- * @returns the gas price to use for this transaction
391
- */
392
- setGasPrice(userGasPrice?: number): number;
393
- /**
394
- * Check whether gas limit passed in by user are within our max and min bounds
395
- * If they are not set, set them to the defaults
396
- * @param userGasLimit user defined gas limit
397
- * @returns the gas limit to use for this transaction
398
- */
399
- setGasLimit(userGasLimit?: number): number;
400
- validateRecoveryParams(params: RecoverOptions): void;
401
- private signRecoveryTSS;
402
- /**
403
- * Helper which combines key shares of user and backup
404
- * */
405
- private getKeyCombinedFromTssKeyShares;
406
- /**
407
- * Helper which Adds signatures to tx object and re-serializes tx
408
- * */
409
- private getSignedTxFromSignature;
410
- /**
411
- * Builds a funds recovery transaction without BitGo
412
- * @param params
413
- * @param params.userKey {String} [encrypted] xprv
414
- * @param params.backupKey {String} [encrypted] xprv or xpub if the xprv is held by a KRS provider
415
- * @param params.walletPassphrase {String} used to decrypt userKey and backupKey
416
- * @param params.walletContractAddress {String} the ETH address of the wallet contract
417
- * @param params.krsProvider {String} necessary if backup key is held by KRS
418
- * @param params.recoveryDestination {String} target address to send recovered funds to
419
- * @param params.bitgoFeeAddress {String} wrong chain wallet fee address for evm based cross chain recovery txn
420
- * @param params.bitgoDestinationAddress {String} target bitgo address where fee will be sent for evm based cross chain recovery txn
421
- */
422
- recover(params: RecoverOptions): Promise<RecoveryInfo | OfflineVaultTxInfo>;
423
- /**
424
- * Builds a unsigned (for cold, custody wallet) or
425
- * half-signed (for hot wallet) evm cross chain recovery transaction with
426
- * same expected arguments as recover method.
427
- * This helps recover funds from evm based wrong chain.
428
- */
429
- protected recoverEthLikeforEvmBasedRecovery(params: RecoverOptions): Promise<RecoveryInfo | OfflineVaultTxInfo>;
430
- recoverEthLikeTokenforEvmBasedRecovery(params: RecoverOptions, bitgoFeeAddressNonce: number, gasLimit: any, gasPrice: any, userKey: any, userSigningKey: any): Promise<OfflineVaultTxInfo>;
431
- validateEvmBasedRecoveryParams(params: RecoverOptions): void;
432
- /**
433
- * Create a new transaction builder for the current chain
434
- * @return a new transaction builder
435
- */
436
- protected getTransactionBuilder(): TransactionBuilder;
437
- /**
438
- * Get the base chain that the coin exists on.
439
- */
440
- getBaseChain(): string;
441
- /**
442
- * Return types, values, and total amount in wei to send in a batch transaction, using the method signature
443
- * `distributeBatch(address[], uint256[])`
444
- * @param {Recipient[]} recipients - transaction recipients
445
- * @returns {GetBatchExecutionInfoRT} information needed to execute the batch transaction
446
- */
447
- getBatchExecutionInfo(recipients: Recipient[]): GetBatchExecutionInfoRT;
448
- /**
449
- * Get the data required to make an ETH function call defined by the given types and values
450
- *
451
- * @param functionName The name of the function being called, e.g. transfer
452
- * @param types The types of the function call in order
453
- * @param values The values of the function call in order
454
- * @return {Buffer} The combined data for the function call
455
- */
456
- getMethodCallData: (functionName: any, types: any, values: any) => Buffer;
457
- /**
458
- * Recovers a tx with TSS key shares
459
- * same expected arguments as recover method, but with TSS key shares
460
- */
461
- protected recoverTSS(params: RecoverOptions): Promise<RecoveryInfo | OfflineVaultTxInfo>;
462
- /**
463
- * Recovers a tx with non-TSS keys
464
- * same expected arguments as recover method (original logic before adding TSS recover path)
465
- */
466
- protected recoverEthLike(params: RecoverOptions): Promise<RecoveryInfo | OfflineVaultTxInfo>;
467
- /**
468
- * Recover an unsupported token from a BitGo multisig wallet
469
- * This builds a half-signed transaction, for which there will be an admin route to co-sign and broadcast. Optionally
470
- * the user can set params.broadcast = true and the half-signed tx will be sent to BitGo for cosigning and broadcasting
471
- * @param params
472
- * @param params.wallet the wallet to recover the token from
473
- * @param params.tokenContractAddress the contract address of the unsupported token
474
- * @param params.recipient the destination address recovered tokens should be sent to
475
- * @param params.walletPassphrase the wallet passphrase
476
- * @param params.prv the xprv
477
- * @param params.broadcast if true, we will automatically submit the half-signed tx to BitGo for cosigning and broadcasting
478
- */
479
- recoverToken(params: RecoverTokenOptions): Promise<RecoverTokenTransaction>;
480
- /**
481
- * Build arguments to call the send method on the wallet contract
482
- * @param txInfo
483
- */
484
- getSendMethodArgs(txInfo: GetSendMethodArgsOptions): SendMethodArgs[];
485
- /**
486
- * Make a query to Etherscan for information such as balance, token balance, solidity calls
487
- * @param query {Object} key-value pairs of parameters to append after /api
488
- * @returns {Object} response from Etherscan
489
- */
490
- recoveryBlockchainExplorerQuery(query: Record<string, string>): Promise<any>;
491
- /**
492
- * Creates the extra parameters needed to build a hop transaction
493
- * @param buildParams The original build parameters
494
- * @returns extra parameters object to merge with the original build parameters object and send to the platform
495
- */
496
- createHopTransactionParams(buildParams: HopTransactionBuildOptions): Promise<HopParams>;
497
- /**
498
- * Validates that the hop prebuild from the HSM is valid and correct
499
- * @param wallet The wallet that the prebuild is for
500
- * @param hopPrebuild The prebuild to validate
501
- * @param originalParams The original parameters passed to prebuildTransaction
502
- * @returns void
503
- * @throws Error if The prebuild is invalid
504
- */
505
- validateHopPrebuild(wallet: IWallet, hopPrebuild: HopPrebuild, originalParams?: {
506
- recipients: Recipient[];
507
- }): Promise<void>;
508
- /**
509
- * Gets the hop digest for the user to sign. This is validated in the HSM to prove that the user requested this tx
510
- * @param paramsArr The parameters to hash together for the digest
511
- */
512
- private static getHopDigest;
513
60
  /**
514
61
  * Modify prebuild before sending it to the server. Add things like hop transaction params
515
62
  * @param buildParams The whitelisted parameters for this prebuild
@@ -520,71 +67,13 @@ export declare class Eth extends BaseCoin {
520
67
  */
521
68
  getExtraPrebuildParams(buildParams: BuildOptions): Promise<BuildOptions>;
522
69
  /**
523
- * Modify prebuild after receiving it from the server. Add things like nlocktime
524
- */
525
- postProcessPrebuild(params: TransactionPrebuild): Promise<TransactionPrebuild>;
526
- /**
527
- * Coin-specific things done before signing a transaction, i.e. verification
528
- * @param params
529
- */
530
- presignTransaction(params: PresignTransactionOptions): Promise<PresignTransactionOptions>;
531
- /**
532
- * Fetch fee estimate information from the server
533
- * @param {Object} params The params passed into the function
534
- * @param {Boolean} [params.hop] True if we should estimate fee for a hop transaction
535
- * @param {String} [params.recipient] The recipient of the transaction to estimate a send to
536
- * @param {String} [params.data] The ETH tx data to estimate a send for
537
- * @returns {Object} The fee info returned from the server
538
- */
539
- feeEstimate(params: FeeEstimateOptions): Promise<FeeEstimate>;
540
- /**
541
- * Generate secp256k1 key pair
542
- *
543
- * @param seed
544
- * @returns {Object} object with generated pub and prv
545
- */
546
- generateKeyPair(seed: Buffer): KeyPair;
547
- parseTransaction(params: ParseTransactionOptions): Promise<ParsedTransaction>;
548
- /**
549
- * Make sure an address is a wallet address and throw an error if it's not.
550
- * @param {Object} params
551
- * @param {String} params.address The derived address string on the network
552
- * @param {Object} params.coinSpecific Coin-specific details for the address such as a forwarderVersion
553
- * @param {String} params.baseAddress The base address of the wallet on the network
554
- * @throws {InvalidAddressError}
555
- * @throws {InvalidAddressVerificationObjectPropertyError}
556
- * @throws {UnexpectedAddressError}
557
- * @returns {Boolean} True iff address is a wallet address
558
- */
559
- isWalletAddress(params: VerifyEthAddressOptions): Promise<boolean>;
560
- verifyCoin(txPrebuild: TransactionPrebuild): boolean;
561
- verifyTssTransaction(params: VerifyEthTransactionOptions): boolean;
562
- /**
563
- * Verify that a transaction prebuild complies with the original intention
564
- *
565
- * @param params
566
- * @param params.txParams params object passed to send
567
- * @param params.txPrebuild prebuild object returned by server
568
- * @param params.wallet Wallet object to obtain keys to verify against
569
- * @returns {boolean}
70
+ * Create a new transaction builder for the current chain
71
+ * @return a new transaction builder
570
72
  */
571
- verifyTransaction(params: VerifyEthTransactionOptions): Promise<boolean>;
73
+ protected getTransactionBuilder(): TransactionBuilder;
572
74
  /** @inheritDoc */
573
75
  supportsMessageSigning(): boolean;
574
76
  /** @inheritDoc */
575
77
  supportsSigningTypedData(): boolean;
576
- /**
577
- * Transform message to accommodate specific blockchain requirements.
578
- * @param message the message to prepare
579
- * @return string the prepared message.
580
- */
581
- encodeMessage(message: string): string;
582
- /**
583
- * Transform the Typed data to accomodate the blockchain requirements (EIP-712)
584
- * @param typedData the typed data to prepare
585
- * @return a buffer of the result
586
- */
587
- encodeTypedData(typedData: TypedData): Buffer;
588
- private isETHAddress;
589
78
  }
590
79
  //# sourceMappingURL=eth.d.ts.map
@@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