envio 2.2.5-fuel → 2.3.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/evm.schema.json +499 -0
- package/fuel.schema.json +129 -83
- package/package.json +10 -10
package/evm.schema.json
ADDED
|
@@ -0,0 +1,499 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"title": "Envio Config Schema",
|
|
4
|
+
"description": "Schema for a YAML config for an envio indexer",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"description": {
|
|
8
|
+
"description": "Description of the project",
|
|
9
|
+
"type": [
|
|
10
|
+
"string",
|
|
11
|
+
"null"
|
|
12
|
+
]
|
|
13
|
+
},
|
|
14
|
+
"name": {
|
|
15
|
+
"description": "Name of the project",
|
|
16
|
+
"type": "string"
|
|
17
|
+
},
|
|
18
|
+
"ecosystem": {
|
|
19
|
+
"description": "Ecosystem of the project.",
|
|
20
|
+
"anyOf": [
|
|
21
|
+
{
|
|
22
|
+
"$ref": "#/$defs/EcosystemTag"
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"type": "null"
|
|
26
|
+
}
|
|
27
|
+
]
|
|
28
|
+
},
|
|
29
|
+
"schema": {
|
|
30
|
+
"description": "Custom path to schema.yaml file",
|
|
31
|
+
"type": [
|
|
32
|
+
"string",
|
|
33
|
+
"null"
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
"contracts": {
|
|
37
|
+
"description": "Global contract definitions that must contain all definitions except addresses. You can share a single handler/abi/event definitions for contracts across multiple chains.",
|
|
38
|
+
"type": [
|
|
39
|
+
"array",
|
|
40
|
+
"null"
|
|
41
|
+
],
|
|
42
|
+
"items": {
|
|
43
|
+
"$ref": "#/$defs/GlobalContract_for_ContractConfig"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"networks": {
|
|
47
|
+
"description": "Configuration of the blockchain networks that the project is deployed on.",
|
|
48
|
+
"type": "array",
|
|
49
|
+
"items": {
|
|
50
|
+
"$ref": "#/$defs/Network"
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
"unordered_multichain_mode": {
|
|
54
|
+
"description": "A flag to indicate if the indexer should use a single queue for all chains or a queue per chain (default: false)",
|
|
55
|
+
"type": [
|
|
56
|
+
"boolean",
|
|
57
|
+
"null"
|
|
58
|
+
]
|
|
59
|
+
},
|
|
60
|
+
"event_decoder": {
|
|
61
|
+
"description": "The event decoder to use for the indexer (default: hypersync-client)",
|
|
62
|
+
"anyOf": [
|
|
63
|
+
{
|
|
64
|
+
"$ref": "#/$defs/EventDecoder"
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"type": "null"
|
|
68
|
+
}
|
|
69
|
+
]
|
|
70
|
+
},
|
|
71
|
+
"rollback_on_reorg": {
|
|
72
|
+
"description": "A flag to indicate if the indexer should rollback to the last known valid block on a reorg. This currently incurs a performance hit on historical sync and is recommended to turn this off while developing (default: true)",
|
|
73
|
+
"type": [
|
|
74
|
+
"boolean",
|
|
75
|
+
"null"
|
|
76
|
+
]
|
|
77
|
+
},
|
|
78
|
+
"save_full_history": {
|
|
79
|
+
"description": "A flag to indicate if the indexer should save the full history of events. This is useful for debugging but will increase the size of the database (default: false)",
|
|
80
|
+
"type": [
|
|
81
|
+
"boolean",
|
|
82
|
+
"null"
|
|
83
|
+
]
|
|
84
|
+
},
|
|
85
|
+
"field_selection": {
|
|
86
|
+
"description": "An object representing additional fields to add to the event passed to handlers.",
|
|
87
|
+
"anyOf": [
|
|
88
|
+
{
|
|
89
|
+
"$ref": "#/$defs/FieldSelection"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"type": "null"
|
|
93
|
+
}
|
|
94
|
+
]
|
|
95
|
+
},
|
|
96
|
+
"raw_events": {
|
|
97
|
+
"description": "If true, the indexer will store the raw event data in the database. This is useful for debugging, but will increase the size of the database and the amount of time it takes to process events (default: false)",
|
|
98
|
+
"type": [
|
|
99
|
+
"boolean",
|
|
100
|
+
"null"
|
|
101
|
+
]
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"additionalProperties": false,
|
|
105
|
+
"required": [
|
|
106
|
+
"name",
|
|
107
|
+
"networks"
|
|
108
|
+
],
|
|
109
|
+
"$defs": {
|
|
110
|
+
"EcosystemTag": {
|
|
111
|
+
"type": "string",
|
|
112
|
+
"enum": [
|
|
113
|
+
"evm"
|
|
114
|
+
]
|
|
115
|
+
},
|
|
116
|
+
"GlobalContract_for_ContractConfig": {
|
|
117
|
+
"type": "object",
|
|
118
|
+
"properties": {
|
|
119
|
+
"name": {
|
|
120
|
+
"description": "A unique project-wide name for this contract (no spaces)",
|
|
121
|
+
"type": "string"
|
|
122
|
+
},
|
|
123
|
+
"abi_file_path": {
|
|
124
|
+
"description": "Relative path (from config) to a json abi. If this is used then each configured event should simply be referenced by its name",
|
|
125
|
+
"type": [
|
|
126
|
+
"string",
|
|
127
|
+
"null"
|
|
128
|
+
]
|
|
129
|
+
},
|
|
130
|
+
"handler": {
|
|
131
|
+
"description": "The relative path to a file where handlers are registered for the given contract",
|
|
132
|
+
"type": "string"
|
|
133
|
+
},
|
|
134
|
+
"events": {
|
|
135
|
+
"description": "A list of events that should be indexed on this contract",
|
|
136
|
+
"type": "array",
|
|
137
|
+
"items": {
|
|
138
|
+
"$ref": "#/$defs/EventConfig"
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
},
|
|
142
|
+
"additionalProperties": false,
|
|
143
|
+
"required": [
|
|
144
|
+
"name",
|
|
145
|
+
"handler",
|
|
146
|
+
"events"
|
|
147
|
+
]
|
|
148
|
+
},
|
|
149
|
+
"EventConfig": {
|
|
150
|
+
"type": "object",
|
|
151
|
+
"properties": {
|
|
152
|
+
"event": {
|
|
153
|
+
"description": "The human readable signature of an event 'eg. Transfer(address indexed from, address indexed to, uint256 value)' OR a reference to the name of an event in a json ABI file defined in your contract config. A provided signature will take precedence over what is defined in the json ABI",
|
|
154
|
+
"type": "string"
|
|
155
|
+
},
|
|
156
|
+
"name": {
|
|
157
|
+
"description": "Name of the event in the HyperIndex generated code. When ommitted, the event field will be used. Should be unique per contract",
|
|
158
|
+
"type": [
|
|
159
|
+
"string",
|
|
160
|
+
"null"
|
|
161
|
+
]
|
|
162
|
+
}
|
|
163
|
+
},
|
|
164
|
+
"additionalProperties": false,
|
|
165
|
+
"required": [
|
|
166
|
+
"event"
|
|
167
|
+
]
|
|
168
|
+
},
|
|
169
|
+
"Network": {
|
|
170
|
+
"type": "object",
|
|
171
|
+
"properties": {
|
|
172
|
+
"id": {
|
|
173
|
+
"description": "Public chain/network id",
|
|
174
|
+
"type": "integer",
|
|
175
|
+
"format": "uint64",
|
|
176
|
+
"minimum": 0
|
|
177
|
+
},
|
|
178
|
+
"rpc_config": {
|
|
179
|
+
"description": "RPC Config that will be used to subscribe to blockchain data on this network (TIP: This is optional and in most cases does not need to be specified if the network is supported with HyperSync. We recommend using HyperSync instead of RPC for 100x speed-up)",
|
|
180
|
+
"anyOf": [
|
|
181
|
+
{
|
|
182
|
+
"$ref": "#/$defs/RpcConfig"
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
"type": "null"
|
|
186
|
+
}
|
|
187
|
+
]
|
|
188
|
+
},
|
|
189
|
+
"hypersync_config": {
|
|
190
|
+
"description": "Optional HyperSync Config for additional fine-tuning",
|
|
191
|
+
"anyOf": [
|
|
192
|
+
{
|
|
193
|
+
"$ref": "#/$defs/HypersyncConfig"
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
"type": "null"
|
|
197
|
+
}
|
|
198
|
+
]
|
|
199
|
+
},
|
|
200
|
+
"confirmed_block_threshold": {
|
|
201
|
+
"description": "The number of blocks from the head that the indexer should account for in case of reorgs.",
|
|
202
|
+
"type": [
|
|
203
|
+
"integer",
|
|
204
|
+
"null"
|
|
205
|
+
],
|
|
206
|
+
"format": "int32"
|
|
207
|
+
},
|
|
208
|
+
"start_block": {
|
|
209
|
+
"description": "The block at which the indexer should start ingesting data",
|
|
210
|
+
"type": "integer",
|
|
211
|
+
"format": "int32"
|
|
212
|
+
},
|
|
213
|
+
"end_block": {
|
|
214
|
+
"description": "The block at which the indexer should terminate.",
|
|
215
|
+
"type": [
|
|
216
|
+
"integer",
|
|
217
|
+
"null"
|
|
218
|
+
],
|
|
219
|
+
"format": "int32"
|
|
220
|
+
},
|
|
221
|
+
"contracts": {
|
|
222
|
+
"description": "All the contracts that should be indexed on the given network",
|
|
223
|
+
"type": "array",
|
|
224
|
+
"items": {
|
|
225
|
+
"$ref": "#/$defs/NetworkContract_for_ContractConfig"
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
},
|
|
229
|
+
"additionalProperties": false,
|
|
230
|
+
"required": [
|
|
231
|
+
"id",
|
|
232
|
+
"start_block",
|
|
233
|
+
"contracts"
|
|
234
|
+
]
|
|
235
|
+
},
|
|
236
|
+
"RpcConfig": {
|
|
237
|
+
"type": "object",
|
|
238
|
+
"properties": {
|
|
239
|
+
"url": {
|
|
240
|
+
"description": "URL of the RPC endpoint. Can be a single URL or an array of URLs. If multiple URLs are provided, the first one will be used as the primary RPC endpoint and the rest will be used as fallbacks.",
|
|
241
|
+
"anyOf": [
|
|
242
|
+
{
|
|
243
|
+
"type": "string"
|
|
244
|
+
},
|
|
245
|
+
{
|
|
246
|
+
"type": "array",
|
|
247
|
+
"items": {
|
|
248
|
+
"type": "string"
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
]
|
|
252
|
+
},
|
|
253
|
+
"initial_block_interval": {
|
|
254
|
+
"description": "The starting interval in range of blocks per query",
|
|
255
|
+
"type": [
|
|
256
|
+
"integer",
|
|
257
|
+
"null"
|
|
258
|
+
],
|
|
259
|
+
"format": "uint32",
|
|
260
|
+
"minimum": 0
|
|
261
|
+
},
|
|
262
|
+
"backoff_multiplicative": {
|
|
263
|
+
"description": "After an RPC error, how much to scale back the number of blocks requested at once",
|
|
264
|
+
"type": [
|
|
265
|
+
"number",
|
|
266
|
+
"null"
|
|
267
|
+
],
|
|
268
|
+
"format": "double"
|
|
269
|
+
},
|
|
270
|
+
"acceleration_additive": {
|
|
271
|
+
"description": "Without RPC errors or timeouts, how much to increase the number of blocks requested by for the next batch",
|
|
272
|
+
"type": [
|
|
273
|
+
"integer",
|
|
274
|
+
"null"
|
|
275
|
+
],
|
|
276
|
+
"format": "uint32",
|
|
277
|
+
"minimum": 0
|
|
278
|
+
},
|
|
279
|
+
"interval_ceiling": {
|
|
280
|
+
"description": "Do not further increase the block interval past this limit",
|
|
281
|
+
"type": [
|
|
282
|
+
"integer",
|
|
283
|
+
"null"
|
|
284
|
+
],
|
|
285
|
+
"format": "uint32",
|
|
286
|
+
"minimum": 0
|
|
287
|
+
},
|
|
288
|
+
"backoff_millis": {
|
|
289
|
+
"description": "After an error, how long to wait before retrying",
|
|
290
|
+
"type": [
|
|
291
|
+
"integer",
|
|
292
|
+
"null"
|
|
293
|
+
],
|
|
294
|
+
"format": "uint32",
|
|
295
|
+
"minimum": 0
|
|
296
|
+
},
|
|
297
|
+
"fallback_stall_timeout": {
|
|
298
|
+
"description": "If a fallback RPC is provided, the amount of time in ms to wait before kicking off the next provider",
|
|
299
|
+
"type": [
|
|
300
|
+
"integer",
|
|
301
|
+
"null"
|
|
302
|
+
],
|
|
303
|
+
"format": "uint32",
|
|
304
|
+
"minimum": 0
|
|
305
|
+
},
|
|
306
|
+
"query_timeout_millis": {
|
|
307
|
+
"description": "How long to wait before cancelling an RPC request",
|
|
308
|
+
"type": [
|
|
309
|
+
"integer",
|
|
310
|
+
"null"
|
|
311
|
+
],
|
|
312
|
+
"format": "uint32",
|
|
313
|
+
"minimum": 0
|
|
314
|
+
}
|
|
315
|
+
},
|
|
316
|
+
"additionalProperties": false,
|
|
317
|
+
"required": [
|
|
318
|
+
"url"
|
|
319
|
+
]
|
|
320
|
+
},
|
|
321
|
+
"HypersyncConfig": {
|
|
322
|
+
"type": "object",
|
|
323
|
+
"properties": {
|
|
324
|
+
"url": {
|
|
325
|
+
"description": "URL of the HyperSync endpoint (default: The most performant HyperSync endpoint for the network)",
|
|
326
|
+
"type": "string"
|
|
327
|
+
}
|
|
328
|
+
},
|
|
329
|
+
"additionalProperties": false,
|
|
330
|
+
"required": [
|
|
331
|
+
"url"
|
|
332
|
+
]
|
|
333
|
+
},
|
|
334
|
+
"NetworkContract_for_ContractConfig": {
|
|
335
|
+
"type": "object",
|
|
336
|
+
"properties": {
|
|
337
|
+
"name": {
|
|
338
|
+
"description": "A unique project-wide name for this contract if events and handler are defined OR a reference to the name of contract defined globally at the top level",
|
|
339
|
+
"type": "string"
|
|
340
|
+
},
|
|
341
|
+
"address": {
|
|
342
|
+
"description": "A single address or a list of addresses to be indexed. This can be left as null in the case where this contracts addresses will be registered dynamically.",
|
|
343
|
+
"$ref": "#/$defs/Addresses"
|
|
344
|
+
},
|
|
345
|
+
"abi_file_path": {
|
|
346
|
+
"description": "Relative path (from config) to a json abi. If this is used then each configured event should simply be referenced by its name",
|
|
347
|
+
"type": [
|
|
348
|
+
"string",
|
|
349
|
+
"null"
|
|
350
|
+
]
|
|
351
|
+
},
|
|
352
|
+
"handler": {
|
|
353
|
+
"description": "The relative path to a file where handlers are registered for the given contract",
|
|
354
|
+
"type": "string"
|
|
355
|
+
},
|
|
356
|
+
"events": {
|
|
357
|
+
"description": "A list of events that should be indexed on this contract",
|
|
358
|
+
"type": "array",
|
|
359
|
+
"items": {
|
|
360
|
+
"$ref": "#/$defs/EventConfig"
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
},
|
|
364
|
+
"additionalProperties": false,
|
|
365
|
+
"required": [
|
|
366
|
+
"name"
|
|
367
|
+
]
|
|
368
|
+
},
|
|
369
|
+
"Addresses": {
|
|
370
|
+
"anyOf": [
|
|
371
|
+
{
|
|
372
|
+
"anyOf": [
|
|
373
|
+
{
|
|
374
|
+
"type": "string"
|
|
375
|
+
},
|
|
376
|
+
{
|
|
377
|
+
"type": "integer",
|
|
378
|
+
"format": "uint",
|
|
379
|
+
"minimum": 0
|
|
380
|
+
}
|
|
381
|
+
]
|
|
382
|
+
},
|
|
383
|
+
{
|
|
384
|
+
"type": "array",
|
|
385
|
+
"items": {
|
|
386
|
+
"anyOf": [
|
|
387
|
+
{
|
|
388
|
+
"type": "string"
|
|
389
|
+
},
|
|
390
|
+
{
|
|
391
|
+
"type": "integer",
|
|
392
|
+
"format": "uint",
|
|
393
|
+
"minimum": 0
|
|
394
|
+
}
|
|
395
|
+
]
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
]
|
|
399
|
+
},
|
|
400
|
+
"EventDecoder": {
|
|
401
|
+
"type": "string",
|
|
402
|
+
"enum": [
|
|
403
|
+
"viem",
|
|
404
|
+
"hypersync-client"
|
|
405
|
+
]
|
|
406
|
+
},
|
|
407
|
+
"FieldSelection": {
|
|
408
|
+
"type": "object",
|
|
409
|
+
"properties": {
|
|
410
|
+
"transaction_fields": {
|
|
411
|
+
"description": "Fields of a transaction to add to the event passed to handlers",
|
|
412
|
+
"type": [
|
|
413
|
+
"array",
|
|
414
|
+
"null"
|
|
415
|
+
],
|
|
416
|
+
"items": {
|
|
417
|
+
"$ref": "#/$defs/TransactionField"
|
|
418
|
+
}
|
|
419
|
+
},
|
|
420
|
+
"block_fields": {
|
|
421
|
+
"description": "Fields of a block to add to the event passed to handlers",
|
|
422
|
+
"type": [
|
|
423
|
+
"array",
|
|
424
|
+
"null"
|
|
425
|
+
],
|
|
426
|
+
"items": {
|
|
427
|
+
"$ref": "#/$defs/BlockField"
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
},
|
|
431
|
+
"additionalProperties": false
|
|
432
|
+
},
|
|
433
|
+
"TransactionField": {
|
|
434
|
+
"type": "string",
|
|
435
|
+
"enum": [
|
|
436
|
+
"transactionIndex",
|
|
437
|
+
"hash",
|
|
438
|
+
"from",
|
|
439
|
+
"to",
|
|
440
|
+
"gas",
|
|
441
|
+
"gasPrice",
|
|
442
|
+
"maxPriorityFeePerGas",
|
|
443
|
+
"maxFeePerGas",
|
|
444
|
+
"cumulativeGasUsed",
|
|
445
|
+
"effectiveGasPrice",
|
|
446
|
+
"gasUsed",
|
|
447
|
+
"input",
|
|
448
|
+
"nonce",
|
|
449
|
+
"value",
|
|
450
|
+
"v",
|
|
451
|
+
"r",
|
|
452
|
+
"s",
|
|
453
|
+
"contractAddress",
|
|
454
|
+
"logsBloom",
|
|
455
|
+
"root",
|
|
456
|
+
"status",
|
|
457
|
+
"yParity",
|
|
458
|
+
"chainId",
|
|
459
|
+
"maxFeePerBlobGas",
|
|
460
|
+
"blobVersionedHashes",
|
|
461
|
+
"kind",
|
|
462
|
+
"l1Fee",
|
|
463
|
+
"l1GasPrice",
|
|
464
|
+
"l1GasUsed",
|
|
465
|
+
"l1FeeScalar",
|
|
466
|
+
"gasUsedForL1"
|
|
467
|
+
]
|
|
468
|
+
},
|
|
469
|
+
"BlockField": {
|
|
470
|
+
"type": "string",
|
|
471
|
+
"enum": [
|
|
472
|
+
"parentHash",
|
|
473
|
+
"nonce",
|
|
474
|
+
"sha3Uncles",
|
|
475
|
+
"logsBloom",
|
|
476
|
+
"transactionsRoot",
|
|
477
|
+
"stateRoot",
|
|
478
|
+
"receiptsRoot",
|
|
479
|
+
"miner",
|
|
480
|
+
"difficulty",
|
|
481
|
+
"totalDifficulty",
|
|
482
|
+
"extraData",
|
|
483
|
+
"size",
|
|
484
|
+
"gasLimit",
|
|
485
|
+
"gasUsed",
|
|
486
|
+
"uncles",
|
|
487
|
+
"baseFeePerGas",
|
|
488
|
+
"blobGasUsed",
|
|
489
|
+
"excessBlobGas",
|
|
490
|
+
"parentBeaconBlockRoot",
|
|
491
|
+
"withdrawalsRoot",
|
|
492
|
+
"l1BlockNumber",
|
|
493
|
+
"sendCount",
|
|
494
|
+
"sendRoot",
|
|
495
|
+
"mixHash"
|
|
496
|
+
]
|
|
497
|
+
}
|
|
498
|
+
}
|
|
499
|
+
}
|
package/fuel.schema.json
CHANGED
|
@@ -11,6 +11,21 @@
|
|
|
11
11
|
"null"
|
|
12
12
|
]
|
|
13
13
|
},
|
|
14
|
+
"name": {
|
|
15
|
+
"description": "Name of the project",
|
|
16
|
+
"type": "string"
|
|
17
|
+
},
|
|
18
|
+
"ecosystem": {
|
|
19
|
+
"description": "Ecosystem of the project.",
|
|
20
|
+
"$ref": "#/$defs/EcosystemTag"
|
|
21
|
+
},
|
|
22
|
+
"schema": {
|
|
23
|
+
"description": "Custom path to schema.yaml file",
|
|
24
|
+
"type": [
|
|
25
|
+
"string",
|
|
26
|
+
"null"
|
|
27
|
+
]
|
|
28
|
+
},
|
|
14
29
|
"contracts": {
|
|
15
30
|
"description": "Global contract definitions that must contain all definitions except addresses. You can share a single handler/abi/event definitions for contracts across multiple chains.",
|
|
16
31
|
"type": [
|
|
@@ -21,14 +36,6 @@
|
|
|
21
36
|
"$ref": "#/$defs/GlobalContract_for_ContractConfig"
|
|
22
37
|
}
|
|
23
38
|
},
|
|
24
|
-
"ecosystem": {
|
|
25
|
-
"description": "Ecosystem of the project.",
|
|
26
|
-
"$ref": "#/$defs/EcosystemTag"
|
|
27
|
-
},
|
|
28
|
-
"name": {
|
|
29
|
-
"description": "Name of the project",
|
|
30
|
-
"type": "string"
|
|
31
|
-
},
|
|
32
39
|
"networks": {
|
|
33
40
|
"description": "Configuration of the blockchain networks that the project is deployed on.",
|
|
34
41
|
"type": "array",
|
|
@@ -36,10 +43,10 @@
|
|
|
36
43
|
"$ref": "#/$defs/Network"
|
|
37
44
|
}
|
|
38
45
|
},
|
|
39
|
-
"
|
|
40
|
-
"description": "
|
|
46
|
+
"raw_events": {
|
|
47
|
+
"description": "If true, the indexer will store the raw event data in the database. This is useful for debugging, but will increase the size of the database and the amount of time it takes to process events (default: false)",
|
|
41
48
|
"type": [
|
|
42
|
-
"
|
|
49
|
+
"boolean",
|
|
43
50
|
"null"
|
|
44
51
|
]
|
|
45
52
|
}
|
|
@@ -51,78 +58,33 @@
|
|
|
51
58
|
"networks"
|
|
52
59
|
],
|
|
53
60
|
"$defs": {
|
|
54
|
-
"Addresses": {
|
|
55
|
-
"anyOf": [
|
|
56
|
-
{
|
|
57
|
-
"anyOf": [
|
|
58
|
-
{
|
|
59
|
-
"type": "string"
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
"type": "integer",
|
|
63
|
-
"format": "uint",
|
|
64
|
-
"minimum": 0
|
|
65
|
-
}
|
|
66
|
-
]
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
"type": "array",
|
|
70
|
-
"items": {
|
|
71
|
-
"anyOf": [
|
|
72
|
-
{
|
|
73
|
-
"type": "string"
|
|
74
|
-
},
|
|
75
|
-
{
|
|
76
|
-
"type": "integer",
|
|
77
|
-
"format": "uint",
|
|
78
|
-
"minimum": 0
|
|
79
|
-
}
|
|
80
|
-
]
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
]
|
|
84
|
-
},
|
|
85
61
|
"EcosystemTag": {
|
|
86
62
|
"type": "string",
|
|
87
63
|
"enum": [
|
|
88
64
|
"fuel"
|
|
89
65
|
]
|
|
90
66
|
},
|
|
91
|
-
"
|
|
67
|
+
"GlobalContract_for_ContractConfig": {
|
|
92
68
|
"type": "object",
|
|
93
69
|
"properties": {
|
|
94
|
-
"logId": {
|
|
95
|
-
"type": [
|
|
96
|
-
"string",
|
|
97
|
-
"null"
|
|
98
|
-
]
|
|
99
|
-
},
|
|
100
70
|
"name": {
|
|
71
|
+
"description": "A unique project-wide name for this contract (no spaces)",
|
|
101
72
|
"type": "string"
|
|
102
|
-
}
|
|
103
|
-
},
|
|
104
|
-
"additionalProperties": false,
|
|
105
|
-
"required": [
|
|
106
|
-
"name"
|
|
107
|
-
]
|
|
108
|
-
},
|
|
109
|
-
"GlobalContract_for_ContractConfig": {
|
|
110
|
-
"type": "object",
|
|
111
|
-
"properties": {
|
|
73
|
+
},
|
|
112
74
|
"abi_file_path": {
|
|
75
|
+
"description": "Relative path (from config) to a json abi.",
|
|
76
|
+
"type": "string"
|
|
77
|
+
},
|
|
78
|
+
"handler": {
|
|
79
|
+
"description": "The relative path to a file where handlers are registered for the given contract",
|
|
113
80
|
"type": "string"
|
|
114
81
|
},
|
|
115
82
|
"events": {
|
|
83
|
+
"description": "A list of events that should be indexed on this contract",
|
|
116
84
|
"type": "array",
|
|
117
85
|
"items": {
|
|
118
86
|
"$ref": "#/$defs/EventConfig"
|
|
119
87
|
}
|
|
120
|
-
},
|
|
121
|
-
"handler": {
|
|
122
|
-
"type": "string"
|
|
123
|
-
},
|
|
124
|
-
"name": {
|
|
125
|
-
"type": "string"
|
|
126
88
|
}
|
|
127
89
|
},
|
|
128
90
|
"additionalProperties": false,
|
|
@@ -133,30 +95,65 @@
|
|
|
133
95
|
"events"
|
|
134
96
|
]
|
|
135
97
|
},
|
|
136
|
-
"
|
|
98
|
+
"EventConfig": {
|
|
137
99
|
"type": "object",
|
|
138
100
|
"properties": {
|
|
139
|
-
"
|
|
140
|
-
"
|
|
141
|
-
"
|
|
142
|
-
"$ref": "#/$defs/NetworkContract_for_ContractConfig"
|
|
143
|
-
}
|
|
101
|
+
"name": {
|
|
102
|
+
"description": "A reference to a struct in the ABI or a unique name for the provided log_id",
|
|
103
|
+
"type": "string"
|
|
144
104
|
},
|
|
145
|
-
"
|
|
105
|
+
"logId": {
|
|
106
|
+
"description": "A reference to a log_id in the ABI",
|
|
146
107
|
"type": [
|
|
147
|
-
"
|
|
108
|
+
"string",
|
|
148
109
|
"null"
|
|
149
|
-
]
|
|
150
|
-
|
|
151
|
-
|
|
110
|
+
]
|
|
111
|
+
}
|
|
112
|
+
},
|
|
113
|
+
"additionalProperties": false,
|
|
114
|
+
"required": [
|
|
115
|
+
"name"
|
|
116
|
+
]
|
|
117
|
+
},
|
|
118
|
+
"Network": {
|
|
119
|
+
"type": "object",
|
|
120
|
+
"properties": {
|
|
152
121
|
"id": {
|
|
122
|
+
"description": "Public chain/network id",
|
|
153
123
|
"type": "integer",
|
|
154
124
|
"format": "uint64",
|
|
155
125
|
"minimum": 0
|
|
156
126
|
},
|
|
157
127
|
"start_block": {
|
|
128
|
+
"description": "The block at which the indexer should start ingesting data",
|
|
158
129
|
"type": "integer",
|
|
159
130
|
"format": "int32"
|
|
131
|
+
},
|
|
132
|
+
"end_block": {
|
|
133
|
+
"description": "The block at which the indexer should terminate.",
|
|
134
|
+
"type": [
|
|
135
|
+
"integer",
|
|
136
|
+
"null"
|
|
137
|
+
],
|
|
138
|
+
"format": "int32"
|
|
139
|
+
},
|
|
140
|
+
"hyperfuel_config": {
|
|
141
|
+
"description": "Optional HyperFuel Config for additional fine-tuning",
|
|
142
|
+
"anyOf": [
|
|
143
|
+
{
|
|
144
|
+
"$ref": "#/$defs/HyperfuelConfig"
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
"type": "null"
|
|
148
|
+
}
|
|
149
|
+
]
|
|
150
|
+
},
|
|
151
|
+
"contracts": {
|
|
152
|
+
"description": "All the contracts that should be indexed on the given network",
|
|
153
|
+
"type": "array",
|
|
154
|
+
"items": {
|
|
155
|
+
"$ref": "#/$defs/NetworkContract_for_ContractConfig"
|
|
156
|
+
}
|
|
160
157
|
}
|
|
161
158
|
},
|
|
162
159
|
"additionalProperties": false,
|
|
@@ -166,32 +163,81 @@
|
|
|
166
163
|
"contracts"
|
|
167
164
|
]
|
|
168
165
|
},
|
|
166
|
+
"HyperfuelConfig": {
|
|
167
|
+
"type": "object",
|
|
168
|
+
"properties": {
|
|
169
|
+
"url": {
|
|
170
|
+
"description": "URL of the HyperFuel endpoint (default: The most stable HyperFuel endpoint for the network)",
|
|
171
|
+
"type": "string"
|
|
172
|
+
}
|
|
173
|
+
},
|
|
174
|
+
"additionalProperties": false,
|
|
175
|
+
"required": [
|
|
176
|
+
"url"
|
|
177
|
+
]
|
|
178
|
+
},
|
|
169
179
|
"NetworkContract_for_ContractConfig": {
|
|
170
180
|
"type": "object",
|
|
171
181
|
"properties": {
|
|
172
|
-
"
|
|
182
|
+
"name": {
|
|
183
|
+
"description": "A unique project-wide name for this contract if events and handler are defined OR a reference to the name of contract defined globally at the top level",
|
|
173
184
|
"type": "string"
|
|
174
185
|
},
|
|
175
186
|
"address": {
|
|
187
|
+
"description": "A single address or a list of addresses to be indexed. This can be left as null in the case where this contracts addresses will be registered dynamically.",
|
|
176
188
|
"$ref": "#/$defs/Addresses"
|
|
177
189
|
},
|
|
190
|
+
"abi_file_path": {
|
|
191
|
+
"description": "Relative path (from config) to a json abi.",
|
|
192
|
+
"type": "string"
|
|
193
|
+
},
|
|
194
|
+
"handler": {
|
|
195
|
+
"description": "The relative path to a file where handlers are registered for the given contract",
|
|
196
|
+
"type": "string"
|
|
197
|
+
},
|
|
178
198
|
"events": {
|
|
199
|
+
"description": "A list of events that should be indexed on this contract",
|
|
179
200
|
"type": "array",
|
|
180
201
|
"items": {
|
|
181
202
|
"$ref": "#/$defs/EventConfig"
|
|
182
203
|
}
|
|
183
|
-
},
|
|
184
|
-
"handler": {
|
|
185
|
-
"type": "string"
|
|
186
|
-
},
|
|
187
|
-
"name": {
|
|
188
|
-
"type": "string"
|
|
189
204
|
}
|
|
190
205
|
},
|
|
191
206
|
"additionalProperties": false,
|
|
192
207
|
"required": [
|
|
193
208
|
"name"
|
|
194
209
|
]
|
|
210
|
+
},
|
|
211
|
+
"Addresses": {
|
|
212
|
+
"anyOf": [
|
|
213
|
+
{
|
|
214
|
+
"anyOf": [
|
|
215
|
+
{
|
|
216
|
+
"type": "string"
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"type": "integer",
|
|
220
|
+
"format": "uint",
|
|
221
|
+
"minimum": 0
|
|
222
|
+
}
|
|
223
|
+
]
|
|
224
|
+
},
|
|
225
|
+
{
|
|
226
|
+
"type": "array",
|
|
227
|
+
"items": {
|
|
228
|
+
"anyOf": [
|
|
229
|
+
{
|
|
230
|
+
"type": "string"
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
"type": "integer",
|
|
234
|
+
"format": "uint",
|
|
235
|
+
"minimum": 0
|
|
236
|
+
}
|
|
237
|
+
]
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
]
|
|
195
241
|
}
|
|
196
242
|
}
|
|
197
243
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "envio",
|
|
3
|
-
"version": "v2.
|
|
3
|
+
"version": "v2.3.1",
|
|
4
4
|
"description": "A latency and sync speed optimized, developer friendly blockchain data indexer.",
|
|
5
5
|
"bin": "lib/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
},
|
|
13
13
|
"repository": {
|
|
14
14
|
"type": "git",
|
|
15
|
-
"url": "git+https://github.com/enviodev/
|
|
15
|
+
"url": "git+https://github.com/enviodev/hyperindex.git"
|
|
16
16
|
},
|
|
17
17
|
"keywords": [
|
|
18
18
|
"blockchain",
|
|
@@ -25,9 +25,9 @@
|
|
|
25
25
|
"author": "envio contributors <about@envio.dev>",
|
|
26
26
|
"license": "GPL-3.0",
|
|
27
27
|
"bugs": {
|
|
28
|
-
"url": "https://github.com/enviodev/
|
|
28
|
+
"url": "https://github.com/enviodev/hyperindex/issues"
|
|
29
29
|
},
|
|
30
|
-
"homepage": "https://
|
|
30
|
+
"homepage": "https://envio.dev",
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@types/node": "^18.11.18",
|
|
33
33
|
"@typescript-eslint/eslint-plugin": "^5.48.0",
|
|
@@ -36,11 +36,10 @@
|
|
|
36
36
|
"typescript": "^4.9.4"
|
|
37
37
|
},
|
|
38
38
|
"optionalDependencies": {
|
|
39
|
-
"envio-linux-x64": "v2.
|
|
40
|
-
"envio-linux-arm64": "v2.
|
|
41
|
-
"envio-darwin-x64": "v2.
|
|
42
|
-
"envio-darwin-arm64": "v2.
|
|
43
|
-
"envio-win32-x64": "v2.2.5-fuel"
|
|
39
|
+
"envio-linux-x64": "v2.3.1",
|
|
40
|
+
"envio-linux-arm64": "v2.3.1",
|
|
41
|
+
"envio-darwin-x64": "v2.3.1",
|
|
42
|
+
"envio-darwin-arm64": "v2.3.1"
|
|
44
43
|
},
|
|
45
44
|
"eslintConfig": {
|
|
46
45
|
"extends": [
|
|
@@ -58,6 +57,7 @@
|
|
|
58
57
|
},
|
|
59
58
|
"files": [
|
|
60
59
|
"lib",
|
|
60
|
+
"evm.schema.json",
|
|
61
61
|
"fuel.schema.json"
|
|
62
62
|
]
|
|
63
|
-
}
|
|
63
|
+
}
|