@relayprotocol/relay-sdk 2.4.0 → 2.4.2
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/_cjs/src/routes/index.js +1 -0
- package/_cjs/src/routes/index.js.map +1 -1
- package/_cjs/src/version.js +1 -1
- package/_cjs/tsconfig.build.tsbuildinfo +1 -1
- package/_esm/src/routes/index.js +1 -0
- package/_esm/src/routes/index.js.map +1 -1
- package/_esm/src/version.js +1 -1
- package/_esm/tsconfig.build.tsbuildinfo +1 -1
- package/_types/src/routes/index.d.ts.map +1 -1
- package/_types/src/types/api.d.ts +397 -7
- package/_types/src/types/api.d.ts.map +1 -1
- package/_types/src/version.d.ts +1 -1
- package/_types/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/readme.md +4 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/routes/index.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/routes/index.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,MAAM,UA0ClB,CAAC"}
|
|
@@ -374,7 +374,10 @@ export interface paths {
|
|
|
374
374
|
source?: string;
|
|
375
375
|
/** @description Address to send the refund to in the case of failure, if not specified then the receipient address or user address is used */
|
|
376
376
|
refundTo?: string;
|
|
377
|
-
/**
|
|
377
|
+
/**
|
|
378
|
+
* @deprecated
|
|
379
|
+
* @description Always refund on the origin chain in case of any issues
|
|
380
|
+
*/
|
|
378
381
|
refundOnOrigin?: boolean;
|
|
379
382
|
/** @description Enable this to use the exact input rather than exact output */
|
|
380
383
|
useExactInput?: boolean;
|
|
@@ -551,7 +554,10 @@ export interface paths {
|
|
|
551
554
|
source?: string;
|
|
552
555
|
/** @description Address to send the refund to in the case of failure, if not specified then the receipient address or user address is used */
|
|
553
556
|
refundTo?: string;
|
|
554
|
-
/**
|
|
557
|
+
/**
|
|
558
|
+
* @deprecated
|
|
559
|
+
* @description Always refund on the origin chain in case of any issues
|
|
560
|
+
*/
|
|
555
561
|
refundOnOrigin?: boolean;
|
|
556
562
|
/** @description Enable this to use the exact input rather than exact output */
|
|
557
563
|
useExactInput?: boolean;
|
|
@@ -823,6 +829,45 @@ export interface paths {
|
|
|
823
829
|
amountUsd?: string;
|
|
824
830
|
minimumAmount?: string;
|
|
825
831
|
};
|
|
832
|
+
/**
|
|
833
|
+
* @description The amount of fees for the request that are subsidized by the request sponsor. Does not include deposit origin gas unless it is a permit based deposit.
|
|
834
|
+
* @example {
|
|
835
|
+
* "currency": {
|
|
836
|
+
* "chainId": 8453,
|
|
837
|
+
* "address": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
838
|
+
* "symbol": "USDC",
|
|
839
|
+
* "name": "USD Coin",
|
|
840
|
+
* "decimals": 6,
|
|
841
|
+
* "metadata": {
|
|
842
|
+
* "logoURI": "https://ethereum-optimism.github.io/data/USDC/logo.png",
|
|
843
|
+
* "verified": false,
|
|
844
|
+
* "isNative": false
|
|
845
|
+
* }
|
|
846
|
+
* },
|
|
847
|
+
* "amount": "30754920",
|
|
848
|
+
* "amountFormatted": "30.75492",
|
|
849
|
+
* "amountUsd": "30.901612",
|
|
850
|
+
* "minimumAmount": "30454920"
|
|
851
|
+
* }
|
|
852
|
+
*/
|
|
853
|
+
subsidized?: {
|
|
854
|
+
currency?: {
|
|
855
|
+
chainId?: number;
|
|
856
|
+
address?: string;
|
|
857
|
+
symbol?: string;
|
|
858
|
+
name?: string;
|
|
859
|
+
decimals?: number;
|
|
860
|
+
metadata?: {
|
|
861
|
+
logoURI?: string;
|
|
862
|
+
verified?: boolean;
|
|
863
|
+
isNative?: boolean;
|
|
864
|
+
};
|
|
865
|
+
};
|
|
866
|
+
amount?: string;
|
|
867
|
+
amountFormatted?: string;
|
|
868
|
+
amountUsd?: string;
|
|
869
|
+
minimumAmount?: string;
|
|
870
|
+
};
|
|
826
871
|
};
|
|
827
872
|
breakdown?: {
|
|
828
873
|
/** @description Amount that will be bridged in the estimated time */
|
|
@@ -893,7 +938,10 @@ export interface paths {
|
|
|
893
938
|
appFees?: string[];
|
|
894
939
|
/** @description Address to send the refund to in the case of failure, if not specified then the receipient address or user address is used */
|
|
895
940
|
refundTo?: string;
|
|
896
|
-
/**
|
|
941
|
+
/**
|
|
942
|
+
* @deprecated
|
|
943
|
+
* @description Always refund on the origin chain in case of any issues
|
|
944
|
+
*/
|
|
897
945
|
refundOnOrigin?: boolean;
|
|
898
946
|
source?: string;
|
|
899
947
|
/**
|
|
@@ -1077,7 +1125,10 @@ export interface paths {
|
|
|
1077
1125
|
appFees?: string[];
|
|
1078
1126
|
/** @description Address to send the refund to in the case of failure, if not specified then the receipient address or user address is used */
|
|
1079
1127
|
refundTo?: string;
|
|
1080
|
-
/**
|
|
1128
|
+
/**
|
|
1129
|
+
* @deprecated
|
|
1130
|
+
* @description Always refund on the origin chain in case of any issues
|
|
1131
|
+
*/
|
|
1081
1132
|
refundOnOrigin?: boolean;
|
|
1082
1133
|
source?: string;
|
|
1083
1134
|
/**
|
|
@@ -1342,6 +1393,45 @@ export interface paths {
|
|
|
1342
1393
|
amountUsd?: string;
|
|
1343
1394
|
minimumAmount?: string;
|
|
1344
1395
|
};
|
|
1396
|
+
/**
|
|
1397
|
+
* @description The amount of fees for the request that are subsidized by the request sponsor. Does not include deposit origin gas unless it is a permit based deposit.
|
|
1398
|
+
* @example {
|
|
1399
|
+
* "currency": {
|
|
1400
|
+
* "chainId": 8453,
|
|
1401
|
+
* "address": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
1402
|
+
* "symbol": "USDC",
|
|
1403
|
+
* "name": "USD Coin",
|
|
1404
|
+
* "decimals": 6,
|
|
1405
|
+
* "metadata": {
|
|
1406
|
+
* "logoURI": "https://ethereum-optimism.github.io/data/USDC/logo.png",
|
|
1407
|
+
* "verified": false,
|
|
1408
|
+
* "isNative": false
|
|
1409
|
+
* }
|
|
1410
|
+
* },
|
|
1411
|
+
* "amount": "30754920",
|
|
1412
|
+
* "amountFormatted": "30.75492",
|
|
1413
|
+
* "amountUsd": "30.901612",
|
|
1414
|
+
* "minimumAmount": "30454920"
|
|
1415
|
+
* }
|
|
1416
|
+
*/
|
|
1417
|
+
subsidized?: {
|
|
1418
|
+
currency?: {
|
|
1419
|
+
chainId?: number;
|
|
1420
|
+
address?: string;
|
|
1421
|
+
symbol?: string;
|
|
1422
|
+
name?: string;
|
|
1423
|
+
decimals?: number;
|
|
1424
|
+
metadata?: {
|
|
1425
|
+
logoURI?: string;
|
|
1426
|
+
verified?: boolean;
|
|
1427
|
+
isNative?: boolean;
|
|
1428
|
+
};
|
|
1429
|
+
};
|
|
1430
|
+
amount?: string;
|
|
1431
|
+
amountFormatted?: string;
|
|
1432
|
+
amountUsd?: string;
|
|
1433
|
+
minimumAmount?: string;
|
|
1434
|
+
};
|
|
1345
1435
|
};
|
|
1346
1436
|
/**
|
|
1347
1437
|
* @example {
|
|
@@ -1438,7 +1528,10 @@ export interface paths {
|
|
|
1438
1528
|
source?: string;
|
|
1439
1529
|
/** @description Address to send the refund to in the case of failure, if not specified then the recipient address or user address is used */
|
|
1440
1530
|
refundTo?: string;
|
|
1441
|
-
/**
|
|
1531
|
+
/**
|
|
1532
|
+
* @deprecated
|
|
1533
|
+
* @description Always refund on the origin chain in case of any issues
|
|
1534
|
+
*/
|
|
1442
1535
|
refundOnOrigin?: boolean;
|
|
1443
1536
|
/**
|
|
1444
1537
|
* @description Enable this to route payments via a forwarder contract. This contract will emit an event when receiving payments before forwarding to the solver. This is needed when depositing from a smart contract as the payment will be an internal transaction and detecting such a transaction requires obtaining the transaction traces.
|
|
@@ -1718,6 +1811,45 @@ export interface paths {
|
|
|
1718
1811
|
amountUsd?: string;
|
|
1719
1812
|
minimumAmount?: string;
|
|
1720
1813
|
};
|
|
1814
|
+
/**
|
|
1815
|
+
* @description The amount of fees for the request that are subsidized by the request sponsor. Does not include deposit origin gas unless it is a permit based deposit.
|
|
1816
|
+
* @example {
|
|
1817
|
+
* "currency": {
|
|
1818
|
+
* "chainId": 8453,
|
|
1819
|
+
* "address": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
1820
|
+
* "symbol": "USDC",
|
|
1821
|
+
* "name": "USD Coin",
|
|
1822
|
+
* "decimals": 6,
|
|
1823
|
+
* "metadata": {
|
|
1824
|
+
* "logoURI": "https://ethereum-optimism.github.io/data/USDC/logo.png",
|
|
1825
|
+
* "verified": false,
|
|
1826
|
+
* "isNative": false
|
|
1827
|
+
* }
|
|
1828
|
+
* },
|
|
1829
|
+
* "amount": "30754920",
|
|
1830
|
+
* "amountFormatted": "30.75492",
|
|
1831
|
+
* "amountUsd": "30.901612",
|
|
1832
|
+
* "minimumAmount": "30454920"
|
|
1833
|
+
* }
|
|
1834
|
+
*/
|
|
1835
|
+
subsidized?: {
|
|
1836
|
+
currency?: {
|
|
1837
|
+
chainId?: number;
|
|
1838
|
+
address?: string;
|
|
1839
|
+
symbol?: string;
|
|
1840
|
+
name?: string;
|
|
1841
|
+
decimals?: number;
|
|
1842
|
+
metadata?: {
|
|
1843
|
+
logoURI?: string;
|
|
1844
|
+
verified?: boolean;
|
|
1845
|
+
isNative?: boolean;
|
|
1846
|
+
};
|
|
1847
|
+
};
|
|
1848
|
+
amount?: string;
|
|
1849
|
+
amountFormatted?: string;
|
|
1850
|
+
amountUsd?: string;
|
|
1851
|
+
minimumAmount?: string;
|
|
1852
|
+
};
|
|
1721
1853
|
};
|
|
1722
1854
|
breakdown?: {
|
|
1723
1855
|
/** @description Amount that will be swapped in the estimated time */
|
|
@@ -1906,6 +2038,7 @@ export interface paths {
|
|
|
1906
2038
|
tradeType: "EXACT_INPUT" | "EXACT_OUTPUT";
|
|
1907
2039
|
referrer?: string;
|
|
1908
2040
|
gasLimitForDepositSpecifiedTxs?: number;
|
|
2041
|
+
originGasOverhead?: number;
|
|
1909
2042
|
};
|
|
1910
2043
|
};
|
|
1911
2044
|
};
|
|
@@ -2165,6 +2298,45 @@ export interface paths {
|
|
|
2165
2298
|
amountUsd?: string;
|
|
2166
2299
|
minimumAmount?: string;
|
|
2167
2300
|
};
|
|
2301
|
+
/**
|
|
2302
|
+
* @description The amount of fees for the request that are subsidized by the request sponsor. Does not include deposit origin gas unless it is a permit based deposit.
|
|
2303
|
+
* @example {
|
|
2304
|
+
* "currency": {
|
|
2305
|
+
* "chainId": 8453,
|
|
2306
|
+
* "address": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
2307
|
+
* "symbol": "USDC",
|
|
2308
|
+
* "name": "USD Coin",
|
|
2309
|
+
* "decimals": 6,
|
|
2310
|
+
* "metadata": {
|
|
2311
|
+
* "logoURI": "https://ethereum-optimism.github.io/data/USDC/logo.png",
|
|
2312
|
+
* "verified": false,
|
|
2313
|
+
* "isNative": false
|
|
2314
|
+
* }
|
|
2315
|
+
* },
|
|
2316
|
+
* "amount": "30754920",
|
|
2317
|
+
* "amountFormatted": "30.75492",
|
|
2318
|
+
* "amountUsd": "30.901612",
|
|
2319
|
+
* "minimumAmount": "30454920"
|
|
2320
|
+
* }
|
|
2321
|
+
*/
|
|
2322
|
+
subsidized?: {
|
|
2323
|
+
currency?: {
|
|
2324
|
+
chainId?: number;
|
|
2325
|
+
address?: string;
|
|
2326
|
+
symbol?: string;
|
|
2327
|
+
name?: string;
|
|
2328
|
+
decimals?: number;
|
|
2329
|
+
metadata?: {
|
|
2330
|
+
logoURI?: string;
|
|
2331
|
+
verified?: boolean;
|
|
2332
|
+
isNative?: boolean;
|
|
2333
|
+
};
|
|
2334
|
+
};
|
|
2335
|
+
amount?: string;
|
|
2336
|
+
amountFormatted?: string;
|
|
2337
|
+
amountUsd?: string;
|
|
2338
|
+
minimumAmount?: string;
|
|
2339
|
+
};
|
|
2168
2340
|
};
|
|
2169
2341
|
breakdown?: {
|
|
2170
2342
|
/** @description Amount that will be swapped in the estimated time */
|
|
@@ -2415,11 +2587,19 @@ export interface paths {
|
|
|
2415
2587
|
r: string;
|
|
2416
2588
|
s: string;
|
|
2417
2589
|
}[];
|
|
2590
|
+
/** @description Additional data needed for specific routes */
|
|
2591
|
+
additionalData?: {
|
|
2592
|
+
/** @description If the request originates from Bitcoin and the user is a P2SH address, the public key is needed to be able to generate the transaction data */
|
|
2593
|
+
userPublicKey?: string;
|
|
2594
|
+
};
|
|
2418
2595
|
referrer?: string;
|
|
2419
2596
|
referrerAddress?: string;
|
|
2420
2597
|
/** @description Address to send the refund to in the case of failure, if not specified then the recipient address or user address is used */
|
|
2421
2598
|
refundTo?: string;
|
|
2422
|
-
/**
|
|
2599
|
+
/**
|
|
2600
|
+
* @deprecated
|
|
2601
|
+
* @description Always refund on the origin chain in case of any issues
|
|
2602
|
+
*/
|
|
2423
2603
|
refundOnOrigin?: boolean;
|
|
2424
2604
|
/** @description If set, the destination fill will include a gas topup to the recipient (only supported for EVM chains if the requested currency is not the gas currency on the destination chain) */
|
|
2425
2605
|
topupGas?: boolean;
|
|
@@ -2455,6 +2635,8 @@ export interface paths {
|
|
|
2455
2635
|
useDepositAddress?: boolean;
|
|
2456
2636
|
/** @description Slippage tolerance for the swap, if not specified then the slippage tolerance is automatically calculated to avoid front-running. This value is in basis points (1/100th of a percent), e.g. 50 for 0.5% slippage */
|
|
2457
2637
|
slippageTolerance?: string;
|
|
2638
|
+
/** @description Slippage tolerance for destination gas in the event that the deposit occurs after the order deadline, and more gas is required for the solver to execute the destination transaction. */
|
|
2639
|
+
latePaymentSlippageTolerance?: string;
|
|
2458
2640
|
appFees?: {
|
|
2459
2641
|
/** @description Address that will receive the app fee, if not specified then the user address is used */
|
|
2460
2642
|
recipient?: string;
|
|
@@ -2473,6 +2655,14 @@ export interface paths {
|
|
|
2473
2655
|
includedSwapSources?: string[];
|
|
2474
2656
|
/** @description Swap sources to exclude for swap routing. */
|
|
2475
2657
|
excludedSwapSources?: string[];
|
|
2658
|
+
/** @description Swap sources to include for swap routing on origin. */
|
|
2659
|
+
includedOriginSwapSources?: string[];
|
|
2660
|
+
/** @description Swap sources to include for swap routing on destination. */
|
|
2661
|
+
includedDestinationSwapSources?: string[];
|
|
2662
|
+
/** @description The gas overhead for the origin chain, this is used to calculate the gas fee for the origin chain when the solver is executing a gasless transaction on the origin chain */
|
|
2663
|
+
originGasOverhead?: number;
|
|
2664
|
+
/** @description The payer to be set for deposit transactions on solana. This account must have enough for fees and rent. */
|
|
2665
|
+
depositFeePayer?: string;
|
|
2476
2666
|
};
|
|
2477
2667
|
};
|
|
2478
2668
|
};
|
|
@@ -2737,6 +2927,45 @@ export interface paths {
|
|
|
2737
2927
|
amountUsd?: string;
|
|
2738
2928
|
minimumAmount?: string;
|
|
2739
2929
|
};
|
|
2930
|
+
/**
|
|
2931
|
+
* @description The amount of fees for the request that are subsidized by the request sponsor. Does not include deposit origin gas unless it is a permit based deposit.
|
|
2932
|
+
* @example {
|
|
2933
|
+
* "currency": {
|
|
2934
|
+
* "chainId": 8453,
|
|
2935
|
+
* "address": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
2936
|
+
* "symbol": "USDC",
|
|
2937
|
+
* "name": "USD Coin",
|
|
2938
|
+
* "decimals": 6,
|
|
2939
|
+
* "metadata": {
|
|
2940
|
+
* "logoURI": "https://ethereum-optimism.github.io/data/USDC/logo.png",
|
|
2941
|
+
* "verified": false,
|
|
2942
|
+
* "isNative": false
|
|
2943
|
+
* }
|
|
2944
|
+
* },
|
|
2945
|
+
* "amount": "30754920",
|
|
2946
|
+
* "amountFormatted": "30.75492",
|
|
2947
|
+
* "amountUsd": "30.901612",
|
|
2948
|
+
* "minimumAmount": "30454920"
|
|
2949
|
+
* }
|
|
2950
|
+
*/
|
|
2951
|
+
subsidized?: {
|
|
2952
|
+
currency?: {
|
|
2953
|
+
chainId?: number;
|
|
2954
|
+
address?: string;
|
|
2955
|
+
symbol?: string;
|
|
2956
|
+
name?: string;
|
|
2957
|
+
decimals?: number;
|
|
2958
|
+
metadata?: {
|
|
2959
|
+
logoURI?: string;
|
|
2960
|
+
verified?: boolean;
|
|
2961
|
+
isNative?: boolean;
|
|
2962
|
+
};
|
|
2963
|
+
};
|
|
2964
|
+
amount?: string;
|
|
2965
|
+
amountFormatted?: string;
|
|
2966
|
+
amountUsd?: string;
|
|
2967
|
+
minimumAmount?: string;
|
|
2968
|
+
};
|
|
2740
2969
|
};
|
|
2741
2970
|
/** @description A summary of the swap and what the user should expect to happen given an input */
|
|
2742
2971
|
details?: {
|
|
@@ -2870,6 +3099,24 @@ export interface paths {
|
|
|
2870
3099
|
usd?: string;
|
|
2871
3100
|
percent?: string;
|
|
2872
3101
|
};
|
|
3102
|
+
expandedPriceImpact?: {
|
|
3103
|
+
/** @description Cost to execute swap or bridge depending on available liquidity. This value can be negative (representing network rewards for improving liquidity distribution) */
|
|
3104
|
+
swap?: {
|
|
3105
|
+
usd?: string;
|
|
3106
|
+
};
|
|
3107
|
+
/** @description Fees paid to cover transaction execution costs */
|
|
3108
|
+
execution?: {
|
|
3109
|
+
usd?: string;
|
|
3110
|
+
};
|
|
3111
|
+
/** @description Fees paid to the protocol */
|
|
3112
|
+
relay?: {
|
|
3113
|
+
usd?: string;
|
|
3114
|
+
};
|
|
3115
|
+
/** @description Fees paid to the app. Currency will be the same as the relayer fee currency. This needs to be claimed later by the app owner and is not immediately distributed to the app */
|
|
3116
|
+
app?: {
|
|
3117
|
+
usd?: string;
|
|
3118
|
+
};
|
|
3119
|
+
};
|
|
2873
3120
|
/** @description The swap rate which is equal to 1 input unit in the output unit, e.g. 1 USDC -> x ETH. This value can fluctuate based on gas and fees. */
|
|
2874
3121
|
rate?: string;
|
|
2875
3122
|
slippageTolerance?: {
|
|
@@ -2973,7 +3220,10 @@ export interface paths {
|
|
|
2973
3220
|
referrer?: string;
|
|
2974
3221
|
/** @description Address to send the refund to in the case of failure, if not specified then the recipient address or user address is used */
|
|
2975
3222
|
refundTo?: string;
|
|
2976
|
-
/**
|
|
3223
|
+
/**
|
|
3224
|
+
* @deprecated
|
|
3225
|
+
* @description Always refund on the origin chain in case of any issues
|
|
3226
|
+
*/
|
|
2977
3227
|
refundOnOrigin?: boolean;
|
|
2978
3228
|
/**
|
|
2979
3229
|
* @description Enable this to route payments via a receiver contract. This contract will emit an event when receiving payments before forwarding to the solver. This is needed when depositing from a smart contract as the payment will be an internal transaction and detecting such a transaction requires obtaining the transaction traces.
|
|
@@ -3200,6 +3450,45 @@ export interface paths {
|
|
|
3200
3450
|
amountUsd?: string;
|
|
3201
3451
|
minimumAmount?: string;
|
|
3202
3452
|
};
|
|
3453
|
+
/**
|
|
3454
|
+
* @description The amount of fees for the request that are subsidized by the request sponsor. Does not include deposit origin gas unless it is a permit based deposit.
|
|
3455
|
+
* @example {
|
|
3456
|
+
* "currency": {
|
|
3457
|
+
* "chainId": 8453,
|
|
3458
|
+
* "address": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
3459
|
+
* "symbol": "USDC",
|
|
3460
|
+
* "name": "USD Coin",
|
|
3461
|
+
* "decimals": 6,
|
|
3462
|
+
* "metadata": {
|
|
3463
|
+
* "logoURI": "https://ethereum-optimism.github.io/data/USDC/logo.png",
|
|
3464
|
+
* "verified": false,
|
|
3465
|
+
* "isNative": false
|
|
3466
|
+
* }
|
|
3467
|
+
* },
|
|
3468
|
+
* "amount": "30754920",
|
|
3469
|
+
* "amountFormatted": "30.75492",
|
|
3470
|
+
* "amountUsd": "30.901612",
|
|
3471
|
+
* "minimumAmount": "30454920"
|
|
3472
|
+
* }
|
|
3473
|
+
*/
|
|
3474
|
+
subsidized?: {
|
|
3475
|
+
currency?: {
|
|
3476
|
+
chainId?: number;
|
|
3477
|
+
address?: string;
|
|
3478
|
+
symbol?: string;
|
|
3479
|
+
name?: string;
|
|
3480
|
+
decimals?: number;
|
|
3481
|
+
metadata?: {
|
|
3482
|
+
logoURI?: string;
|
|
3483
|
+
verified?: boolean;
|
|
3484
|
+
isNative?: boolean;
|
|
3485
|
+
};
|
|
3486
|
+
};
|
|
3487
|
+
amount?: string;
|
|
3488
|
+
amountFormatted?: string;
|
|
3489
|
+
amountUsd?: string;
|
|
3490
|
+
minimumAmount?: string;
|
|
3491
|
+
};
|
|
3203
3492
|
};
|
|
3204
3493
|
/** @description A summary of the swap and what the user should expect to happen given an input */
|
|
3205
3494
|
details?: {
|
|
@@ -3350,6 +3639,105 @@ export interface paths {
|
|
|
3350
3639
|
};
|
|
3351
3640
|
};
|
|
3352
3641
|
};
|
|
3642
|
+
"/execute": {
|
|
3643
|
+
post: {
|
|
3644
|
+
requestBody: {
|
|
3645
|
+
content: {
|
|
3646
|
+
"application/json": {
|
|
3647
|
+
/**
|
|
3648
|
+
* @description The kind of gasless transaction to execute. Currently supported: rawCalls
|
|
3649
|
+
* @enum {string}
|
|
3650
|
+
*/
|
|
3651
|
+
executionKind: "rawCalls";
|
|
3652
|
+
/** @description Raw call parameters for the gasless transaction */
|
|
3653
|
+
data: {
|
|
3654
|
+
/** @description Chain ID of the EVM network */
|
|
3655
|
+
chainId: number;
|
|
3656
|
+
/** @description Address of the contract to call */
|
|
3657
|
+
to: string;
|
|
3658
|
+
/** @description Encoded function call data */
|
|
3659
|
+
data: string;
|
|
3660
|
+
/** @description ETH value to send with the call (in wei) */
|
|
3661
|
+
value: string;
|
|
3662
|
+
/** @description Authorization list for EIP-7702 transactions to be executed on destination chain */
|
|
3663
|
+
authorizationList?: {
|
|
3664
|
+
chainId: number;
|
|
3665
|
+
address: string;
|
|
3666
|
+
nonce: number;
|
|
3667
|
+
yParity: number;
|
|
3668
|
+
r: string;
|
|
3669
|
+
s: string;
|
|
3670
|
+
}[];
|
|
3671
|
+
};
|
|
3672
|
+
/** @description Options related to gas fee sponsorship and app referrer */
|
|
3673
|
+
executionOptions: {
|
|
3674
|
+
/** @description The referrer of the app which is executing the gasless transaction */
|
|
3675
|
+
referrer: string;
|
|
3676
|
+
/** @description If the app should pay for the fees associated with the request */
|
|
3677
|
+
subsidizeFees: boolean;
|
|
3678
|
+
};
|
|
3679
|
+
};
|
|
3680
|
+
};
|
|
3681
|
+
};
|
|
3682
|
+
responses: {
|
|
3683
|
+
/** @description Transaction successfully queued for execution */
|
|
3684
|
+
200: {
|
|
3685
|
+
content: {
|
|
3686
|
+
"application/json": {
|
|
3687
|
+
/** @example Transaction submitted */
|
|
3688
|
+
message?: string;
|
|
3689
|
+
/** @example 0xabc123... */
|
|
3690
|
+
requestId?: string;
|
|
3691
|
+
};
|
|
3692
|
+
};
|
|
3693
|
+
};
|
|
3694
|
+
/** @description Bad Request - Invalid input or simulation failure */
|
|
3695
|
+
400: {
|
|
3696
|
+
content: {
|
|
3697
|
+
"application/json": {
|
|
3698
|
+
/** @example to is required */
|
|
3699
|
+
error?: string;
|
|
3700
|
+
} | {
|
|
3701
|
+
/** @example data is required */
|
|
3702
|
+
error?: string;
|
|
3703
|
+
} | {
|
|
3704
|
+
/** @example value is required */
|
|
3705
|
+
error?: string;
|
|
3706
|
+
} | {
|
|
3707
|
+
/** @example chainId is required */
|
|
3708
|
+
error?: string;
|
|
3709
|
+
} | {
|
|
3710
|
+
/** @example authorizationList cannot be empty */
|
|
3711
|
+
error?: string;
|
|
3712
|
+
} | {
|
|
3713
|
+
/** @example SimulationError */
|
|
3714
|
+
error?: string;
|
|
3715
|
+
/** @example execution reverted: invalid opcode */
|
|
3716
|
+
message?: string;
|
|
3717
|
+
};
|
|
3718
|
+
};
|
|
3719
|
+
};
|
|
3720
|
+
/** @description Unauthorized - Missing or invalid API key or referrer */
|
|
3721
|
+
401: {
|
|
3722
|
+
content: {
|
|
3723
|
+
"application/json": {
|
|
3724
|
+
/** @example Unauthorized */
|
|
3725
|
+
error?: string;
|
|
3726
|
+
};
|
|
3727
|
+
};
|
|
3728
|
+
};
|
|
3729
|
+
/** @description Internal Server Error */
|
|
3730
|
+
500: {
|
|
3731
|
+
content: {
|
|
3732
|
+
"application/json": {
|
|
3733
|
+
/** @example Internal server error */
|
|
3734
|
+
error?: string;
|
|
3735
|
+
};
|
|
3736
|
+
};
|
|
3737
|
+
};
|
|
3738
|
+
};
|
|
3739
|
+
};
|
|
3740
|
+
};
|
|
3353
3741
|
"/lives": {
|
|
3354
3742
|
get: {
|
|
3355
3743
|
responses: {
|
|
@@ -4007,6 +4395,8 @@ export interface paths {
|
|
|
4007
4395
|
slippageTolerance?: string;
|
|
4008
4396
|
/** @enum {string} */
|
|
4009
4397
|
failReason?: "UNKNOWN" | "AMOUNT_TOO_LOW_TO_REFUND" | "DEPOSIT_ADDRESS_MISMATCH" | "DEPOSIT_CHAIN_MISMATCH" | "SLIPPAGE" | "INCORRECT_DEPOSIT_CURRENCY" | "DOUBLE_SPEND" | "SOLVER_CAPACITY_EXCEEDED" | "DEPOSITED_AMOUNT_TOO_LOW_TO_FILL" | "NEGATIVE_NEW_AMOUNT_AFTER_FEES" | "NO_QUOTES" | "MISSING_REVERT_DATA" | "REVERSE_SWAP_FAILED" | "GENERATE_SWAP_FAILED" | "TOO_LITTLE_RECEIVED" | "EXECUTION_REVERTED" | "NEW_CALLDATA_INCLUDES_HIGHER_RENT_FEE" | "TRANSACTION_REVERTED" | "N/A";
|
|
4398
|
+
/** @enum {string} */
|
|
4399
|
+
refundFailReason?: "AMOUNT_TOO_LOW_TO_REFUND";
|
|
4010
4400
|
fees?: {
|
|
4011
4401
|
/** @description Estimated gas cost required for execution, in wei */
|
|
4012
4402
|
gas?: string;
|