tapimo 0.5.3 → 0.7.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/dist/App.d.ts +15830 -7220
- package/dist/App.d.ts.map +1 -1
- package/dist/App.js +9 -1
- package/dist/App.js.map +1 -1
- package/dist/Scope.d.ts +4 -0
- package/dist/Scope.d.ts.map +1 -1
- package/dist/Scope.js +5 -0
- package/dist/Scope.js.map +1 -1
- package/dist/admin/App.d.ts +1011 -412
- package/dist/admin/App.d.ts.map +1 -1
- package/dist/admin/App.js +4 -0
- package/dist/admin/App.js.map +1 -1
- package/dist/admin/apps/api-keys.d.ts +2 -1
- package/dist/admin/apps/api-keys.d.ts.map +1 -1
- package/dist/admin/apps/early-access.d.ts +148 -0
- package/dist/admin/apps/early-access.d.ts.map +1 -0
- package/dist/admin/apps/early-access.js +133 -0
- package/dist/admin/apps/early-access.js.map +1 -0
- package/dist/admin/apps/organizations.d.ts +124 -1
- package/dist/admin/apps/organizations.d.ts.map +1 -1
- package/dist/admin/apps/organizations.js +97 -6
- package/dist/admin/apps/organizations.js.map +1 -1
- package/dist/admin/apps/verified-tokens.d.ts +526 -1
- package/dist/admin/apps/verified-tokens.d.ts.map +1 -1
- package/dist/admin/apps/verified-tokens.js +214 -1
- package/dist/admin/apps/verified-tokens.js.map +1 -1
- package/dist/admin/ui.generated.d.ts +1 -1
- package/dist/admin/ui.generated.d.ts.map +1 -1
- package/dist/admin/ui.generated.js +95 -75
- package/dist/admin/ui.generated.js.map +1 -1
- package/dist/analytics/Analytics.d.ts.map +1 -1
- package/dist/analytics/Analytics.js +20 -0
- package/dist/analytics/Analytics.js.map +1 -1
- package/dist/analytics/tables/requestEvents.d.ts +18 -0
- package/dist/analytics/tables/requestEvents.d.ts.map +1 -1
- package/dist/analytics/tables/requestEvents.js +36 -7
- package/dist/analytics/tables/requestEvents.js.map +1 -1
- package/dist/apps/data/App.d.ts +6260 -4924
- package/dist/apps/data/App.d.ts.map +1 -1
- package/dist/apps/data/App.js +11 -6
- package/dist/apps/data/App.js.map +1 -1
- package/dist/apps/data/FundingQuoteProviders.d.ts +34 -1
- package/dist/apps/data/FundingQuoteProviders.d.ts.map +1 -1
- package/dist/apps/data/FundingQuoteProviders.js +194 -16
- package/dist/apps/data/FundingQuoteProviders.js.map +1 -1
- package/dist/apps/data/FxOracle.d.ts +71 -0
- package/dist/apps/data/FxOracle.d.ts.map +1 -0
- package/dist/apps/data/FxOracle.js +97 -0
- package/dist/apps/data/FxOracle.js.map +1 -0
- package/dist/apps/data/index.d.ts +1 -0
- package/dist/apps/data/index.d.ts.map +1 -1
- package/dist/apps/data/index.js +1 -0
- package/dist/apps/data/index.js.map +1 -1
- package/dist/apps/data/routes/activities.d.ts +3599 -1382
- package/dist/apps/data/routes/activities.d.ts.map +1 -1
- package/dist/apps/data/routes/activities.js +250 -88
- package/dist/apps/data/routes/activities.js.map +1 -1
- package/dist/apps/data/routes/addresses.d.ts +872 -251
- package/dist/apps/data/routes/addresses.d.ts.map +1 -1
- package/dist/apps/data/routes/addresses.js +11 -9
- package/dist/apps/data/routes/addresses.js.map +1 -1
- package/dist/apps/data/routes/balances.d.ts +77 -26
- package/dist/apps/data/routes/balances.d.ts.map +1 -1
- package/dist/apps/data/routes/balances.js +88 -45
- package/dist/apps/data/routes/balances.js.map +1 -1
- package/dist/apps/data/routes/blocks.d.ts +39 -39
- package/dist/apps/data/routes/coingecko.d.ts +54 -54
- package/dist/apps/data/routes/exchanges.d.ts +856 -105
- package/dist/apps/data/routes/exchanges.d.ts.map +1 -1
- package/dist/apps/data/routes/exchanges.js +518 -76
- package/dist/apps/data/routes/exchanges.js.map +1 -1
- package/dist/apps/data/routes/fee-amm.d.ts +81 -67
- package/dist/apps/data/routes/fee-amm.d.ts.map +1 -1
- package/dist/apps/data/routes/fee-amm.js +76 -91
- package/dist/apps/data/routes/fee-amm.js.map +1 -1
- package/dist/apps/data/routes/funding.d.ts +80 -36
- package/dist/apps/data/routes/funding.d.ts.map +1 -1
- package/dist/apps/data/routes/funding.js +65 -31
- package/dist/apps/data/routes/funding.js.map +1 -1
- package/dist/apps/data/routes/receipts.d.ts +392 -315
- package/dist/apps/data/routes/receipts.d.ts.map +1 -1
- package/dist/apps/data/routes/receipts.js +152 -77
- package/dist/apps/data/routes/receipts.js.map +1 -1
- package/dist/apps/data/routes/tokens.d.ts +167 -174
- package/dist/apps/data/routes/tokens.d.ts.map +1 -1
- package/dist/apps/data/routes/tokens.js +15 -13
- package/dist/apps/data/routes/tokens.js.map +1 -1
- package/dist/apps/data/routes/transactions.d.ts +277 -536
- package/dist/apps/data/routes/transactions.d.ts.map +1 -1
- package/dist/apps/data/routes/transactions.js +96 -77
- package/dist/apps/data/routes/transactions.js.map +1 -1
- package/dist/apps/data/routes/transfers.d.ts +157 -81
- package/dist/apps/data/routes/transfers.d.ts.map +1 -1
- package/dist/apps/data/routes/transfers.js +272 -130
- package/dist/apps/data/routes/transfers.js.map +1 -1
- package/dist/apps/data/routes/valuation.d.ts +307 -0
- package/dist/apps/data/routes/valuation.d.ts.map +1 -0
- package/dist/apps/data/routes/valuation.js +292 -0
- package/dist/apps/data/routes/valuation.js.map +1 -0
- package/dist/apps/data/routes/verified-tokens.d.ts +36 -36
- package/dist/apps/data/routes/verified-tokens.d.ts.map +1 -1
- package/dist/apps/data/routes/verified-tokens.js +7 -5
- package/dist/apps/data/routes/verified-tokens.js.map +1 -1
- package/dist/apps/data/routes/webhooks.d.ts +103 -123
- package/dist/apps/data/routes/webhooks.d.ts.map +1 -1
- package/dist/apps/data/routes/webhooks.js +124 -25
- package/dist/apps/data/routes/webhooks.js.map +1 -1
- package/dist/apps/index.d.ts +2 -1
- package/dist/apps/index.d.ts.map +1 -1
- package/dist/apps/index.js +2 -1
- package/dist/apps/index.js.map +1 -1
- package/dist/apps/management/App.d.ts +8554 -1692
- package/dist/apps/management/App.d.ts.map +1 -1
- package/dist/apps/management/App.js +12 -1
- package/dist/apps/management/App.js.map +1 -1
- package/dist/apps/management/routes/api-keys.d.ts +7 -0
- package/dist/apps/management/routes/api-keys.d.ts.map +1 -1
- package/dist/apps/management/routes/api-keys.js +17 -3
- package/dist/apps/management/routes/api-keys.js.map +1 -1
- package/dist/apps/management/routes/billing.d.ts +157 -162
- package/dist/apps/management/routes/billing.d.ts.map +1 -1
- package/dist/apps/management/routes/billing.js +31 -23
- package/dist/apps/management/routes/billing.js.map +1 -1
- package/dist/apps/management/routes/faucet.d.ts +232 -0
- package/dist/apps/management/routes/faucet.d.ts.map +1 -0
- package/dist/apps/management/routes/faucet.js +154 -0
- package/dist/apps/management/routes/faucet.js.map +1 -0
- package/dist/apps/management/routes/invitations.d.ts +60 -60
- package/dist/apps/management/routes/invite-links.d.ts +49 -20
- package/dist/apps/management/routes/invite-links.d.ts.map +1 -1
- package/dist/apps/management/routes/invite-links.js +26 -1
- package/dist/apps/management/routes/invite-links.js.map +1 -1
- package/dist/apps/management/routes/me.d.ts +6 -6
- package/dist/apps/management/routes/members.d.ts +6 -6
- package/dist/apps/management/routes/orgs.d.ts +42 -42
- package/dist/apps/management/routes/orgs.d.ts.map +1 -1
- package/dist/apps/management/routes/orgs.js +5 -0
- package/dist/apps/management/routes/orgs.js.map +1 -1
- package/dist/apps/management/routes/projects.d.ts +44 -44
- package/dist/apps/management/routes/usage.d.ts +3 -0
- package/dist/apps/management/routes/usage.d.ts.map +1 -1
- package/dist/apps/management/routes/usage.js +4 -0
- package/dist/apps/management/routes/usage.js.map +1 -1
- package/dist/apps/management/routes/verified-token-requests.d.ts +697 -0
- package/dist/apps/management/routes/verified-token-requests.d.ts.map +1 -0
- package/dist/apps/management/routes/verified-token-requests.js +271 -0
- package/dist/apps/management/routes/verified-token-requests.js.map +1 -0
- package/dist/apps/management/routes/webhooks.d.ts +6977 -0
- package/dist/apps/management/routes/webhooks.d.ts.map +1 -0
- package/dist/apps/management/routes/webhooks.js +573 -0
- package/dist/apps/management/routes/webhooks.js.map +1 -0
- package/dist/apps/mpp/App.d.ts +363 -0
- package/dist/apps/mpp/App.d.ts.map +1 -0
- package/dist/apps/mpp/App.js +72 -0
- package/dist/apps/mpp/App.js.map +1 -0
- package/dist/apps/mpp/Mpp.d.ts +178 -0
- package/dist/apps/mpp/Mpp.d.ts.map +1 -0
- package/dist/apps/mpp/Mpp.js +183 -0
- package/dist/apps/mpp/Mpp.js.map +1 -0
- package/dist/apps/mpp/index.d.ts +3 -0
- package/dist/apps/mpp/index.d.ts.map +1 -0
- package/dist/apps/mpp/index.js +3 -0
- package/dist/apps/mpp/index.js.map +1 -0
- package/dist/apps/relay/App.d.ts.map +1 -1
- package/dist/apps/relay/App.js +56 -9
- package/dist/apps/relay/App.js.map +1 -1
- package/dist/db/Db.d.ts +6 -0
- package/dist/db/Db.d.ts.map +1 -1
- package/dist/db/Db.js +110 -0
- package/dist/db/Db.js.map +1 -1
- package/dist/db/Schema.d.ts +53 -0
- package/dist/db/Schema.d.ts.map +1 -1
- package/dist/db/Schema.js +56 -0
- package/dist/db/Schema.js.map +1 -1
- package/dist/db/tables/earlyAccess.d.ts +50 -0
- package/dist/db/tables/earlyAccess.d.ts.map +1 -0
- package/dist/db/tables/earlyAccess.js +63 -0
- package/dist/db/tables/earlyAccess.js.map +1 -0
- package/dist/db/tables/enabledBillingSources.d.ts +73 -0
- package/dist/db/tables/enabledBillingSources.d.ts.map +1 -0
- package/dist/db/tables/enabledBillingSources.js +69 -0
- package/dist/db/tables/enabledBillingSources.js.map +1 -0
- package/dist/db/tables/invitations.d.ts.map +1 -1
- package/dist/db/tables/invitations.js +3 -0
- package/dist/db/tables/invitations.js.map +1 -1
- package/dist/db/tables/inviteLinks.d.ts +10 -2
- package/dist/db/tables/inviteLinks.d.ts.map +1 -1
- package/dist/db/tables/inviteLinks.js +10 -1
- package/dist/db/tables/inviteLinks.js.map +1 -1
- package/dist/db/tables/organizations.d.ts +5 -2
- package/dist/db/tables/organizations.d.ts.map +1 -1
- package/dist/db/tables/organizations.js +13 -2
- package/dist/db/tables/organizations.js.map +1 -1
- package/dist/db/tables/sponsoredTransactions.d.ts +2 -0
- package/dist/db/tables/sponsoredTransactions.d.ts.map +1 -1
- package/dist/db/tables/sponsoredTransactions.js +2 -0
- package/dist/db/tables/sponsoredTransactions.js.map +1 -1
- package/dist/db/tables/verifiedTokenRequests.d.ts +94 -0
- package/dist/db/tables/verifiedTokenRequests.d.ts.map +1 -0
- package/dist/db/tables/verifiedTokenRequests.js +120 -0
- package/dist/db/tables/verifiedTokenRequests.js.map +1 -0
- package/dist/db/tables/webhookSubscriptions.d.ts +14 -0
- package/dist/db/tables/webhookSubscriptions.d.ts.map +1 -1
- package/dist/db/tables/webhookSubscriptions.js +16 -0
- package/dist/db/tables/webhookSubscriptions.js.map +1 -1
- package/dist/handlers/internal/utils.d.ts +1 -16
- package/dist/handlers/internal/utils.d.ts.map +1 -1
- package/dist/handlers/internal/utils.js +17 -6
- package/dist/handlers/internal/utils.js.map +1 -1
- package/dist/handlers/relay.d.ts.map +1 -1
- package/dist/handlers/relay.js +37 -5
- package/dist/handlers/relay.js.map +1 -1
- package/dist/internal/Auth.d.ts +11 -2
- package/dist/internal/Auth.d.ts.map +1 -1
- package/dist/internal/Auth.js +14 -47
- package/dist/internal/Auth.js.map +1 -1
- package/dist/internal/FundingQuotes.d.ts +147 -47
- package/dist/internal/FundingQuotes.d.ts.map +1 -1
- package/dist/internal/FundingQuotes.js +119 -33
- package/dist/internal/FundingQuotes.js.map +1 -1
- package/dist/internal/Log.d.ts +37 -5
- package/dist/internal/Log.d.ts.map +1 -1
- package/dist/internal/Log.js +52 -3
- package/dist/internal/Log.js.map +1 -1
- package/dist/internal/MetricSink.d.ts.map +1 -1
- package/dist/internal/MetricSink.js +24 -0
- package/dist/internal/MetricSink.js.map +1 -1
- package/dist/internal/OpenApi.d.ts +2 -2
- package/dist/internal/OpenApi.d.ts.map +1 -1
- package/dist/internal/OpenApi.js +3 -0
- package/dist/internal/OpenApi.js.map +1 -1
- package/dist/internal/Response.d.ts +2 -2
- package/dist/internal/Response.d.ts.map +1 -1
- package/dist/internal/Response.js +12 -4
- package/dist/internal/Response.js.map +1 -1
- package/dist/internal/Schema.d.ts +14 -5
- package/dist/internal/Schema.d.ts.map +1 -1
- package/dist/internal/Schema.js +23 -5
- package/dist/internal/Schema.js.map +1 -1
- package/dist/internal/Value.d.ts +18 -0
- package/dist/internal/Value.d.ts.map +1 -1
- package/dist/internal/Value.js +11 -1
- package/dist/internal/Value.js.map +1 -1
- package/dist/internal/VerifiedTokens.d.ts.map +1 -1
- package/dist/internal/VerifiedTokens.js +10 -1
- package/dist/internal/VerifiedTokens.js.map +1 -1
- package/dist/internal/Webhooks.d.ts +24 -3
- package/dist/internal/Webhooks.d.ts.map +1 -1
- package/dist/internal/Webhooks.js +34 -8
- package/dist/internal/Webhooks.js.map +1 -1
- package/package.json +7 -2
- package/src/App.test.ts +9 -4
- package/src/App.ts +23 -3
- package/src/Client.test-d.ts +733 -20
- package/src/Scope.ts +5 -0
- package/src/admin/App.test.ts +4 -0
- package/src/admin/App.ts +4 -0
- package/src/admin/apps/early-access.test.ts +125 -0
- package/src/admin/apps/early-access.ts +176 -0
- package/src/admin/apps/organizations.test.ts +86 -2
- package/src/admin/apps/organizations.ts +155 -31
- package/src/admin/apps/scopes.test.ts +5 -0
- package/src/admin/apps/verified-tokens.test.ts +201 -0
- package/src/admin/apps/verified-tokens.ts +532 -286
- package/src/admin/ui/plugin.ts +2 -1
- package/src/admin/ui/src/lib/early-access.ts +63 -0
- package/src/admin/ui/src/lib/organizations.test.ts +81 -1
- package/src/admin/ui/src/lib/organizations.ts +92 -0
- package/src/admin/ui/src/lib/verified-tokens.ts +79 -0
- package/src/admin/ui/src/routeTree.gen.ts +33 -2
- package/src/admin/ui/src/routes/__root.tsx +2 -1
- package/src/admin/ui/src/routes/api-keys.tsx +1 -1
- package/src/admin/ui/src/routes/early-access.tsx +162 -0
- package/src/admin/ui/src/routes/organizations_.$orgId.tsx +103 -0
- package/src/admin/ui/src/routes/verified-tokens.tsx +230 -19
- package/src/admin/ui.generated.ts +95 -94
- package/src/analytics/Analytics.test.ts +83 -0
- package/src/analytics/Analytics.ts +20 -0
- package/src/analytics/tables/requestEvents.ts +60 -7
- package/src/apps/composition.test.ts +11 -2
- package/src/apps/data/App.test.ts +1 -1
- package/src/apps/data/App.ts +22 -14
- package/src/apps/data/FundingQuoteProviders.test.ts +297 -4
- package/src/apps/data/FundingQuoteProviders.ts +255 -29
- package/src/apps/data/FxOracle.test.ts +118 -0
- package/src/apps/data/FxOracle.ts +153 -0
- package/src/apps/data/index.ts +1 -0
- package/src/apps/data/routes/activities.test.ts +177 -3
- package/src/apps/data/routes/activities.ts +441 -132
- package/src/apps/data/routes/addresses.ts +19 -9
- package/src/apps/data/routes/balances.test.ts +148 -11
- package/src/apps/data/routes/balances.ts +140 -51
- package/src/apps/data/routes/exchanges.test.ts +544 -9
- package/src/apps/data/routes/exchanges.ts +690 -103
- package/src/apps/data/routes/fee-amm.test.ts +47 -23
- package/src/apps/data/routes/fee-amm.ts +98 -119
- package/src/apps/data/routes/funding.test.ts +113 -8
- package/src/apps/data/routes/funding.ts +77 -51
- package/src/apps/data/routes/receipts.test.ts +129 -23
- package/src/apps/data/routes/receipts.ts +205 -100
- package/src/apps/data/routes/tokens.test.ts +43 -0
- package/src/apps/data/routes/tokens.ts +28 -13
- package/src/apps/data/routes/transactions.test.ts +72 -19
- package/src/apps/data/routes/transactions.ts +162 -92
- package/src/apps/data/routes/transfers.test.ts +341 -31
- package/src/apps/data/routes/transfers.ts +358 -158
- package/src/apps/data/routes/valuation.test.ts +437 -0
- package/src/apps/data/routes/valuation.ts +423 -0
- package/src/apps/data/routes/verified-tokens.ts +14 -2
- package/src/apps/data/routes/webhooks.test.ts +56 -8
- package/src/apps/data/routes/webhooks.ts +144 -27
- package/src/apps/index.ts +2 -1
- package/src/apps/management/App.ts +13 -0
- package/src/apps/management/routes/api-keys.test.ts +14 -0
- package/src/apps/management/routes/api-keys.ts +27 -3
- package/src/apps/management/routes/billing.test.ts +152 -20
- package/src/apps/management/routes/billing.ts +34 -18
- package/src/apps/management/routes/faucet.test.ts +87 -0
- package/src/apps/management/routes/faucet.ts +201 -0
- package/src/apps/management/routes/invite-links.test.ts +117 -0
- package/src/apps/management/routes/invite-links.ts +43 -1
- package/src/apps/management/routes/me.test.ts +9 -99
- package/src/apps/management/routes/orgs.test.ts +45 -2
- package/src/apps/management/routes/orgs.ts +6 -0
- package/src/apps/management/routes/scopes.test.ts +1 -0
- package/src/apps/management/routes/usage.test.ts +6 -0
- package/src/apps/management/routes/usage.ts +7 -0
- package/src/apps/management/routes/verified-token-requests.test.ts +377 -0
- package/src/apps/management/routes/verified-token-requests.ts +397 -0
- package/src/apps/management/routes/webhooks.test.ts +426 -0
- package/src/apps/management/routes/webhooks.ts +672 -0
- package/src/apps/mpp/App.ts +86 -0
- package/src/apps/mpp/Mpp.test.ts +193 -0
- package/src/apps/mpp/Mpp.ts +353 -0
- package/src/apps/mpp/index.ts +2 -0
- package/src/apps/mpp/internal/Adapter.ts +11 -0
- package/src/apps/mpp/internal/Error.ts +9 -0
- package/src/apps/mpp/internal/Idempotency.ts +7 -0
- package/src/apps/mpp/internal/Screening.ts +10 -0
- package/src/apps/relay/App.test.ts +88 -6
- package/src/apps/relay/App.ts +61 -9
- package/src/db/Db.test.ts +19 -0
- package/src/db/Db.ts +125 -0
- package/src/db/Schema.ts +68 -0
- package/src/db/tables/earlyAccess.ts +86 -0
- package/src/db/tables/enabledBillingSources.test.ts +303 -0
- package/src/db/tables/enabledBillingSources.ts +118 -0
- package/src/db/tables/invitations.ts +3 -0
- package/src/db/tables/inviteLinks.ts +22 -3
- package/src/db/tables/organizations.test.ts +103 -0
- package/src/db/tables/organizations.ts +18 -2
- package/src/db/tables/sponsoredTransactions.ts +4 -0
- package/src/db/tables/verifiedTokenRequests.test.ts +200 -0
- package/src/db/tables/verifiedTokenRequests.ts +182 -0
- package/src/db/tables/webhookSubscriptions.ts +31 -0
- package/src/handlers/internal/utils.ts +22 -6
- package/src/handlers/relay.errors.test.ts +153 -0
- package/src/handlers/relay.ts +42 -7
- package/src/internal/Auth.test.ts +3 -3
- package/src/internal/Auth.ts +15 -47
- package/src/internal/FundingQuotes.test.ts +161 -6
- package/src/internal/FundingQuotes.ts +141 -39
- package/src/internal/Log.test-d.ts +21 -0
- package/src/internal/Log.test.ts +141 -0
- package/src/internal/Log.ts +93 -6
- package/src/internal/MetricSink.test.ts +215 -0
- package/src/internal/MetricSink.ts +24 -0
- package/src/internal/OpenApi.ts +3 -0
- package/src/internal/Response.test.ts +28 -0
- package/src/internal/Response.ts +12 -4
- package/src/internal/Schema.ts +50 -5
- package/src/internal/Value.test.ts +20 -0
- package/src/internal/Value.ts +24 -1
- package/src/internal/VerifiedTokens.ts +9 -1
- package/src/internal/Webhooks.test.ts +140 -0
- package/src/internal/Webhooks.ts +53 -9
|
@@ -23,6 +23,7 @@ export declare namespace schema {
|
|
|
23
23
|
/** Source or destination token reference. */
|
|
24
24
|
const Token: z.ZodMiniObject<{
|
|
25
25
|
address: z.ZodMiniString<string>;
|
|
26
|
+
currency: z.ZodMiniString<string>;
|
|
26
27
|
decimals: z.ZodMiniNumber<number>;
|
|
27
28
|
metadata: z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>;
|
|
28
29
|
name: z.ZodMiniString<string>;
|
|
@@ -31,9 +32,11 @@ export declare namespace schema {
|
|
|
31
32
|
tokenKey: z.ZodMiniString<string>;
|
|
32
33
|
verified: z.ZodMiniBoolean<boolean>;
|
|
33
34
|
}, z.core.$strip>;
|
|
34
|
-
/**
|
|
35
|
+
/** Self-contained source or destination amount in a funding quote. */
|
|
35
36
|
const TokenAmount: z.ZodMiniObject<{
|
|
36
|
-
|
|
37
|
+
baseUnits: z.ZodMiniString<string>;
|
|
38
|
+
currency: z.ZodMiniString<string>;
|
|
39
|
+
decimals: z.ZodMiniNumber<number>;
|
|
37
40
|
formatted: z.ZodMiniString<string>;
|
|
38
41
|
}, z.core.$strip>;
|
|
39
42
|
/** Provider summary embedded in a funding quote. */
|
|
@@ -43,6 +46,7 @@ export declare namespace schema {
|
|
|
43
46
|
relay: "relay";
|
|
44
47
|
rhino: "rhino";
|
|
45
48
|
squid: "squid";
|
|
49
|
+
symbiosis: "symbiosis";
|
|
46
50
|
}>;
|
|
47
51
|
kind: z.ZodMiniString<string>;
|
|
48
52
|
name: z.ZodMiniString<string>;
|
|
@@ -58,17 +62,25 @@ export declare namespace schema {
|
|
|
58
62
|
thin: "thin";
|
|
59
63
|
}>;
|
|
60
64
|
}, z.core.$strip>;
|
|
61
|
-
/** Provider
|
|
65
|
+
/** Provider quote freshness data. */
|
|
62
66
|
const QuoteDetails: z.ZodMiniObject<{
|
|
63
67
|
expiresAt: z.ZodMiniOptional<z.ZodMiniISODateTime>;
|
|
64
|
-
inputAmount: z.ZodMiniString<string>;
|
|
65
|
-
minimumOutputAmount: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
66
|
-
outputAmount: z.ZodMiniString<string>;
|
|
67
|
-
outputAmountFormatted: z.ZodMiniString<string>;
|
|
68
68
|
sampledAt: z.ZodMiniISODateTime;
|
|
69
69
|
}, z.core.$strip>;
|
|
70
70
|
/** Successful live funding quote. */
|
|
71
71
|
const FundingQuote: z.ZodMiniObject<{
|
|
72
|
+
destinationAmount: z.ZodMiniObject<{
|
|
73
|
+
baseUnits: z.ZodMiniString<string>;
|
|
74
|
+
currency: z.ZodMiniString<string>;
|
|
75
|
+
decimals: z.ZodMiniNumber<number>;
|
|
76
|
+
formatted: z.ZodMiniString<string>;
|
|
77
|
+
}, z.core.$strip>;
|
|
78
|
+
destinationAmountMin: z.ZodMiniOptional<z.ZodMiniObject<{
|
|
79
|
+
baseUnits: z.ZodMiniString<string>;
|
|
80
|
+
currency: z.ZodMiniString<string>;
|
|
81
|
+
decimals: z.ZodMiniNumber<number>;
|
|
82
|
+
formatted: z.ZodMiniString<string>;
|
|
83
|
+
}, z.core.$strip>>;
|
|
72
84
|
destinationChain: z.ZodMiniObject<{
|
|
73
85
|
addressFormat: z.ZodMiniEnum<{
|
|
74
86
|
base58: "base58";
|
|
@@ -86,6 +98,7 @@ export declare namespace schema {
|
|
|
86
98
|
}, z.core.$strip>;
|
|
87
99
|
destinationToken: z.ZodMiniObject<{
|
|
88
100
|
address: z.ZodMiniString<string>;
|
|
101
|
+
currency: z.ZodMiniString<string>;
|
|
89
102
|
decimals: z.ZodMiniNumber<number>;
|
|
90
103
|
metadata: z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>;
|
|
91
104
|
name: z.ZodMiniString<string>;
|
|
@@ -101,6 +114,7 @@ export declare namespace schema {
|
|
|
101
114
|
relay: "relay";
|
|
102
115
|
rhino: "rhino";
|
|
103
116
|
squid: "squid";
|
|
117
|
+
symbiosis: "symbiosis";
|
|
104
118
|
}>;
|
|
105
119
|
kind: z.ZodMiniString<string>;
|
|
106
120
|
name: z.ZodMiniString<string>;
|
|
@@ -117,14 +131,12 @@ export declare namespace schema {
|
|
|
117
131
|
}, z.core.$strip>;
|
|
118
132
|
quote: z.ZodMiniObject<{
|
|
119
133
|
expiresAt: z.ZodMiniOptional<z.ZodMiniISODateTime>;
|
|
120
|
-
inputAmount: z.ZodMiniString<string>;
|
|
121
|
-
minimumOutputAmount: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
122
|
-
outputAmount: z.ZodMiniString<string>;
|
|
123
|
-
outputAmountFormatted: z.ZodMiniString<string>;
|
|
124
134
|
sampledAt: z.ZodMiniISODateTime;
|
|
125
135
|
}, z.core.$strip>;
|
|
126
136
|
sourceAmount: z.ZodMiniObject<{
|
|
127
|
-
|
|
137
|
+
baseUnits: z.ZodMiniString<string>;
|
|
138
|
+
currency: z.ZodMiniString<string>;
|
|
139
|
+
decimals: z.ZodMiniNumber<number>;
|
|
128
140
|
formatted: z.ZodMiniString<string>;
|
|
129
141
|
}, z.core.$strip>;
|
|
130
142
|
sourceChain: z.ZodMiniObject<{
|
|
@@ -144,6 +156,7 @@ export declare namespace schema {
|
|
|
144
156
|
}, z.core.$strip>;
|
|
145
157
|
sourceToken: z.ZodMiniObject<{
|
|
146
158
|
address: z.ZodMiniString<string>;
|
|
159
|
+
currency: z.ZodMiniString<string>;
|
|
147
160
|
decimals: z.ZodMiniNumber<number>;
|
|
148
161
|
metadata: z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>;
|
|
149
162
|
name: z.ZodMiniString<string>;
|
|
@@ -160,6 +173,7 @@ export declare namespace schema {
|
|
|
160
173
|
relay: "relay";
|
|
161
174
|
rhino: "rhino";
|
|
162
175
|
squid: "squid";
|
|
176
|
+
symbiosis: "symbiosis";
|
|
163
177
|
}>;
|
|
164
178
|
kind: z.ZodMiniString<string>;
|
|
165
179
|
name: z.ZodMiniString<string>;
|
|
@@ -186,6 +200,7 @@ export declare namespace schema {
|
|
|
186
200
|
providerIds: z.ZodMiniOptional<z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>>;
|
|
187
201
|
tokens: z.ZodMiniArray<z.ZodMiniObject<{
|
|
188
202
|
address: z.ZodMiniString<string>;
|
|
203
|
+
currency: z.ZodMiniString<string>;
|
|
189
204
|
decimals: z.ZodMiniNumber<number>;
|
|
190
205
|
metadata: z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>;
|
|
191
206
|
name: z.ZodMiniString<string>;
|
|
@@ -205,6 +220,7 @@ export declare namespace schema {
|
|
|
205
220
|
relay: "relay";
|
|
206
221
|
rhino: "rhino";
|
|
207
222
|
squid: "squid";
|
|
223
|
+
symbiosis: "symbiosis";
|
|
208
224
|
}>>;
|
|
209
225
|
sourceAmount: z.ZodMiniString<string>;
|
|
210
226
|
sourceAmountUnits: z.ZodMiniDefault<z.ZodMiniEnum<{
|
|
@@ -217,6 +233,18 @@ export declare namespace schema {
|
|
|
217
233
|
/** Non-paginated list of successful funding quotes. */
|
|
218
234
|
const Response: z.ZodMiniObject<{
|
|
219
235
|
data: z.ZodMiniArray<z.ZodMiniObject<{
|
|
236
|
+
destinationAmount: z.ZodMiniObject<{
|
|
237
|
+
baseUnits: z.ZodMiniString<string>;
|
|
238
|
+
currency: z.ZodMiniString<string>;
|
|
239
|
+
decimals: z.ZodMiniNumber<number>;
|
|
240
|
+
formatted: z.ZodMiniString<string>;
|
|
241
|
+
}, z.core.$strip>;
|
|
242
|
+
destinationAmountMin: z.ZodMiniOptional<z.ZodMiniObject<{
|
|
243
|
+
baseUnits: z.ZodMiniString<string>;
|
|
244
|
+
currency: z.ZodMiniString<string>;
|
|
245
|
+
decimals: z.ZodMiniNumber<number>;
|
|
246
|
+
formatted: z.ZodMiniString<string>;
|
|
247
|
+
}, z.core.$strip>>;
|
|
220
248
|
destinationChain: z.ZodMiniObject<{
|
|
221
249
|
addressFormat: z.ZodMiniEnum<{
|
|
222
250
|
base58: "base58";
|
|
@@ -234,6 +262,7 @@ export declare namespace schema {
|
|
|
234
262
|
}, z.core.$strip>;
|
|
235
263
|
destinationToken: z.ZodMiniObject<{
|
|
236
264
|
address: z.ZodMiniString<string>;
|
|
265
|
+
currency: z.ZodMiniString<string>;
|
|
237
266
|
decimals: z.ZodMiniNumber<number>;
|
|
238
267
|
metadata: z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>;
|
|
239
268
|
name: z.ZodMiniString<string>;
|
|
@@ -249,6 +278,7 @@ export declare namespace schema {
|
|
|
249
278
|
relay: "relay";
|
|
250
279
|
rhino: "rhino";
|
|
251
280
|
squid: "squid";
|
|
281
|
+
symbiosis: "symbiosis";
|
|
252
282
|
}>;
|
|
253
283
|
kind: z.ZodMiniString<string>;
|
|
254
284
|
name: z.ZodMiniString<string>;
|
|
@@ -265,14 +295,12 @@ export declare namespace schema {
|
|
|
265
295
|
}, z.core.$strip>;
|
|
266
296
|
quote: z.ZodMiniObject<{
|
|
267
297
|
expiresAt: z.ZodMiniOptional<z.ZodMiniISODateTime>;
|
|
268
|
-
inputAmount: z.ZodMiniString<string>;
|
|
269
|
-
minimumOutputAmount: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
270
|
-
outputAmount: z.ZodMiniString<string>;
|
|
271
|
-
outputAmountFormatted: z.ZodMiniString<string>;
|
|
272
298
|
sampledAt: z.ZodMiniISODateTime;
|
|
273
299
|
}, z.core.$strip>;
|
|
274
300
|
sourceAmount: z.ZodMiniObject<{
|
|
275
|
-
|
|
301
|
+
baseUnits: z.ZodMiniString<string>;
|
|
302
|
+
currency: z.ZodMiniString<string>;
|
|
303
|
+
decimals: z.ZodMiniNumber<number>;
|
|
276
304
|
formatted: z.ZodMiniString<string>;
|
|
277
305
|
}, z.core.$strip>;
|
|
278
306
|
sourceChain: z.ZodMiniObject<{
|
|
@@ -292,6 +320,7 @@ export declare namespace schema {
|
|
|
292
320
|
}, z.core.$strip>;
|
|
293
321
|
sourceToken: z.ZodMiniObject<{
|
|
294
322
|
address: z.ZodMiniString<string>;
|
|
323
|
+
currency: z.ZodMiniString<string>;
|
|
295
324
|
decimals: z.ZodMiniNumber<number>;
|
|
296
325
|
metadata: z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>;
|
|
297
326
|
name: z.ZodMiniString<string>;
|
|
@@ -323,6 +352,7 @@ export declare namespace schema {
|
|
|
323
352
|
providerIds: z.ZodMiniOptional<z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>>;
|
|
324
353
|
tokens: z.ZodMiniArray<z.ZodMiniObject<{
|
|
325
354
|
address: z.ZodMiniString<string>;
|
|
355
|
+
currency: z.ZodMiniString<string>;
|
|
326
356
|
decimals: z.ZodMiniNumber<number>;
|
|
327
357
|
metadata: z.ZodMiniRecord<z.ZodMiniString<string>, z.ZodMiniString<string>>;
|
|
328
358
|
name: z.ZodMiniString<string>;
|
|
@@ -344,6 +374,7 @@ export declare namespace schema {
|
|
|
344
374
|
relay: "relay";
|
|
345
375
|
rhino: "rhino";
|
|
346
376
|
squid: "squid";
|
|
377
|
+
symbiosis: "symbiosis";
|
|
347
378
|
}>;
|
|
348
379
|
kind: z.ZodMiniString<string>;
|
|
349
380
|
name: z.ZodMiniString<string>;
|
|
@@ -376,14 +407,14 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
376
407
|
} | {
|
|
377
408
|
output: {
|
|
378
409
|
error: {
|
|
379
|
-
code: "
|
|
410
|
+
code: "upstream_error";
|
|
380
411
|
details?: readonly Response.error.Detail[] | undefined;
|
|
381
412
|
message: string;
|
|
382
413
|
};
|
|
383
414
|
requestId: string;
|
|
384
415
|
};
|
|
385
416
|
outputFormat: "json";
|
|
386
|
-
status:
|
|
417
|
+
status: 502;
|
|
387
418
|
input: {
|
|
388
419
|
query: {
|
|
389
420
|
destinationToken?: string | string[];
|
|
@@ -397,14 +428,14 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
397
428
|
} | {
|
|
398
429
|
output: {
|
|
399
430
|
error: {
|
|
400
|
-
code: "
|
|
431
|
+
code: "api_key_malformed";
|
|
401
432
|
details?: readonly Response.error.Detail[] | undefined;
|
|
402
433
|
message: string;
|
|
403
434
|
};
|
|
404
435
|
requestId: string;
|
|
405
436
|
};
|
|
406
437
|
outputFormat: "json";
|
|
407
|
-
status:
|
|
438
|
+
status: 400;
|
|
408
439
|
input: {
|
|
409
440
|
query: {
|
|
410
441
|
destinationToken?: string | string[];
|
|
@@ -418,14 +449,14 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
418
449
|
} | {
|
|
419
450
|
output: {
|
|
420
451
|
error: {
|
|
421
|
-
code: "
|
|
452
|
+
code: "api_key_invalid" | "api_key_missing";
|
|
422
453
|
details?: readonly Response.error.Detail[] | undefined;
|
|
423
454
|
message: string;
|
|
424
455
|
};
|
|
425
456
|
requestId: string;
|
|
426
457
|
};
|
|
427
458
|
outputFormat: "json";
|
|
428
|
-
status:
|
|
459
|
+
status: 401;
|
|
429
460
|
input: {
|
|
430
461
|
query: {
|
|
431
462
|
destinationToken?: string | string[];
|
|
@@ -439,14 +470,14 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
439
470
|
} | {
|
|
440
471
|
output: {
|
|
441
472
|
error: {
|
|
442
|
-
code: "
|
|
473
|
+
code: "api_key_forbidden";
|
|
443
474
|
details?: readonly Response.error.Detail[] | undefined;
|
|
444
475
|
message: string;
|
|
445
476
|
};
|
|
446
477
|
requestId: string;
|
|
447
478
|
};
|
|
448
479
|
outputFormat: "json";
|
|
449
|
-
status:
|
|
480
|
+
status: 403;
|
|
450
481
|
input: {
|
|
451
482
|
query: {
|
|
452
483
|
destinationToken?: string | string[];
|
|
@@ -460,14 +491,14 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
460
491
|
} | {
|
|
461
492
|
output: {
|
|
462
493
|
error: {
|
|
463
|
-
code: "
|
|
494
|
+
code: "payment_required" | "rate_limit_exceeded";
|
|
464
495
|
details?: readonly Response.error.Detail[] | undefined;
|
|
465
496
|
message: string;
|
|
466
497
|
};
|
|
467
498
|
requestId: string;
|
|
468
499
|
};
|
|
469
500
|
outputFormat: "json";
|
|
470
|
-
status:
|
|
501
|
+
status: 429;
|
|
471
502
|
input: {
|
|
472
503
|
query: {
|
|
473
504
|
destinationToken?: string | string[];
|
|
@@ -481,14 +512,14 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
481
512
|
} | {
|
|
482
513
|
output: {
|
|
483
514
|
error: {
|
|
484
|
-
code: "
|
|
515
|
+
code: "query_invalid";
|
|
485
516
|
details?: readonly Response.error.Detail[] | undefined;
|
|
486
517
|
message: string;
|
|
487
518
|
};
|
|
488
519
|
requestId: string;
|
|
489
520
|
};
|
|
490
521
|
outputFormat: "json";
|
|
491
|
-
status:
|
|
522
|
+
status: 400;
|
|
492
523
|
input: {
|
|
493
524
|
query: {
|
|
494
525
|
destinationToken?: string | string[];
|
|
@@ -502,6 +533,18 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
502
533
|
} | {
|
|
503
534
|
output: {
|
|
504
535
|
data: {
|
|
536
|
+
destinationAmount: {
|
|
537
|
+
baseUnits: string;
|
|
538
|
+
currency: string;
|
|
539
|
+
decimals: number;
|
|
540
|
+
formatted: string;
|
|
541
|
+
};
|
|
542
|
+
destinationAmountMin?: {
|
|
543
|
+
baseUnits: string;
|
|
544
|
+
currency: string;
|
|
545
|
+
decimals: number;
|
|
546
|
+
formatted: string;
|
|
547
|
+
} | undefined;
|
|
505
548
|
destinationChain: {
|
|
506
549
|
addressFormat: "base58" | "base58check" | "evm";
|
|
507
550
|
id: string;
|
|
@@ -513,6 +556,7 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
513
556
|
};
|
|
514
557
|
destinationToken: {
|
|
515
558
|
address: string;
|
|
559
|
+
currency: string;
|
|
516
560
|
decimals: number;
|
|
517
561
|
metadata: {
|
|
518
562
|
[x: string]: string;
|
|
@@ -525,7 +569,7 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
525
569
|
};
|
|
526
570
|
id: string;
|
|
527
571
|
provider: {
|
|
528
|
-
id: "across" | "relay" | "rhino" | "squid";
|
|
572
|
+
id: "across" | "relay" | "rhino" | "squid" | "symbiosis";
|
|
529
573
|
kind: string;
|
|
530
574
|
name: string;
|
|
531
575
|
requiresApiKey: boolean;
|
|
@@ -538,14 +582,12 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
538
582
|
};
|
|
539
583
|
quote: {
|
|
540
584
|
expiresAt?: string | undefined;
|
|
541
|
-
inputAmount: string;
|
|
542
|
-
minimumOutputAmount?: string | undefined;
|
|
543
|
-
outputAmount: string;
|
|
544
|
-
outputAmountFormatted: string;
|
|
545
585
|
sampledAt: string;
|
|
546
586
|
};
|
|
547
587
|
sourceAmount: {
|
|
548
|
-
|
|
588
|
+
baseUnits: string;
|
|
589
|
+
currency: string;
|
|
590
|
+
decimals: number;
|
|
549
591
|
formatted: string;
|
|
550
592
|
};
|
|
551
593
|
sourceChain: {
|
|
@@ -559,6 +601,7 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
559
601
|
};
|
|
560
602
|
sourceToken: {
|
|
561
603
|
address: string;
|
|
604
|
+
currency: string;
|
|
562
605
|
decimals: number;
|
|
563
606
|
metadata: {
|
|
564
607
|
[x: string]: string;
|
|
@@ -652,6 +695,7 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
652
695
|
} | undefined;
|
|
653
696
|
tokens: {
|
|
654
697
|
address: string;
|
|
698
|
+
currency: string;
|
|
655
699
|
decimals: number;
|
|
656
700
|
metadata: {
|
|
657
701
|
[x: string]: string;
|
|
@@ -727,7 +771,7 @@ export declare function funding(options?: funding.Options): import("hono/hono-ba
|
|
|
727
771
|
} | {
|
|
728
772
|
output: {
|
|
729
773
|
data: {
|
|
730
|
-
id: "across" | "relay" | "rhino" | "squid";
|
|
774
|
+
id: "across" | "relay" | "rhino" | "squid" | "symbiosis";
|
|
731
775
|
kind: string;
|
|
732
776
|
name: string;
|
|
733
777
|
requiresApiKey: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"funding.d.ts","sourceRoot":"","sources":["../../../../src/apps/data/routes/funding.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,UAAU,CAAA;AAE7B,OAAO,KAAK,KAAK,GAAG,MAAM,iBAAiB,CAAA;AAG3C,OAAO,KAAK,aAAa,MAAM,oCAAoC,CAAA;
|
|
1
|
+
{"version":3,"file":"funding.d.ts","sourceRoot":"","sources":["../../../../src/apps/data/routes/funding.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,UAAU,CAAA;AAE7B,OAAO,KAAK,KAAK,GAAG,MAAM,iBAAiB,CAAA;AAG3C,OAAO,KAAK,aAAa,MAAM,oCAAoC,CAAA;AAGnE,OAAO,KAAK,QAAQ,MAAM,+BAA+B,CAAA;AAKzD,oDAAoD;AACpD,yBAAiB,MAAM,CAAC;IACtB,6CAA6C;IACtC,MAAM,KAAK;;;;;;;;;;;;;;qBAiCjB,CAAA;IAED,6CAA6C;IACtC,MAAM,KAAK;;;;;;;;;;qBAmDjB,CAAA;IAED,sEAAsE;IAC/D,MAAM,WAAW;;;;;qBAGvB,CAAA;IAED,oDAAoD;IAC7C,MAAM,WAAW;;;;;;;;;;;qBAsBvB,CAAA;IAED,+EAA+E;IACxE,MAAM,OAAO;;;;;;;;qBA4BnB,CAAA;IAED,qCAAqC;IAC9B,MAAM,YAAY;;;qBAgBxB,CAAA;IAED,qCAAqC;IAC9B,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBA0BxB,CAAA;IAED,4CAA4C;IACrC,MAAM,QAAQ;;;;;;;;;;;;;;;qBA2BpB,CAAA;IAED,qEAAqE;IAC9D,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;qBAK1B,CAAA;IAED,8CAA8C;IAC9C,UAAiB,YAAY,CAAC;QAC5B,gDAAgD;QACzC,MAAM,KAAK;;;;;;;;;;;;;;;;0BAoD0D,CAAA;QAE5E,uDAAuD;QAChD,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;yBAKpB,CAAA;KACF;IAED,mDAAmD;IACnD,UAAiB,iBAAiB,CAAC;QACjC,4CAA4C;QACrC,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;yBAOpB,CAAA;KACF;IAED,+CAA+C;IAC/C,UAAiB,aAAa,CAAC;QAC7B,oDAAoD;QAC7C,MAAM,QAAQ;;;;;;;;;;;;;;;;;yBAKpB,CAAA;KACF;CACF;AA4DD,2EAA2E;AAC3E,wBAAgB,OAAO,CAAC,OAAO,GAAE,OAAO,CAAC,OAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iCAiJpD;AAED,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,uCAAuC;IACvC,KAAK,OAAO,GAAG;QACb,qDAAqD;QACrD,QAAQ,CAAC,EAAE,aAAa,CAAC,gBAAgB,GAAG,SAAS,CAAA;QACrD,kDAAkD;QAClD,gBAAgB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;KACtC,CAAA;CACF"}
|
|
@@ -6,6 +6,7 @@ import * as FundingQuotes from '../../../internal/FundingQuotes.js';
|
|
|
6
6
|
import * as OpenApi from '../../../internal/OpenApi.js';
|
|
7
7
|
import * as Response from '../../../internal/Response.js';
|
|
8
8
|
import * as Schema from '../../../internal/Schema.js';
|
|
9
|
+
import * as Value from '../../../internal/Value.js';
|
|
9
10
|
import * as FundingQuoteProviders from '../FundingQuoteProviders.js';
|
|
10
11
|
/** Zod schemas owned by funding quote resources. */
|
|
11
12
|
export var schema;
|
|
@@ -33,6 +34,9 @@ export var schema;
|
|
|
33
34
|
address: z
|
|
34
35
|
.string()
|
|
35
36
|
.check(z.describe('Contract address, mint, or issuer address on the token chain.'), z.meta({ examples: ['0x833589fcd6edb6e08f4c7c32d4f71b54bda02913'] })),
|
|
37
|
+
currency: z
|
|
38
|
+
.string()
|
|
39
|
+
.check(z.describe('Monetary denomination represented by this token.'), z.meta({ examples: ['USD'] })),
|
|
36
40
|
decimals: z
|
|
37
41
|
.number()
|
|
38
42
|
.check(z.int(), z.gte(0), z.describe('Number of decimal places this token uses.'), z.meta({ examples: [6] })),
|
|
@@ -55,17 +59,12 @@ export var schema;
|
|
|
55
59
|
.boolean()
|
|
56
60
|
.check(z.describe('Whether Tempo recognizes this token in its funding quote inventory.'), z.meta({ examples: [true] })),
|
|
57
61
|
}), 'A normalized token reference for funding quotes.');
|
|
58
|
-
/**
|
|
59
|
-
schema.TokenAmount = Schema.describe(
|
|
60
|
-
amount: Schema.DecimalString.check(z.describe("The requested source amount in the token's smallest unit.")),
|
|
61
|
-
formatted: z
|
|
62
|
-
.string()
|
|
63
|
-
.check(z.describe('The same amount in human-readable decimal form, using the source token’s `decimals`.'), z.meta({ examples: ['1'] })),
|
|
64
|
-
}), 'The requested source amount in provider-safe base units and display form.');
|
|
62
|
+
/** Self-contained source or destination amount in a funding quote. */
|
|
63
|
+
schema.TokenAmount = Schema.describe(Schema.TokenAmount, 'A funding amount in base units and human-readable form.');
|
|
65
64
|
/** Provider summary embedded in a funding quote. */
|
|
66
65
|
schema.ProviderRef = Schema.describe(z.object({
|
|
67
66
|
id: z
|
|
68
|
-
.enum(['across', 'relay', 'rhino', 'squid'])
|
|
67
|
+
.enum(['across', 'relay', 'rhino', 'squid', 'symbiosis'])
|
|
69
68
|
.check(z.describe('Stable provider id.'), z.meta({ examples: ['relay'] })),
|
|
70
69
|
kind: z
|
|
71
70
|
.string()
|
|
@@ -92,28 +91,21 @@ export var schema;
|
|
|
92
91
|
.enum(['liquid', 'thin'])
|
|
93
92
|
.check(z.describe('Machine-readable quality tier for a successful quote.'), z.meta({ examples: ['liquid'] })),
|
|
94
93
|
}), 'Machine-readable liquidity, fee, and source signals for a successful quote.');
|
|
95
|
-
/** Provider
|
|
94
|
+
/** Provider quote freshness data. */
|
|
96
95
|
schema.QuoteDetails = Schema.describe(z.object({
|
|
97
96
|
expiresAt: z
|
|
98
97
|
.optional(z.iso.datetime())
|
|
99
98
|
.check(z.describe('Timestamp after which the provider quote is no longer valid.'), z.meta({ examples: ['2026-01-01T00:01:00Z'] })),
|
|
100
|
-
inputAmount: Schema.DecimalString.check(z.describe('Source amount sent to the provider in base units.'), z.meta({ examples: ['1000000'] })),
|
|
101
|
-
minimumOutputAmount: z
|
|
102
|
-
.optional(Schema.DecimalString)
|
|
103
|
-
.check(z.describe('Slippage-adjusted minimum destination amount in base units.'), z.meta({ examples: ['988000'] })),
|
|
104
|
-
outputAmount: z
|
|
105
|
-
.string()
|
|
106
|
-
.check(z.regex(/^\d+$/))
|
|
107
|
-
.check(z.describe('Expected destination amount in base units.'), z.meta({ examples: ['989102'] })),
|
|
108
|
-
outputAmountFormatted: z
|
|
109
|
-
.string()
|
|
110
|
-
.check(z.describe('Expected destination amount rendered with destination token decimals.'), z.meta({ examples: ['0.989102'] })),
|
|
111
99
|
sampledAt: z.iso
|
|
112
100
|
.datetime()
|
|
113
101
|
.check(z.describe('Timestamp for the live quote probe.'), z.meta({ examples: ['2026-01-01T00:00:00Z'] })),
|
|
114
|
-
}), '
|
|
102
|
+
}), 'Freshness data for a provider funding quote.');
|
|
115
103
|
/** Successful live funding quote. */
|
|
116
104
|
schema.FundingQuote = Schema.describe(z.object({
|
|
105
|
+
destinationAmount: schema.TokenAmount.check(z.describe('Expected destination amount.')),
|
|
106
|
+
destinationAmountMin: z
|
|
107
|
+
.optional(schema.TokenAmount)
|
|
108
|
+
.check(z.describe('Provider-derived minimum destination amount. Symbiosis and Squid quotes use a fixed 1% slippage tolerance.')),
|
|
117
109
|
destinationChain: schema.Chain.check(z.describe('Destination chain, always Tempo mainnet in V1.')),
|
|
118
110
|
destinationToken: schema.Token.check(z.describe('Tempo token expected from this quote.')),
|
|
119
111
|
id: z
|
|
@@ -129,7 +121,7 @@ export var schema;
|
|
|
129
121
|
/** Funding quote provider catalog entry. */
|
|
130
122
|
schema.Provider = Schema.describe(z.object({
|
|
131
123
|
id: z
|
|
132
|
-
.enum(['across', 'relay', 'rhino', 'squid'])
|
|
124
|
+
.enum(['across', 'relay', 'rhino', 'squid', 'symbiosis'])
|
|
133
125
|
.check(z.describe('Stable provider id.'), z.meta({ examples: ['relay'] })),
|
|
134
126
|
kind: z
|
|
135
127
|
.string()
|
|
@@ -158,8 +150,8 @@ export var schema;
|
|
|
158
150
|
.optional(z.string())
|
|
159
151
|
.check(z.describe('Tempo destination token symbol, address, or token key. Defaults to USDC.e.'), z.meta({ examples: ['USDC.e'] })),
|
|
160
152
|
provider: z
|
|
161
|
-
.optional(z.enum(['across', 'relay', 'rhino', 'squid']))
|
|
162
|
-
.check(z.describe('Only request a quote from this provider. Supported ids are `across`, `relay`, `rhino`, and `
|
|
153
|
+
.optional(z.enum(['across', 'relay', 'rhino', 'squid', 'symbiosis']))
|
|
154
|
+
.check(z.describe('Only request a quote from this provider. Supported ids are `across`, `relay`, `rhino`, `squid`, and `symbiosis`; omit it to query every configured provider.'), z.meta({ examples: ['relay'] })),
|
|
163
155
|
sourceAmount: z
|
|
164
156
|
.string()
|
|
165
157
|
.check(z.regex(/^(?=.*[1-9])\d+(\.\d+)?$/), z.describe('Positive source token amount. Base units by default, so 1 USDC is `1000000`.'), z.meta({ examples: ['1000000'] })),
|
|
@@ -211,7 +203,20 @@ const fundingQuoteResponseExample = (() => {
|
|
|
211
203
|
return {
|
|
212
204
|
data: [
|
|
213
205
|
{
|
|
214
|
-
|
|
206
|
+
destinationAmount: Value.tokenAmount({
|
|
207
|
+
baseUnits: '979295',
|
|
208
|
+
currency: candidate.destinationToken.currency,
|
|
209
|
+
decimals: candidate.destinationToken.decimals,
|
|
210
|
+
}),
|
|
211
|
+
destinationAmountMin: Value.tokenAmount({
|
|
212
|
+
baseUnits: '939242',
|
|
213
|
+
currency: candidate.destinationToken.currency,
|
|
214
|
+
decimals: candidate.destinationToken.decimals,
|
|
215
|
+
}),
|
|
216
|
+
destinationChain: candidate.destinationChain,
|
|
217
|
+
destinationToken: candidate.destinationToken,
|
|
218
|
+
id: candidate.id,
|
|
219
|
+
provider: candidate.provider,
|
|
215
220
|
quality: {
|
|
216
221
|
estimatedSeconds: 1,
|
|
217
222
|
liquiditySource: 'providerQuote',
|
|
@@ -219,12 +224,15 @@ const fundingQuoteResponseExample = (() => {
|
|
|
219
224
|
tier: 'liquid',
|
|
220
225
|
},
|
|
221
226
|
quote: {
|
|
222
|
-
inputAmount: '1000000',
|
|
223
|
-
minimumOutputAmount: '939242',
|
|
224
|
-
outputAmount: '979295',
|
|
225
|
-
outputAmountFormatted: '0.979295',
|
|
226
227
|
sampledAt: '2026-01-01T00:00:00.000Z',
|
|
227
228
|
},
|
|
229
|
+
sourceAmount: Value.tokenAmount({
|
|
230
|
+
baseUnits: candidate.sourceAmount.amount,
|
|
231
|
+
currency: candidate.sourceToken.currency,
|
|
232
|
+
decimals: candidate.sourceToken.decimals,
|
|
233
|
+
}),
|
|
234
|
+
sourceChain: candidate.sourceChain,
|
|
235
|
+
sourceToken: candidate.sourceToken,
|
|
228
236
|
},
|
|
229
237
|
],
|
|
230
238
|
};
|
|
@@ -245,7 +253,7 @@ export function funding(options = {}) {
|
|
|
245
253
|
code: 'query_invalid',
|
|
246
254
|
message: 'Invalid query parameters',
|
|
247
255
|
}), OpenApi.describeRoute({
|
|
248
|
-
description: 'Returns live quotes for funding Tempo with a stablecoin. Omit `provider` to query all configured providers. This endpoint does not execute a transfer.',
|
|
256
|
+
description: 'Returns live quotes for funding Tempo with a stablecoin. Omit `provider` to query all configured providers. Provider minimums can use provider-specific slippage policies; Symbiosis and Squid use 1%. This endpoint does not execute a transfer.',
|
|
249
257
|
operationId: 'quoteFunding',
|
|
250
258
|
responses: OpenApi.responses({
|
|
251
259
|
errors: {
|
|
@@ -272,6 +280,7 @@ export function funding(options = {}) {
|
|
|
272
280
|
message: 'Invalid query parameters',
|
|
273
281
|
});
|
|
274
282
|
const query = c.req.valid('query');
|
|
283
|
+
const attempts = [];
|
|
275
284
|
try {
|
|
276
285
|
c.header('Cache-Control', 'no-store');
|
|
277
286
|
return c.json(Response.validated(schema.quoteFunding.Response, {
|
|
@@ -280,6 +289,7 @@ export function funding(options = {}) {
|
|
|
280
289
|
adapterTimeoutMs: options.adapterTimeoutMs,
|
|
281
290
|
cache: { bypass: cacheBypass(c.req.raw) },
|
|
282
291
|
destinationToken: query.destinationToken,
|
|
292
|
+
onAttempt: (attempt) => attempts.push(attempt),
|
|
283
293
|
provider: query.provider,
|
|
284
294
|
sourceAmount: query.sourceAmount,
|
|
285
295
|
sourceAmountUnits: query.sourceAmountUnits,
|
|
@@ -307,6 +317,10 @@ export function funding(options = {}) {
|
|
|
307
317
|
}
|
|
308
318
|
throw cause;
|
|
309
319
|
}
|
|
320
|
+
finally {
|
|
321
|
+
if (attempts.length > 0)
|
|
322
|
+
c.set('fundingProviderAttempts', attempts.map(fundingProviderAttempt));
|
|
323
|
+
}
|
|
310
324
|
})
|
|
311
325
|
.get('/v1/funding/chains', Auth.policy({ apiKey: { scopes: ['data:read'] }, mpp: true, public: true }), OpenApi.describeRoute({
|
|
312
326
|
description: 'Lists the source chains and stablecoins you can use when requesting a funding quote.',
|
|
@@ -322,7 +336,7 @@ export function funding(options = {}) {
|
|
|
322
336
|
tags: ['Funding'],
|
|
323
337
|
}), Cache.response({
|
|
324
338
|
cacheControl: Cache.policies.stable,
|
|
325
|
-
name: 'tempo-api:funding-chains:
|
|
339
|
+
name: 'tempo-api:funding-chains:v2',
|
|
326
340
|
key: (c) => c.req.url,
|
|
327
341
|
}), (c) => {
|
|
328
342
|
if (Auth.narrowAccess)
|
|
@@ -355,6 +369,26 @@ export function funding(options = {}) {
|
|
|
355
369
|
}), 200);
|
|
356
370
|
});
|
|
357
371
|
}
|
|
372
|
+
function fundingProviderAttempt(attempt) {
|
|
373
|
+
const operation = FundingQuoteProviders.providerOperation(attempt.provider);
|
|
374
|
+
if (attempt.outcome !== 'failed')
|
|
375
|
+
return {
|
|
376
|
+
durationMs: attempt.durationMs,
|
|
377
|
+
id: attempt.provider,
|
|
378
|
+
operation,
|
|
379
|
+
outcome: attempt.outcome,
|
|
380
|
+
};
|
|
381
|
+
return {
|
|
382
|
+
durationMs: attempt.durationMs,
|
|
383
|
+
failure: FundingQuoteProviders.providerFailure({
|
|
384
|
+
cause: attempt.cause,
|
|
385
|
+
provider: attempt.provider,
|
|
386
|
+
}).failure,
|
|
387
|
+
id: attempt.provider,
|
|
388
|
+
operation,
|
|
389
|
+
outcome: attempt.outcome,
|
|
390
|
+
};
|
|
391
|
+
}
|
|
358
392
|
// Maps caller-input errors to a specific 400 message; anything else rethrows.
|
|
359
393
|
function requestErrorMessage(cause) {
|
|
360
394
|
if (cause instanceof FundingQuotes.InvalidAmountError)
|