matter-labs / matter-labs/block-explorer

Explorer API reports proxy contracts incorrectly

Open
#264 1 comment 0 reactions 1 assignee View on GitHub

@petarTxFusion is already working on this.

Since Mar 18, 2025.

bug
Dominant language
TypeScript
Stars
139
Forks
145
Avg merge
8h 3m
Merged PRs (30d)
3

Description

🐛 Bug Report
📝 Description

The explorer API incorrectly reports that a proxy smart contract isn't a proxy.

Online block explorer reports that a proxy smart contract is a proxy:
https://explorer.zksync.io/address/0x5A7d6b2F92C77FAD6CCaBd7EE0624E64907Eaf3E#contract

But the explorer API reports that the same smart contract is NOT a proxy:
https://block-explorer-api.mainnet.zksync.io/api?module=contract&action=getsourcecode&address=0x5A7d6b2F92C77FAD6CCaBd7EE0624E64907Eaf3E

            "Proxy": "0",
            "Implementation": "",
🔄 Reproduction Steps
  1. Search for a proxy smart contract in the online explorer (https://explorer.zksync.io/). The explorer will show that the contract is a proxy.
  2. Search for the same smart contract via the API (https://block-explorer-api.mainnet.zksync.io/api). The response will indicate that the same contract is not a proxy.
🤔 Expected Behavior

The API response should indicate that the proxy smart contract is a proxy ("Proxy": "1"). It should also return the address of the implementation contract ("Implementation").

😯 Current Behavior

The API response indicates that the proxy smart contract is NOT a proxy ("Proxy": "0"). It also doesn't return any implementation contract address ("Implementation": "").

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.