tapimo 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/dist/App.d.ts +31 -9
- package/dist/App.d.ts.map +1 -1
- package/dist/App.js +3 -3
- package/dist/App.js.map +1 -1
- package/dist/admin/App.d.ts +116 -116
- package/dist/apps/data/App.d.ts +30 -5
- package/dist/apps/data/App.d.ts.map +1 -1
- package/dist/apps/data/App.js +1 -1
- package/dist/apps/data/App.js.map +1 -1
- package/dist/apps/data/FundingRouteProviders.d.ts +54 -0
- package/dist/apps/data/FundingRouteProviders.d.ts.map +1 -0
- package/dist/apps/data/FundingRouteProviders.js +355 -0
- package/dist/apps/data/FundingRouteProviders.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/funding.d.ts +79 -1
- package/dist/apps/data/routes/funding.d.ts.map +1 -1
- package/dist/apps/data/routes/funding.js +68 -8
- package/dist/apps/data/routes/funding.js.map +1 -1
- package/dist/apps/data/routes/indexer.d.ts +5 -5
- package/dist/apps/docs/App.d.ts +1 -1
- package/dist/apps/docs/App.js +1 -1
- package/dist/apps/index.d.ts +2 -2
- package/dist/apps/index.d.ts.map +1 -1
- package/dist/apps/index.js +2 -2
- package/dist/apps/index.js.map +1 -1
- package/dist/apps/{platform → management}/App.d.ts +11 -11
- package/dist/apps/{platform → management}/App.d.ts.map +1 -1
- package/dist/apps/{platform → management}/App.js +7 -7
- package/dist/apps/management/App.js.map +1 -0
- package/dist/apps/management/Billing.d.ts.map +1 -0
- package/dist/apps/management/Billing.js.map +1 -0
- package/dist/apps/management/index.d.ts +3 -0
- package/dist/apps/management/index.d.ts.map +1 -0
- package/dist/apps/management/index.js +3 -0
- package/dist/apps/management/index.js.map +1 -0
- package/dist/apps/management/routes/api-keys.d.ts.map +1 -0
- package/dist/apps/{platform → management}/routes/api-keys.js +1 -1
- package/dist/apps/management/routes/api-keys.js.map +1 -0
- package/dist/apps/{platform → management}/routes/billing.d.ts.map +1 -1
- package/dist/apps/management/routes/billing.js.map +1 -0
- package/dist/apps/{platform → management}/routes/invitations.d.ts +1 -1
- package/dist/apps/management/routes/invitations.d.ts.map +1 -0
- package/dist/apps/{platform → management}/routes/invitations.js +1 -1
- package/dist/apps/management/routes/invitations.js.map +1 -0
- package/dist/apps/management/routes/me.d.ts.map +1 -0
- package/dist/apps/management/routes/me.js.map +1 -0
- package/dist/apps/management/routes/members.d.ts.map +1 -0
- package/dist/apps/management/routes/members.js.map +1 -0
- package/dist/apps/management/routes/orgs.d.ts.map +1 -0
- package/dist/apps/management/routes/orgs.js.map +1 -0
- package/dist/apps/{platform → management}/routes/projects.d.ts.map +1 -1
- package/dist/apps/management/routes/projects.js.map +1 -0
- package/dist/apps/management/routes/scopes.d.ts.map +1 -0
- package/dist/apps/management/routes/scopes.js.map +1 -0
- package/dist/apps/management/routes/usage.d.ts.map +1 -0
- package/dist/apps/management/routes/usage.js.map +1 -0
- package/dist/apps/mcp.js +1 -1
- package/dist/apps/relay/App.js +1 -1
- package/dist/apps/relay/App.js.map +1 -1
- package/dist/internal/Auth.js +1 -1
- package/dist/internal/Auth.js.map +1 -1
- package/dist/internal/EdgeCache.js +1 -1
- package/dist/internal/EdgeCache.js.map +1 -1
- package/dist/internal/FundingRoutes.d.ts +748 -16
- package/dist/internal/FundingRoutes.d.ts.map +1 -1
- package/dist/internal/FundingRoutes.js +166 -31
- package/dist/internal/FundingRoutes.js.map +1 -1
- package/package.json +5 -5
- package/src/App.ts +10 -10
- package/src/Client.test-d.ts +4 -4
- package/src/apps/composition.test.ts +26 -13
- package/src/apps/data/App.ts +3 -1
- package/src/apps/data/FundingRouteProviders.test.ts +281 -0
- package/src/apps/data/FundingRouteProviders.ts +459 -0
- package/src/apps/data/index.ts +1 -0
- package/src/apps/data/routes/funding.test.ts +102 -2
- package/src/apps/data/routes/funding.ts +122 -8
- package/src/apps/docs/App.ts +1 -1
- package/src/apps/index.ts +2 -2
- package/src/apps/{platform → management}/App.ts +14 -14
- package/src/apps/{platform → management}/index.ts +1 -1
- package/src/apps/{platform → management}/routes/api-keys.ts +1 -1
- package/src/apps/{platform → management}/routes/invitations.ts +1 -1
- package/src/apps/mcp.test.ts +1 -1
- package/src/apps/mcp.ts +1 -1
- package/src/apps/relay/App.test.ts +1 -1
- package/src/apps/relay/App.ts +1 -1
- package/src/internal/Auth.ts +1 -1
- package/src/internal/EdgeCache.ts +1 -1
- package/src/internal/FundingRoutes.test.ts +213 -0
- package/src/internal/FundingRoutes.ts +347 -32
- package/dist/apps/platform/App.js.map +0 -1
- package/dist/apps/platform/Billing.d.ts.map +0 -1
- package/dist/apps/platform/Billing.js.map +0 -1
- package/dist/apps/platform/index.d.ts +0 -3
- package/dist/apps/platform/index.d.ts.map +0 -1
- package/dist/apps/platform/index.js +0 -3
- package/dist/apps/platform/index.js.map +0 -1
- package/dist/apps/platform/routes/api-keys.d.ts.map +0 -1
- package/dist/apps/platform/routes/api-keys.js.map +0 -1
- package/dist/apps/platform/routes/billing.js.map +0 -1
- package/dist/apps/platform/routes/invitations.d.ts.map +0 -1
- package/dist/apps/platform/routes/invitations.js.map +0 -1
- package/dist/apps/platform/routes/me.d.ts.map +0 -1
- package/dist/apps/platform/routes/me.js.map +0 -1
- package/dist/apps/platform/routes/members.d.ts.map +0 -1
- package/dist/apps/platform/routes/members.js.map +0 -1
- package/dist/apps/platform/routes/orgs.d.ts.map +0 -1
- package/dist/apps/platform/routes/orgs.js.map +0 -1
- package/dist/apps/platform/routes/projects.js.map +0 -1
- package/dist/apps/platform/routes/scopes.d.ts.map +0 -1
- package/dist/apps/platform/routes/scopes.js.map +0 -1
- package/dist/apps/platform/routes/usage.d.ts.map +0 -1
- package/dist/apps/platform/routes/usage.js.map +0 -1
- /package/dist/apps/{platform → management}/Billing.d.ts +0 -0
- /package/dist/apps/{platform → management}/Billing.js +0 -0
- /package/dist/apps/{platform → management}/routes/api-keys.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/billing.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/billing.js +0 -0
- /package/dist/apps/{platform → management}/routes/me.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/me.js +0 -0
- /package/dist/apps/{platform → management}/routes/members.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/members.js +0 -0
- /package/dist/apps/{platform → management}/routes/orgs.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/orgs.js +0 -0
- /package/dist/apps/{platform → management}/routes/projects.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/projects.js +0 -0
- /package/dist/apps/{platform → management}/routes/scopes.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/scopes.js +0 -0
- /package/dist/apps/{platform → management}/routes/usage.d.ts +0 -0
- /package/dist/apps/{platform → management}/routes/usage.js +0 -0
- /package/src/apps/{platform → management}/Billing.test.ts +0 -0
- /package/src/apps/{platform → management}/Billing.ts +0 -0
- /package/src/apps/{platform → management}/routes/api-keys.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/billing.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/billing.ts +0 -0
- /package/src/apps/{platform → management}/routes/invitations.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/me.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/me.ts +0 -0
- /package/src/apps/{platform → management}/routes/members.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/members.ts +0 -0
- /package/src/apps/{platform → management}/routes/orgs.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/orgs.ts +0 -0
- /package/src/apps/{platform → management}/routes/projects.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/projects.ts +0 -0
- /package/src/apps/{platform → management}/routes/scopes.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/scopes.ts +0 -0
- /package/src/apps/{platform → management}/routes/usage.test.ts +0 -0
- /package/src/apps/{platform → management}/routes/usage.ts +0 -0
|
@@ -1,3 +1,366 @@
|
|
|
1
|
+
/** Tempo mainnet as a CAIP-2 chain reference. */
|
|
2
|
+
declare const destinationChain: {
|
|
3
|
+
readonly addressFormat: 'evm';
|
|
4
|
+
readonly id: 'eip155:4217';
|
|
5
|
+
readonly kind: 'evm';
|
|
6
|
+
readonly name: 'Tempo';
|
|
7
|
+
};
|
|
8
|
+
/** Source chains accepted by the funding route inventory. */
|
|
9
|
+
declare const sourceChains: readonly [{
|
|
10
|
+
readonly addressFormat: 'evm';
|
|
11
|
+
readonly aliases: readonly ['ethereum', 'eth', 'eip155:1'];
|
|
12
|
+
readonly id: 'eip155:1';
|
|
13
|
+
readonly kind: 'evm';
|
|
14
|
+
readonly name: 'Ethereum';
|
|
15
|
+
readonly providerIds: {
|
|
16
|
+
readonly across: '1';
|
|
17
|
+
readonly bridge: 'ethereum';
|
|
18
|
+
readonly bungee: '1';
|
|
19
|
+
readonly lifi: '1';
|
|
20
|
+
readonly relay: '1';
|
|
21
|
+
};
|
|
22
|
+
readonly slug: 'ethereum';
|
|
23
|
+
readonly tokens: readonly [{
|
|
24
|
+
readonly address: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48';
|
|
25
|
+
readonly coingeckoId: 'usd-coin';
|
|
26
|
+
readonly decimals: 6;
|
|
27
|
+
readonly name: 'USD Coin';
|
|
28
|
+
readonly standard: 'ERC-20';
|
|
29
|
+
readonly symbol: 'USDC';
|
|
30
|
+
}, {
|
|
31
|
+
readonly address: '0xdac17f958d2ee523a2206206994597c13d831ec7';
|
|
32
|
+
readonly coingeckoId: 'tether';
|
|
33
|
+
readonly decimals: 6;
|
|
34
|
+
readonly name: 'Tether USD';
|
|
35
|
+
readonly standard: 'ERC-20';
|
|
36
|
+
readonly symbol: 'USDT';
|
|
37
|
+
}, {
|
|
38
|
+
readonly address: '0x6c3ea9036406852006290770bedfcaba0e23a0e8';
|
|
39
|
+
readonly coingeckoId: 'paypal-usd';
|
|
40
|
+
readonly decimals: 6;
|
|
41
|
+
readonly name: 'PayPal USD';
|
|
42
|
+
readonly standard: 'ERC-20';
|
|
43
|
+
readonly symbol: 'PYUSD';
|
|
44
|
+
}, {
|
|
45
|
+
readonly address: '0x1abaea1f7c830bd89acc67ec4af516284b1bc33c';
|
|
46
|
+
readonly coingeckoId: 'euro-coin';
|
|
47
|
+
readonly decimals: 6;
|
|
48
|
+
readonly name: 'Euro Coin';
|
|
49
|
+
readonly standard: 'ERC-20';
|
|
50
|
+
readonly symbol: 'EURC';
|
|
51
|
+
}, {
|
|
52
|
+
readonly address: '0x6b175474e89094c44da98b954eedeac495271d0f';
|
|
53
|
+
readonly coingeckoId: 'dai';
|
|
54
|
+
readonly decimals: 18;
|
|
55
|
+
readonly name: 'Dai Stablecoin';
|
|
56
|
+
readonly standard: 'ERC-20';
|
|
57
|
+
readonly symbol: 'DAI';
|
|
58
|
+
}];
|
|
59
|
+
}, {
|
|
60
|
+
readonly addressFormat: 'evm';
|
|
61
|
+
readonly aliases: readonly ['base', 'eip155:8453'];
|
|
62
|
+
readonly id: 'eip155:8453';
|
|
63
|
+
readonly kind: 'evm';
|
|
64
|
+
readonly name: 'Base';
|
|
65
|
+
readonly providerIds: {
|
|
66
|
+
readonly across: '8453';
|
|
67
|
+
readonly bridge: 'base';
|
|
68
|
+
readonly bungee: '8453';
|
|
69
|
+
readonly lifi: '8453';
|
|
70
|
+
readonly relay: '8453';
|
|
71
|
+
};
|
|
72
|
+
readonly slug: 'base';
|
|
73
|
+
readonly tokens: readonly [{
|
|
74
|
+
readonly address: '0x833589fcd6edb6e08f4c7c32d4f71b54bda02913';
|
|
75
|
+
readonly coingeckoId: 'usd-coin';
|
|
76
|
+
readonly decimals: 6;
|
|
77
|
+
readonly name: 'USD Coin';
|
|
78
|
+
readonly standard: 'ERC-20';
|
|
79
|
+
readonly symbol: 'USDC';
|
|
80
|
+
}, {
|
|
81
|
+
readonly address: '0xfde4c96c8593536e31f229ea8f37b2ada2699bb2';
|
|
82
|
+
readonly coingeckoId: 'tether';
|
|
83
|
+
readonly decimals: 6;
|
|
84
|
+
readonly name: 'Tether USD';
|
|
85
|
+
readonly standard: 'ERC-20';
|
|
86
|
+
readonly symbol: 'USDT';
|
|
87
|
+
}, {
|
|
88
|
+
readonly address: '0x60a3e35cc302bfa44cb288bc5a4f316fdb1adb42';
|
|
89
|
+
readonly coingeckoId: 'euro-coin';
|
|
90
|
+
readonly decimals: 6;
|
|
91
|
+
readonly name: 'Euro Coin';
|
|
92
|
+
readonly standard: 'ERC-20';
|
|
93
|
+
readonly symbol: 'EURC';
|
|
94
|
+
}];
|
|
95
|
+
}, {
|
|
96
|
+
readonly addressFormat: 'evm';
|
|
97
|
+
readonly aliases: readonly ['bnb', 'bsc', 'eip155:56'];
|
|
98
|
+
readonly id: 'eip155:56';
|
|
99
|
+
readonly kind: 'evm';
|
|
100
|
+
readonly name: 'BNB Smart Chain';
|
|
101
|
+
readonly providerIds: {
|
|
102
|
+
readonly across: '56';
|
|
103
|
+
readonly bungee: '56';
|
|
104
|
+
readonly lifi: '56';
|
|
105
|
+
readonly relay: '56';
|
|
106
|
+
};
|
|
107
|
+
readonly slug: 'bnb';
|
|
108
|
+
readonly tokens: readonly [{
|
|
109
|
+
readonly address: '0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d';
|
|
110
|
+
readonly coingeckoId: 'usd-coin';
|
|
111
|
+
readonly decimals: 18;
|
|
112
|
+
readonly name: 'Binance-Peg USD Coin';
|
|
113
|
+
readonly standard: 'BEP-20';
|
|
114
|
+
readonly symbol: 'USDC';
|
|
115
|
+
}, {
|
|
116
|
+
readonly address: '0x55d398326f99059ff775485246999027b3197955';
|
|
117
|
+
readonly coingeckoId: 'tether';
|
|
118
|
+
readonly decimals: 18;
|
|
119
|
+
readonly name: 'Tether USD';
|
|
120
|
+
readonly standard: 'BEP-20';
|
|
121
|
+
readonly symbol: 'USDT';
|
|
122
|
+
}];
|
|
123
|
+
}, {
|
|
124
|
+
readonly addressFormat: 'solana';
|
|
125
|
+
readonly aliases: readonly ['solana', 'solana:mainnet'];
|
|
126
|
+
readonly id: 'solana:mainnet';
|
|
127
|
+
readonly kind: 'solana';
|
|
128
|
+
readonly name: 'Solana';
|
|
129
|
+
readonly providerIds: {
|
|
130
|
+
readonly bridge: 'solana';
|
|
131
|
+
readonly relay: 'solana';
|
|
132
|
+
};
|
|
133
|
+
readonly slug: 'solana';
|
|
134
|
+
readonly tokens: readonly [{
|
|
135
|
+
readonly address: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v';
|
|
136
|
+
readonly coingeckoId: 'usd-coin';
|
|
137
|
+
readonly decimals: 6;
|
|
138
|
+
readonly name: 'USD Coin';
|
|
139
|
+
readonly standard: 'SPL';
|
|
140
|
+
readonly symbol: 'USDC';
|
|
141
|
+
}, {
|
|
142
|
+
readonly address: 'Es9vMFrzaCERmJfrF4H2FYD4KCo3LwC1uix9YEaQ8t1v';
|
|
143
|
+
readonly coingeckoId: 'tether';
|
|
144
|
+
readonly decimals: 6;
|
|
145
|
+
readonly name: 'Tether USD';
|
|
146
|
+
readonly standard: 'SPL';
|
|
147
|
+
readonly symbol: 'USDT';
|
|
148
|
+
}];
|
|
149
|
+
}, {
|
|
150
|
+
readonly addressFormat: 'tron';
|
|
151
|
+
readonly aliases: readonly ['tron', 'tron:mainnet'];
|
|
152
|
+
readonly id: 'tron:mainnet';
|
|
153
|
+
readonly kind: 'tron';
|
|
154
|
+
readonly name: 'Tron';
|
|
155
|
+
readonly providerIds: {
|
|
156
|
+
readonly bridge: 'tron';
|
|
157
|
+
readonly relay: 'tron';
|
|
158
|
+
};
|
|
159
|
+
readonly slug: 'tron';
|
|
160
|
+
readonly tokens: readonly [{
|
|
161
|
+
readonly address: 'TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t';
|
|
162
|
+
readonly coingeckoId: 'tether';
|
|
163
|
+
readonly decimals: 6;
|
|
164
|
+
readonly name: 'Tether USD';
|
|
165
|
+
readonly standard: 'TRC-20';
|
|
166
|
+
readonly symbol: 'USDT';
|
|
167
|
+
}];
|
|
168
|
+
}];
|
|
169
|
+
/** Tempo destination tokens supported by the initial funding route inventory. */
|
|
170
|
+
declare const destinationTokens: readonly [{
|
|
171
|
+
readonly address: '0x20c0000000000000000000000000000000000000';
|
|
172
|
+
readonly decimals: 6;
|
|
173
|
+
readonly name: 'pathUSD';
|
|
174
|
+
readonly slug: 'pathusd';
|
|
175
|
+
readonly standard: 'TIP-20';
|
|
176
|
+
readonly symbol: 'pathUSD';
|
|
177
|
+
}, {
|
|
178
|
+
readonly address: '0x20c000000000000000000000b9537d11c60e8b50';
|
|
179
|
+
readonly decimals: 6;
|
|
180
|
+
readonly name: 'Bridged USDC (Stargate)';
|
|
181
|
+
readonly slug: 'usdce';
|
|
182
|
+
readonly standard: 'TIP-20';
|
|
183
|
+
readonly symbol: 'USDC.e';
|
|
184
|
+
}, {
|
|
185
|
+
readonly address: '0x20c0000000000000000000001621e21f71cf12fb';
|
|
186
|
+
readonly decimals: 6;
|
|
187
|
+
readonly name: 'Bridged EURC';
|
|
188
|
+
readonly slug: 'eurce';
|
|
189
|
+
readonly standard: 'TIP-20';
|
|
190
|
+
readonly symbol: 'EURC.e';
|
|
191
|
+
}, {
|
|
192
|
+
readonly address: '0x20c00000000000000000000014f22ca97301eb73';
|
|
193
|
+
readonly decimals: 6;
|
|
194
|
+
readonly name: 'USDT0';
|
|
195
|
+
readonly slug: 'usdt0';
|
|
196
|
+
readonly standard: 'TIP-20';
|
|
197
|
+
readonly symbol: 'USDT0';
|
|
198
|
+
}, {
|
|
199
|
+
readonly address: '0x20c0000000000000000000003554d28269e0f3c2';
|
|
200
|
+
readonly decimals: 6;
|
|
201
|
+
readonly name: 'frxUSD';
|
|
202
|
+
readonly slug: 'frxusd';
|
|
203
|
+
readonly standard: 'TIP-20';
|
|
204
|
+
readonly symbol: 'frxUSD';
|
|
205
|
+
}];
|
|
206
|
+
/** Providers exposed by the generic provider catalog. */
|
|
207
|
+
declare const providers: readonly [{
|
|
208
|
+
readonly capabilities: readonly ['fundingRoutes'];
|
|
209
|
+
readonly id: 'across';
|
|
210
|
+
readonly kind: 'intentBridge';
|
|
211
|
+
readonly name: 'Across';
|
|
212
|
+
readonly requiresApiKey: true;
|
|
213
|
+
readonly status: 'inventoryOnly';
|
|
214
|
+
}, {
|
|
215
|
+
readonly capabilities: readonly ['fundingRoutes'];
|
|
216
|
+
readonly id: 'relay';
|
|
217
|
+
readonly kind: 'solverNetwork';
|
|
218
|
+
readonly name: 'Relay';
|
|
219
|
+
readonly requiresApiKey: false;
|
|
220
|
+
readonly status: 'inventoryOnly';
|
|
221
|
+
}, {
|
|
222
|
+
readonly capabilities: readonly ['fundingRoutes'];
|
|
223
|
+
readonly id: 'bridge';
|
|
224
|
+
readonly kind: 'enterpriseTransfer';
|
|
225
|
+
readonly name: 'Bridge.xyz';
|
|
226
|
+
readonly requiresApiKey: true;
|
|
227
|
+
readonly status: 'inventoryOnly';
|
|
228
|
+
}, {
|
|
229
|
+
readonly capabilities: readonly ['fundingRoutes'];
|
|
230
|
+
readonly id: 'bungee';
|
|
231
|
+
readonly kind: 'aggregator';
|
|
232
|
+
readonly name: 'Bungee';
|
|
233
|
+
readonly requiresApiKey: false;
|
|
234
|
+
readonly status: 'inventoryOnly';
|
|
235
|
+
}, {
|
|
236
|
+
readonly capabilities: readonly ['fundingRoutes'];
|
|
237
|
+
readonly id: 'lifi';
|
|
238
|
+
readonly kind: 'aggregator';
|
|
239
|
+
readonly name: 'LI.FI';
|
|
240
|
+
readonly requiresApiKey: true;
|
|
241
|
+
readonly status: 'planned';
|
|
242
|
+
}];
|
|
243
|
+
type TokenInput = (typeof sourceChains)[number]['tokens'][number];
|
|
244
|
+
type DestinationTokenInput = (typeof destinationTokens)[number];
|
|
245
|
+
type ProviderInput = (typeof providers)[number];
|
|
246
|
+
type SourceChainInput = (typeof sourceChains)[number];
|
|
247
|
+
/** Provider ids accepted by the funding route inventory. */
|
|
248
|
+
export type ProviderId = ProviderInput['id'];
|
|
249
|
+
/** Provider-specific route status for the requested amount. */
|
|
250
|
+
export type RouteStatus = 'available' | 'thin' | 'unknown' | 'unavailable' | 'error';
|
|
251
|
+
/** Machine-readable route quality tier. */
|
|
252
|
+
export type QualityTier = 'liquid' | 'thin' | 'unknown' | 'unavailable' | 'error';
|
|
253
|
+
/** Response expansions accepted by funding route discovery. */
|
|
254
|
+
export type Include = 'quotes';
|
|
255
|
+
/** Normalized chain reference passed to provider adapters. */
|
|
256
|
+
export type ChainRef = ReturnType<typeof formatChain> | typeof destinationChain;
|
|
257
|
+
/** Normalized token amount passed to provider adapters. */
|
|
258
|
+
export type TokenAmount = ReturnType<typeof resolveSourceAmount>;
|
|
259
|
+
/** Normalized token reference passed to provider adapters. */
|
|
260
|
+
export type TokenRef = ReturnType<typeof formatDestinationToken> | ReturnType<typeof formatSourceToken>;
|
|
261
|
+
/** A normalized funding route candidate returned by route discovery. */
|
|
262
|
+
export type RouteCandidate = ReturnType<typeof formatRouteCandidate>;
|
|
263
|
+
/** Cache policy for a single funding route discovery request. */
|
|
264
|
+
export type CachePolicy = {
|
|
265
|
+
/** Whether provider adapters should bypass their own quote or inventory caches. */
|
|
266
|
+
bypass: boolean;
|
|
267
|
+
};
|
|
268
|
+
/** Normalized caller request passed to provider adapters. */
|
|
269
|
+
export type QuoteRequest = {
|
|
270
|
+
/** Optional Tempo destination token symbol, address, or token key. */
|
|
271
|
+
destinationToken?: string | undefined;
|
|
272
|
+
/** Response expansions requested by the caller. */
|
|
273
|
+
include: readonly Include[];
|
|
274
|
+
/** Maximum number of route candidates requested by the caller. */
|
|
275
|
+
limit: number;
|
|
276
|
+
/** Optional provider id filter. */
|
|
277
|
+
provider?: string | undefined;
|
|
278
|
+
/** Source amount as supplied by the caller. */
|
|
279
|
+
sourceAmount: string;
|
|
280
|
+
/** Unit used by {@link sourceAmount}. */
|
|
281
|
+
sourceAmountUnits: SourceAmountUnits;
|
|
282
|
+
/** Chain alias or CAIP-2 source chain id. */
|
|
283
|
+
sourceChain: string;
|
|
284
|
+
/** Source token symbol, contract address, mint, or Tempo token key. */
|
|
285
|
+
sourceToken: string;
|
|
286
|
+
};
|
|
287
|
+
/** Input passed to a provider adapter for one static route candidate probe. */
|
|
288
|
+
export type QuoteProbeInput = {
|
|
289
|
+
/** Cache policy for provider-side inventory, quote, and liquidity lookups. */
|
|
290
|
+
cache: CachePolicy;
|
|
291
|
+
/** Destination chain, always Tempo mainnet in V1. */
|
|
292
|
+
destinationChain: ChainRef;
|
|
293
|
+
/** Tempo token expected from this route. */
|
|
294
|
+
destinationToken: TokenRef;
|
|
295
|
+
/** Response expansions requested by the caller. */
|
|
296
|
+
include: readonly Include[];
|
|
297
|
+
/** Normalized caller request that produced this route candidate. */
|
|
298
|
+
request: QuoteRequest;
|
|
299
|
+
/** Static candidate being enriched with live provider information. */
|
|
300
|
+
route: RouteCandidate;
|
|
301
|
+
/** Source amount in base units and display form. */
|
|
302
|
+
sourceAmount: TokenAmount;
|
|
303
|
+
/** Chain where the caller currently holds funds. */
|
|
304
|
+
sourceChain: ChainRef;
|
|
305
|
+
/** Token the caller currently holds. */
|
|
306
|
+
sourceToken: TokenRef;
|
|
307
|
+
};
|
|
308
|
+
/** Provider-specific source amount limits, expressed in source base units. */
|
|
309
|
+
export type QuoteProbeLimits = {
|
|
310
|
+
/** Provider-reported instant source amount capacity. */
|
|
311
|
+
instantSourceAmount?: string | null | undefined;
|
|
312
|
+
/** Provider-reported maximum source amount. */
|
|
313
|
+
maxSourceAmount?: string | null | undefined;
|
|
314
|
+
/** Provider-reported minimum source amount. */
|
|
315
|
+
minSourceAmount?: string | null | undefined;
|
|
316
|
+
};
|
|
317
|
+
/** Quote probe data returned by a provider adapter. */
|
|
318
|
+
export type QuoteProbeResult = {
|
|
319
|
+
/** Stable route error code when status is `error`. */
|
|
320
|
+
errorCode?: string | null | undefined;
|
|
321
|
+
/** Provider quote expiry timestamp. */
|
|
322
|
+
expiresAt?: string | null | undefined;
|
|
323
|
+
/** Provider-reported source amount limits. */
|
|
324
|
+
limits?: QuoteProbeLimits | null | undefined;
|
|
325
|
+
/** Slippage-adjusted minimum destination amount in base units. */
|
|
326
|
+
minimumOutputAmount?: string | null | undefined;
|
|
327
|
+
/** Expected destination amount in base units. */
|
|
328
|
+
outputAmount?: string | null | undefined;
|
|
329
|
+
/** Expected destination amount rendered with destination token decimals. */
|
|
330
|
+
outputAmountFormatted?: string | null | undefined;
|
|
331
|
+
/** Timestamp for the live quote or route probe. */
|
|
332
|
+
sampledAt: string;
|
|
333
|
+
/** Provider-specific route status for the requested amount. */
|
|
334
|
+
status: RouteStatus;
|
|
335
|
+
/** Provider-backed route quality metadata. */
|
|
336
|
+
quality?: {
|
|
337
|
+
/** Available USD capacity, when available. */
|
|
338
|
+
availableVolumeUsd?: string | null | undefined;
|
|
339
|
+
/** Estimated settlement time in seconds, when known. */
|
|
340
|
+
estimatedSeconds?: number | null | undefined;
|
|
341
|
+
/** Estimated fee in basis points, when known. */
|
|
342
|
+
feeBps?: number | null | undefined;
|
|
343
|
+
/** 24h routed volume in USD, when available. */
|
|
344
|
+
historicalVolumeUsd24h?: string | null | undefined;
|
|
345
|
+
/** Instant USD capacity, when available. */
|
|
346
|
+
instantVolumeUsd?: string | null | undefined;
|
|
347
|
+
/** Where the live liquidity or support signal came from. */
|
|
348
|
+
liquiditySource: string;
|
|
349
|
+
/** Explainable route score from 0 to 100, when enough signals are available. */
|
|
350
|
+
score?: number | null | undefined;
|
|
351
|
+
/** Provider-specific quote source or endpoint detail. */
|
|
352
|
+
sourceDetail?: string | null | undefined;
|
|
353
|
+
/** Machine-readable route quality tier. */
|
|
354
|
+
tier?: QualityTier | undefined;
|
|
355
|
+
};
|
|
356
|
+
};
|
|
357
|
+
/** Adapter used to enrich a static route candidate with live provider information. */
|
|
358
|
+
export type ProviderAdapter = {
|
|
359
|
+
/** Probes provider-backed quote information for one static candidate. */
|
|
360
|
+
probeQuote(input: QuoteProbeInput, signal: AbortSignal): Promise<QuoteProbeResult>;
|
|
361
|
+
};
|
|
362
|
+
/** Provider adapter registry, keyed by provider id. Missing adapters leave routes static. */
|
|
363
|
+
export type ProviderAdapters = Partial<Record<ProviderId, ProviderAdapter>>;
|
|
1
364
|
/** Lists normalized chains and source tokens that can fund Tempo. */
|
|
2
365
|
export declare function listChains(): {
|
|
3
366
|
tokens: {
|
|
@@ -43,22 +406,52 @@ export declare function listChains(): {
|
|
|
43
406
|
}[];
|
|
44
407
|
/** Lists providers, optionally filtered by one provider capability. */
|
|
45
408
|
export declare function listProviders(options?: listProviders.Options): {
|
|
409
|
+
status: "configured" | "inventoryOnly" | "planned";
|
|
46
410
|
capabilities: "fundingRoutes"[];
|
|
47
411
|
id: "across" | "bridge" | "bungee" | "lifi" | "relay";
|
|
48
412
|
kind: "aggregator" | "enterpriseTransfer" | "intentBridge" | "solverNetwork";
|
|
49
413
|
name: "Across" | "Bridge.xyz" | "Bungee" | "LI.FI" | "Relay";
|
|
50
414
|
requiresApiKey: boolean;
|
|
51
|
-
status: "inventoryOnly" | "planned";
|
|
52
415
|
}[];
|
|
53
416
|
export declare namespace listProviders {
|
|
54
417
|
/** Options for listing providers. */
|
|
55
418
|
type Options = {
|
|
419
|
+
/** Provider adapters configured for this deployment. */
|
|
420
|
+
adapters?: ProviderAdapters | undefined;
|
|
56
421
|
/** Provider capability to require. */
|
|
57
422
|
capability?: Capability | undefined;
|
|
58
423
|
};
|
|
59
424
|
}
|
|
60
|
-
/**
|
|
61
|
-
export declare function
|
|
425
|
+
/** Parses the comma-separated `include` query parameter. */
|
|
426
|
+
export declare function parseInclude(input: string | undefined): readonly "quotes"[];
|
|
427
|
+
/** Lists funding route candidates, enriching static inventory when adapters are configured. */
|
|
428
|
+
export declare function listRoutes(options: listRoutes.Options): Promise<({
|
|
429
|
+
errorCode: string | null;
|
|
430
|
+
quality: {
|
|
431
|
+
availableVolumeUsd: string | null | undefined;
|
|
432
|
+
estimatedSeconds: number | null | undefined;
|
|
433
|
+
feeBps: number | null | undefined;
|
|
434
|
+
historicalVolumeUsd24h: string | null | undefined;
|
|
435
|
+
instantVolumeUsd: string | null | undefined;
|
|
436
|
+
liquiditySource: string;
|
|
437
|
+
score: number | null | undefined;
|
|
438
|
+
sourceDetail: string | null | undefined;
|
|
439
|
+
tier: QualityTier | undefined;
|
|
440
|
+
};
|
|
441
|
+
quote: {
|
|
442
|
+
readonly expiresAt: string | null;
|
|
443
|
+
readonly inputAmount: string;
|
|
444
|
+
readonly limits: {
|
|
445
|
+
instantSourceAmount: string | null;
|
|
446
|
+
maxSourceAmount: string | null;
|
|
447
|
+
minSourceAmount: string | null;
|
|
448
|
+
} | null;
|
|
449
|
+
readonly minimumOutputAmount: string | null;
|
|
450
|
+
readonly outputAmount: string | null;
|
|
451
|
+
readonly outputAmountFormatted: string | null;
|
|
452
|
+
readonly sampledAt: string;
|
|
453
|
+
} | null;
|
|
454
|
+
status: RouteStatus;
|
|
62
455
|
destinationChain: {
|
|
63
456
|
readonly addressFormat: 'evm';
|
|
64
457
|
readonly id: 'eip155:4217';
|
|
@@ -82,16 +475,6 @@ export declare function listRoutes(options: listRoutes.Options): {
|
|
|
82
475
|
name: "Across" | "Bridge.xyz" | "Bungee" | "LI.FI" | "Relay";
|
|
83
476
|
requiresApiKey: boolean;
|
|
84
477
|
};
|
|
85
|
-
quality: {
|
|
86
|
-
availableVolumeUsd: null;
|
|
87
|
-
estimatedSeconds: null;
|
|
88
|
-
feeBps: null;
|
|
89
|
-
historicalVolumeUsd24h: null;
|
|
90
|
-
instantVolumeUsd: null;
|
|
91
|
-
liquiditySource: string;
|
|
92
|
-
score: null;
|
|
93
|
-
tier: 'unknown';
|
|
94
|
-
};
|
|
95
478
|
sourceAmount: {
|
|
96
479
|
amount: string;
|
|
97
480
|
formatted: string;
|
|
@@ -139,10 +522,181 @@ export declare function listRoutes(options: listRoutes.Options): {
|
|
|
139
522
|
tokenKey: string;
|
|
140
523
|
verified: boolean;
|
|
141
524
|
};
|
|
142
|
-
|
|
525
|
+
} | {
|
|
526
|
+
readonly destinationChain: {
|
|
527
|
+
readonly addressFormat: 'evm';
|
|
528
|
+
readonly id: 'eip155:4217';
|
|
529
|
+
readonly kind: 'evm';
|
|
530
|
+
readonly name: 'Tempo';
|
|
531
|
+
};
|
|
532
|
+
readonly destinationToken: {
|
|
533
|
+
address: "0x20c0000000000000000000000000000000000000" | "0x20c00000000000000000000014f22ca97301eb73" | "0x20c0000000000000000000001621e21f71cf12fb" | "0x20c0000000000000000000003554d28269e0f3c2" | "0x20c000000000000000000000b9537d11c60e8b50";
|
|
534
|
+
decimals: 6;
|
|
535
|
+
metadata: {};
|
|
536
|
+
name: "Bridged EURC" | "Bridged USDC (Stargate)" | "USDT0" | "frxUSD" | "pathUSD";
|
|
537
|
+
standard: "TIP-20";
|
|
538
|
+
symbol: "EURC.e" | "USDC.e" | "USDT0" | "frxUSD" | "pathUSD";
|
|
539
|
+
tokenKey: string;
|
|
540
|
+
verified: boolean;
|
|
541
|
+
};
|
|
542
|
+
readonly errorCode: null;
|
|
543
|
+
readonly id: string;
|
|
544
|
+
readonly provider: {
|
|
545
|
+
id: "across" | "bridge" | "bungee" | "lifi" | "relay";
|
|
546
|
+
kind: "aggregator" | "enterpriseTransfer" | "intentBridge" | "solverNetwork";
|
|
547
|
+
name: "Across" | "Bridge.xyz" | "Bungee" | "LI.FI" | "Relay";
|
|
548
|
+
requiresApiKey: boolean;
|
|
549
|
+
};
|
|
550
|
+
readonly quality: {
|
|
551
|
+
readonly availableVolumeUsd: null;
|
|
552
|
+
readonly estimatedSeconds: null;
|
|
553
|
+
readonly feeBps: null;
|
|
554
|
+
readonly historicalVolumeUsd24h: null;
|
|
555
|
+
readonly instantVolumeUsd: null;
|
|
556
|
+
readonly liquiditySource: 'staticInventory';
|
|
557
|
+
readonly score: null;
|
|
558
|
+
readonly sourceDetail: null;
|
|
559
|
+
readonly tier: 'unknown';
|
|
560
|
+
};
|
|
561
|
+
readonly quote: null;
|
|
562
|
+
readonly sourceAmount: {
|
|
563
|
+
amount: string;
|
|
564
|
+
formatted: string;
|
|
565
|
+
usd: null;
|
|
566
|
+
};
|
|
567
|
+
readonly sourceChain: {
|
|
568
|
+
addressFormat: "evm" | "solana" | "tron";
|
|
569
|
+
id: "eip155:1" | "eip155:56" | "eip155:8453" | "solana:mainnet" | "tron:mainnet";
|
|
570
|
+
kind: "evm" | "solana" | "tron";
|
|
571
|
+
name: "BNB Smart Chain" | "Base" | "Ethereum" | "Solana" | "Tron";
|
|
572
|
+
providerIds: {
|
|
573
|
+
readonly across: '1';
|
|
574
|
+
readonly bridge: 'ethereum';
|
|
575
|
+
readonly bungee: '1';
|
|
576
|
+
readonly lifi: '1';
|
|
577
|
+
readonly relay: '1';
|
|
578
|
+
} | {
|
|
579
|
+
readonly across: '8453';
|
|
580
|
+
readonly bridge: 'base';
|
|
581
|
+
readonly bungee: '8453';
|
|
582
|
+
readonly lifi: '8453';
|
|
583
|
+
readonly relay: '8453';
|
|
584
|
+
} | {
|
|
585
|
+
readonly across: '56';
|
|
586
|
+
readonly bungee: '56';
|
|
587
|
+
readonly lifi: '56';
|
|
588
|
+
readonly relay: '56';
|
|
589
|
+
} | {
|
|
590
|
+
readonly bridge: 'solana';
|
|
591
|
+
readonly relay: 'solana';
|
|
592
|
+
} | {
|
|
593
|
+
readonly bridge: 'tron';
|
|
594
|
+
readonly relay: 'tron';
|
|
595
|
+
};
|
|
596
|
+
};
|
|
597
|
+
readonly sourceToken: {
|
|
598
|
+
address: "0x1abaea1f7c830bd89acc67ec4af516284b1bc33c" | "0x55d398326f99059ff775485246999027b3197955" | "0x60a3e35cc302bfa44cb288bc5a4f316fdb1adb42" | "0x6b175474e89094c44da98b954eedeac495271d0f" | "0x6c3ea9036406852006290770bedfcaba0e23a0e8" | "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913" | "0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d" | "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48" | "0xdac17f958d2ee523a2206206994597c13d831ec7" | "0xfde4c96c8593536e31f229ea8f37b2ada2699bb2" | "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" | "Es9vMFrzaCERmJfrF4H2FYD4KCo3LwC1uix9YEaQ8t1v" | "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t";
|
|
599
|
+
decimals: 6 | 18;
|
|
600
|
+
metadata: {
|
|
601
|
+
coingeckoId: "dai" | "euro-coin" | "paypal-usd" | "tether" | "usd-coin";
|
|
602
|
+
};
|
|
603
|
+
name: "Binance-Peg USD Coin" | "Dai Stablecoin" | "Euro Coin" | "PayPal USD" | "Tether USD" | "USD Coin";
|
|
604
|
+
standard: "BEP-20" | "ERC-20" | "SPL" | "TRC-20";
|
|
605
|
+
symbol: "DAI" | "EURC" | "PYUSD" | "USDC" | "USDT";
|
|
606
|
+
tokenKey: string;
|
|
607
|
+
verified: boolean;
|
|
608
|
+
};
|
|
609
|
+
readonly status: 'unknown';
|
|
610
|
+
})[]>;
|
|
611
|
+
/** Lists static funding route candidates for a normalized caller request. */
|
|
612
|
+
export declare function listStaticRoutes(options: listStaticRoutes.Options): {
|
|
613
|
+
readonly destinationChain: {
|
|
614
|
+
readonly addressFormat: 'evm';
|
|
615
|
+
readonly id: 'eip155:4217';
|
|
616
|
+
readonly kind: 'evm';
|
|
617
|
+
readonly name: 'Tempo';
|
|
618
|
+
};
|
|
619
|
+
readonly destinationToken: {
|
|
620
|
+
address: "0x20c0000000000000000000000000000000000000" | "0x20c00000000000000000000014f22ca97301eb73" | "0x20c0000000000000000000001621e21f71cf12fb" | "0x20c0000000000000000000003554d28269e0f3c2" | "0x20c000000000000000000000b9537d11c60e8b50";
|
|
621
|
+
decimals: 6;
|
|
622
|
+
metadata: {};
|
|
623
|
+
name: "Bridged EURC" | "Bridged USDC (Stargate)" | "USDT0" | "frxUSD" | "pathUSD";
|
|
624
|
+
standard: "TIP-20";
|
|
625
|
+
symbol: "EURC.e" | "USDC.e" | "USDT0" | "frxUSD" | "pathUSD";
|
|
626
|
+
tokenKey: string;
|
|
627
|
+
verified: boolean;
|
|
628
|
+
};
|
|
629
|
+
readonly errorCode: null;
|
|
630
|
+
readonly id: string;
|
|
631
|
+
readonly provider: {
|
|
632
|
+
id: "across" | "bridge" | "bungee" | "lifi" | "relay";
|
|
633
|
+
kind: "aggregator" | "enterpriseTransfer" | "intentBridge" | "solverNetwork";
|
|
634
|
+
name: "Across" | "Bridge.xyz" | "Bungee" | "LI.FI" | "Relay";
|
|
635
|
+
requiresApiKey: boolean;
|
|
636
|
+
};
|
|
637
|
+
readonly quality: {
|
|
638
|
+
readonly availableVolumeUsd: null;
|
|
639
|
+
readonly estimatedSeconds: null;
|
|
640
|
+
readonly feeBps: null;
|
|
641
|
+
readonly historicalVolumeUsd24h: null;
|
|
642
|
+
readonly instantVolumeUsd: null;
|
|
643
|
+
readonly liquiditySource: 'staticInventory';
|
|
644
|
+
readonly score: null;
|
|
645
|
+
readonly sourceDetail: null;
|
|
646
|
+
readonly tier: 'unknown';
|
|
647
|
+
};
|
|
648
|
+
readonly quote: null;
|
|
649
|
+
readonly sourceAmount: {
|
|
650
|
+
amount: string;
|
|
651
|
+
formatted: string;
|
|
652
|
+
usd: null;
|
|
653
|
+
};
|
|
654
|
+
readonly sourceChain: {
|
|
655
|
+
addressFormat: "evm" | "solana" | "tron";
|
|
656
|
+
id: "eip155:1" | "eip155:56" | "eip155:8453" | "solana:mainnet" | "tron:mainnet";
|
|
657
|
+
kind: "evm" | "solana" | "tron";
|
|
658
|
+
name: "BNB Smart Chain" | "Base" | "Ethereum" | "Solana" | "Tron";
|
|
659
|
+
providerIds: {
|
|
660
|
+
readonly across: '1';
|
|
661
|
+
readonly bridge: 'ethereum';
|
|
662
|
+
readonly bungee: '1';
|
|
663
|
+
readonly lifi: '1';
|
|
664
|
+
readonly relay: '1';
|
|
665
|
+
} | {
|
|
666
|
+
readonly across: '8453';
|
|
667
|
+
readonly bridge: 'base';
|
|
668
|
+
readonly bungee: '8453';
|
|
669
|
+
readonly lifi: '8453';
|
|
670
|
+
readonly relay: '8453';
|
|
671
|
+
} | {
|
|
672
|
+
readonly across: '56';
|
|
673
|
+
readonly bungee: '56';
|
|
674
|
+
readonly lifi: '56';
|
|
675
|
+
readonly relay: '56';
|
|
676
|
+
} | {
|
|
677
|
+
readonly bridge: 'solana';
|
|
678
|
+
readonly relay: 'solana';
|
|
679
|
+
} | {
|
|
680
|
+
readonly bridge: 'tron';
|
|
681
|
+
readonly relay: 'tron';
|
|
682
|
+
};
|
|
683
|
+
};
|
|
684
|
+
readonly sourceToken: {
|
|
685
|
+
address: "0x1abaea1f7c830bd89acc67ec4af516284b1bc33c" | "0x55d398326f99059ff775485246999027b3197955" | "0x60a3e35cc302bfa44cb288bc5a4f316fdb1adb42" | "0x6b175474e89094c44da98b954eedeac495271d0f" | "0x6c3ea9036406852006290770bedfcaba0e23a0e8" | "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913" | "0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d" | "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48" | "0xdac17f958d2ee523a2206206994597c13d831ec7" | "0xfde4c96c8593536e31f229ea8f37b2ada2699bb2" | "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" | "Es9vMFrzaCERmJfrF4H2FYD4KCo3LwC1uix9YEaQ8t1v" | "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t";
|
|
686
|
+
decimals: 6 | 18;
|
|
687
|
+
metadata: {
|
|
688
|
+
coingeckoId: "dai" | "euro-coin" | "paypal-usd" | "tether" | "usd-coin";
|
|
689
|
+
};
|
|
690
|
+
name: "Binance-Peg USD Coin" | "Dai Stablecoin" | "Euro Coin" | "PayPal USD" | "Tether USD" | "USD Coin";
|
|
691
|
+
standard: "BEP-20" | "ERC-20" | "SPL" | "TRC-20";
|
|
692
|
+
symbol: "DAI" | "EURC" | "PYUSD" | "USDC" | "USDT";
|
|
693
|
+
tokenKey: string;
|
|
694
|
+
verified: boolean;
|
|
695
|
+
};
|
|
696
|
+
readonly status: 'unknown';
|
|
143
697
|
}[];
|
|
144
|
-
export declare namespace
|
|
145
|
-
/** Options for listing funding routes. */
|
|
698
|
+
export declare namespace listStaticRoutes {
|
|
699
|
+
/** Options for listing static funding routes. */
|
|
146
700
|
type Options = {
|
|
147
701
|
/** Optional Tempo destination token symbol, address, or token key. */
|
|
148
702
|
destinationToken?: string | undefined;
|
|
@@ -160,10 +714,179 @@ export declare namespace listRoutes {
|
|
|
160
714
|
sourceToken: string;
|
|
161
715
|
};
|
|
162
716
|
}
|
|
717
|
+
export declare namespace listRoutes {
|
|
718
|
+
/** Options for listing funding routes. */
|
|
719
|
+
type Options = listStaticRoutes.Options & {
|
|
720
|
+
/** Provider adapters used to enrich static inventory with live data. */
|
|
721
|
+
adapters?: ProviderAdapters | undefined;
|
|
722
|
+
/** Per-provider quote timeout in milliseconds. */
|
|
723
|
+
adapterTimeoutMs?: number | undefined;
|
|
724
|
+
/** Cache policy for provider-side inventory, quote, and liquidity lookups. */
|
|
725
|
+
cache?: CachePolicy | undefined;
|
|
726
|
+
/** Response expansions requested by the caller. */
|
|
727
|
+
include?: readonly Include[] | undefined;
|
|
728
|
+
};
|
|
729
|
+
}
|
|
163
730
|
/** Provider capability identifiers accepted by the generic provider catalog. */
|
|
164
731
|
export type Capability = 'fundingRoutes';
|
|
165
732
|
/** Source amount unit accepted by the funding route request. */
|
|
166
733
|
export type SourceAmountUnits = 'baseUnits' | 'decimal';
|
|
734
|
+
declare function formatChain(chain: SourceChainInput): {
|
|
735
|
+
addressFormat: "evm" | "solana" | "tron";
|
|
736
|
+
id: "eip155:1" | "eip155:56" | "eip155:8453" | "solana:mainnet" | "tron:mainnet";
|
|
737
|
+
kind: "evm" | "solana" | "tron";
|
|
738
|
+
name: "BNB Smart Chain" | "Base" | "Ethereum" | "Solana" | "Tron";
|
|
739
|
+
providerIds: {
|
|
740
|
+
readonly across: '1';
|
|
741
|
+
readonly bridge: 'ethereum';
|
|
742
|
+
readonly bungee: '1';
|
|
743
|
+
readonly lifi: '1';
|
|
744
|
+
readonly relay: '1';
|
|
745
|
+
} | {
|
|
746
|
+
readonly across: '8453';
|
|
747
|
+
readonly bridge: 'base';
|
|
748
|
+
readonly bungee: '8453';
|
|
749
|
+
readonly lifi: '8453';
|
|
750
|
+
readonly relay: '8453';
|
|
751
|
+
} | {
|
|
752
|
+
readonly across: '56';
|
|
753
|
+
readonly bungee: '56';
|
|
754
|
+
readonly lifi: '56';
|
|
755
|
+
readonly relay: '56';
|
|
756
|
+
} | {
|
|
757
|
+
readonly bridge: 'solana';
|
|
758
|
+
readonly relay: 'solana';
|
|
759
|
+
} | {
|
|
760
|
+
readonly bridge: 'tron';
|
|
761
|
+
readonly relay: 'tron';
|
|
762
|
+
};
|
|
763
|
+
};
|
|
764
|
+
declare function formatDestinationToken(token: DestinationTokenInput): {
|
|
765
|
+
address: "0x20c0000000000000000000000000000000000000" | "0x20c00000000000000000000014f22ca97301eb73" | "0x20c0000000000000000000001621e21f71cf12fb" | "0x20c0000000000000000000003554d28269e0f3c2" | "0x20c000000000000000000000b9537d11c60e8b50";
|
|
766
|
+
decimals: 6;
|
|
767
|
+
metadata: {};
|
|
768
|
+
name: "Bridged EURC" | "Bridged USDC (Stargate)" | "USDT0" | "frxUSD" | "pathUSD";
|
|
769
|
+
standard: "TIP-20";
|
|
770
|
+
symbol: "EURC.e" | "USDC.e" | "USDT0" | "frxUSD" | "pathUSD";
|
|
771
|
+
tokenKey: string;
|
|
772
|
+
verified: boolean;
|
|
773
|
+
};
|
|
774
|
+
declare function formatRouteCandidate(options: {
|
|
775
|
+
destinationToken: DestinationTokenInput;
|
|
776
|
+
provider: ProviderInput;
|
|
777
|
+
sourceAmount: ReturnType<typeof resolveSourceAmount>;
|
|
778
|
+
sourceChain: SourceChainInput;
|
|
779
|
+
sourceToken: TokenInput;
|
|
780
|
+
}): {
|
|
781
|
+
readonly destinationChain: {
|
|
782
|
+
readonly addressFormat: 'evm';
|
|
783
|
+
readonly id: 'eip155:4217';
|
|
784
|
+
readonly kind: 'evm';
|
|
785
|
+
readonly name: 'Tempo';
|
|
786
|
+
};
|
|
787
|
+
readonly destinationToken: {
|
|
788
|
+
address: "0x20c0000000000000000000000000000000000000" | "0x20c00000000000000000000014f22ca97301eb73" | "0x20c0000000000000000000001621e21f71cf12fb" | "0x20c0000000000000000000003554d28269e0f3c2" | "0x20c000000000000000000000b9537d11c60e8b50";
|
|
789
|
+
decimals: 6;
|
|
790
|
+
metadata: {};
|
|
791
|
+
name: "Bridged EURC" | "Bridged USDC (Stargate)" | "USDT0" | "frxUSD" | "pathUSD";
|
|
792
|
+
standard: "TIP-20";
|
|
793
|
+
symbol: "EURC.e" | "USDC.e" | "USDT0" | "frxUSD" | "pathUSD";
|
|
794
|
+
tokenKey: string;
|
|
795
|
+
verified: boolean;
|
|
796
|
+
};
|
|
797
|
+
readonly errorCode: null;
|
|
798
|
+
readonly id: string;
|
|
799
|
+
readonly provider: {
|
|
800
|
+
id: "across" | "bridge" | "bungee" | "lifi" | "relay";
|
|
801
|
+
kind: "aggregator" | "enterpriseTransfer" | "intentBridge" | "solverNetwork";
|
|
802
|
+
name: "Across" | "Bridge.xyz" | "Bungee" | "LI.FI" | "Relay";
|
|
803
|
+
requiresApiKey: boolean;
|
|
804
|
+
};
|
|
805
|
+
readonly quality: {
|
|
806
|
+
readonly availableVolumeUsd: null;
|
|
807
|
+
readonly estimatedSeconds: null;
|
|
808
|
+
readonly feeBps: null;
|
|
809
|
+
readonly historicalVolumeUsd24h: null;
|
|
810
|
+
readonly instantVolumeUsd: null;
|
|
811
|
+
readonly liquiditySource: 'staticInventory';
|
|
812
|
+
readonly score: null;
|
|
813
|
+
readonly sourceDetail: null;
|
|
814
|
+
readonly tier: 'unknown';
|
|
815
|
+
};
|
|
816
|
+
readonly quote: null;
|
|
817
|
+
readonly sourceAmount: {
|
|
818
|
+
amount: string;
|
|
819
|
+
formatted: string;
|
|
820
|
+
usd: null;
|
|
821
|
+
};
|
|
822
|
+
readonly sourceChain: {
|
|
823
|
+
addressFormat: "evm" | "solana" | "tron";
|
|
824
|
+
id: "eip155:1" | "eip155:56" | "eip155:8453" | "solana:mainnet" | "tron:mainnet";
|
|
825
|
+
kind: "evm" | "solana" | "tron";
|
|
826
|
+
name: "BNB Smart Chain" | "Base" | "Ethereum" | "Solana" | "Tron";
|
|
827
|
+
providerIds: {
|
|
828
|
+
readonly across: '1';
|
|
829
|
+
readonly bridge: 'ethereum';
|
|
830
|
+
readonly bungee: '1';
|
|
831
|
+
readonly lifi: '1';
|
|
832
|
+
readonly relay: '1';
|
|
833
|
+
} | {
|
|
834
|
+
readonly across: '8453';
|
|
835
|
+
readonly bridge: 'base';
|
|
836
|
+
readonly bungee: '8453';
|
|
837
|
+
readonly lifi: '8453';
|
|
838
|
+
readonly relay: '8453';
|
|
839
|
+
} | {
|
|
840
|
+
readonly across: '56';
|
|
841
|
+
readonly bungee: '56';
|
|
842
|
+
readonly lifi: '56';
|
|
843
|
+
readonly relay: '56';
|
|
844
|
+
} | {
|
|
845
|
+
readonly bridge: 'solana';
|
|
846
|
+
readonly relay: 'solana';
|
|
847
|
+
} | {
|
|
848
|
+
readonly bridge: 'tron';
|
|
849
|
+
readonly relay: 'tron';
|
|
850
|
+
};
|
|
851
|
+
};
|
|
852
|
+
readonly sourceToken: {
|
|
853
|
+
address: "0x1abaea1f7c830bd89acc67ec4af516284b1bc33c" | "0x55d398326f99059ff775485246999027b3197955" | "0x60a3e35cc302bfa44cb288bc5a4f316fdb1adb42" | "0x6b175474e89094c44da98b954eedeac495271d0f" | "0x6c3ea9036406852006290770bedfcaba0e23a0e8" | "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913" | "0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d" | "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48" | "0xdac17f958d2ee523a2206206994597c13d831ec7" | "0xfde4c96c8593536e31f229ea8f37b2ada2699bb2" | "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" | "Es9vMFrzaCERmJfrF4H2FYD4KCo3LwC1uix9YEaQ8t1v" | "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t";
|
|
854
|
+
decimals: 6 | 18;
|
|
855
|
+
metadata: {
|
|
856
|
+
coingeckoId: "dai" | "euro-coin" | "paypal-usd" | "tether" | "usd-coin";
|
|
857
|
+
};
|
|
858
|
+
name: "Binance-Peg USD Coin" | "Dai Stablecoin" | "Euro Coin" | "PayPal USD" | "Tether USD" | "USD Coin";
|
|
859
|
+
standard: "BEP-20" | "ERC-20" | "SPL" | "TRC-20";
|
|
860
|
+
symbol: "DAI" | "EURC" | "PYUSD" | "USDC" | "USDT";
|
|
861
|
+
tokenKey: string;
|
|
862
|
+
verified: boolean;
|
|
863
|
+
};
|
|
864
|
+
readonly status: 'unknown';
|
|
865
|
+
};
|
|
866
|
+
declare function formatSourceToken(chain: SourceChainInput, token: TokenInput): {
|
|
867
|
+
address: "0x1abaea1f7c830bd89acc67ec4af516284b1bc33c" | "0x55d398326f99059ff775485246999027b3197955" | "0x60a3e35cc302bfa44cb288bc5a4f316fdb1adb42" | "0x6b175474e89094c44da98b954eedeac495271d0f" | "0x6c3ea9036406852006290770bedfcaba0e23a0e8" | "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913" | "0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d" | "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48" | "0xdac17f958d2ee523a2206206994597c13d831ec7" | "0xfde4c96c8593536e31f229ea8f37b2ada2699bb2" | "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" | "Es9vMFrzaCERmJfrF4H2FYD4KCo3LwC1uix9YEaQ8t1v" | "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t";
|
|
868
|
+
decimals: 6 | 18;
|
|
869
|
+
metadata: {
|
|
870
|
+
coingeckoId: "dai" | "euro-coin" | "paypal-usd" | "tether" | "usd-coin";
|
|
871
|
+
};
|
|
872
|
+
name: "Binance-Peg USD Coin" | "Dai Stablecoin" | "Euro Coin" | "PayPal USD" | "Tether USD" | "USD Coin";
|
|
873
|
+
standard: "BEP-20" | "ERC-20" | "SPL" | "TRC-20";
|
|
874
|
+
symbol: "DAI" | "EURC" | "PYUSD" | "USDC" | "USDT";
|
|
875
|
+
tokenKey: string;
|
|
876
|
+
verified: boolean;
|
|
877
|
+
};
|
|
878
|
+
declare function resolveSourceAmount(options: resolveSourceAmount.Options): {
|
|
879
|
+
amount: string;
|
|
880
|
+
formatted: string;
|
|
881
|
+
usd: null;
|
|
882
|
+
};
|
|
883
|
+
declare namespace resolveSourceAmount {
|
|
884
|
+
type Options = {
|
|
885
|
+
amount: string;
|
|
886
|
+
token: TokenInput;
|
|
887
|
+
units: SourceAmountUnits;
|
|
888
|
+
};
|
|
889
|
+
}
|
|
167
890
|
/** Error thrown when the caller supplies an unsupported destination token. */
|
|
168
891
|
export declare class UnsupportedDestinationTokenError extends Error {
|
|
169
892
|
name: string;
|
|
@@ -172,12 +895,21 @@ export declare class UnsupportedDestinationTokenError extends Error {
|
|
|
172
895
|
export declare class InvalidAmountError extends Error {
|
|
173
896
|
name: string;
|
|
174
897
|
}
|
|
898
|
+
/** Error thrown internally when a provider adapter exceeds its route quote timeout. */
|
|
899
|
+
export declare class ProviderAdapterTimeoutError extends Error {
|
|
900
|
+
name: string;
|
|
901
|
+
}
|
|
175
902
|
/** Error thrown when the caller filters to an unknown provider. */
|
|
176
903
|
export declare class UnsupportedProviderError extends Error {
|
|
177
904
|
name: string;
|
|
178
905
|
}
|
|
906
|
+
/** Error thrown when the caller requests an unsupported include expansion. */
|
|
907
|
+
export declare class UnsupportedIncludeError extends Error {
|
|
908
|
+
name: string;
|
|
909
|
+
}
|
|
179
910
|
/** Error thrown when the caller supplies an unsupported source chain. */
|
|
180
911
|
export declare class UnsupportedSourceChainError extends Error {
|
|
181
912
|
name: string;
|
|
182
913
|
}
|
|
914
|
+
export {};
|
|
183
915
|
//# sourceMappingURL=FundingRoutes.d.ts.map
|