Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

Connect AI agents to Etherscan

Scalekit connector
Open markdown

The Etherscan connector lets your AI agent act in each user's Etherscan account. Each user connects their own Etherscan API key once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 60 tools.

Tools
60
What they doRead · write · destructive
60 · 0 · 060 read0 write0 destructive
Users sign in with

Setup

  1. Install the SDK

    Terminal window
    npm install @scalekit-sdk/node dotenv
  2. Set your credentials

    Add your Scalekit credentials to your .env file. Find values in app.scalekit.com > Developers > API Credentials.

    .env
    SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
    SCALEKIT_CLIENT_ID=<your-client-id>
    SCALEKIT_CLIENT_SECRET=<your-client-secret>
  3. Create the Etherscan connection

    In AgentKit > Connections, create an Etherscan connection. The name you give it is the connection_name your code passes. See Configure connections.

  4. Authorize a user and make your first call

    quickstart.mts
    import { ScalekitClient } from '@scalekit-sdk/node'
    import 'dotenv/config'
    import { createInterface } from 'node:readline/promises'
    const scalekit = new ScalekitClient(
    process.env.SCALEKIT_ENVIRONMENT_URL,
    process.env.SCALEKIT_CLIENT_ID,
    process.env.SCALEKIT_CLIENT_SECRET,
    )
    const actions = scalekit.actions
    const connector = 'etherscan'
    const identifier = 'user_123'
    // Generate an authorization link for the user
    const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
    console.log('Authorize Etherscan:', link)
    const rl = createInterface({ input: process.stdin, output: process.stdout })
    await rl.question('Press Enter after authorizing...')
    rl.close()
    // Make your first call
    const result = await actions.executeTool({
    connector,
    identifier,
    toolName: 'etherscan_api_usage_get',
    toolInput: {},
    })
    console.log(result)
    Terminal window
    npx tsx quickstart.mts

    Each user opens the link once and enters their Etherscan credentials there. See Authorize a user for the full flow and statuses.

Tools

Pass the exact name to execute_tool
Try in PlaygroundRequest a tool
  • etherscan_address_funded_by_getGet the address and transaction that first funded an externally owned address, to trace where its funds came from.Read-only

    Get Address Funded By

    Get the address and transaction that first funded an externally owned address, to trace where its funds came from. Not available for contract addresses. Returns status, message and result.

    Inputs

    addressstringrequired
    Address to query, 0x followed by 40 hex characters. Example: 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe.
    chainidstring
    Chain ID to query: 1 Ethereum (default), 8453 Base, 42161 Arbitrum One, 10 OP Mainnet, 137 Polygon, 56 BNB Smart Chain, 43114 Avalanche C-Chain, 11155111 Sepolia, and the other chains in etherscan_chains_list. Example: 1.default 1
  • etherscan_address_nft_holdings_listList the ERC-721 collections and token counts held by an address.Read-only

    Get Address ERC721 Token Holding

    List the ERC-721 collections and token counts held by an address. PRO plan endpoint. Returns status, message and result.

    Inputs

    addressstringrequired
    Address to query, 0x followed by 40 hex characters. Example: 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe.
    chainidstring
    Chain ID to query: 1 Ethereum (default), 8453 Base, 42161 Arbitrum One, 10 OP Mainnet, 137 Polygon, 56 BNB Smart Chain, 43114 Avalanche C-Chain, 11155111 Sepolia, and the other chains in etherscan_chains_list. Example: 1.default 1
    offsetinteger
    Records per page (the API caps page times offset at 10,000). Example: 100.
    pageinteger
    Page number, starting at 1. Example: 1.
  • etherscan_address_nft_inventory_listList the ERC-721 token IDs an address holds in one collection.Read-only

    Get Address ERC721 Token Inventory by Contract

    List the ERC-721 token IDs an address holds in one collection. PRO plan endpoint. Returns status, message and result.

    Inputs

    addressstringrequired
    Address to query, 0x followed by 40 hex characters. Example: 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe.
    contractaddressstringrequired
    Token contract address. Example: 0xdAC17F958D2ee523a2206206994597C13D831ec7.
    chainidstring
    Chain ID to query: 1 Ethereum (default), 8453 Base, 42161 Arbitrum One, 10 OP Mainnet, 137 Polygon, 56 BNB Smart Chain, 43114 Avalanche C-Chain, 11155111 Sepolia, and the other chains in etherscan_chains_list. Example: 1.default 1
    offsetinteger
    Records per page (the API caps page times offset at 10,000). Example: 100.
    pageinteger
    Page number, starting at 1. Example: 1.
  • etherscan_address_tag_getGet the name tag, labels, reputation and other metadata of an address.Read-only

    Get Metadata for an Address

    Get the name tag, labels, reputation and other metadata of an address. Metadata plan endpoint. Returns status, message and result.

    Inputs

    addressstringrequired
    Address to query, 0x followed by 40 hex characters. Example: 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe.
    chainidstring
    Chain ID to query: 1 Ethereum (default), 8453 Base, 42161 Arbitrum One, 10 OP Mainnet, 137 Polygon, 56 BNB Smart Chain, 43114 Avalanche C-Chain, 11155111 Sepolia, and the other chains in etherscan_chains_list. Example: 1.default 1
  • etherscan_address_token_holdings_listList the ERC-20 tokens and balances held by an address.Read-only

    Get Address ERC20 Token Holding

    List the ERC-20 tokens and balances held by an address. PRO plan endpoint. Returns status, message and result.

    Inputs

    addressstringrequired
    Address to query, 0x followed by 40 hex characters. Example: 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe.
    chainidstring
    Chain ID to query: 1 Ethereum (default), 8453 Base, 42161 Arbitrum One, 10 OP Mainnet, 137 Polygon, 56 BNB Smart Chain, 43114 Avalanche C-Chain, 11155111 Sepolia, and the other chains in etherscan_chains_list. Example: 1.default 1
    offsetinteger
    Records per page (the API caps page times offset at 10,000). Example: 100.
    pageinteger
    Page number, starting at 1. Example: 1.
  • etherscan_api_usage_getGet your API credit usage and limit for the current interval.Read-only

    Get API Usage

    Get your API credit usage and limit for the current interval. Returns status, message and result.

    Inputs

    This tool takes no inputs.

  • etherscan_balance_getGet the native token balance (e.g.Read-only

    Get Native Balance for an Address

    Get the native token balance (e.g. ETH, in wei) of an address. Use etherscan_balances_multi_get for several addresses and etherscan_token_balance_get for an ERC-20 token. Returns status, message and result.

    Inputs

    addressstringrequired
    Address to query, 0x followed by 40 hex characters. Example: 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe.
    chainidstring
    Chain ID to query: 1 Ethereum (default), 8453 Base, 42161 Arbitrum One, 10 OP Mainnet, 137 Polygon, 56 BNB Smart Chain, 43114 Avalanche C-Chain, 11155111 Sepolia, and the other chains in etherscan_chains_list. Example: 1.default 1
    tagstring
    Block to read at: latest, earliest, pending or a block number in hex. Example: latest.
  • etherscan_balance_history_getGet the native token balance of an address at a past block number.Read-only

    Get Historical Native Balance for an Address

    Get the native token balance of an address at a past block number. PRO plan endpoint. Returns status, message and result.

    Inputs

    addressstringrequired
    Address to query, 0x followed by 40 hex characters. Example: 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe.
    blocknointegerrequired
    Block number. Example: 19000000.
    chainidstring
    Chain ID to query: 1 Ethereum (default), 8453 Base, 42161 Arbitrum One, 10 OP Mainnet, 137 Polygon, 56 BNB Smart Chain, 43114 Avalanche C-Chain, 11155111 Sepolia, and the other chains in etherscan_chains_list. Example: 1.default 1