Overview
ERC-681 defines a URI scheme for Ethereum transactions, enabling:- QR codes for payment requests
- Deep links to wallet apps
- Embeddable payment buttons
- Standardized transaction sharing
Quick Start
- Parse URL
- Format URL
- QR Code
URL Components
Required
- address: Target Ethereum address (20 bytes, checksummed or lowercase)
Optional
- chainId: Network identifier (e.g., 1 for mainnet, 137 for Polygon)
- functionName: Contract function to call
- functionParams: Function parameters as key-value pairs
- value: ETH amount in wei
- gas: Gas limit
- gasPrice: Gas price in wei
- data: Raw hex-encoded calldata (overrides function encoding)
API Documentation
parse
Parse ERC-681 URL into components
format
Format components into ERC-681 URL
from
Create branded TransactionUrl type
Usage Patterns
Payment Request
Token Approval Deep Link
Invoice with Memo
Specification References
- ERC-681 - Transaction URL format
- EIP-681 - Full specification
- URI Scheme - IANA registration
Related
- Address - Ethereum address handling
- Abi - Function encoding for contract calls
- Transaction - Transaction types

