
Product
Introducing Manifest Alerts
Socket now detects supply chain risks in project manifests, starting with missing lockfiles that can make dependency installs non-reproducible.
@evmexplorer/blockscout
Advanced tools
EVM Explorer TypeScript Blockscout v2 sdk.
npm install @evmexplorer/blockscout
or
yarn add @evmexplorer/blockscout
To fetch a transaction on Ethereum mainnet as demonstrated on Ethereum Stack Oveflow answer:
import type { TransactionBlockscout } from '@evmexplorer/blockscout';
import { fetchTransactionBlockscout } from '@evmexplorer/blockscout';
const data: TransactionBlockscout = await fetchTransactionBlockscout(
'0xdc7ddf3d0e53532eeeda7a7a99c88255ccee5a3b4404441278cbbd79b4c85086',
);
console.log(data);
The fetchTransactionBlockscout function returns an object with the following properties:
{
priority_fee: '70439166556560',
tx_burnt_fee: '676806248593230',
raw_input: '0xa22cb4650000000000000000000000001e0049783f008a0085193e00003d00cd54003c710000000000000000000000000000000000000000000000000000000000000001',
result: 'success',
hash: '0xdc7ddf3d0e53532eeeda7a7a99c88255ccee5a3b4404441278cbbd79b4c85086',
max_fee_per_gas: '15917702655',
revert_reason: null,
confirmation_duration: [0, 12000],
type: 2,
token_transfers_overflow: false,
confirmations: 47513,
position: 72,
max_priority_fee_per_gas: '1267119384',
transaction_tag: null,
created_contract: null,
value: '0',
tx_types: ['contract_call'],
from:
{
ens_domain_name: null,
hash: '0xA3b711752f08980F4a71777217FA81304aEB8ee7',
implementations: [],
is_contract: false,
is_scam: false,
is_verified: false,
metadata: null,
name: null,
private_tags: [],
proxy_type: null,
public_tags: [],
watchlist_names: [],
},
gas_used: '55590',
status: 'ok',
to:
{
ens_domain_name: null,
hash: '0x22C1f6050E56d2876009903609a2cC3fEf83B415',
implementations: [[Object]],
is_contract: true,
is_scam: false,
is_verified: true,
metadata: { tags: [Array] },
name: 'AdminUpgradeabilityProxy',
private_tags: [],
proxy_type: 'eip1967',
public_tags: [],
watchlist_names: [],
},
authorization_list: [],
method: 'setApprovalForAll',
fee: { type: 'actual', value: '747245415149790' },
tx_tag: null,
actions: [],
gas_limit: '73310',
gas_price: '13442083381',
decoded_input:
{
method_call: 'setApprovalForAll(address to, bool approved)',
method_id: 'a22cb465',
parameters: [[Object], [Object]],
},
has_error_in_internal_txs: false,
token_transfers: [],
base_fee_per_gas: '12174963997',
timestamp: '2024-12-08T17:44:23.000000Z',
nonce: 464,
block: 21359346,
transaction_types: ['contract_call'],
exchange_rate: '3859.75',
block_number: 21359346,
has_error_in_internal_transactions: false,
}
You can also go over the transaction visually at EVM Explorer transaction page.
You can also query the blockchain address token balances as demonstrated on Stack Overflow. For example, let's query Vitalik's balances:
export type { AddressTokens } from "@evmexplorer/blockscout";
export { fetchTokensAddress } from "@evmexplorer/blockscout";
const data: AddressTokens = await fetchTokensAddress(
'0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045',
);
console.log(data.length)
console.log(data[0])
6081
{
token: {
address: '0x28561B8A2360F463011c16b6Cc0B0cbEF8dbBcad',
circulating_market_cap: '75858317.61202328',
decimals: '9',
exchange_rate: '0.00017784',
holders: '14334',
icon_url: 'https://assets.coingecko.com/coins/images/50348/small/1000000612.jpg?1727248974',
name: 'MOO DENG',
symbol: 'MOODENG',
total_supply: '420690000000000000000',
type: 'ERC-20',
volume_24h: '10219755.637613483'
},
token_id: null,
token_instance: null,
value: '30000105889157756560'
}
Vitalik has 6081 tokens. The first token in the array of all 6081 tokens is Moo Deng token.
You can also query the latest block transactions with Ethers provider as demonstrated on Stack Overflow.
import { fetchBlockTransactionsBlockscout } from '@evmexplorer/blockscout';
const block = await provider.getBlock();
const data = await fetchBlockTransactionsBlockscout(block);
EVM Explorer - Tracking Smart Contract Transaction Data
FAQs
EVM Explorer TypeScript BlockScout V2 sdk
We found that @evmexplorer/blockscout demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket now detects supply chain risks in project manifests, starting with missing lockfiles that can make dependency installs non-reproducible.

Research
/Security News
The trojanized extensions use TinyGo-compiled WebAssembly and Solana transaction memos to resolve command-and-control infrastructure.

Security News
Anthropic says the directive cited national security concerns over a narrow jailbreak, but offered no specific technical details.