0xtrails 0.7.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/dist/{ccip-fConRNoG.js → ccip-uMWNlvmJ.js} +34 -34
  2. package/dist/fees.d.ts.map +1 -1
  3. package/dist/{index-BbajxCG_.js → index-BiPwqVkZ.js} +31527 -28874
  4. package/dist/index.d.ts +8 -1
  5. package/dist/index.d.ts.map +1 -1
  6. package/dist/index.js +478 -456
  7. package/dist/intents.d.ts +10 -4
  8. package/dist/intents.d.ts.map +1 -1
  9. package/dist/prepareSend.d.ts +1 -1
  10. package/dist/prepareSend.d.ts.map +1 -1
  11. package/dist/prices.d.ts +2 -2
  12. package/dist/prices.d.ts.map +1 -1
  13. package/dist/refund.d.ts +116 -0
  14. package/dist/refund.d.ts.map +1 -0
  15. package/dist/tokenBalances.d.ts +1 -1
  16. package/dist/tokenBalances.d.ts.map +1 -1
  17. package/dist/transactionIntent/handlers/crossChain.d.ts +4 -3
  18. package/dist/transactionIntent/handlers/crossChain.d.ts.map +1 -1
  19. package/dist/transactionIntent/handlers/sameChainSameToken.d.ts +3 -3
  20. package/dist/transactionIntent/handlers/sameChainSameToken.d.ts.map +1 -1
  21. package/dist/transactionIntent/quote/normalizeQuote.d.ts +1 -2
  22. package/dist/transactionIntent/quote/normalizeQuote.d.ts.map +1 -1
  23. package/dist/transactionIntent/quote/quoteHelpers.d.ts +3 -3
  24. package/dist/transactionIntent/quote/quoteHelpers.d.ts.map +1 -1
  25. package/dist/transactionIntent/types.d.ts +5 -4
  26. package/dist/transactionIntent/types.d.ts.map +1 -1
  27. package/dist/transactions.d.ts +4 -0
  28. package/dist/transactions.d.ts.map +1 -1
  29. package/dist/widget/components/AccountIntentTransactionHistory.d.ts.map +1 -1
  30. package/dist/widget/components/ClassicSwap.d.ts +2 -1
  31. package/dist/widget/components/ClassicSwap.d.ts.map +1 -1
  32. package/dist/widget/components/Earn.d.ts +2 -1
  33. package/dist/widget/components/Earn.d.ts.map +1 -1
  34. package/dist/widget/components/ErrorDisplay.d.ts.map +1 -1
  35. package/dist/widget/components/Fund.d.ts +2 -1
  36. package/dist/widget/components/Fund.d.ts.map +1 -1
  37. package/dist/widget/components/FundSwap.d.ts +2 -1
  38. package/dist/widget/components/FundSwap.d.ts.map +1 -1
  39. package/dist/widget/components/Pay.d.ts +2 -1
  40. package/dist/widget/components/Pay.d.ts.map +1 -1
  41. package/dist/widget/components/PoolDeposit.d.ts +2 -1
  42. package/dist/widget/components/PoolDeposit.d.ts.map +1 -1
  43. package/dist/widget/components/QuoteDetails.d.ts +1 -0
  44. package/dist/widget/components/QuoteDetails.d.ts.map +1 -1
  45. package/dist/widget/components/Swap.d.ts +2 -1
  46. package/dist/widget/components/Swap.d.ts.map +1 -1
  47. package/dist/widget/components/TokenImage.d.ts.map +1 -1
  48. package/dist/widget/components/TransactionDetails.d.ts.map +1 -1
  49. package/dist/widget/css/compiled.css +1 -1
  50. package/dist/widget/hooks/useAmountUsd.d.ts.map +1 -1
  51. package/dist/widget/hooks/useDefaultTokenSelection.d.ts.map +1 -1
  52. package/dist/widget/hooks/useGetIntent.d.ts +18 -0
  53. package/dist/widget/hooks/useGetIntent.d.ts.map +1 -0
  54. package/dist/widget/hooks/useIntentTransactionHistory.d.ts.map +1 -1
  55. package/dist/widget/hooks/useQuote.d.ts +10 -7
  56. package/dist/widget/hooks/useQuote.d.ts.map +1 -1
  57. package/dist/widget/hooks/useSendForm.d.ts +3 -2
  58. package/dist/widget/hooks/useSendForm.d.ts.map +1 -1
  59. package/dist/widget/hooks/useTokenList.d.ts.map +1 -1
  60. package/dist/widget/hooks/useTrailsSendTransaction.d.ts.map +1 -1
  61. package/dist/widget/index.js +3 -3
  62. package/dist/widget/widget.d.ts +2 -1
  63. package/dist/widget/widget.d.ts.map +1 -1
  64. package/package.json +5 -12
  65. package/src/fees.ts +8 -2
  66. package/src/index.ts +33 -1
  67. package/src/intents.ts +34 -7
  68. package/src/prepareSend.ts +6 -4
  69. package/src/prices.ts +6 -6
  70. package/src/refund.ts +914 -0
  71. package/src/tokenBalances.ts +4 -14
  72. package/src/transactionIntent/handlers/crossChain.ts +21 -10
  73. package/src/transactionIntent/handlers/sameChainSameToken.ts +12 -8
  74. package/src/transactionIntent/quote/normalizeQuote.ts +29 -27
  75. package/src/transactionIntent/quote/quoteHelpers.ts +5 -9
  76. package/src/transactionIntent/types.ts +5 -3
  77. package/src/transactions.ts +5 -0
  78. package/src/widget/compiled.css +1 -1
  79. package/src/widget/components/AccountIntentTransactionHistory.tsx +197 -5
  80. package/src/widget/components/ClassicSwap.tsx +6 -3
  81. package/src/widget/components/Earn.tsx +6 -3
  82. package/src/widget/components/ErrorDisplay.tsx +6 -4
  83. package/src/widget/components/Fund.tsx +6 -3
  84. package/src/widget/components/FundSwap.tsx +2 -1
  85. package/src/widget/components/Pay.tsx +15 -7
  86. package/src/widget/components/PoolDeposit.tsx +6 -3
  87. package/src/widget/components/QuoteDetails.tsx +34 -38
  88. package/src/widget/components/Swap.tsx +2 -1
  89. package/src/widget/components/TokenImage.tsx +3 -1
  90. package/src/widget/components/TransactionDetails.tsx +108 -0
  91. package/src/widget/hooks/useAmountUsd.ts +0 -3
  92. package/src/widget/hooks/useDefaultTokenSelection.tsx +0 -3
  93. package/src/widget/hooks/useGetIntent.ts +53 -0
  94. package/src/widget/hooks/useIntentTransactionHistory.ts +85 -3
  95. package/src/widget/hooks/useQuote.ts +16 -10
  96. package/src/widget/hooks/useSendForm.ts +30 -15
  97. package/src/widget/hooks/useTokenList.ts +2 -4
  98. package/src/widget/hooks/useTrailsSendTransaction.ts +2 -1
  99. package/src/widget/widget.tsx +12 -6
  100. package/dist/sequenceWallet.d.ts +0 -67
  101. package/dist/sequenceWallet.d.ts.map +0 -1
  102. package/src/sequenceWallet.ts +0 -532
@@ -256,11 +256,7 @@ export interface GetTokenBalancesWithPrice {
256
256
  >
257
257
  }
258
258
 
259
- export function useTokenBalances(
260
- address: Address.Address,
261
- indexerGatewayClient?: SequenceIndexerGateway,
262
- sequenceApiClient?: TrailsClient,
263
- ): {
259
+ export function useTokenBalances(address: Address.Address | null): {
264
260
  tokenBalancesData: GetTokenBalancesSummaryReturn | undefined
265
261
  isLoadingBalances: boolean
266
262
  isLoadingPrices: boolean
@@ -268,13 +264,8 @@ export function useTokenBalances(
268
264
  balanceError: Error | null
269
265
  sortedTokens: Token[]
270
266
  } {
271
- // Always call hooks unconditionally to fix React rules violation
272
- const hookIndexerClient = useIndexerGatewayClient()
273
- const hookTrailsClient = useTrailsClient()
274
-
275
- // Use passed parameters if available, otherwise use hook results
276
- const indexerClient = indexerGatewayClient ?? hookIndexerClient
277
- const apiClient = sequenceApiClient ?? hookTrailsClient
267
+ // Use hooks to get clients
268
+ const indexerClient = useIndexerGatewayClient()
278
269
 
279
270
  // Fetch token balances with improved query key structure
280
271
  const {
@@ -285,7 +276,7 @@ export function useTokenBalances(
285
276
  queryKey: ["getTokenBalancesWithPrices", "summary", address],
286
277
  queryFn: async (): Promise<GetTokenBalancesWithPrice> => {
287
278
  if (!address) {
288
- logger.console.warn("[trails-sdk] No account address or indexer client")
279
+ logger.console.warn("[trails-sdk] No account address provided")
289
280
  return {
290
281
  balances: [],
291
282
  nativeBalances: [],
@@ -377,7 +368,6 @@ export function useTokenBalances(
377
368
  }
378
369
  }),
379
370
  ) ?? [],
380
- apiClient,
381
371
  )
382
372
 
383
373
  const { data: sortedTokens = [], isLoading: isLoadingSortedTokens } =
@@ -7,7 +7,7 @@ import type {
7
7
  } from "viem"
8
8
  import { JsonEncode } from "@0xtrails/api"
9
9
  import { getChainRpcClient } from "../../chains.js"
10
- import type { FeeOption, TrailsApi } from "@0xtrails/api"
10
+ import type { FeeOption, TrailsApi, RouteProvider } from "@0xtrails/api"
11
11
  import type { IntentTransaction } from "@0xtrails/api"
12
12
  import type { PrepareSendReturn, SendReturn } from "../types.js"
13
13
  import type { TransactionState } from "../../transactions.js"
@@ -116,7 +116,8 @@ export async function handleCrossChain({
116
116
  slippageTolerance,
117
117
  tradeType,
118
118
  originNativeTokenPriceUsd,
119
- quoteProvider,
119
+ swapProvider,
120
+ bridgeProvider,
120
121
  fundMethod,
121
122
  mode,
122
123
  checkoutOnHandlers,
@@ -159,7 +160,8 @@ export async function handleCrossChain({
159
160
  slippageTolerance: string
160
161
  tradeType: TradeType
161
162
  originNativeTokenPriceUsd?: number | null
162
- quoteProvider?: string | null
163
+ swapProvider?: RouteProvider | null
164
+ bridgeProvider?: RouteProvider | null
163
165
  fundMethod?: string
164
166
  mode?: "pay" | "fund" | "earn" | "swap"
165
167
  checkoutOnHandlers?: Partial<CheckoutOnHandlers>
@@ -178,8 +180,6 @@ export async function handleCrossChain({
178
180
  trailsApiKey?: string
179
181
  trailsApiUrl?: string
180
182
  }): Promise<PrepareSendReturn> {
181
- const salt = Date.now().toString()
182
-
183
183
  const intentArgs = await getIntentArgs(
184
184
  mainSignerAddress,
185
185
  originChainId,
@@ -190,10 +190,10 @@ export async function handleCrossChain({
190
190
  tradeType === TradeType.EXACT_OUTPUT ? swapAmount : "0", // destinationTokenAmount
191
191
  recipient,
192
192
  destinationCalldata,
193
- salt,
194
193
  slippageTolerance,
195
194
  tradeType,
196
- quoteProvider,
195
+ swapProvider,
196
+ bridgeProvider,
197
197
  undefined, // connector - not available in this context
198
198
  walletId, // walletId - use this to check for Sequence wallets
199
199
  isSmartWallet, // isSmartWallet - force onlyNativeGasFee when true
@@ -350,6 +350,19 @@ export async function handleCrossChain({
350
350
  estimatedGasLimitForQuote,
351
351
  )
352
352
 
353
+ if (
354
+ intent.quote?.routeProviders &&
355
+ intent.quote.routeProviders.length === 1
356
+ ) {
357
+ swapProvider = intent.quote.routeProviders[0]!
358
+ } else if (
359
+ intent.quote?.routeProviders &&
360
+ intent.quote.routeProviders.length === 2
361
+ ) {
362
+ swapProvider = intent.quote.routeProviders[0]!
363
+ bridgeProvider = intent.quote.routeProviders[1]!
364
+ }
365
+
353
366
  const quote = await getNormalizedQuoteObject({
354
367
  originDepositAddress: originIntentAddress,
355
368
  destinationDepositAddress: intent.destinationIntentAddress,
@@ -377,7 +390,6 @@ export async function handleCrossChain({
377
390
  priceImpactUsd: getPriceImpactUsdFromIntent(intent),
378
391
  transactionStates,
379
392
  originNativeTokenPriceUsd,
380
- quoteProvider: intent.quote?.quoteProvider,
381
393
  noSufficientBalance,
382
394
  estimatedGasLimit: estimatedGasLimitForQuote,
383
395
  intent,
@@ -1347,8 +1359,7 @@ export async function handleCrossChain({
1347
1359
  logger.console.log(
1348
1360
  "[trails-sdk] Starting destinationSendMetaTxnPromise",
1349
1361
  {
1350
- quoteProvider: intent.quote.quoteProvider,
1351
- hasQuoteProviderRequestId: !!intent.quote.quoteProviderRequestId,
1362
+ routeProviders: intent.quote.routeProviders || [],
1352
1363
  hasPrecondition1: !!destinationPre,
1353
1364
  hasMetaTxn1: !!destinationMeta,
1354
1365
  },
@@ -1,7 +1,7 @@
1
1
  import type { Account, Chain, WalletClient, TransactionReceipt } from "viem"
2
2
  import { formatUnits } from "viem"
3
3
  import { getChainRpcClient } from "../../chains.js"
4
- import type { FeeOption, TrailsApi } from "@0xtrails/api"
4
+ import type { FeeOption, TrailsApi, RouteProvider } from "@0xtrails/api"
5
5
  import type { PrepareSendReturn, SendReturn } from "../types.js"
6
6
  import type { IntentTransaction } from "@0xtrails/api"
7
7
  import type { TransactionState } from "../../transactions.js"
@@ -62,7 +62,7 @@ export async function handleSameChainSameToken({
62
62
  destinationTokenPriceUsd,
63
63
  originNativeTokenPriceUsd,
64
64
  slippageTolerance,
65
- quoteProvider,
65
+ swapProvider,
66
66
  checkoutOnHandlers,
67
67
  mode,
68
68
  fundMethod,
@@ -97,7 +97,7 @@ export async function handleSameChainSameToken({
97
97
  destinationTokenPriceUsd?: number | null
98
98
  originNativeTokenPriceUsd?: number | null
99
99
  slippageTolerance: string
100
- quoteProvider?: string | null
100
+ swapProvider?: RouteProvider | null
101
101
  checkoutOnHandlers?: Partial<CheckoutOnHandlers>
102
102
  mode?: "pay" | "fund" | "earn" | "swap"
103
103
  fundMethod?: string
@@ -201,7 +201,6 @@ export async function handleSameChainSameToken({
201
201
  destinationChainId: effectiveOriginChainId,
202
202
  originNativeTokenPriceUsd,
203
203
  slippageTolerance,
204
- quoteProvider: quoteProvider || "direct",
205
204
  noSufficientBalance,
206
205
  estimatedGasLimit: estimatedGasLimitForQuote,
207
206
  trailsApiKey: trailsApiKey || "",
@@ -451,7 +450,6 @@ export async function handleSameChainSameToken({
451
450
  }
452
451
 
453
452
  // For same-chain transactions, use Intent flow to support gasless deposits
454
- const salt = Date.now().toString()
455
453
  const intentArgs = await getIntentArgs(
456
454
  mainSignerAddress,
457
455
  effectiveOriginChainId,
@@ -462,10 +460,10 @@ export async function handleSameChainSameToken({
462
460
  "0", // destinationTokenAmount (exact input)
463
461
  recipient,
464
462
  destinationCalldata,
465
- salt,
466
463
  slippageTolerance,
467
464
  TradeType.EXACT_INPUT,
468
- quoteProvider || "",
465
+ swapProvider,
466
+ null,
469
467
  undefined, // connector - not available in this context
470
468
  walletId, // walletId - use this to check for Sequence wallets
471
469
  isSmartWallet, // isSmartWallet - force onlyNativeGasFee when true
@@ -534,6 +532,13 @@ export async function handleSameChainSameToken({
534
532
  estimatedGasLimitForQuote,
535
533
  )
536
534
 
535
+ if (
536
+ intent.quote?.routeProviders &&
537
+ intent.quote.routeProviders.length === 1
538
+ ) {
539
+ swapProvider = intent.quote.routeProviders[0]!
540
+ }
541
+
537
542
  const quote = await getNormalizedQuoteObject({
538
543
  originDepositAddress: intent.originIntentAddress,
539
544
  destinationDepositAddress: intent.destinationIntentAddress,
@@ -552,7 +557,6 @@ export async function handleSameChainSameToken({
552
557
  destinationChainId: effectiveOriginChainId,
553
558
  originNativeTokenPriceUsd,
554
559
  slippageTolerance,
555
- quoteProvider: intent.quote?.quoteProvider || "",
556
560
  noSufficientBalance,
557
561
  estimatedGasLimit: estimatedGasLimitForQuote,
558
562
  intent,
@@ -1,7 +1,7 @@
1
- import type { Intent } from "@0xtrails/api"
1
+ import type { Intent, RouteProvider } from "@0xtrails/api"
2
2
  import type { TransactionState } from "../../transactions.js"
3
3
  import type { PrepareSendQuote, PrepareSendFees } from "../types.js"
4
- import type { QuoteProviderInfo } from "../../widget/hooks/useQuote.js"
4
+ import type { RouteProviderInfo } from "../../widget/hooks/useQuote.js"
5
5
  import { formatUnits } from "viem"
6
6
  import { mainnet } from "viem/chains"
7
7
  import { getTokenInfo } from "../../tokens.js"
@@ -64,7 +64,6 @@ export async function getNormalizedQuoteObject({
64
64
  priceImpact,
65
65
  priceImpactUsd,
66
66
  originNativeTokenPriceUsd,
67
- quoteProvider,
68
67
  noSufficientBalance,
69
68
  estimatedGasLimit,
70
69
  intent,
@@ -91,7 +90,6 @@ export async function getNormalizedQuoteObject({
91
90
  priceImpact?: string
92
91
  priceImpactUsd?: string
93
92
  originNativeTokenPriceUsd?: number | null
94
- quoteProvider?: string
95
93
  noSufficientBalance?: boolean
96
94
  estimatedGasLimit?: bigint
97
95
  intent?: Intent
@@ -262,30 +260,34 @@ export async function getNormalizedQuoteObject({
262
260
  destinationToken.symbol,
263
261
  )
264
262
 
265
- let quoteProviderUrl = ""
266
- if (quoteProvider === "cctp") {
267
- quoteProviderUrl = "https://www.circle.com/"
268
- } else if (quoteProvider === "relay") {
269
- quoteProviderUrl = "https://relay.link/"
270
- } else if (quoteProvider === "lifi") {
271
- quoteProviderUrl = "https://li.fi/"
263
+ // Map RouteProvider enum values to display names and URLs
264
+ const routeProviderInfo: Record<
265
+ RouteProvider,
266
+ { name: string; url: string }
267
+ > = {
268
+ AUTO: { name: "", url: "" },
269
+ CCTP: { name: "Circle CCTP", url: "https://www.circle.com/" },
270
+ RELAY: { name: "Relay", url: "https://relay.link/" },
271
+ LIFI: { name: "LiFi", url: "https://li.fi/" },
272
+ ZEROX: { name: "0x", url: "https://0x.org/" },
273
+ SUSHI: { name: "Sushi", url: "https://www.sushi.com/" },
272
274
  }
273
275
 
274
- const quoteProviderNames = {
275
- cctp: "Circle CCTP",
276
- relay: "Relay",
277
- lifi: "LiFi",
278
- }
279
-
280
- const quoteProviderName =
281
- quoteProviderNames[quoteProvider as keyof typeof quoteProviderNames] ||
282
- quoteProvider ||
283
- ""
284
- const quoteProviderInfo: QuoteProviderInfo = {
285
- id: quoteProvider || "",
286
- name: quoteProviderName || "",
287
- url: quoteProviderUrl || "",
288
- }
276
+ // Build routeProviders array from intent.quote.routeProviders
277
+ const routeProviders: RouteProviderInfo[] =
278
+ intent?.quote?.routeProviders && Array.isArray(intent.quote.routeProviders)
279
+ ? intent.quote.routeProviders.map((provider) => {
280
+ const info = routeProviderInfo[provider] || {
281
+ name: provider,
282
+ url: "",
283
+ }
284
+ return {
285
+ id: provider,
286
+ name: info.name,
287
+ url: info.url,
288
+ }
289
+ })
290
+ : []
289
291
 
290
292
  const priceImpactUsdDisplay = formatUsdAmountDisplay(priceImpactUsd)
291
293
 
@@ -401,7 +403,7 @@ export async function getNormalizedQuoteObject({
401
403
  destinationAmountMinDisplay: formatAmountDisplay(
402
404
  destinationAmountMinFormatted,
403
405
  ),
404
- quoteProvider: quoteProviderInfo,
406
+ routeProviders,
405
407
  noSufficientBalance: noSufficientBalance || false,
406
408
  trailsFeeBreakdown,
407
409
  grandTotalUsd,
@@ -1,4 +1,4 @@
1
- import type { QuoteIntentRequest } from "@0xtrails/api"
1
+ import type { QuoteIntentRequest, RouteProvider } from "@0xtrails/api"
2
2
  import type { Connector } from "wagmi"
3
3
  import { getIsCustomCalldata } from "../../contractUtils.js"
4
4
  import {
@@ -19,21 +19,16 @@ export async function getIntentArgs(
19
19
  destinationTokenAmount: string,
20
20
  recipient: string,
21
21
  destinationCalldata: string | undefined,
22
- _destinationSalt: string = Date.now().toString(),
23
22
  slippageTolerance: string, // 0.03 = 3%
24
23
  tradeType: TradeType,
25
- provider?: string | null,
24
+ swapProvider?: RouteProvider | null,
25
+ bridgeProvider?: RouteProvider | null,
26
26
  connector?: Connector | undefined,
27
27
  walletId?: string | undefined,
28
28
  isSmartWallet?: boolean,
29
29
  ): Promise<QuoteIntentRequest> {
30
30
  const hasCustomCalldata = getIsCustomCalldata(destinationCalldata)
31
31
 
32
- let effectiveProvider = provider
33
- if (provider === "auto") {
34
- effectiveProvider = undefined
35
- }
36
-
37
32
  // Check if wallet is Sequence wallet (via connector or walletId)
38
33
  const isSequence = connector
39
34
  ? isSequenceWallet(connector)
@@ -74,7 +69,8 @@ export async function getIntentArgs(
74
69
  onlyNativeGasFee,
75
70
  options: {
76
71
  slippageTolerance: Number(slippageTolerance),
77
- quoteProvider: effectiveProvider || undefined,
72
+ swapProvider: swapProvider || undefined,
73
+ bridgeProvider: bridgeProvider || undefined,
78
74
  },
79
75
  tradeType,
80
76
  }
@@ -13,11 +13,12 @@ import type {
13
13
  FeeOption,
14
14
  GasFeeOptions,
15
15
  ExecuteIntentResponse,
16
+ RouteProvider,
16
17
  } from "@0xtrails/api"
17
18
  import type { TransactionState } from "../transactions.js"
18
19
  import type { Token } from "../tokens.js"
19
20
  import type { CheckoutOnHandlers } from "../widget/hooks/useCheckout.js"
20
- import type { QuoteProviderInfo } from "../widget/hooks/useQuote.js"
21
+ import type { RouteProviderInfo } from "../widget/hooks/useQuote.js"
21
22
  import type { TrailsFeeBreakdown } from "../fees.js"
22
23
  import type { IntentTransaction } from "@0xtrails/api"
23
24
 
@@ -54,7 +55,8 @@ export type PrepareSendOptions = {
54
55
  gasless?: boolean
55
56
  slippageTolerance?: string
56
57
  originNativeTokenPriceUsd?: number | null
57
- quoteProvider?: string | null
58
+ swapProvider?: RouteProvider | null
59
+ bridgeProvider?: RouteProvider | null
58
60
  fundMethod?: string
59
61
  mode?: "pay" | "fund" | "earn" | "swap"
60
62
  originPublicClient?: PublicClient
@@ -125,7 +127,7 @@ export type PrepareSendQuote = {
125
127
  gasCostFormatted: string
126
128
  originTokenRate: string
127
129
  destinationTokenRate: string
128
- quoteProvider: QuoteProviderInfo | null
130
+ routeProviders?: RouteProviderInfo[]
129
131
  noSufficientBalance: boolean
130
132
  trailsFeeBreakdown?: TrailsFeeBreakdown | null
131
133
  grandTotalUsd?: number
@@ -265,6 +265,7 @@ export type IntentTransaction = {
265
265
  originIntentAddress: string
266
266
  destinationIntentAddress: string
267
267
  mainSigner: string
268
+ intentId?: string
268
269
  metaTxnId?: string
269
270
  txnHash?: string
270
271
  executionStatus?: string
@@ -279,6 +280,10 @@ export type IntentTransaction = {
279
280
  // Transaction hashes from API response
280
281
  originTransactionHash?: string // Transaction hash from API
281
282
  destinationTransactionHash?: string // Transaction hash from API
283
+ // Transaction statuses from API response
284
+ depositTransactionStatus?: string // Deposit transaction status from API
285
+ originTransactionStatus?: string // Origin transaction status from API
286
+ destinationTransactionStatus?: string // Destination transaction status from API
282
287
  // Enriched token information
283
288
  originToken?: {
284
289
  symbol: string