@0xtrails/api 0.10.4 → 0.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,1158 @@
1
+ export declare const WebrpcVersion = "v1";
2
+ export declare const WebrpcSchemaVersion = "v1-26.2.10-fcbe559";
3
+ export declare const WebrpcSchemaHash = "739a9f32a6c6cb2dabf3c8843e28a336430d748b";
4
+ export interface TrailsClient {
5
+ ping(headers?: object, signal?: AbortSignal): Promise<PingResponse>;
6
+ runtimeStatus(headers?: object, signal?: AbortSignal): Promise<RuntimeStatusResponse>;
7
+ clock(headers?: object, signal?: AbortSignal): Promise<ClockResponse>;
8
+ quoteIntent(req: QuoteIntentRequest, headers?: object, signal?: AbortSignal): Promise<QuoteIntentResponse>;
9
+ commitIntent(req: CommitIntentRequest, headers?: object, signal?: AbortSignal): Promise<CommitIntentResponse>;
10
+ executeIntent(req: ExecuteIntentRequest, headers?: object, signal?: AbortSignal): Promise<ExecuteIntentResponse>;
11
+ waitIntentReceipt(req: WaitIntentReceiptRequest, headers?: object, signal?: AbortSignal): Promise<WaitIntentReceiptResponse>;
12
+ getIntentReceipt(req: GetIntentReceiptRequest, headers?: object, signal?: AbortSignal): Promise<GetIntentReceiptResponse>;
13
+ getIntent(req: GetIntentRequest, headers?: object, signal?: AbortSignal): Promise<GetIntentResponse>;
14
+ searchIntents(req: SearchIntentsRequest, headers?: object, signal?: AbortSignal): Promise<SearchIntentsResponse>;
15
+ getIntentConfig(req: GetIntentConfigRequest, headers?: object, signal?: AbortSignal): Promise<GetIntentConfigResponse>;
16
+ getIntentHistory(req: GetIntentHistoryRequest, headers?: object, signal?: AbortSignal): Promise<GetIntentHistoryResponse>;
17
+ abortIntent(req: AbortIntentRequest, headers?: object, signal?: AbortSignal): Promise<AbortIntentResponse>;
18
+ /**
19
+ * GetChains will return the list of supported chains by Trails.
20
+ */
21
+ getChains(req: GetChainsRequest, headers?: object, signal?: AbortSignal): Promise<GetChainsResponse>;
22
+ /**
23
+ * GetExactOutputRoutes will return a list of origin tokens, when given a destination chain and token,
24
+ * that can be used to pay/send from an origin chain the exact output amount on the
25
+ * destination chain.
26
+ *
27
+ * The request will include the destination chain and token desired. Optionally, the
28
+ * user can specify an origin chain and token to filter results to only that specific
29
+ * origin token. Additionally, an optional owner address can be provided to filter
30
+ * results to only tokens the owner has a balance on (requires indexer gateway to be
31
+ * configured).
32
+ *
33
+ * The response is a list of origin tokens and their chains which can be used to fulfill
34
+ * the exact output request. These are tokens the user can send FROM to achieve the desired
35
+ * destination token amount.
36
+ *
37
+ * aka, the 'pay' routes
38
+ */
39
+ getExactOutputRoutes(req: GetExactOutputRoutesRequest, headers?: object, signal?: AbortSignal): Promise<GetExactOutputRoutesResponse>;
40
+ /**
41
+ * GetExactInputRoutes will return a list of destination tokens, when given an origin chain and token,
42
+ * that can be used to send/swap to a destination chain and token.
43
+ *
44
+ * The request will include the origin chain and token used for input. Optionally, the
45
+ * user can specify a destination chain and token to further filter the results.
46
+ *
47
+ * The response is a list of destination tokens and their chains which can be reached from
48
+ * the origin token and chain. These are tokens the user can send TO from the given origin token.
49
+ *
50
+ * aka, the 'swap' routes
51
+ */
52
+ getExactInputRoutes(req: GetExactInputRoutesRequest, headers?: object, signal?: AbortSignal): Promise<GetExactInputRoutesResponse>;
53
+ /**
54
+ * GetTokenList will return a list of tokens based on the provided filters.
55
+ * NOTE: there are many filters and options on GetTokenListRequest
56
+ */
57
+ getTokenList(req: GetTokenListRequest, headers?: object, signal?: AbortSignal): Promise<GetTokenListResponse>;
58
+ /**
59
+ * GetTokenPrices will return the live prices for a list of tokens.
60
+ */
61
+ getTokenPrices(req: GetTokenPricesRequest, headers?: object, signal?: AbortSignal): Promise<GetTokenPricesResponse>;
62
+ /**
63
+ * GetExchangeRate returns the exchange rate from USD to a specified currency.
64
+ */
65
+ getExchangeRate(req: GetExchangeRateRequest, headers?: object, signal?: AbortSignal): Promise<GetExchangeRateResponse>;
66
+ /**
67
+ * GetCountryList returns the list of supported countries for onramp providers.
68
+ */
69
+ getCountryList(headers?: object, signal?: AbortSignal): Promise<GetCountryListResponse>;
70
+ /**
71
+ * GetTrailsContracts returns Trails contract addresses used by the Trails Intents stack.
72
+ */
73
+ getTrailsContracts(headers?: object, signal?: AbortSignal): Promise<GetTrailsContractsResponse>;
74
+ getSupportedIntentProtocolVersions(headers?: object, signal?: AbortSignal): Promise<GetSupportedIntentProtocolVersionsResponse>;
75
+ /**
76
+ * GetEarnPools returns aggregated pool information from DeFi protocols (Aave, Morpho).
77
+ * This endpoint provides yield-bearing opportunities across multiple chains.
78
+ */
79
+ getEarnPools(req: GetEarnPoolsRequest, headers?: object, signal?: AbortSignal): Promise<GetEarnPoolsResponse>;
80
+ /**
81
+ * GetFiatCurrencyList returns the list of supported fiat currencies for display preferences.
82
+ */
83
+ getFiatCurrencyList(headers?: object, signal?: AbortSignal): Promise<GetFiatCurrencyListResponse>;
84
+ /**
85
+ * @deprecated please use GetIntentHistory instead
86
+ */
87
+ getIntentTransactionHistory(req: GetIntentTransactionHistoryRequest, headers?: object, signal?: AbortSignal): Promise<GetIntentTransactionHistoryResponse>;
88
+ }
89
+ export declare enum TradeType {
90
+ EXACT_INPUT = "EXACT_INPUT",
91
+ EXACT_OUTPUT = "EXACT_OUTPUT"
92
+ }
93
+ export declare enum RouteProvider {
94
+ AUTO = "AUTO",
95
+ CCTP = "CCTP",
96
+ LIFI = "LIFI",
97
+ RELAY = "RELAY",
98
+ SUSHI = "SUSHI",
99
+ WETH = "WETH",
100
+ ZEROX = "ZEROX"
101
+ }
102
+ export declare enum FundMethod {
103
+ WALLET = "WALLET",
104
+ DIRECT_TRANSFER = "DIRECT_TRANSFER",
105
+ ONRAMP_MESH = "ONRAMP_MESH",
106
+ ONRAMP_MELD = "ONRAMP_MELD"
107
+ }
108
+ export declare enum IntentProtocolVersion {
109
+ v1 = "v1",
110
+ v1_5 = "v1_5"
111
+ }
112
+ export declare enum IntentSource {
113
+ ORIGIN = "ORIGIN",
114
+ DESTINATION = "DESTINATION"
115
+ }
116
+ export declare enum IntentStatus {
117
+ QUOTED = "QUOTED",
118
+ COMMITTED = "COMMITTED",
119
+ EXECUTING = "EXECUTING",
120
+ FAILED = "FAILED",
121
+ SUCCEEDED = "SUCCEEDED",
122
+ ABORTED = "ABORTED",
123
+ REFUNDED = "REFUNDED"
124
+ }
125
+ export declare enum TransactionType {
126
+ UNKNOWN = "UNKNOWN",
127
+ DEPOSIT = "DEPOSIT",
128
+ ORIGIN = "ORIGIN",
129
+ DESTINATION = "DESTINATION",
130
+ ROUTE = "ROUTE",
131
+ REFUND = "REFUND"
132
+ }
133
+ export declare enum TransactionContext {
134
+ NONE = "NONE",
135
+ CCTPV2_MESSAGE = "CCTPV2_MESSAGE"
136
+ }
137
+ export declare enum TransactionStatus {
138
+ UNKNOWN = "UNKNOWN",
139
+ ON_HOLD = "ON_HOLD",
140
+ PENDING = "PENDING",
141
+ RELAYING = "RELAYING",
142
+ SENT = "SENT",
143
+ ERRORED = "ERRORED",
144
+ MINING = "MINING",
145
+ SUCCEEDED = "SUCCEEDED",
146
+ FAILED = "FAILED",
147
+ ABORTED = "ABORTED",
148
+ REVERTED = "REVERTED"
149
+ }
150
+ export declare enum ChainGasUsageStatus {
151
+ NORMAL = "NORMAL",
152
+ BUSY = "BUSY",
153
+ VERY_BUSY = "VERY_BUSY"
154
+ }
155
+ export declare enum CCTPTransferStatus {
156
+ UNKNOWN = "UNKNOWN",
157
+ ON_HOLD = "ON_HOLD",
158
+ PENDING = "PENDING",
159
+ FETCHING = "FETCHING",
160
+ COMPLETE = "COMPLETE",
161
+ FAILED = "FAILED"
162
+ }
163
+ export declare enum RelayTransferStatus {
164
+ UNKNOWN = "UNKNOWN",
165
+ ON_HOLD = "ON_HOLD",
166
+ PENDING = "PENDING",
167
+ FETCHING = "FETCHING",
168
+ COMPLETE = "COMPLETE",
169
+ REFUNDED = "REFUNDED",
170
+ FAILED = "FAILED"
171
+ }
172
+ export interface QuoteIntentRequest {
173
+ ownerAddress: string;
174
+ originChainId: number;
175
+ originTokenAddress: string;
176
+ destinationChainId: number;
177
+ destinationTokenAddress: string;
178
+ destinationToAddress?: string;
179
+ destinationApproveAddress?: string;
180
+ destinationCallData?: string;
181
+ destinationCallValue?: bigint;
182
+ originTokenAmount?: bigint;
183
+ destinationTokenAmount?: bigint;
184
+ tradeType?: TradeType;
185
+ fundMethod?: FundMethod;
186
+ onlyNativeGasFee?: boolean;
187
+ options?: QuoteIntentRequestOptions;
188
+ }
189
+ export interface QuoteIntentRequestOptions {
190
+ swapProvider?: RouteProvider;
191
+ bridgeProvider?: RouteProvider;
192
+ slippageTolerance?: number;
193
+ trailsAddressOverrides?: TrailsAddressOverrides;
194
+ }
195
+ export interface PassthroughInfo {
196
+ eligible: boolean;
197
+ passthroughTransaction?: PassThroughTransaction;
198
+ transactionStates?: Array<TransactionStateInfo>;
199
+ }
200
+ export interface Intent {
201
+ intentId: string;
202
+ status: IntentStatus;
203
+ quoteRequest: QuoteIntentRequest;
204
+ ownerAddress: string;
205
+ originChainId: number;
206
+ destinationChainId: number;
207
+ originIntentAddress: string;
208
+ destinationIntentAddress?: string;
209
+ salt: bigint;
210
+ depositTransaction: DepositTransaction;
211
+ passthrough?: boolean;
212
+ originCalls: IntentCalls;
213
+ destinationCalls?: IntentCalls;
214
+ originPrecondition: TransactionPrecondition;
215
+ destinationPrecondition?: TransactionPrecondition;
216
+ originMetaTxn: MetaTxn;
217
+ destinationMetaTxn?: MetaTxn;
218
+ quote: IntentProviderQuote;
219
+ fees: IntentFees;
220
+ trailsVersion: string;
221
+ intentProtocolVersion?: IntentProtocolVersion;
222
+ trailsContracts: TrailsContracts;
223
+ expiresAt: string;
224
+ updatedAt?: string;
225
+ createdAt?: string;
226
+ }
227
+ export interface DepositTransaction {
228
+ toAddress: string;
229
+ tokenAddress: string;
230
+ decimals?: number;
231
+ amount: bigint;
232
+ chainId: number;
233
+ to: string;
234
+ data: string;
235
+ value: bigint;
236
+ }
237
+ export interface PassThroughTransaction {
238
+ toAddress: string;
239
+ tokenAddress: string;
240
+ decimals?: number;
241
+ amount: bigint;
242
+ chainId: number;
243
+ to: string;
244
+ data: string;
245
+ value: bigint;
246
+ }
247
+ export interface TransactionStateInfo {
248
+ id: string;
249
+ label: string;
250
+ chainId: number;
251
+ }
252
+ export interface IntentCalls {
253
+ chainId: number;
254
+ space?: bigint;
255
+ nonce?: bigint;
256
+ calls: Array<TransactionCall>;
257
+ }
258
+ export interface TransactionCall {
259
+ to: string;
260
+ value?: bigint;
261
+ data?: string;
262
+ gasLimit?: bigint;
263
+ delegateCall?: boolean;
264
+ onlyFallback?: boolean;
265
+ behaviorOnError?: number;
266
+ }
267
+ export interface TransactionPrecondition {
268
+ type: string;
269
+ chainId: number;
270
+ ownerAddress: string;
271
+ tokenAddress: string;
272
+ minAmount: bigint;
273
+ }
274
+ export interface MetaTxn {
275
+ id: string;
276
+ chainId: number;
277
+ walletAddress: string;
278
+ contract: string;
279
+ input: string;
280
+ }
281
+ export interface IntentHistory {
282
+ intentId: string;
283
+ status: IntentStatus;
284
+ expiresAt: string;
285
+ updatedAt?: string;
286
+ createdAt?: string;
287
+ receipt: IntentReceipt;
288
+ }
289
+ export interface IntentReceiptSummary {
290
+ intentId: string;
291
+ status: IntentStatus;
292
+ ownerAddress: string;
293
+ originChainId: number;
294
+ destinationChainId: number;
295
+ tradeType: TradeType;
296
+ routeProviders: Array<RouteProvider>;
297
+ originIntentAddress: string;
298
+ originTokenAddress: string;
299
+ originTokenAmount: bigint;
300
+ originTokenMetadata: TokenMetadata;
301
+ destinationIntentAddress: string;
302
+ destinationTokenAddress?: string;
303
+ destinationTokenAmount?: bigint;
304
+ destinationToAddress?: string;
305
+ destinationTokenMetadata: TokenMetadata;
306
+ destinationHasCallData: boolean;
307
+ destinationHasCallValue: boolean;
308
+ memo?: string;
309
+ createdAt: string;
310
+ expiresAt: string;
311
+ startedAt?: string;
312
+ finishedAt?: string;
313
+ }
314
+ export interface IntentReceipt {
315
+ intentId: string;
316
+ status: IntentStatus;
317
+ ownerAddress: string;
318
+ originChainId: number;
319
+ destinationChainId: number;
320
+ depositTransaction: IntentTransaction;
321
+ originTransaction: IntentTransaction;
322
+ destinationTransaction?: IntentTransaction;
323
+ refundTransaction?: IntentTransaction;
324
+ summary: IntentReceiptSummary;
325
+ updatedAt?: string;
326
+ createdAt?: string;
327
+ }
328
+ export interface IntentTransaction {
329
+ intentId: string;
330
+ status: TransactionStatus;
331
+ statusReason?: string;
332
+ chainId: number;
333
+ type: TransactionType;
334
+ context: TransactionContext;
335
+ fromAddress: string;
336
+ toAddress: string;
337
+ tokenAddress: string;
338
+ tokenAmount: bigint;
339
+ metaTxnId?: string;
340
+ metaTxnFeeQuote?: string;
341
+ precondition?: TransactionPrecondition;
342
+ depositIntentEntry?: DepositIntentEntry;
343
+ txnHash?: string;
344
+ txnMinedAt?: string;
345
+ updatedAt?: string;
346
+ createdAt?: string;
347
+ }
348
+ export interface PriceImpact {
349
+ priceImpact: number;
350
+ priceImpactUsd: number;
351
+ }
352
+ export interface PriceImpactDetails {
353
+ executionPriceImpact: PriceImpact;
354
+ marketPriceImpact: PriceImpact;
355
+ providerFeesPriceImpact: PriceImpact;
356
+ trailsFeesPriceImpact: PriceImpact;
357
+ netPriceImpact: PriceImpact;
358
+ }
359
+ export interface IntentProviderQuote {
360
+ routeProviders: Array<RouteProvider>;
361
+ routeProvidersRequestIds: Array<string>;
362
+ routeProvidersFeeUsd: Array<number>;
363
+ fromAmount: bigint;
364
+ fromAmountMin: bigint;
365
+ fromAmountUsd: number;
366
+ fromAmountMinUsd: number;
367
+ toAmount: bigint;
368
+ toAmountMin: bigint;
369
+ toAmountUsd: number;
370
+ toAmountMinUsd: number;
371
+ maxSlippage: number;
372
+ priceImpact: number;
373
+ priceImpactUsd: number;
374
+ priceImpactDetails: PriceImpactDetails;
375
+ }
376
+ export interface IntentFees {
377
+ originGas: IntentTransactionGasFee;
378
+ destinationGas?: IntentTransactionGasFee;
379
+ provider: IntentProviderFees;
380
+ feeTokenAddress: string;
381
+ feeTokenAmount: bigint;
382
+ feeTokenUsd: number;
383
+ feeTokenTotal: bigint;
384
+ gasFeeTotal: bigint;
385
+ gasFeeUsd: number;
386
+ trailsFeeTotal: bigint;
387
+ trailsFeeUsd: number;
388
+ collectorFeeTotal: bigint;
389
+ collectorFeeUsd: number;
390
+ providerFeeTotal: bigint;
391
+ providerFeeUsd: number;
392
+ totalFeeAmount: bigint;
393
+ totalFeeUsd: number;
394
+ }
395
+ export interface IntentProviderFees {
396
+ quoteProvider: string;
397
+ quoteProviderFee: bigint;
398
+ quoteProviderFeeUsd: number;
399
+ trailsFee: bigint;
400
+ trailsFeeUsd: number;
401
+ quoteProviderWithTrailsFee: bigint;
402
+ providerWithTrailsFeeUsd: number;
403
+ totalFeeAmount: bigint;
404
+ totalFeeUsd: number;
405
+ }
406
+ export interface IntentSummary {
407
+ intentId: string;
408
+ status: IntentStatus;
409
+ ownerAddress: string;
410
+ originChainId: number;
411
+ destinationChainId: number;
412
+ originIntentAddress: string;
413
+ destinationIntentAddress: string;
414
+ depositTransactionHash?: string;
415
+ depositTransactionStatus: TransactionStatus;
416
+ originTransactionHash?: string;
417
+ originTransactionStatus: TransactionStatus;
418
+ destinationTransactionHash?: string;
419
+ destinationTransactionStatus: TransactionStatus;
420
+ originTokenAddress: string;
421
+ originTokenAmount: bigint;
422
+ originTokenMetadata: TokenMetadata;
423
+ destinationTokenAddress: string;
424
+ destinationTokenAmount: bigint;
425
+ destinationTokenMetadata: TokenMetadata;
426
+ destinationToAddress: string;
427
+ expiresAt: string;
428
+ updatedAt?: string;
429
+ createdAt: string;
430
+ }
431
+ export interface IntentTransactionGasFee {
432
+ chainId: number;
433
+ totalGasLimit: bigint;
434
+ gasPrice: bigint;
435
+ nativeTokenSymbol: string;
436
+ nativeTokenPriceUsd?: number;
437
+ chainGasUsageStatus: ChainGasUsageStatus;
438
+ totalFeeAmount: bigint;
439
+ totalFeeUsd: string;
440
+ metaTxnFeeDetails: MetaTxnFeeDetails;
441
+ metaTxnGasQuote: string;
442
+ }
443
+ export interface MetaTxnFeeDetails {
444
+ metaTxnId: string;
445
+ estimatedGasLimit: bigint;
446
+ feeNative: bigint;
447
+ }
448
+ export interface ChainMetadata {
449
+ chainId: number;
450
+ name: string;
451
+ logoUri?: string;
452
+ testnet?: boolean;
453
+ }
454
+ export interface TokenMetadata {
455
+ chainId: number;
456
+ tokenAddress: string;
457
+ name: string;
458
+ symbol: string;
459
+ decimals?: number;
460
+ logoUri?: string;
461
+ }
462
+ export interface Token {
463
+ chainId: number;
464
+ tokenAddress: string;
465
+ tokenSymbol?: string;
466
+ }
467
+ export interface TokenPrice {
468
+ token: Token;
469
+ priceUsd?: number;
470
+ updatedAt: string;
471
+ }
472
+ export interface ExchangeRate {
473
+ name: string;
474
+ symbol: string;
475
+ value: number;
476
+ vsCurrency: string;
477
+ currencyType: string;
478
+ }
479
+ export interface CCTPTransfer {
480
+ id: number;
481
+ intentId: string;
482
+ originChainId: number;
483
+ destinationChainId: number;
484
+ originTxnId: number;
485
+ originTxnHash: string;
486
+ destinationTxnId: number;
487
+ message: string;
488
+ attestation: string;
489
+ status: number;
490
+ statusReason?: string;
491
+ createdAt: string;
492
+ updatedAt: string;
493
+ }
494
+ export interface RelayTransfer {
495
+ id: number;
496
+ intentId: string;
497
+ originChainId: number;
498
+ destinationChainId: number;
499
+ originTxnId: number;
500
+ originTxnHash: string;
501
+ destinationTxnId: number;
502
+ destinationTxnHash: string;
503
+ status: number;
504
+ statusReason?: string;
505
+ createdAt: string;
506
+ updatedAt: string;
507
+ }
508
+ export interface GasFeeOptions {
509
+ gasEstimate: GasEstimate;
510
+ feeOptions: Array<FeeOption>;
511
+ expiresAt: string;
512
+ feeCollectorAddress: string;
513
+ }
514
+ export interface GasEstimate {
515
+ totalGas: number;
516
+ gasPrice: string;
517
+ nativeCost: string;
518
+ nativeCostUsd: number;
519
+ }
520
+ export interface FeeOption {
521
+ tokenAddress: string;
522
+ tokenSymbol: string;
523
+ tokenDecimals: number;
524
+ amount: bigint;
525
+ amountUsd: number;
526
+ feeCollectorAddress: string;
527
+ is2612: boolean;
528
+ isPassthroughEligible?: boolean;
529
+ }
530
+ export interface DepositSignature {
531
+ permitSignature?: string;
532
+ permitDeadline?: number;
533
+ permitAmount?: bigint;
534
+ selectedGasFeeOption: FeeOption;
535
+ deadline: number;
536
+ }
537
+ export interface DepositIntentEntry {
538
+ permitSignature?: string;
539
+ permitDeadline?: number;
540
+ permitAmount?: bigint;
541
+ feeAmount: string;
542
+ feeToken: string;
543
+ feeCollector: string;
544
+ deadline: number;
545
+ }
546
+ export interface TrailsAddressOverrides {
547
+ sequenceWalletFactoryAddress?: string;
548
+ sequenceWalletMainModuleAddress?: string;
549
+ sequenceWalletMainModuleUpgradableAddress?: string;
550
+ sequenceWalletGuestModuleAddress?: string;
551
+ sequenceWalletUtilsAddress?: string;
552
+ }
553
+ export interface TrailsContracts {
554
+ trailsUtilsAddress: string;
555
+ }
556
+ export interface ChainInfo {
557
+ id: number;
558
+ name: string;
559
+ tokenName: string;
560
+ tokenSymbol: string;
561
+ tokenDecimals: number;
562
+ isTestnet: boolean;
563
+ supportsBridging: boolean;
564
+ logoUri?: string;
565
+ blockExplorerUrl?: string;
566
+ }
567
+ export interface TokenInfo {
568
+ chainId: number;
569
+ address: string;
570
+ name: string;
571
+ symbol: string;
572
+ decimals: number;
573
+ supportsBridging?: boolean;
574
+ logoUri?: string;
575
+ featured: boolean;
576
+ }
577
+ export interface EarnPool {
578
+ id: string;
579
+ name: string;
580
+ protocol: string;
581
+ chainId: number;
582
+ apy: number;
583
+ tvl: number;
584
+ token: PoolTokenInfo;
585
+ depositAddress: string;
586
+ isActive: boolean;
587
+ poolUrl?: string;
588
+ protocolUrl?: string;
589
+ wrappedTokenGatewayAddress?: string;
590
+ }
591
+ export interface PoolTokenInfo {
592
+ symbol: string;
593
+ name: string;
594
+ address: string;
595
+ decimals: number;
596
+ logoUrl?: string;
597
+ }
598
+ export interface CountryRegion {
599
+ regionCode: string;
600
+ name: string;
601
+ }
602
+ export interface Country {
603
+ countryCode: string;
604
+ name: string;
605
+ flag: string;
606
+ flagImageUrl: string;
607
+ regions?: Array<CountryRegion>;
608
+ }
609
+ export interface FiatCurrency {
610
+ code: string;
611
+ symbol: string;
612
+ name: string;
613
+ flag: string;
614
+ decimals: number;
615
+ }
616
+ export interface MeldQuote {
617
+ transactionType: string;
618
+ sourceAmount: number;
619
+ sourceAmountWithoutFees: number;
620
+ fiatAmountWithoutFees: number;
621
+ destinationAmountWithoutFees?: number;
622
+ sourceCurrencyCode: string;
623
+ countryCode: string;
624
+ totalFee: number;
625
+ networkFee: number;
626
+ transactionFee: number;
627
+ destinationAmount: number;
628
+ destinationCurrencyCode: string;
629
+ exchangeRate: number;
630
+ paymentMethodType: string;
631
+ customerScore: number;
632
+ serviceProvider: string;
633
+ institutionName?: string;
634
+ lowKyc?: boolean;
635
+ partnerFee: number;
636
+ }
637
+ export declare enum SortOrder {
638
+ DESC = "DESC",
639
+ ASC = "ASC"
640
+ }
641
+ export interface RuntimeStatus {
642
+ healthOK: boolean;
643
+ version: string;
644
+ branch: string;
645
+ commitHash: string;
646
+ startTime: string;
647
+ uptime: string;
648
+ hostname: string;
649
+ runnables: any;
650
+ services: Array<ServiceStatus>;
651
+ }
652
+ export interface ServiceStatus {
653
+ name: string;
654
+ healthy: boolean;
655
+ error?: string;
656
+ latency: string;
657
+ }
658
+ export interface QuoteIntentResponse {
659
+ intent: Intent;
660
+ gasFeeOptions: GasFeeOptions;
661
+ transactionStates?: Array<TransactionStateInfo>;
662
+ passthrough?: PassthroughInfo;
663
+ }
664
+ export interface CommitIntentRequest {
665
+ intent: Intent;
666
+ }
667
+ export interface CommitIntentResponse {
668
+ intentId: string;
669
+ }
670
+ export interface ExecuteIntentRequest {
671
+ intentId: string;
672
+ depositTransactionHash?: string;
673
+ depositSignature?: DepositSignature;
674
+ }
675
+ export interface ExecuteIntentResponse {
676
+ intentId: string;
677
+ intentStatus: IntentStatus;
678
+ }
679
+ export interface GetIntentReceiptRequest {
680
+ intentId: string;
681
+ }
682
+ export interface GetIntentReceiptResponse {
683
+ intentReceipt: IntentReceipt;
684
+ }
685
+ export interface WaitIntentReceiptRequest {
686
+ intentId: string;
687
+ lastReceiptStates?: Array<TransactionStatus>;
688
+ }
689
+ export interface WaitIntentReceiptResponse {
690
+ intentReceipt: IntentReceipt;
691
+ receiptStates: Array<TransactionStatus>;
692
+ done: boolean;
693
+ }
694
+ export interface GetIntentRequest {
695
+ intentId: string;
696
+ }
697
+ export interface GetIntentResponse {
698
+ intent: Intent;
699
+ }
700
+ export interface SearchIntentsRequest {
701
+ byIntentId?: string;
702
+ byProjectId?: number;
703
+ byTransactionHash?: string;
704
+ byOwnerAddress?: string;
705
+ byOriginIntentAddress?: string;
706
+ byDestinationIntentAddress?: string;
707
+ byQueryString?: string;
708
+ }
709
+ export interface SearchIntentsResponse {
710
+ intents: Array<Intent>;
711
+ }
712
+ export interface GetIntentConfigRequest {
713
+ intentId: string;
714
+ intentSource: IntentSource;
715
+ }
716
+ export interface GetIntentConfigResponse {
717
+ address: string;
718
+ imageHash: string;
719
+ walletConfiguration: any;
720
+ }
721
+ export interface GetIntentHistoryRequest {
722
+ page?: Page;
723
+ byProjectId?: number;
724
+ byOwnerAddress?: string;
725
+ }
726
+ export interface GetIntentHistoryResponse {
727
+ intents: Array<IntentHistory>;
728
+ nextPage?: Page;
729
+ }
730
+ export interface AbortIntentRequest {
731
+ intentId: string;
732
+ chainId: number;
733
+ abortTransactionHash: string;
734
+ }
735
+ export interface AbortIntentResponse {
736
+ intentId: string;
737
+ status: IntentStatus;
738
+ }
739
+ export interface GetTokenPricesRequest {
740
+ tokens: Array<Token>;
741
+ }
742
+ export interface GetTokenPricesResponse {
743
+ tokenPrices: Array<TokenPrice>;
744
+ }
745
+ export interface GetChainsRequest {
746
+ routeProvider?: string;
747
+ }
748
+ export interface GetChainsResponse {
749
+ chains: Array<ChainInfo>;
750
+ }
751
+ export interface GetExactOutputRoutesRequest {
752
+ destinationChainId: number;
753
+ destinationTokenAddress: string;
754
+ originChainId?: number;
755
+ originTokenAddress?: string;
756
+ ownerAddress?: string;
757
+ }
758
+ export interface GetExactOutputRoutesResponse {
759
+ tokens: Array<TokenInfo>;
760
+ }
761
+ export interface GetExactInputRoutesRequest {
762
+ originChainId: number;
763
+ originTokenAddress: string;
764
+ destinationChainId?: number;
765
+ destinationTokenAddress?: string;
766
+ }
767
+ export interface GetExactInputRoutesResponse {
768
+ tokens: Array<TokenInfo>;
769
+ }
770
+ export interface GetTokenListRequest {
771
+ chainIds: Array<number>;
772
+ searchQuery?: string;
773
+ limit?: number;
774
+ tokenAddress?: string;
775
+ includeAllListed?: boolean;
776
+ includeExternal?: boolean;
777
+ excludeTokens?: Array<string>;
778
+ }
779
+ export interface GetTokenListResponse {
780
+ tokens: Array<TokenInfo>;
781
+ }
782
+ export interface GetEarnPoolsRequest {
783
+ chainIds?: Array<number>;
784
+ protocols?: Array<string>;
785
+ minTvl?: number;
786
+ maxApy?: number;
787
+ }
788
+ export interface GetEarnPoolsResponse {
789
+ pools: Array<EarnPool>;
790
+ timestamp: string;
791
+ cached: boolean;
792
+ }
793
+ export interface Page {
794
+ column?: string;
795
+ before?: number;
796
+ after?: number;
797
+ sort?: Array<SortBy>;
798
+ pageSize?: number;
799
+ more?: boolean;
800
+ }
801
+ export interface SortBy {
802
+ column: string;
803
+ order: SortOrder;
804
+ }
805
+ export interface GetIntentTransactionHistoryRequest {
806
+ page?: Page;
807
+ byProjectId?: number;
808
+ byOwnerAddress?: string;
809
+ }
810
+ export interface GetIntentTransactionHistoryResponse {
811
+ intents: Array<IntentSummary>;
812
+ nextPage?: Page;
813
+ }
814
+ export interface PingRequest {
815
+ }
816
+ export interface PingResponse {
817
+ version: string;
818
+ }
819
+ export interface RuntimeStatusRequest {
820
+ }
821
+ export interface RuntimeStatusResponse {
822
+ status: RuntimeStatus;
823
+ }
824
+ export interface ClockRequest {
825
+ }
826
+ export interface ClockResponse {
827
+ serverTime: string;
828
+ }
829
+ export interface GetExchangeRateRequest {
830
+ toCurrency: string;
831
+ }
832
+ export interface GetExchangeRateResponse {
833
+ exchangeRate: ExchangeRate;
834
+ }
835
+ export interface GetCountryListRequest {
836
+ }
837
+ export interface GetCountryListResponse {
838
+ countries: Array<Country>;
839
+ }
840
+ export interface GetTrailsContractsRequest {
841
+ }
842
+ export interface GetTrailsContractsResponse {
843
+ TrailsContracts: TrailsContracts;
844
+ }
845
+ export interface GetSupportedIntentProtocolVersionsRequest {
846
+ }
847
+ export interface GetSupportedIntentProtocolVersionsResponse {
848
+ versions: Array<IntentProtocolVersion>;
849
+ }
850
+ export interface GetFiatCurrencyListRequest {
851
+ }
852
+ export interface GetFiatCurrencyListResponse {
853
+ currencies: Array<FiatCurrency>;
854
+ }
855
+ export declare class Trails implements TrailsClient {
856
+ protected hostname: string;
857
+ protected fetch: Fetch;
858
+ protected path: string;
859
+ constructor(hostname: string, fetch: Fetch);
860
+ private url;
861
+ queryKey: {
862
+ ping: () => readonly ["Trails", "ping"];
863
+ runtimeStatus: () => readonly ["Trails", "runtimeStatus"];
864
+ clock: () => readonly ["Trails", "clock"];
865
+ quoteIntent: (req: QuoteIntentRequest) => readonly ["Trails", "quoteIntent", QuoteIntentRequest];
866
+ commitIntent: (req: CommitIntentRequest) => readonly ["Trails", "commitIntent", CommitIntentRequest];
867
+ executeIntent: (req: ExecuteIntentRequest) => readonly ["Trails", "executeIntent", ExecuteIntentRequest];
868
+ waitIntentReceipt: (req: WaitIntentReceiptRequest) => readonly ["Trails", "waitIntentReceipt", WaitIntentReceiptRequest];
869
+ getIntentReceipt: (req: GetIntentReceiptRequest) => readonly ["Trails", "getIntentReceipt", GetIntentReceiptRequest];
870
+ getIntent: (req: GetIntentRequest) => readonly ["Trails", "getIntent", GetIntentRequest];
871
+ searchIntents: (req: SearchIntentsRequest) => readonly ["Trails", "searchIntents", SearchIntentsRequest];
872
+ getIntentConfig: (req: GetIntentConfigRequest) => readonly ["Trails", "getIntentConfig", GetIntentConfigRequest];
873
+ getIntentHistory: (req: GetIntentHistoryRequest) => readonly ["Trails", "getIntentHistory", GetIntentHistoryRequest];
874
+ abortIntent: (req: AbortIntentRequest) => readonly ["Trails", "abortIntent", AbortIntentRequest];
875
+ getChains: (req: GetChainsRequest) => readonly ["Trails", "getChains", GetChainsRequest];
876
+ getExactOutputRoutes: (req: GetExactOutputRoutesRequest) => readonly ["Trails", "getExactOutputRoutes", GetExactOutputRoutesRequest];
877
+ getExactInputRoutes: (req: GetExactInputRoutesRequest) => readonly ["Trails", "getExactInputRoutes", GetExactInputRoutesRequest];
878
+ getTokenList: (req: GetTokenListRequest) => readonly ["Trails", "getTokenList", GetTokenListRequest];
879
+ getTokenPrices: (req: GetTokenPricesRequest) => readonly ["Trails", "getTokenPrices", GetTokenPricesRequest];
880
+ getExchangeRate: (req: GetExchangeRateRequest) => readonly ["Trails", "getExchangeRate", GetExchangeRateRequest];
881
+ getCountryList: () => readonly ["Trails", "getCountryList"];
882
+ getTrailsContracts: () => readonly ["Trails", "getTrailsContracts"];
883
+ getSupportedIntentProtocolVersions: () => readonly ["Trails", "getSupportedIntentProtocolVersions"];
884
+ getEarnPools: (req: GetEarnPoolsRequest) => readonly ["Trails", "getEarnPools", GetEarnPoolsRequest];
885
+ getFiatCurrencyList: () => readonly ["Trails", "getFiatCurrencyList"];
886
+ getIntentTransactionHistory: (req: GetIntentTransactionHistoryRequest) => readonly ["Trails", "getIntentTransactionHistory", GetIntentTransactionHistoryRequest];
887
+ };
888
+ ping: (headers?: object, signal?: AbortSignal) => Promise<PingResponse>;
889
+ runtimeStatus: (headers?: object, signal?: AbortSignal) => Promise<RuntimeStatusResponse>;
890
+ clock: (headers?: object, signal?: AbortSignal) => Promise<ClockResponse>;
891
+ quoteIntent: (req: QuoteIntentRequest, headers?: object, signal?: AbortSignal) => Promise<QuoteIntentResponse>;
892
+ commitIntent: (req: CommitIntentRequest, headers?: object, signal?: AbortSignal) => Promise<CommitIntentResponse>;
893
+ executeIntent: (req: ExecuteIntentRequest, headers?: object, signal?: AbortSignal) => Promise<ExecuteIntentResponse>;
894
+ waitIntentReceipt: (req: WaitIntentReceiptRequest, headers?: object, signal?: AbortSignal) => Promise<WaitIntentReceiptResponse>;
895
+ getIntentReceipt: (req: GetIntentReceiptRequest, headers?: object, signal?: AbortSignal) => Promise<GetIntentReceiptResponse>;
896
+ getIntent: (req: GetIntentRequest, headers?: object, signal?: AbortSignal) => Promise<GetIntentResponse>;
897
+ searchIntents: (req: SearchIntentsRequest, headers?: object, signal?: AbortSignal) => Promise<SearchIntentsResponse>;
898
+ getIntentConfig: (req: GetIntentConfigRequest, headers?: object, signal?: AbortSignal) => Promise<GetIntentConfigResponse>;
899
+ getIntentHistory: (req: GetIntentHistoryRequest, headers?: object, signal?: AbortSignal) => Promise<GetIntentHistoryResponse>;
900
+ abortIntent: (req: AbortIntentRequest, headers?: object, signal?: AbortSignal) => Promise<AbortIntentResponse>;
901
+ getChains: (req: GetChainsRequest, headers?: object, signal?: AbortSignal) => Promise<GetChainsResponse>;
902
+ getExactOutputRoutes: (req: GetExactOutputRoutesRequest, headers?: object, signal?: AbortSignal) => Promise<GetExactOutputRoutesResponse>;
903
+ getExactInputRoutes: (req: GetExactInputRoutesRequest, headers?: object, signal?: AbortSignal) => Promise<GetExactInputRoutesResponse>;
904
+ getTokenList: (req: GetTokenListRequest, headers?: object, signal?: AbortSignal) => Promise<GetTokenListResponse>;
905
+ getTokenPrices: (req: GetTokenPricesRequest, headers?: object, signal?: AbortSignal) => Promise<GetTokenPricesResponse>;
906
+ getExchangeRate: (req: GetExchangeRateRequest, headers?: object, signal?: AbortSignal) => Promise<GetExchangeRateResponse>;
907
+ getCountryList: (headers?: object, signal?: AbortSignal) => Promise<GetCountryListResponse>;
908
+ getTrailsContracts: (headers?: object, signal?: AbortSignal) => Promise<GetTrailsContractsResponse>;
909
+ getSupportedIntentProtocolVersions: (headers?: object, signal?: AbortSignal) => Promise<GetSupportedIntentProtocolVersionsResponse>;
910
+ getEarnPools: (req: GetEarnPoolsRequest, headers?: object, signal?: AbortSignal) => Promise<GetEarnPoolsResponse>;
911
+ getFiatCurrencyList: (headers?: object, signal?: AbortSignal) => Promise<GetFiatCurrencyListResponse>;
912
+ getIntentTransactionHistory: (req: GetIntentTransactionHistoryRequest, headers?: object, signal?: AbortSignal) => Promise<GetIntentTransactionHistoryResponse>;
913
+ }
914
+ export type Fetch = (input: RequestInfo, init?: RequestInit) => Promise<Response>;
915
+ export declare const JsonEncode: <T = any>(obj: T) => string;
916
+ export declare const JsonDecode: <T = any>(data: string | any, typ?: string) => T;
917
+ type WebrpcErrorParams = {
918
+ name?: string;
919
+ code?: number;
920
+ message?: string;
921
+ status?: number;
922
+ cause?: string;
923
+ };
924
+ export declare class WebrpcError extends Error {
925
+ code: number;
926
+ status: number;
927
+ constructor(error?: WebrpcErrorParams);
928
+ static new(payload: any): WebrpcError;
929
+ }
930
+ export declare class WebrpcEndpointError extends WebrpcError {
931
+ constructor(error?: WebrpcErrorParams);
932
+ }
933
+ export declare class WebrpcRequestFailedError extends WebrpcError {
934
+ constructor(error?: WebrpcErrorParams);
935
+ }
936
+ export declare class WebrpcBadRouteError extends WebrpcError {
937
+ constructor(error?: WebrpcErrorParams);
938
+ }
939
+ export declare class WebrpcBadMethodError extends WebrpcError {
940
+ constructor(error?: WebrpcErrorParams);
941
+ }
942
+ export declare class WebrpcBadRequestError extends WebrpcError {
943
+ constructor(error?: WebrpcErrorParams);
944
+ }
945
+ export declare class WebrpcBadResponseError extends WebrpcError {
946
+ constructor(error?: WebrpcErrorParams);
947
+ }
948
+ export declare class WebrpcServerPanicError extends WebrpcError {
949
+ constructor(error?: WebrpcErrorParams);
950
+ }
951
+ export declare class WebrpcInternalErrorError extends WebrpcError {
952
+ constructor(error?: WebrpcErrorParams);
953
+ }
954
+ export declare class WebrpcClientAbortedError extends WebrpcError {
955
+ constructor(error?: WebrpcErrorParams);
956
+ }
957
+ export declare class WebrpcStreamLostError extends WebrpcError {
958
+ constructor(error?: WebrpcErrorParams);
959
+ }
960
+ export declare class WebrpcStreamFinishedError extends WebrpcError {
961
+ constructor(error?: WebrpcErrorParams);
962
+ }
963
+ export declare class UnauthorizedError extends WebrpcError {
964
+ constructor(error?: WebrpcErrorParams);
965
+ }
966
+ export declare class PermissionDeniedError extends WebrpcError {
967
+ constructor(error?: WebrpcErrorParams);
968
+ }
969
+ export declare class SessionExpiredError extends WebrpcError {
970
+ constructor(error?: WebrpcErrorParams);
971
+ }
972
+ export declare class MethodNotFoundError extends WebrpcError {
973
+ constructor(error?: WebrpcErrorParams);
974
+ }
975
+ export declare class RequestConflictError extends WebrpcError {
976
+ constructor(error?: WebrpcErrorParams);
977
+ }
978
+ export declare class AbortedError extends WebrpcError {
979
+ constructor(error?: WebrpcErrorParams);
980
+ }
981
+ export declare class GeoblockedError extends WebrpcError {
982
+ constructor(error?: WebrpcErrorParams);
983
+ }
984
+ export declare class RateLimitedError extends WebrpcError {
985
+ constructor(error?: WebrpcErrorParams);
986
+ }
987
+ export declare class ProjectNotFoundError extends WebrpcError {
988
+ constructor(error?: WebrpcErrorParams);
989
+ }
990
+ export declare class AccessKeyNotFoundError extends WebrpcError {
991
+ constructor(error?: WebrpcErrorParams);
992
+ }
993
+ export declare class AccessKeyMismatchError extends WebrpcError {
994
+ constructor(error?: WebrpcErrorParams);
995
+ }
996
+ export declare class InvalidOriginError extends WebrpcError {
997
+ constructor(error?: WebrpcErrorParams);
998
+ }
999
+ export declare class InvalidServiceError extends WebrpcError {
1000
+ constructor(error?: WebrpcErrorParams);
1001
+ }
1002
+ export declare class UnauthorizedUserError extends WebrpcError {
1003
+ constructor(error?: WebrpcErrorParams);
1004
+ }
1005
+ export declare class QuotaExceededError extends WebrpcError {
1006
+ constructor(error?: WebrpcErrorParams);
1007
+ }
1008
+ export declare class QuotaRateLimitError extends WebrpcError {
1009
+ constructor(error?: WebrpcErrorParams);
1010
+ }
1011
+ export declare class NoDefaultKeyError extends WebrpcError {
1012
+ constructor(error?: WebrpcErrorParams);
1013
+ }
1014
+ export declare class MaxAccessKeysError extends WebrpcError {
1015
+ constructor(error?: WebrpcErrorParams);
1016
+ }
1017
+ export declare class AtLeastOneKeyError extends WebrpcError {
1018
+ constructor(error?: WebrpcErrorParams);
1019
+ }
1020
+ export declare class TimeoutError extends WebrpcError {
1021
+ constructor(error?: WebrpcErrorParams);
1022
+ }
1023
+ export declare class InvalidArgumentError extends WebrpcError {
1024
+ constructor(error?: WebrpcErrorParams);
1025
+ }
1026
+ export declare class UnexpectedError extends WebrpcError {
1027
+ constructor(error?: WebrpcErrorParams);
1028
+ }
1029
+ export declare class UnavailableError extends WebrpcError {
1030
+ constructor(error?: WebrpcErrorParams);
1031
+ }
1032
+ export declare class QueryFailedError extends WebrpcError {
1033
+ constructor(error?: WebrpcErrorParams);
1034
+ }
1035
+ export declare class IntentStatusError extends WebrpcError {
1036
+ constructor(error?: WebrpcErrorParams);
1037
+ }
1038
+ export declare class NotFoundError extends WebrpcError {
1039
+ constructor(error?: WebrpcErrorParams);
1040
+ }
1041
+ export declare class UnsupportedNetworkError extends WebrpcError {
1042
+ constructor(error?: WebrpcErrorParams);
1043
+ }
1044
+ export declare class ClientOutdatedError extends WebrpcError {
1045
+ constructor(error?: WebrpcErrorParams);
1046
+ }
1047
+ export declare class IntentsSkippedError extends WebrpcError {
1048
+ constructor(error?: WebrpcErrorParams);
1049
+ }
1050
+ export declare class QuoteExpiredError extends WebrpcError {
1051
+ constructor(error?: WebrpcErrorParams);
1052
+ }
1053
+ export declare class IntentsDisabledError extends WebrpcError {
1054
+ constructor(error?: WebrpcErrorParams);
1055
+ }
1056
+ export declare enum errors {
1057
+ WebrpcEndpoint = "WebrpcEndpoint",
1058
+ WebrpcRequestFailed = "WebrpcRequestFailed",
1059
+ WebrpcBadRoute = "WebrpcBadRoute",
1060
+ WebrpcBadMethod = "WebrpcBadMethod",
1061
+ WebrpcBadRequest = "WebrpcBadRequest",
1062
+ WebrpcBadResponse = "WebrpcBadResponse",
1063
+ WebrpcServerPanic = "WebrpcServerPanic",
1064
+ WebrpcInternalError = "WebrpcInternalError",
1065
+ WebrpcClientAborted = "WebrpcClientAborted",
1066
+ WebrpcStreamLost = "WebrpcStreamLost",
1067
+ WebrpcStreamFinished = "WebrpcStreamFinished",
1068
+ Unauthorized = "Unauthorized",
1069
+ PermissionDenied = "PermissionDenied",
1070
+ SessionExpired = "SessionExpired",
1071
+ MethodNotFound = "MethodNotFound",
1072
+ RequestConflict = "RequestConflict",
1073
+ Aborted = "Aborted",
1074
+ Geoblocked = "Geoblocked",
1075
+ RateLimited = "RateLimited",
1076
+ ProjectNotFound = "ProjectNotFound",
1077
+ AccessKeyNotFound = "AccessKeyNotFound",
1078
+ AccessKeyMismatch = "AccessKeyMismatch",
1079
+ InvalidOrigin = "InvalidOrigin",
1080
+ InvalidService = "InvalidService",
1081
+ UnauthorizedUser = "UnauthorizedUser",
1082
+ QuotaExceeded = "QuotaExceeded",
1083
+ QuotaRateLimit = "QuotaRateLimit",
1084
+ NoDefaultKey = "NoDefaultKey",
1085
+ MaxAccessKeys = "MaxAccessKeys",
1086
+ AtLeastOneKey = "AtLeastOneKey",
1087
+ Timeout = "Timeout",
1088
+ InvalidArgument = "InvalidArgument",
1089
+ Unexpected = "Unexpected",
1090
+ Unavailable = "Unavailable",
1091
+ QueryFailed = "QueryFailed",
1092
+ IntentStatus = "IntentStatus",
1093
+ NotFound = "NotFound",
1094
+ UnsupportedNetwork = "UnsupportedNetwork",
1095
+ ClientOutdated = "ClientOutdated",
1096
+ IntentsSkipped = "IntentsSkipped",
1097
+ QuoteExpired = "QuoteExpired",
1098
+ IntentsDisabled = "IntentsDisabled"
1099
+ }
1100
+ export declare enum WebrpcErrorCodes {
1101
+ WebrpcEndpoint = 0,
1102
+ WebrpcRequestFailed = -1,
1103
+ WebrpcBadRoute = -2,
1104
+ WebrpcBadMethod = -3,
1105
+ WebrpcBadRequest = -4,
1106
+ WebrpcBadResponse = -5,
1107
+ WebrpcServerPanic = -6,
1108
+ WebrpcInternalError = -7,
1109
+ WebrpcClientAborted = -8,
1110
+ WebrpcStreamLost = -9,
1111
+ WebrpcStreamFinished = -10,
1112
+ Unauthorized = 1000,
1113
+ PermissionDenied = 1001,
1114
+ SessionExpired = 1002,
1115
+ MethodNotFound = 1003,
1116
+ RequestConflict = 1004,
1117
+ Aborted = 1005,
1118
+ Geoblocked = 1006,
1119
+ RateLimited = 1007,
1120
+ ProjectNotFound = 1008,
1121
+ AccessKeyNotFound = 1101,
1122
+ AccessKeyMismatch = 1102,
1123
+ InvalidOrigin = 1103,
1124
+ InvalidService = 1104,
1125
+ UnauthorizedUser = 1105,
1126
+ QuotaExceeded = 1200,
1127
+ QuotaRateLimit = 1201,
1128
+ NoDefaultKey = 1300,
1129
+ MaxAccessKeys = 1301,
1130
+ AtLeastOneKey = 1302,
1131
+ Timeout = 1900,
1132
+ InvalidArgument = 2000,
1133
+ Unexpected = 2001,
1134
+ Unavailable = 2002,
1135
+ QueryFailed = 2003,
1136
+ IntentStatus = 2004,
1137
+ NotFound = 8000,
1138
+ UnsupportedNetwork = 8008,
1139
+ ClientOutdated = 8009,
1140
+ IntentsSkipped = 7000,
1141
+ QuoteExpired = 7001,
1142
+ IntentsDisabled = 9000
1143
+ }
1144
+ export declare const webrpcErrorByCode: {
1145
+ [code: number]: any;
1146
+ };
1147
+ export declare const WebrpcHeader = "Webrpc";
1148
+ export declare const WebrpcHeaderValue = "webrpc@v0.32.2;gen-typescript@v0.23.1;trails-api@v1-26.2.10-fcbe559";
1149
+ type WebrpcGenVersions = {
1150
+ WebrpcGenVersion: string;
1151
+ codeGenName: string;
1152
+ codeGenVersion: string;
1153
+ schemaName: string;
1154
+ schemaVersion: string;
1155
+ };
1156
+ export declare function VersionFromHeader(headers: Headers): WebrpcGenVersions;
1157
+ export {};
1158
+ //# sourceMappingURL=trails-api-v1_5.gen.d.ts.map