tapimo 0.10.2 → 0.11.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.
Files changed (135) hide show
  1. package/dist/App.d.ts +3412 -1968
  2. package/dist/App.d.ts.map +1 -1
  3. package/dist/App.js.map +1 -1
  4. package/dist/Webhooks.d.ts +0 -75
  5. package/dist/Webhooks.d.ts.map +1 -1
  6. package/dist/Webhooks.js +1 -143
  7. package/dist/Webhooks.js.map +1 -1
  8. package/dist/admin/App.d.ts +74 -74
  9. package/dist/admin/apps/api-keys.d.ts +4 -4
  10. package/dist/admin/apps/earn-vaults.d.ts +1 -1
  11. package/dist/admin/apps/organizations.d.ts +3 -3
  12. package/dist/admin/apps/verified-tokens.d.ts +74 -74
  13. package/dist/apps/data/App.d.ts +3618 -2954
  14. package/dist/apps/data/App.d.ts.map +1 -1
  15. package/dist/apps/data/App.js +5 -2
  16. package/dist/apps/data/App.js.map +1 -1
  17. package/dist/apps/data/routes/activities.d.ts +1 -1
  18. package/dist/apps/data/routes/activities.d.ts.map +1 -1
  19. package/dist/apps/data/routes/activities.js +55 -27
  20. package/dist/apps/data/routes/activities.js.map +1 -1
  21. package/dist/apps/data/routes/addresses.d.ts +343 -343
  22. package/dist/apps/data/routes/balances.d.ts +11 -11
  23. package/dist/apps/data/routes/blocks.d.ts +5 -5
  24. package/dist/apps/data/routes/coingecko.d.ts +176 -176
  25. package/dist/apps/data/routes/earn.d.ts +4 -4
  26. package/dist/apps/data/routes/exchanges.d.ts +4 -4
  27. package/dist/apps/data/routes/fee-amm.d.ts +26 -26
  28. package/dist/apps/data/routes/indexer.d.ts +34 -34
  29. package/dist/apps/data/routes/receipts.d.ts +236 -236
  30. package/dist/apps/data/routes/tokenlist.d.ts +12 -12
  31. package/dist/apps/data/routes/tokens.d.ts +3 -3
  32. package/dist/apps/data/routes/transactions.d.ts +1 -1
  33. package/dist/apps/data/routes/transfers.d.ts +13 -13
  34. package/dist/apps/data/routes/valuation.d.ts +21 -21
  35. package/dist/apps/data/routes/verified-tokens.d.ts +5 -5
  36. package/dist/apps/data/routes/webhooks.d.ts +1011 -151
  37. package/dist/apps/data/routes/webhooks.d.ts.map +1 -1
  38. package/dist/apps/data/routes/webhooks.js +124 -737
  39. package/dist/apps/data/routes/webhooks.js.map +1 -1
  40. package/dist/apps/data/routes/zones.d.ts +31 -31
  41. package/dist/apps/funding/routes/deposit-addresses.d.ts +2 -2
  42. package/dist/apps/funding/routes/providers.d.ts +13 -13
  43. package/dist/apps/funding/routes/transfers.d.ts +33 -33
  44. package/dist/apps/management/App.d.ts +793 -16
  45. package/dist/apps/management/App.d.ts.map +1 -1
  46. package/dist/apps/management/routes/api-keys.d.ts +50 -50
  47. package/dist/apps/management/routes/faucet.d.ts +31 -31
  48. package/dist/apps/management/routes/invite-links.d.ts +42 -42
  49. package/dist/apps/management/routes/members.d.ts +79 -79
  50. package/dist/apps/management/routes/projects.d.ts +40 -40
  51. package/dist/apps/management/routes/usage.d.ts +80 -80
  52. package/dist/apps/management/routes/webhooks.d.ts +1031 -59
  53. package/dist/apps/management/routes/webhooks.d.ts.map +1 -1
  54. package/dist/apps/management/routes/webhooks.js +27 -4
  55. package/dist/apps/management/routes/webhooks.js.map +1 -1
  56. package/dist/db/Db.d.ts.map +1 -1
  57. package/dist/db/Db.js +21 -0
  58. package/dist/db/Db.js.map +1 -1
  59. package/dist/db/Schema.d.ts +7 -1
  60. package/dist/db/Schema.d.ts.map +1 -1
  61. package/dist/db/Schema.js +9 -0
  62. package/dist/db/Schema.js.map +1 -1
  63. package/dist/db/tables/webhookQueueEvents.d.ts +3 -1
  64. package/dist/db/tables/webhookQueueEvents.d.ts.map +1 -1
  65. package/dist/db/tables/webhookQueueEvents.js +4 -0
  66. package/dist/db/tables/webhookQueueEvents.js.map +1 -1
  67. package/dist/db/tables/webhookSubscriptions.d.ts +33 -69
  68. package/dist/db/tables/webhookSubscriptions.d.ts.map +1 -1
  69. package/dist/db/tables/webhookSubscriptions.js +63 -100
  70. package/dist/db/tables/webhookSubscriptions.js.map +1 -1
  71. package/dist/internal/MetricSink.d.ts +35 -125
  72. package/dist/internal/MetricSink.d.ts.map +1 -1
  73. package/dist/internal/MetricSink.js +50 -121
  74. package/dist/internal/MetricSink.js.map +1 -1
  75. package/dist/internal/Schema.d.ts +3 -1
  76. package/dist/internal/Schema.d.ts.map +1 -1
  77. package/dist/internal/Schema.js +4 -2
  78. package/dist/internal/Schema.js.map +1 -1
  79. package/dist/internal/WebhookTransfer.d.ts +1 -55
  80. package/dist/internal/WebhookTransfer.d.ts.map +1 -1
  81. package/dist/internal/WebhookTransfer.js +1 -239
  82. package/dist/internal/WebhookTransfer.js.map +1 -1
  83. package/dist/internal/Webhooks.d.ts +83 -44
  84. package/dist/internal/Webhooks.d.ts.map +1 -1
  85. package/dist/internal/Webhooks.js +87 -73
  86. package/dist/internal/Webhooks.js.map +1 -1
  87. package/dist/internal/funding/DepositWebhook.d.ts +25 -0
  88. package/dist/internal/funding/DepositWebhook.d.ts.map +1 -0
  89. package/dist/internal/funding/DepositWebhook.js +74 -0
  90. package/dist/internal/funding/DepositWebhook.js.map +1 -0
  91. package/dist/internal/funding/Reconciliation.d.ts +6 -0
  92. package/dist/internal/funding/Reconciliation.d.ts.map +1 -1
  93. package/dist/internal/funding/Reconciliation.js +42 -10
  94. package/dist/internal/funding/Reconciliation.js.map +1 -1
  95. package/dist/internal/funding/index.d.ts +1 -0
  96. package/dist/internal/funding/index.d.ts.map +1 -1
  97. package/dist/internal/funding/index.js +1 -0
  98. package/dist/internal/funding/index.js.map +1 -1
  99. package/dist/internal/webhookDestinations/slack.d.ts.map +1 -1
  100. package/dist/internal/webhookDestinations/slack.js +16 -0
  101. package/dist/internal/webhookDestinations/slack.js.map +1 -1
  102. package/package.json +1 -1
  103. package/src/App.ts +3 -0
  104. package/src/Client.test-d.ts +22 -1
  105. package/src/Webhooks.ts +1 -220
  106. package/src/apps/data/App.ts +8 -2
  107. package/src/apps/data/routes/activities.test.ts +107 -11
  108. package/src/apps/data/routes/activities.ts +64 -32
  109. package/src/apps/data/routes/webhooks.test.ts +179 -1497
  110. package/src/apps/data/routes/webhooks.ts +150 -974
  111. package/src/apps/management/routes/webhooks.test.ts +79 -1
  112. package/src/apps/management/routes/webhooks.ts +40 -4
  113. package/src/db/Db.test.ts +1 -5
  114. package/src/db/Db.ts +23 -0
  115. package/src/db/Schema.ts +13 -0
  116. package/src/db/tables/organizations.test.ts +5 -2
  117. package/src/db/tables/webhookQueueEvents.ts +7 -1
  118. package/src/db/tables/webhookSubscriptions.ts +89 -138
  119. package/src/internal/MetricSink.test.ts +41 -373
  120. package/src/internal/MetricSink.ts +92 -273
  121. package/src/internal/Schema.test.ts +18 -0
  122. package/src/internal/Schema.ts +13 -2
  123. package/src/internal/WebhookTransfer.ts +1 -351
  124. package/src/internal/Webhooks.test.ts +102 -139
  125. package/src/internal/Webhooks.ts +175 -106
  126. package/src/internal/funding/DepositWebhook.test.ts +131 -0
  127. package/src/internal/funding/DepositWebhook.ts +101 -0
  128. package/src/internal/funding/Reconciliation.test.ts +14 -0
  129. package/src/internal/funding/Reconciliation.ts +161 -86
  130. package/src/internal/funding/index.test.ts +1 -0
  131. package/src/internal/funding/index.ts +1 -0
  132. package/src/internal/webhookDestinations/slack.ts +15 -0
  133. package/src/Webhooks.bench.ts +0 -714
  134. package/src/Webhooks.memory.bench.ts +0 -250
  135. package/src/Webhooks.test.ts +0 -146
@@ -68,14 +68,14 @@ export declare function tokenlist(): import("hono/hono-base").HonoBase<App.Envir
68
68
  } | {
69
69
  output: {
70
70
  error: {
71
- code: "upstream_error";
71
+ code: "api_key_malformed";
72
72
  details?: readonly Response.error.Detail[] | undefined;
73
73
  message: string;
74
74
  };
75
75
  requestId: string;
76
76
  };
77
77
  outputFormat: "json";
78
- status: 502;
78
+ status: 400;
79
79
  input: {
80
80
  query?: {
81
81
  chainId?: string | string[];
@@ -84,14 +84,14 @@ export declare function tokenlist(): import("hono/hono-base").HonoBase<App.Envir
84
84
  } | {
85
85
  output: {
86
86
  error: {
87
- code: "api_key_malformed";
87
+ code: "api_key_invalid" | "api_key_missing";
88
88
  details?: readonly Response.error.Detail[] | undefined;
89
89
  message: string;
90
90
  };
91
91
  requestId: string;
92
92
  };
93
93
  outputFormat: "json";
94
- status: 400;
94
+ status: 401;
95
95
  input: {
96
96
  query?: {
97
97
  chainId?: string | string[];
@@ -100,14 +100,14 @@ export declare function tokenlist(): import("hono/hono-base").HonoBase<App.Envir
100
100
  } | {
101
101
  output: {
102
102
  error: {
103
- code: "api_key_invalid" | "api_key_missing";
103
+ code: "api_key_forbidden" | "api_key_ip_forbidden";
104
104
  details?: readonly Response.error.Detail[] | undefined;
105
105
  message: string;
106
106
  };
107
107
  requestId: string;
108
108
  };
109
109
  outputFormat: "json";
110
- status: 401;
110
+ status: 403;
111
111
  input: {
112
112
  query?: {
113
113
  chainId?: string | string[];
@@ -116,14 +116,14 @@ export declare function tokenlist(): import("hono/hono-base").HonoBase<App.Envir
116
116
  } | {
117
117
  output: {
118
118
  error: {
119
- code: "api_key_forbidden" | "api_key_ip_forbidden";
119
+ code: "payment_required" | "rate_limit_exceeded";
120
120
  details?: readonly Response.error.Detail[] | undefined;
121
121
  message: string;
122
122
  };
123
123
  requestId: string;
124
124
  };
125
125
  outputFormat: "json";
126
- status: 403;
126
+ status: 429;
127
127
  input: {
128
128
  query?: {
129
129
  chainId?: string | string[];
@@ -132,14 +132,14 @@ export declare function tokenlist(): import("hono/hono-base").HonoBase<App.Envir
132
132
  } | {
133
133
  output: {
134
134
  error: {
135
- code: "payment_required" | "rate_limit_exceeded";
135
+ code: "query_invalid";
136
136
  details?: readonly Response.error.Detail[] | undefined;
137
137
  message: string;
138
138
  };
139
139
  requestId: string;
140
140
  };
141
141
  outputFormat: "json";
142
- status: 429;
142
+ status: 400;
143
143
  input: {
144
144
  query?: {
145
145
  chainId?: string | string[];
@@ -148,14 +148,14 @@ export declare function tokenlist(): import("hono/hono-base").HonoBase<App.Envir
148
148
  } | {
149
149
  output: {
150
150
  error: {
151
- code: "query_invalid";
151
+ code: "upstream_error";
152
152
  details?: readonly Response.error.Detail[] | undefined;
153
153
  message: string;
154
154
  };
155
155
  requestId: string;
156
156
  };
157
157
  outputFormat: "json";
158
- status: 400;
158
+ status: 502;
159
159
  input: {
160
160
  query?: {
161
161
  chainId?: string | string[];
@@ -136,7 +136,7 @@ export declare namespace schema {
136
136
  quoteToken: "quoteToken";
137
137
  transferStats: "transferStats";
138
138
  }>>>;
139
- limit: z.ZodMiniDefault<z.ZodMiniNumber<unknown>>;
139
+ limit: z.ZodMiniDefault<z.ZodMiniPipe<z.ZodMiniNumber<unknown>, z.ZodMiniTransform<number, number>>>;
140
140
  order: z.ZodMiniDefault<z.ZodMiniEnum<{
141
141
  asc: "asc";
142
142
  desc: "desc";
@@ -203,7 +203,7 @@ export declare namespace schema {
203
203
  token: "token";
204
204
  totalCount: "totalCount";
205
205
  }>>>;
206
- limit: z.ZodMiniDefault<z.ZodMiniNumber<unknown>>;
206
+ limit: z.ZodMiniDefault<z.ZodMiniPipe<z.ZodMiniNumber<unknown>, z.ZodMiniTransform<number, number>>>;
207
207
  page: z.ZodMiniOptional<z.ZodMiniNumber<unknown>>;
208
208
  }, z.core.$strict>;
209
209
  /** A single TIP-20 token holder. */
@@ -292,7 +292,7 @@ export declare namespace schema {
292
292
  token: "token";
293
293
  totalCount: "totalCount";
294
294
  }>>>;
295
- limit: z.ZodMiniDefault<z.ZodMiniNumber<unknown>>;
295
+ limit: z.ZodMiniDefault<z.ZodMiniPipe<z.ZodMiniNumber<unknown>, z.ZodMiniTransform<number, number>>>;
296
296
  order: z.ZodMiniDefault<z.ZodMiniEnum<{
297
297
  asc: "asc";
298
298
  desc: "desc";
@@ -711,7 +711,7 @@ export declare namespace schema {
711
711
  receipt: "receipt";
712
712
  totalCount: "totalCount";
713
713
  }>>>;
714
- limit: z.ZodMiniDefault<z.ZodMiniNumber<unknown>>;
714
+ limit: z.ZodMiniDefault<z.ZodMiniPipe<z.ZodMiniNumber<unknown>, z.ZodMiniTransform<number, number>>>;
715
715
  order: z.ZodMiniDefault<z.ZodMiniEnum<{
716
716
  asc: "asc";
717
717
  desc: "desc";
@@ -88,7 +88,7 @@ export declare namespace schema {
88
88
  "token.verified": "token.verified";
89
89
  totalCount: "totalCount";
90
90
  }>>>;
91
- limit: z.ZodMiniDefault<z.ZodMiniNumber<unknown>>;
91
+ limit: z.ZodMiniDefault<z.ZodMiniPipe<z.ZodMiniNumber<unknown>, z.ZodMiniTransform<number, number>>>;
92
92
  order: z.ZodMiniDefault<z.ZodMiniEnum<{
93
93
  asc: "asc";
94
94
  desc: "desc";
@@ -255,14 +255,14 @@ export declare function transfers(options?: transfers.Options): import("hono/hon
255
255
  } | {
256
256
  output: {
257
257
  error: {
258
- code: "upstream_error";
258
+ code: "api_key_malformed";
259
259
  details?: readonly Response.error.Detail[] | undefined;
260
260
  message: string;
261
261
  };
262
262
  requestId: string;
263
263
  };
264
264
  outputFormat: "json";
265
- status: 502;
265
+ status: 400;
266
266
  input: {
267
267
  query?: {
268
268
  recipient?: string | string[];
@@ -285,14 +285,14 @@ export declare function transfers(options?: transfers.Options): import("hono/hon
285
285
  } | {
286
286
  output: {
287
287
  error: {
288
- code: "api_key_malformed";
288
+ code: "api_key_invalid" | "api_key_missing";
289
289
  details?: readonly Response.error.Detail[] | undefined;
290
290
  message: string;
291
291
  };
292
292
  requestId: string;
293
293
  };
294
294
  outputFormat: "json";
295
- status: 400;
295
+ status: 401;
296
296
  input: {
297
297
  query?: {
298
298
  recipient?: string | string[];
@@ -315,14 +315,14 @@ export declare function transfers(options?: transfers.Options): import("hono/hon
315
315
  } | {
316
316
  output: {
317
317
  error: {
318
- code: "api_key_invalid" | "api_key_missing";
318
+ code: "api_key_forbidden" | "api_key_ip_forbidden";
319
319
  details?: readonly Response.error.Detail[] | undefined;
320
320
  message: string;
321
321
  };
322
322
  requestId: string;
323
323
  };
324
324
  outputFormat: "json";
325
- status: 401;
325
+ status: 403;
326
326
  input: {
327
327
  query?: {
328
328
  recipient?: string | string[];
@@ -345,14 +345,14 @@ export declare function transfers(options?: transfers.Options): import("hono/hon
345
345
  } | {
346
346
  output: {
347
347
  error: {
348
- code: "api_key_forbidden" | "api_key_ip_forbidden";
348
+ code: "payment_required" | "rate_limit_exceeded";
349
349
  details?: readonly Response.error.Detail[] | undefined;
350
350
  message: string;
351
351
  };
352
352
  requestId: string;
353
353
  };
354
354
  outputFormat: "json";
355
- status: 403;
355
+ status: 429;
356
356
  input: {
357
357
  query?: {
358
358
  recipient?: string | string[];
@@ -375,14 +375,14 @@ export declare function transfers(options?: transfers.Options): import("hono/hon
375
375
  } | {
376
376
  output: {
377
377
  error: {
378
- code: "payment_required" | "rate_limit_exceeded";
378
+ code: "query_invalid";
379
379
  details?: readonly Response.error.Detail[] | undefined;
380
380
  message: string;
381
381
  };
382
382
  requestId: string;
383
383
  };
384
384
  outputFormat: "json";
385
- status: 429;
385
+ status: 400;
386
386
  input: {
387
387
  query?: {
388
388
  recipient?: string | string[];
@@ -405,14 +405,14 @@ export declare function transfers(options?: transfers.Options): import("hono/hon
405
405
  } | {
406
406
  output: {
407
407
  error: {
408
- code: "query_invalid";
408
+ code: "upstream_error";
409
409
  details?: readonly Response.error.Detail[] | undefined;
410
410
  message: string;
411
411
  };
412
412
  requestId: string;
413
413
  };
414
414
  outputFormat: "json";
415
- status: 400;
415
+ status: 502;
416
416
  input: {
417
417
  query?: {
418
418
  recipient?: string | string[];
@@ -66,27 +66,6 @@ export declare function addresses(options?: addresses.Options): import("hono/hon
66
66
  currency?: string | string[];
67
67
  } | undefined;
68
68
  };
69
- } | {
70
- output: {
71
- error: {
72
- code: "upstream_error";
73
- details?: readonly Response.error.Detail[] | undefined;
74
- message: string;
75
- };
76
- requestId: string;
77
- };
78
- outputFormat: "json";
79
- status: 502;
80
- input: {
81
- param: {
82
- address: `0x${string}`;
83
- };
84
- } & {
85
- query?: {
86
- chainId?: string | string[];
87
- currency?: string | string[];
88
- } | undefined;
89
- };
90
69
  } | {
91
70
  output: {
92
71
  error: {
@@ -238,6 +217,27 @@ export declare function addresses(options?: addresses.Options): import("hono/hon
238
217
  currency?: string | string[];
239
218
  } | undefined;
240
219
  };
220
+ } | {
221
+ output: {
222
+ error: {
223
+ code: "upstream_error";
224
+ details?: readonly Response.error.Detail[] | undefined;
225
+ message: string;
226
+ };
227
+ requestId: string;
228
+ };
229
+ outputFormat: "json";
230
+ status: 502;
231
+ input: {
232
+ param: {
233
+ address: `0x${string}`;
234
+ };
235
+ } & {
236
+ query?: {
237
+ chainId?: string | string[];
238
+ currency?: string | string[];
239
+ } | undefined;
240
+ };
241
241
  };
242
242
  };
243
243
  }, "/", "/v1/addresses/:address/valuation">;
@@ -440,7 +440,7 @@ export declare function verifiedTokens(): import("hono/hono-base").HonoBase<App.
440
440
  } | {
441
441
  output: {
442
442
  error: {
443
- code: "query_invalid";
443
+ code: "address_invalid";
444
444
  details?: readonly Response.error.Detail[] | undefined;
445
445
  message: string;
446
446
  };
@@ -460,14 +460,14 @@ export declare function verifiedTokens(): import("hono/hono-base").HonoBase<App.
460
460
  } | {
461
461
  output: {
462
462
  error: {
463
- code: "upstream_error";
463
+ code: "query_invalid";
464
464
  details?: readonly Response.error.Detail[] | undefined;
465
465
  message: string;
466
466
  };
467
467
  requestId: string;
468
468
  };
469
469
  outputFormat: "json";
470
- status: 502;
470
+ status: 400;
471
471
  input: {
472
472
  param: {
473
473
  address: `0x${string}`;
@@ -480,14 +480,14 @@ export declare function verifiedTokens(): import("hono/hono-base").HonoBase<App.
480
480
  } | {
481
481
  output: {
482
482
  error: {
483
- code: "address_invalid";
483
+ code: "upstream_error";
484
484
  details?: readonly Response.error.Detail[] | undefined;
485
485
  message: string;
486
486
  };
487
487
  requestId: string;
488
488
  };
489
489
  outputFormat: "json";
490
- status: 400;
490
+ status: 502;
491
491
  input: {
492
492
  param: {
493
493
  address: `0x${string}`;