Skip to content

Latest commit

 

History

History
297 lines (264 loc) · 7.84 KB

contracts.md

File metadata and controls

297 lines (264 loc) · 7.84 KB

Contract Wrappers

The contract wrappers provided by Nerman.js currently support basic event listening. You can interact with these events using the following functions on each wrapper.

constructor()

  • provider: string | ethers.JsonRpcProvider. Our wrappers can handle providers behind the scene, so you only need to provide a JSON RPC URL from your preferred provider (like Alchemy) to make them work. We also offer the ability to pass in your own provider, giving you flexibility when needed.
import * as nerman from "nerman";

const nouns = new nerman.Nouns("<JSON_RPC_URL>");

on()

Registers a listener function to the given event, triggering the function with the appropriate data whenever the event fires on the blockchain. Throws an error if the event is not supported.

  • eventName: string. The name of the event.
  • listener: Function. The listener function.
nouns.on("NounCreated", (data) => {
	console.log(data.id);
});

off()

Removes any assigned listeners from the event. Does nothing if there was no listener.

  • eventName: string. The event name.
nouns.off("NounCreated");

trigger()

Triggers the listener of the given event with the given data. Throws an error if there is no listener assigned.

  • eventName: string. The event name.
  • data: unknown. The event data.
nouns.trigger("NounCreated", {
	id: 420,
	seed: {
		background: 0,
		body: 0,
		accessory: 0,
		head: 0,
		glasses: 0
	}
});

ERC20

Contract Address
stETH 0xae7ab96520de3a18e5e111b5eaab095312d7fe84
rETH 0xae78736cd615f374d3085123a210448e74fc6393
WETH 0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
USDC 0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48
wstETH 0x7f39c581f595b53c5cb19bd0b3f8da6c935e2ca0

Nouns

Contract Address Notes
Treasury / Executor 0xb1a32FC9F9D8b2cf86C068Cae13108809547ef71
TokenBuyer 0x4f2aCdc74f6941390d9b1804faBc3E780388cfe5
Payer 0xd97Bcd9f47cEe35c0a9ec1dc40C1269afc9E8E1D
AuctionHouseV2 0x830BD73E4184ceF73443C15111a1DF14e495C706 Change to V2 with Proposal 532, executed on block 19810422
LogicV4 0x6f3E6272A167e8AcCb32072d08E0957F9c79223d Change to V4 with Proposal 532, executed on block 19810422

For more details, check out our contracts page and the Nouns Contracts Readme.

Propdates

A contract that handles posting updates.

Version Address Note
V1 0x94b4fb16893C0Fb4E470eEf2559C24FD87FEd5F1
V2 0xa5Bf9A9b8f60CFD98b1cCB592f2F9F37Bb0033a4 Updated to V2 on block 18689732. 01-Dec-2023.

Nouns Forks

Each fork has its own unique addresses for its treasury, token, auction, and logic contracts. These deployed contracts can be found in the Nouns Fork Deployer Contract events.

There do not appear to be any auction proxies at the moment, and there are no triggered auction events.

Fork Contract Address
0 Token 0x06cF70f6f90E0B1f17d19F3Cb962A39E505D5b3f
Auction 0xd5c122b40823e467bc6e3c859cb530b105cae22e
Logic 0xa30e1fbb8e1b5d6487e9f3dda55df05e225f82b6
Treasury 0x55dd565c6f94b3bad1f4a35398af4a526fcd465f
1 Token 0xd6473f1d7c07dc08983a7f09f59c1a2aba17be41
Auction 0xb350beda0210fae7a179809fb0ae0ecd565164b0
Logic 0x5b8dd9f30425a7e6942c2ecf1d87acafbeab3073
Treasury 0x6a4c7cada167a0da8b0323dcc3f0083ac5706817
2 Token 0xd7bf9e2c54d07582004782004ed20d0336d52669
Auction 0xd5d4c3863c320bc9f5fe9ee0d3da6f7b214449ef
Logic 0xcf8b3ce9e92990a689fbdc886585a84ea0e4aece
Treasury 0x4e2d32da6ea31cbdd96e14c34bf8141c15902e06

Federation

Federation Nouns Pool contracts. V1 is no longer in use.

Version Address
V1 0xBE5E6De0d0Ac82b087bAaA1d53F145a52EfE1642
V2 0x0f722d69B3D8C292E85F2b1E5D9F4439edd58F1e