Skip to content
This repository was archived by the owner on Mar 11, 2026. It is now read-only.

'getBlockWithTransactions' does not include 'size' in its response #471

@edyionescu

Description

@edyionescu

Environment

  • Node.js version: 22.11.0
  • Alchemy SDK version: 3.4.8

The problem

getBlockWithTransactions does not include size in its response as mentioned in the docs. It is listed in the response object parameters, but does not appear in the example response.

How to reproduce:

import { Alchemy, Network } from 'alchemy-sdk';

const alchemy = new Alchemy({
  apiKey: ALCHEMY_API_KEY,
  network: Network.ETH_MAINNET,
});

console.log((await alchemy.core.getBlockWithTransactions(21179399)).size);
// undefined

The size is present in the JSON-RPC response of eth_getBlockByNumber. Here is the sandbox link for the same block.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions