@requestnetwork/payment-detection 0.43.1-next.2046 → 0.43.1-next.2047
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -8,4 +8,5 @@ export type TheGraphClientOptions = RequestConfig & {
|
|
|
8
8
|
baseUrl?: string;
|
|
9
9
|
};
|
|
10
10
|
export declare const getTheGraphSuperfluidClient: (network: string, options?: TheGraphClientOptions) => TheGraphSuperfluidClient;
|
|
11
|
+
export declare const buildTheGraphSuperfluidUrl: (baseUrl: string | undefined, network: string) => string;
|
|
11
12
|
//# sourceMappingURL=superfluid.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"superfluid.d.ts","sourceRoot":"","sources":["../../src/thegraph/superfluid.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;AACxD,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"superfluid.d.ts","sourceRoot":"","sources":["../../src/thegraph/superfluid.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;AACxD,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAmB1D;;GAEG;AACH,MAAM,MAAM,wBAAwB,GAAG,UAAU,CAAC,OAAO,MAAM,CAAC,CAAC;AACjE,MAAM,MAAM,qBAAqB,GAAG,aAAa,GAAG;IAClD,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,eAAO,MAAM,2BAA2B,YAC7B,MAAM,YACL,qBAAqB,KAC9B,wBAIF,CAAC;AAEF,eAAO,MAAM,0BAA0B,YAC5B,MAAM,GAAG,SAAS,WAClB,MAAM,KACd,MASF,CAAC"}
|
|
@@ -1,24 +1,37 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getTheGraphSuperfluidClient = void 0;
|
|
3
|
+
exports.buildTheGraphSuperfluidUrl = exports.getTheGraphSuperfluidClient = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const graphql_request_1 = require("graphql-request");
|
|
6
6
|
const graphql_superfluid_1 = require("./generated/graphql-superfluid");
|
|
7
7
|
const BASE_URL = `https://subgraph-endpoints.superfluid.dev`;
|
|
8
8
|
const NETWORK_TO_URL = {
|
|
9
|
-
|
|
9
|
+
'arbitrum-one': 'arbitrum-one',
|
|
10
10
|
avalanche: 'avalanche-c',
|
|
11
|
+
base: 'base-mainnet',
|
|
12
|
+
bsc: 'bsc-mainnet',
|
|
13
|
+
celo: 'celo-mainnet',
|
|
14
|
+
mainnet: 'eth-mainnet',
|
|
15
|
+
matic: 'polygon-mainnet',
|
|
16
|
+
optimism: 'optimism-mainnet',
|
|
17
|
+
sepolia: 'eth-sepolia',
|
|
18
|
+
xdai: 'xdai-mainnet',
|
|
11
19
|
};
|
|
12
20
|
const getTheGraphSuperfluidClient = (network, options) => {
|
|
13
21
|
const _a = options !== null && options !== void 0 ? options : {}, { baseUrl: _baseUrl } = _a, clientOptions = tslib_1.__rest(_a, ["baseUrl"]);
|
|
14
|
-
const
|
|
22
|
+
const url = (0, exports.buildTheGraphSuperfluidUrl)(_baseUrl, network);
|
|
23
|
+
return (0, graphql_superfluid_1.getSdk)(new graphql_request_1.GraphQLClient(url, clientOptions));
|
|
24
|
+
};
|
|
25
|
+
exports.getTheGraphSuperfluidClient = getTheGraphSuperfluidClient;
|
|
26
|
+
const buildTheGraphSuperfluidUrl = (baseUrl, network) => {
|
|
15
27
|
// Note: it is also possible to use the IPFS hash of the subgraph
|
|
16
28
|
// eg. /subgraphs/id/QmcCaSkefrmhe4xQj6Y6BBbHiFkbrn6UGDEBUWER7nt399
|
|
17
29
|
// which is a better security but would require an update of the
|
|
18
30
|
// library each time the subgraph is updated, which isn't ideal
|
|
19
31
|
// for early testing.
|
|
20
|
-
|
|
21
|
-
|
|
32
|
+
return network === 'private'
|
|
33
|
+
? 'http://localhost:8000/subgraphs/name/superfluid-finance/protocol-v1-goerli'
|
|
34
|
+
: `${baseUrl || BASE_URL}/${NETWORK_TO_URL[network]}/protocol-v1`;
|
|
22
35
|
};
|
|
23
|
-
exports.
|
|
36
|
+
exports.buildTheGraphSuperfluidUrl = buildTheGraphSuperfluidUrl;
|
|
24
37
|
//# sourceMappingURL=superfluid.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"superfluid.js","sourceRoot":"","sources":["../../src/thegraph/superfluid.ts"],"names":[],"mappings":";;;;AAAA,qDAAgD;AAChD,uEAAwD;AAGxD,MAAM,QAAQ,GAAG,2CAA2C,CAAC;AAC7D,MAAM,cAAc,GAA2B;IAC7C,QAAQ,EAAE,kBAAkB;IAC5B,
|
|
1
|
+
{"version":3,"file":"superfluid.js","sourceRoot":"","sources":["../../src/thegraph/superfluid.ts"],"names":[],"mappings":";;;;AAAA,qDAAgD;AAChD,uEAAwD;AAGxD,MAAM,QAAQ,GAAG,2CAA2C,CAAC;AAC7D,MAAM,cAAc,GAA2B;IAC7C,cAAc,EAAE,cAAc;IAC9B,SAAS,EAAE,aAAa;IACxB,IAAI,EAAE,cAAc;IACpB,GAAG,EAAE,aAAa;IAClB,IAAI,EAAE,cAAc;IACpB,OAAO,EAAE,aAAa;IACtB,KAAK,EAAE,iBAAiB;IACxB,QAAQ,EAAE,kBAAkB;IAC5B,OAAO,EAAE,aAAa;IACtB,IAAI,EAAE,cAAc;CACrB,CAAC;AAaK,MAAM,2BAA2B,GAAG,CACzC,OAAe,EACf,OAA+B,EACL,EAAE;IAC5B,MAAM,KAA0C,OAAO,aAAP,OAAO,cAAP,OAAO,GAAI,EAAE,EAAvD,EAAE,OAAO,EAAE,QAAQ,OAAoC,EAA/B,aAAa,sBAArC,WAAuC,CAAgB,CAAC;IAC9D,MAAM,GAAG,GAAG,IAAA,kCAA0B,EAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;IAC1D,OAAO,IAAA,2BAAM,EAAC,IAAI,+BAAa,CAAC,GAAG,EAAE,aAAa,CAAC,CAAC,CAAC;AACvD,CAAC,CAAC;AAPW,QAAA,2BAA2B,+BAOtC;AAEK,MAAM,0BAA0B,GAAG,CACxC,OAA2B,EAC3B,OAAe,EACP,EAAE;IACV,iEAAiE;IACjE,oEAAoE;IACpE,iEAAiE;IACjE,gEAAgE;IAChE,sBAAsB;IACtB,OAAO,OAAO,KAAK,SAAS;QAC1B,CAAC,CAAC,4EAA4E;QAC9E,CAAC,CAAC,GAAG,OAAO,IAAI,QAAQ,IAAI,cAAc,CAAC,OAAO,CAAC,cAAc,CAAC;AACtE,CAAC,CAAC;AAZW,QAAA,0BAA0B,8BAYrC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@requestnetwork/payment-detection",
|
|
3
|
-
"version": "0.43.1-next.
|
|
3
|
+
"version": "0.43.1-next.2047+bd453887",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
"codegen": "graphql-codegen --config codegen.yml ; graphql-codegen --config codegen-superfluid.yml; graphql-codegen --config codegen-near.yml"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@requestnetwork/currency": "0.16.1-next.
|
|
45
|
-
"@requestnetwork/smart-contracts": "0.36.1-next.
|
|
46
|
-
"@requestnetwork/types": "0.43.1-next.
|
|
47
|
-
"@requestnetwork/utils": "0.43.1-next.
|
|
44
|
+
"@requestnetwork/currency": "0.16.1-next.2047+bd453887",
|
|
45
|
+
"@requestnetwork/smart-contracts": "0.36.1-next.2047+bd453887",
|
|
46
|
+
"@requestnetwork/types": "0.43.1-next.2047+bd453887",
|
|
47
|
+
"@requestnetwork/utils": "0.43.1-next.2047+bd453887",
|
|
48
48
|
"ethers": "5.5.1",
|
|
49
49
|
"graphql": "16.8.1",
|
|
50
50
|
"graphql-request": "6.1.0",
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
"@graphql-codegen/typescript-operations": "4.0.1",
|
|
62
62
|
"@graphql-codegen/typescript-resolvers": "4.0.1",
|
|
63
63
|
"@jridgewell/gen-mapping": "0.3.2",
|
|
64
|
-
"@requestnetwork/advanced-logic": "0.42.1-next.
|
|
64
|
+
"@requestnetwork/advanced-logic": "0.42.1-next.2047+bd453887",
|
|
65
65
|
"@types/jest": "29.5.6",
|
|
66
66
|
"jest": "29.5.0",
|
|
67
67
|
"jest-junit": "16.0.0",
|
|
@@ -70,5 +70,5 @@
|
|
|
70
70
|
"ts-node": "10.9.1",
|
|
71
71
|
"typescript": "5.1.3"
|
|
72
72
|
},
|
|
73
|
-
"gitHead": "
|
|
73
|
+
"gitHead": "bd45388730be3a9d9f49854b40b09c53ebd812d8"
|
|
74
74
|
}
|