参数
addressstring必填- 20-byte address, hex encoded.
blockstring必填- Block number in hex (e.g. "0x1208a5f") or a tag: "latest", "safe", "finalized", "earliest" or "pending". L0vd endpoints run archive nodes, so any historical block works.
返回值
string Nonce, hex encoded.
适用场景
Get the nonce of an address: how many transactions it has sent up to and including the given block.
Compare two blocks to count an account's outgoing transactions in a period, or detect whether a wallet was active at all.
如何解读结果
Hex integer. 0x1 means one transaction sent. For contracts it counts contracts created by that contract (EIP-161).
提示
- Use "pending" only when you are about to sign a new transaction; for analytics use a fixed block number so the answer never changes.
- The nonce counts sent transactions only. Received transfers do not change it.