@emberai/onchain-actions-registry 1.0.0-alpha.3

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.
Files changed (129) hide show
  1. package/dist/aave-lending-plugin/adapter.d.ts +56 -0
  2. package/dist/aave-lending-plugin/adapter.d.ts.map +1 -0
  3. package/dist/aave-lending-plugin/adapter.js +326 -0
  4. package/dist/aave-lending-plugin/adapter.js.map +1 -0
  5. package/dist/aave-lending-plugin/chain.d.ts +30 -0
  6. package/dist/aave-lending-plugin/chain.d.ts.map +1 -0
  7. package/dist/aave-lending-plugin/chain.js +36 -0
  8. package/dist/aave-lending-plugin/chain.js.map +1 -0
  9. package/dist/aave-lending-plugin/dataProvider.d.ts +19 -0
  10. package/dist/aave-lending-plugin/dataProvider.d.ts.map +1 -0
  11. package/dist/aave-lending-plugin/dataProvider.js +18 -0
  12. package/dist/aave-lending-plugin/dataProvider.js.map +1 -0
  13. package/dist/aave-lending-plugin/errors.d.ts +13 -0
  14. package/dist/aave-lending-plugin/errors.d.ts.map +1 -0
  15. package/dist/aave-lending-plugin/errors.js +366 -0
  16. package/dist/aave-lending-plugin/errors.js.map +1 -0
  17. package/dist/aave-lending-plugin/index.d.ts +24 -0
  18. package/dist/aave-lending-plugin/index.d.ts.map +1 -0
  19. package/dist/aave-lending-plugin/index.js +136 -0
  20. package/dist/aave-lending-plugin/index.js.map +1 -0
  21. package/dist/aave-lending-plugin/market.d.ts +11 -0
  22. package/dist/aave-lending-plugin/market.d.ts.map +1 -0
  23. package/dist/aave-lending-plugin/market.js +22 -0
  24. package/dist/aave-lending-plugin/market.js.map +1 -0
  25. package/dist/aave-lending-plugin/populateTransaction.d.ts +4 -0
  26. package/dist/aave-lending-plugin/populateTransaction.d.ts.map +1 -0
  27. package/dist/aave-lending-plugin/populateTransaction.js +31 -0
  28. package/dist/aave-lending-plugin/populateTransaction.js.map +1 -0
  29. package/dist/aave-lending-plugin/userSummary.d.ts +15 -0
  30. package/dist/aave-lending-plugin/userSummary.d.ts.map +1 -0
  31. package/dist/aave-lending-plugin/userSummary.js +62 -0
  32. package/dist/aave-lending-plugin/userSummary.js.map +1 -0
  33. package/dist/chainConfig.d.ts +10 -0
  34. package/dist/chainConfig.d.ts.map +1 -0
  35. package/dist/chainConfig.js +2 -0
  36. package/dist/chainConfig.js.map +1 -0
  37. package/dist/core/actions/index.d.ts +6 -0
  38. package/dist/core/actions/index.d.ts.map +1 -0
  39. package/dist/core/actions/index.js +2 -0
  40. package/dist/core/actions/index.js.map +1 -0
  41. package/dist/core/actions/lending.d.ts +22 -0
  42. package/dist/core/actions/lending.d.ts.map +1 -0
  43. package/dist/core/actions/lending.js +2 -0
  44. package/dist/core/actions/lending.js.map +1 -0
  45. package/dist/core/actions/liquidity.d.ts +14 -0
  46. package/dist/core/actions/liquidity.d.ts.map +1 -0
  47. package/dist/core/actions/liquidity.js +2 -0
  48. package/dist/core/actions/liquidity.js.map +1 -0
  49. package/dist/core/actions/perpetuals.d.ts +6 -0
  50. package/dist/core/actions/perpetuals.d.ts.map +1 -0
  51. package/dist/core/actions/perpetuals.js +2 -0
  52. package/dist/core/actions/perpetuals.js.map +1 -0
  53. package/dist/core/actions/swap.d.ts +10 -0
  54. package/dist/core/actions/swap.d.ts.map +1 -0
  55. package/dist/core/actions/swap.js +2 -0
  56. package/dist/core/actions/swap.js.map +1 -0
  57. package/dist/core/actions/types.d.ts +70 -0
  58. package/dist/core/actions/types.d.ts.map +1 -0
  59. package/dist/core/actions/types.js +2 -0
  60. package/dist/core/actions/types.js.map +1 -0
  61. package/dist/core/index.d.ts +41 -0
  62. package/dist/core/index.d.ts.map +1 -0
  63. package/dist/core/index.js +5 -0
  64. package/dist/core/index.js.map +1 -0
  65. package/dist/core/pluginType.d.ts +25 -0
  66. package/dist/core/pluginType.d.ts.map +1 -0
  67. package/dist/core/pluginType.js +2 -0
  68. package/dist/core/pluginType.js.map +1 -0
  69. package/dist/core/queries/index.d.ts +4 -0
  70. package/dist/core/queries/index.d.ts.map +1 -0
  71. package/dist/core/queries/index.js +4 -0
  72. package/dist/core/queries/index.js.map +1 -0
  73. package/dist/core/queries/lending.d.ts +12 -0
  74. package/dist/core/queries/lending.d.ts.map +1 -0
  75. package/dist/core/queries/lending.js +2 -0
  76. package/dist/core/queries/lending.js.map +1 -0
  77. package/dist/core/queries/liquidity.d.ts +17 -0
  78. package/dist/core/queries/liquidity.d.ts.map +1 -0
  79. package/dist/core/queries/liquidity.js +2 -0
  80. package/dist/core/queries/liquidity.js.map +1 -0
  81. package/dist/core/queries/perpetuals.d.ts +10 -0
  82. package/dist/core/queries/perpetuals.d.ts.map +1 -0
  83. package/dist/core/queries/perpetuals.js +2 -0
  84. package/dist/core/queries/perpetuals.js.map +1 -0
  85. package/dist/core/schemas/core.d.ts +315 -0
  86. package/dist/core/schemas/core.d.ts.map +1 -0
  87. package/dist/core/schemas/core.js +76 -0
  88. package/dist/core/schemas/core.js.map +1 -0
  89. package/dist/core/schemas/enums.d.ts +37 -0
  90. package/dist/core/schemas/enums.d.ts.map +1 -0
  91. package/dist/core/schemas/enums.js +36 -0
  92. package/dist/core/schemas/enums.js.map +1 -0
  93. package/dist/core/schemas/index.d.ts +9 -0
  94. package/dist/core/schemas/index.d.ts.map +1 -0
  95. package/dist/core/schemas/index.js +9 -0
  96. package/dist/core/schemas/index.js.map +1 -0
  97. package/dist/core/schemas/lending.d.ts +903 -0
  98. package/dist/core/schemas/lending.d.ts.map +1 -0
  99. package/dist/core/schemas/lending.js +71 -0
  100. package/dist/core/schemas/lending.js.map +1 -0
  101. package/dist/core/schemas/liquidity.d.ts +604 -0
  102. package/dist/core/schemas/liquidity.d.ts.map +1 -0
  103. package/dist/core/schemas/liquidity.js +74 -0
  104. package/dist/core/schemas/liquidity.js.map +1 -0
  105. package/dist/core/schemas/perpetuals.d.ts +974 -0
  106. package/dist/core/schemas/perpetuals.d.ts.map +1 -0
  107. package/dist/core/schemas/perpetuals.js +116 -0
  108. package/dist/core/schemas/perpetuals.js.map +1 -0
  109. package/dist/core/schemas/requests.d.ts +218 -0
  110. package/dist/core/schemas/requests.d.ts.map +1 -0
  111. package/dist/core/schemas/requests.js +15 -0
  112. package/dist/core/schemas/requests.js.map +1 -0
  113. package/dist/core/schemas/swap.d.ts +451 -0
  114. package/dist/core/schemas/swap.d.ts.map +1 -0
  115. package/dist/core/schemas/swap.js +37 -0
  116. package/dist/core/schemas/swap.js.map +1 -0
  117. package/dist/core/schemas/wallet.d.ts +69 -0
  118. package/dist/core/schemas/wallet.d.ts.map +1 -0
  119. package/dist/core/schemas/wallet.js +9 -0
  120. package/dist/core/schemas/wallet.js.map +1 -0
  121. package/dist/index.d.ts +8 -0
  122. package/dist/index.d.ts.map +1 -0
  123. package/dist/index.js +16 -0
  124. package/dist/index.js.map +1 -0
  125. package/dist/registry.d.ts +24 -0
  126. package/dist/registry.d.ts.map +1 -0
  127. package/dist/registry.js +38 -0
  128. package/dist/registry.js.map +1 -0
  129. package/package.json +78 -0
@@ -0,0 +1,451 @@
1
+ import { z } from 'zod';
2
+ export declare const SwapTokensRequestSchema: z.ZodObject<{
3
+ fromToken: z.ZodObject<{
4
+ tokenUid: z.ZodObject<{
5
+ chainId: z.ZodString;
6
+ address: z.ZodString;
7
+ }, "strip", z.ZodTypeAny, {
8
+ chainId: string;
9
+ address: string;
10
+ }, {
11
+ chainId: string;
12
+ address: string;
13
+ }>;
14
+ name: z.ZodString;
15
+ symbol: z.ZodString;
16
+ isNative: z.ZodBoolean;
17
+ decimals: z.ZodNumber;
18
+ iconUri: z.ZodOptional<z.ZodNullable<z.ZodString>>;
19
+ isVetted: z.ZodBoolean;
20
+ }, "strip", z.ZodTypeAny, {
21
+ symbol: string;
22
+ tokenUid: {
23
+ chainId: string;
24
+ address: string;
25
+ };
26
+ name: string;
27
+ isNative: boolean;
28
+ decimals: number;
29
+ isVetted: boolean;
30
+ iconUri?: string | null | undefined;
31
+ }, {
32
+ symbol: string;
33
+ tokenUid: {
34
+ chainId: string;
35
+ address: string;
36
+ };
37
+ name: string;
38
+ isNative: boolean;
39
+ decimals: number;
40
+ isVetted: boolean;
41
+ iconUri?: string | null | undefined;
42
+ }>;
43
+ toToken: z.ZodObject<{
44
+ tokenUid: z.ZodObject<{
45
+ chainId: z.ZodString;
46
+ address: z.ZodString;
47
+ }, "strip", z.ZodTypeAny, {
48
+ chainId: string;
49
+ address: string;
50
+ }, {
51
+ chainId: string;
52
+ address: string;
53
+ }>;
54
+ name: z.ZodString;
55
+ symbol: z.ZodString;
56
+ isNative: z.ZodBoolean;
57
+ decimals: z.ZodNumber;
58
+ iconUri: z.ZodOptional<z.ZodNullable<z.ZodString>>;
59
+ isVetted: z.ZodBoolean;
60
+ }, "strip", z.ZodTypeAny, {
61
+ symbol: string;
62
+ tokenUid: {
63
+ chainId: string;
64
+ address: string;
65
+ };
66
+ name: string;
67
+ isNative: boolean;
68
+ decimals: number;
69
+ isVetted: boolean;
70
+ iconUri?: string | null | undefined;
71
+ }, {
72
+ symbol: string;
73
+ tokenUid: {
74
+ chainId: string;
75
+ address: string;
76
+ };
77
+ name: string;
78
+ isNative: boolean;
79
+ decimals: number;
80
+ isVetted: boolean;
81
+ iconUri?: string | null | undefined;
82
+ }>;
83
+ amount: z.ZodBigInt;
84
+ limitPrice: z.ZodOptional<z.ZodString>;
85
+ slippageTolerance: z.ZodOptional<z.ZodString>;
86
+ expiration: z.ZodOptional<z.ZodString>;
87
+ recipient: z.ZodString;
88
+ }, "strip", z.ZodTypeAny, {
89
+ amount: bigint;
90
+ fromToken: {
91
+ symbol: string;
92
+ tokenUid: {
93
+ chainId: string;
94
+ address: string;
95
+ };
96
+ name: string;
97
+ isNative: boolean;
98
+ decimals: number;
99
+ isVetted: boolean;
100
+ iconUri?: string | null | undefined;
101
+ };
102
+ toToken: {
103
+ symbol: string;
104
+ tokenUid: {
105
+ chainId: string;
106
+ address: string;
107
+ };
108
+ name: string;
109
+ isNative: boolean;
110
+ decimals: number;
111
+ isVetted: boolean;
112
+ iconUri?: string | null | undefined;
113
+ };
114
+ recipient: string;
115
+ expiration?: string | undefined;
116
+ limitPrice?: string | undefined;
117
+ slippageTolerance?: string | undefined;
118
+ }, {
119
+ amount: bigint;
120
+ fromToken: {
121
+ symbol: string;
122
+ tokenUid: {
123
+ chainId: string;
124
+ address: string;
125
+ };
126
+ name: string;
127
+ isNative: boolean;
128
+ decimals: number;
129
+ isVetted: boolean;
130
+ iconUri?: string | null | undefined;
131
+ };
132
+ toToken: {
133
+ symbol: string;
134
+ tokenUid: {
135
+ chainId: string;
136
+ address: string;
137
+ };
138
+ name: string;
139
+ isNative: boolean;
140
+ decimals: number;
141
+ isVetted: boolean;
142
+ iconUri?: string | null | undefined;
143
+ };
144
+ recipient: string;
145
+ expiration?: string | undefined;
146
+ limitPrice?: string | undefined;
147
+ slippageTolerance?: string | undefined;
148
+ }>;
149
+ export type SwapTokensRequest = z.infer<typeof SwapTokensRequestSchema>;
150
+ export declare const SwapTokensResponseSchema: z.ZodObject<{
151
+ fromToken: z.ZodObject<{
152
+ tokenUid: z.ZodObject<{
153
+ chainId: z.ZodString;
154
+ address: z.ZodString;
155
+ }, "strip", z.ZodTypeAny, {
156
+ chainId: string;
157
+ address: string;
158
+ }, {
159
+ chainId: string;
160
+ address: string;
161
+ }>;
162
+ name: z.ZodString;
163
+ symbol: z.ZodString;
164
+ isNative: z.ZodBoolean;
165
+ decimals: z.ZodNumber;
166
+ iconUri: z.ZodOptional<z.ZodNullable<z.ZodString>>;
167
+ isVetted: z.ZodBoolean;
168
+ }, "strip", z.ZodTypeAny, {
169
+ symbol: string;
170
+ tokenUid: {
171
+ chainId: string;
172
+ address: string;
173
+ };
174
+ name: string;
175
+ isNative: boolean;
176
+ decimals: number;
177
+ isVetted: boolean;
178
+ iconUri?: string | null | undefined;
179
+ }, {
180
+ symbol: string;
181
+ tokenUid: {
182
+ chainId: string;
183
+ address: string;
184
+ };
185
+ name: string;
186
+ isNative: boolean;
187
+ decimals: number;
188
+ isVetted: boolean;
189
+ iconUri?: string | null | undefined;
190
+ }>;
191
+ toToken: z.ZodObject<{
192
+ tokenUid: z.ZodObject<{
193
+ chainId: z.ZodString;
194
+ address: z.ZodString;
195
+ }, "strip", z.ZodTypeAny, {
196
+ chainId: string;
197
+ address: string;
198
+ }, {
199
+ chainId: string;
200
+ address: string;
201
+ }>;
202
+ name: z.ZodString;
203
+ symbol: z.ZodString;
204
+ isNative: z.ZodBoolean;
205
+ decimals: z.ZodNumber;
206
+ iconUri: z.ZodOptional<z.ZodNullable<z.ZodString>>;
207
+ isVetted: z.ZodBoolean;
208
+ }, "strip", z.ZodTypeAny, {
209
+ symbol: string;
210
+ tokenUid: {
211
+ chainId: string;
212
+ address: string;
213
+ };
214
+ name: string;
215
+ isNative: boolean;
216
+ decimals: number;
217
+ isVetted: boolean;
218
+ iconUri?: string | null | undefined;
219
+ }, {
220
+ symbol: string;
221
+ tokenUid: {
222
+ chainId: string;
223
+ address: string;
224
+ };
225
+ name: string;
226
+ isNative: boolean;
227
+ decimals: number;
228
+ isVetted: boolean;
229
+ iconUri?: string | null | undefined;
230
+ }>;
231
+ exactFromAmount: z.ZodString;
232
+ displayFromAmount: z.ZodString;
233
+ exactToAmount: z.ZodString;
234
+ displayToAmount: z.ZodString;
235
+ transactions: z.ZodArray<z.ZodObject<{
236
+ type: z.ZodEnum<[string, ...string[]]>;
237
+ to: z.ZodString;
238
+ data: z.ZodString;
239
+ value: z.ZodString;
240
+ chainId: z.ZodString;
241
+ }, "strip", z.ZodTypeAny, {
242
+ value: string;
243
+ type: string;
244
+ chainId: string;
245
+ to: string;
246
+ data: string;
247
+ }, {
248
+ value: string;
249
+ type: string;
250
+ chainId: string;
251
+ to: string;
252
+ data: string;
253
+ }>, "many">;
254
+ feeBreakdown: z.ZodOptional<z.ZodObject<{
255
+ serviceFee: z.ZodString;
256
+ slippageCost: z.ZodString;
257
+ total: z.ZodString;
258
+ feeDenomination: z.ZodString;
259
+ }, "strip", z.ZodTypeAny, {
260
+ serviceFee: string;
261
+ slippageCost: string;
262
+ total: string;
263
+ feeDenomination: string;
264
+ }, {
265
+ serviceFee: string;
266
+ slippageCost: string;
267
+ total: string;
268
+ feeDenomination: string;
269
+ }>>;
270
+ estimation: z.ZodOptional<z.ZodObject<{
271
+ effectivePrice: z.ZodString;
272
+ timeEstimate: z.ZodString;
273
+ expiration: z.ZodString;
274
+ }, "strip", z.ZodTypeAny, {
275
+ effectivePrice: string;
276
+ timeEstimate: string;
277
+ expiration: string;
278
+ }, {
279
+ effectivePrice: string;
280
+ timeEstimate: string;
281
+ expiration: string;
282
+ }>>;
283
+ providerTracking: z.ZodOptional<z.ZodObject<{
284
+ requestId: z.ZodString;
285
+ providerName: z.ZodString;
286
+ explorerUrl: z.ZodString;
287
+ }, "strip", z.ZodTypeAny, {
288
+ requestId: string;
289
+ providerName: string;
290
+ explorerUrl: string;
291
+ }, {
292
+ requestId: string;
293
+ providerName: string;
294
+ explorerUrl: string;
295
+ }>>;
296
+ }, "strip", z.ZodTypeAny, {
297
+ fromToken: {
298
+ symbol: string;
299
+ tokenUid: {
300
+ chainId: string;
301
+ address: string;
302
+ };
303
+ name: string;
304
+ isNative: boolean;
305
+ decimals: number;
306
+ isVetted: boolean;
307
+ iconUri?: string | null | undefined;
308
+ };
309
+ toToken: {
310
+ symbol: string;
311
+ tokenUid: {
312
+ chainId: string;
313
+ address: string;
314
+ };
315
+ name: string;
316
+ isNative: boolean;
317
+ decimals: number;
318
+ isVetted: boolean;
319
+ iconUri?: string | null | undefined;
320
+ };
321
+ exactFromAmount: string;
322
+ displayFromAmount: string;
323
+ exactToAmount: string;
324
+ displayToAmount: string;
325
+ transactions: {
326
+ value: string;
327
+ type: string;
328
+ chainId: string;
329
+ to: string;
330
+ data: string;
331
+ }[];
332
+ feeBreakdown?: {
333
+ serviceFee: string;
334
+ slippageCost: string;
335
+ total: string;
336
+ feeDenomination: string;
337
+ } | undefined;
338
+ estimation?: {
339
+ effectivePrice: string;
340
+ timeEstimate: string;
341
+ expiration: string;
342
+ } | undefined;
343
+ providerTracking?: {
344
+ requestId: string;
345
+ providerName: string;
346
+ explorerUrl: string;
347
+ } | undefined;
348
+ }, {
349
+ fromToken: {
350
+ symbol: string;
351
+ tokenUid: {
352
+ chainId: string;
353
+ address: string;
354
+ };
355
+ name: string;
356
+ isNative: boolean;
357
+ decimals: number;
358
+ isVetted: boolean;
359
+ iconUri?: string | null | undefined;
360
+ };
361
+ toToken: {
362
+ symbol: string;
363
+ tokenUid: {
364
+ chainId: string;
365
+ address: string;
366
+ };
367
+ name: string;
368
+ isNative: boolean;
369
+ decimals: number;
370
+ isVetted: boolean;
371
+ iconUri?: string | null | undefined;
372
+ };
373
+ exactFromAmount: string;
374
+ displayFromAmount: string;
375
+ exactToAmount: string;
376
+ displayToAmount: string;
377
+ transactions: {
378
+ value: string;
379
+ type: string;
380
+ chainId: string;
381
+ to: string;
382
+ data: string;
383
+ }[];
384
+ feeBreakdown?: {
385
+ serviceFee: string;
386
+ slippageCost: string;
387
+ total: string;
388
+ feeDenomination: string;
389
+ } | undefined;
390
+ estimation?: {
391
+ effectivePrice: string;
392
+ timeEstimate: string;
393
+ expiration: string;
394
+ } | undefined;
395
+ providerTracking?: {
396
+ requestId: string;
397
+ providerName: string;
398
+ explorerUrl: string;
399
+ } | undefined;
400
+ }>;
401
+ export type SwapTokensResponse = z.infer<typeof SwapTokensResponseSchema>;
402
+ export declare const GetProviderTrackingStatusRequestSchema: z.ZodObject<{
403
+ requestId: z.ZodString;
404
+ transactionId: z.ZodString;
405
+ }, "strip", z.ZodTypeAny, {
406
+ requestId: string;
407
+ transactionId: string;
408
+ }, {
409
+ requestId: string;
410
+ transactionId: string;
411
+ }>;
412
+ export type GetProviderTrackingStatusRequest = z.infer<typeof GetProviderTrackingStatusRequestSchema>;
413
+ export declare const GetProviderTrackingStatusResponseSchema: z.ZodObject<{
414
+ trackingStatus: z.ZodObject<{
415
+ requestId: z.ZodString;
416
+ transactionId: z.ZodString;
417
+ providerName: z.ZodString;
418
+ explorerUrl: z.ZodString;
419
+ status: z.ZodString;
420
+ }, "strip", z.ZodTypeAny, {
421
+ status: string;
422
+ requestId: string;
423
+ providerName: string;
424
+ explorerUrl: string;
425
+ transactionId: string;
426
+ }, {
427
+ status: string;
428
+ requestId: string;
429
+ providerName: string;
430
+ explorerUrl: string;
431
+ transactionId: string;
432
+ }>;
433
+ }, "strip", z.ZodTypeAny, {
434
+ trackingStatus: {
435
+ status: string;
436
+ requestId: string;
437
+ providerName: string;
438
+ explorerUrl: string;
439
+ transactionId: string;
440
+ };
441
+ }, {
442
+ trackingStatus: {
443
+ status: string;
444
+ requestId: string;
445
+ providerName: string;
446
+ explorerUrl: string;
447
+ transactionId: string;
448
+ };
449
+ }>;
450
+ export type GetProviderTrackingStatusResponse = z.infer<typeof GetProviderTrackingStatusResponseSchema>;
451
+ //# sourceMappingURL=swap.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"swap.d.ts","sourceRoot":"","sources":["../../../src/core/schemas/swap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AASxB,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAQlC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAExE,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAWnC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAE1E,eAAO,MAAM,sCAAsC;;;;;;;;;EAGjD,CAAC;AACH,MAAM,MAAM,gCAAgC,GAAG,CAAC,CAAC,KAAK,CACpD,OAAO,sCAAsC,CAC9C,CAAC;AAEF,eAAO,MAAM,uCAAuC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAQlD,CAAC;AACH,MAAM,MAAM,iCAAiC,GAAG,CAAC,CAAC,KAAK,CACrD,OAAO,uCAAuC,CAC/C,CAAC"}
@@ -0,0 +1,37 @@
1
+ import { z } from 'zod';
2
+ import { FeeBreakdownSchema, TransactionPlanSchema, SwapEstimationSchema, ProviderTrackingInfoSchema, TokenSchema, } from './core.js';
3
+ export const SwapTokensRequestSchema = z.object({
4
+ fromToken: TokenSchema,
5
+ toToken: TokenSchema,
6
+ amount: z.bigint(),
7
+ limitPrice: z.string().optional(),
8
+ slippageTolerance: z.string().optional(),
9
+ expiration: z.string().optional(),
10
+ recipient: z.string(),
11
+ });
12
+ export const SwapTokensResponseSchema = z.object({
13
+ fromToken: TokenSchema,
14
+ toToken: TokenSchema,
15
+ exactFromAmount: z.string(),
16
+ displayFromAmount: z.string(),
17
+ exactToAmount: z.string(),
18
+ displayToAmount: z.string(),
19
+ transactions: z.array(TransactionPlanSchema),
20
+ feeBreakdown: FeeBreakdownSchema.optional(),
21
+ estimation: SwapEstimationSchema.optional(),
22
+ providerTracking: ProviderTrackingInfoSchema.optional(),
23
+ });
24
+ export const GetProviderTrackingStatusRequestSchema = z.object({
25
+ requestId: z.string(),
26
+ transactionId: z.string(),
27
+ });
28
+ export const GetProviderTrackingStatusResponseSchema = z.object({
29
+ trackingStatus: z.object({
30
+ requestId: z.string(),
31
+ transactionId: z.string(),
32
+ providerName: z.string(),
33
+ explorerUrl: z.string(),
34
+ status: z.string(),
35
+ }),
36
+ });
37
+ //# sourceMappingURL=swap.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"swap.js","sourceRoot":"","sources":["../../../src/core/schemas/swap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,kBAAkB,EAClB,qBAAqB,EACrB,oBAAoB,EACpB,0BAA0B,EAC1B,WAAW,GACZ,MAAM,WAAW,CAAC;AAEnB,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9C,SAAS,EAAE,WAAW;IACtB,OAAO,EAAE,WAAW;IACpB,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE;IAClB,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACxC,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;CACtB,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC/C,SAAS,EAAE,WAAW;IACtB,OAAO,EAAE,WAAW;IACpB,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE;IAC3B,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE;IAC7B,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE;IACzB,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE;IAC3B,YAAY,EAAE,CAAC,CAAC,KAAK,CAAC,qBAAqB,CAAC;IAC5C,YAAY,EAAE,kBAAkB,CAAC,QAAQ,EAAE;IAC3C,UAAU,EAAE,oBAAoB,CAAC,QAAQ,EAAE;IAC3C,gBAAgB,EAAE,0BAA0B,CAAC,QAAQ,EAAE;CACxD,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,sCAAsC,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7D,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE;CAC1B,CAAC,CAAC;AAKH,MAAM,CAAC,MAAM,uCAAuC,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9D,cAAc,EAAE,CAAC,CAAC,MAAM,CAAC;QACvB,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;QACrB,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE;QACzB,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE;QACxB,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE;QACvB,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE;KACnB,CAAC;CACH,CAAC,CAAC"}
@@ -0,0 +1,69 @@
1
+ import { z } from 'zod';
2
+ export declare const GetWalletBalancesRequestSchema: z.ZodObject<{
3
+ walletAddress: z.ZodString;
4
+ }, "strip", z.ZodTypeAny, {
5
+ walletAddress: string;
6
+ }, {
7
+ walletAddress: string;
8
+ }>;
9
+ export type GetWalletBalancesRequest = z.infer<typeof GetWalletBalancesRequestSchema>;
10
+ export declare const GetWalletBalancesResponseSchema: z.ZodObject<{
11
+ balances: z.ZodArray<z.ZodObject<{
12
+ tokenUid: z.ZodObject<{
13
+ chainId: z.ZodString;
14
+ address: z.ZodString;
15
+ }, "strip", z.ZodTypeAny, {
16
+ chainId: string;
17
+ address: string;
18
+ }, {
19
+ chainId: string;
20
+ address: string;
21
+ }>;
22
+ amount: z.ZodString;
23
+ symbol: z.ZodOptional<z.ZodString>;
24
+ valueUsd: z.ZodOptional<z.ZodNumber>;
25
+ decimals: z.ZodOptional<z.ZodNumber>;
26
+ }, "strip", z.ZodTypeAny, {
27
+ tokenUid: {
28
+ chainId: string;
29
+ address: string;
30
+ };
31
+ amount: string;
32
+ symbol?: string | undefined;
33
+ decimals?: number | undefined;
34
+ valueUsd?: number | undefined;
35
+ }, {
36
+ tokenUid: {
37
+ chainId: string;
38
+ address: string;
39
+ };
40
+ amount: string;
41
+ symbol?: string | undefined;
42
+ decimals?: number | undefined;
43
+ valueUsd?: number | undefined;
44
+ }>, "many">;
45
+ }, "strip", z.ZodTypeAny, {
46
+ balances: {
47
+ tokenUid: {
48
+ chainId: string;
49
+ address: string;
50
+ };
51
+ amount: string;
52
+ symbol?: string | undefined;
53
+ decimals?: number | undefined;
54
+ valueUsd?: number | undefined;
55
+ }[];
56
+ }, {
57
+ balances: {
58
+ tokenUid: {
59
+ chainId: string;
60
+ address: string;
61
+ };
62
+ amount: string;
63
+ symbol?: string | undefined;
64
+ decimals?: number | undefined;
65
+ valueUsd?: number | undefined;
66
+ }[];
67
+ }>;
68
+ export type GetWalletBalancesResponse = z.infer<typeof GetWalletBalancesResponseSchema>;
69
+ //# sourceMappingURL=wallet.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wallet.d.ts","sourceRoot":"","sources":["../../../src/core/schemas/wallet.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,8BAA8B;;;;;;EAEzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC;AAEtF,eAAO,MAAM,+BAA+B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAE1C,CAAC;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { z } from 'zod';
2
+ import { BalanceSchema } from './core.js';
3
+ export const GetWalletBalancesRequestSchema = z.object({
4
+ walletAddress: z.string(),
5
+ });
6
+ export const GetWalletBalancesResponseSchema = z.object({
7
+ balances: z.array(BalanceSchema),
8
+ });
9
+ //# sourceMappingURL=wallet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wallet.js","sourceRoot":"","sources":["../../../src/core/schemas/wallet.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAE1C,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,MAAM,CAAC;IACrD,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE;CAC1B,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAAC,CAAC,MAAM,CAAC;IACtD,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,aAAa,CAAC;CACjC,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import type { ChainConfig } from './chainConfig.js';
2
+ import { PublicEmberPluginRegistry } from './registry.js';
3
+ /**
4
+ * Initialize the public Ember plugin registry.
5
+ * @returns The initialized public Ember plugin registry with registered plugins.
6
+ */
7
+ export declare function initializePublicRegistry(chainConfigs: ChainConfig[]): PublicEmberPluginRegistry;
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,EAAE,yBAAyB,EAAE,MAAM,eAAe,CAAC;AAG1D;;;GAGG;AACH,wBAAgB,wBAAwB,CAAC,YAAY,EAAE,WAAW,EAAE,6BAUnE"}
package/dist/index.js ADDED
@@ -0,0 +1,16 @@
1
+ import { PublicEmberPluginRegistry } from './registry.js';
2
+ import { registerAave } from './aave-lending-plugin/index.js';
3
+ /**
4
+ * Initialize the public Ember plugin registry.
5
+ * @returns The initialized public Ember plugin registry with registered plugins.
6
+ */
7
+ export function initializePublicRegistry(chainConfigs) {
8
+ const registry = new PublicEmberPluginRegistry();
9
+ // Register any plugin in here
10
+ for (const chainConfig of chainConfigs) {
11
+ // Create aave plugins for each chain config
12
+ registerAave(chainConfig, registry);
13
+ }
14
+ return registry;
15
+ }
16
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,yBAAyB,EAAE,MAAM,eAAe,CAAC;AAC1D,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAE9D;;;GAGG;AACH,MAAM,UAAU,wBAAwB,CAAC,YAA2B;IAClE,MAAM,QAAQ,GAAG,IAAI,yBAAyB,EAAE,CAAC;IAEjD,8BAA8B;IAC9B,KAAK,MAAM,WAAW,IAAI,YAAY,EAAE,CAAC;QACvC,4CAA4C;QAC5C,YAAY,CAAC,WAAW,EAAE,QAAQ,CAAC,CAAC;IACtC,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC"}
@@ -0,0 +1,24 @@
1
+ import type { EmberPlugin, PluginType } from './core/index.js';
2
+ /**
3
+ * Registry for public Ember plugins.
4
+ */
5
+ export declare class PublicEmberPluginRegistry {
6
+ private plugins;
7
+ private deferredPlugins;
8
+ /**
9
+ * Register a new Ember plugin.
10
+ * @param plugin The plugin to register.
11
+ */
12
+ registerPlugin(plugin: EmberPlugin<PluginType>): void;
13
+ /**
14
+ * Register a new deferred Ember plugin.
15
+ * @param pluginPromise The promise resolving to the plugin to register.
16
+ */
17
+ registerDeferredPlugin(pluginPromise: Promise<EmberPlugin<PluginType>>): void;
18
+ /**
19
+ * Iterator for the registered Ember plugins.
20
+ */
21
+ getPlugins(): AsyncIterable<EmberPlugin<PluginType>>;
22
+ get emberPlugins(): EmberPlugin<PluginType>[];
23
+ }
24
+ //# sourceMappingURL=registry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../src/registry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAE/D;;GAEG;AACH,qBAAa,yBAAyB;IACpC,OAAO,CAAC,OAAO,CAAiC;IAChD,OAAO,CAAC,eAAe,CAA0C;IAEjE;;;OAGG;IACI,cAAc,CAAC,MAAM,EAAE,WAAW,CAAC,UAAU,CAAC;IAIrD;;;OAGG;IACI,sBAAsB,CAAC,aAAa,EAAE,OAAO,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;IAI7E;;OAEG;IACW,UAAU,IAAI,aAAa,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;IAelE,IAAW,YAAY,IAAI,WAAW,CAAC,UAAU,CAAC,EAAE,CAEnD;CACF"}
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Registry for public Ember plugins.
3
+ */
4
+ export class PublicEmberPluginRegistry {
5
+ plugins = [];
6
+ deferredPlugins = [];
7
+ /**
8
+ * Register a new Ember plugin.
9
+ * @param plugin The plugin to register.
10
+ */
11
+ registerPlugin(plugin) {
12
+ this.plugins.push(plugin);
13
+ }
14
+ /**
15
+ * Register a new deferred Ember plugin.
16
+ * @param pluginPromise The promise resolving to the plugin to register.
17
+ */
18
+ registerDeferredPlugin(pluginPromise) {
19
+ this.deferredPlugins.push(pluginPromise);
20
+ }
21
+ /**
22
+ * Iterator for the registered Ember plugins.
23
+ */
24
+ async *getPlugins() {
25
+ yield* this.plugins;
26
+ for (const pluginPromise of this.deferredPlugins) {
27
+ const plugin = await pluginPromise;
28
+ // Register the plugin now that it is resolved
29
+ this.registerPlugin(plugin);
30
+ yield plugin;
31
+ }
32
+ this.deferredPlugins = [];
33
+ }
34
+ get emberPlugins() {
35
+ return this.plugins;
36
+ }
37
+ }
38
+ //# sourceMappingURL=registry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"registry.js","sourceRoot":"","sources":["../src/registry.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,OAAO,yBAAyB;IAC5B,OAAO,GAA8B,EAAE,CAAC;IACxC,eAAe,GAAuC,EAAE,CAAC;IAEjE;;;OAGG;IACI,cAAc,CAAC,MAA+B;QACnD,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IAC5B,CAAC;IAED;;;OAGG;IACI,sBAAsB,CAAC,aAA+C;QAC3E,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IAC3C,CAAC;IAED;;OAEG;IACI,KAAK,CAAC,CAAC,UAAU;QACtB,KAAK,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC;QAEpB,KAAK,MAAM,aAAa,IAAI,IAAI,CAAC,eAAe,EAAE,CAAC;YACjD,MAAM,MAAM,GAAG,MAAM,aAAa,CAAC;YAEnC,8CAA8C;YAC9C,IAAI,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC;YAE5B,MAAM,MAAM,CAAC;QACf,CAAC;QAED,IAAI,CAAC,eAAe,GAAG,EAAE,CAAC;IAC5B,CAAC;IAED,IAAW,YAAY;QACrB,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;CACF"}