-
Notifications
You must be signed in to change notification settings - Fork 4
/
schema.js
53 lines (50 loc) · 1.17 KB
/
schema.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
import { f4 as W, f_ as C, f$ as h, g0 as Vr, f5 as ce, f6 as Se, qSe, fd as pr } from "./pages_catch-all.js"
const _t = W({
buys: C(),
sells: C(),
volumeUsdBuy: C(),
volumeUsdSell: C(),
amountBuy: h(),
amountSell: h(),
balanceAmount: h().nullable(),
balancePercentage: C().nullable(),
firstSwap: C(),
new: Vr()
})
const Dn = W({
logType: ce("swap"),
blockNumber: C(),
blockTimestamp: C(),
txnHash: h(),
maker: h().optional(),
makerScreener: _t.optional(),
logIndex: C(),
txnType: ce("buy").or(ce("sell")),
priceUsd: h().optional(),
volumeUsd: h().optional(),
amount0: h(),
amount1: h()
})
const Nn = W({
logType: ce("add").or(ce("remove")),
blockNumber: C(),
blockTimestamp: C(),
txnHash: h(),
maker: h().optional(),
makerScreener: _t.optional(),
logIndex: C(),
amount0: h(),
amount1: h()
})
const Hn = Dn.or(Nn)
const jn = W({
schemaVersion: h(),
baseTokenSymbol: h().optional(),
quoteTokenSymbol: h().optional(),
logs: Se(Hn).nullable()
})
const Ui = W({
schemaVersion: ce("4.0"),
pairs: Se(pr)
})
export {jn as logsSchema, Ui as searchSchema}