@1inch/fusion-sdk 2.3.8 → 2.3.9-rc.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/cjs/abi/NativeOrderFactory.abi.json +217 -0
- package/dist/cjs/abi/NativeOrderImpl.abi.json +281 -0
- package/dist/cjs/api/quoter/quote/quote.js +29 -4
- package/dist/cjs/contracts/index.js +20 -0
- package/dist/cjs/contracts/native-order-factory.js +115 -0
- package/dist/cjs/contracts/native-order-impl.js +129 -0
- package/dist/cjs/contracts/proxy-factory.js +87 -0
- package/dist/cjs/contracts/types.js +4 -0
- package/dist/cjs/fusion-order/cancellation-auction.js +81 -0
- package/dist/cjs/fusion-order/fusion-order.js +71 -25
- package/dist/cjs/fusion-order/fusion-order.spec.js +73 -0
- package/dist/cjs/fusion-order/index.js +1 -0
- package/dist/cjs/fusion-order/types.js +4 -0
- package/dist/cjs/index.js +1 -0
- package/dist/cjs/sdk/sdk.js +83 -28
- package/dist/esm/abi/NativeOrderFactory.abi.json +217 -0
- package/dist/esm/abi/NativeOrderImpl.abi.json +281 -0
- package/dist/esm/api/quoter/quote/quote.js +24 -4
- package/dist/esm/contracts/index.js +3 -0
- package/dist/esm/contracts/native-order-factory.js +100 -0
- package/dist/esm/contracts/native-order-impl.js +114 -0
- package/dist/esm/contracts/proxy-factory.js +72 -0
- package/dist/esm/contracts/types.js +1 -0
- package/dist/esm/fusion-order/cancellation-auction.js +66 -0
- package/dist/esm/fusion-order/fusion-order.js +69 -23
- package/dist/esm/fusion-order/fusion-order.spec.js +73 -0
- package/dist/esm/fusion-order/index.js +1 -0
- package/dist/esm/fusion-order/types.js +11 -0
- package/dist/esm/index.js +1 -0
- package/dist/esm/package.json +1 -1
- package/dist/esm/sdk/sdk.js +83 -28
- package/dist/types/src/api/quoter/quote/quote.d.ts +3 -0
- package/dist/types/src/api/quoter/types.d.ts +2 -0
- package/dist/types/src/contracts/index.d.ts +3 -0
- package/dist/types/src/contracts/native-order-factory.d.ts +9 -0
- package/dist/types/src/contracts/native-order-impl.d.ts +10 -0
- package/dist/types/src/contracts/proxy-factory.d.ts +8 -0
- package/dist/types/src/contracts/types.d.ts +6 -0
- package/dist/types/src/fusion-order/cancellation-auction.d.ts +7 -0
- package/dist/types/src/fusion-order/fusion-order.d.ts +9 -27
- package/dist/types/src/fusion-order/index.d.ts +1 -0
- package/dist/types/src/fusion-order/types.d.ts +20 -0
- package/dist/types/src/index.d.ts +1 -0
- package/dist/types/src/sdk/sdk.d.ts +4 -0
- package/dist/types/tsconfig.types.tsbuildinfo +1 -1
- package/package.json +1 -1
package/dist/cjs/sdk/sdk.js
CHANGED
|
@@ -341,50 +341,55 @@ var FusionSDK = /*#__PURE__*/ function() {
|
|
|
341
341
|
},
|
|
342
342
|
{
|
|
343
343
|
key: "submitOrder",
|
|
344
|
-
value:
|
|
344
|
+
value: /**
|
|
345
|
+
* Submit order to relayer
|
|
346
|
+
*
|
|
347
|
+
* Note, that orders from native assets must be submitted with `submitNativeOrder`
|
|
348
|
+
*
|
|
349
|
+
* @see FusionSDK.submitNativeOrder
|
|
350
|
+
*/ function submitOrder(order, quoteId) {
|
|
345
351
|
var _this = this;
|
|
346
352
|
return _async_to_generator(function() {
|
|
347
|
-
var
|
|
353
|
+
var signature;
|
|
348
354
|
return _ts_generator(this, function(_state) {
|
|
349
355
|
switch(_state.label){
|
|
350
356
|
case 0:
|
|
351
|
-
if (!_this.config.blockchainProvider) {
|
|
352
|
-
throw new Error('blockchainProvider has not set to config');
|
|
353
|
-
}
|
|
354
|
-
orderStruct = order.build();
|
|
355
357
|
return [
|
|
356
358
|
4,
|
|
357
|
-
_this.
|
|
359
|
+
_this.signOrder(order)
|
|
358
360
|
];
|
|
359
361
|
case 1:
|
|
360
362
|
signature = _state.sent();
|
|
361
|
-
relayerRequest = _index1.RelayerRequest.new({
|
|
362
|
-
order: orderStruct,
|
|
363
|
-
signature: signature,
|
|
364
|
-
quoteId: quoteId,
|
|
365
|
-
extension: order.extension.encode()
|
|
366
|
-
});
|
|
367
|
-
return [
|
|
368
|
-
4,
|
|
369
|
-
_this.api.submitOrder(relayerRequest)
|
|
370
|
-
];
|
|
371
|
-
case 2:
|
|
372
|
-
_state.sent();
|
|
373
363
|
return [
|
|
374
364
|
2,
|
|
375
|
-
|
|
376
|
-
order: orderStruct,
|
|
377
|
-
signature: signature,
|
|
378
|
-
quoteId: quoteId,
|
|
379
|
-
orderHash: order.getOrderHash(_this.config.network),
|
|
380
|
-
extension: relayerRequest.extension
|
|
381
|
-
}
|
|
365
|
+
_this._submitOrder(order, quoteId, signature)
|
|
382
366
|
];
|
|
383
367
|
}
|
|
384
368
|
});
|
|
385
369
|
})();
|
|
386
370
|
}
|
|
387
371
|
},
|
|
372
|
+
{
|
|
373
|
+
key: "submitNativeOrder",
|
|
374
|
+
value: /**
|
|
375
|
+
* Submit order to relayer
|
|
376
|
+
*
|
|
377
|
+
* Note, that orders from native assets must be submitted on-chain as well
|
|
378
|
+
* @see NativeOrdersFactory.create
|
|
379
|
+
*/ function submitNativeOrder(order, maker, quoteId) {
|
|
380
|
+
var _this = this;
|
|
381
|
+
return _async_to_generator(function() {
|
|
382
|
+
var signature;
|
|
383
|
+
return _ts_generator(this, function(_state) {
|
|
384
|
+
signature = _this.signNativeOrder(order, maker);
|
|
385
|
+
return [
|
|
386
|
+
2,
|
|
387
|
+
_this._submitOrder(order, quoteId, signature)
|
|
388
|
+
];
|
|
389
|
+
});
|
|
390
|
+
})();
|
|
391
|
+
}
|
|
392
|
+
},
|
|
388
393
|
{
|
|
389
394
|
key: "placeOrder",
|
|
390
395
|
value: function placeOrder(params) {
|
|
@@ -442,7 +447,13 @@ var FusionSDK = /*#__PURE__*/ function() {
|
|
|
442
447
|
},
|
|
443
448
|
{
|
|
444
449
|
key: "signOrder",
|
|
445
|
-
value:
|
|
450
|
+
value: /**
|
|
451
|
+
* Sign order using `blockchainProvider` from config
|
|
452
|
+
*
|
|
453
|
+
* Use FusionSDK.signNativeOrder for signing orders from native asset
|
|
454
|
+
*
|
|
455
|
+
* @see FusionSDK.signNativeOrder
|
|
456
|
+
*/ function signOrder(order) {
|
|
446
457
|
var _this = this;
|
|
447
458
|
return _async_to_generator(function() {
|
|
448
459
|
var orderStruct, data;
|
|
@@ -460,6 +471,49 @@ var FusionSDK = /*#__PURE__*/ function() {
|
|
|
460
471
|
})();
|
|
461
472
|
}
|
|
462
473
|
},
|
|
474
|
+
{
|
|
475
|
+
key: "signNativeOrder",
|
|
476
|
+
value: function signNativeOrder(order, maker) {
|
|
477
|
+
return order.nativeSignature(maker);
|
|
478
|
+
}
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
key: "_submitOrder",
|
|
482
|
+
value: function _submitOrder(order, quoteId, signature) {
|
|
483
|
+
var _this = this;
|
|
484
|
+
return _async_to_generator(function() {
|
|
485
|
+
var orderStruct, relayerRequest;
|
|
486
|
+
return _ts_generator(this, function(_state) {
|
|
487
|
+
switch(_state.label){
|
|
488
|
+
case 0:
|
|
489
|
+
orderStruct = order.build();
|
|
490
|
+
relayerRequest = _index1.RelayerRequest.new({
|
|
491
|
+
order: orderStruct,
|
|
492
|
+
signature: signature,
|
|
493
|
+
quoteId: quoteId,
|
|
494
|
+
extension: order.extension.encode()
|
|
495
|
+
});
|
|
496
|
+
return [
|
|
497
|
+
4,
|
|
498
|
+
_this.api.submitOrder(relayerRequest)
|
|
499
|
+
];
|
|
500
|
+
case 1:
|
|
501
|
+
_state.sent();
|
|
502
|
+
return [
|
|
503
|
+
2,
|
|
504
|
+
{
|
|
505
|
+
order: orderStruct,
|
|
506
|
+
signature: signature,
|
|
507
|
+
quoteId: quoteId,
|
|
508
|
+
orderHash: order.getOrderHash(_this.config.network),
|
|
509
|
+
extension: relayerRequest.extension
|
|
510
|
+
}
|
|
511
|
+
];
|
|
512
|
+
}
|
|
513
|
+
});
|
|
514
|
+
})();
|
|
515
|
+
}
|
|
516
|
+
},
|
|
463
517
|
{
|
|
464
518
|
key: "getQuoteResult",
|
|
465
519
|
value: function getQuoteResult(params) {
|
|
@@ -498,4 +552,5 @@ var FusionSDK = /*#__PURE__*/ function() {
|
|
|
498
552
|
}
|
|
499
553
|
]);
|
|
500
554
|
return FusionSDK;
|
|
501
|
-
}
|
|
555
|
+
} // eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
556
|
+
();
|
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"type": "constructor",
|
|
4
|
+
"inputs": [
|
|
5
|
+
{
|
|
6
|
+
"name": "weth",
|
|
7
|
+
"type": "address",
|
|
8
|
+
"internalType": "contract IWETH"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"name": "nativeOrderImplementation",
|
|
12
|
+
"type": "address",
|
|
13
|
+
"internalType": "address"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"name": "limitOrderProtocol",
|
|
17
|
+
"type": "address",
|
|
18
|
+
"internalType": "address"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"name": "accessToken",
|
|
22
|
+
"type": "address",
|
|
23
|
+
"internalType": "contract IERC20"
|
|
24
|
+
}
|
|
25
|
+
],
|
|
26
|
+
"stateMutability": "nonpayable"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"type": "function",
|
|
30
|
+
"name": "create",
|
|
31
|
+
"inputs": [
|
|
32
|
+
{
|
|
33
|
+
"name": "makerOrder",
|
|
34
|
+
"type": "tuple",
|
|
35
|
+
"internalType": "struct IOrderMixin.Order",
|
|
36
|
+
"components": [
|
|
37
|
+
{
|
|
38
|
+
"name": "salt",
|
|
39
|
+
"type": "uint256",
|
|
40
|
+
"internalType": "uint256"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"name": "maker",
|
|
44
|
+
"type": "uint256",
|
|
45
|
+
"internalType": "Address"
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"name": "receiver",
|
|
49
|
+
"type": "uint256",
|
|
50
|
+
"internalType": "Address"
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"name": "makerAsset",
|
|
54
|
+
"type": "uint256",
|
|
55
|
+
"internalType": "Address"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"name": "takerAsset",
|
|
59
|
+
"type": "uint256",
|
|
60
|
+
"internalType": "Address"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"name": "makingAmount",
|
|
64
|
+
"type": "uint256",
|
|
65
|
+
"internalType": "uint256"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"name": "takingAmount",
|
|
69
|
+
"type": "uint256",
|
|
70
|
+
"internalType": "uint256"
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"name": "makerTraits",
|
|
74
|
+
"type": "uint256",
|
|
75
|
+
"internalType": "MakerTraits"
|
|
76
|
+
}
|
|
77
|
+
]
|
|
78
|
+
}
|
|
79
|
+
],
|
|
80
|
+
"outputs": [
|
|
81
|
+
{"name": "clone", "type": "address", "internalType": "address"}
|
|
82
|
+
],
|
|
83
|
+
"stateMutability": "payable"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
"type": "function",
|
|
87
|
+
"name": "owner",
|
|
88
|
+
"inputs": [],
|
|
89
|
+
"outputs": [{"name": "", "type": "address", "internalType": "address"}],
|
|
90
|
+
"stateMutability": "view"
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
"type": "function",
|
|
94
|
+
"name": "renounceOwnership",
|
|
95
|
+
"inputs": [],
|
|
96
|
+
"outputs": [],
|
|
97
|
+
"stateMutability": "nonpayable"
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
"type": "function",
|
|
101
|
+
"name": "rescueFunds",
|
|
102
|
+
"inputs": [
|
|
103
|
+
{"name": "token", "type": "address", "internalType": "address"},
|
|
104
|
+
{"name": "to", "type": "address", "internalType": "address"},
|
|
105
|
+
{"name": "amount", "type": "uint256", "internalType": "uint256"}
|
|
106
|
+
],
|
|
107
|
+
"outputs": [],
|
|
108
|
+
"stateMutability": "nonpayable"
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"type": "function",
|
|
112
|
+
"name": "transferOwnership",
|
|
113
|
+
"inputs": [
|
|
114
|
+
{"name": "newOwner", "type": "address", "internalType": "address"}
|
|
115
|
+
],
|
|
116
|
+
"outputs": [],
|
|
117
|
+
"stateMutability": "nonpayable"
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
"type": "event",
|
|
121
|
+
"name": "NativeOrderCreated",
|
|
122
|
+
"inputs": [
|
|
123
|
+
{
|
|
124
|
+
"name": "maker",
|
|
125
|
+
"type": "address",
|
|
126
|
+
"indexed": false,
|
|
127
|
+
"internalType": "address"
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
"name": "orderHash",
|
|
131
|
+
"type": "bytes32",
|
|
132
|
+
"indexed": false,
|
|
133
|
+
"internalType": "bytes32"
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
"name": "clone",
|
|
137
|
+
"type": "address",
|
|
138
|
+
"indexed": false,
|
|
139
|
+
"internalType": "address"
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
"name": "value",
|
|
143
|
+
"type": "uint256",
|
|
144
|
+
"indexed": false,
|
|
145
|
+
"internalType": "uint256"
|
|
146
|
+
}
|
|
147
|
+
],
|
|
148
|
+
"anonymous": false
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
"type": "event",
|
|
152
|
+
"name": "OwnershipTransferred",
|
|
153
|
+
"inputs": [
|
|
154
|
+
{
|
|
155
|
+
"name": "previousOwner",
|
|
156
|
+
"type": "address",
|
|
157
|
+
"indexed": true,
|
|
158
|
+
"internalType": "address"
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
"name": "newOwner",
|
|
162
|
+
"type": "address",
|
|
163
|
+
"indexed": true,
|
|
164
|
+
"internalType": "address"
|
|
165
|
+
}
|
|
166
|
+
],
|
|
167
|
+
"anonymous": false
|
|
168
|
+
},
|
|
169
|
+
{"type": "error", "name": "FailedDeployment", "inputs": []},
|
|
170
|
+
{
|
|
171
|
+
"type": "error",
|
|
172
|
+
"name": "InsufficientBalance",
|
|
173
|
+
"inputs": [
|
|
174
|
+
{"name": "balance", "type": "uint256", "internalType": "uint256"},
|
|
175
|
+
{"name": "needed", "type": "uint256", "internalType": "uint256"}
|
|
176
|
+
]
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
"type": "error",
|
|
180
|
+
"name": "OrderMakerShouldBeMsgSender",
|
|
181
|
+
"inputs": [
|
|
182
|
+
{"name": "expected", "type": "address", "internalType": "address"},
|
|
183
|
+
{"name": "actual", "type": "address", "internalType": "address"}
|
|
184
|
+
]
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
"type": "error",
|
|
188
|
+
"name": "OrderMakingAmountShouldBeEqualToMsgValue",
|
|
189
|
+
"inputs": [
|
|
190
|
+
{"name": "expected", "type": "uint256", "internalType": "uint256"},
|
|
191
|
+
{"name": "actual", "type": "uint256", "internalType": "uint256"}
|
|
192
|
+
]
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
"type": "error",
|
|
196
|
+
"name": "OrderReceiverShouldNotBeThis",
|
|
197
|
+
"inputs": [
|
|
198
|
+
{"name": "receiver", "type": "address", "internalType": "address"},
|
|
199
|
+
{"name": "self", "type": "address", "internalType": "address"}
|
|
200
|
+
]
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
"type": "error",
|
|
204
|
+
"name": "OwnableInvalidOwner",
|
|
205
|
+
"inputs": [
|
|
206
|
+
{"name": "owner", "type": "address", "internalType": "address"}
|
|
207
|
+
]
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
"type": "error",
|
|
211
|
+
"name": "OwnableUnauthorizedAccount",
|
|
212
|
+
"inputs": [
|
|
213
|
+
{"name": "account", "type": "address", "internalType": "address"}
|
|
214
|
+
]
|
|
215
|
+
},
|
|
216
|
+
{"type": "error", "name": "SafeTransferFailed", "inputs": []}
|
|
217
|
+
]
|
|
@@ -0,0 +1,281 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"type": "constructor",
|
|
4
|
+
"inputs": [
|
|
5
|
+
{
|
|
6
|
+
"name": "weth",
|
|
7
|
+
"type": "address",
|
|
8
|
+
"internalType": "contract IWETH"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"name": "nativeOrderFactory",
|
|
12
|
+
"type": "address",
|
|
13
|
+
"internalType": "address"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"name": "limitOrderProtocol",
|
|
17
|
+
"type": "address",
|
|
18
|
+
"internalType": "address"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"name": "accessToken",
|
|
22
|
+
"type": "address",
|
|
23
|
+
"internalType": "contract IERC20"
|
|
24
|
+
}
|
|
25
|
+
],
|
|
26
|
+
"stateMutability": "nonpayable"
|
|
27
|
+
},
|
|
28
|
+
{"type": "receive", "stateMutability": "payable"},
|
|
29
|
+
{
|
|
30
|
+
"type": "function",
|
|
31
|
+
"name": "cancelExpiredOrderByResolver",
|
|
32
|
+
"inputs": [
|
|
33
|
+
{
|
|
34
|
+
"name": "makerOrder",
|
|
35
|
+
"type": "tuple",
|
|
36
|
+
"internalType": "struct IOrderMixin.Order",
|
|
37
|
+
"components": [
|
|
38
|
+
{
|
|
39
|
+
"name": "salt",
|
|
40
|
+
"type": "uint256",
|
|
41
|
+
"internalType": "uint256"
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"name": "maker",
|
|
45
|
+
"type": "uint256",
|
|
46
|
+
"internalType": "Address"
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"name": "receiver",
|
|
50
|
+
"type": "uint256",
|
|
51
|
+
"internalType": "Address"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"name": "makerAsset",
|
|
55
|
+
"type": "uint256",
|
|
56
|
+
"internalType": "Address"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"name": "takerAsset",
|
|
60
|
+
"type": "uint256",
|
|
61
|
+
"internalType": "Address"
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"name": "makingAmount",
|
|
65
|
+
"type": "uint256",
|
|
66
|
+
"internalType": "uint256"
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"name": "takingAmount",
|
|
70
|
+
"type": "uint256",
|
|
71
|
+
"internalType": "uint256"
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"name": "makerTraits",
|
|
75
|
+
"type": "uint256",
|
|
76
|
+
"internalType": "MakerTraits"
|
|
77
|
+
}
|
|
78
|
+
]
|
|
79
|
+
}
|
|
80
|
+
],
|
|
81
|
+
"outputs": [],
|
|
82
|
+
"stateMutability": "nonpayable"
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
"type": "function",
|
|
86
|
+
"name": "cancelOrder",
|
|
87
|
+
"inputs": [
|
|
88
|
+
{
|
|
89
|
+
"name": "makerOrder",
|
|
90
|
+
"type": "tuple",
|
|
91
|
+
"internalType": "struct IOrderMixin.Order",
|
|
92
|
+
"components": [
|
|
93
|
+
{
|
|
94
|
+
"name": "salt",
|
|
95
|
+
"type": "uint256",
|
|
96
|
+
"internalType": "uint256"
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"name": "maker",
|
|
100
|
+
"type": "uint256",
|
|
101
|
+
"internalType": "Address"
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
"name": "receiver",
|
|
105
|
+
"type": "uint256",
|
|
106
|
+
"internalType": "Address"
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
"name": "makerAsset",
|
|
110
|
+
"type": "uint256",
|
|
111
|
+
"internalType": "Address"
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
"name": "takerAsset",
|
|
115
|
+
"type": "uint256",
|
|
116
|
+
"internalType": "Address"
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"name": "makingAmount",
|
|
120
|
+
"type": "uint256",
|
|
121
|
+
"internalType": "uint256"
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
"name": "takingAmount",
|
|
125
|
+
"type": "uint256",
|
|
126
|
+
"internalType": "uint256"
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
"name": "makerTraits",
|
|
130
|
+
"type": "uint256",
|
|
131
|
+
"internalType": "MakerTraits"
|
|
132
|
+
}
|
|
133
|
+
]
|
|
134
|
+
}
|
|
135
|
+
],
|
|
136
|
+
"outputs": [],
|
|
137
|
+
"stateMutability": "nonpayable"
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
"type": "function",
|
|
141
|
+
"name": "decimals",
|
|
142
|
+
"inputs": [],
|
|
143
|
+
"outputs": [{"name": "", "type": "uint8", "internalType": "uint8"}],
|
|
144
|
+
"stateMutability": "pure"
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
"type": "function",
|
|
148
|
+
"name": "depositAndApprove",
|
|
149
|
+
"inputs": [],
|
|
150
|
+
"outputs": [],
|
|
151
|
+
"stateMutability": "payable"
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
"type": "function",
|
|
155
|
+
"name": "isValidSignature",
|
|
156
|
+
"inputs": [
|
|
157
|
+
{"name": "hash", "type": "bytes32", "internalType": "bytes32"},
|
|
158
|
+
{"name": "signature", "type": "bytes", "internalType": "bytes"}
|
|
159
|
+
],
|
|
160
|
+
"outputs": [{"name": "", "type": "bytes4", "internalType": "bytes4"}],
|
|
161
|
+
"stateMutability": "view"
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"type": "function",
|
|
165
|
+
"name": "name",
|
|
166
|
+
"inputs": [],
|
|
167
|
+
"outputs": [{"name": "", "type": "string", "internalType": "string"}],
|
|
168
|
+
"stateMutability": "pure"
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
"type": "function",
|
|
172
|
+
"name": "rescueFunds",
|
|
173
|
+
"inputs": [
|
|
174
|
+
{"name": "token", "type": "address", "internalType": "address"},
|
|
175
|
+
{"name": "to", "type": "address", "internalType": "address"},
|
|
176
|
+
{"name": "amount", "type": "uint256", "internalType": "uint256"}
|
|
177
|
+
],
|
|
178
|
+
"outputs": [],
|
|
179
|
+
"stateMutability": "nonpayable"
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
"type": "function",
|
|
183
|
+
"name": "symbol",
|
|
184
|
+
"inputs": [],
|
|
185
|
+
"outputs": [{"name": "", "type": "string", "internalType": "string"}],
|
|
186
|
+
"stateMutability": "pure"
|
|
187
|
+
},
|
|
188
|
+
{
|
|
189
|
+
"type": "event",
|
|
190
|
+
"name": "NativeOrderCancelled",
|
|
191
|
+
"inputs": [
|
|
192
|
+
{
|
|
193
|
+
"name": "makerOrderHash",
|
|
194
|
+
"type": "bytes32",
|
|
195
|
+
"indexed": false,
|
|
196
|
+
"internalType": "bytes32"
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
"name": "balance",
|
|
200
|
+
"type": "uint256",
|
|
201
|
+
"indexed": false,
|
|
202
|
+
"internalType": "uint256"
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
"name": "resolverReward",
|
|
206
|
+
"type": "uint256",
|
|
207
|
+
"indexed": false,
|
|
208
|
+
"internalType": "uint256"
|
|
209
|
+
}
|
|
210
|
+
],
|
|
211
|
+
"anonymous": false
|
|
212
|
+
},
|
|
213
|
+
{"type": "error", "name": "CanNotCancelForZeroBalance", "inputs": []},
|
|
214
|
+
{"type": "error", "name": "EthDepositRejected", "inputs": []},
|
|
215
|
+
{"type": "error", "name": "ForceApproveFailed", "inputs": []},
|
|
216
|
+
{
|
|
217
|
+
"type": "error",
|
|
218
|
+
"name": "OnlyFactoryViolation",
|
|
219
|
+
"inputs": [
|
|
220
|
+
{"name": "sender", "type": "address", "internalType": "address"},
|
|
221
|
+
{"name": "factory", "type": "address", "internalType": "address"}
|
|
222
|
+
]
|
|
223
|
+
},
|
|
224
|
+
{
|
|
225
|
+
"type": "error",
|
|
226
|
+
"name": "OnlyLimitOrderProtocolViolation",
|
|
227
|
+
"inputs": [
|
|
228
|
+
{"name": "sender", "type": "address", "internalType": "address"},
|
|
229
|
+
{
|
|
230
|
+
"name": "limitOrderProtocol",
|
|
231
|
+
"type": "address",
|
|
232
|
+
"internalType": "address"
|
|
233
|
+
}
|
|
234
|
+
]
|
|
235
|
+
},
|
|
236
|
+
{
|
|
237
|
+
"type": "error",
|
|
238
|
+
"name": "OrderIsIncorrect",
|
|
239
|
+
"inputs": [
|
|
240
|
+
{"name": "expected", "type": "address", "internalType": "address"},
|
|
241
|
+
{"name": "actual", "type": "address", "internalType": "address"}
|
|
242
|
+
]
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
"type": "error",
|
|
246
|
+
"name": "OrderShouldBeExpired",
|
|
247
|
+
"inputs": [
|
|
248
|
+
{
|
|
249
|
+
"name": "currentTime",
|
|
250
|
+
"type": "uint256",
|
|
251
|
+
"internalType": "uint256"
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"name": "expirationTime",
|
|
255
|
+
"type": "uint256",
|
|
256
|
+
"internalType": "uint256"
|
|
257
|
+
}
|
|
258
|
+
]
|
|
259
|
+
},
|
|
260
|
+
{
|
|
261
|
+
"type": "error",
|
|
262
|
+
"name": "RescueFundsTooMuch",
|
|
263
|
+
"inputs": [
|
|
264
|
+
{"name": "requested", "type": "uint256", "internalType": "uint256"},
|
|
265
|
+
{"name": "available", "type": "uint256", "internalType": "uint256"}
|
|
266
|
+
]
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
"type": "error",
|
|
270
|
+
"name": "ResolverAccessTokenMissing",
|
|
271
|
+
"inputs": [
|
|
272
|
+
{"name": "resolver", "type": "address", "internalType": "address"},
|
|
273
|
+
{
|
|
274
|
+
"name": "accessToken",
|
|
275
|
+
"type": "address",
|
|
276
|
+
"internalType": "address"
|
|
277
|
+
}
|
|
278
|
+
]
|
|
279
|
+
},
|
|
280
|
+
{"type": "error", "name": "SafeTransferFailed", "inputs": []}
|
|
281
|
+
]
|