Skip to content

Commit

Permalink
Merge branch 'ethers-v5' of github.com-rare:LooksRare/sdk-v2 into fix…
Browse files Browse the repository at this point in the history
…/ethers-v5-chain-addresses
  • Loading branch information
perryrare committed Jan 24, 2024
2 parents 247d270 + bd667b7 commit cbbc356
Show file tree
Hide file tree
Showing 4 changed files with 83 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@looksrare/sdk-v2",
"version": "0.9.4",
"version": "0.9.5",
"license": "MIT",
"main": "dist/index.cjs.js",
"module": "dist/index.esm.js",
Expand Down
47 changes: 43 additions & 4 deletions src/constants/addresses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ const sepoliaAddresses: Addresses = {
};

const arbitrumSepoliaAddresses: Addresses = {
LOOKS: "0x0d2ddc4A656eB8398499fd7adF3DA7Cc545810Ab", // @note - not "LOOKS", but a test ERC20
LOOKS: "",
EXCHANGE_V2: "",
TRANSFER_MANAGER_V2: "0x21D44Cd218895d08bB57E2161A5c8De1CE898165",
TRANSFER_MANAGER_V2: "",
WETH: "",
ORDER_VALIDATOR_V2: "",
REVERSE_RECORDS: "",
Expand All @@ -49,9 +49,45 @@ const arbitrumSepoliaAddresses: Addresses = {
};

const arbitrumMainnetAddresses: Addresses = {
LOOKS: "0x0000000000000000000000000000000000000000", // bridged LOOKS
LOOKS: "",
EXCHANGE_V2: "",
TRANSFER_MANAGER_V2: "0x0000000000A3573e1caFe02fe1C3Ac48473C9332",
TRANSFER_MANAGER_V2: "",
WETH: "",
ORDER_VALIDATOR_V2: "",
REVERSE_RECORDS: "",
LOOKS_LP_V3: "",
STAKING_POOL_FOR_LOOKS_LP: "",
AGGREGATOR_UNISWAP_V3: "",
};

const baseMainnetAddresses: Addresses = {
LOOKS: "",
EXCHANGE_V2: "",
TRANSFER_MANAGER_V2: "",
WETH: "",
ORDER_VALIDATOR_V2: "",
REVERSE_RECORDS: "",
LOOKS_LP_V3: "",
STAKING_POOL_FOR_LOOKS_LP: "",
AGGREGATOR_UNISWAP_V3: "",
};

const baseSepoliaAddresses: Addresses = {
LOOKS: "",
EXCHANGE_V2: "",
TRANSFER_MANAGER_V2: "",
WETH: "",
ORDER_VALIDATOR_V2: "",
REVERSE_RECORDS: "",
LOOKS_LP_V3: "",
STAKING_POOL_FOR_LOOKS_LP: "",
AGGREGATOR_UNISWAP_V3: "",
};

const blastSepoliaAddresses: Addresses = {
LOOKS: "",
EXCHANGE_V2: "",
TRANSFER_MANAGER_V2: "",
WETH: "",
ORDER_VALIDATOR_V2: "",
REVERSE_RECORDS: "",
Expand All @@ -70,4 +106,7 @@ export const addressesByNetwork: { [chainId in ChainId]: Addresses } = {
[ChainId.SEPOLIA]: sepoliaAddresses,
[ChainId.ARB_SEPOLIA]: arbitrumSepoliaAddresses,
[ChainId.ARB_MAINNET]: arbitrumMainnetAddresses,
[ChainId.BASE_MAINNET]: baseMainnetAddresses,
[ChainId.BASE_SEPOLIA]: baseSepoliaAddresses,
[ChainId.BLAST_SEPOLIA]: blastSepoliaAddresses,
};
36 changes: 36 additions & 0 deletions src/constants/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,30 @@ export const chainInfo: { [chainId in ChainId]: ChainInfo } = {
cloudinaryUrl: "https://looksrare.mo.cloudinary.net/sepolia",
wsUrl: "wss://ws-sepolia.looksrare.org/ws",
},
[ChainId.BASE_MAINNET]: {
label: "Base Mainnet",
appUrl: "https://looksrare.org",
explorer: "https://basescan.org",
rpcUrl: "https://base-mainnet.g.alchemy.com/v2",
baseApiUrl: "https://graphql.looksrare.org",
osApiUrl: "https://api.opensea.io",
cdnUrl: "https://static.looksnice.org",
rewardsSubgraphUrl: "https://api.thegraph.com/subgraphs/name/looksrare/looks-distribution",
cloudinaryUrl: "https://looksrare.mo.cloudinary.net",
wsUrl: "wss://ws.looksrare.org/ws",
},
[ChainId.BASE_SEPOLIA]: {
label: "Base Sepolia",
appUrl: "https://sepolia.looksrare.org",
explorer: "https://sepolia-explorer.base.org",
rpcUrl: "https://base-sepolia.g.alchemy.com/v2",
baseApiUrl: "https://graphql-sepolia.looksrare.org",
osApiUrl: "https://testnets-api.opensea.io",
cdnUrl: "https://static-sepolia.looksnice.org",
rewardsSubgraphUrl: "https://api.thegraph.com/subgraphs/name/0xjurassicpunk/looks-distribution",
cloudinaryUrl: "https://looksrare.mo.cloudinary.net/sepolia",
wsUrl: "wss://ws-sepolia.looksrare.org/ws",
},
[ChainId.HARDHAT]: {
label: "Hardhat",
appUrl: "http://localhost:3000",
Expand All @@ -73,4 +97,16 @@ export const chainInfo: { [chainId in ChainId]: ChainInfo } = {
cloudinaryUrl: "",
wsUrl: "ws://localhost:5001/ws",
},
[ChainId.BLAST_SEPOLIA]: {
label: "Blast Sepolia",
appUrl: "https://sepolia.looksrare.org",
explorer: "https://testnet.blastscan.io/",
rpcUrl: "https://sepolia.blast.io",
baseApiUrl: "https://graphql-sepolia.looksrare.org",
osApiUrl: "https://testnets-api.opensea.io",
cdnUrl: "https://static-sepolia.looksnice.org",
rewardsSubgraphUrl: "https://api.thegraph.com/subgraphs/name/0xjurassicpunk/looks-distribution",
cloudinaryUrl: "https://looksrare.mo.cloudinary.net/sepolia",
wsUrl: "wss://ws-sepolia.looksrare.org/ws",
},
};
3 changes: 3 additions & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ export enum ChainId {
HARDHAT = 31337,
ARB_MAINNET = 42161,
ARB_SEPOLIA = 421614,
BASE_MAINNET = 8453,
BASE_SEPOLIA = 84532,
BLAST_SEPOLIA = 168587773,
}

/** ChainInfo data used to interact with LooksRare ecosystem */
Expand Down

0 comments on commit cbbc356

Please sign in to comment.