@0xsequence/indexer 1.9.11 → 1.9.12
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.
|
@@ -18,9 +18,9 @@ function _extends() {
|
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
/* eslint-disable */
|
|
21
|
-
// sequence-indexer v0.4.0
|
|
21
|
+
// sequence-indexer v0.4.0 83530970d81179658f6546c87fc4352280dbd287
|
|
22
22
|
// --
|
|
23
|
-
// Code generated by webrpc-gen@v0.
|
|
23
|
+
// Code generated by webrpc-gen@v0.14.0-dev with typescript@v0.10.0 generator. DO NOT EDIT.
|
|
24
24
|
//
|
|
25
25
|
// webrpc-gen -schema=indexer.ridl -target=typescript@v0.10.0 -client -out=./clients/indexer.gen.ts
|
|
26
26
|
|
|
@@ -31,7 +31,7 @@ const WebRPCVersion = 'v1';
|
|
|
31
31
|
const WebRPCSchemaVersion = 'v0.4.0';
|
|
32
32
|
|
|
33
33
|
// Schema hash generated from your RIDL schema
|
|
34
|
-
const WebRPCSchemaHash = '
|
|
34
|
+
const WebRPCSchemaHash = '83530970d81179658f6546c87fc4352280dbd287';
|
|
35
35
|
|
|
36
36
|
//
|
|
37
37
|
// Types
|
|
@@ -39,6 +39,7 @@ const WebRPCSchemaHash = 'b53b368f85445da25796f8cc90459c61425c13f4';
|
|
|
39
39
|
|
|
40
40
|
let ContractType = /*#__PURE__*/function (ContractType) {
|
|
41
41
|
ContractType["UNKNOWN"] = "UNKNOWN";
|
|
42
|
+
ContractType["NATIVE"] = "NATIVE";
|
|
42
43
|
ContractType["ERC20"] = "ERC20";
|
|
43
44
|
ContractType["ERC721"] = "ERC721";
|
|
44
45
|
ContractType["ERC1155"] = "ERC1155";
|
|
@@ -46,6 +47,7 @@ let ContractType = /*#__PURE__*/function (ContractType) {
|
|
|
46
47
|
ContractType["ERC20_BRIDGE"] = "ERC20_BRIDGE";
|
|
47
48
|
ContractType["ERC721_BRIDGE"] = "ERC721_BRIDGE";
|
|
48
49
|
ContractType["ERC1155_BRIDGE"] = "ERC1155_BRIDGE";
|
|
50
|
+
ContractType["SEQ_MARKETPLACE"] = "SEQ_MARKETPLACE";
|
|
49
51
|
return ContractType;
|
|
50
52
|
}({});
|
|
51
53
|
let EventLogType = /*#__PURE__*/function (EventLogType) {
|
|
@@ -61,6 +63,12 @@ let EventLogDataType = /*#__PURE__*/function (EventLogDataType) {
|
|
|
61
63
|
EventLogDataType["SEQUENCE_TXN"] = "SEQUENCE_TXN";
|
|
62
64
|
return EventLogDataType;
|
|
63
65
|
}({});
|
|
66
|
+
let OrderStatus = /*#__PURE__*/function (OrderStatus) {
|
|
67
|
+
OrderStatus["OPEN"] = "OPEN";
|
|
68
|
+
OrderStatus["CLOSED"] = "CLOSED";
|
|
69
|
+
OrderStatus["CANCELLED"] = "CANCELLED";
|
|
70
|
+
return OrderStatus;
|
|
71
|
+
}({});
|
|
64
72
|
let TxnTransferType = /*#__PURE__*/function (TxnTransferType) {
|
|
65
73
|
TxnTransferType["UNKNOWN"] = "UNKNOWN";
|
|
66
74
|
TxnTransferType["SEND"] = "SEND";
|
|
@@ -202,6 +210,25 @@ class Indexer {
|
|
|
202
210
|
});
|
|
203
211
|
});
|
|
204
212
|
};
|
|
213
|
+
this.getOrderbookOrders = (args, headers) => {
|
|
214
|
+
return this.fetch(this.url('GetOrderbookOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
215
|
+
return buildResponse(res).then(_data => {
|
|
216
|
+
return {
|
|
217
|
+
page: _data.page,
|
|
218
|
+
orders: _data.orders
|
|
219
|
+
};
|
|
220
|
+
});
|
|
221
|
+
});
|
|
222
|
+
};
|
|
223
|
+
this.getTopOrders = (args, headers) => {
|
|
224
|
+
return this.fetch(this.url('GetTopOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
225
|
+
return buildResponse(res).then(_data => {
|
|
226
|
+
return {
|
|
227
|
+
orders: _data.orders
|
|
228
|
+
};
|
|
229
|
+
});
|
|
230
|
+
});
|
|
231
|
+
};
|
|
205
232
|
this.fetchTransactionReceiptWithFilter = (args, headers) => {
|
|
206
233
|
return this.fetch(this.url('FetchTransactionReceiptWithFilter'), createHTTPRequest(args, headers)).then(res => {
|
|
207
234
|
return buildResponse(res).then(_data => {
|
|
@@ -323,6 +350,7 @@ exports.ContractType = ContractType;
|
|
|
323
350
|
exports.EventLogDataType = EventLogDataType;
|
|
324
351
|
exports.EventLogType = EventLogType;
|
|
325
352
|
exports.Indexer = Indexer;
|
|
353
|
+
exports.OrderStatus = OrderStatus;
|
|
326
354
|
exports.SequenceIndexer = SequenceIndexer;
|
|
327
355
|
exports.SortOrder = SortOrder;
|
|
328
356
|
exports.TransactionStatus = TransactionStatus;
|
|
@@ -18,9 +18,9 @@ function _extends() {
|
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
/* eslint-disable */
|
|
21
|
-
// sequence-indexer v0.4.0
|
|
21
|
+
// sequence-indexer v0.4.0 83530970d81179658f6546c87fc4352280dbd287
|
|
22
22
|
// --
|
|
23
|
-
// Code generated by webrpc-gen@v0.
|
|
23
|
+
// Code generated by webrpc-gen@v0.14.0-dev with typescript@v0.10.0 generator. DO NOT EDIT.
|
|
24
24
|
//
|
|
25
25
|
// webrpc-gen -schema=indexer.ridl -target=typescript@v0.10.0 -client -out=./clients/indexer.gen.ts
|
|
26
26
|
|
|
@@ -31,7 +31,7 @@ const WebRPCVersion = 'v1';
|
|
|
31
31
|
const WebRPCSchemaVersion = 'v0.4.0';
|
|
32
32
|
|
|
33
33
|
// Schema hash generated from your RIDL schema
|
|
34
|
-
const WebRPCSchemaHash = '
|
|
34
|
+
const WebRPCSchemaHash = '83530970d81179658f6546c87fc4352280dbd287';
|
|
35
35
|
|
|
36
36
|
//
|
|
37
37
|
// Types
|
|
@@ -39,6 +39,7 @@ const WebRPCSchemaHash = 'b53b368f85445da25796f8cc90459c61425c13f4';
|
|
|
39
39
|
|
|
40
40
|
let ContractType = /*#__PURE__*/function (ContractType) {
|
|
41
41
|
ContractType["UNKNOWN"] = "UNKNOWN";
|
|
42
|
+
ContractType["NATIVE"] = "NATIVE";
|
|
42
43
|
ContractType["ERC20"] = "ERC20";
|
|
43
44
|
ContractType["ERC721"] = "ERC721";
|
|
44
45
|
ContractType["ERC1155"] = "ERC1155";
|
|
@@ -46,6 +47,7 @@ let ContractType = /*#__PURE__*/function (ContractType) {
|
|
|
46
47
|
ContractType["ERC20_BRIDGE"] = "ERC20_BRIDGE";
|
|
47
48
|
ContractType["ERC721_BRIDGE"] = "ERC721_BRIDGE";
|
|
48
49
|
ContractType["ERC1155_BRIDGE"] = "ERC1155_BRIDGE";
|
|
50
|
+
ContractType["SEQ_MARKETPLACE"] = "SEQ_MARKETPLACE";
|
|
49
51
|
return ContractType;
|
|
50
52
|
}({});
|
|
51
53
|
let EventLogType = /*#__PURE__*/function (EventLogType) {
|
|
@@ -61,6 +63,12 @@ let EventLogDataType = /*#__PURE__*/function (EventLogDataType) {
|
|
|
61
63
|
EventLogDataType["SEQUENCE_TXN"] = "SEQUENCE_TXN";
|
|
62
64
|
return EventLogDataType;
|
|
63
65
|
}({});
|
|
66
|
+
let OrderStatus = /*#__PURE__*/function (OrderStatus) {
|
|
67
|
+
OrderStatus["OPEN"] = "OPEN";
|
|
68
|
+
OrderStatus["CLOSED"] = "CLOSED";
|
|
69
|
+
OrderStatus["CANCELLED"] = "CANCELLED";
|
|
70
|
+
return OrderStatus;
|
|
71
|
+
}({});
|
|
64
72
|
let TxnTransferType = /*#__PURE__*/function (TxnTransferType) {
|
|
65
73
|
TxnTransferType["UNKNOWN"] = "UNKNOWN";
|
|
66
74
|
TxnTransferType["SEND"] = "SEND";
|
|
@@ -202,6 +210,25 @@ class Indexer {
|
|
|
202
210
|
});
|
|
203
211
|
});
|
|
204
212
|
};
|
|
213
|
+
this.getOrderbookOrders = (args, headers) => {
|
|
214
|
+
return this.fetch(this.url('GetOrderbookOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
215
|
+
return buildResponse(res).then(_data => {
|
|
216
|
+
return {
|
|
217
|
+
page: _data.page,
|
|
218
|
+
orders: _data.orders
|
|
219
|
+
};
|
|
220
|
+
});
|
|
221
|
+
});
|
|
222
|
+
};
|
|
223
|
+
this.getTopOrders = (args, headers) => {
|
|
224
|
+
return this.fetch(this.url('GetTopOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
225
|
+
return buildResponse(res).then(_data => {
|
|
226
|
+
return {
|
|
227
|
+
orders: _data.orders
|
|
228
|
+
};
|
|
229
|
+
});
|
|
230
|
+
});
|
|
231
|
+
};
|
|
205
232
|
this.fetchTransactionReceiptWithFilter = (args, headers) => {
|
|
206
233
|
return this.fetch(this.url('FetchTransactionReceiptWithFilter'), createHTTPRequest(args, headers)).then(res => {
|
|
207
234
|
return buildResponse(res).then(_data => {
|
|
@@ -323,6 +350,7 @@ exports.ContractType = ContractType;
|
|
|
323
350
|
exports.EventLogDataType = EventLogDataType;
|
|
324
351
|
exports.EventLogType = EventLogType;
|
|
325
352
|
exports.Indexer = Indexer;
|
|
353
|
+
exports.OrderStatus = OrderStatus;
|
|
326
354
|
exports.SequenceIndexer = SequenceIndexer;
|
|
327
355
|
exports.SortOrder = SortOrder;
|
|
328
356
|
exports.TransactionStatus = TransactionStatus;
|
|
@@ -14,9 +14,9 @@ function _extends() {
|
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
/* eslint-disable */
|
|
17
|
-
// sequence-indexer v0.4.0
|
|
17
|
+
// sequence-indexer v0.4.0 83530970d81179658f6546c87fc4352280dbd287
|
|
18
18
|
// --
|
|
19
|
-
// Code generated by webrpc-gen@v0.
|
|
19
|
+
// Code generated by webrpc-gen@v0.14.0-dev with typescript@v0.10.0 generator. DO NOT EDIT.
|
|
20
20
|
//
|
|
21
21
|
// webrpc-gen -schema=indexer.ridl -target=typescript@v0.10.0 -client -out=./clients/indexer.gen.ts
|
|
22
22
|
|
|
@@ -27,7 +27,7 @@ const WebRPCVersion = 'v1';
|
|
|
27
27
|
const WebRPCSchemaVersion = 'v0.4.0';
|
|
28
28
|
|
|
29
29
|
// Schema hash generated from your RIDL schema
|
|
30
|
-
const WebRPCSchemaHash = '
|
|
30
|
+
const WebRPCSchemaHash = '83530970d81179658f6546c87fc4352280dbd287';
|
|
31
31
|
|
|
32
32
|
//
|
|
33
33
|
// Types
|
|
@@ -35,6 +35,7 @@ const WebRPCSchemaHash = 'b53b368f85445da25796f8cc90459c61425c13f4';
|
|
|
35
35
|
|
|
36
36
|
let ContractType = /*#__PURE__*/function (ContractType) {
|
|
37
37
|
ContractType["UNKNOWN"] = "UNKNOWN";
|
|
38
|
+
ContractType["NATIVE"] = "NATIVE";
|
|
38
39
|
ContractType["ERC20"] = "ERC20";
|
|
39
40
|
ContractType["ERC721"] = "ERC721";
|
|
40
41
|
ContractType["ERC1155"] = "ERC1155";
|
|
@@ -42,6 +43,7 @@ let ContractType = /*#__PURE__*/function (ContractType) {
|
|
|
42
43
|
ContractType["ERC20_BRIDGE"] = "ERC20_BRIDGE";
|
|
43
44
|
ContractType["ERC721_BRIDGE"] = "ERC721_BRIDGE";
|
|
44
45
|
ContractType["ERC1155_BRIDGE"] = "ERC1155_BRIDGE";
|
|
46
|
+
ContractType["SEQ_MARKETPLACE"] = "SEQ_MARKETPLACE";
|
|
45
47
|
return ContractType;
|
|
46
48
|
}({});
|
|
47
49
|
let EventLogType = /*#__PURE__*/function (EventLogType) {
|
|
@@ -57,6 +59,12 @@ let EventLogDataType = /*#__PURE__*/function (EventLogDataType) {
|
|
|
57
59
|
EventLogDataType["SEQUENCE_TXN"] = "SEQUENCE_TXN";
|
|
58
60
|
return EventLogDataType;
|
|
59
61
|
}({});
|
|
62
|
+
let OrderStatus = /*#__PURE__*/function (OrderStatus) {
|
|
63
|
+
OrderStatus["OPEN"] = "OPEN";
|
|
64
|
+
OrderStatus["CLOSED"] = "CLOSED";
|
|
65
|
+
OrderStatus["CANCELLED"] = "CANCELLED";
|
|
66
|
+
return OrderStatus;
|
|
67
|
+
}({});
|
|
60
68
|
let TxnTransferType = /*#__PURE__*/function (TxnTransferType) {
|
|
61
69
|
TxnTransferType["UNKNOWN"] = "UNKNOWN";
|
|
62
70
|
TxnTransferType["SEND"] = "SEND";
|
|
@@ -198,6 +206,25 @@ class Indexer {
|
|
|
198
206
|
});
|
|
199
207
|
});
|
|
200
208
|
};
|
|
209
|
+
this.getOrderbookOrders = (args, headers) => {
|
|
210
|
+
return this.fetch(this.url('GetOrderbookOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
211
|
+
return buildResponse(res).then(_data => {
|
|
212
|
+
return {
|
|
213
|
+
page: _data.page,
|
|
214
|
+
orders: _data.orders
|
|
215
|
+
};
|
|
216
|
+
});
|
|
217
|
+
});
|
|
218
|
+
};
|
|
219
|
+
this.getTopOrders = (args, headers) => {
|
|
220
|
+
return this.fetch(this.url('GetTopOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
221
|
+
return buildResponse(res).then(_data => {
|
|
222
|
+
return {
|
|
223
|
+
orders: _data.orders
|
|
224
|
+
};
|
|
225
|
+
});
|
|
226
|
+
});
|
|
227
|
+
};
|
|
201
228
|
this.fetchTransactionReceiptWithFilter = (args, headers) => {
|
|
202
229
|
return this.fetch(this.url('FetchTransactionReceiptWithFilter'), createHTTPRequest(args, headers)).then(res => {
|
|
203
230
|
return buildResponse(res).then(_data => {
|
|
@@ -315,4 +342,4 @@ class SequenceIndexer extends Indexer {
|
|
|
315
342
|
}
|
|
316
343
|
}
|
|
317
344
|
|
|
318
|
-
export { ContractType, EventLogDataType, EventLogType, Indexer, SequenceIndexer, SortOrder, TransactionStatus, TransactionType, TxnTransferType, WebRPCSchemaHash, WebRPCSchemaVersion, WebRPCVersion };
|
|
345
|
+
export { ContractType, EventLogDataType, EventLogType, Indexer, OrderStatus, SequenceIndexer, SortOrder, TransactionStatus, TransactionType, TxnTransferType, WebRPCSchemaHash, WebRPCSchemaVersion, WebRPCVersion };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const WebRPCVersion = "v1";
|
|
2
2
|
export declare const WebRPCSchemaVersion = "v0.4.0";
|
|
3
|
-
export declare const WebRPCSchemaHash = "
|
|
3
|
+
export declare const WebRPCSchemaHash = "83530970d81179658f6546c87fc4352280dbd287";
|
|
4
4
|
export interface ContractInfo {
|
|
5
5
|
chainId: number;
|
|
6
6
|
address: string;
|
|
@@ -47,13 +47,15 @@ export interface TokenMetadata {
|
|
|
47
47
|
}
|
|
48
48
|
export declare enum ContractType {
|
|
49
49
|
UNKNOWN = "UNKNOWN",
|
|
50
|
+
NATIVE = "NATIVE",
|
|
50
51
|
ERC20 = "ERC20",
|
|
51
52
|
ERC721 = "ERC721",
|
|
52
53
|
ERC1155 = "ERC1155",
|
|
53
54
|
SEQUENCE_WALLET = "SEQUENCE_WALLET",
|
|
54
55
|
ERC20_BRIDGE = "ERC20_BRIDGE",
|
|
55
56
|
ERC721_BRIDGE = "ERC721_BRIDGE",
|
|
56
|
-
ERC1155_BRIDGE = "ERC1155_BRIDGE"
|
|
57
|
+
ERC1155_BRIDGE = "ERC1155_BRIDGE",
|
|
58
|
+
SEQ_MARKETPLACE = "SEQ_MARKETPLACE"
|
|
57
59
|
}
|
|
58
60
|
export declare enum EventLogType {
|
|
59
61
|
UNKNOWN = "UNKNOWN",
|
|
@@ -66,6 +68,11 @@ export declare enum EventLogDataType {
|
|
|
66
68
|
NATIVE_TOKEN_TRANSFER = "NATIVE_TOKEN_TRANSFER",
|
|
67
69
|
SEQUENCE_TXN = "SEQUENCE_TXN"
|
|
68
70
|
}
|
|
71
|
+
export declare enum OrderStatus {
|
|
72
|
+
OPEN = "OPEN",
|
|
73
|
+
CLOSED = "CLOSED",
|
|
74
|
+
CANCELLED = "CANCELLED"
|
|
75
|
+
}
|
|
69
76
|
export declare enum TxnTransferType {
|
|
70
77
|
UNKNOWN = "UNKNOWN",
|
|
71
78
|
SEND = "SEND",
|
|
@@ -101,6 +108,16 @@ export interface RuntimeStatus {
|
|
|
101
108
|
chainID: number;
|
|
102
109
|
checks: RuntimeChecks;
|
|
103
110
|
}
|
|
111
|
+
export interface WALWriterRuntimeStatus {
|
|
112
|
+
healthOK: boolean;
|
|
113
|
+
startTime: string;
|
|
114
|
+
uptime: number;
|
|
115
|
+
ver: string;
|
|
116
|
+
branch: string;
|
|
117
|
+
commitHash: string;
|
|
118
|
+
chainID: number;
|
|
119
|
+
percentWALWritten: number;
|
|
120
|
+
}
|
|
104
121
|
export interface RuntimeChecks {
|
|
105
122
|
running: boolean;
|
|
106
123
|
cgoEnabled: boolean;
|
|
@@ -109,10 +126,14 @@ export interface RuntimeChecks {
|
|
|
109
126
|
percentIndexed: number;
|
|
110
127
|
lastBlockNum: number;
|
|
111
128
|
lastBlockNumWithState: number;
|
|
129
|
+
bloomStatus: BloomStatus;
|
|
112
130
|
bond: Bond;
|
|
131
|
+
diskUsage: string;
|
|
113
132
|
}
|
|
114
133
|
export interface Bond {
|
|
115
134
|
pebble: PebbleMetrics;
|
|
135
|
+
estimatedDiskUsagePerTable: any;
|
|
136
|
+
estimatedDiskUsageTotal: string;
|
|
116
137
|
}
|
|
117
138
|
export interface PebbleMetrics {
|
|
118
139
|
compactionCount: number;
|
|
@@ -121,6 +142,11 @@ export interface PebbleMetrics {
|
|
|
121
142
|
compactionNumInProgress: number;
|
|
122
143
|
compactionMarkedFiles: number;
|
|
123
144
|
}
|
|
145
|
+
export interface BloomStatus {
|
|
146
|
+
enabled: boolean;
|
|
147
|
+
initialized: boolean;
|
|
148
|
+
bloomInitElapsedTime: string;
|
|
149
|
+
}
|
|
124
150
|
export interface EtherBalance {
|
|
125
151
|
accountAddress: string;
|
|
126
152
|
balanceWei: string;
|
|
@@ -167,6 +193,27 @@ export interface TokenBalance {
|
|
|
167
193
|
contractInfo?: ContractInfo;
|
|
168
194
|
tokenMetadata?: TokenMetadata;
|
|
169
195
|
}
|
|
196
|
+
export interface OrderbookOrder {
|
|
197
|
+
orderId: string;
|
|
198
|
+
tokenContract: string;
|
|
199
|
+
tokenId: string;
|
|
200
|
+
isListing: boolean;
|
|
201
|
+
quantity: string;
|
|
202
|
+
quantityRemaining: string;
|
|
203
|
+
currencyAddress: string;
|
|
204
|
+
pricePerToken: string;
|
|
205
|
+
expiry: string;
|
|
206
|
+
orderStatus: OrderStatus;
|
|
207
|
+
createdBy: string;
|
|
208
|
+
createdAt: number;
|
|
209
|
+
orderbookContractAddress: string;
|
|
210
|
+
}
|
|
211
|
+
export interface OrderbookOrderFilter {
|
|
212
|
+
isListing?: boolean;
|
|
213
|
+
userAddress?: string;
|
|
214
|
+
tokenIds: Array<string>;
|
|
215
|
+
excludeUserAddress?: string;
|
|
216
|
+
}
|
|
170
217
|
export interface TokenHistory {
|
|
171
218
|
blockNumber: number;
|
|
172
219
|
blockHash: string;
|
|
@@ -279,6 +326,7 @@ export interface WebhookEventFilter {
|
|
|
279
326
|
}
|
|
280
327
|
export interface MetadataOptions {
|
|
281
328
|
verifiedOnly?: boolean;
|
|
329
|
+
unverifiedOnly?: boolean;
|
|
282
330
|
includeContracts?: Array<string>;
|
|
283
331
|
}
|
|
284
332
|
export interface Indexer {
|
|
@@ -294,6 +342,8 @@ export interface Indexer {
|
|
|
294
342
|
getTransactionHistory(args: GetTransactionHistoryArgs, headers?: object): Promise<GetTransactionHistoryReturn>;
|
|
295
343
|
syncBalance(args: SyncBalanceArgs, headers?: object): Promise<SyncBalanceReturn>;
|
|
296
344
|
fetchTransactionReceipt(args: FetchTransactionReceiptArgs, headers?: object): Promise<FetchTransactionReceiptReturn>;
|
|
345
|
+
getOrderbookOrders(args: GetOrderbookOrdersArgs, headers?: object): Promise<GetOrderbookOrdersReturn>;
|
|
346
|
+
getTopOrders(args: GetTopOrdersArgs, headers?: object): Promise<GetTopOrdersReturn>;
|
|
297
347
|
fetchTransactionReceiptWithFilter(args: FetchTransactionReceiptWithFilterArgs, headers?: object): Promise<FetchTransactionReceiptWithFilterReturn>;
|
|
298
348
|
getAllWebhookListeners(args: GetAllWebhookListenersArgs, headers?: object): Promise<GetAllWebhookListenersReturn>;
|
|
299
349
|
getWebhookListener(args: GetWebhookListenerArgs, headers?: object): Promise<GetWebhookListenerReturn>;
|
|
@@ -333,6 +383,7 @@ export interface GetTokenBalancesArgs {
|
|
|
333
383
|
tokenID?: string;
|
|
334
384
|
includeMetadata?: boolean;
|
|
335
385
|
metadataOptions?: MetadataOptions;
|
|
386
|
+
includeCollectionTokens?: boolean;
|
|
336
387
|
page?: Page;
|
|
337
388
|
}
|
|
338
389
|
export interface GetTokenBalancesReturn {
|
|
@@ -396,6 +447,31 @@ export interface FetchTransactionReceiptArgs {
|
|
|
396
447
|
export interface FetchTransactionReceiptReturn {
|
|
397
448
|
receipt: TransactionReceipt;
|
|
398
449
|
}
|
|
450
|
+
export interface GetOrderbookOrdersArgs {
|
|
451
|
+
page?: Page;
|
|
452
|
+
orderbookContractAddress: string;
|
|
453
|
+
collectionAddress: string;
|
|
454
|
+
currencyAddresses: Array<string>;
|
|
455
|
+
filters: Array<OrderbookOrderFilter>;
|
|
456
|
+
orderStatuses: Array<OrderStatus>;
|
|
457
|
+
beforeExpiryTimestamp: number;
|
|
458
|
+
}
|
|
459
|
+
export interface GetOrderbookOrdersReturn {
|
|
460
|
+
page?: Page;
|
|
461
|
+
orders: Array<OrderbookOrder>;
|
|
462
|
+
}
|
|
463
|
+
export interface GetTopOrdersArgs {
|
|
464
|
+
orderbookContractAddress: string;
|
|
465
|
+
collectionAddress: string;
|
|
466
|
+
currencyAddresses: Array<string>;
|
|
467
|
+
tokenIDs: Array<string>;
|
|
468
|
+
isListing: boolean;
|
|
469
|
+
priceSort: SortOrder;
|
|
470
|
+
excludeUser?: string;
|
|
471
|
+
}
|
|
472
|
+
export interface GetTopOrdersReturn {
|
|
473
|
+
orders: Array<OrderbookOrder>;
|
|
474
|
+
}
|
|
399
475
|
export interface FetchTransactionReceiptWithFilterArgs {
|
|
400
476
|
filter: Filter;
|
|
401
477
|
maxBlockWait?: number;
|
|
@@ -457,6 +533,8 @@ export declare class Indexer implements Indexer {
|
|
|
457
533
|
getTransactionHistory: (args: GetTransactionHistoryArgs, headers?: object | undefined) => Promise<GetTransactionHistoryReturn>;
|
|
458
534
|
syncBalance: (args: SyncBalanceArgs, headers?: object | undefined) => Promise<SyncBalanceReturn>;
|
|
459
535
|
fetchTransactionReceipt: (args: FetchTransactionReceiptArgs, headers?: object | undefined) => Promise<FetchTransactionReceiptReturn>;
|
|
536
|
+
getOrderbookOrders: (args: GetOrderbookOrdersArgs, headers?: object | undefined) => Promise<GetOrderbookOrdersReturn>;
|
|
537
|
+
getTopOrders: (args: GetTopOrdersArgs, headers?: object | undefined) => Promise<GetTopOrdersReturn>;
|
|
460
538
|
fetchTransactionReceiptWithFilter: (args: FetchTransactionReceiptWithFilterArgs, headers?: object | undefined) => Promise<FetchTransactionReceiptWithFilterReturn>;
|
|
461
539
|
getAllWebhookListeners: (args: GetAllWebhookListenersArgs, headers?: object | undefined) => Promise<GetAllWebhookListenersReturn>;
|
|
462
540
|
getWebhookListener: (args: GetWebhookListenerArgs, headers?: object | undefined) => Promise<GetWebhookListenerReturn>;
|
package/package.json
CHANGED
package/src/indexer.gen.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
// sequence-indexer v0.4.0
|
|
2
|
+
// sequence-indexer v0.4.0 83530970d81179658f6546c87fc4352280dbd287
|
|
3
3
|
// --
|
|
4
|
-
// Code generated by webrpc-gen@v0.
|
|
4
|
+
// Code generated by webrpc-gen@v0.14.0-dev with typescript@v0.10.0 generator. DO NOT EDIT.
|
|
5
5
|
//
|
|
6
6
|
// webrpc-gen -schema=indexer.ridl -target=typescript@v0.10.0 -client -out=./clients/indexer.gen.ts
|
|
7
7
|
|
|
@@ -12,7 +12,7 @@ export const WebRPCVersion = 'v1'
|
|
|
12
12
|
export const WebRPCSchemaVersion = 'v0.4.0'
|
|
13
13
|
|
|
14
14
|
// Schema hash generated from your RIDL schema
|
|
15
|
-
export const WebRPCSchemaHash = '
|
|
15
|
+
export const WebRPCSchemaHash = '83530970d81179658f6546c87fc4352280dbd287'
|
|
16
16
|
|
|
17
17
|
//
|
|
18
18
|
// Types
|
|
@@ -63,13 +63,15 @@ export interface TokenMetadata {
|
|
|
63
63
|
}
|
|
64
64
|
export enum ContractType {
|
|
65
65
|
UNKNOWN = 'UNKNOWN',
|
|
66
|
+
NATIVE = 'NATIVE',
|
|
66
67
|
ERC20 = 'ERC20',
|
|
67
68
|
ERC721 = 'ERC721',
|
|
68
69
|
ERC1155 = 'ERC1155',
|
|
69
70
|
SEQUENCE_WALLET = 'SEQUENCE_WALLET',
|
|
70
71
|
ERC20_BRIDGE = 'ERC20_BRIDGE',
|
|
71
72
|
ERC721_BRIDGE = 'ERC721_BRIDGE',
|
|
72
|
-
ERC1155_BRIDGE = 'ERC1155_BRIDGE'
|
|
73
|
+
ERC1155_BRIDGE = 'ERC1155_BRIDGE',
|
|
74
|
+
SEQ_MARKETPLACE = 'SEQ_MARKETPLACE'
|
|
73
75
|
}
|
|
74
76
|
export enum EventLogType {
|
|
75
77
|
UNKNOWN = 'UNKNOWN',
|
|
@@ -82,6 +84,11 @@ export enum EventLogDataType {
|
|
|
82
84
|
NATIVE_TOKEN_TRANSFER = 'NATIVE_TOKEN_TRANSFER',
|
|
83
85
|
SEQUENCE_TXN = 'SEQUENCE_TXN'
|
|
84
86
|
}
|
|
87
|
+
export enum OrderStatus {
|
|
88
|
+
OPEN = 'OPEN',
|
|
89
|
+
CLOSED = 'CLOSED',
|
|
90
|
+
CANCELLED = 'CANCELLED'
|
|
91
|
+
}
|
|
85
92
|
export enum TxnTransferType {
|
|
86
93
|
UNKNOWN = 'UNKNOWN',
|
|
87
94
|
SEND = 'SEND',
|
|
@@ -120,6 +127,17 @@ export interface RuntimeStatus {
|
|
|
120
127
|
checks: RuntimeChecks
|
|
121
128
|
}
|
|
122
129
|
|
|
130
|
+
export interface WALWriterRuntimeStatus {
|
|
131
|
+
healthOK: boolean
|
|
132
|
+
startTime: string
|
|
133
|
+
uptime: number
|
|
134
|
+
ver: string
|
|
135
|
+
branch: string
|
|
136
|
+
commitHash: string
|
|
137
|
+
chainID: number
|
|
138
|
+
percentWALWritten: number
|
|
139
|
+
}
|
|
140
|
+
|
|
123
141
|
export interface RuntimeChecks {
|
|
124
142
|
running: boolean
|
|
125
143
|
cgoEnabled: boolean
|
|
@@ -128,11 +146,15 @@ export interface RuntimeChecks {
|
|
|
128
146
|
percentIndexed: number
|
|
129
147
|
lastBlockNum: number
|
|
130
148
|
lastBlockNumWithState: number
|
|
149
|
+
bloomStatus: BloomStatus
|
|
131
150
|
bond: Bond
|
|
151
|
+
diskUsage: string
|
|
132
152
|
}
|
|
133
153
|
|
|
134
154
|
export interface Bond {
|
|
135
155
|
pebble: PebbleMetrics
|
|
156
|
+
estimatedDiskUsagePerTable: any
|
|
157
|
+
estimatedDiskUsageTotal: string
|
|
136
158
|
}
|
|
137
159
|
|
|
138
160
|
export interface PebbleMetrics {
|
|
@@ -143,6 +165,12 @@ export interface PebbleMetrics {
|
|
|
143
165
|
compactionMarkedFiles: number
|
|
144
166
|
}
|
|
145
167
|
|
|
168
|
+
export interface BloomStatus {
|
|
169
|
+
enabled: boolean
|
|
170
|
+
initialized: boolean
|
|
171
|
+
bloomInitElapsedTime: string
|
|
172
|
+
}
|
|
173
|
+
|
|
146
174
|
export interface EtherBalance {
|
|
147
175
|
accountAddress: string
|
|
148
176
|
balanceWei: string
|
|
@@ -196,6 +224,29 @@ export interface TokenBalance {
|
|
|
196
224
|
tokenMetadata?: TokenMetadata
|
|
197
225
|
}
|
|
198
226
|
|
|
227
|
+
export interface OrderbookOrder {
|
|
228
|
+
orderId: string
|
|
229
|
+
tokenContract: string
|
|
230
|
+
tokenId: string
|
|
231
|
+
isListing: boolean
|
|
232
|
+
quantity: string
|
|
233
|
+
quantityRemaining: string
|
|
234
|
+
currencyAddress: string
|
|
235
|
+
pricePerToken: string
|
|
236
|
+
expiry: string
|
|
237
|
+
orderStatus: OrderStatus
|
|
238
|
+
createdBy: string
|
|
239
|
+
createdAt: number
|
|
240
|
+
orderbookContractAddress: string
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
export interface OrderbookOrderFilter {
|
|
244
|
+
isListing?: boolean
|
|
245
|
+
userAddress?: string
|
|
246
|
+
tokenIds: Array<string>
|
|
247
|
+
excludeUserAddress?: string
|
|
248
|
+
}
|
|
249
|
+
|
|
199
250
|
export interface TokenHistory {
|
|
200
251
|
blockNumber: number
|
|
201
252
|
blockHash: string
|
|
@@ -318,6 +369,7 @@ export interface WebhookEventFilter {
|
|
|
318
369
|
|
|
319
370
|
export interface MetadataOptions {
|
|
320
371
|
verifiedOnly?: boolean
|
|
372
|
+
unverifiedOnly?: boolean
|
|
321
373
|
includeContracts?: Array<string>
|
|
322
374
|
}
|
|
323
375
|
|
|
@@ -334,6 +386,8 @@ export interface Indexer {
|
|
|
334
386
|
getTransactionHistory(args: GetTransactionHistoryArgs, headers?: object): Promise<GetTransactionHistoryReturn>
|
|
335
387
|
syncBalance(args: SyncBalanceArgs, headers?: object): Promise<SyncBalanceReturn>
|
|
336
388
|
fetchTransactionReceipt(args: FetchTransactionReceiptArgs, headers?: object): Promise<FetchTransactionReceiptReturn>
|
|
389
|
+
getOrderbookOrders(args: GetOrderbookOrdersArgs, headers?: object): Promise<GetOrderbookOrdersReturn>
|
|
390
|
+
getTopOrders(args: GetTopOrdersArgs, headers?: object): Promise<GetTopOrdersReturn>
|
|
337
391
|
fetchTransactionReceiptWithFilter(
|
|
338
392
|
args: FetchTransactionReceiptWithFilterArgs,
|
|
339
393
|
headers?: object
|
|
@@ -378,6 +432,7 @@ export interface GetTokenBalancesArgs {
|
|
|
378
432
|
tokenID?: string
|
|
379
433
|
includeMetadata?: boolean
|
|
380
434
|
metadataOptions?: MetadataOptions
|
|
435
|
+
includeCollectionTokens?: boolean
|
|
381
436
|
page?: Page
|
|
382
437
|
}
|
|
383
438
|
|
|
@@ -443,6 +498,33 @@ export interface FetchTransactionReceiptArgs {
|
|
|
443
498
|
export interface FetchTransactionReceiptReturn {
|
|
444
499
|
receipt: TransactionReceipt
|
|
445
500
|
}
|
|
501
|
+
export interface GetOrderbookOrdersArgs {
|
|
502
|
+
page?: Page
|
|
503
|
+
orderbookContractAddress: string
|
|
504
|
+
collectionAddress: string
|
|
505
|
+
currencyAddresses: Array<string>
|
|
506
|
+
filters: Array<OrderbookOrderFilter>
|
|
507
|
+
orderStatuses: Array<OrderStatus>
|
|
508
|
+
beforeExpiryTimestamp: number
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
export interface GetOrderbookOrdersReturn {
|
|
512
|
+
page?: Page
|
|
513
|
+
orders: Array<OrderbookOrder>
|
|
514
|
+
}
|
|
515
|
+
export interface GetTopOrdersArgs {
|
|
516
|
+
orderbookContractAddress: string
|
|
517
|
+
collectionAddress: string
|
|
518
|
+
currencyAddresses: Array<string>
|
|
519
|
+
tokenIDs: Array<string>
|
|
520
|
+
isListing: boolean
|
|
521
|
+
priceSort: SortOrder
|
|
522
|
+
excludeUser?: string
|
|
523
|
+
}
|
|
524
|
+
|
|
525
|
+
export interface GetTopOrdersReturn {
|
|
526
|
+
orders: Array<OrderbookOrder>
|
|
527
|
+
}
|
|
446
528
|
export interface FetchTransactionReceiptWithFilterArgs {
|
|
447
529
|
filter: Filter
|
|
448
530
|
maxBlockWait?: number
|
|
@@ -633,6 +715,27 @@ export class Indexer implements Indexer {
|
|
|
633
715
|
})
|
|
634
716
|
}
|
|
635
717
|
|
|
718
|
+
getOrderbookOrders = (args: GetOrderbookOrdersArgs, headers?: object): Promise<GetOrderbookOrdersReturn> => {
|
|
719
|
+
return this.fetch(this.url('GetOrderbookOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
720
|
+
return buildResponse(res).then(_data => {
|
|
721
|
+
return {
|
|
722
|
+
page: <Page>_data.page,
|
|
723
|
+
orders: <Array<OrderbookOrder>>_data.orders
|
|
724
|
+
}
|
|
725
|
+
})
|
|
726
|
+
})
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
getTopOrders = (args: GetTopOrdersArgs, headers?: object): Promise<GetTopOrdersReturn> => {
|
|
730
|
+
return this.fetch(this.url('GetTopOrders'), createHTTPRequest(args, headers)).then(res => {
|
|
731
|
+
return buildResponse(res).then(_data => {
|
|
732
|
+
return {
|
|
733
|
+
orders: <Array<OrderbookOrder>>_data.orders
|
|
734
|
+
}
|
|
735
|
+
})
|
|
736
|
+
})
|
|
737
|
+
}
|
|
738
|
+
|
|
636
739
|
fetchTransactionReceiptWithFilter = (
|
|
637
740
|
args: FetchTransactionReceiptWithFilterArgs,
|
|
638
741
|
headers?: object
|