@xyo-network/crypto-contract-function-read-plugin 2.85.0 → 2.85.1
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/browser/Diviner/Diviner.d.cts +2 -0
- package/dist/browser/Diviner/Diviner.d.cts.map +1 -1
- package/dist/browser/Diviner/Diviner.d.mts +2 -0
- package/dist/browser/Diviner/Diviner.d.mts.map +1 -1
- package/dist/browser/Diviner/Diviner.d.ts +2 -0
- package/dist/browser/Diviner/Diviner.d.ts.map +1 -1
- package/dist/browser/Plugin.d.cts +1 -2
- package/dist/browser/Plugin.d.cts.map +1 -1
- package/dist/browser/Plugin.d.mts +1 -2
- package/dist/browser/Plugin.d.mts.map +1 -1
- package/dist/browser/Plugin.d.ts +1 -2
- package/dist/browser/Plugin.d.ts.map +1 -1
- package/dist/browser/Witness.d.cts +2 -0
- package/dist/browser/Witness.d.cts.map +1 -1
- package/dist/browser/Witness.d.mts +2 -0
- package/dist/browser/Witness.d.mts.map +1 -1
- package/dist/browser/Witness.d.ts +2 -0
- package/dist/browser/Witness.d.ts.map +1 -1
- package/dist/browser/index.cjs +70 -72
- package/dist/browser/index.cjs.map +1 -1
- package/dist/browser/index.d.cts +1 -3
- package/dist/browser/index.d.cts.map +1 -1
- package/dist/browser/index.d.mts +1 -3
- package/dist/browser/index.d.mts.map +1 -1
- package/dist/browser/index.d.ts +1 -3
- package/dist/browser/index.d.ts.map +1 -1
- package/dist/browser/index.js +73 -75
- package/dist/browser/index.js.map +1 -1
- package/dist/node/Diviner/Diviner.d.cts +2 -0
- package/dist/node/Diviner/Diviner.d.cts.map +1 -1
- package/dist/node/Diviner/Diviner.d.mts +2 -0
- package/dist/node/Diviner/Diviner.d.mts.map +1 -1
- package/dist/node/Diviner/Diviner.d.ts +2 -0
- package/dist/node/Diviner/Diviner.d.ts.map +1 -1
- package/dist/node/Plugin.d.cts +1 -2
- package/dist/node/Plugin.d.cts.map +1 -1
- package/dist/node/Plugin.d.mts +1 -2
- package/dist/node/Plugin.d.mts.map +1 -1
- package/dist/node/Plugin.d.ts +1 -2
- package/dist/node/Plugin.d.ts.map +1 -1
- package/dist/node/Witness.d.cts +2 -0
- package/dist/node/Witness.d.cts.map +1 -1
- package/dist/node/Witness.d.mts +2 -0
- package/dist/node/Witness.d.mts.map +1 -1
- package/dist/node/Witness.d.ts +2 -0
- package/dist/node/Witness.d.ts.map +1 -1
- package/dist/node/index.cjs +73 -75
- package/dist/node/index.cjs.map +1 -1
- package/dist/node/index.d.cts +1 -3
- package/dist/node/index.d.cts.map +1 -1
- package/dist/node/index.d.mts +1 -3
- package/dist/node/index.d.mts.map +1 -1
- package/dist/node/index.d.ts +1 -3
- package/dist/node/index.d.ts.map +1 -1
- package/dist/node/index.js +76 -78
- package/dist/node/index.js.map +1 -1
- package/package.json +30 -30
- package/src/Diviner/Diviner.ts +6 -1
- package/src/Plugin.ts +2 -0
- package/src/Witness.ts +2 -0
- package/src/index.ts +1 -7
- package/src/spec/NftIndexToNftIdIndex/Erc721.NftId.Index.json +314 -0
- package/src/spec/TotalSupplyToNftIndexIndex/Erc721.NftIndex.Index.json +118 -28
package/package.json
CHANGED
|
@@ -10,41 +10,41 @@
|
|
|
10
10
|
"url": "https://github.com/XYOracleNetwork/plugins/issues"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@xylabs/assert": "^2.13.
|
|
14
|
-
"@xylabs/promise": "^2.13.
|
|
15
|
-
"@xyo-network/abstract-diviner": "^2.85.
|
|
16
|
-
"@xyo-network/abstract-witness": "^2.85.
|
|
17
|
-
"@xyo-network/crypto-contract-function-read-payload-plugin": "~2.85.
|
|
18
|
-
"@xyo-network/crypto-nft-payload-plugin": "~2.85.
|
|
19
|
-
"@xyo-network/module-model": "^2.85.
|
|
20
|
-
"@xyo-network/payload-model": "^2.85.
|
|
21
|
-
"@xyo-network/payloadset-plugin": "^2.85.
|
|
22
|
-
"@xyo-network/witness-model": "^2.85.
|
|
13
|
+
"@xylabs/assert": "^2.13.22",
|
|
14
|
+
"@xylabs/promise": "^2.13.22",
|
|
15
|
+
"@xyo-network/abstract-diviner": "^2.85.3",
|
|
16
|
+
"@xyo-network/abstract-witness": "^2.85.3",
|
|
17
|
+
"@xyo-network/crypto-contract-function-read-payload-plugin": "~2.85.1",
|
|
18
|
+
"@xyo-network/crypto-nft-payload-plugin": "~2.85.1",
|
|
19
|
+
"@xyo-network/module-model": "^2.85.3",
|
|
20
|
+
"@xyo-network/payload-model": "^2.85.3",
|
|
21
|
+
"@xyo-network/payloadset-plugin": "^2.85.3",
|
|
22
|
+
"@xyo-network/witness-model": "^2.85.3",
|
|
23
23
|
"ethers": "^6.9.1"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@xylabs/delay": "^2.13.
|
|
27
|
-
"@xylabs/hex": "^2.13.
|
|
28
|
-
"@xylabs/jest-helpers": "^2.13.
|
|
26
|
+
"@xylabs/delay": "^2.13.22",
|
|
27
|
+
"@xylabs/hex": "^2.13.22",
|
|
28
|
+
"@xylabs/jest-helpers": "^2.13.22",
|
|
29
29
|
"@xylabs/ts-scripts-yarn3": "^3.2.25",
|
|
30
30
|
"@xylabs/tsconfig": "^3.2.25",
|
|
31
|
-
"@xyo-network/account": "^2.85.
|
|
32
|
-
"@xyo-network/diviner-boundwitness-memory": "^2.85.
|
|
33
|
-
"@xyo-network/diviner-jsonpatch": "^2.85.
|
|
34
|
-
"@xyo-network/diviner-jsonpath-aggregate-memory": "^2.85.
|
|
35
|
-
"@xyo-network/diviner-model": "^2.85.
|
|
36
|
-
"@xyo-network/diviner-payload-memory": "^2.85.
|
|
37
|
-
"@xyo-network/diviner-payload-model": "^2.85.
|
|
38
|
-
"@xyo-network/diviner-range": "^2.85.
|
|
39
|
-
"@xyo-network/diviner-temporal-indexing": "^2.85.
|
|
40
|
-
"@xyo-network/evm-nft-id-payload-plugin": "~2.85.
|
|
41
|
-
"@xyo-network/manifest": "^2.85.
|
|
42
|
-
"@xyo-network/memory-archivist": "^2.85.
|
|
43
|
-
"@xyo-network/node-memory": "^2.85.
|
|
31
|
+
"@xyo-network/account": "^2.85.3",
|
|
32
|
+
"@xyo-network/diviner-boundwitness-memory": "^2.85.3",
|
|
33
|
+
"@xyo-network/diviner-jsonpatch": "^2.85.3",
|
|
34
|
+
"@xyo-network/diviner-jsonpath-aggregate-memory": "^2.85.3",
|
|
35
|
+
"@xyo-network/diviner-model": "^2.85.3",
|
|
36
|
+
"@xyo-network/diviner-payload-memory": "^2.85.3",
|
|
37
|
+
"@xyo-network/diviner-payload-model": "^2.85.3",
|
|
38
|
+
"@xyo-network/diviner-range": "^2.85.3",
|
|
39
|
+
"@xyo-network/diviner-temporal-indexing": "^2.85.3",
|
|
40
|
+
"@xyo-network/evm-nft-id-payload-plugin": "~2.85.1",
|
|
41
|
+
"@xyo-network/manifest": "^2.85.3",
|
|
42
|
+
"@xyo-network/memory-archivist": "^2.85.3",
|
|
43
|
+
"@xyo-network/node-memory": "^2.85.3",
|
|
44
44
|
"@xyo-network/open-zeppelin-typechain": "^3.0.5",
|
|
45
|
-
"@xyo-network/sentinel-model": "^2.85.
|
|
46
|
-
"@xyo-network/witness-blockchain-abstract": "^2.85.
|
|
47
|
-
"@xyo-network/witness-timestamp": "^2.85.
|
|
45
|
+
"@xyo-network/sentinel-model": "^2.85.3",
|
|
46
|
+
"@xyo-network/witness-blockchain-abstract": "^2.85.3",
|
|
47
|
+
"@xyo-network/witness-timestamp": "^2.85.3",
|
|
48
48
|
"async-mutex": "^0.4.0",
|
|
49
49
|
"jest": "^29.7.0",
|
|
50
50
|
"typescript": "^5.3.3"
|
|
@@ -88,6 +88,6 @@
|
|
|
88
88
|
"url": "https://github.com/XYOracleNetwork/plugins.git"
|
|
89
89
|
},
|
|
90
90
|
"sideEffects": false,
|
|
91
|
-
"version": "2.85.
|
|
91
|
+
"version": "2.85.1",
|
|
92
92
|
"type": "module"
|
|
93
93
|
}
|
package/src/Diviner/Diviner.ts
CHANGED
|
@@ -13,8 +13,10 @@ import {
|
|
|
13
13
|
} from '@xyo-network/crypto-contract-function-read-payload-plugin'
|
|
14
14
|
import { isPayloadOfSchemaType, Payload } from '@xyo-network/payload-model'
|
|
15
15
|
|
|
16
|
+
/** @deprecated use EvmCallDiviner instead */
|
|
16
17
|
export type FindCallResult<TResult = string, TPayload = Payload> = [TResult, TPayload] | [undefined, TPayload] | [undefined, undefined]
|
|
17
18
|
|
|
19
|
+
/** @deprecated use EvmCallDiviner instead */
|
|
18
20
|
export class CryptoContractDiviner<TParams extends CryptoContractDivinerParams = CryptoContractDivinerParams> extends AbstractDiviner<TParams> {
|
|
19
21
|
static override configSchemas = [CryptoContractDivinerConfigSchema]
|
|
20
22
|
static labels: CryptoContractDivinerLabels = CryptoContractDivinerLabels
|
|
@@ -30,6 +32,7 @@ export class CryptoContractDiviner<TParams extends CryptoContractDivinerParams =
|
|
|
30
32
|
|
|
31
33
|
protected static matchingExistingField<R = string, T extends Payload = Payload>(objs: T[], field: keyof T): R | undefined {
|
|
32
34
|
const expectedValue = objs.at(0)?.[field] as R
|
|
35
|
+
// eslint-disable-next-line unicorn/no-array-reduce
|
|
33
36
|
const didNotMatch = objs.reduce((prev, obj) => {
|
|
34
37
|
return prev || obj[field] !== expectedValue
|
|
35
38
|
}, false)
|
|
@@ -47,6 +50,7 @@ export class CryptoContractDiviner<TParams extends CryptoContractDivinerParams =
|
|
|
47
50
|
protected override async divineHandler(inPayloads: CryptoContractFunctionCallResult[] = []): Promise<ContractInfo[]> {
|
|
48
51
|
const callResults = inPayloads.filter(isPayloadOfSchemaType<CryptoContractFunctionCallResult>(CryptoContractFunctionCallResultSchema))
|
|
49
52
|
const addresses = Object.keys(
|
|
53
|
+
// eslint-disable-next-line unicorn/no-array-reduce
|
|
50
54
|
callResults.reduce<Record<string, boolean>>((prev, result) => {
|
|
51
55
|
if (result.address) {
|
|
52
56
|
prev[result.address] = true
|
|
@@ -58,7 +62,7 @@ export class CryptoContractDiviner<TParams extends CryptoContractDivinerParams =
|
|
|
58
62
|
addresses.map(async (address) => {
|
|
59
63
|
const foundCallResults = callResults.filter((callResult) => callResult.address === address)
|
|
60
64
|
const info: ContractInfo = {
|
|
61
|
-
|
|
65
|
+
results: await this.reduceResults(foundCallResults),
|
|
62
66
|
...this.contractInfoRequiredFields(foundCallResults),
|
|
63
67
|
}
|
|
64
68
|
return info
|
|
@@ -69,6 +73,7 @@ export class CryptoContractDiviner<TParams extends CryptoContractDivinerParams =
|
|
|
69
73
|
}
|
|
70
74
|
|
|
71
75
|
protected reduceResults(callResults: CryptoContractFunctionCallResult[]): Promisable<ContractInfo['results']> {
|
|
76
|
+
// eslint-disable-next-line unicorn/no-array-reduce
|
|
72
77
|
return callResults.reduce<Record<string, unknown>>((prev, callResult) => {
|
|
73
78
|
prev[callResult.functionName] = asCryptoContractFunctionCallSuccess(callResult)?.result
|
|
74
79
|
return prev
|
package/src/Plugin.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
+
/* eslint-disable import/no-deprecated */
|
|
1
2
|
import { NftSchema } from '@xyo-network/crypto-nft-payload-plugin'
|
|
2
3
|
import { PayloadSetSchema } from '@xyo-network/payload-model'
|
|
3
4
|
import { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'
|
|
4
5
|
|
|
5
6
|
import { CryptoContractFunctionReadWitness } from './Witness'
|
|
6
7
|
|
|
8
|
+
/** @deprecated use EvmCallWitness instead */
|
|
7
9
|
export const CryptoContractFunctionReadWitnessPlugin = () =>
|
|
8
10
|
createPayloadSetWitnessPlugin<CryptoContractFunctionReadWitness>(
|
|
9
11
|
{ required: { [NftSchema]: 1 }, schema: PayloadSetSchema },
|
package/src/Witness.ts
CHANGED
|
@@ -15,6 +15,7 @@ import { isPayloadOfSchemaType } from '@xyo-network/payload-model'
|
|
|
15
15
|
import { WitnessParams } from '@xyo-network/witness-model'
|
|
16
16
|
import { Contract, Provider } from 'ethers'
|
|
17
17
|
|
|
18
|
+
/** @deprecated use EvmCallWitness instead */
|
|
18
19
|
export type CryptoContractFunctionReadWitnessParams = WitnessParams<
|
|
19
20
|
AnyConfigSchema<CryptoContractFunctionReadWitnessConfig>,
|
|
20
21
|
{
|
|
@@ -22,6 +23,7 @@ export type CryptoContractFunctionReadWitnessParams = WitnessParams<
|
|
|
22
23
|
}
|
|
23
24
|
>
|
|
24
25
|
|
|
26
|
+
/** @deprecated use EvmCallWitness instead */
|
|
25
27
|
export class CryptoContractFunctionReadWitness<
|
|
26
28
|
TParams extends CryptoContractFunctionReadWitnessParams = CryptoContractFunctionReadWitnessParams,
|
|
27
29
|
> extends AbstractWitness<TParams, CryptoContractFunctionCall, CryptoContractFunctionCallResult> {
|
package/src/index.ts
CHANGED
|
@@ -1,9 +1,3 @@
|
|
|
1
|
-
import { CryptoContractFunctionReadWitnessPlugin } from './Plugin'
|
|
2
|
-
|
|
3
1
|
export * from './Diviner'
|
|
2
|
+
export { CryptoContractFunctionReadWitnessPlugin, CryptoContractFunctionReadWitnessPlugin as default } from './Plugin'
|
|
4
3
|
export * from './Witness'
|
|
5
|
-
|
|
6
|
-
export { CryptoContractFunctionReadWitnessPlugin }
|
|
7
|
-
|
|
8
|
-
// eslint-disable-next-line import/no-default-export
|
|
9
|
-
export default CryptoContractFunctionReadWitnessPlugin
|
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/XYOracleNetwork/sdk-xyo-client-js/main/packages/manifest/src/schema.json",
|
|
3
|
+
"nodes": [
|
|
4
|
+
{
|
|
5
|
+
"config": {
|
|
6
|
+
"name": "Info",
|
|
7
|
+
"schema": "network.xyo.node.config"
|
|
8
|
+
},
|
|
9
|
+
"modules": {
|
|
10
|
+
"private": [
|
|
11
|
+
{
|
|
12
|
+
"config": {
|
|
13
|
+
"name": "AddressStateArchivist",
|
|
14
|
+
"schema": "network.xyo.archivist.config",
|
|
15
|
+
"storeQueries": false
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"config": {
|
|
20
|
+
"archivist": "AddressStateArchivist",
|
|
21
|
+
"name": "AddressStateBoundWitnessDiviner",
|
|
22
|
+
"schema": "network.xyo.diviner.boundwitness.config"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
"config": {
|
|
27
|
+
"archivist": "AddressStateArchivist",
|
|
28
|
+
"name": "AddressStatePayloadDiviner",
|
|
29
|
+
"schema": "network.xyo.diviner.payload.config"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"config": {
|
|
34
|
+
"name": "IndexArchivist",
|
|
35
|
+
"schema": "network.xyo.archivist.config"
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"config": {
|
|
40
|
+
"archivist": "IndexArchivist",
|
|
41
|
+
"name": "IndexBoundWitnessDiviner",
|
|
42
|
+
"schema": "network.xyo.diviner.boundwitness.config"
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"config": {
|
|
47
|
+
"archivist": "IndexArchivist",
|
|
48
|
+
"name": "IndexPayloadDiviner",
|
|
49
|
+
"schema": "network.xyo.diviner.payload.config"
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"config": {
|
|
54
|
+
"filter": {
|
|
55
|
+
"payload_schemas": ["network.xyo.evm.nft.index"]
|
|
56
|
+
},
|
|
57
|
+
"labels": {
|
|
58
|
+
"network.xyo.diviner.stage": "stateToIndexCandidateDiviner"
|
|
59
|
+
},
|
|
60
|
+
"name": "StateToIndexCandidateDiviner",
|
|
61
|
+
"payloadStore": {
|
|
62
|
+
"archivist": "Archivist",
|
|
63
|
+
"boundWitnessDiviner": "BoundWitnessDiviner",
|
|
64
|
+
"payloadDiviner": "PayloadDiviner"
|
|
65
|
+
},
|
|
66
|
+
"schema": "network.xyo.diviner.indexing.temporal.stage.stateToIndexCandidateDiviner.config"
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"config": {
|
|
71
|
+
"labels": {
|
|
72
|
+
"network.xyo.diviner.stage": "indexCandidateToIndexDiviner"
|
|
73
|
+
},
|
|
74
|
+
"name": "IndexCandidateToIndexDiviner",
|
|
75
|
+
"schema": "network.xyo.diviner.indexing.temporal.stage.indexCandidateToIndexDiviner.config",
|
|
76
|
+
"schemaTransforms": {
|
|
77
|
+
"network.xyo.evm.nft.index": [
|
|
78
|
+
{
|
|
79
|
+
"destinationField": "address",
|
|
80
|
+
"sourcePathExpression": "$.address"
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
"destinationField": "chainId",
|
|
84
|
+
"sourcePathExpression": "$.chainId"
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"destinationField": "index",
|
|
88
|
+
"sourcePathExpression": "$.index"
|
|
89
|
+
}
|
|
90
|
+
],
|
|
91
|
+
"network.xyo.timestamp": [
|
|
92
|
+
{
|
|
93
|
+
"destinationField": "timestamp",
|
|
94
|
+
"sourcePathExpression": "$.timestamp"
|
|
95
|
+
}
|
|
96
|
+
]
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
"config": {
|
|
102
|
+
"divinerQuerySchema": "network.xyo.diviner.payload.query",
|
|
103
|
+
"indexQuerySchema": "network.xyo.diviner.payload.query",
|
|
104
|
+
"indexSchema": "network.xyo.diviner.indexing.temporal.result.index",
|
|
105
|
+
"labels": {
|
|
106
|
+
"network.xyo.diviner.stage": "divinerQueryToIndexQueryDiviner"
|
|
107
|
+
},
|
|
108
|
+
"name": "QueryToIndexQueryDiviner",
|
|
109
|
+
"schema": "network.xyo.diviner.indexing.temporal.stage.divinerQueryToIndexQueryDiviner.config",
|
|
110
|
+
"schemaTransforms": {
|
|
111
|
+
"network.xyo.diviner.payload.query": [
|
|
112
|
+
{
|
|
113
|
+
"destinationField": "address",
|
|
114
|
+
"sourcePathExpression": "$.address"
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
"defaultValue": 1,
|
|
118
|
+
"destinationField": "chainId",
|
|
119
|
+
"sourcePathExpression": "$.chainId"
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
"defaultValue": 1,
|
|
123
|
+
"destinationField": "limit",
|
|
124
|
+
"sourcePathExpression": "$.limit"
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
"defaultValue": 0,
|
|
128
|
+
"destinationField": "offset",
|
|
129
|
+
"sourcePathExpression": "$.offset"
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
"defaultValue": "desc",
|
|
133
|
+
"destinationField": "order",
|
|
134
|
+
"sourcePathExpression": "$.order"
|
|
135
|
+
}
|
|
136
|
+
]
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
"config": {
|
|
142
|
+
"labels": {
|
|
143
|
+
"network.xyo.diviner.stage": "indexQueryResponseToDivinerQueryResponseDiviner"
|
|
144
|
+
},
|
|
145
|
+
"name": "IndexQueryResponseToQueryResponseDiviner",
|
|
146
|
+
"schema": "network.xyo.diviner.indexing.temporal.stage.indexQueryResponseToDivinerQueryResponseDiviner.config"
|
|
147
|
+
}
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
"config": {
|
|
151
|
+
"name": "TimestampWitness",
|
|
152
|
+
"schema": "network.xyo.witness.timestamp.config"
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
"config": {
|
|
157
|
+
"name": "RangeDiviner",
|
|
158
|
+
"schema": "network.xyo.diviner.range.config"
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
"config": {
|
|
163
|
+
"name": "InputBufferingDiviner",
|
|
164
|
+
"operations": [
|
|
165
|
+
{
|
|
166
|
+
"op": "test",
|
|
167
|
+
"path": "/schema",
|
|
168
|
+
"value": "network.xyo.crypto.contract.function.call"
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
"op": "test",
|
|
172
|
+
"path": "/functionName",
|
|
173
|
+
"value": "tokenByIndex"
|
|
174
|
+
},
|
|
175
|
+
{ "op": "defined", "path": "/address" }
|
|
176
|
+
],
|
|
177
|
+
"schema": "network.xyo.diviner.jsonpatch.config"
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
"config": {
|
|
182
|
+
"destinationSchema": "network.xyo.evm.nft.id",
|
|
183
|
+
"name": "NftIdPartialToNftIdTransformDiviner",
|
|
184
|
+
"schemaTransforms": {
|
|
185
|
+
"network.xyo.crypto.contract.function.call.result": [
|
|
186
|
+
{
|
|
187
|
+
"destinationField": "address",
|
|
188
|
+
"sourcePathExpression": "$.address"
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
"destinationField": "chainId",
|
|
192
|
+
"sourcePathExpression": "$.chainId"
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
"destinationField": "tokenId",
|
|
196
|
+
"sourcePathExpression": "$.result"
|
|
197
|
+
}
|
|
198
|
+
]
|
|
199
|
+
},
|
|
200
|
+
"schema": "network.xyo.diviner.jsonpath.aggregate.config"
|
|
201
|
+
}
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
"config": {
|
|
205
|
+
"name": "InputBufferingSentinel",
|
|
206
|
+
"schema": "network.xyo.sentinel.config",
|
|
207
|
+
"synchronous": "true",
|
|
208
|
+
"tasks": [
|
|
209
|
+
{
|
|
210
|
+
"input": true,
|
|
211
|
+
"module": "InputBufferingDiviner"
|
|
212
|
+
}
|
|
213
|
+
]
|
|
214
|
+
}
|
|
215
|
+
},
|
|
216
|
+
{
|
|
217
|
+
"config": {
|
|
218
|
+
"functionName": "tokenByIndex",
|
|
219
|
+
"labels": {
|
|
220
|
+
"network.xyo.crypto.contract.interface": "Erc721Enumerable"
|
|
221
|
+
},
|
|
222
|
+
"language": "javascript",
|
|
223
|
+
"name": "Erc721TokenByIndexWitness",
|
|
224
|
+
"schema": "network.xyo.crypto.contract.function.read.config"
|
|
225
|
+
}
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
"config": {
|
|
229
|
+
"archiving": {
|
|
230
|
+
"archivists": ["Archivist"]
|
|
231
|
+
},
|
|
232
|
+
"name": "TokenIndexToTokenIdSentinel",
|
|
233
|
+
"schema": "network.xyo.sentinel.config",
|
|
234
|
+
"synchronous": "true",
|
|
235
|
+
"tasks": [
|
|
236
|
+
{
|
|
237
|
+
"input": true,
|
|
238
|
+
"module": "Erc721TokenByIndexWitness"
|
|
239
|
+
}
|
|
240
|
+
]
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
],
|
|
244
|
+
"public": [
|
|
245
|
+
{
|
|
246
|
+
"config": {
|
|
247
|
+
"name": "Archivist",
|
|
248
|
+
"schema": "network.xyo.archivist.config",
|
|
249
|
+
"storeQueries": false
|
|
250
|
+
}
|
|
251
|
+
},
|
|
252
|
+
{
|
|
253
|
+
"config": {
|
|
254
|
+
"archivist": "Archivist",
|
|
255
|
+
"name": "BoundWitnessDiviner",
|
|
256
|
+
"schema": "network.xyo.diviner.boundwitness.config"
|
|
257
|
+
}
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
"config": {
|
|
261
|
+
"archivist": "Archivist",
|
|
262
|
+
"name": "PayloadDiviner",
|
|
263
|
+
"schema": "network.xyo.diviner.payload.config"
|
|
264
|
+
}
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
"config": {
|
|
268
|
+
"indexStore": {
|
|
269
|
+
"archivist": "IndexArchivist",
|
|
270
|
+
"boundWitnessDiviner": "IndexBoundWitnessDiviner",
|
|
271
|
+
"payloadDiviner": "IndexPayloadDiviner"
|
|
272
|
+
},
|
|
273
|
+
"indexingDivinerStages": {
|
|
274
|
+
"divinerQueryToIndexQueryDiviner": "QueryToIndexQueryDiviner",
|
|
275
|
+
"indexCandidateToIndexDiviner": "IndexCandidateToIndexDiviner",
|
|
276
|
+
"indexQueryResponseToDivinerQueryResponseDiviner": "IndexQueryResponseToQueryResponseDiviner",
|
|
277
|
+
"stateToIndexCandidateDiviner": "StateToIndexCandidateDiviner"
|
|
278
|
+
},
|
|
279
|
+
"name": "IndexDiviner",
|
|
280
|
+
"pollFrequency": 1,
|
|
281
|
+
"schema": "network.xyo.diviner.indexing.temporal.config",
|
|
282
|
+
"stateStore": {
|
|
283
|
+
"archivist": "AddressStateArchivist",
|
|
284
|
+
"boundWitnessDiviner": "AddressStateBoundWitnessDiviner",
|
|
285
|
+
"payloadDiviner": "AddressStatePayloadDiviner"
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
},
|
|
289
|
+
{
|
|
290
|
+
"config": {
|
|
291
|
+
"archiving": {
|
|
292
|
+
"archivists": ["Archivist"]
|
|
293
|
+
},
|
|
294
|
+
"name": "Sentinel",
|
|
295
|
+
"schema": "network.xyo.sentinel.config",
|
|
296
|
+
"synchronous": "true",
|
|
297
|
+
"tasks": [
|
|
298
|
+
{
|
|
299
|
+
"input": true,
|
|
300
|
+
"module": "Erc721TokenByIndexWitness"
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
"input": ["Erc721TokenByIndexWitness"],
|
|
304
|
+
"module": "NftIdPartialToNftIdTransformDiviner"
|
|
305
|
+
}
|
|
306
|
+
]
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
]
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
],
|
|
313
|
+
"schema": "network.xyo.manifest"
|
|
314
|
+
}
|