From 19039a58987c2bfadd7466af6cb9c2397e56188f Mon Sep 17 00:00:00 2001 From: Eric Wang Date: Thu, 13 Jul 2023 06:30:42 -0700 Subject: [PATCH] fix(sdk-core): make amount optional in stake options Ticket: EA-549 --- modules/bitgo/test/v2/unit/staking/stakingWalletCommon.ts | 2 -- modules/sdk-core/src/bitgo/staking/iStakingWallet.ts | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/modules/bitgo/test/v2/unit/staking/stakingWalletCommon.ts b/modules/bitgo/test/v2/unit/staking/stakingWalletCommon.ts index 45aed8e8c1..ae3da77c20 100644 --- a/modules/bitgo/test/v2/unit/staking/stakingWalletCommon.ts +++ b/modules/bitgo/test/v2/unit/staking/stakingWalletCommon.ts @@ -81,7 +81,6 @@ describe('Staking Wallet Common', function () { const expected = fixtures.stakingRequest([fixtures.transaction('NEW')]); const msScope = nock(microservicesUri) .post(`/api/staking/v1/${stakingWallet.coin}/wallets/${stakingWallet.walletId}/requests`, { - amount: '1', clientId: 'clientId', type: 'STAKE', delegationRequests: [ @@ -93,7 +92,6 @@ describe('Staking Wallet Common', function () { .reply(201, expected); const options = { - amount: '1', clientId: 'clientId', delegationRequests: [ { amount: '1', validator: '123' }, diff --git a/modules/sdk-core/src/bitgo/staking/iStakingWallet.ts b/modules/sdk-core/src/bitgo/staking/iStakingWallet.ts index 8935b3fd37..1880e28d0d 100644 --- a/modules/sdk-core/src/bitgo/staking/iStakingWallet.ts +++ b/modules/sdk-core/src/bitgo/staking/iStakingWallet.ts @@ -24,7 +24,7 @@ export interface DelegationRequest { } export interface StakeOptions { - amount: string; + amount?: string; clientId?: string; validator?: string; durationSeconds?: string;