diff --git a/packages/whale-api-client/__tests__/api/blocks.test.ts b/packages/whale-api-client/__tests__/api/blocks.test.ts index 5dc449b51d..b98551a2d0 100644 --- a/packages/whale-api-client/__tests__/api/blocks.test.ts +++ b/packages/whale-api-client/__tests__/api/blocks.test.ts @@ -45,7 +45,8 @@ const ExpectedBlock = { merkleroot: expect.stringMatching(/[0-f]{64}/), size: expect.any(Number), sizeStripped: expect.any(Number), - weight: expect.any(Number) + weight: expect.any(Number), + reward: expect.any(String) } describe('list', () => { @@ -124,6 +125,7 @@ describe('get', () => { describe('getTransactions', () => { const ExpectedTransaction = { id: expect.stringMatching(/[0-f]{64}/), + order: expect.any(Number), block: { hash: expect.stringMatching(/[0-f]{64}/), height: expect.any(Number), @@ -138,7 +140,8 @@ describe('getTransactions', () => { weight: expect.any(Number), lockTime: expect.any(Number), vinCount: expect.any(Number), - voutCount: expect.any(Number) + voutCount: expect.any(Number), + totalVoutValue: expect.any(String) } it('should getTransactions through hash', async () => { diff --git a/packages/whale-api-client/__tests__/api/transaction.test.ts b/packages/whale-api-client/__tests__/api/transaction.test.ts index bb2495f3bb..68776c6fd8 100644 --- a/packages/whale-api-client/__tests__/api/transaction.test.ts +++ b/packages/whale-api-client/__tests__/api/transaction.test.ts @@ -69,6 +69,7 @@ describe('get', () => { const transaction = await client.transactions.get(txid) expect(transaction).toStrictEqual({ id: txid, + order: expect.any(Number), block: { hash: expect.any(String), height: expect.any(Number), @@ -83,7 +84,8 @@ describe('get', () => { weight: expect.any(Number), lockTime: expect.any(Number), vinCount: expect.any(Number), - voutCount: expect.any(Number) + voutCount: expect.any(Number), + totalVoutValue: expect.any(String) }) }) diff --git a/packages/whale-api-client/src/api/blocks.ts b/packages/whale-api-client/src/api/blocks.ts index 4ec1fb5983..cb0e5e709a 100644 --- a/packages/whale-api-client/src/api/blocks.ts +++ b/packages/whale-api-client/src/api/blocks.ts @@ -54,6 +54,7 @@ export interface Block { masternode: string minter: string minterBlockCount: number + reward: string // ------------| reward string as decimal stakeModifier: string merkleroot: string diff --git a/packages/whale-api-client/src/api/transactions.ts b/packages/whale-api-client/src/api/transactions.ts index 499489ba0f..9e68263428 100644 --- a/packages/whale-api-client/src/api/transactions.ts +++ b/packages/whale-api-client/src/api/transactions.ts @@ -54,6 +54,7 @@ export interface Transaction { lockTime: number vinCount: number voutCount: number + totalVoutValue: string } /**