@human-protocol/sdk 1.1.10 → 1.1.11
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.
- package/dist/constants.js +8 -8
- package/dist/escrow.d.ts +12 -12
- package/dist/escrow.d.ts.map +1 -1
- package/dist/escrow.js +42 -30
- package/dist/graphql/queries/escrow.d.ts +2 -2
- package/dist/graphql/queries/escrow.d.ts.map +1 -1
- package/dist/graphql/queries/escrow.js +30 -26
- package/dist/graphql/queries/hmtoken.d.ts +2 -0
- package/dist/graphql/queries/hmtoken.d.ts.map +1 -0
- package/dist/graphql/queries/hmtoken.js +21 -0
- package/dist/graphql/queries/index.d.ts +2 -0
- package/dist/graphql/queries/index.d.ts.map +1 -1
- package/dist/graphql/queries/index.js +2 -0
- package/dist/graphql/queries/statistics.d.ts +5 -0
- package/dist/graphql/queries/statistics.d.ts.map +1 -0
- package/dist/graphql/queries/statistics.js +87 -0
- package/dist/graphql/types.d.ts +91 -0
- package/dist/graphql/types.d.ts.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -1
- package/dist/interfaces.d.ts +9 -3
- package/dist/interfaces.d.ts.map +1 -1
- package/dist/statistics.d.ts +45 -0
- package/dist/statistics.d.ts.map +1 -0
- package/dist/statistics.js +144 -0
- package/dist/storage.d.ts +2 -2
- package/dist/storage.d.ts.map +1 -1
- package/dist/storage.js +4 -4
- package/package.json +1 -1
- package/src/constants.ts +8 -8
- package/src/escrow.ts +51 -36
- package/src/graphql/queries/escrow.ts +31 -25
- package/src/graphql/queries/hmtoken.ts +17 -0
- package/src/graphql/queries/index.ts +2 -0
- package/src/graphql/queries/statistics.ts +88 -0
- package/src/graphql/types.ts +105 -0
- package/src/index.ts +8 -1
- package/src/interfaces.ts +16 -3
- package/src/statistics.ts +196 -0
- package/src/storage.ts +4 -4
package/dist/constants.js
CHANGED
|
@@ -53,7 +53,7 @@ exports.NETWORKS = {
|
|
|
53
53
|
stakingAddress: '0x05398211bA2046E296fBc9a9D3EB49e3F15C3123',
|
|
54
54
|
rewardPoolAddress: '0x4A5963Dd6792692e9147EdC7659936b96251917a',
|
|
55
55
|
kvstoreAddress: '0x70671167176C4934204B1C7e97F5e86695857ef2',
|
|
56
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/mainnet-
|
|
56
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/mainnet-v2',
|
|
57
57
|
oldSubgraphUrl: '',
|
|
58
58
|
oldFactoryAddress: '',
|
|
59
59
|
},
|
|
@@ -79,7 +79,7 @@ exports.NETWORKS = {
|
|
|
79
79
|
stakingAddress: '0xf46B45Df3d956369726d8Bd93Ba33963Ab692920',
|
|
80
80
|
rewardPoolAddress: '0x0376D26246Eb35FF4F9924cF13E6C05fd0bD7Fb4',
|
|
81
81
|
kvstoreAddress: '0xc9Fe39c4b6e1d7A2991355Af159956982DADf842',
|
|
82
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/goerli-
|
|
82
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/goerli-v2',
|
|
83
83
|
oldSubgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/goerli',
|
|
84
84
|
oldFactoryAddress: '0xaAe6a2646C1F88763E62e0cD08aD050Ea66AC46F',
|
|
85
85
|
},
|
|
@@ -92,7 +92,7 @@ exports.NETWORKS = {
|
|
|
92
92
|
stakingAddress: '0xdFbB79dC35a3A53741be54a2C9b587d6BafAbd1C',
|
|
93
93
|
rewardPoolAddress: '0xf376443BCc6d4d4D63eeC086bc4A9E4a83878e0e',
|
|
94
94
|
kvstoreAddress: '0x2B95bEcb6EBC4589f64CB000dFCF716b4aeF8aA6',
|
|
95
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/bsc-
|
|
95
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/bsc-v2',
|
|
96
96
|
oldSubgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/bsc',
|
|
97
97
|
oldFactoryAddress: '0xc88bC422cAAb2ac8812de03176402dbcA09533f4',
|
|
98
98
|
},
|
|
@@ -105,7 +105,7 @@ exports.NETWORKS = {
|
|
|
105
105
|
stakingAddress: '0x5517fE916Fe9F8dB15B0DDc76ebDf0BdDCd4ed18',
|
|
106
106
|
rewardPoolAddress: '0xB0A0500103eCEc431b73F6BAd923F0a2774E6e29',
|
|
107
107
|
kvstoreAddress: '0x3aD4B091E054f192a822D1406f4535eAd38580e4',
|
|
108
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/bsctest-
|
|
108
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/bsctest-v2',
|
|
109
109
|
oldSubgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/bsctest',
|
|
110
110
|
oldFactoryAddress: '0xaae6a2646c1f88763e62e0cd08ad050ea66ac46f',
|
|
111
111
|
},
|
|
@@ -118,7 +118,7 @@ exports.NETWORKS = {
|
|
|
118
118
|
stakingAddress: '0xcbAd56bE3f504E98bd70875823d3CC0242B7bB29',
|
|
119
119
|
rewardPoolAddress: '0xa8e32d777a3839440cc7c24D591A64B9481753B3',
|
|
120
120
|
kvstoreAddress: '0x35Cf4beBD58F9C8D75B9eA2599479b6C173d406F',
|
|
121
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/polygon-
|
|
121
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/polygon-v2',
|
|
122
122
|
oldSubgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/polygon',
|
|
123
123
|
oldFactoryAddress: '0x45eBc3eAE6DA485097054ae10BA1A0f8e8c7f794',
|
|
124
124
|
},
|
|
@@ -131,7 +131,7 @@ exports.NETWORKS = {
|
|
|
131
131
|
stakingAddress: '0x7Fd3dF914E7b6Bd96B4c744Df32183b51368Bfac',
|
|
132
132
|
rewardPoolAddress: '0xf0145eD99AC3c4f877aDa7dA4D1E059ec9116BAE',
|
|
133
133
|
kvstoreAddress: '0xD7F61E812e139a5a02eDae9Dfec146E1b8eA3807',
|
|
134
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/mumbai-
|
|
134
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/mumbai-v2',
|
|
135
135
|
oldSubgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/mumbai',
|
|
136
136
|
oldFactoryAddress: '0x558cd800f9F0B02f3B149667bDe003284c867E94',
|
|
137
137
|
},
|
|
@@ -144,7 +144,7 @@ exports.NETWORKS = {
|
|
|
144
144
|
stakingAddress: '0x05398211bA2046E296fBc9a9D3EB49e3F15C3123',
|
|
145
145
|
rewardPoolAddress: '0x4A5963Dd6792692e9147EdC7659936b96251917a',
|
|
146
146
|
kvstoreAddress: '0x70671167176C4934204B1C7e97F5e86695857ef2',
|
|
147
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/moonbeam-
|
|
147
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/moonbeam-v2',
|
|
148
148
|
oldSubgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/moonbeam',
|
|
149
149
|
oldFactoryAddress: '0x98108c28B7767a52BE38B4860832dd4e11A7ecad',
|
|
150
150
|
},
|
|
@@ -157,7 +157,7 @@ exports.NETWORKS = {
|
|
|
157
157
|
stakingAddress: '0xBFC7009F3371F93F3B54DdC8caCd02914a37495c',
|
|
158
158
|
rewardPoolAddress: '0xf46B45Df3d956369726d8Bd93Ba33963Ab692920',
|
|
159
159
|
kvstoreAddress: '0xE3D74BBFa45B4bCa69FF28891fBE392f4B4d4e4d',
|
|
160
|
-
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/moonbase-alpha-
|
|
160
|
+
subgraphUrl: 'https://api.thegraph.com/subgraphs/name/humanprotocol/moonbase-alpha-v2',
|
|
161
161
|
oldSubgraphUrl: '',
|
|
162
162
|
oldFactoryAddress: '',
|
|
163
163
|
},
|
package/dist/escrow.d.ts
CHANGED
|
@@ -32,7 +32,7 @@ export declare class EscrowClient {
|
|
|
32
32
|
* @returns {Promise<string>} - Return the address of the escrow created.
|
|
33
33
|
* @throws {Error} - An error object if an error occurred.
|
|
34
34
|
*/
|
|
35
|
-
createEscrow(tokenAddress: string, trustedHandlers: string[]): Promise<string>;
|
|
35
|
+
createEscrow(tokenAddress: string, trustedHandlers: string[], jobRequesterId: string): Promise<string>;
|
|
36
36
|
/**
|
|
37
37
|
* Sets up the parameters of the escrow.
|
|
38
38
|
*
|
|
@@ -52,7 +52,7 @@ export declare class EscrowClient {
|
|
|
52
52
|
* @returns {Promise<string>}
|
|
53
53
|
* @throws {Error} - An error object if an error occurred.
|
|
54
54
|
*/
|
|
55
|
-
createAndSetupEscrow(tokenAddress: string, trustedHandlers: string[], escrowConfig: IEscrowConfig): Promise<string>;
|
|
55
|
+
createAndSetupEscrow(tokenAddress: string, trustedHandlers: string[], jobRequesterId: string, escrowConfig: IEscrowConfig): Promise<string>;
|
|
56
56
|
/**
|
|
57
57
|
* **Adds funds of the chosen token to the escrow.*
|
|
58
58
|
*
|
|
@@ -126,6 +126,14 @@ export declare class EscrowClient {
|
|
|
126
126
|
* @throws {Error} - An error object if an error occurred.
|
|
127
127
|
*/
|
|
128
128
|
getBalance(escrowAddress: string): Promise<BigNumber>;
|
|
129
|
+
/**
|
|
130
|
+
* Returns the manifest file hash.
|
|
131
|
+
*
|
|
132
|
+
* @param {string} escrowAddress - Address of the escrow.
|
|
133
|
+
* @returns {Promise<void>}
|
|
134
|
+
* @throws {Error} - An error object if an error occurred.
|
|
135
|
+
*/
|
|
136
|
+
getManifestHash(escrowAddress: string): Promise<string>;
|
|
129
137
|
/**
|
|
130
138
|
* Returns the manifest file URL.
|
|
131
139
|
*
|
|
@@ -167,21 +175,13 @@ export declare class EscrowClient {
|
|
|
167
175
|
*/
|
|
168
176
|
getStatus(escrowAddress: string): Promise<EscrowStatus>;
|
|
169
177
|
/**
|
|
170
|
-
* Returns the
|
|
171
|
-
*
|
|
172
|
-
* @param {IEscrowsFilter} requesterAddress - Address of the requester.
|
|
173
|
-
* @returns {Promise<string[]>}
|
|
174
|
-
* @throws {Error} - An error object if an error occurred.
|
|
175
|
-
*/
|
|
176
|
-
getLaunchedEscrows(launcherAddress: string): Promise<EscrowData[]>;
|
|
177
|
-
/**
|
|
178
|
-
* Returns the escrow addresses based on a specified filter.
|
|
178
|
+
* Returns the list of escrows for given filter
|
|
179
179
|
*
|
|
180
180
|
* @param {IEscrowsFilter} filter - Filter parameters.
|
|
181
181
|
* @returns {Promise<EscrowData[]>}
|
|
182
182
|
* @throws {Error} - An error object if an error occurred.
|
|
183
183
|
*/
|
|
184
|
-
|
|
184
|
+
getEscrows(filter?: IEscrowsFilter): Promise<EscrowData[]>;
|
|
185
185
|
/**
|
|
186
186
|
* Returns the recording oracle address of given escrow
|
|
187
187
|
*
|
package/dist/escrow.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"escrow.d.ts","sourceRoot":"","sources":["../src/escrow.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AAU5D,OAAO,EAAE,SAAS,EAAmB,MAAM,EAAU,MAAM,QAAQ,CAAC;AA2BpE,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC7D,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAEpD,OAAO,
|
|
1
|
+
{"version":3,"file":"escrow.d.ts","sourceRoot":"","sources":["../src/escrow.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AAU5D,OAAO,EAAE,SAAS,EAAmB,MAAM,EAAU,MAAM,QA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BAAyB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAoBvE;;;;;;OAMG;IACG,qBAAqB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAoBnE;;;;;;OAMG;IACG,0BAA0B,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAoBxE;;;;;;OAMG;IACG,iBAAiB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;CAmBhE"}
|
package/dist/escrow.js
CHANGED
|
@@ -67,7 +67,7 @@ class EscrowClient {
|
|
|
67
67
|
* @returns {Promise<string>} - Return the address of the escrow created.
|
|
68
68
|
* @throws {Error} - An error object if an error occurred.
|
|
69
69
|
*/
|
|
70
|
-
async createEscrow(tokenAddress, trustedHandlers) {
|
|
70
|
+
async createEscrow(tokenAddress, trustedHandlers, jobRequesterId) {
|
|
71
71
|
if (!ethers_1.ethers.utils.isAddress(tokenAddress)) {
|
|
72
72
|
throw error_1.ErrorInvalidTokenAddress;
|
|
73
73
|
}
|
|
@@ -77,8 +77,8 @@ class EscrowClient {
|
|
|
77
77
|
}
|
|
78
78
|
});
|
|
79
79
|
try {
|
|
80
|
-
const result = await (await this.escrowFactoryContract.createEscrow(tokenAddress, trustedHandlers)).wait();
|
|
81
|
-
const event = result.events?.find(({ topics }) => topics.includes(ethers_1.ethers.utils.id('
|
|
80
|
+
const result = await (await this.escrowFactoryContract.createEscrow(tokenAddress, trustedHandlers, jobRequesterId)).wait();
|
|
81
|
+
const event = result.events?.find(({ topics }) => topics.includes(ethers_1.ethers.utils.id('LaunchedV2(address,address,string)')))?.args;
|
|
82
82
|
if (!event) {
|
|
83
83
|
throw error_1.ErrorLaunchedEventIsNotEmitted;
|
|
84
84
|
}
|
|
@@ -144,9 +144,9 @@ class EscrowClient {
|
|
|
144
144
|
* @returns {Promise<string>}
|
|
145
145
|
* @throws {Error} - An error object if an error occurred.
|
|
146
146
|
*/
|
|
147
|
-
async createAndSetupEscrow(tokenAddress, trustedHandlers, escrowConfig) {
|
|
147
|
+
async createAndSetupEscrow(tokenAddress, trustedHandlers, jobRequesterId, escrowConfig) {
|
|
148
148
|
try {
|
|
149
|
-
const escrowAddress = await this.createEscrow(tokenAddress, trustedHandlers);
|
|
149
|
+
const escrowAddress = await this.createEscrow(tokenAddress, trustedHandlers, jobRequesterId);
|
|
150
150
|
await this.setup(escrowAddress, escrowConfig);
|
|
151
151
|
return escrowAddress;
|
|
152
152
|
}
|
|
@@ -399,6 +399,28 @@ class EscrowClient {
|
|
|
399
399
|
return (0, utils_1.throwError)(e);
|
|
400
400
|
}
|
|
401
401
|
}
|
|
402
|
+
/**
|
|
403
|
+
* Returns the manifest file hash.
|
|
404
|
+
*
|
|
405
|
+
* @param {string} escrowAddress - Address of the escrow.
|
|
406
|
+
* @returns {Promise<void>}
|
|
407
|
+
* @throws {Error} - An error object if an error occurred.
|
|
408
|
+
*/
|
|
409
|
+
async getManifestHash(escrowAddress) {
|
|
410
|
+
if (!ethers_1.ethers.utils.isAddress(escrowAddress)) {
|
|
411
|
+
throw error_1.ErrorInvalidEscrowAddressProvided;
|
|
412
|
+
}
|
|
413
|
+
if (!(await this.escrowFactoryContract.hasEscrow(escrowAddress))) {
|
|
414
|
+
throw error_1.ErrorEscrowAddressIsNotProvidedByFactory;
|
|
415
|
+
}
|
|
416
|
+
try {
|
|
417
|
+
this.escrowContract = typechain_types_1.Escrow__factory.connect(escrowAddress, this.signerOrProvider);
|
|
418
|
+
return this.escrowContract.manifestHash();
|
|
419
|
+
}
|
|
420
|
+
catch (e) {
|
|
421
|
+
return (0, utils_1.throwError)(e);
|
|
422
|
+
}
|
|
423
|
+
}
|
|
402
424
|
/**
|
|
403
425
|
* Returns the manifest file URL.
|
|
404
426
|
*
|
|
@@ -510,39 +532,29 @@ class EscrowClient {
|
|
|
510
532
|
}
|
|
511
533
|
}
|
|
512
534
|
/**
|
|
513
|
-
* Returns the
|
|
535
|
+
* Returns the list of escrows for given filter
|
|
514
536
|
*
|
|
515
|
-
* @param {IEscrowsFilter}
|
|
516
|
-
* @returns {Promise<
|
|
537
|
+
* @param {IEscrowsFilter} filter - Filter parameters.
|
|
538
|
+
* @returns {Promise<EscrowData[]>}
|
|
517
539
|
* @throws {Error} - An error object if an error occurred.
|
|
518
540
|
*/
|
|
519
|
-
async
|
|
520
|
-
if (!ethers_1.ethers.utils.isAddress(
|
|
541
|
+
async getEscrows(filter = {}) {
|
|
542
|
+
if (filter.launcher && !ethers_1.ethers.utils.isAddress(filter.launcher)) {
|
|
521
543
|
throw error_1.ErrorInvalidAddress;
|
|
522
544
|
}
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
}
|
|
527
|
-
catch (e) {
|
|
528
|
-
return (0, utils_1.throwError)(e);
|
|
545
|
+
if (filter.recordingOracle &&
|
|
546
|
+
!ethers_1.ethers.utils.isAddress(filter.recordingOracle)) {
|
|
547
|
+
throw error_1.ErrorInvalidAddress;
|
|
529
548
|
}
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
* Returns the escrow addresses based on a specified filter.
|
|
533
|
-
*
|
|
534
|
-
* @param {IEscrowsFilter} filter - Filter parameters.
|
|
535
|
-
* @returns {Promise<EscrowData[]>}
|
|
536
|
-
* @throws {Error} - An error object if an error occurred.
|
|
537
|
-
*/
|
|
538
|
-
async getEscrowsFiltered(filter) {
|
|
539
|
-
if (filter?.launcherAddress &&
|
|
540
|
-
!ethers_1.ethers.utils.isAddress(filter?.launcherAddress)) {
|
|
549
|
+
if (filter.reputationOracle &&
|
|
550
|
+
!ethers_1.ethers.utils.isAddress(filter.reputationOracle)) {
|
|
541
551
|
throw error_1.ErrorInvalidAddress;
|
|
542
552
|
}
|
|
543
553
|
try {
|
|
544
|
-
const { escrows } = await (0, graphql_request_1.default)(this.network.subgraphUrl, graphql_1.
|
|
554
|
+
const { escrows } = await (0, graphql_request_1.default)(this.network.subgraphUrl, (0, graphql_1.GET_ESCROWS_QUERY)(filter), {
|
|
545
555
|
...filter,
|
|
556
|
+
from: filter.from ? +filter.from.getTime() / 1000 : undefined,
|
|
557
|
+
to: filter.to ? +filter.to.getTime() / 1000 : undefined,
|
|
546
558
|
});
|
|
547
559
|
return escrows;
|
|
548
560
|
}
|
|
@@ -642,7 +654,7 @@ class EscrowClient {
|
|
|
642
654
|
__decorate([
|
|
643
655
|
decorators_1.requiresSigner,
|
|
644
656
|
__metadata("design:type", Function),
|
|
645
|
-
__metadata("design:paramtypes", [String, Array]),
|
|
657
|
+
__metadata("design:paramtypes", [String, Array, String]),
|
|
646
658
|
__metadata("design:returntype", Promise)
|
|
647
659
|
], EscrowClient.prototype, "createEscrow", null);
|
|
648
660
|
__decorate([
|
|
@@ -654,7 +666,7 @@ __decorate([
|
|
|
654
666
|
__decorate([
|
|
655
667
|
decorators_1.requiresSigner,
|
|
656
668
|
__metadata("design:type", Function),
|
|
657
|
-
__metadata("design:paramtypes", [String, Array, Object]),
|
|
669
|
+
__metadata("design:paramtypes", [String, Array, String, Object]),
|
|
658
670
|
__metadata("design:returntype", Promise)
|
|
659
671
|
], EscrowClient.prototype, "createAndSetupEscrow", null);
|
|
660
672
|
__decorate([
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
export declare const
|
|
1
|
+
import { IEscrowsFilter } from '../../interfaces';
|
|
2
|
+
export declare const GET_ESCROWS_QUERY: (filter: IEscrowsFilter) => import("graphql").DocumentNode;
|
|
3
3
|
//# sourceMappingURL=escrow.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"escrow.d.ts","sourceRoot":"","sources":["../../../src/graphql/queries/escrow.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"escrow.d.ts","sourceRoot":"","sources":["../../../src/graphql/queries/escrow.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AA0BlD,eAAO,MAAM,iBAAiB,WAAY,cAAc,mCAgCvD,CAAC"}
|
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.
|
|
6
|
+
exports.GET_ESCROWS_QUERY = void 0;
|
|
7
7
|
const graphql_tag_1 = __importDefault(require("graphql-tag"));
|
|
8
8
|
const ESCROW_FRAGMENT = (0, graphql_tag_1.default) `
|
|
9
9
|
fragment EscrowFields on Escrow {
|
|
@@ -25,33 +25,37 @@ const ESCROW_FRAGMENT = (0, graphql_tag_1.default) `
|
|
|
25
25
|
status
|
|
26
26
|
token
|
|
27
27
|
totalFundedAmount
|
|
28
|
+
createdAt
|
|
28
29
|
}
|
|
29
30
|
`;
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
31
|
+
const GET_ESCROWS_QUERY = (filter) => {
|
|
32
|
+
const { launcher, reputationOracle, recordingOracle, status, from, to } = filter;
|
|
33
|
+
const WHERE_CLAUSE = `
|
|
34
|
+
where: {
|
|
35
|
+
${launcher ? `launcher: $launcher` : ''}
|
|
36
|
+
${reputationOracle ? `reputationOracle: $reputationOracle` : ''}
|
|
37
|
+
${recordingOracle ? `recordingOracle: $recordingOracle` : ''}
|
|
38
|
+
${status ? `status: $status` : ''}
|
|
39
|
+
${from ? `createdAt_gte: $from` : ''}
|
|
40
|
+
${to ? `createdAt_lte: $to` : ''}
|
|
34
41
|
}
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
) {
|
|
45
|
-
escrows(
|
|
46
|
-
where: {
|
|
47
|
-
launcher: $launcherAddress
|
|
48
|
-
status: $status
|
|
49
|
-
createdAt_gte: $from
|
|
50
|
-
createdAt_lte: $to
|
|
51
|
-
}
|
|
42
|
+
`;
|
|
43
|
+
return (0, graphql_tag_1.default) `
|
|
44
|
+
query getEscrows(
|
|
45
|
+
$launcher: String
|
|
46
|
+
$reputationOracle: String
|
|
47
|
+
$recordingOracle: String
|
|
48
|
+
$status: String
|
|
49
|
+
$from: Int
|
|
50
|
+
$to: Int
|
|
52
51
|
) {
|
|
53
|
-
|
|
52
|
+
escrows(
|
|
53
|
+
${WHERE_CLAUSE}
|
|
54
|
+
) {
|
|
55
|
+
...EscrowFields
|
|
56
|
+
}
|
|
54
57
|
}
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
+
${ESCROW_FRAGMENT}
|
|
59
|
+
`;
|
|
60
|
+
};
|
|
61
|
+
exports.GET_ESCROWS_QUERY = GET_ESCROWS_QUERY;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hmtoken.d.ts","sourceRoot":"","sources":["../../../src/graphql/queries/hmtoken.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,iBAAiB,gCAO7B,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.GET_HOLDERS_QUERY = void 0;
|
|
7
|
+
const graphql_tag_1 = __importDefault(require("graphql-tag"));
|
|
8
|
+
const HOLDER_FRAGMENT = (0, graphql_tag_1.default) `
|
|
9
|
+
fragment HolderFields on Holder {
|
|
10
|
+
address
|
|
11
|
+
balance
|
|
12
|
+
}
|
|
13
|
+
`;
|
|
14
|
+
exports.GET_HOLDERS_QUERY = (0, graphql_tag_1.default) `
|
|
15
|
+
query GetHolders {
|
|
16
|
+
holders {
|
|
17
|
+
...HolderFields
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
${HOLDER_FRAGMENT}
|
|
21
|
+
`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/graphql/queries/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/graphql/queries/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC"}
|
|
@@ -15,4 +15,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./escrow"), exports);
|
|
18
|
+
__exportStar(require("./hmtoken"), exports);
|
|
18
19
|
__exportStar(require("./reward"), exports);
|
|
20
|
+
__exportStar(require("./statistics"), exports);
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { IStatisticsParams } from '../../interfaces';
|
|
2
|
+
export declare const GET_HMTOKEN_STATISTICS_QUERY: import("graphql").DocumentNode;
|
|
3
|
+
export declare const GET_ESCROW_STATISTICS_QUERY: import("graphql").DocumentNode;
|
|
4
|
+
export declare const GET_EVENT_DAY_DATA_QUERY: (params: IStatisticsParams) => import("graphql").DocumentNode;
|
|
5
|
+
//# sourceMappingURL=statistics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"statistics.d.ts","sourceRoot":"","sources":["../../../src/graphql/queries/statistics.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAmDrD,eAAO,MAAM,4BAA4B,gCAOxC,CAAC;AAEF,eAAO,MAAM,2BAA2B,gCAOvC,CAAC;AAEF,eAAO,MAAM,wBAAwB,WAAY,iBAAiB,mCAiBjE,CAAC"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.GET_EVENT_DAY_DATA_QUERY = exports.GET_ESCROW_STATISTICS_QUERY = exports.GET_HMTOKEN_STATISTICS_QUERY = void 0;
|
|
7
|
+
const graphql_tag_1 = __importDefault(require("graphql-tag"));
|
|
8
|
+
const HMTOKEN_STATISTICS_FRAGMENT = (0, graphql_tag_1.default) `
|
|
9
|
+
fragment HMTokenStatisticsFields on HMTokenStatistics {
|
|
10
|
+
totalTransferEventCount
|
|
11
|
+
totalBulkTransferEventCount
|
|
12
|
+
totalApprovalEventCount
|
|
13
|
+
totalBulkApprovalEventCount
|
|
14
|
+
totalValueTransfered
|
|
15
|
+
holders
|
|
16
|
+
}
|
|
17
|
+
`;
|
|
18
|
+
const ESCROW_STATISTICS_FRAGMENT = (0, graphql_tag_1.default) `
|
|
19
|
+
fragment EscrowStatisticsFields on EscrowStatistics {
|
|
20
|
+
fundEventCount
|
|
21
|
+
setupEventCount
|
|
22
|
+
storeResultsEventCount
|
|
23
|
+
bulkPayoutEventCount
|
|
24
|
+
pendingStatusEventCount
|
|
25
|
+
cancelledStatusEventCount
|
|
26
|
+
partialStatusEventCount
|
|
27
|
+
paidStatusEventCount
|
|
28
|
+
completedStatusEventCount
|
|
29
|
+
totalEventCount
|
|
30
|
+
totalEscrowCount
|
|
31
|
+
}
|
|
32
|
+
`;
|
|
33
|
+
const EVENT_DAY_DATA_FRAGMENT = (0, graphql_tag_1.default) `
|
|
34
|
+
fragment EventDayDataFields on EventDayData {
|
|
35
|
+
timestamp
|
|
36
|
+
dailyFundEventCount
|
|
37
|
+
dailySetupEventCount
|
|
38
|
+
dailyStoreResultsEventCount
|
|
39
|
+
dailyBulkPayoutEventCount
|
|
40
|
+
dailyPendingStatusEventCount
|
|
41
|
+
dailyCancelledStatusEventCount
|
|
42
|
+
dailyPartialStatusEventCount
|
|
43
|
+
dailyPaidStatusEventCount
|
|
44
|
+
dailyCompletedStatusEventCount
|
|
45
|
+
dailyTotalEventCount
|
|
46
|
+
dailyEscrowCount
|
|
47
|
+
dailyWorkerCount
|
|
48
|
+
dailyPayoutCount
|
|
49
|
+
dailyPayoutAmount
|
|
50
|
+
dailyHMTTransferCount
|
|
51
|
+
dailyHMTTransferAmount
|
|
52
|
+
}
|
|
53
|
+
`;
|
|
54
|
+
exports.GET_HMTOKEN_STATISTICS_QUERY = (0, graphql_tag_1.default) `
|
|
55
|
+
query GetHMTokenStatistics {
|
|
56
|
+
hmtokenStatistics(id: "hmt-statistics-id") {
|
|
57
|
+
...HMTokenStatisticsFields
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
${HMTOKEN_STATISTICS_FRAGMENT}
|
|
61
|
+
`;
|
|
62
|
+
exports.GET_ESCROW_STATISTICS_QUERY = (0, graphql_tag_1.default) `
|
|
63
|
+
query GetEscrowStatistics {
|
|
64
|
+
escrowStatistics(id: "escrow-statistics-id") {
|
|
65
|
+
...EscrowStatisticsFields
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
${ESCROW_STATISTICS_FRAGMENT}
|
|
69
|
+
`;
|
|
70
|
+
const GET_EVENT_DAY_DATA_QUERY = (params) => {
|
|
71
|
+
const { from, to } = params;
|
|
72
|
+
const WHERE_CLAUSE = `
|
|
73
|
+
where: {
|
|
74
|
+
${from !== undefined ? `timestamp_gte: $from` : ''}
|
|
75
|
+
${to !== undefined ? `timestamp_lte: $to` : ''}
|
|
76
|
+
}
|
|
77
|
+
`;
|
|
78
|
+
return (0, graphql_tag_1.default) `
|
|
79
|
+
query GetEscrowDayData($from: Int, $to: Int) {
|
|
80
|
+
eventDayDatas(${WHERE_CLAUSE}) {
|
|
81
|
+
...EventDayDataFields
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
${EVENT_DAY_DATA_FRAGMENT}
|
|
85
|
+
`;
|
|
86
|
+
};
|
|
87
|
+
exports.GET_EVENT_DAY_DATA_QUERY = GET_EVENT_DAY_DATA_QUERY;
|
package/dist/graphql/types.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { BigNumber } from 'ethers';
|
|
1
2
|
export type EscrowData = {
|
|
2
3
|
id: string;
|
|
3
4
|
address: string;
|
|
@@ -17,6 +18,47 @@ export type EscrowData = {
|
|
|
17
18
|
status: string;
|
|
18
19
|
token: string;
|
|
19
20
|
totalFundedAmount: string;
|
|
21
|
+
createdAt: string;
|
|
22
|
+
};
|
|
23
|
+
export type HMTStatisticsData = {
|
|
24
|
+
totalTransferEventCount: string;
|
|
25
|
+
totalBulkTransferEventCount: string;
|
|
26
|
+
totalApprovalEventCount: string;
|
|
27
|
+
totalBulkApprovalEventCount: string;
|
|
28
|
+
totalValueTransfered: string;
|
|
29
|
+
holders: string;
|
|
30
|
+
};
|
|
31
|
+
export type EscrowStatisticsData = {
|
|
32
|
+
fundEventCount: string;
|
|
33
|
+
setupEventCount: string;
|
|
34
|
+
storeResultsEventCount: string;
|
|
35
|
+
bulkPayoutEventCount: string;
|
|
36
|
+
pendingStatusEventCount: string;
|
|
37
|
+
cancelledStatusEventCount: string;
|
|
38
|
+
partialStatusEventCount: string;
|
|
39
|
+
paidStatusEventCount: string;
|
|
40
|
+
completedStatusEventCount: string;
|
|
41
|
+
totalEventCount: string;
|
|
42
|
+
totalEscrowCount: string;
|
|
43
|
+
};
|
|
44
|
+
export type EventDayData = {
|
|
45
|
+
timestamp: string;
|
|
46
|
+
dailyFundEventCount: string;
|
|
47
|
+
dailySetupEventCount: string;
|
|
48
|
+
dailyStoreResultsEventCount: string;
|
|
49
|
+
dailyBulkPayoutEventCount: string;
|
|
50
|
+
dailyPendingStatusEventCount: string;
|
|
51
|
+
dailyCancelledStatusEventCount: string;
|
|
52
|
+
dailyPartialStatusEventCount: string;
|
|
53
|
+
dailyPaidStatusEventCount: string;
|
|
54
|
+
dailyCompletedStatusEventCount: string;
|
|
55
|
+
dailyTotalEventCount: string;
|
|
56
|
+
dailyEscrowCount: string;
|
|
57
|
+
dailyWorkerCount: string;
|
|
58
|
+
dailyPayoutCount: string;
|
|
59
|
+
dailyPayoutAmount: string;
|
|
60
|
+
dailyHMTTransferCount: string;
|
|
61
|
+
dailyHMTTransferAmount: string;
|
|
20
62
|
};
|
|
21
63
|
export type RewardAddedEventData = {
|
|
22
64
|
escrowAddress: string;
|
|
@@ -24,4 +66,53 @@ export type RewardAddedEventData = {
|
|
|
24
66
|
slasher: string;
|
|
25
67
|
amount: string;
|
|
26
68
|
};
|
|
69
|
+
export type DailyEscrowData = {
|
|
70
|
+
timestamp: Date;
|
|
71
|
+
escrowsTotal: number;
|
|
72
|
+
escrowsPending: number;
|
|
73
|
+
escrowsSolved: number;
|
|
74
|
+
escrowsPaid: number;
|
|
75
|
+
escrowsCancelled: number;
|
|
76
|
+
};
|
|
77
|
+
export type EscrowStatistics = {
|
|
78
|
+
totalEscrows: number;
|
|
79
|
+
dailyEscrowsData: DailyEscrowData[];
|
|
80
|
+
};
|
|
81
|
+
export type DailyWorkerData = {
|
|
82
|
+
timestamp: Date;
|
|
83
|
+
activeWorkers: number;
|
|
84
|
+
averageJobsSolved: number;
|
|
85
|
+
};
|
|
86
|
+
export type WorkerStatistics = {
|
|
87
|
+
dailyWorkersData: DailyWorkerData[];
|
|
88
|
+
};
|
|
89
|
+
export type DailyPaymentData = {
|
|
90
|
+
timestamp: Date;
|
|
91
|
+
totalAmountPaid: BigNumber;
|
|
92
|
+
totalCount: number;
|
|
93
|
+
averageAmountPerJob: BigNumber;
|
|
94
|
+
averageAmountPerWorker: BigNumber;
|
|
95
|
+
};
|
|
96
|
+
export type PaymentStatistics = {
|
|
97
|
+
dailyPaymentsData: DailyPaymentData[];
|
|
98
|
+
};
|
|
99
|
+
export type HMTHolderData = {
|
|
100
|
+
address: string;
|
|
101
|
+
balance: string;
|
|
102
|
+
};
|
|
103
|
+
export type HMTHolder = {
|
|
104
|
+
address: string;
|
|
105
|
+
balance: BigNumber;
|
|
106
|
+
};
|
|
107
|
+
export type DailyHMTData = {
|
|
108
|
+
timestamp: Date;
|
|
109
|
+
totalTransactionAmount: BigNumber;
|
|
110
|
+
totalTransactionCount: number;
|
|
111
|
+
};
|
|
112
|
+
export type HMTStatistics = {
|
|
113
|
+
totalTransferAmount: BigNumber;
|
|
114
|
+
totalHolders: number;
|
|
115
|
+
holders: HMTHolder[];
|
|
116
|
+
dailyHMTData: DailyHMTData[];
|
|
117
|
+
};
|
|
27
118
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/graphql/types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,UAAU,GAAG;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,CAAC;IACvB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,iBAAiB,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/graphql/types.ts"],"names":[],"mappings":"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AC;AAEF,MAAM,MAAM,eAAe,GAAG;IAC5B,SAAS,EAAE,IAAI,CAAC;IAChB,aAAa,EAAE,MAAM,CAAC;IACtB,iBAAiB,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,gBAAgB,EAAE,eAAe,EAAE,CAAC;CACrC,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,SAAS,EAAE,IAAI,CAAC;IAChB,eAAe,EAAE,SAAS,CAAC;IAC3B,UAAU,EAAE,MAAM,CAAC;IACnB,mBAAmB,EAAE,SAAS,CAAC;IAC/B,sBAAsB,EAAE,SAAS,CAAC;CACnC,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,iBAAiB,EAAE,gBAAgB,EAAE,CAAC;CACvC,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,SAAS,CAAC;CACpB,CAAC;AAEF,MAAM,MAAM,YAAY,GAAG;IACzB,SAAS,EAAE,IAAI,CAAC;IAChB,sBAAsB,EAAE,SAAS,CAAC;IAClC,qBAAqB,EAAE,MAAM,CAAC;CAC/B,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,mBAAmB,EAAE,SAAS,CAAC;IAC/B,YAAY,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,SAAS,EAAE,CAAC;IACrB,YAAY,EAAE,YAAY,EAAE,CAAC;CAC9B,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -2,9 +2,10 @@ import { StakingClient } from './staking';
|
|
|
2
2
|
import { StorageClient } from './storage';
|
|
3
3
|
import { KVStoreClient } from './kvstore';
|
|
4
4
|
import { EscrowClient } from './escrow';
|
|
5
|
+
import { StatisticsClient } from './statistics';
|
|
5
6
|
export * from './constants';
|
|
6
7
|
export * from './types';
|
|
7
8
|
export * from './enums';
|
|
8
9
|
export * from './interfaces';
|
|
9
|
-
export { StakingClient, StorageClient, KVStoreClient, EscrowClient };
|
|
10
|
+
export { StakingClient, StorageClient, KVStoreClient, EscrowClient, StatisticsClient, };
|
|
10
11
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AACxC,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAEhD,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAE7B,OAAO,EACL,aAAa,EACb,aAAa,EACb,aAAa,EACb,YAAY,EACZ,gBAAgB,GACjB,CAAC"}
|