erc1271_signer 0.1.1 copy "erc1271_signer: ^0.1.1" to clipboard
erc1271_signer: ^0.1.1 copied to clipboard

Dart port of viem-style utilities for Ethereum: Coinbase Smart Wallet message signing, EIP-191/EIP-712 hashing, and ERC-1271-compatible signatures.

example/lib/main.dart

import 'package:erc1271_signer/erc1271_signer.dart';

void main() async {
  // Replace with your chain, private key, and message.
  const chainName = 'baseSepolia';
  const privateKey = '0x_your_private_key_here';
  const message = 'I hereby declare that I am the address owner.';

  print('Signing message with Coinbase Smart Wallet...');
  print('Chain: $chainName');
  print('Message: $message');
  print('');

  final signature = await signMessage(
    chainName: chainName,
    privateKey: privateKey,
    message: message,
  );

  print('Signature (ERC-1271 wrapped):');
  print(signature);
}
0
likes
160
points
255
downloads

Publisher

verified publisherpiusikeoffiah.dev

Weekly Downloads

Dart port of viem-style utilities for Ethereum: Coinbase Smart Wallet message signing, EIP-191/EIP-712 hashing, and ERC-1271-compatible signatures.

Repository (GitHub)
View/report issues

Topics

#ethereum #web3 #erc1271 #crypto #blockchain

Documentation

Documentation
API reference

License

MIT (license)

Dependencies

convert, hashlib, http, web3dart

More

Packages that depend on erc1271_signer