diff --git a/.env b/.env index 4c2f1ad6..11c7bdd2 100644 --- a/.env +++ b/.env @@ -1,38 +1,46 @@ NODE_MODE=deployed DATABASE_URL_LOCAL=mongodb://localhost:27017/V2-graphQL -DATABASE_URL_ONLINE=mongodb+srv://admin:scytalelabs@cluster0-9yop5.mongodb.net/V2-graphQL-backend-demo?retryWrites=true&w=majority +DATABASE_URL_ONLINE=mongodb+srv://admin:scytalelabs@cluster0-9yop5.mongodb.net/V2-graphQL-backend-forinterface?retryWrites=true&w=majority COIN_MARKET_CAP_API_KEY=35a7ebf7-894d-4b67-8d57-36a2b050cbc8 -FACTORY_CONTRACT=Feb336a5487f160DA388d878296C9043Ab29b50daE9756675FD332408275bBeB -FACTORY_CONTRACT_PACKAGE=315A4d4d50132831DFD82bc3eB4f49Ec4E7CE6985b0dD57C43F075FFA4323853 -PAIR_CONTRACT=8E617aB8536AeF351eDc422F41F4FF1ECf26d27329D6df667e75381D49Aa65e2 -PAIR_CONTRACT_PACKAGE=FE1EAd1b5970755D2e636E78c29eA9e31fA13DC4E03DA7A3db0C6F6dceaa56a4 +FACTORY_CONTRACT=E52D527b3E7d9818cEDb6484e0e51ED3550505465C454e4Bd5e95d9418f3f93a +FACTORY_CONTRACT_PACKAGE=8589bE2588adb1240B8D6C470b4F2DF05cAa0bcb737962D77E3B628E9960Db2a +WCSPR=d540e0435C6Be6E7f359e132a99566d8da9d4aDc6bF19254072F32cc62A922bB +LIBRARY=e9E973B4c2D228d50311e696b0aedDEd80313F474a668E56c8Db31af0951a83c +PAIR_CONTRACT=27982d94c019D7E51c43C5aA60b771f458DcEddC7CEFFcc6d120f62B7321a610 +PAIR_CONTRACT_PACKAGE=4ed480e4d592852b515DeBDF7Af1301106F18649a314260A66DC29db743BCb1E CALLEE_CONTRACT=fbfeda8b97f056f526f20c2fc2b486d9bdbfb3e46b9a164527e57c0c86e68612 -TOKEN0_CONTRACT=635b24a7455FC130413eEA8f14D26A3BA8a92f96347E71F12B37cfA41Ff161f1 -TOKEN0_CONTRACT_PACKAGE=08dded65ea4c74269C471a1accfE358e48A05A191AC94d98fb16c1f15531fB4F -TOKEN1_CONTRACT=cd3aE802766D8b4Dbfb6bE9aA1c00983D4B8547e93564fd460b34630D1C9fd12 -TOKEN1_CONTRACT_PACKAGE=33A09555898Bd59822eBe134f9Ee5377c7fDC48c0161Da8c4fAe1A0B1a92429d +TOKEN0_CONTRACT=d540e0435C6Be6E7f359e132a99566d8da9d4aDc6bF19254072F32cc62A922bB +TOKEN0_CONTRACT_PACKAGE=aC1C3c25f46af1Eb60FE6A3E3349898ff75958e44B92F4312edf0FB8124133ec +TOKEN1_CONTRACT=45825eA26146D81EC58b7566B25757cD03B4e4F447Af1573E22EBeF38D93a6c1 +TOKEN1_CONTRACT_PACKAGE=97c882aC4C66b6c645C88416546699A1AeF6fd4b162A324da3e6D9f503BAb87d -WETH_CONTRACT=b0F4A61cdD8F0995cE84185598CB8A59682A20fa5C5FF95c00EFd268AE62AccF -WETH_CONTRACT_PACKAGE=40c305D8c156D96669a7c2a2843624923Feed0b869DE5136fAa9964E1be0AfaB +WCSPR_CONTRACT=d540e0435C6Be6E7f359e132a99566d8da9d4aDc6bF19254072F32cc62A922bB +WCSPR_CONTRACT_PACKAGE=aC1C3c25f46af1Eb60FE6A3E3349898ff75958e44B92F4312edf0FB8124133ec + +WISE_CONTRACT=bbe35d58c30e66e128f2AD83E4B2030441FDB5dA0227772ab7F277920F4482Ac +WISE_CONTRACT_PACKAGE=de46DA9475FD4ac3002A8eb74266589c65e48d0D55cC7cD0919b365B037D2Aa4 + +USDC_CONTRACT=45825eA26146D81EC58b7566B25757cD03B4e4F447Af1573E22EBeF38D93a6c1 +USDC_CONTRACT_PACKAGE=97c882aC4C66b6c645C88416546699A1AeF6fd4b162A324da3e6D9f503BAb87d + +WCSPR_WISE_CONTRACT=9c2AA298dc8f7bc10A7E57d005ED0A4C97597c963368246C51671c0794A48707 +WCSPR_WISE_CONTRACT_PACKAGE=780490fe3dA633ed7b8A2A6f3dA04e4725F6Ef226eC9484Af1D7aB8e16a9B5de + +WCSPR_USDC_CONTRACT=27982d94c019D7E51c43C5aA60b771f458DcEddC7CEFFcc6d120f62B7321a610 +WCSPR_USDC_CONTRACT_PACKAGE=4ed480e4d592852b515DeBDF7Af1301106F18649a314260A66DC29db743BCb1E DAI_CONTRACT=22b311471Fc4CeBA1b10204A4939A7772483C017CE74a1807f053D69F813714F DAI_CONTRACT_PACKAGE=a05337e453FCeef5C75e8F85254B441Ec1BeC13AbEC9Cc9Ada0a7A2b9400Fb3f -USDC_CONTRACT=5572759df79b1DbaE68270FbAd493dcFBc477097C63eEE88f3b57Bd07F5013b5 -USDC_CONTRACT_PACKAGE=1026614f9E470CEfc3c22617A6F10f98035AfBd52F3622A286521537A055851A - USDT_CONTRACT=F8D63B789784e150018dEc41236BeaF018061AFa44AA85E4A6e3D3d7Eaa13B07 USDT_CONTRACT_PACKAGE=85A2a3144fD921732f90BC538a3457e04E329ea5Ac5976372cfC910f94D345bA -WETH_DAI_CONTRACT=F41eea03821F59de6a3d48161dA1ba267Fc4048B7d6761Cb18E80C5C68049388 -WETH_DAI_CONTRACT_PACKAGE=f2Ae63407dea00ebD03cC7ff5DB5EC9f1e266f9C6A0e7890D6fC1940Cf5FD9c2 - -WETH_USDC_CONTRACT=d56974F48C484D73dD61b6C34Ec532123bF11C231600e8fb1F6D349D52658700 -WETH_USDC_CONTRACT_PACKAGE=7BD3e65A2aAb62c8f467ef4eb581E3C50cA445428bEF75eBCe697232da7dB104 +WCSPR_DAI_CONTRACT=F41eea03821F59de6a3d48161dA1ba267Fc4048B7d6761Cb18E80C5C68049388 +WCSPR_DAI_CONTRACT_PACKAGE=f2Ae63407dea00ebD03cC7ff5DB5EC9f1e266f9C6A0e7890D6fC1940Cf5FD9c2 -WETH_USDT_CONTRACT=d94b6EF6f2d47C7A054dfF699CB0B3A8294AE7221107aF837F9A78Fc3e795f72 -WETH_USDT_CONTRACT_PACKAGE=7bf128904dD425CB9bCCD910A83dF6B7FAA565249f2CA77bFDFA06E8676bC940 +WCSPR_USDT_CONTRACT=d94b6EF6f2d47C7A054dfF699CB0B3A8294AE7221107aF837F9A78Fc3e795f72 +WCSPR_USDT_CONTRACT_PACKAGE=7bf128904dD425CB9bCCD910A83dF6B7FAA565249f2CA77bFDFA06E8676bC940 GRAPHQL=http://localhost:3000/graphql @@ -52,8 +60,8 @@ PAIR_MASTER_KEY_PAIR_PATH=JsClients/PAIR/keys/ MASTER_KEY_PAIR_PATH=JsClients/ROUTER/keys/ ERC20_CONTRACT_NAME=erc20 -ERC20_TOKEN_NAME=token1 -ERC20_TOKEN_SYMBOL=erc +ERC20_TOKEN_NAME=WISE +ERC20_TOKEN_SYMBOL=WISE ERC20_DECIMALS=18 ERC20_TOTAL_SUPPLY=0 @@ -70,7 +78,7 @@ FACTORY_INSTALL_PAYMENT_AMOUNT=150000000000 PAIR_INSTALL_PAYMENT_AMOUNT=300000000000 MINT_PAYMENT_AMOUNT=5000000000 -MINT_AMOUNT=2000 +MINT_AMOUNT=1000 BURN_PAYMENT_AMOUNT=5000000000 BURN_AMOUNT=5 @@ -103,14 +111,10 @@ CREATE_PAIR_PAYMENT_AMOUNT=5000000000 TOKEN_NAME=uniswap-router TOKEN_SYMBOL=DRAG TOKEN_META=origin fire,lifetime infinite - -FACTORY=Feb336a5487f160DA388d878296C9043Ab29b50daE9756675FD332408275bBeB -WCSPR=Dd511B90c7f6eacd2F74f8A1B25305a2902e3554f7489e30ca0b19247AEAb031 -LIBRARY=a1f2C4107B70AcefDf2A7A56A9F0B3B0839880CEF70869DBf829a8b5d25C0Bf7 CONTRACT_NAME=UniSwapRouter -CONTRACT_HASH=72756eCa24936bABED4aF0d73D164351DD36374C549ba07537dd3917c320cE2E -PACKAGE_HASH=4c49499E985c2Adc03a200a80196E9cE1dA3d08D81BaE9Aa898BbE6dffd79B73 +CONTRACT_HASH=7BF6CabE546d56998Dd69A4A31E1ED10F01114E2D3a2064d9441275f68b68164 +PACKAGE_HASH=67EFaF1aBf4e1786dC4510fE03bec0a4c5E47bdE0Dd0b12fC0A3EE3fa5e77Ce5 INSTALL_PAYMENT_AMOUNT=200000000000 MINT_ONE_PAYMENT_AMOUNT=2000000000 MINT_COPIES_PAYMENT_AMOUNT=100000000000 @@ -121,14 +125,14 @@ MINT_COPIES_COUNT=20 MINT_MANY_META_SIZE=5 MINT_MANY_META_COUNT=5 -TO = 635b24a7455FC130413eEA8f14D26A3BA8a92f96347E71F12B37cfA41Ff161f1 +TO = d540e0435C6Be6E7f359e132a99566d8da9d4aDc6bF19254072F32cc62A922bB DEADLINE = 1739598100811 # add_liquidity -TOKEN_A = 635b24a7455FC130413eEA8f14D26A3BA8a92f96347E71F12B37cfA41Ff161f1 -TOKEN_B = cd3aE802766D8b4Dbfb6bE9aA1c00983D4B8547e93564fd460b34630D1C9fd12 -AMOUNT_A_DESIRED = 500 -AMOUNT_B_DESIRED = 600 +TOKEN_A = d540e0435C6Be6E7f359e132a99566d8da9d4aDc6bF19254072F32cc62A922bB +TOKEN_B = 45825eA26146D81EC58b7566B25757cD03B4e4F447Af1573E22EBeF38D93a6c1 +AMOUNT_A_DESIRED = 8000 +AMOUNT_B_DESIRED = 1000 AMOUNT_A_MIN = 250 AMOUNT_B_MIN = 300 diff --git a/JsClients/ERC20/keys/public_key.pem b/JsClients/ERC20/keys/public_key.pem index f98e72d5..8771b33f 100644 --- a/JsClients/ERC20/keys/public_key.pem +++ b/JsClients/ERC20/keys/public_key.pem @@ -1,3 +1,3 @@ -----BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEA3+dK57Rtp6tCa8ok1Tc7nsBk58+yRje2BOR/jpXRd9M= +MCowBQYDK2VwAyEAdAHEIxfo63Vd7xAcHgX7hvJEKHPG00EjSlKZwlwSqW4= -----END PUBLIC KEY----- diff --git a/JsClients/ERC20/keys/public_key_hex b/JsClients/ERC20/keys/public_key_hex index 2cc0d0ef..6b3b9a27 100644 --- a/JsClients/ERC20/keys/public_key_hex +++ b/JsClients/ERC20/keys/public_key_hex @@ -1 +1 @@ -01dfe74ae7b46da7ab426bca24d5373b9ec064e7cfb24637b604e47f8e95d177d3 \ No newline at end of file +017401c42317e8eb755def101c1e05fb86f2442873c6d341234a5299c25c12a96e \ No newline at end of file diff --git a/JsClients/ERC20/keys/secret_key.pem b/JsClients/ERC20/keys/secret_key.pem index 87bc46e3..9b3830a2 100644 --- a/JsClients/ERC20/keys/secret_key.pem +++ b/JsClients/ERC20/keys/secret_key.pem @@ -1,3 +1,3 @@ -----BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIAXbC6e4WdEjVyRrAD3RxaSDzw+vjnjoXfcYZXvZ/eS6 +MC4CAQAwBQYDK2VwBCIEILBFlQdHrxhOISa01o5a4Z7JF+/FtroCwFIQAA9XjOgP -----END PRIVATE KEY----- diff --git a/JsClients/FACTORY/keys/public_key.pem b/JsClients/FACTORY/keys/public_key.pem index 034388b7..d85d6fd2 100644 --- a/JsClients/FACTORY/keys/public_key.pem +++ b/JsClients/FACTORY/keys/public_key.pem @@ -1,3 +1,3 @@ -----BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEA1+OwE9RelRF3eORZ3e4iUWIW1W883H+LOXwzWrZqbVA= +MCowBQYDK2VwAyEAtWGFIJ0gO1SctlvGB+BubT+DMZLEdOnO66/hVBUpspI= -----END PUBLIC KEY----- diff --git a/JsClients/FACTORY/keys/public_key_hex b/JsClients/FACTORY/keys/public_key_hex index 3d006af4..88e98320 100644 --- a/JsClients/FACTORY/keys/public_key_hex +++ b/JsClients/FACTORY/keys/public_key_hex @@ -1 +1 @@ -01d7e3b013d45e95117778e459ddee22516216d56f3cdc7f8b397c335ab66a6d50 \ No newline at end of file +01b56185209d203b549cb65bc607e06e6d3f833192c474e9ceebafe1541529b292 \ No newline at end of file diff --git a/JsClients/FACTORY/keys/secret_key.pem b/JsClients/FACTORY/keys/secret_key.pem index 5e4511be..88959fc1 100644 --- a/JsClients/FACTORY/keys/secret_key.pem +++ b/JsClients/FACTORY/keys/secret_key.pem @@ -1,3 +1,3 @@ -----BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEILl9vXz3VhH+hkAP2AWLl6j7ODQKTRcOKiEhKwTMzU/Z +MC4CAQAwBQYDK2VwBCIEIAfQJZLsmOUr6dRXZIrSLw2xDjcokM3vNuArKhbM+eES -----END PRIVATE KEY----- diff --git a/JsClients/KEY/deploykeys/public_key.pem b/JsClients/KEY/deploykeys/public_key.pem new file mode 100644 index 00000000..8fd204d9 --- /dev/null +++ b/JsClients/KEY/deploykeys/public_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PUBLIC KEY----- +MCowBQYDK2VwAyEAz4Em841i4YEWHO1DKdEks1sqMz6Q0qUSWbUVQMqXCdU= +-----END PUBLIC KEY----- diff --git a/JsClients/KEY/deploykeys/public_key_hex b/JsClients/KEY/deploykeys/public_key_hex new file mode 100644 index 00000000..89074db0 --- /dev/null +++ b/JsClients/KEY/deploykeys/public_key_hex @@ -0,0 +1 @@ +01cf8126f38d62e181161ced4329d124b35b2a333e90d2a51259b51540ca9709d5 \ No newline at end of file diff --git a/JsClients/KEY/deploykeys/secret_key.pem b/JsClients/KEY/deploykeys/secret_key.pem new file mode 100644 index 00000000..bd34f91d --- /dev/null +++ b/JsClients/KEY/deploykeys/secret_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PRIVATE KEY----- +MC4CAQAwBQYDK2VwBCIEIOWIxnHwe+sv0SCiB2UB8EMclilV5mOBlEUxEJ0MVhE/ +-----END PRIVATE KEY----- diff --git a/JsClients/KEY/erc20keys/public_key.pem b/JsClients/KEY/erc20keys/public_key.pem new file mode 100644 index 00000000..5503c5e0 --- /dev/null +++ b/JsClients/KEY/erc20keys/public_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PUBLIC KEY----- +MCowBQYDK2VwAyEAdAHEIxfo63Vd7xAcHgX7hvJEKHPG00EjSlKZwlwSqW4= +-----END PUBLIC KEY----- diff --git a/JsClients/KEY/erc20keys/public_key_hex b/JsClients/KEY/erc20keys/public_key_hex new file mode 100644 index 00000000..6b3b9a27 --- /dev/null +++ b/JsClients/KEY/erc20keys/public_key_hex @@ -0,0 +1 @@ +017401c42317e8eb755def101c1e05fb86f2442873c6d341234a5299c25c12a96e \ No newline at end of file diff --git a/JsClients/KEY/erc20keys/secret_key.pem b/JsClients/KEY/erc20keys/secret_key.pem new file mode 100644 index 00000000..6f4de8fd --- /dev/null +++ b/JsClients/KEY/erc20keys/secret_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PRIVATE KEY----- +MC4CAQAwBQYDK2VwBCIEILBFlQdHrxhOISa01o5a4Z7JF+/FtroCwFIQAA9XjOgP +-----END PRIVATE KEY----- diff --git a/JsClients/KEY/extrakeys/public_key.pem b/JsClients/KEY/extrakeys/public_key.pem new file mode 100644 index 00000000..5e7e11e9 --- /dev/null +++ b/JsClients/KEY/extrakeys/public_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PUBLIC KEY----- +MCowBQYDK2VwAyEAWltK4eH/EP1hDH1jI9PDMUOKge73vNOqR4P28mT6OqQ= +-----END PUBLIC KEY----- diff --git a/JsClients/KEY/extrakeys/public_key_hex b/JsClients/KEY/extrakeys/public_key_hex new file mode 100644 index 00000000..cfb004bf --- /dev/null +++ b/JsClients/KEY/extrakeys/public_key_hex @@ -0,0 +1 @@ +015a5b4ae1e1ff10fd610c7d6323d3c331438a81eef7bcd3aa4783f6f264fa3aa4 \ No newline at end of file diff --git a/JsClients/KEY/extrakeys/secret_key.pem b/JsClients/KEY/extrakeys/secret_key.pem new file mode 100644 index 00000000..c6c4469f --- /dev/null +++ b/JsClients/KEY/extrakeys/secret_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PRIVATE KEY----- +MC4CAQAwBQYDK2VwBCIEIPoXHj1Ln9iB/pbHoB1DGVc0f11S422kDfAH5XD67EUa +-----END PRIVATE KEY----- diff --git a/JsClients/KEY/factorykeys/public_key.pem b/JsClients/KEY/factorykeys/public_key.pem new file mode 100644 index 00000000..17bd5804 --- /dev/null +++ b/JsClients/KEY/factorykeys/public_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PUBLIC KEY----- +MCowBQYDK2VwAyEAtWGFIJ0gO1SctlvGB+BubT+DMZLEdOnO66/hVBUpspI= +-----END PUBLIC KEY----- diff --git a/JsClients/KEY/factorykeys/public_key_hex b/JsClients/KEY/factorykeys/public_key_hex new file mode 100644 index 00000000..88e98320 --- /dev/null +++ b/JsClients/KEY/factorykeys/public_key_hex @@ -0,0 +1 @@ +01b56185209d203b549cb65bc607e06e6d3f833192c474e9ceebafe1541529b292 \ No newline at end of file diff --git a/JsClients/KEY/factorykeys/secret_key.pem b/JsClients/KEY/factorykeys/secret_key.pem new file mode 100644 index 00000000..2f572d68 --- /dev/null +++ b/JsClients/KEY/factorykeys/secret_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PRIVATE KEY----- +MC4CAQAwBQYDK2VwBCIEIAfQJZLsmOUr6dRXZIrSLw2xDjcokM3vNuArKhbM+eES +-----END PRIVATE KEY----- diff --git a/JsClients/KEY/moneykeys/public_key.pem b/JsClients/KEY/moneykeys/public_key.pem new file mode 100644 index 00000000..6a348344 --- /dev/null +++ b/JsClients/KEY/moneykeys/public_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PUBLIC KEY----- +MCowBQYDK2VwAyEAkiDYds03hKjSdfJng8iSp3bx4V/aEbDAYJt6Ny+cz9Q= +-----END PUBLIC KEY----- diff --git a/JsClients/KEY/moneykeys/public_key_hex b/JsClients/KEY/moneykeys/public_key_hex new file mode 100644 index 00000000..b69ed86d --- /dev/null +++ b/JsClients/KEY/moneykeys/public_key_hex @@ -0,0 +1 @@ +019220d876cd3784a8d275f26783c892a776f1e15fda11b0c0609b7a372f9ccfd4 \ No newline at end of file diff --git a/JsClients/KEY/moneykeys/secret_key.pem b/JsClients/KEY/moneykeys/secret_key.pem new file mode 100644 index 00000000..c7e58e13 --- /dev/null +++ b/JsClients/KEY/moneykeys/secret_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PRIVATE KEY----- +MC4CAQAwBQYDK2VwBCIEINn5R/VQW1MUs0NC5XmmN7SBAgZIx9v4ModUIPb6Pc64 +-----END PRIVATE KEY----- diff --git a/JsClients/KEY/pairkeys/public_key.pem b/JsClients/KEY/pairkeys/public_key.pem new file mode 100644 index 00000000..7c53b0b2 --- /dev/null +++ b/JsClients/KEY/pairkeys/public_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PUBLIC KEY----- +MCowBQYDK2VwAyEATV8zAx7R6t6WJF5yy9hdWHMXNtwoDMtzfTBtR89qBfA= +-----END PUBLIC KEY----- diff --git a/JsClients/KEY/pairkeys/public_key_hex b/JsClients/KEY/pairkeys/public_key_hex new file mode 100644 index 00000000..9f10dccf --- /dev/null +++ b/JsClients/KEY/pairkeys/public_key_hex @@ -0,0 +1 @@ +014d5f33031ed1eade96245e72cbd85d58731736dc280ccb737d306d47cf6a05f0 \ No newline at end of file diff --git a/JsClients/KEY/pairkeys/secret_key.pem b/JsClients/KEY/pairkeys/secret_key.pem new file mode 100644 index 00000000..cdc7a286 --- /dev/null +++ b/JsClients/KEY/pairkeys/secret_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PRIVATE KEY----- +MC4CAQAwBQYDK2VwBCIEIFLdK204pwQWlbcyJhwFt6lm8IA1CE5bGkgOorL7Fpw9 +-----END PRIVATE KEY----- diff --git a/JsClients/KEY/routerkeys/public_key.pem b/JsClients/KEY/routerkeys/public_key.pem new file mode 100644 index 00000000..ed8c6f86 --- /dev/null +++ b/JsClients/KEY/routerkeys/public_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PUBLIC KEY----- +MCowBQYDK2VwAyEA+do3V4WYtns0Fo1Pf515rpcb13KxTZ2CqE0fO2EwLI0= +-----END PUBLIC KEY----- diff --git a/JsClients/KEY/routerkeys/public_key_hex b/JsClients/KEY/routerkeys/public_key_hex new file mode 100644 index 00000000..9bd6c364 --- /dev/null +++ b/JsClients/KEY/routerkeys/public_key_hex @@ -0,0 +1 @@ +01f9da37578598b67b34168d4f7f9d79ae971bd772b14d9d82a84d1f3b61302c8d \ No newline at end of file diff --git a/JsClients/KEY/routerkeys/secret_key.pem b/JsClients/KEY/routerkeys/secret_key.pem new file mode 100644 index 00000000..54c63279 --- /dev/null +++ b/JsClients/KEY/routerkeys/secret_key.pem @@ -0,0 +1,3 @@ +-----BEGIN PRIVATE KEY----- +MC4CAQAwBQYDK2VwBCIEIFRzYRkz4v3gXo9Y6NyX4tfnwCXMpPxcC5NY7hcIlih/ +-----END PRIVATE KEY----- diff --git a/JsClients/PAIR/keys/public_key.pem b/JsClients/PAIR/keys/public_key.pem index de2b7e14..3033acba 100644 --- a/JsClients/PAIR/keys/public_key.pem +++ b/JsClients/PAIR/keys/public_key.pem @@ -1,3 +1,3 @@ -----BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEAQNtKh0ylHmSZUIbTnJuiit4EnohD0eeJ4TZp3nFtk9Y= +MCowBQYDK2VwAyEAz4Em841i4YEWHO1DKdEks1sqMz6Q0qUSWbUVQMqXCdU= -----END PUBLIC KEY----- diff --git a/JsClients/PAIR/keys/public_key_hex b/JsClients/PAIR/keys/public_key_hex index 7807fcf6..89074db0 100644 --- a/JsClients/PAIR/keys/public_key_hex +++ b/JsClients/PAIR/keys/public_key_hex @@ -1 +1 @@ -0140db4a874ca51e64995086d39c9ba28ade049e8843d1e789e13669de716d93d6 \ No newline at end of file +01cf8126f38d62e181161ced4329d124b35b2a333e90d2a51259b51540ca9709d5 \ No newline at end of file diff --git a/JsClients/PAIR/keys/secret_key.pem b/JsClients/PAIR/keys/secret_key.pem index 5a39a0f5..39fe9ece 100644 --- a/JsClients/PAIR/keys/secret_key.pem +++ b/JsClients/PAIR/keys/secret_key.pem @@ -1,3 +1,3 @@ -----BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEICfW+upRlenPvqwo+WC1pO/hqBdNz89jk49DczFA242n +MC4CAQAwBQYDK2VwBCIEIOWIxnHwe+sv0SCiB2UB8EMclilV5mOBlEUxEJ0MVhE/ -----END PRIVATE KEY----- diff --git a/JsClients/ROUTER/keys/public_key.pem b/JsClients/ROUTER/keys/public_key.pem index cb47a159..6a348344 100644 --- a/JsClients/ROUTER/keys/public_key.pem +++ b/JsClients/ROUTER/keys/public_key.pem @@ -1,3 +1,3 @@ -----BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEA7/psTmqMpHP9Qa7WsOpobZTYRpqLgiBAm1PR1i0r/n0= +MCowBQYDK2VwAyEAkiDYds03hKjSdfJng8iSp3bx4V/aEbDAYJt6Ny+cz9Q= -----END PUBLIC KEY----- diff --git a/JsClients/ROUTER/keys/public_key_hex b/JsClients/ROUTER/keys/public_key_hex index 7a886b23..b69ed86d 100644 --- a/JsClients/ROUTER/keys/public_key_hex +++ b/JsClients/ROUTER/keys/public_key_hex @@ -1 +1 @@ -01effa6c4e6a8ca473fd41aed6b0ea686d94d8469a8b8220409b53d1d62d2bfe7d \ No newline at end of file +019220d876cd3784a8d275f26783c892a776f1e15fda11b0c0609b7a372f9ccfd4 \ No newline at end of file diff --git a/JsClients/ROUTER/keys/secret_key.pem b/JsClients/ROUTER/keys/secret_key.pem index 90028eef..c7e58e13 100644 --- a/JsClients/ROUTER/keys/secret_key.pem +++ b/JsClients/ROUTER/keys/secret_key.pem @@ -1,3 +1,3 @@ -----BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIE6qeWIPHTdUrPVEFu9RRaizeEG64llEZJm5MPAeY5tI +MC4CAQAwBQYDK2VwBCIEINn5R/VQW1MUs0NC5XmmN7SBAgZIx9v4ModUIPb6Pc64 -----END PRIVATE KEY----- diff --git a/JsClients/ROUTER/test/install.ts b/JsClients/ROUTER/test/install.ts index f02a7616..048fe903 100644 --- a/JsClients/ROUTER/test/install.ts +++ b/JsClients/ROUTER/test/install.ts @@ -18,7 +18,7 @@ const { MASTER_KEY_PAIR_PATH, TOKEN_NAME, TOKEN_SYMBOL, - FACTORY, + FACTORY_CONTRACT, WCSPR, LIBRARY, CONTRACT_NAME, @@ -59,7 +59,7 @@ const test = async () => { const installDeployHash = await uniswapRouter.install( KEYS, - FACTORY!, + FACTORY_CONTRACT!, WCSPR!, LIBRARY!, 'UniSwapRouter', @@ -67,7 +67,7 @@ const test = async () => { WASM_PATH! ); - console.log("Passed Parameters: \nfactory: \t", FACTORY, + console.log("Passed Parameters: \nfactory: \t", FACTORY_CONTRACT, "\nwcspr: \t", WCSPR, "\nlibrary: \t", LIBRARY, "\ncontract_name: \t", CONTRACT_NAME, "\n"); diff --git a/JsClients/ROUTER/wasm/uniswap-v2-router.wasm b/JsClients/ROUTER/wasm/uniswap-v2-router.wasm index 149cf8cf..b8d2c7b0 100644 Binary files a/JsClients/ROUTER/wasm/uniswap-v2-router.wasm and b/JsClients/ROUTER/wasm/uniswap-v2-router.wasm differ diff --git a/JsClients/keys/erc20keys/public_key.pem b/JsClients/keys/erc20keys/public_key.pem deleted file mode 100644 index e7b8ab2f..00000000 --- a/JsClients/keys/erc20keys/public_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEA3+dK57Rtp6tCa8ok1Tc7nsBk58+yRje2BOR/jpXRd9M= ------END PUBLIC KEY----- diff --git a/JsClients/keys/erc20keys/public_key_hex b/JsClients/keys/erc20keys/public_key_hex deleted file mode 100644 index 2cc0d0ef..00000000 --- a/JsClients/keys/erc20keys/public_key_hex +++ /dev/null @@ -1 +0,0 @@ -01dfe74ae7b46da7ab426bca24d5373b9ec064e7cfb24637b604e47f8e95d177d3 \ No newline at end of file diff --git a/JsClients/keys/erc20keys/secret_key.pem b/JsClients/keys/erc20keys/secret_key.pem deleted file mode 100644 index 0843b8ca..00000000 --- a/JsClients/keys/erc20keys/secret_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIAXbC6e4WdEjVyRrAD3RxaSDzw+vjnjoXfcYZXvZ/eS6 ------END PRIVATE KEY----- diff --git a/JsClients/keys/extrakeys/public_key.pem b/JsClients/keys/extrakeys/public_key.pem deleted file mode 100644 index e7b8ab2f..00000000 --- a/JsClients/keys/extrakeys/public_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEA3+dK57Rtp6tCa8ok1Tc7nsBk58+yRje2BOR/jpXRd9M= ------END PUBLIC KEY----- diff --git a/JsClients/keys/extrakeys/public_key_hex b/JsClients/keys/extrakeys/public_key_hex deleted file mode 100644 index 2cc0d0ef..00000000 --- a/JsClients/keys/extrakeys/public_key_hex +++ /dev/null @@ -1 +0,0 @@ -01dfe74ae7b46da7ab426bca24d5373b9ec064e7cfb24637b604e47f8e95d177d3 \ No newline at end of file diff --git a/JsClients/keys/extrakeys/secret_key.pem b/JsClients/keys/extrakeys/secret_key.pem deleted file mode 100644 index 0843b8ca..00000000 --- a/JsClients/keys/extrakeys/secret_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIAXbC6e4WdEjVyRrAD3RxaSDzw+vjnjoXfcYZXvZ/eS6 ------END PRIVATE KEY----- diff --git a/JsClients/keys/factorykeys/public_key.pem b/JsClients/keys/factorykeys/public_key.pem deleted file mode 100644 index aab8e72a..00000000 --- a/JsClients/keys/factorykeys/public_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEA1+OwE9RelRF3eORZ3e4iUWIW1W883H+LOXwzWrZqbVA= ------END PUBLIC KEY----- diff --git a/JsClients/keys/factorykeys/public_key_hex b/JsClients/keys/factorykeys/public_key_hex deleted file mode 100644 index 3d006af4..00000000 --- a/JsClients/keys/factorykeys/public_key_hex +++ /dev/null @@ -1 +0,0 @@ -01d7e3b013d45e95117778e459ddee22516216d56f3cdc7f8b397c335ab66a6d50 \ No newline at end of file diff --git a/JsClients/keys/factorykeys/secret_key.pem b/JsClients/keys/factorykeys/secret_key.pem deleted file mode 100644 index 85eeee81..00000000 --- a/JsClients/keys/factorykeys/secret_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEILl9vXz3VhH+hkAP2AWLl6j7ODQKTRcOKiEhKwTMzU/Z ------END PRIVATE KEY----- diff --git a/JsClients/keys/pairkeys/public_key.pem b/JsClients/keys/pairkeys/public_key.pem deleted file mode 100644 index 3a3b9ab5..00000000 --- a/JsClients/keys/pairkeys/public_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEAQNtKh0ylHmSZUIbTnJuiit4EnohD0eeJ4TZp3nFtk9Y= ------END PUBLIC KEY----- diff --git a/JsClients/keys/pairkeys/public_key_hex b/JsClients/keys/pairkeys/public_key_hex deleted file mode 100644 index 7807fcf6..00000000 --- a/JsClients/keys/pairkeys/public_key_hex +++ /dev/null @@ -1 +0,0 @@ -0140db4a874ca51e64995086d39c9ba28ade049e8843d1e789e13669de716d93d6 \ No newline at end of file diff --git a/JsClients/keys/pairkeys/secret_key.pem b/JsClients/keys/pairkeys/secret_key.pem deleted file mode 100644 index 06491e9e..00000000 --- a/JsClients/keys/pairkeys/secret_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEICfW+upRlenPvqwo+WC1pO/hqBdNz89jk49DczFA242n ------END PRIVATE KEY----- diff --git a/JsClients/keys/routerkeys/public_key.pem b/JsClients/keys/routerkeys/public_key.pem deleted file mode 100644 index cb47a159..00000000 --- a/JsClients/keys/routerkeys/public_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEA7/psTmqMpHP9Qa7WsOpobZTYRpqLgiBAm1PR1i0r/n0= ------END PUBLIC KEY----- diff --git a/JsClients/keys/routerkeys/public_key_hex b/JsClients/keys/routerkeys/public_key_hex deleted file mode 100644 index 7a886b23..00000000 --- a/JsClients/keys/routerkeys/public_key_hex +++ /dev/null @@ -1 +0,0 @@ -01effa6c4e6a8ca473fd41aed6b0ea686d94d8469a8b8220409b53d1d62d2bfe7d \ No newline at end of file diff --git a/JsClients/keys/routerkeys/secret_key.pem b/JsClients/keys/routerkeys/secret_key.pem deleted file mode 100644 index 90028eef..00000000 --- a/JsClients/keys/routerkeys/secret_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIE6qeWIPHTdUrPVEFu9RRaizeEG64llEZJm5MPAeY5tI ------END PRIVATE KEY----- diff --git a/JsClients/keys/stablecoinkeys/public_key.pem b/JsClients/keys/stablecoinkeys/public_key.pem deleted file mode 100644 index 74d49310..00000000 --- a/JsClients/keys/stablecoinkeys/public_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEAFs3RI2a6ola6cfah+AS7gB3ljhRwyOJ5JD5eqESGxRc= ------END PUBLIC KEY----- diff --git a/JsClients/keys/stablecoinkeys/public_key_hex b/JsClients/keys/stablecoinkeys/public_key_hex deleted file mode 100644 index 884ffad2..00000000 --- a/JsClients/keys/stablecoinkeys/public_key_hex +++ /dev/null @@ -1 +0,0 @@ -0116cdd12366baa256ba71f6a1f804bb801de58e1470c8e279243e5ea84486c517 \ No newline at end of file diff --git a/JsClients/keys/stablecoinkeys/secret_key.pem b/JsClients/keys/stablecoinkeys/secret_key.pem deleted file mode 100644 index 0081e8a1..00000000 --- a/JsClients/keys/stablecoinkeys/secret_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEICBEaiC8+ZHwQwcfj0ixrSbgNp/Neo7mB7zMpATARyNG ------END PRIVATE KEY----- diff --git a/JsClients/keys/stablecoinpairkeys/public_key.pem b/JsClients/keys/stablecoinpairkeys/public_key.pem deleted file mode 100644 index ac0b57a9..00000000 --- a/JsClients/keys/stablecoinpairkeys/public_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PUBLIC KEY----- -MCowBQYDK2VwAyEAQRCCnJYvBjg45F6tiOUmbO1Zto3/PTNQuGDx+H8PxdA= ------END PUBLIC KEY----- diff --git a/JsClients/keys/stablecoinpairkeys/public_key_hex b/JsClients/keys/stablecoinpairkeys/public_key_hex deleted file mode 100644 index 9f82f5ba..00000000 --- a/JsClients/keys/stablecoinpairkeys/public_key_hex +++ /dev/null @@ -1 +0,0 @@ -014110829c962f063838e45ead88e5266ced59b68dff3d3350b860f1f87f0fc5d0 \ No newline at end of file diff --git a/JsClients/keys/stablecoinpairkeys/secret_key.pem b/JsClients/keys/stablecoinpairkeys/secret_key.pem deleted file mode 100644 index 4147e5d4..00000000 --- a/JsClients/keys/stablecoinpairkeys/secret_key.pem +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIJQ1lN4GXj9Ss8w7KnaZFraUzq0s8PvQi1hgAD2fCwkL ------END PRIVATE KEY----- diff --git a/graphql/mutations.js b/graphql/mutations.js index 9cb6cdbb..27216b03 100644 --- a/graphql/mutations.js +++ b/graphql/mutations.js @@ -158,8 +158,9 @@ const handleNewPair = { let TokenName=await fetchTokenName(args.token1); let TokenSymbol=await fetchTokenSymbol(args.token1); - let TokenTotalSupply=await fetchTokenTotalSupply(args.token1); - + //let TokenTotalSupply=await fetchTokenTotalSupply(args.token1); + let TokenTotalSupply=10000; + token1 = new Token({ id: args.token1, symbol: TokenSymbol, diff --git a/graphql/pricing.js b/graphql/pricing.js index f97c22b4..6c7f6d85 100644 --- a/graphql/pricing.js +++ b/graphql/pricing.js @@ -11,16 +11,17 @@ const { //UNTRACKED_PAIRS } = require("./helpers"); -const WETH_ADDRESS = "b0F4A61cdD8F0995cE84185598CB8A59682A20fa5C5FF95c00EFd268AE62AccF".toLowerCase(); -const USDC_WETH_PAIR = "F41eea03821F59de6a3d48161dA1ba267Fc4048B7d6761Cb18E80C5C68049388".toLowerCase(); // created 10008355 -const DAI_WETH_PAIR = "d56974F48C484D73dD61b6C34Ec532123bF11C231600e8fb1F6D349D52658700".toLowerCase(); // created block 10042267 -const USDT_WETH_PAIR = "d94b6EF6f2d47C7A054dfF699CB0B3A8294AE7221107aF837F9A78Fc3e795f72".toLowerCase(); // created block 10093341 +const WCSPR_ADDRESS = "d540e0435C6Be6E7f359e132a99566d8da9d4aDc6bF19254072F32cc62A922bB".toLowerCase(); +const WCSPR_USDC__PAIR = "27982d94c019D7E51c43C5aA60b771f458DcEddC7CEFFcc6d120f62B7321a610".toLowerCase(); // created 10008355 +const WCSPR_DAI_PAIR = "0000000000000000000000000000000000000000000000000000000000000000".toLowerCase(); // created block 10042267 +const WCSPR_USDT_PAIR = "0000000000000000000000000000000000000000000000000000000000000000".toLowerCase(); // created block 10093341 async function getEthPriceInUSD() { + // fetch eth prices for each stablecoin - let daiPair = await Pair.findOne({ id: DAI_WETH_PAIR }); // dai is token0 - let usdcPair = await Pair.findOne({ id: USDC_WETH_PAIR }); // usdc is token0 - let usdtPair = await Pair.findOne({ id: USDT_WETH_PAIR }); // usdt is token1 + let daiPair = await Pair.findOne({ id: WCSPR_DAI_PAIR }); // dai is token0 + let usdcPair = await Pair.findOne({ id: WCSPR_USDC__PAIR }); // usdc is token0 + let usdtPair = await Pair.findOne({ id: WCSPR_USDT_PAIR }); // usdt is token1 // all 3 have been created if (daiPair !== null && usdcPair !== null && usdtPair !== null) { @@ -50,10 +51,10 @@ async function getEthPriceInUSD() { // token where amounts should contribute to tracked volume and liquidity let WHITELIST = [ - "b0F4A61cdD8F0995cE84185598CB8A59682A20fa5C5FF95c00EFd268AE62AccF".toLowerCase(), // WETH - "22b311471Fc4CeBA1b10204A4939A7772483C017CE74a1807f053D69F813714F".toLowerCase(), // DAI - "5572759df79b1DbaE68270FbAd493dcFBc477097C63eEE88f3b57Bd07F5013b5".toLowerCase(), // USDC - "F8D63B789784e150018dEc41236BeaF018061AFa44AA85E4A6e3D3d7Eaa13B07".toLowerCase(), // USDT + "d540e0435C6Be6E7f359e132a99566d8da9d4aDc6bF19254072F32cc62A922bB".toLowerCase(), // WCSPR + "0000000000000000000000000000000000000000000000000000000000000000".toLowerCase(), // DAI + "45825eA26146D81EC58b7566B25757cD03B4e4F447Af1573E22EBeF38D93a6c1".toLowerCase(), // USDC + "0000000000000000000000000000000000000000000000000000000000000000".toLowerCase(), // USDT ]; // minimum liquidity required to count towards tracked volume for pairs with small # of Lps @@ -69,7 +70,7 @@ let MINIMUM_LIQUIDITY_THRESHOLD_ETH = 2; * @todo update to be derived ETH (add stablecoin estimates) **/ async function findEthPerToken(token) { - if (token.id == WETH_ADDRESS) { + if (token.id == WCSPR_ADDRESS) { return ONE_BD; } // loop through whitelist and check if paired with any diff --git a/package.json b/package.json index b0994c52..06e6c8a6 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,15 @@ "version": "0.0.0", "private": true, "scripts": { - "start": "ts-node ./bin/www" + "start": "ts-node ./bin/www", + "test:erc20install": "ts-node JsClients/ERC20/test/install.ts", + "test:erc20installed": "ts-node JsClients/ERC20/test/installed.ts", + "test:pairinstall": "ts-node JsClients/PAIR/test/install.ts", + "test:pairinstalled": "ts-node JsClients/PAIR/test/installed.ts", + "test:factoryinstall": "ts-node JsClients/FACTORY/test/install.ts", + "test:factoryinstalled": "ts-node JsClients/FACTORY/test/installed.ts", + "test:routerinstall": "ts-node JsClients/ROUTER/test/install.ts", + "test:routerinstalled": "ts-node JsClients/ROUTER/test/installed.ts" }, "dependencies": { "axios": "^0.24.0", diff --git a/test.js b/test.js index 299da695..c3eea84b 100644 --- a/test.js +++ b/test.js @@ -8,5 +8,5 @@ // var date = new Date("2021-12-14T18:42:24.445Z"); // var seconds = date.getTime(); // console.log("time: ",seconds); -let contractHash="Feb336a5487f160DA388d878296C9043Ab29b50daE9756675FD332408275bBeB".toLowerCase(); +let contractHash="9AAc32Ad999163C374dd7A87E0046b126A0466Cc944C68EAF69ca4cC4d1788C4".toLowerCase(); console.log(contractHash); \ No newline at end of file