Skip to content

Commit

Permalink
Merge pull request #265 from yanyanho/dev
Browse files Browse the repository at this point in the history
replace the graph url of arbi and op
  • Loading branch information
yanyanho authored Jul 18, 2024
2 parents 90b6089 + 7ec552f commit 9a3ce7d
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 41 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -232,27 +232,27 @@ private HttpEntity getHttpEntityFromChain(String chainId) throws IOException {
HttpPost request = null;
switch (chainId) {
case Constants.CHAIN_ID_OP: // op
request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/Bfrtk6bLRZoULLzAZ99hZ1Ae8kvFxsUWa4e97XzWJYhG");
break;
case Constants.CHAIN_ID_SEPOLIA: // sepolia
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/9p6zFejTBC2bLLJRCdrk1A2PXfZkriRMacM5wiCAyh5Z");
break;
case Constants.CHAIN_ID_SCROLL: // scroll
request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/8HhHjdsXrZ1cjq5qNpksoWfAm1NTDDFhH2Yb8ZkBixjo");
request = new HttpPost("https://subgraph.satsuma-prod.com/3213d35a17f1/zhes-team--158805/dloptimismdistribute/api");
break;
// case Constants.CHAIN_ID_SEPOLIA: // sepolia
// request = new HttpPost(
// "https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/9p6zFejTBC2bLLJRCdrk1A2PXfZkriRMacM5wiCAyh5Z");
// break;
// case Constants.CHAIN_ID_SCROLL: // scroll
// request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/8HhHjdsXrZ1cjq5qNpksoWfAm1NTDDFhH2Yb8ZkBixjo");
// break;
case Constants.CHAIN_ID_ARBITRUM: // arbitrum
request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/BbFUyrr7KeB9VjxrSqWFDWAcsyDsGdbinrteLrPK5MVb");
break;
case Constants.CHAIN_ID_ZKSYNC: // zksync
request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/DzTmBT2V5kFQL6LpjC3iubYkusfj4HLVScCrAcT2DKGK");
break;
case Constants.CHAIN_ID_POLYGON_ZKEVM: // polygon zkevm
request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/A46TwCAxDy4upqLuS7bgXd14yLQdTjfS4AVPMNwWkZSR");
break;
case Constants.CHAIN_ID_LINEA: //linea
request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/DatcM6CoN5u79XPx1wYFFnWXpHYcfDodkbycx2vSp25C");
request = new HttpPost("https://subgraph.satsuma-prod.com/3213d35a17f1/zhes-team--158805/dlarbitrumdistribute/api");
break;
// case Constants.CHAIN_ID_ZKSYNC: // zksync
// request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/DzTmBT2V5kFQL6LpjC3iubYkusfj4HLVScCrAcT2DKGK");
// break;
// case Constants.CHAIN_ID_POLYGON_ZKEVM: // polygon zkevm
// request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/A46TwCAxDy4upqLuS7bgXd14yLQdTjfS4AVPMNwWkZSR");
// break;
// case Constants.CHAIN_ID_LINEA: //linea
// request = new HttpPost("https://gateway-arbitrum.network.thegraph.com/api/" + merkleDistributorConfig.getGraphConfig().getKey() +"/subgraphs/id/DatcM6CoN5u79XPx1wYFFnWXpHYcfDodkbycx2vSp25C");
// break;
}

if (request == null)
Expand Down
45 changes: 22 additions & 23 deletions src/main/java/com/dl/officialsite/redpacket/RedPacketService.java
Original file line number Diff line number Diff line change
Expand Up @@ -149,33 +149,32 @@ private HttpEntity getHttpEntityFromChain(String chainId) throws IOException {
switch (chainId) {
case Constants.CHAIN_ID_OP: // op
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +
"/subgraphs/id/G7LuMuUuWUW8UknEx8x2aVSeFtqpNMEKHvka2aKiDzRm");
break;
case Constants.CHAIN_ID_SEPOLIA: //sepolia
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/84hUXdB1qCmn8Du8bDmpLxxFSHjsgFCUKcrbtM4j5tp6");
break;
case Constants.CHAIN_ID_SCROLL: //scrool
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/6Ln5DVxZuYiY4VZzDQ2hzweBMRBpwW1SKRjeUy2YouRC");
"https://subgraph.satsuma-prod.com/f440a1fb5a7f/caodalong--672935/dloptimismredpacket/api");
break;
// case Constants.CHAIN_ID_SEPOLIA: //sepolia
// request = new HttpPost(
// "https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/84hUXdB1qCmn8Du8bDmpLxxFSHjsgFCUKcrbtM4j5tp6");
// break;
// case Constants.CHAIN_ID_SCROLL: //scrool
// request = new HttpPost(
// "https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/6Ln5DVxZuYiY4VZzDQ2hzweBMRBpwW1SKRjeUy2YouRC");
// break;
case Constants.CHAIN_ID_ARBITRUM: //arbitrum
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/9S1hiM5vzZ3m7o9SBpywHHcC8VZBSRUZTv3R8Npt56gS");
break;
case Constants.CHAIN_ID_ZKSYNC: //zksync
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/ERTqnTVeQKH8CVYwfGnqqZjtNDzgdnJRYQCgD4TY1gUX");
break;
case Constants.CHAIN_ID_POLYGON_ZKEVM: //polygon zkevm
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/5DsufFHE6P7tK7QT1mGCPrQEKURD2E1SSHAyCSzf5CAg");
break;
case Constants.CHAIN_ID_LINEA: //linea
request = new HttpPost(
"https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/958YHrTJturbhR6uwRyPu1wmBNiXivNkLMPY7tUiL4wD");
"https://subgraph.satsuma-prod.com/f440a1fb5a7f/caodalong--672935/dlarbitrumredpacket/api");
break;
// case Constants.CHAIN_ID_ZKSYNC: //zksync
// request = new HttpPost(
// "https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/ERTqnTVeQKH8CVYwfGnqqZjtNDzgdnJRYQCgD4TY1gUX");
// break;
// case Constants.CHAIN_ID_POLYGON_ZKEVM: //polygon zkevm
// request = new HttpPost(
// "https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/5DsufFHE6P7tK7QT1mGCPrQEKURD2E1SSHAyCSzf5CAg");
// break;
// case Constants.CHAIN_ID_LINEA: //linea
// request = new HttpPost(
// "https://gateway-arbitrum.network.thegraph.com/api/" + redPacketConfig.getGraphConfig().getKey() +"/subgraphs/id/958YHrTJturbhR6uwRyPu1wmBNiXivNkLMPY7tUiL4wD");
// break;

}
request.setHeader("Content-Type", "application/json");
Expand Down

0 comments on commit 9a3ce7d

Please sign in to comment.