@lifi/compose-spec 0.10.0 → 0.12.0
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/README.md +1 -1
- package/dist/index.cjs +95 -109
- package/dist/index.d.cts +450 -568
- package/dist/index.d.ts +450 -568
- package/dist/index.js +91 -105
- package/package.json +1 -1
- package/src/chainCapabilities.ts +6 -6
- package/src/compile.ts +45 -33
- package/src/continuation.ts +158 -107
- package/src/descriptor.ts +20 -72
- package/src/flow.ts +40 -4
- package/src/flowSchema.ts +26 -12
- package/src/hexPatterns.ts +0 -5
- package/src/index.ts +25 -9
- package/src/manifest.ts +1 -0
- package/src/materialiserMetadata.ts +6 -3
- package/src/output.ts +20 -13
- package/src/resource.ts +43 -30
- package/src/route.ts +10 -15
- package/src/zodSchemas.ts +58 -71
package/dist/index.d.ts
CHANGED
|
@@ -29,19 +29,19 @@ export declare const ResourceSchema: Schema.transform<Schema.Union<[Schema.Struc
|
|
|
29
29
|
token: Schema.refine<string, typeof Schema.String>;
|
|
30
30
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
31
31
|
}>]>, Schema.SchemaClass<{
|
|
32
|
-
readonly kind: "native";
|
|
33
32
|
readonly chainId: number;
|
|
33
|
+
readonly kind: "native";
|
|
34
34
|
} | {
|
|
35
|
-
readonly kind: "erc20";
|
|
36
|
-
readonly chainId: number;
|
|
37
35
|
readonly token: string;
|
|
38
|
-
}, {
|
|
39
|
-
readonly kind: "native";
|
|
40
36
|
readonly chainId: number;
|
|
41
|
-
} | {
|
|
42
37
|
readonly kind: "erc20";
|
|
38
|
+
}, {
|
|
43
39
|
readonly chainId: number;
|
|
40
|
+
readonly kind: "native";
|
|
41
|
+
} | {
|
|
44
42
|
readonly token: string;
|
|
43
|
+
readonly chainId: number;
|
|
44
|
+
readonly kind: "erc20";
|
|
45
45
|
}, never>>;
|
|
46
46
|
export declare const ResourceInputSchema: Schema.Struct<{
|
|
47
47
|
name: typeof Schema.String;
|
|
@@ -53,19 +53,19 @@ export declare const ResourceInputSchema: Schema.Struct<{
|
|
|
53
53
|
token: Schema.refine<string, typeof Schema.String>;
|
|
54
54
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
55
55
|
}>]>, Schema.SchemaClass<{
|
|
56
|
-
readonly kind: "native";
|
|
57
56
|
readonly chainId: number;
|
|
57
|
+
readonly kind: "native";
|
|
58
58
|
} | {
|
|
59
|
-
readonly kind: "erc20";
|
|
60
|
-
readonly chainId: number;
|
|
61
59
|
readonly token: string;
|
|
62
|
-
}, {
|
|
63
|
-
readonly kind: "native";
|
|
64
60
|
readonly chainId: number;
|
|
65
|
-
} | {
|
|
66
61
|
readonly kind: "erc20";
|
|
62
|
+
}, {
|
|
67
63
|
readonly chainId: number;
|
|
64
|
+
readonly kind: "native";
|
|
65
|
+
} | {
|
|
68
66
|
readonly token: string;
|
|
67
|
+
readonly chainId: number;
|
|
68
|
+
readonly kind: "erc20";
|
|
69
69
|
}, never>>;
|
|
70
70
|
}>;
|
|
71
71
|
export declare const HandleInputSchema: Schema.Struct<{
|
|
@@ -82,19 +82,19 @@ export declare const FlowInputSchema: Schema.Union<[Schema.Struct<{
|
|
|
82
82
|
token: Schema.refine<string, typeof Schema.String>;
|
|
83
83
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
84
84
|
}>]>, Schema.SchemaClass<{
|
|
85
|
-
readonly kind: "native";
|
|
86
85
|
readonly chainId: number;
|
|
86
|
+
readonly kind: "native";
|
|
87
87
|
} | {
|
|
88
|
-
readonly kind: "erc20";
|
|
89
|
-
readonly chainId: number;
|
|
90
88
|
readonly token: string;
|
|
91
|
-
}, {
|
|
92
|
-
readonly kind: "native";
|
|
93
89
|
readonly chainId: number;
|
|
94
|
-
} | {
|
|
95
90
|
readonly kind: "erc20";
|
|
91
|
+
}, {
|
|
96
92
|
readonly chainId: number;
|
|
93
|
+
readonly kind: "native";
|
|
94
|
+
} | {
|
|
97
95
|
readonly token: string;
|
|
96
|
+
readonly chainId: number;
|
|
97
|
+
readonly kind: "erc20";
|
|
98
98
|
}, never>>;
|
|
99
99
|
}>, Schema.Struct<{
|
|
100
100
|
name: typeof Schema.String;
|
|
@@ -145,6 +145,68 @@ export declare const LineageSchema: Schema.Struct<{
|
|
|
145
145
|
journeyId: Schema.filter<typeof Schema.String>;
|
|
146
146
|
parentRequestId: Schema.filter<typeof Schema.String>;
|
|
147
147
|
}>;
|
|
148
|
+
export declare const ForwardToSchema: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
149
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
150
|
+
}>]>;
|
|
151
|
+
export declare const EpilogueForwardSchema: Schema.Struct<{
|
|
152
|
+
resource: Schema.transform<Schema.Union<[Schema.Struct<{
|
|
153
|
+
kind: Schema.Literal<["native"]>;
|
|
154
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
155
|
+
}>, Schema.Struct<{
|
|
156
|
+
kind: Schema.Literal<["erc20"]>;
|
|
157
|
+
token: Schema.refine<string, typeof Schema.String>;
|
|
158
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
159
|
+
}>]>, Schema.SchemaClass<{
|
|
160
|
+
readonly chainId: number;
|
|
161
|
+
readonly kind: "native";
|
|
162
|
+
} | {
|
|
163
|
+
readonly token: string;
|
|
164
|
+
readonly chainId: number;
|
|
165
|
+
readonly kind: "erc20";
|
|
166
|
+
}, {
|
|
167
|
+
readonly chainId: number;
|
|
168
|
+
readonly kind: "native";
|
|
169
|
+
} | {
|
|
170
|
+
readonly token: string;
|
|
171
|
+
readonly chainId: number;
|
|
172
|
+
readonly kind: "erc20";
|
|
173
|
+
}, never>>;
|
|
174
|
+
to: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
175
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
176
|
+
}>]>;
|
|
177
|
+
}>;
|
|
178
|
+
export declare const EpilogueSchema: Schema.filter<Schema.Struct<{
|
|
179
|
+
forwards: Schema.optional<Schema.NonEmptyArray<Schema.Struct<{
|
|
180
|
+
resource: Schema.transform<Schema.Union<[Schema.Struct<{
|
|
181
|
+
kind: Schema.Literal<["native"]>;
|
|
182
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
183
|
+
}>, Schema.Struct<{
|
|
184
|
+
kind: Schema.Literal<["erc20"]>;
|
|
185
|
+
token: Schema.refine<string, typeof Schema.String>;
|
|
186
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
187
|
+
}>]>, Schema.SchemaClass<{
|
|
188
|
+
readonly chainId: number;
|
|
189
|
+
readonly kind: "native";
|
|
190
|
+
} | {
|
|
191
|
+
readonly token: string;
|
|
192
|
+
readonly chainId: number;
|
|
193
|
+
readonly kind: "erc20";
|
|
194
|
+
}, {
|
|
195
|
+
readonly chainId: number;
|
|
196
|
+
readonly kind: "native";
|
|
197
|
+
} | {
|
|
198
|
+
readonly token: string;
|
|
199
|
+
readonly chainId: number;
|
|
200
|
+
readonly kind: "erc20";
|
|
201
|
+
}, never>>;
|
|
202
|
+
to: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
203
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
204
|
+
}>]>;
|
|
205
|
+
}>>>;
|
|
206
|
+
remainder: Schema.optional<Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
207
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
208
|
+
}>]>>;
|
|
209
|
+
}>>;
|
|
148
210
|
export declare const FlowSchema: Schema.Struct<{
|
|
149
211
|
version: Schema.Literal<[1]>;
|
|
150
212
|
id: typeof Schema.String;
|
|
@@ -159,19 +221,19 @@ export declare const FlowSchema: Schema.Struct<{
|
|
|
159
221
|
token: Schema.refine<string, typeof Schema.String>;
|
|
160
222
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
161
223
|
}>]>, Schema.SchemaClass<{
|
|
162
|
-
readonly kind: "native";
|
|
163
224
|
readonly chainId: number;
|
|
225
|
+
readonly kind: "native";
|
|
164
226
|
} | {
|
|
165
|
-
readonly kind: "erc20";
|
|
166
|
-
readonly chainId: number;
|
|
167
227
|
readonly token: string;
|
|
168
|
-
}, {
|
|
169
|
-
readonly kind: "native";
|
|
170
228
|
readonly chainId: number;
|
|
171
|
-
} | {
|
|
172
229
|
readonly kind: "erc20";
|
|
230
|
+
}, {
|
|
173
231
|
readonly chainId: number;
|
|
232
|
+
readonly kind: "native";
|
|
233
|
+
} | {
|
|
174
234
|
readonly token: string;
|
|
235
|
+
readonly chainId: number;
|
|
236
|
+
readonly kind: "erc20";
|
|
175
237
|
}, never>>;
|
|
176
238
|
}>, Schema.Struct<{
|
|
177
239
|
name: typeof Schema.String;
|
|
@@ -202,6 +264,38 @@ export declare const FlowSchema: Schema.Struct<{
|
|
|
202
264
|
journeyId: Schema.filter<typeof Schema.String>;
|
|
203
265
|
parentRequestId: Schema.filter<typeof Schema.String>;
|
|
204
266
|
}>>;
|
|
267
|
+
epilogue: Schema.optional<Schema.filter<Schema.Struct<{
|
|
268
|
+
forwards: Schema.optional<Schema.NonEmptyArray<Schema.Struct<{
|
|
269
|
+
resource: Schema.transform<Schema.Union<[Schema.Struct<{
|
|
270
|
+
kind: Schema.Literal<["native"]>;
|
|
271
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
272
|
+
}>, Schema.Struct<{
|
|
273
|
+
kind: Schema.Literal<["erc20"]>;
|
|
274
|
+
token: Schema.refine<string, typeof Schema.String>;
|
|
275
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
276
|
+
}>]>, Schema.SchemaClass<{
|
|
277
|
+
readonly chainId: number;
|
|
278
|
+
readonly kind: "native";
|
|
279
|
+
} | {
|
|
280
|
+
readonly token: string;
|
|
281
|
+
readonly chainId: number;
|
|
282
|
+
readonly kind: "erc20";
|
|
283
|
+
}, {
|
|
284
|
+
readonly chainId: number;
|
|
285
|
+
readonly kind: "native";
|
|
286
|
+
} | {
|
|
287
|
+
readonly token: string;
|
|
288
|
+
readonly chainId: number;
|
|
289
|
+
readonly kind: "erc20";
|
|
290
|
+
}, never>>;
|
|
291
|
+
to: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
292
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
293
|
+
}>]>;
|
|
294
|
+
}>>>;
|
|
295
|
+
remainder: Schema.optional<Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
296
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
297
|
+
}>]>>;
|
|
298
|
+
}>>>;
|
|
205
299
|
}>;
|
|
206
300
|
type SolType = typeof SolTypeSchema.Type;
|
|
207
301
|
type ResourceInput = typeof ResourceInputSchema.Type;
|
|
@@ -213,42 +307,76 @@ type BindValue = typeof BindValueSchema.Type;
|
|
|
213
307
|
type AppliedGuard = typeof AppliedGuardSchema.Type;
|
|
214
308
|
type Call = typeof CallSchema.Type;
|
|
215
309
|
type Lineage = typeof LineageSchema.Type;
|
|
310
|
+
type ForwardTo = typeof ForwardToSchema.Type;
|
|
311
|
+
type EpilogueForward = typeof EpilogueForwardSchema.Type;
|
|
312
|
+
type Epilogue = typeof EpilogueSchema.Type;
|
|
216
313
|
type Flow = typeof FlowSchema.Type;
|
|
217
314
|
//#endregion
|
|
218
315
|
//#region src/continuation.d.ts
|
|
219
316
|
export declare const CONTINUATION_COMMITMENT_OP_ID = "continuation.commitment";
|
|
220
|
-
export declare const ContinuationOutcomeSchema: Schema.transform<Schema.
|
|
221
|
-
token:
|
|
222
|
-
minAmount
|
|
223
|
-
destination:
|
|
224
|
-
chainId:
|
|
225
|
-
}
|
|
317
|
+
export declare const ContinuationOutcomeSchema: Schema.transform<Schema.Schema<{
|
|
318
|
+
readonly token: string;
|
|
319
|
+
readonly minAmount?: string | undefined;
|
|
320
|
+
readonly destination: string;
|
|
321
|
+
readonly chainId: number;
|
|
322
|
+
}, {
|
|
323
|
+
readonly token: string;
|
|
324
|
+
readonly destination: string;
|
|
325
|
+
readonly chainId: number;
|
|
326
|
+
readonly minAmount?: string | undefined;
|
|
327
|
+
}, never>, Schema.SchemaClass<{
|
|
328
|
+
readonly token: string;
|
|
329
|
+
readonly minAmount?: string | undefined;
|
|
330
|
+
readonly destination: string;
|
|
331
|
+
readonly chainId: number;
|
|
332
|
+
}, {
|
|
333
|
+
readonly token: string;
|
|
334
|
+
readonly minAmount?: string | undefined;
|
|
335
|
+
readonly destination: string;
|
|
226
336
|
readonly chainId: number;
|
|
337
|
+
}, never>>;
|
|
338
|
+
export declare const CommittedOutcomeSchema: Schema.transform<Schema.Schema<{
|
|
227
339
|
readonly token: string;
|
|
228
340
|
readonly minAmount: string;
|
|
229
341
|
readonly destination: string;
|
|
342
|
+
readonly chainId: number;
|
|
230
343
|
}, {
|
|
344
|
+
readonly token: string;
|
|
345
|
+
readonly minAmount: string;
|
|
346
|
+
readonly destination: string;
|
|
231
347
|
readonly chainId: number;
|
|
348
|
+
}, never>, Schema.SchemaClass<{
|
|
232
349
|
readonly token: string;
|
|
233
350
|
readonly minAmount: string;
|
|
234
351
|
readonly destination: string;
|
|
352
|
+
readonly chainId: number;
|
|
353
|
+
}, {
|
|
354
|
+
readonly token: string;
|
|
355
|
+
readonly minAmount: string;
|
|
356
|
+
readonly destination: string;
|
|
357
|
+
readonly chainId: number;
|
|
235
358
|
}, never>>;
|
|
236
359
|
export declare const ContinuationIntentSchema: Schema.Struct<{
|
|
237
|
-
outcomes: Schema.NonEmptyArray<Schema.transform<Schema.
|
|
238
|
-
token: Schema.refine<string, typeof Schema.String>;
|
|
239
|
-
minAmount: Schema.filter<typeof Schema.String>;
|
|
240
|
-
destination: Schema.refine<string, typeof Schema.String>;
|
|
241
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
242
|
-
}>, Schema.SchemaClass<{
|
|
243
|
-
readonly chainId: number;
|
|
360
|
+
outcomes: Schema.NonEmptyArray<Schema.transform<Schema.Schema<{
|
|
244
361
|
readonly token: string;
|
|
245
|
-
readonly minAmount
|
|
362
|
+
readonly minAmount?: string | undefined;
|
|
246
363
|
readonly destination: string;
|
|
364
|
+
readonly chainId: number;
|
|
247
365
|
}, {
|
|
366
|
+
readonly token: string;
|
|
367
|
+
readonly destination: string;
|
|
248
368
|
readonly chainId: number;
|
|
369
|
+
readonly minAmount?: string | undefined;
|
|
370
|
+
}, never>, Schema.SchemaClass<{
|
|
249
371
|
readonly token: string;
|
|
250
|
-
readonly minAmount
|
|
372
|
+
readonly minAmount?: string | undefined;
|
|
251
373
|
readonly destination: string;
|
|
374
|
+
readonly chainId: number;
|
|
375
|
+
}, {
|
|
376
|
+
readonly token: string;
|
|
377
|
+
readonly minAmount?: string | undefined;
|
|
378
|
+
readonly destination: string;
|
|
379
|
+
readonly chainId: number;
|
|
252
380
|
}, never>>>;
|
|
253
381
|
continuationFlow: Schema.optional<Schema.Struct<{
|
|
254
382
|
version: Schema.Literal<[1]>;
|
|
@@ -264,19 +392,19 @@ export declare const ContinuationIntentSchema: Schema.Struct<{
|
|
|
264
392
|
token: Schema.refine<string, typeof Schema.String>;
|
|
265
393
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
266
394
|
}>]>, Schema.SchemaClass<{
|
|
267
|
-
readonly kind: "native";
|
|
268
395
|
readonly chainId: number;
|
|
396
|
+
readonly kind: "native";
|
|
269
397
|
} | {
|
|
270
|
-
readonly kind: "erc20";
|
|
271
|
-
readonly chainId: number;
|
|
272
398
|
readonly token: string;
|
|
273
|
-
}, {
|
|
274
|
-
readonly kind: "native";
|
|
275
399
|
readonly chainId: number;
|
|
276
|
-
} | {
|
|
277
400
|
readonly kind: "erc20";
|
|
401
|
+
}, {
|
|
278
402
|
readonly chainId: number;
|
|
403
|
+
readonly kind: "native";
|
|
404
|
+
} | {
|
|
279
405
|
readonly token: string;
|
|
406
|
+
readonly chainId: number;
|
|
407
|
+
readonly kind: "erc20";
|
|
280
408
|
}, never>>;
|
|
281
409
|
}>, Schema.Struct<{
|
|
282
410
|
name: typeof Schema.String;
|
|
@@ -307,18 +435,51 @@ export declare const ContinuationIntentSchema: Schema.Struct<{
|
|
|
307
435
|
journeyId: Schema.filter<typeof Schema.String>;
|
|
308
436
|
parentRequestId: Schema.filter<typeof Schema.String>;
|
|
309
437
|
}>>;
|
|
438
|
+
epilogue: Schema.optional<Schema.filter<Schema.Struct<{
|
|
439
|
+
forwards: Schema.optional<Schema.NonEmptyArray<Schema.Struct<{
|
|
440
|
+
resource: Schema.transform<Schema.Union<[Schema.Struct<{
|
|
441
|
+
kind: Schema.Literal<["native"]>;
|
|
442
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
443
|
+
}>, Schema.Struct<{
|
|
444
|
+
kind: Schema.Literal<["erc20"]>;
|
|
445
|
+
token: Schema.refine<string, typeof Schema.String>;
|
|
446
|
+
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
447
|
+
}>]>, Schema.SchemaClass<{
|
|
448
|
+
readonly chainId: number;
|
|
449
|
+
readonly kind: "native";
|
|
450
|
+
} | {
|
|
451
|
+
readonly token: string;
|
|
452
|
+
readonly chainId: number;
|
|
453
|
+
readonly kind: "erc20";
|
|
454
|
+
}, {
|
|
455
|
+
readonly chainId: number;
|
|
456
|
+
readonly kind: "native";
|
|
457
|
+
} | {
|
|
458
|
+
readonly token: string;
|
|
459
|
+
readonly chainId: number;
|
|
460
|
+
readonly kind: "erc20";
|
|
461
|
+
}, never>>;
|
|
462
|
+
to: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
463
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
464
|
+
}>]>;
|
|
465
|
+
}>>>;
|
|
466
|
+
remainder: Schema.optional<Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Struct<{
|
|
467
|
+
$ref: Schema.filter<typeof Schema.String>;
|
|
468
|
+
}>]>>;
|
|
469
|
+
}>>>;
|
|
310
470
|
}>>;
|
|
311
471
|
validity: Schema.Struct<{
|
|
312
472
|
expiresAtMs: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
313
473
|
}>;
|
|
314
|
-
perpetual: Schema.optional<typeof Schema.Boolean>;
|
|
315
474
|
provider: Schema.optional<typeof Schema.String>;
|
|
316
475
|
funding: Schema.optional<Schema.Literal<["inline", "external"]>>;
|
|
476
|
+
refund: Schema.optional<Schema.filter<Schema.refine<string, typeof Schema.String>>>;
|
|
477
|
+
exact: Schema.optional<typeof Schema.Boolean>;
|
|
317
478
|
}>;
|
|
318
479
|
export declare const HexStringSchema: Schema.filter<typeof Schema.String>;
|
|
319
480
|
export declare const Phase1ArtifactSchema: Schema.Union<[Schema.Struct<{
|
|
320
481
|
kind: Schema.Literal<["transaction"]>;
|
|
321
|
-
funding: Schema.Literal<["inline", "external"]>;
|
|
482
|
+
funding: Schema.Literal<["inline", "external", "delivered"]>;
|
|
322
483
|
transactionRequest: Schema.optional<Schema.Struct<{
|
|
323
484
|
to: typeof Schema.String;
|
|
324
485
|
data: typeof Schema.String;
|
|
@@ -331,10 +492,21 @@ export declare const Phase1ArtifactSchema: Schema.Union<[Schema.Struct<{
|
|
|
331
492
|
token: Schema.filter<typeof Schema.String>;
|
|
332
493
|
amount: typeof Schema.String;
|
|
333
494
|
cap: typeof Schema.String;
|
|
495
|
+
floor: typeof Schema.String;
|
|
334
496
|
owner: Schema.filter<typeof Schema.String>;
|
|
335
497
|
refund: Schema.filter<typeof Schema.String>;
|
|
336
498
|
expiresAtMs: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
337
499
|
}>>;
|
|
500
|
+
binding: Schema.optional<Schema.Struct<{
|
|
501
|
+
executionTarget: Schema.filter<typeof Schema.String>;
|
|
502
|
+
payload: Schema.filter<typeof Schema.String>;
|
|
503
|
+
payloadHash: Schema.filter<typeof Schema.String>;
|
|
504
|
+
calldata: Schema.filter<typeof Schema.String>;
|
|
505
|
+
approvals: Schema.Array$<Schema.Struct<{
|
|
506
|
+
token: Schema.filter<typeof Schema.String>;
|
|
507
|
+
spender: Schema.filter<typeof Schema.String>;
|
|
508
|
+
}>>;
|
|
509
|
+
}>>;
|
|
338
510
|
}>, Schema.Struct<{
|
|
339
511
|
kind: Schema.Literal<["signables"]>;
|
|
340
512
|
typedData: Schema.Array$<typeof Schema.Unknown>;
|
|
@@ -347,87 +519,56 @@ export declare const Erc20BalanceGteSpecSchema: Schema.Struct<{
|
|
|
347
519
|
kind: Schema.Literal<["erc20BalanceGte"]>;
|
|
348
520
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
349
521
|
token: Schema.refine<string, typeof Schema.String>;
|
|
350
|
-
owner: Schema.refine<string, typeof Schema.String>;
|
|
522
|
+
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
351
523
|
minAmount: Schema.filter<typeof Schema.String>;
|
|
352
524
|
}>;
|
|
353
525
|
export declare const NativeBalanceGteSpecSchema: Schema.Struct<{
|
|
354
526
|
kind: Schema.Literal<["nativeBalanceGte"]>;
|
|
355
527
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
356
|
-
owner: Schema.refine<string, typeof Schema.String>;
|
|
528
|
+
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
357
529
|
minAmount: Schema.filter<typeof Schema.String>;
|
|
358
530
|
}>;
|
|
359
531
|
export declare const CallCheckSpecSchema: Schema.Struct<{
|
|
360
532
|
kind: Schema.Literal<["call"]>;
|
|
361
533
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
362
534
|
to: Schema.refine<string, typeof Schema.String>;
|
|
363
|
-
|
|
535
|
+
signature: typeof Schema.String;
|
|
536
|
+
args: Schema.Array$<typeof Schema.String>;
|
|
364
537
|
comparator: Schema.Literal<["gte", "eq", "lte"]>;
|
|
365
|
-
|
|
366
|
-
}>;
|
|
367
|
-
export declare const Erc20BalanceDeltaGteSpecSchema: Schema.Struct<{
|
|
368
|
-
kind: Schema.Literal<["erc20BalanceDeltaGte"]>;
|
|
369
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
370
|
-
token: Schema.refine<string, typeof Schema.String>;
|
|
371
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
372
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
373
|
-
}>;
|
|
374
|
-
export declare const NativeBalanceDeltaGteSpecSchema: Schema.Struct<{
|
|
375
|
-
kind: Schema.Literal<["nativeBalanceDeltaGte"]>;
|
|
376
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
377
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
378
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
538
|
+
threshold: Schema.filter<typeof Schema.String>;
|
|
379
539
|
}>;
|
|
380
540
|
export declare const AssertionSpecSchema: Schema.Union<[Schema.Struct<{
|
|
381
541
|
kind: Schema.Literal<["erc20BalanceGte"]>;
|
|
382
542
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
383
543
|
token: Schema.refine<string, typeof Schema.String>;
|
|
384
|
-
owner: Schema.refine<string, typeof Schema.String>;
|
|
544
|
+
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
385
545
|
minAmount: Schema.filter<typeof Schema.String>;
|
|
386
546
|
}>, Schema.Struct<{
|
|
387
547
|
kind: Schema.Literal<["nativeBalanceGte"]>;
|
|
388
548
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
389
|
-
owner: Schema.refine<string, typeof Schema.String>;
|
|
549
|
+
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
390
550
|
minAmount: Schema.filter<typeof Schema.String>;
|
|
391
551
|
}>, Schema.Struct<{
|
|
392
552
|
kind: Schema.Literal<["call"]>;
|
|
393
553
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
394
554
|
to: Schema.refine<string, typeof Schema.String>;
|
|
395
|
-
|
|
555
|
+
signature: typeof Schema.String;
|
|
556
|
+
args: Schema.Array$<typeof Schema.String>;
|
|
396
557
|
comparator: Schema.Literal<["gte", "eq", "lte"]>;
|
|
397
|
-
|
|
398
|
-
}>, Schema.Struct<{
|
|
399
|
-
kind: Schema.Literal<["erc20BalanceDeltaGte"]>;
|
|
400
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
401
|
-
token: Schema.refine<string, typeof Schema.String>;
|
|
402
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
403
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
404
|
-
}>, Schema.Struct<{
|
|
405
|
-
kind: Schema.Literal<["nativeBalanceDeltaGte"]>;
|
|
406
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
407
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
408
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
558
|
+
threshold: Schema.filter<typeof Schema.String>;
|
|
409
559
|
}>]>;
|
|
410
560
|
type ContinuationOutcome = typeof ContinuationOutcomeSchema.Type;
|
|
561
|
+
type CommittedOutcome = typeof CommittedOutcomeSchema.Type;
|
|
411
562
|
type ContinuationIntent = typeof ContinuationIntentSchema.Type;
|
|
412
563
|
type Phase1Artifact = typeof Phase1ArtifactSchema.Type;
|
|
413
564
|
type AssertionSpec = typeof AssertionSpecSchema.Type;
|
|
414
|
-
|
|
565
|
+
type CallCheckSpec = typeof CallCheckSpecSchema.Type;
|
|
566
|
+
export declare const settledOutcome: <I extends {
|
|
567
|
+
readonly outcomes: readonly [unknown, ...unknown[]];
|
|
568
|
+
}>(intent: I) => I["outcomes"][0];
|
|
415
569
|
//#endregion
|
|
416
570
|
//#region src/descriptor.d.ts
|
|
417
571
|
export declare const Bytes32HexSchema: Schema.filter<typeof Schema.String>;
|
|
418
|
-
export declare const AssertedErc20BalanceGteSpecSchema: Schema.Struct<{
|
|
419
|
-
kind: Schema.Literal<["erc20BalanceGte"]>;
|
|
420
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
421
|
-
token: Schema.refine<string, typeof Schema.String>;
|
|
422
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
423
|
-
minAmount: Schema.filter<typeof Schema.String>;
|
|
424
|
-
}>;
|
|
425
|
-
export declare const AssertedNativeBalanceGteSpecSchema: Schema.Struct<{
|
|
426
|
-
kind: Schema.Literal<["nativeBalanceGte"]>;
|
|
427
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
428
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
429
|
-
minAmount: Schema.filter<typeof Schema.String>;
|
|
430
|
-
}>;
|
|
431
572
|
export declare const AssertedPredicateSchema: Schema.transformOrFail<Schema.Union<[Schema.Struct<{
|
|
432
573
|
kind: Schema.Literal<["erc20BalanceGte"]>;
|
|
433
574
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
@@ -443,78 +584,48 @@ export declare const AssertedPredicateSchema: Schema.transformOrFail<Schema.Unio
|
|
|
443
584
|
kind: Schema.Literal<["call"]>;
|
|
444
585
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
445
586
|
to: Schema.refine<string, typeof Schema.String>;
|
|
446
|
-
|
|
587
|
+
signature: typeof Schema.String;
|
|
588
|
+
args: Schema.Array$<typeof Schema.String>;
|
|
447
589
|
comparator: Schema.Literal<["gte", "eq", "lte"]>;
|
|
448
|
-
|
|
449
|
-
}>, Schema.Struct<{
|
|
450
|
-
kind: Schema.Literal<["erc20BalanceDeltaGte"]>;
|
|
451
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
452
|
-
token: Schema.refine<string, typeof Schema.String>;
|
|
453
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
454
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
455
|
-
}>, Schema.Struct<{
|
|
456
|
-
kind: Schema.Literal<["nativeBalanceDeltaGte"]>;
|
|
457
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
458
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
459
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
590
|
+
threshold: Schema.filter<typeof Schema.String>;
|
|
460
591
|
}>]>, Schema.SchemaClass<{
|
|
461
|
-
readonly
|
|
462
|
-
readonly kind: "call";
|
|
463
|
-
readonly chainId: number;
|
|
464
|
-
readonly to: string;
|
|
465
|
-
readonly calldata: string;
|
|
466
|
-
readonly comparator: "gte" | "eq" | "lte";
|
|
467
|
-
} | {
|
|
468
|
-
readonly kind: "erc20BalanceDeltaGte";
|
|
592
|
+
readonly minAmount: string;
|
|
469
593
|
readonly chainId: number;
|
|
470
|
-
readonly
|
|
594
|
+
readonly kind: "nativeBalanceGte";
|
|
471
595
|
readonly owner: string;
|
|
472
|
-
readonly minDelta: string;
|
|
473
596
|
} | {
|
|
474
|
-
readonly
|
|
597
|
+
readonly token: string;
|
|
598
|
+
readonly minAmount: string;
|
|
475
599
|
readonly chainId: number;
|
|
476
|
-
readonly owner: string;
|
|
477
|
-
readonly minDelta: string;
|
|
478
|
-
} | {
|
|
479
600
|
readonly kind: "erc20BalanceGte";
|
|
480
|
-
readonly chainId: number;
|
|
481
|
-
readonly token: string;
|
|
482
601
|
readonly owner: string;
|
|
483
|
-
readonly minAmount: string;
|
|
484
602
|
} | {
|
|
485
|
-
readonly kind: "nativeBalanceGte";
|
|
486
603
|
readonly chainId: number;
|
|
487
|
-
readonly owner: string;
|
|
488
|
-
readonly minAmount: string;
|
|
489
|
-
}, {
|
|
490
|
-
readonly value: string;
|
|
491
604
|
readonly kind: "call";
|
|
492
|
-
readonly chainId: number;
|
|
493
605
|
readonly to: string;
|
|
494
|
-
readonly
|
|
606
|
+
readonly signature: string;
|
|
607
|
+
readonly args: readonly string[];
|
|
495
608
|
readonly comparator: "gte" | "eq" | "lte";
|
|
496
|
-
|
|
497
|
-
|
|
609
|
+
readonly threshold: string;
|
|
610
|
+
}, {
|
|
611
|
+
readonly minAmount: string;
|
|
498
612
|
readonly chainId: number;
|
|
499
|
-
readonly
|
|
613
|
+
readonly kind: "nativeBalanceGte";
|
|
500
614
|
readonly owner: string;
|
|
501
|
-
readonly minDelta: string;
|
|
502
615
|
} | {
|
|
503
|
-
readonly
|
|
616
|
+
readonly token: string;
|
|
617
|
+
readonly minAmount: string;
|
|
504
618
|
readonly chainId: number;
|
|
505
|
-
readonly owner: string;
|
|
506
|
-
readonly minDelta: string;
|
|
507
|
-
} | {
|
|
508
619
|
readonly kind: "erc20BalanceGte";
|
|
509
|
-
readonly chainId: number;
|
|
510
|
-
readonly token: string;
|
|
511
620
|
readonly owner: string;
|
|
512
|
-
readonly minAmount: string;
|
|
513
621
|
} | {
|
|
514
|
-
readonly kind: "nativeBalanceGte";
|
|
515
622
|
readonly chainId: number;
|
|
516
|
-
readonly
|
|
517
|
-
readonly
|
|
623
|
+
readonly kind: "call";
|
|
624
|
+
readonly to: string;
|
|
625
|
+
readonly signature: string;
|
|
626
|
+
readonly args: readonly string[];
|
|
627
|
+
readonly comparator: "gte" | "eq" | "lte";
|
|
628
|
+
readonly threshold: string;
|
|
518
629
|
}, never>, never>;
|
|
519
630
|
export declare const VerificationDescriptorSchema: Schema.Struct<{
|
|
520
631
|
validationProgramHash: Schema.filter<typeof Schema.String>;
|
|
@@ -534,78 +645,48 @@ export declare const VerificationDescriptorSchema: Schema.Struct<{
|
|
|
534
645
|
kind: Schema.Literal<["call"]>;
|
|
535
646
|
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
536
647
|
to: Schema.refine<string, typeof Schema.String>;
|
|
537
|
-
|
|
648
|
+
signature: typeof Schema.String;
|
|
649
|
+
args: Schema.Array$<typeof Schema.String>;
|
|
538
650
|
comparator: Schema.Literal<["gte", "eq", "lte"]>;
|
|
539
|
-
|
|
540
|
-
}>, Schema.Struct<{
|
|
541
|
-
kind: Schema.Literal<["erc20BalanceDeltaGte"]>;
|
|
542
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
543
|
-
token: Schema.refine<string, typeof Schema.String>;
|
|
544
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
545
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
546
|
-
}>, Schema.Struct<{
|
|
547
|
-
kind: Schema.Literal<["nativeBalanceDeltaGte"]>;
|
|
548
|
-
chainId: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
549
|
-
owner: Schema.Union<[Schema.refine<string, typeof Schema.String>, Schema.Literal<["escrow", "delivery"]>]>;
|
|
550
|
-
minDelta: Schema.filter<typeof Schema.String>;
|
|
651
|
+
threshold: Schema.filter<typeof Schema.String>;
|
|
551
652
|
}>]>, Schema.SchemaClass<{
|
|
552
|
-
readonly
|
|
553
|
-
readonly kind: "call";
|
|
554
|
-
readonly chainId: number;
|
|
555
|
-
readonly to: string;
|
|
556
|
-
readonly calldata: string;
|
|
557
|
-
readonly comparator: "gte" | "eq" | "lte";
|
|
558
|
-
} | {
|
|
559
|
-
readonly kind: "erc20BalanceDeltaGte";
|
|
653
|
+
readonly minAmount: string;
|
|
560
654
|
readonly chainId: number;
|
|
561
|
-
readonly
|
|
655
|
+
readonly kind: "nativeBalanceGte";
|
|
562
656
|
readonly owner: string;
|
|
563
|
-
readonly minDelta: string;
|
|
564
657
|
} | {
|
|
565
|
-
readonly
|
|
658
|
+
readonly token: string;
|
|
659
|
+
readonly minAmount: string;
|
|
566
660
|
readonly chainId: number;
|
|
567
|
-
readonly owner: string;
|
|
568
|
-
readonly minDelta: string;
|
|
569
|
-
} | {
|
|
570
661
|
readonly kind: "erc20BalanceGte";
|
|
571
|
-
readonly chainId: number;
|
|
572
|
-
readonly token: string;
|
|
573
662
|
readonly owner: string;
|
|
574
|
-
readonly minAmount: string;
|
|
575
663
|
} | {
|
|
576
|
-
readonly kind: "nativeBalanceGte";
|
|
577
664
|
readonly chainId: number;
|
|
578
|
-
readonly owner: string;
|
|
579
|
-
readonly minAmount: string;
|
|
580
|
-
}, {
|
|
581
|
-
readonly value: string;
|
|
582
665
|
readonly kind: "call";
|
|
583
|
-
readonly chainId: number;
|
|
584
666
|
readonly to: string;
|
|
585
|
-
readonly
|
|
667
|
+
readonly signature: string;
|
|
668
|
+
readonly args: readonly string[];
|
|
586
669
|
readonly comparator: "gte" | "eq" | "lte";
|
|
587
|
-
|
|
588
|
-
|
|
670
|
+
readonly threshold: string;
|
|
671
|
+
}, {
|
|
672
|
+
readonly minAmount: string;
|
|
589
673
|
readonly chainId: number;
|
|
590
|
-
readonly
|
|
674
|
+
readonly kind: "nativeBalanceGte";
|
|
591
675
|
readonly owner: string;
|
|
592
|
-
readonly minDelta: string;
|
|
593
676
|
} | {
|
|
594
|
-
readonly
|
|
677
|
+
readonly token: string;
|
|
678
|
+
readonly minAmount: string;
|
|
595
679
|
readonly chainId: number;
|
|
596
|
-
readonly owner: string;
|
|
597
|
-
readonly minDelta: string;
|
|
598
|
-
} | {
|
|
599
680
|
readonly kind: "erc20BalanceGte";
|
|
600
|
-
readonly chainId: number;
|
|
601
|
-
readonly token: string;
|
|
602
681
|
readonly owner: string;
|
|
603
|
-
readonly minAmount: string;
|
|
604
682
|
} | {
|
|
605
|
-
readonly kind: "nativeBalanceGte";
|
|
606
683
|
readonly chainId: number;
|
|
607
|
-
readonly
|
|
608
|
-
readonly
|
|
684
|
+
readonly kind: "call";
|
|
685
|
+
readonly to: string;
|
|
686
|
+
readonly signature: string;
|
|
687
|
+
readonly args: readonly string[];
|
|
688
|
+
readonly comparator: "gte" | "eq" | "lte";
|
|
689
|
+
readonly threshold: string;
|
|
609
690
|
}, never>, never>>;
|
|
610
691
|
}>;
|
|
611
692
|
export declare const canonicalAssertedPredicate: (specs: readonly AssertionSpec[]) => string;
|
|
@@ -618,26 +699,24 @@ interface OutputAmount {
|
|
|
618
699
|
readonly expected: bigint;
|
|
619
700
|
readonly min?: bigint;
|
|
620
701
|
}
|
|
621
|
-
|
|
702
|
+
interface NativeResource {
|
|
622
703
|
readonly kind: 'native';
|
|
623
704
|
readonly chainId: number;
|
|
624
|
-
}
|
|
705
|
+
}
|
|
706
|
+
interface ERC20Resource {
|
|
625
707
|
readonly kind: 'erc20';
|
|
626
708
|
readonly token: string;
|
|
627
709
|
readonly chainId: number;
|
|
628
|
-
}
|
|
710
|
+
}
|
|
711
|
+
type Resource = NativeResource | ERC20Resource;
|
|
629
712
|
export declare const erc20Resource: (token: string, chainId: number) => Resource;
|
|
630
713
|
export declare const nativeResource: (chainId: number) => Resource;
|
|
631
|
-
export declare const isERC20Resource: (r: Resource) => r is
|
|
632
|
-
|
|
633
|
-
}>;
|
|
634
|
-
export declare const isNativeResource: (r: Resource) => r is Extract<Resource, {
|
|
635
|
-
kind: "native";
|
|
636
|
-
}>;
|
|
714
|
+
export declare const isERC20Resource: (r: Resource) => r is ERC20Resource;
|
|
715
|
+
export declare const isNativeResource: (r: Resource) => r is NativeResource;
|
|
637
716
|
export declare const resourcesEqual: (a: Resource, b: Resource) => boolean;
|
|
638
717
|
export declare const foldResource: <R>(r: Resource, cases: {
|
|
639
|
-
readonly native: (
|
|
640
|
-
readonly erc20: (
|
|
718
|
+
readonly native: (r: NativeResource) => R;
|
|
719
|
+
readonly erc20: (r: ERC20Resource) => R;
|
|
641
720
|
}) => R;
|
|
642
721
|
export declare const resourceToken: (r: Resource) => string;
|
|
643
722
|
export declare const resourceKey: (r: Resource) => string;
|
|
@@ -645,7 +724,7 @@ export declare const erc20Token: (r: Resource) => string;
|
|
|
645
724
|
//#endregion
|
|
646
725
|
//#region src/output.d.ts
|
|
647
726
|
type EstimateBasis = 'simulated' | 'quoted';
|
|
648
|
-
type MinimumBasis = 'guard' | 'op' | 'declared';
|
|
727
|
+
type MinimumBasis = 'guard' | 'op' | 'input' | 'declared';
|
|
649
728
|
interface Estimate {
|
|
650
729
|
readonly basis: EstimateBasis;
|
|
651
730
|
readonly value: bigint;
|
|
@@ -664,6 +743,7 @@ type Delivery = {
|
|
|
664
743
|
readonly when: 'future';
|
|
665
744
|
readonly etaSeconds?: number;
|
|
666
745
|
readonly provider?: string;
|
|
746
|
+
readonly trackingId?: string;
|
|
667
747
|
};
|
|
668
748
|
interface OutputBase {
|
|
669
749
|
readonly resource: Resource;
|
|
@@ -686,8 +766,8 @@ export declare const ResourcePortZod: z.ZodObject<{
|
|
|
686
766
|
kind: z.ZodLiteral<"resource">;
|
|
687
767
|
name: z.ZodString;
|
|
688
768
|
accepts: z.ZodEnum<{
|
|
689
|
-
erc20: "erc20";
|
|
690
769
|
native: "native";
|
|
770
|
+
erc20: "erc20";
|
|
691
771
|
any: "any";
|
|
692
772
|
}>;
|
|
693
773
|
mode: z.ZodEnum<{
|
|
@@ -706,12 +786,12 @@ export declare const HandleUnitsZod: z.ZodEnum<{
|
|
|
706
786
|
"token-decimals": "token-decimals";
|
|
707
787
|
}>;
|
|
708
788
|
export declare const StaticSolTypeZod: z.ZodEnum<{
|
|
789
|
+
uint8: "uint8";
|
|
790
|
+
uint16: "uint16";
|
|
709
791
|
uint32: "uint32";
|
|
710
|
-
uint256: "uint256";
|
|
711
|
-
uint128: "uint128";
|
|
712
792
|
uint64: "uint64";
|
|
713
|
-
|
|
714
|
-
|
|
793
|
+
uint128: "uint128";
|
|
794
|
+
uint256: "uint256";
|
|
715
795
|
address: "address";
|
|
716
796
|
bool: "bool";
|
|
717
797
|
bytes32: "bytes32";
|
|
@@ -722,19 +802,19 @@ export declare const HandlePortZod: z.ZodObject<{
|
|
|
722
802
|
name: z.ZodString;
|
|
723
803
|
type: z.ZodEnum<{
|
|
724
804
|
string: "string";
|
|
805
|
+
uint8: "uint8";
|
|
806
|
+
uint16: "uint16";
|
|
725
807
|
uint32: "uint32";
|
|
726
|
-
uint256: "uint256";
|
|
727
|
-
uint128: "uint128";
|
|
728
808
|
uint64: "uint64";
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
address: "address";
|
|
732
|
-
bool: "bool";
|
|
733
|
-
bytes32: "bytes32";
|
|
809
|
+
uint128: "uint128";
|
|
810
|
+
uint256: "uint256";
|
|
734
811
|
int128: "int128";
|
|
735
812
|
int256: "int256";
|
|
813
|
+
address: "address";
|
|
814
|
+
bool: "bool";
|
|
736
815
|
bytes: "bytes";
|
|
737
816
|
bytes4: "bytes4";
|
|
817
|
+
bytes32: "bytes32";
|
|
738
818
|
}>;
|
|
739
819
|
mode: z.ZodEnum<{
|
|
740
820
|
linear: "linear";
|
|
@@ -754,8 +834,8 @@ export declare const InputPortZod: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
754
834
|
kind: z.ZodLiteral<"resource">;
|
|
755
835
|
name: z.ZodString;
|
|
756
836
|
accepts: z.ZodEnum<{
|
|
757
|
-
erc20: "erc20";
|
|
758
837
|
native: "native";
|
|
838
|
+
erc20: "erc20";
|
|
759
839
|
any: "any";
|
|
760
840
|
}>;
|
|
761
841
|
mode: z.ZodEnum<{
|
|
@@ -768,19 +848,19 @@ export declare const InputPortZod: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
768
848
|
name: z.ZodString;
|
|
769
849
|
type: z.ZodEnum<{
|
|
770
850
|
string: "string";
|
|
851
|
+
uint8: "uint8";
|
|
852
|
+
uint16: "uint16";
|
|
771
853
|
uint32: "uint32";
|
|
772
|
-
uint256: "uint256";
|
|
773
|
-
uint128: "uint128";
|
|
774
854
|
uint64: "uint64";
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
address: "address";
|
|
778
|
-
bool: "bool";
|
|
779
|
-
bytes32: "bytes32";
|
|
855
|
+
uint128: "uint128";
|
|
856
|
+
uint256: "uint256";
|
|
780
857
|
int128: "int128";
|
|
781
858
|
int256: "int256";
|
|
859
|
+
address: "address";
|
|
860
|
+
bool: "bool";
|
|
782
861
|
bytes: "bytes";
|
|
783
862
|
bytes4: "bytes4";
|
|
863
|
+
bytes32: "bytes32";
|
|
784
864
|
}>;
|
|
785
865
|
mode: z.ZodEnum<{
|
|
786
866
|
linear: "linear";
|
|
@@ -832,19 +912,19 @@ export declare const OutputPortZod: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
832
912
|
name: z.ZodString;
|
|
833
913
|
type: z.ZodEnum<{
|
|
834
914
|
string: "string";
|
|
915
|
+
uint8: "uint8";
|
|
916
|
+
uint16: "uint16";
|
|
835
917
|
uint32: "uint32";
|
|
836
|
-
uint256: "uint256";
|
|
837
|
-
uint128: "uint128";
|
|
838
918
|
uint64: "uint64";
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
address: "address";
|
|
842
|
-
bool: "bool";
|
|
843
|
-
bytes32: "bytes32";
|
|
919
|
+
uint128: "uint128";
|
|
920
|
+
uint256: "uint256";
|
|
844
921
|
int128: "int128";
|
|
845
922
|
int256: "int256";
|
|
923
|
+
address: "address";
|
|
924
|
+
bool: "bool";
|
|
846
925
|
bytes: "bytes";
|
|
847
926
|
bytes4: "bytes4";
|
|
927
|
+
bytes32: "bytes32";
|
|
848
928
|
}>;
|
|
849
929
|
mode: z.ZodEnum<{
|
|
850
930
|
linear: "linear";
|
|
@@ -867,8 +947,8 @@ export declare const ManifestOperationZod: z.ZodObject<{
|
|
|
867
947
|
kind: z.ZodLiteral<"resource">;
|
|
868
948
|
name: z.ZodString;
|
|
869
949
|
accepts: z.ZodEnum<{
|
|
870
|
-
erc20: "erc20";
|
|
871
950
|
native: "native";
|
|
951
|
+
erc20: "erc20";
|
|
872
952
|
any: "any";
|
|
873
953
|
}>;
|
|
874
954
|
mode: z.ZodEnum<{
|
|
@@ -881,19 +961,19 @@ export declare const ManifestOperationZod: z.ZodObject<{
|
|
|
881
961
|
name: z.ZodString;
|
|
882
962
|
type: z.ZodEnum<{
|
|
883
963
|
string: "string";
|
|
964
|
+
uint8: "uint8";
|
|
965
|
+
uint16: "uint16";
|
|
884
966
|
uint32: "uint32";
|
|
885
|
-
uint256: "uint256";
|
|
886
|
-
uint128: "uint128";
|
|
887
967
|
uint64: "uint64";
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
address: "address";
|
|
891
|
-
bool: "bool";
|
|
892
|
-
bytes32: "bytes32";
|
|
968
|
+
uint128: "uint128";
|
|
969
|
+
uint256: "uint256";
|
|
893
970
|
int128: "int128";
|
|
894
971
|
int256: "int256";
|
|
972
|
+
address: "address";
|
|
973
|
+
bool: "bool";
|
|
895
974
|
bytes: "bytes";
|
|
896
975
|
bytes4: "bytes4";
|
|
976
|
+
bytes32: "bytes32";
|
|
897
977
|
}>;
|
|
898
978
|
mode: z.ZodEnum<{
|
|
899
979
|
linear: "linear";
|
|
@@ -929,19 +1009,19 @@ export declare const ManifestOperationZod: z.ZodObject<{
|
|
|
929
1009
|
name: z.ZodString;
|
|
930
1010
|
type: z.ZodEnum<{
|
|
931
1011
|
string: "string";
|
|
1012
|
+
uint8: "uint8";
|
|
1013
|
+
uint16: "uint16";
|
|
932
1014
|
uint32: "uint32";
|
|
933
|
-
uint256: "uint256";
|
|
934
|
-
uint128: "uint128";
|
|
935
1015
|
uint64: "uint64";
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
address: "address";
|
|
939
|
-
bool: "bool";
|
|
940
|
-
bytes32: "bytes32";
|
|
1016
|
+
uint128: "uint128";
|
|
1017
|
+
uint256: "uint256";
|
|
941
1018
|
int128: "int128";
|
|
942
1019
|
int256: "int256";
|
|
1020
|
+
address: "address";
|
|
1021
|
+
bool: "bool";
|
|
943
1022
|
bytes: "bytes";
|
|
944
1023
|
bytes4: "bytes4";
|
|
1024
|
+
bytes32: "bytes32";
|
|
945
1025
|
}>;
|
|
946
1026
|
mode: z.ZodEnum<{
|
|
947
1027
|
linear: "linear";
|
|
@@ -980,8 +1060,8 @@ export declare const GuardSelectorZod: z.ZodObject<{
|
|
|
980
1060
|
copy: "copy";
|
|
981
1061
|
}>>;
|
|
982
1062
|
type: z.ZodOptional<z.ZodEnum<{
|
|
983
|
-
erc20: "erc20";
|
|
984
1063
|
native: "native";
|
|
1064
|
+
erc20: "erc20";
|
|
985
1065
|
any: "any";
|
|
986
1066
|
}>>;
|
|
987
1067
|
}, z.core.$strip>;
|
|
@@ -1018,8 +1098,8 @@ export declare const GuardCompatibilityZod: z.ZodObject<{
|
|
|
1018
1098
|
copy: "copy";
|
|
1019
1099
|
}>>;
|
|
1020
1100
|
type: z.ZodOptional<z.ZodEnum<{
|
|
1021
|
-
erc20: "erc20";
|
|
1022
1101
|
native: "native";
|
|
1102
|
+
erc20: "erc20";
|
|
1023
1103
|
any: "any";
|
|
1024
1104
|
}>>;
|
|
1025
1105
|
}, z.core.$strip>;
|
|
@@ -1061,8 +1141,8 @@ export declare const ManifestGuardZod: z.ZodObject<{
|
|
|
1061
1141
|
copy: "copy";
|
|
1062
1142
|
}>>;
|
|
1063
1143
|
type: z.ZodOptional<z.ZodEnum<{
|
|
1064
|
-
erc20: "erc20";
|
|
1065
1144
|
native: "native";
|
|
1145
|
+
erc20: "erc20";
|
|
1066
1146
|
any: "any";
|
|
1067
1147
|
}>>;
|
|
1068
1148
|
}, z.core.$strip>;
|
|
@@ -1094,6 +1174,13 @@ export declare const ManifestPreconditionZod: z.ZodObject<{
|
|
|
1094
1174
|
description: z.ZodOptional<z.ZodString>;
|
|
1095
1175
|
configSchema: z.ZodOptional<z.ZodUnknown>;
|
|
1096
1176
|
}, z.core.$strip>;
|
|
1177
|
+
export declare const ManifestRoutingZod: z.ZodObject<{
|
|
1178
|
+
maxRouteHops: z.ZodNumber;
|
|
1179
|
+
swapHops: z.ZodEnum<{
|
|
1180
|
+
none: "none";
|
|
1181
|
+
head: "head";
|
|
1182
|
+
}>;
|
|
1183
|
+
}, z.core.$strip>;
|
|
1097
1184
|
export declare const ComposeManifestZod: z.ZodObject<{
|
|
1098
1185
|
manifestVersion: z.ZodNumber;
|
|
1099
1186
|
manifestHash: z.ZodString;
|
|
@@ -1105,8 +1192,8 @@ export declare const ComposeManifestZod: z.ZodObject<{
|
|
|
1105
1192
|
kind: z.ZodLiteral<"resource">;
|
|
1106
1193
|
name: z.ZodString;
|
|
1107
1194
|
accepts: z.ZodEnum<{
|
|
1108
|
-
erc20: "erc20";
|
|
1109
1195
|
native: "native";
|
|
1196
|
+
erc20: "erc20";
|
|
1110
1197
|
any: "any";
|
|
1111
1198
|
}>;
|
|
1112
1199
|
mode: z.ZodEnum<{
|
|
@@ -1119,19 +1206,19 @@ export declare const ComposeManifestZod: z.ZodObject<{
|
|
|
1119
1206
|
name: z.ZodString;
|
|
1120
1207
|
type: z.ZodEnum<{
|
|
1121
1208
|
string: "string";
|
|
1122
|
-
uint32: "uint32";
|
|
1123
|
-
uint256: "uint256";
|
|
1124
|
-
uint128: "uint128";
|
|
1125
|
-
uint64: "uint64";
|
|
1126
|
-
uint16: "uint16";
|
|
1127
1209
|
uint8: "uint8";
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1210
|
+
uint16: "uint16";
|
|
1211
|
+
uint32: "uint32";
|
|
1212
|
+
uint64: "uint64";
|
|
1213
|
+
uint128: "uint128";
|
|
1214
|
+
uint256: "uint256";
|
|
1131
1215
|
int128: "int128";
|
|
1132
1216
|
int256: "int256";
|
|
1217
|
+
address: "address";
|
|
1218
|
+
bool: "bool";
|
|
1133
1219
|
bytes: "bytes";
|
|
1134
1220
|
bytes4: "bytes4";
|
|
1221
|
+
bytes32: "bytes32";
|
|
1135
1222
|
}>;
|
|
1136
1223
|
mode: z.ZodEnum<{
|
|
1137
1224
|
linear: "linear";
|
|
@@ -1167,19 +1254,19 @@ export declare const ComposeManifestZod: z.ZodObject<{
|
|
|
1167
1254
|
name: z.ZodString;
|
|
1168
1255
|
type: z.ZodEnum<{
|
|
1169
1256
|
string: "string";
|
|
1257
|
+
uint8: "uint8";
|
|
1258
|
+
uint16: "uint16";
|
|
1170
1259
|
uint32: "uint32";
|
|
1171
|
-
uint256: "uint256";
|
|
1172
|
-
uint128: "uint128";
|
|
1173
1260
|
uint64: "uint64";
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
address: "address";
|
|
1177
|
-
bool: "bool";
|
|
1178
|
-
bytes32: "bytes32";
|
|
1261
|
+
uint128: "uint128";
|
|
1262
|
+
uint256: "uint256";
|
|
1179
1263
|
int128: "int128";
|
|
1180
1264
|
int256: "int256";
|
|
1265
|
+
address: "address";
|
|
1266
|
+
bool: "bool";
|
|
1181
1267
|
bytes: "bytes";
|
|
1182
1268
|
bytes4: "bytes4";
|
|
1269
|
+
bytes32: "bytes32";
|
|
1183
1270
|
}>;
|
|
1184
1271
|
mode: z.ZodEnum<{
|
|
1185
1272
|
linear: "linear";
|
|
@@ -1223,8 +1310,8 @@ export declare const ComposeManifestZod: z.ZodObject<{
|
|
|
1223
1310
|
copy: "copy";
|
|
1224
1311
|
}>>;
|
|
1225
1312
|
type: z.ZodOptional<z.ZodEnum<{
|
|
1226
|
-
erc20: "erc20";
|
|
1227
1313
|
native: "native";
|
|
1314
|
+
erc20: "erc20";
|
|
1228
1315
|
any: "any";
|
|
1229
1316
|
}>>;
|
|
1230
1317
|
}, z.core.$strip>;
|
|
@@ -1256,6 +1343,13 @@ export declare const ComposeManifestZod: z.ZodObject<{
|
|
|
1256
1343
|
description: z.ZodOptional<z.ZodString>;
|
|
1257
1344
|
configSchema: z.ZodOptional<z.ZodUnknown>;
|
|
1258
1345
|
}, z.core.$strip>>>;
|
|
1346
|
+
routing: z.ZodOptional<z.ZodObject<{
|
|
1347
|
+
maxRouteHops: z.ZodNumber;
|
|
1348
|
+
swapHops: z.ZodEnum<{
|
|
1349
|
+
none: "none";
|
|
1350
|
+
head: "head";
|
|
1351
|
+
}>;
|
|
1352
|
+
}, z.core.$strip>>;
|
|
1259
1353
|
}, z.core.$strip>;
|
|
1260
1354
|
declare const SettlementEscrowZod: z.ZodObject<{
|
|
1261
1355
|
chainId: z.ZodNumber;
|
|
@@ -1263,52 +1357,22 @@ declare const SettlementEscrowZod: z.ZodObject<{
|
|
|
1263
1357
|
token: z.ZodString;
|
|
1264
1358
|
amount: z.ZodString;
|
|
1265
1359
|
cap: z.ZodString;
|
|
1360
|
+
floor: z.ZodString;
|
|
1266
1361
|
owner: z.ZodString;
|
|
1267
1362
|
refund: z.ZodString;
|
|
1268
1363
|
expiresAtMs: z.ZodNumber;
|
|
1269
1364
|
}, z.core.$strip>;
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
owner: z.ZodString;
|
|
1275
|
-
minAmount: z.ZodString;
|
|
1276
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1277
|
-
kind: z.ZodLiteral<"nativeBalanceGte">;
|
|
1278
|
-
chainId: z.ZodNumber;
|
|
1279
|
-
owner: z.ZodString;
|
|
1280
|
-
minAmount: z.ZodString;
|
|
1281
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1282
|
-
kind: z.ZodLiteral<"call">;
|
|
1283
|
-
chainId: z.ZodNumber;
|
|
1284
|
-
to: z.ZodString;
|
|
1365
|
+
declare const SettlementBindingZod: z.ZodObject<{
|
|
1366
|
+
executionTarget: z.ZodString;
|
|
1367
|
+
payload: z.ZodString;
|
|
1368
|
+
payloadHash: z.ZodString;
|
|
1285
1369
|
calldata: z.ZodString;
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1293
|
-
kind: z.ZodLiteral<"erc20BalanceDeltaGte">;
|
|
1294
|
-
chainId: z.ZodNumber;
|
|
1295
|
-
token: z.ZodString;
|
|
1296
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1297
|
-
escrow: "escrow";
|
|
1298
|
-
delivery: "delivery";
|
|
1299
|
-
}>]>;
|
|
1300
|
-
minDelta: z.ZodString;
|
|
1301
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1302
|
-
kind: z.ZodLiteral<"nativeBalanceDeltaGte">;
|
|
1303
|
-
chainId: z.ZodNumber;
|
|
1304
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1305
|
-
escrow: "escrow";
|
|
1306
|
-
delivery: "delivery";
|
|
1307
|
-
}>]>;
|
|
1308
|
-
minDelta: z.ZodString;
|
|
1309
|
-
}, z.core.$strip>], "kind">;
|
|
1310
|
-
type AssertionSpecWire = z.infer<typeof AssertionSpecZod>;
|
|
1311
|
-
export declare const AssertedPredicateZod: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1370
|
+
approvals: z.ZodReadonly<z.ZodArray<z.ZodObject<{
|
|
1371
|
+
token: z.ZodString;
|
|
1372
|
+
spender: z.ZodString;
|
|
1373
|
+
}, z.core.$strip>>>;
|
|
1374
|
+
}, z.core.$strip>;
|
|
1375
|
+
export declare const AssertionSpecZod: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1312
1376
|
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1313
1377
|
chainId: z.ZodNumber;
|
|
1314
1378
|
token: z.ZodString;
|
|
@@ -1326,127 +1390,23 @@ export declare const AssertedPredicateZod: z.ZodDiscriminatedUnion<[z.ZodObject<
|
|
|
1326
1390
|
}>]>;
|
|
1327
1391
|
minAmount: z.ZodString;
|
|
1328
1392
|
}, z.core.$strip>, z.ZodObject<{
|
|
1329
|
-
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1330
|
-
chainId: z.ZodNumber;
|
|
1331
|
-
token: z.ZodString;
|
|
1332
|
-
owner: z.ZodString;
|
|
1333
|
-
minAmount: z.ZodString;
|
|
1334
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1335
|
-
kind: z.ZodLiteral<"nativeBalanceGte">;
|
|
1336
|
-
chainId: z.ZodNumber;
|
|
1337
|
-
owner: z.ZodString;
|
|
1338
|
-
minAmount: z.ZodString;
|
|
1339
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1340
|
-
kind: z.ZodLiteral<"call">;
|
|
1341
|
-
chainId: z.ZodNumber;
|
|
1342
|
-
to: z.ZodString;
|
|
1343
|
-
calldata: z.ZodString;
|
|
1344
|
-
comparator: z.ZodEnum<{
|
|
1345
|
-
gte: "gte";
|
|
1346
|
-
eq: "eq";
|
|
1347
|
-
lte: "lte";
|
|
1348
|
-
}>;
|
|
1349
|
-
value: z.ZodString;
|
|
1350
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1351
|
-
kind: z.ZodLiteral<"erc20BalanceDeltaGte">;
|
|
1352
|
-
chainId: z.ZodNumber;
|
|
1353
|
-
token: z.ZodString;
|
|
1354
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1355
|
-
escrow: "escrow";
|
|
1356
|
-
delivery: "delivery";
|
|
1357
|
-
}>]>;
|
|
1358
|
-
minDelta: z.ZodString;
|
|
1359
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1360
|
-
kind: z.ZodLiteral<"nativeBalanceDeltaGte">;
|
|
1361
|
-
chainId: z.ZodNumber;
|
|
1362
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1363
|
-
escrow: "escrow";
|
|
1364
|
-
delivery: "delivery";
|
|
1365
|
-
}>]>;
|
|
1366
|
-
minDelta: z.ZodString;
|
|
1367
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1368
|
-
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1369
|
-
chainId: z.ZodNumber;
|
|
1370
|
-
token: z.ZodString;
|
|
1371
|
-
owner: z.ZodString;
|
|
1372
|
-
minAmount: z.ZodString;
|
|
1373
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1374
|
-
kind: z.ZodLiteral<"nativeBalanceGte">;
|
|
1375
|
-
chainId: z.ZodNumber;
|
|
1376
|
-
owner: z.ZodString;
|
|
1377
|
-
minAmount: z.ZodString;
|
|
1378
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1379
|
-
kind: z.ZodLiteral<"call">;
|
|
1380
|
-
chainId: z.ZodNumber;
|
|
1381
|
-
to: z.ZodString;
|
|
1382
|
-
calldata: z.ZodString;
|
|
1383
|
-
comparator: z.ZodEnum<{
|
|
1384
|
-
gte: "gte";
|
|
1385
|
-
eq: "eq";
|
|
1386
|
-
lte: "lte";
|
|
1387
|
-
}>;
|
|
1388
|
-
value: z.ZodString;
|
|
1389
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1390
|
-
kind: z.ZodLiteral<"erc20BalanceDeltaGte">;
|
|
1391
|
-
chainId: z.ZodNumber;
|
|
1392
|
-
token: z.ZodString;
|
|
1393
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1394
|
-
escrow: "escrow";
|
|
1395
|
-
delivery: "delivery";
|
|
1396
|
-
}>]>;
|
|
1397
|
-
minDelta: z.ZodString;
|
|
1398
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1399
|
-
kind: z.ZodLiteral<"nativeBalanceDeltaGte">;
|
|
1400
|
-
chainId: z.ZodNumber;
|
|
1401
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1402
|
-
escrow: "escrow";
|
|
1403
|
-
delivery: "delivery";
|
|
1404
|
-
}>]>;
|
|
1405
|
-
minDelta: z.ZodString;
|
|
1406
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1407
|
-
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1408
|
-
chainId: z.ZodNumber;
|
|
1409
|
-
token: z.ZodString;
|
|
1410
|
-
owner: z.ZodString;
|
|
1411
|
-
minAmount: z.ZodString;
|
|
1412
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1413
|
-
kind: z.ZodLiteral<"nativeBalanceGte">;
|
|
1414
|
-
chainId: z.ZodNumber;
|
|
1415
|
-
owner: z.ZodString;
|
|
1416
|
-
minAmount: z.ZodString;
|
|
1417
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1418
1393
|
kind: z.ZodLiteral<"call">;
|
|
1419
1394
|
chainId: z.ZodNumber;
|
|
1420
1395
|
to: z.ZodString;
|
|
1421
|
-
|
|
1396
|
+
signature: z.ZodString;
|
|
1397
|
+
args: z.ZodReadonly<z.ZodArray<z.ZodString>>;
|
|
1422
1398
|
comparator: z.ZodEnum<{
|
|
1423
1399
|
gte: "gte";
|
|
1424
1400
|
eq: "eq";
|
|
1425
1401
|
lte: "lte";
|
|
1426
1402
|
}>;
|
|
1427
|
-
|
|
1428
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1429
|
-
kind: z.ZodLiteral<"erc20BalanceDeltaGte">;
|
|
1430
|
-
chainId: z.ZodNumber;
|
|
1431
|
-
token: z.ZodString;
|
|
1432
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1433
|
-
escrow: "escrow";
|
|
1434
|
-
delivery: "delivery";
|
|
1435
|
-
}>]>;
|
|
1436
|
-
minDelta: z.ZodString;
|
|
1437
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1438
|
-
kind: z.ZodLiteral<"nativeBalanceDeltaGte">;
|
|
1439
|
-
chainId: z.ZodNumber;
|
|
1440
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1441
|
-
escrow: "escrow";
|
|
1442
|
-
delivery: "delivery";
|
|
1443
|
-
}>]>;
|
|
1444
|
-
minDelta: z.ZodString;
|
|
1403
|
+
threshold: z.ZodString;
|
|
1445
1404
|
}, z.core.$strip>], "kind">;
|
|
1405
|
+
type AssertionSpecWire = z.infer<typeof AssertionSpecZod>;
|
|
1446
1406
|
export declare const VerificationDescriptorZod: z.ZodObject<{
|
|
1447
1407
|
validationProgramHash: z.ZodString;
|
|
1448
1408
|
paramsHash: z.ZodString;
|
|
1449
|
-
assertedPredicate: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1409
|
+
assertedPredicate: z.ZodReadonly<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1450
1410
|
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1451
1411
|
chainId: z.ZodNumber;
|
|
1452
1412
|
token: z.ZodString;
|
|
@@ -1464,125 +1424,19 @@ export declare const VerificationDescriptorZod: z.ZodObject<{
|
|
|
1464
1424
|
}>]>;
|
|
1465
1425
|
minAmount: z.ZodString;
|
|
1466
1426
|
}, z.core.$strip>, z.ZodObject<{
|
|
1467
|
-
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1468
|
-
chainId: z.ZodNumber;
|
|
1469
|
-
token: z.ZodString;
|
|
1470
|
-
owner: z.ZodString;
|
|
1471
|
-
minAmount: z.ZodString;
|
|
1472
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1473
|
-
kind: z.ZodLiteral<"nativeBalanceGte">;
|
|
1474
|
-
chainId: z.ZodNumber;
|
|
1475
|
-
owner: z.ZodString;
|
|
1476
|
-
minAmount: z.ZodString;
|
|
1477
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1478
|
-
kind: z.ZodLiteral<"call">;
|
|
1479
|
-
chainId: z.ZodNumber;
|
|
1480
|
-
to: z.ZodString;
|
|
1481
|
-
calldata: z.ZodString;
|
|
1482
|
-
comparator: z.ZodEnum<{
|
|
1483
|
-
gte: "gte";
|
|
1484
|
-
eq: "eq";
|
|
1485
|
-
lte: "lte";
|
|
1486
|
-
}>;
|
|
1487
|
-
value: z.ZodString;
|
|
1488
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1489
|
-
kind: z.ZodLiteral<"erc20BalanceDeltaGte">;
|
|
1490
|
-
chainId: z.ZodNumber;
|
|
1491
|
-
token: z.ZodString;
|
|
1492
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1493
|
-
escrow: "escrow";
|
|
1494
|
-
delivery: "delivery";
|
|
1495
|
-
}>]>;
|
|
1496
|
-
minDelta: z.ZodString;
|
|
1497
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1498
|
-
kind: z.ZodLiteral<"nativeBalanceDeltaGte">;
|
|
1499
|
-
chainId: z.ZodNumber;
|
|
1500
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1501
|
-
escrow: "escrow";
|
|
1502
|
-
delivery: "delivery";
|
|
1503
|
-
}>]>;
|
|
1504
|
-
minDelta: z.ZodString;
|
|
1505
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1506
|
-
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1507
|
-
chainId: z.ZodNumber;
|
|
1508
|
-
token: z.ZodString;
|
|
1509
|
-
owner: z.ZodString;
|
|
1510
|
-
minAmount: z.ZodString;
|
|
1511
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1512
|
-
kind: z.ZodLiteral<"nativeBalanceGte">;
|
|
1513
|
-
chainId: z.ZodNumber;
|
|
1514
|
-
owner: z.ZodString;
|
|
1515
|
-
minAmount: z.ZodString;
|
|
1516
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1517
|
-
kind: z.ZodLiteral<"call">;
|
|
1518
|
-
chainId: z.ZodNumber;
|
|
1519
|
-
to: z.ZodString;
|
|
1520
|
-
calldata: z.ZodString;
|
|
1521
|
-
comparator: z.ZodEnum<{
|
|
1522
|
-
gte: "gte";
|
|
1523
|
-
eq: "eq";
|
|
1524
|
-
lte: "lte";
|
|
1525
|
-
}>;
|
|
1526
|
-
value: z.ZodString;
|
|
1527
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1528
|
-
kind: z.ZodLiteral<"erc20BalanceDeltaGte">;
|
|
1529
|
-
chainId: z.ZodNumber;
|
|
1530
|
-
token: z.ZodString;
|
|
1531
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1532
|
-
escrow: "escrow";
|
|
1533
|
-
delivery: "delivery";
|
|
1534
|
-
}>]>;
|
|
1535
|
-
minDelta: z.ZodString;
|
|
1536
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1537
|
-
kind: z.ZodLiteral<"nativeBalanceDeltaGte">;
|
|
1538
|
-
chainId: z.ZodNumber;
|
|
1539
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1540
|
-
escrow: "escrow";
|
|
1541
|
-
delivery: "delivery";
|
|
1542
|
-
}>]>;
|
|
1543
|
-
minDelta: z.ZodString;
|
|
1544
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1545
|
-
kind: z.ZodLiteral<"erc20BalanceGte">;
|
|
1546
|
-
chainId: z.ZodNumber;
|
|
1547
|
-
token: z.ZodString;
|
|
1548
|
-
owner: z.ZodString;
|
|
1549
|
-
minAmount: z.ZodString;
|
|
1550
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1551
|
-
kind: z.ZodLiteral<"nativeBalanceGte">;
|
|
1552
|
-
chainId: z.ZodNumber;
|
|
1553
|
-
owner: z.ZodString;
|
|
1554
|
-
minAmount: z.ZodString;
|
|
1555
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1556
1427
|
kind: z.ZodLiteral<"call">;
|
|
1557
1428
|
chainId: z.ZodNumber;
|
|
1558
1429
|
to: z.ZodString;
|
|
1559
|
-
|
|
1430
|
+
signature: z.ZodString;
|
|
1431
|
+
args: z.ZodReadonly<z.ZodArray<z.ZodString>>;
|
|
1560
1432
|
comparator: z.ZodEnum<{
|
|
1561
1433
|
gte: "gte";
|
|
1562
1434
|
eq: "eq";
|
|
1563
1435
|
lte: "lte";
|
|
1564
1436
|
}>;
|
|
1565
|
-
|
|
1566
|
-
}, z.core.$strip>
|
|
1567
|
-
kind: z.ZodLiteral<"erc20BalanceDeltaGte">;
|
|
1568
|
-
chainId: z.ZodNumber;
|
|
1569
|
-
token: z.ZodString;
|
|
1570
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1571
|
-
escrow: "escrow";
|
|
1572
|
-
delivery: "delivery";
|
|
1573
|
-
}>]>;
|
|
1574
|
-
minDelta: z.ZodString;
|
|
1575
|
-
}, z.core.$strip> | z.ZodObject<{
|
|
1576
|
-
kind: z.ZodLiteral<"nativeBalanceDeltaGte">;
|
|
1577
|
-
chainId: z.ZodNumber;
|
|
1578
|
-
owner: z.ZodUnion<readonly [z.ZodString, z.ZodEnum<{
|
|
1579
|
-
escrow: "escrow";
|
|
1580
|
-
delivery: "delivery";
|
|
1581
|
-
}>]>;
|
|
1582
|
-
minDelta: z.ZodString;
|
|
1583
|
-
}, z.core.$strip>], "kind">>;
|
|
1437
|
+
threshold: z.ZodString;
|
|
1438
|
+
}, z.core.$strip>], "kind">>>;
|
|
1584
1439
|
}, z.core.$strip>;
|
|
1585
|
-
type AssertedPredicateWire = z.infer<typeof AssertedPredicateZod>;
|
|
1586
1440
|
type VerificationDescriptorWire = z.infer<typeof VerificationDescriptorZod>;
|
|
1587
1441
|
export declare const SettlementZod: z.ZodObject<{
|
|
1588
1442
|
escrow: z.ZodOptional<z.ZodObject<{
|
|
@@ -1591,10 +1445,21 @@ export declare const SettlementZod: z.ZodObject<{
|
|
|
1591
1445
|
token: z.ZodString;
|
|
1592
1446
|
amount: z.ZodString;
|
|
1593
1447
|
cap: z.ZodString;
|
|
1448
|
+
floor: z.ZodString;
|
|
1594
1449
|
owner: z.ZodString;
|
|
1595
1450
|
refund: z.ZodString;
|
|
1596
1451
|
expiresAtMs: z.ZodNumber;
|
|
1597
1452
|
}, z.core.$strip>>;
|
|
1453
|
+
binding: z.ZodOptional<z.ZodObject<{
|
|
1454
|
+
executionTarget: z.ZodString;
|
|
1455
|
+
payload: z.ZodString;
|
|
1456
|
+
payloadHash: z.ZodString;
|
|
1457
|
+
calldata: z.ZodString;
|
|
1458
|
+
approvals: z.ZodReadonly<z.ZodArray<z.ZodObject<{
|
|
1459
|
+
token: z.ZodString;
|
|
1460
|
+
spender: z.ZodString;
|
|
1461
|
+
}, z.core.$strip>>>;
|
|
1462
|
+
}, z.core.$strip>>;
|
|
1598
1463
|
}, z.core.$strip>;
|
|
1599
1464
|
type ResourcePort = z.infer<typeof ResourcePortZod>;
|
|
1600
1465
|
type HandlePort = z.infer<typeof HandlePortZod>;
|
|
@@ -1609,29 +1474,22 @@ type GuardCompatibility = z.infer<typeof GuardCompatibilityZod>;
|
|
|
1609
1474
|
type ManifestGuard = z.infer<typeof ManifestGuardZod>;
|
|
1610
1475
|
type ManifestMaterialiser = z.infer<typeof ManifestMaterialiserZod>;
|
|
1611
1476
|
type ManifestPrecondition = z.infer<typeof ManifestPreconditionZod>;
|
|
1477
|
+
type ManifestRouting = z.infer<typeof ManifestRoutingZod>;
|
|
1612
1478
|
type ComposeManifest = z.infer<typeof ComposeManifestZod>;
|
|
1613
1479
|
type SettlementEscrowWire = z.infer<typeof SettlementEscrowZod>;
|
|
1480
|
+
type SettlementBindingWire = z.infer<typeof SettlementBindingZod>;
|
|
1614
1481
|
type SettlementWire = z.infer<typeof SettlementZod>;
|
|
1615
1482
|
//#endregion
|
|
1616
1483
|
//#region src/compile.d.ts
|
|
1617
1484
|
type SimulationPolicy = 'strict' | 'allow-revert';
|
|
1618
|
-
/**
|
|
1619
|
-
* Destination for sweeping proxy-held terminal resources after execution.
|
|
1620
|
-
* Either a literal EVM address or a `{ $ref }` context reference
|
|
1621
|
-
* (e.g. `{ $ref: "context.sender" }`).
|
|
1622
|
-
*/
|
|
1623
|
-
type SweepTo = string | {
|
|
1624
|
-
readonly $ref: string;
|
|
1625
|
-
};
|
|
1626
1485
|
interface ComposeRun {
|
|
1627
1486
|
readonly inputs: Record<string, InputSpec>;
|
|
1628
1487
|
readonly preconditions?: readonly Precondition[];
|
|
1629
1488
|
readonly signer: string;
|
|
1630
1489
|
readonly assumptions?: Record<string, bigint>;
|
|
1631
1490
|
readonly referrer?: string;
|
|
1632
|
-
readonly integratorFeeBps?: number;
|
|
1633
1491
|
readonly maxPriceImpactBps?: number;
|
|
1634
|
-
readonly sweepTo?:
|
|
1492
|
+
readonly sweepTo?: ForwardTo;
|
|
1635
1493
|
readonly simulationPolicy?: SimulationPolicy;
|
|
1636
1494
|
/**
|
|
1637
1495
|
* Also simulate the final user-facing transaction. Defaults to `false`;
|
|
@@ -1708,33 +1566,42 @@ interface SpendEntry {
|
|
|
1708
1566
|
readonly amount: string;
|
|
1709
1567
|
readonly nodeId?: string;
|
|
1710
1568
|
}
|
|
1711
|
-
interface ComposeFee {
|
|
1712
|
-
readonly input: string;
|
|
1713
|
-
readonly token: string;
|
|
1714
|
-
readonly recipient: 'lifi' | 'integrator';
|
|
1715
|
-
readonly recipientAddress: string;
|
|
1716
|
-
readonly bps: number;
|
|
1717
|
-
readonly amount?: string;
|
|
1718
|
-
}
|
|
1719
1569
|
interface ComposeUserProgramSimulation {
|
|
1720
1570
|
readonly status: 'ok';
|
|
1721
1571
|
readonly returnData: string;
|
|
1722
1572
|
}
|
|
1573
|
+
interface ComposeWarning {
|
|
1574
|
+
readonly kind: string;
|
|
1575
|
+
readonly message: string;
|
|
1576
|
+
readonly path?: string;
|
|
1577
|
+
readonly port?: string;
|
|
1578
|
+
readonly fix?: string;
|
|
1579
|
+
}
|
|
1723
1580
|
interface ComposeFill {
|
|
1724
1581
|
readonly spends: readonly SpendEntry[];
|
|
1725
1582
|
readonly validUntilMs?: number;
|
|
1726
1583
|
}
|
|
1584
|
+
interface ExecutedForward {
|
|
1585
|
+
readonly resource: Resource;
|
|
1586
|
+
readonly to: string;
|
|
1587
|
+
readonly amount: bigint;
|
|
1588
|
+
}
|
|
1589
|
+
interface ExecutedEpilogue {
|
|
1590
|
+
readonly forwards: readonly ExecutedForward[];
|
|
1591
|
+
readonly remainder?: string;
|
|
1592
|
+
}
|
|
1727
1593
|
interface ComposeCompileSuccessData extends ComposeContinuationData {
|
|
1728
1594
|
readonly outputs: Outputs;
|
|
1595
|
+
readonly epilogue?: ExecutedEpilogue;
|
|
1729
1596
|
readonly transactionRequest?: ComposeTransactionRequest;
|
|
1730
1597
|
readonly actions?: readonly ComposeAction[];
|
|
1731
1598
|
readonly userProxy: string;
|
|
1732
1599
|
readonly priceImpact?: PriceImpact;
|
|
1733
1600
|
readonly approvals?: readonly ApprovalEntry[];
|
|
1734
|
-
readonly fees?: readonly ComposeFee[];
|
|
1735
1601
|
readonly userProgramSimulation?: ComposeUserProgramSimulation;
|
|
1736
1602
|
readonly fill?: ComposeFill;
|
|
1737
1603
|
readonly verificationByNode?: Record<string, VerificationDescriptor>;
|
|
1604
|
+
readonly warnings?: readonly ComposeWarning[];
|
|
1738
1605
|
}
|
|
1739
1606
|
interface ComposeCompilePartialData extends ComposeContinuationData {
|
|
1740
1607
|
readonly outputs: Outputs;
|
|
@@ -1743,8 +1610,8 @@ interface ComposeCompilePartialData extends ComposeContinuationData {
|
|
|
1743
1610
|
readonly simulationRevert: SimulationRevert;
|
|
1744
1611
|
readonly approvals?: readonly ApprovalEntry[];
|
|
1745
1612
|
readonly actions?: readonly ComposeAction[];
|
|
1746
|
-
readonly fees?: readonly ComposeFee[];
|
|
1747
1613
|
readonly userProgramSimulation?: ComposeUserProgramSimulation;
|
|
1614
|
+
readonly warnings?: readonly ComposeWarning[];
|
|
1748
1615
|
}
|
|
1749
1616
|
type ComposeCompileResult = (ComposeCompileSuccessData & {
|
|
1750
1617
|
readonly status: 'success';
|
|
@@ -1772,12 +1639,12 @@ export declare const isResourcePort: (port: OpInputPort) => port is ResourcePort
|
|
|
1772
1639
|
export declare const isHandlePort: (port: OpInputPort | OpOutputPort) => port is HandlePort;
|
|
1773
1640
|
export declare const isResourceOutputPort: (port: OpInputPort | OpOutputPort) => port is ResourceOutputPort;
|
|
1774
1641
|
export declare const isFutureResourceOutput: (port: OpInputPort | OpOutputPort) => boolean;
|
|
1775
|
-
type ComposeErrorKind = 'decode_error' | 'validation_error' | 'linearity_error' | 'resolve_error' | 'preparation_error' | 'provider_error' | 'no_route_error' | 'resolution_error' | 'resolution_rejected' | 'lowering_error' | 'empty_program' | 'simulation_error' | 'simulation_setup_error' | 'simulation_insufficient_funds' | 'simulation_gas_limit' | 'simulation_rpc_error' | 'simulation_revert' | 'subgraph_simulation_revert' | 'guard_error' | 'continuation_error' | 'compilation_error' | 'verification_error' | 'price_impact_exceeded' | '
|
|
1642
|
+
type ComposeErrorKind = 'decode_error' | 'validation_error' | 'linearity_error' | 'resolve_error' | 'preparation_error' | 'provider_error' | 'no_route_error' | 'resolution_error' | 'resolution_rejected' | 'lowering_error' | 'empty_program' | 'simulation_error' | 'simulation_setup_error' | 'simulation_insufficient_funds' | 'simulation_gas_limit' | 'simulation_rpc_error' | 'simulation_revert' | 'subgraph_simulation_revert' | 'guard_error' | 'continuation_error' | 'compilation_error' | 'verification_error' | 'price_impact_exceeded' | 'flashloan_unauthorized' | 'delivery_error' | 'deadline_exceeded';
|
|
1776
1643
|
/**
|
|
1777
1644
|
* Errors raised by compose routes outside the compile pipeline.
|
|
1778
1645
|
*/
|
|
1779
1646
|
type ComposeRouteErrorKind = 'chain_validation_error' | 'unsupported_token' | 'zero_output' | 'service_unavailable' | 'verification_unavailable' | 'deployment_check_unavailable' | 'manifest_error' | 'sdk_outdated' | 'server_outdated';
|
|
1780
|
-
type GenericComposeErrorKind = Exclude<ComposeErrorKind, 'preparation_error' | 'simulation_revert'>;
|
|
1647
|
+
type GenericComposeErrorKind = Exclude<ComposeErrorKind, 'preparation_error' | 'simulation_revert' | 'delivery_error'>;
|
|
1781
1648
|
interface FailedPreparedOp {
|
|
1782
1649
|
readonly callId: string;
|
|
1783
1650
|
readonly op: string;
|
|
@@ -1802,11 +1669,31 @@ interface SimulationRevertComposeError extends ComposeErrorBase {
|
|
|
1802
1669
|
readonly kind: 'simulation_revert';
|
|
1803
1670
|
readonly details?: SimulationRevert;
|
|
1804
1671
|
}
|
|
1672
|
+
type DeliveryErrorReason = 'floor_drift' | 'eta_exceeds_expiry' | 'quote_failed';
|
|
1673
|
+
interface DeliveryErrorDetails {
|
|
1674
|
+
readonly reason: DeliveryErrorReason;
|
|
1675
|
+
readonly cause?: ComposeErrorKind;
|
|
1676
|
+
readonly quoted: {
|
|
1677
|
+
readonly min: string;
|
|
1678
|
+
readonly expected: string;
|
|
1679
|
+
readonly etaSeconds?: number;
|
|
1680
|
+
};
|
|
1681
|
+
readonly escrow?: {
|
|
1682
|
+
readonly chainId: number;
|
|
1683
|
+
readonly address: string;
|
|
1684
|
+
readonly floor: string;
|
|
1685
|
+
readonly expiresAtMs: number;
|
|
1686
|
+
};
|
|
1687
|
+
}
|
|
1688
|
+
interface DeliveryComposeError extends ComposeErrorBase {
|
|
1689
|
+
readonly kind: 'delivery_error';
|
|
1690
|
+
readonly details: DeliveryErrorDetails;
|
|
1691
|
+
}
|
|
1805
1692
|
interface GenericComposeError extends ComposeErrorBase {
|
|
1806
1693
|
readonly kind: GenericComposeErrorKind;
|
|
1807
1694
|
readonly [key: string]: unknown;
|
|
1808
1695
|
}
|
|
1809
|
-
type ComposeError = PreparationComposeError | SimulationRevertComposeError | GenericComposeError;
|
|
1696
|
+
type ComposeError = PreparationComposeError | SimulationRevertComposeError | DeliveryComposeError | GenericComposeError;
|
|
1810
1697
|
interface MaterialiserInputBase {
|
|
1811
1698
|
readonly kind: string;
|
|
1812
1699
|
}
|
|
@@ -2177,13 +2064,13 @@ interface RouteAmountExact {
|
|
|
2177
2064
|
* {@link RouteAmountExact} for native inputs.
|
|
2178
2065
|
*
|
|
2179
2066
|
* On a route that begins with an aggregator swap the swap's input amount is
|
|
2180
|
-
* pinned to the quoted amount derived from `simAmount
|
|
2181
|
-
*
|
|
2182
|
-
*
|
|
2183
|
-
*
|
|
2184
|
-
*
|
|
2185
|
-
*
|
|
2186
|
-
*
|
|
2067
|
+
* pinned to the quoted amount derived from `simAmount`: a runtime balance below
|
|
2068
|
+
* that pinned amount reverts, and a balance above it leaves the remainder as
|
|
2069
|
+
* `unspentIn`, which may be most of the input and which `sweepTo` receives.
|
|
2070
|
+
* Under `EXACT` the deposit and the pinned quote are the same number, so the
|
|
2071
|
+
* `unspentIn` output is zero and omitted; any pre-existing dust of the sold
|
|
2072
|
+
* token in the proxy is moved to `sweepTo` by the whole-balance sweep
|
|
2073
|
+
* independently of that output.
|
|
2187
2074
|
*/
|
|
2188
2075
|
interface RouteAmountAll {
|
|
2189
2076
|
readonly type: 'ALL';
|
|
@@ -2224,12 +2111,6 @@ interface ComposeRouteRequest {
|
|
|
2224
2111
|
* `0` disables the check.
|
|
2225
2112
|
*/
|
|
2226
2113
|
readonly maxPriceImpactBps?: number;
|
|
2227
|
-
/**
|
|
2228
|
-
* Integrator fee in basis points, taken from the input amount. Range 0–9000.
|
|
2229
|
-
* Defaults to `0` server-side when omitted. A non-zero value requires an
|
|
2230
|
-
* integration-scoped API key; the server rejects it otherwise.
|
|
2231
|
-
*/
|
|
2232
|
-
readonly integratorFeeBps?: number;
|
|
2233
2114
|
/** Opaque referrer tag forwarded to the underlying quote provider. */
|
|
2234
2115
|
readonly referrer?: string;
|
|
2235
2116
|
/**
|
|
@@ -2248,7 +2129,7 @@ interface ComposeRouteRequest {
|
|
|
2248
2129
|
* Accepts an address or `{ $ref: 'context.sender' }` (which counts as
|
|
2249
2130
|
* explicit); `{ $ref: 'context.executionAddress' }` is rejected.
|
|
2250
2131
|
*/
|
|
2251
|
-
readonly sweepTo?:
|
|
2132
|
+
readonly sweepTo?: ForwardTo;
|
|
2252
2133
|
/**
|
|
2253
2134
|
* `'strict'` (the default) fails the request when simulation detects a
|
|
2254
2135
|
* revert; `'allow-revert'` returns a partial result with revert diagnostics
|
|
@@ -2521,6 +2402,7 @@ type MaterialiserMetadata = {
|
|
|
2521
2402
|
readonly min?: bigint;
|
|
2522
2403
|
} | {
|
|
2523
2404
|
readonly kind: 'runtime';
|
|
2405
|
+
readonly min?: bigint;
|
|
2524
2406
|
};
|
|
2525
2407
|
interface MaterialiserResolution {
|
|
2526
2408
|
readonly meta: MaterialiserMetadata;
|
|
@@ -2530,7 +2412,7 @@ export declare const foldMaterialiserMetadata: <R>(meta: MaterialiserMetadata, c
|
|
|
2530
2412
|
readonly exact: (amount: bigint) => R;
|
|
2531
2413
|
readonly exactNative: (amount: bigint) => R;
|
|
2532
2414
|
readonly capped: (amount: bigint, min: bigint | undefined) => R;
|
|
2533
|
-
readonly runtime: () => R;
|
|
2415
|
+
readonly runtime: (min: bigint | undefined) => R;
|
|
2534
2416
|
}) => R;
|
|
2535
2417
|
//#endregion
|
|
2536
|
-
export type { Amount, AppliedGuard, ApprovalEntry, AssertedPredicate,
|
|
2418
|
+
export type { Amount, AppliedGuard, ApprovalEntry, AssertedPredicate, AssertionOwner, AssertionSpec, AssertionSpecWire, Availability, BindValue, Call, CallCheckSpec, ChainCapabilities, CommittedOutcome, ComposeAction, ComposeCompilePartialData, ComposeCompileRequest, ComposeCompileResult, ComposeCompileSuccessData, ComposeError, ComposeErrorKind, ComposeFill, ComposeManifest, ComposeRouteErrorKind, ComposeRouteRequest, ComposeRun, ComposeTransactionRequest, ComposeUserProgramSimulation, ComposeVersion, ComposeWarning, ConsumedOutput, ContextKey, ContinuationIntent, ContinuationOutcome, Delivery, DeliveryComposeError, DeliveryErrorDetails, DeliveryErrorReason, ERC20Resource, Epilogue, EpilogueForward, Erc20AllowancePrecondition, Erc20AllowanceRequirement, Erc20BalancePrecondition, Erc20BalanceRequirement, Estimate, EstimateBasis, ExecutedEpilogue, ExecutedForward, FailedPreparedOp, FlashloanMaterialiserInput, Flow, FlowInput, ForwardTo, GenericComposeError, GenericComposeErrorKind, GuardCompatibility, GuardSelector, HandleInput, HandlePort, HandleUnits, InputSpec, Lineage, LiteralBinding, ManifestGuard, ManifestMaterialiser, ManifestOperation, ManifestPrecondition, ManifestRouting, MaterialiserConfigOf, MaterialiserInput, MaterialiserInputBase, MaterialiserInputOf, MaterialiserMetadata, MaterialiserResolution, Minimum, MinimumBasis, NativeBalancePrecondition, NativeBalanceRequirement, NativeCheckPolicy, NativeErc20, NativeResource, OpInputPort, OpOutputPort, Output, OutputAmount, OutputFamilyPort, Outputs, ParsedRef, Phase1Artifact, Port, Precondition, PreconditionBase, PreconditionConfigOf, PreconditionOf, PreparationComposeError, PriceImpact, ProviderKindName, Ref, RefBuilder, RefPath, RefScope, Resource, ResourceInput, ResourceOutputPort, ResourcePort, RouteAmount, RouteAmountAll, RouteAmountExact, SettlementBindingWire, SettlementEscrowWire, SettlementWire, SimulateBalanceEntry, SimulateOkResult, SimulateRequest, SimulateResult, SimulateRevertDecodeResult, SimulateRevertResult, SimulateSetupErrorResult, SimulationPolicy, SimulationRevert, SimulationRevertComposeError, SlotFinderRequirement, SolType, SpendEntry, StaticSolType, TerminalOutput, TrackedBalance, VerificationDescriptor, VerificationDescriptorWire, VersionCompatibility };
|