Skip to content

Commit

Permalink
fix: mantle graph node url (#1170)
Browse files Browse the repository at this point in the history
  • Loading branch information
MantisClone committed Sep 28, 2023
1 parent 446ca66 commit 89d60f4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions packages/payment-detection/src/thegraph/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ import { getSdk as getNearSdk } from './generated/graphql-near';
const HOSTED_THE_GRAPH_URL =
'https://api.thegraph.com/subgraphs/name/requestnetwork/request-payments-';

const THE_GRAPH_URL_MANTLE_TESTNET =
'https://graph.testnet.mantle.xyz/subgraphs/name/requestnetwork/request-payments-mantle-testnet';

const THE_GRAPH_URL_MANTLE =
'https://graph.fusionx.finance/subgraphs/name/requestnetwork/request-payments-mantle';

// NB: the GraphQL client is automatically generated based on files present in ./queries,
// using graphql-codegen.
// To generate types, run `yarn codegen`, then open the generated files so that the code editor picks up the changes.
Expand Down Expand Up @@ -36,5 +42,9 @@ export const defaultGetTheGraphClient = (network: CurrencyTypes.ChainName) => {
? undefined
: NearChains.isChainSupported(network)
? getTheGraphNearClient(`${HOSTED_THE_GRAPH_URL}${network.replace('aurora', 'near')}`)
: network === 'mantle'
? getTheGraphClient(THE_GRAPH_URL_MANTLE)
: network === 'mantle-testnet'
? getTheGraphClient(THE_GRAPH_URL_MANTLE_TESTNET)
: getTheGraphClient(`${HOSTED_THE_GRAPH_URL}${network}`);
};

0 comments on commit 89d60f4

Please sign in to comment.