@cowprotocol/sdk-bridging 0.4.5 → 0.4.7-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +66 -30
- package/dist/index.d.ts +66 -30
- package/dist/index.js +315 -162
- package/dist/index.mjs +307 -156
- package/package.json +6 -6
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cowAppDataLatestScheme } from '@cowprotocol/sdk-app-data';
|
|
2
2
|
import { Amounts, OrderKind, Address, EnrichedOrder, OrderBookApi } from '@cowprotocol/sdk-order-book';
|
|
3
|
-
import { ChainInfo, TargetChainId, SupportedChainId, TokenInfo,
|
|
3
|
+
import { ChainInfo, TargetChainId, SupportedChainId, TokenInfo, ChainId, EvmCall, CowEnv } from '@cowprotocol/sdk-config';
|
|
4
4
|
import { QuoterParameters, TraderParameters, TradeOptionalParameters, QuoteAndPost, QuoteResults, SwapAdvancedSettings, SigningStepManager, OrderPostingResult, TradingSdk } from '@cowprotocol/sdk-trading';
|
|
5
5
|
import { AccountAddress, SignerLike, TTLCache, AbstractProviderAdapter } from '@cowprotocol/sdk-common';
|
|
6
6
|
import { CowShedSdk, CowShedSdkOptions } from '@cowprotocol/sdk-cow-shed';
|
|
@@ -122,7 +122,13 @@ interface BridgeDeposit extends Omit<QuoteBridgeRequest, 'amount'> {
|
|
|
122
122
|
sellTokenAmount: string;
|
|
123
123
|
minBuyAmount: string;
|
|
124
124
|
}
|
|
125
|
+
/**
|
|
126
|
+
* Main interface for a bridge provider.
|
|
127
|
+
*
|
|
128
|
+
* It contains the main information about the provider, and the methods to get the quote, the bridging params, the status, the cancelling and the refunding of the bridging.
|
|
129
|
+
*/
|
|
125
130
|
interface BridgeProvider<Q extends BridgeQuoteResult> {
|
|
131
|
+
type: 'ReceiverAccountBridgeProvider' | 'HookBridgeProvider';
|
|
126
132
|
info: BridgeProviderInfo;
|
|
127
133
|
/**
|
|
128
134
|
* Get basic supported chains
|
|
@@ -147,6 +153,53 @@ interface BridgeProvider<Q extends BridgeQuoteResult> {
|
|
|
147
153
|
* @param request - The quote request
|
|
148
154
|
*/
|
|
149
155
|
getQuote(request: QuoteBridgeRequest): Promise<Q>;
|
|
156
|
+
/**
|
|
157
|
+
* Get the identifier of the bridging transaction from the settlement transaction.
|
|
158
|
+
* @param chainId
|
|
159
|
+
* @param orderUid - The unique identifier of the order
|
|
160
|
+
* @param txHash - The hash of the settlement transaction in which the bridging post-hook was executed
|
|
161
|
+
*/
|
|
162
|
+
getBridgingParams(chainId: ChainId, orderUid: string, txHash: string): Promise<{
|
|
163
|
+
params: BridgingDepositParams;
|
|
164
|
+
status: BridgeStatusResult;
|
|
165
|
+
} | null>;
|
|
166
|
+
/**
|
|
167
|
+
* Get the explorer url for a bridging id.
|
|
168
|
+
*
|
|
169
|
+
* @param bridgingId - The bridging id
|
|
170
|
+
*/
|
|
171
|
+
getExplorerUrl(bridgingId: string): string;
|
|
172
|
+
/**
|
|
173
|
+
* Get the status of a bridging transaction.
|
|
174
|
+
*
|
|
175
|
+
* @param bridgingId - The bridging id
|
|
176
|
+
* @param originChainId - id of network where funds were deposited
|
|
177
|
+
*/
|
|
178
|
+
getStatus(bridgingId: string, originChainId: SupportedChainId): Promise<BridgeStatusResult>;
|
|
179
|
+
getCancelBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
180
|
+
getRefundBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* A basic bridge provider that relies on sending the tokens to a specific account.
|
|
184
|
+
* This provider doesn't rely on hooks to initiate the bridge.
|
|
185
|
+
*/
|
|
186
|
+
interface ReceiverAccountBridgeProvider<Q extends BridgeQuoteResult> extends BridgeProvider<Q> {
|
|
187
|
+
type: 'ReceiverAccountBridgeProvider';
|
|
188
|
+
/**
|
|
189
|
+
* Get the receiver account to where the tokens will be sent in the source chain so they are automatically bridged to the destination chain.
|
|
190
|
+
*
|
|
191
|
+
* @param quoteRequest - The quote request
|
|
192
|
+
* @param quoteResult - The quote result
|
|
193
|
+
* @returns The receiver account
|
|
194
|
+
*/
|
|
195
|
+
getBridgeReceiverOverride(quoteRequest: QuoteBridgeRequest, quoteResult: Q): Promise<string>;
|
|
196
|
+
}
|
|
197
|
+
/**
|
|
198
|
+
* A bridge provider that uses a hook to initiate the bridge.
|
|
199
|
+
*
|
|
200
|
+
*/
|
|
201
|
+
interface HookBridgeProvider<Q extends BridgeQuoteResult> extends BridgeProvider<Q> {
|
|
202
|
+
type: 'HookBridgeProvider';
|
|
150
203
|
/**
|
|
151
204
|
* Get an unsigned bridge call for a quote.
|
|
152
205
|
*
|
|
@@ -196,31 +249,6 @@ interface BridgeProvider<Q extends BridgeQuoteResult> {
|
|
|
196
249
|
* @param hook - The bridge hook
|
|
197
250
|
*/
|
|
198
251
|
decodeBridgeHook(hook: cowAppDataLatestScheme.CoWHook): Promise<BridgeDeposit>;
|
|
199
|
-
/**
|
|
200
|
-
* Get the identifier of the bridging transaction from the settlement transaction.
|
|
201
|
-
* @param chainId
|
|
202
|
-
* @param orderUid - The unique identifier of the order
|
|
203
|
-
* @param txHash - The hash of the settlement transaction in which the bridging post-hook was executed
|
|
204
|
-
*/
|
|
205
|
-
getBridgingParams(chainId: ChainId, orderUid: string, txHash: string): Promise<{
|
|
206
|
-
params: BridgingDepositParams;
|
|
207
|
-
status: BridgeStatusResult;
|
|
208
|
-
} | null>;
|
|
209
|
-
/**
|
|
210
|
-
* Get the explorer url for a bridging id.
|
|
211
|
-
*
|
|
212
|
-
* @param bridgingId - The bridging id
|
|
213
|
-
*/
|
|
214
|
-
getExplorerUrl(bridgingId: string): string;
|
|
215
|
-
/**
|
|
216
|
-
* Get the status of a bridging transaction.
|
|
217
|
-
*
|
|
218
|
-
* @param bridgingId - The bridging id
|
|
219
|
-
* @param originChainId - id of network where funds were deposited
|
|
220
|
-
*/
|
|
221
|
-
getStatus(bridgingId: string, originChainId: SupportedChainId): Promise<BridgeStatusResult>;
|
|
222
|
-
getCancelBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
223
|
-
getRefundBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
224
252
|
}
|
|
225
253
|
/**
|
|
226
254
|
* A quote and post for a cross-chain swap.
|
|
@@ -303,7 +331,11 @@ interface BridgeQuoteResults extends BridgeQuoteResult {
|
|
|
303
331
|
/**
|
|
304
332
|
* Bridge call details
|
|
305
333
|
*/
|
|
306
|
-
bridgeCallDetails
|
|
334
|
+
bridgeCallDetails?: BridgeCallDetails;
|
|
335
|
+
/**
|
|
336
|
+
* Bridge recipient override
|
|
337
|
+
*/
|
|
338
|
+
bridgeReceiverOverride?: string;
|
|
307
339
|
}
|
|
308
340
|
interface BridgingDepositParams {
|
|
309
341
|
inputTokenAddress: Address;
|
|
@@ -418,6 +450,8 @@ declare function assertIsBridgeQuoteAndPost(quote: CrossChainQuoteAndPost): asse
|
|
|
418
450
|
declare function assertIsQuoteAndPost(quote: CrossChainQuoteAndPost): asserts quote is QuoteAndPost;
|
|
419
451
|
declare function getPostHooks(fullAppData?: string): cowAppDataLatestScheme.CoWHook[];
|
|
420
452
|
declare function isAppDoc(appData: unknown): appData is cowAppDataLatestScheme.AppDataRootSchema;
|
|
453
|
+
declare function isHookBridgeProvider<Q extends BridgeQuoteResult>(provider: BridgeProvider<Q>): provider is HookBridgeProvider<Q>;
|
|
454
|
+
declare function isReceiverAccountBridgeProvider<Q extends BridgeQuoteResult>(provider: BridgeProvider<Q>): provider is ReceiverAccountBridgeProvider<Q>;
|
|
421
455
|
|
|
422
456
|
type BridgingSdkConfig = Required<Omit<BridgingSdkOptions, 'enableLogging' | 'cacheConfig'>>;
|
|
423
457
|
/**
|
|
@@ -851,7 +885,8 @@ interface AcrossBridgeProviderOptions {
|
|
|
851
885
|
interface AcrossQuoteResult extends BridgeQuoteResult {
|
|
852
886
|
suggestedFees: SuggestedFeesResponse;
|
|
853
887
|
}
|
|
854
|
-
declare class AcrossBridgeProvider implements
|
|
888
|
+
declare class AcrossBridgeProvider implements HookBridgeProvider<AcrossQuoteResult> {
|
|
889
|
+
type: "HookBridgeProvider";
|
|
855
890
|
protected api: AcrossApi;
|
|
856
891
|
protected cowShedSdk: CowShedSdk;
|
|
857
892
|
private supportedTokens;
|
|
@@ -1171,8 +1206,9 @@ interface BungeeQuoteResult extends BridgeQuoteResult {
|
|
|
1171
1206
|
bungeeQuote: BungeeQuote;
|
|
1172
1207
|
buildTx: BungeeBuildTx;
|
|
1173
1208
|
}
|
|
1174
|
-
declare class BungeeBridgeProvider implements
|
|
1209
|
+
declare class BungeeBridgeProvider implements HookBridgeProvider<BungeeQuoteResult> {
|
|
1175
1210
|
private options;
|
|
1211
|
+
type: "HookBridgeProvider";
|
|
1176
1212
|
protected api: BungeeApi;
|
|
1177
1213
|
protected cowShedSdk: CowShedSdk;
|
|
1178
1214
|
constructor(options: BungeeBridgeProviderOptions, _adapter?: AbstractProviderAdapter);
|
|
@@ -1196,4 +1232,4 @@ declare class BungeeBridgeProvider implements BridgeProvider<BungeeQuoteResult>
|
|
|
1196
1232
|
private isExtraGasRequired;
|
|
1197
1233
|
}
|
|
1198
1234
|
|
|
1199
|
-
export { AcrossBridgeProvider, type AcrossBridgeProviderOptions, type AcrossQuoteResult, type BestQuoteProgressCallback, type BestQuoteProviderContext, type BridgeCallDetails, type BridgeCosts, type BridgeDeposit, type BridgeHook, BridgeOrderParsingError, type BridgeProvider, BridgeProviderError, type BridgeProviderInfo, BridgeProviderQuoteError, type BridgeQuoteAmountsAndCosts, type BridgeQuoteAndPost, BridgeQuoteErrors, type BridgeQuoteResult, type BridgeQuoteResults, BridgeStatus, type BridgeStatusResult, type BridgingDepositParams, BridgingSdk, BungeeBridgeProvider, type BungeeBridgeProviderOptions, type BungeeQuoteResult, type BuyTokensParams, COW_SHED_PROXY_CREATION_GAS, type CrossChainOrder, type CrossChainQuoteAndPost, DEFAULT_EXTRA_GAS_FOR_HOOK_ESTIMATION, DEFAULT_EXTRA_GAS_PROXY_CREATION, DEFAULT_GAS_COST_FOR_HOOK_ESTIMATION, type GetProviderBuyTokens, HOOK_DAPP_BRIDGE_PROVIDER_PREFIX, type MultiQuoteOptions, type MultiQuoteProgressCallback, type MultiQuoteRequest, type MultiQuoteResult, type ProviderQuoteContext, type QuoteBridgeRequest, type QuoteBridgeRequestWithoutAmount, RAW_PROVIDERS_FILES_PATH, assertIsBridgeQuoteAndPost, assertIsQuoteAndPost, getCrossChainOrder, getPostHooks, isAppDoc, isBridgeQuoteAndPost, isQuoteAndPost };
|
|
1235
|
+
export { AcrossBridgeProvider, type AcrossBridgeProviderOptions, type AcrossQuoteResult, type BestQuoteProgressCallback, type BestQuoteProviderContext, type BridgeCallDetails, type BridgeCosts, type BridgeDeposit, type BridgeHook, BridgeOrderParsingError, type BridgeProvider, BridgeProviderError, type BridgeProviderInfo, BridgeProviderQuoteError, type BridgeQuoteAmountsAndCosts, type BridgeQuoteAndPost, BridgeQuoteErrors, type BridgeQuoteResult, type BridgeQuoteResults, BridgeStatus, type BridgeStatusResult, type BridgingDepositParams, BridgingSdk, BungeeBridgeProvider, type BungeeBridgeProviderOptions, type BungeeQuoteResult, type BuyTokensParams, COW_SHED_PROXY_CREATION_GAS, type CrossChainOrder, type CrossChainQuoteAndPost, DEFAULT_EXTRA_GAS_FOR_HOOK_ESTIMATION, DEFAULT_EXTRA_GAS_PROXY_CREATION, DEFAULT_GAS_COST_FOR_HOOK_ESTIMATION, type GetProviderBuyTokens, HOOK_DAPP_BRIDGE_PROVIDER_PREFIX, type HookBridgeProvider, type MultiQuoteOptions, type MultiQuoteProgressCallback, type MultiQuoteRequest, type MultiQuoteResult, type ProviderQuoteContext, type QuoteBridgeRequest, type QuoteBridgeRequestWithoutAmount, RAW_PROVIDERS_FILES_PATH, type ReceiverAccountBridgeProvider, assertIsBridgeQuoteAndPost, assertIsQuoteAndPost, getCrossChainOrder, getPostHooks, isAppDoc, isBridgeQuoteAndPost, isHookBridgeProvider, isQuoteAndPost, isReceiverAccountBridgeProvider };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cowAppDataLatestScheme } from '@cowprotocol/sdk-app-data';
|
|
2
2
|
import { Amounts, OrderKind, Address, EnrichedOrder, OrderBookApi } from '@cowprotocol/sdk-order-book';
|
|
3
|
-
import { ChainInfo, TargetChainId, SupportedChainId, TokenInfo,
|
|
3
|
+
import { ChainInfo, TargetChainId, SupportedChainId, TokenInfo, ChainId, EvmCall, CowEnv } from '@cowprotocol/sdk-config';
|
|
4
4
|
import { QuoterParameters, TraderParameters, TradeOptionalParameters, QuoteAndPost, QuoteResults, SwapAdvancedSettings, SigningStepManager, OrderPostingResult, TradingSdk } from '@cowprotocol/sdk-trading';
|
|
5
5
|
import { AccountAddress, SignerLike, TTLCache, AbstractProviderAdapter } from '@cowprotocol/sdk-common';
|
|
6
6
|
import { CowShedSdk, CowShedSdkOptions } from '@cowprotocol/sdk-cow-shed';
|
|
@@ -122,7 +122,13 @@ interface BridgeDeposit extends Omit<QuoteBridgeRequest, 'amount'> {
|
|
|
122
122
|
sellTokenAmount: string;
|
|
123
123
|
minBuyAmount: string;
|
|
124
124
|
}
|
|
125
|
+
/**
|
|
126
|
+
* Main interface for a bridge provider.
|
|
127
|
+
*
|
|
128
|
+
* It contains the main information about the provider, and the methods to get the quote, the bridging params, the status, the cancelling and the refunding of the bridging.
|
|
129
|
+
*/
|
|
125
130
|
interface BridgeProvider<Q extends BridgeQuoteResult> {
|
|
131
|
+
type: 'ReceiverAccountBridgeProvider' | 'HookBridgeProvider';
|
|
126
132
|
info: BridgeProviderInfo;
|
|
127
133
|
/**
|
|
128
134
|
* Get basic supported chains
|
|
@@ -147,6 +153,53 @@ interface BridgeProvider<Q extends BridgeQuoteResult> {
|
|
|
147
153
|
* @param request - The quote request
|
|
148
154
|
*/
|
|
149
155
|
getQuote(request: QuoteBridgeRequest): Promise<Q>;
|
|
156
|
+
/**
|
|
157
|
+
* Get the identifier of the bridging transaction from the settlement transaction.
|
|
158
|
+
* @param chainId
|
|
159
|
+
* @param orderUid - The unique identifier of the order
|
|
160
|
+
* @param txHash - The hash of the settlement transaction in which the bridging post-hook was executed
|
|
161
|
+
*/
|
|
162
|
+
getBridgingParams(chainId: ChainId, orderUid: string, txHash: string): Promise<{
|
|
163
|
+
params: BridgingDepositParams;
|
|
164
|
+
status: BridgeStatusResult;
|
|
165
|
+
} | null>;
|
|
166
|
+
/**
|
|
167
|
+
* Get the explorer url for a bridging id.
|
|
168
|
+
*
|
|
169
|
+
* @param bridgingId - The bridging id
|
|
170
|
+
*/
|
|
171
|
+
getExplorerUrl(bridgingId: string): string;
|
|
172
|
+
/**
|
|
173
|
+
* Get the status of a bridging transaction.
|
|
174
|
+
*
|
|
175
|
+
* @param bridgingId - The bridging id
|
|
176
|
+
* @param originChainId - id of network where funds were deposited
|
|
177
|
+
*/
|
|
178
|
+
getStatus(bridgingId: string, originChainId: SupportedChainId): Promise<BridgeStatusResult>;
|
|
179
|
+
getCancelBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
180
|
+
getRefundBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* A basic bridge provider that relies on sending the tokens to a specific account.
|
|
184
|
+
* This provider doesn't rely on hooks to initiate the bridge.
|
|
185
|
+
*/
|
|
186
|
+
interface ReceiverAccountBridgeProvider<Q extends BridgeQuoteResult> extends BridgeProvider<Q> {
|
|
187
|
+
type: 'ReceiverAccountBridgeProvider';
|
|
188
|
+
/**
|
|
189
|
+
* Get the receiver account to where the tokens will be sent in the source chain so they are automatically bridged to the destination chain.
|
|
190
|
+
*
|
|
191
|
+
* @param quoteRequest - The quote request
|
|
192
|
+
* @param quoteResult - The quote result
|
|
193
|
+
* @returns The receiver account
|
|
194
|
+
*/
|
|
195
|
+
getBridgeReceiverOverride(quoteRequest: QuoteBridgeRequest, quoteResult: Q): Promise<string>;
|
|
196
|
+
}
|
|
197
|
+
/**
|
|
198
|
+
* A bridge provider that uses a hook to initiate the bridge.
|
|
199
|
+
*
|
|
200
|
+
*/
|
|
201
|
+
interface HookBridgeProvider<Q extends BridgeQuoteResult> extends BridgeProvider<Q> {
|
|
202
|
+
type: 'HookBridgeProvider';
|
|
150
203
|
/**
|
|
151
204
|
* Get an unsigned bridge call for a quote.
|
|
152
205
|
*
|
|
@@ -196,31 +249,6 @@ interface BridgeProvider<Q extends BridgeQuoteResult> {
|
|
|
196
249
|
* @param hook - The bridge hook
|
|
197
250
|
*/
|
|
198
251
|
decodeBridgeHook(hook: cowAppDataLatestScheme.CoWHook): Promise<BridgeDeposit>;
|
|
199
|
-
/**
|
|
200
|
-
* Get the identifier of the bridging transaction from the settlement transaction.
|
|
201
|
-
* @param chainId
|
|
202
|
-
* @param orderUid - The unique identifier of the order
|
|
203
|
-
* @param txHash - The hash of the settlement transaction in which the bridging post-hook was executed
|
|
204
|
-
*/
|
|
205
|
-
getBridgingParams(chainId: ChainId, orderUid: string, txHash: string): Promise<{
|
|
206
|
-
params: BridgingDepositParams;
|
|
207
|
-
status: BridgeStatusResult;
|
|
208
|
-
} | null>;
|
|
209
|
-
/**
|
|
210
|
-
* Get the explorer url for a bridging id.
|
|
211
|
-
*
|
|
212
|
-
* @param bridgingId - The bridging id
|
|
213
|
-
*/
|
|
214
|
-
getExplorerUrl(bridgingId: string): string;
|
|
215
|
-
/**
|
|
216
|
-
* Get the status of a bridging transaction.
|
|
217
|
-
*
|
|
218
|
-
* @param bridgingId - The bridging id
|
|
219
|
-
* @param originChainId - id of network where funds were deposited
|
|
220
|
-
*/
|
|
221
|
-
getStatus(bridgingId: string, originChainId: SupportedChainId): Promise<BridgeStatusResult>;
|
|
222
|
-
getCancelBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
223
|
-
getRefundBridgingTx(bridgingId: string): Promise<EvmCall>;
|
|
224
252
|
}
|
|
225
253
|
/**
|
|
226
254
|
* A quote and post for a cross-chain swap.
|
|
@@ -303,7 +331,11 @@ interface BridgeQuoteResults extends BridgeQuoteResult {
|
|
|
303
331
|
/**
|
|
304
332
|
* Bridge call details
|
|
305
333
|
*/
|
|
306
|
-
bridgeCallDetails
|
|
334
|
+
bridgeCallDetails?: BridgeCallDetails;
|
|
335
|
+
/**
|
|
336
|
+
* Bridge recipient override
|
|
337
|
+
*/
|
|
338
|
+
bridgeReceiverOverride?: string;
|
|
307
339
|
}
|
|
308
340
|
interface BridgingDepositParams {
|
|
309
341
|
inputTokenAddress: Address;
|
|
@@ -418,6 +450,8 @@ declare function assertIsBridgeQuoteAndPost(quote: CrossChainQuoteAndPost): asse
|
|
|
418
450
|
declare function assertIsQuoteAndPost(quote: CrossChainQuoteAndPost): asserts quote is QuoteAndPost;
|
|
419
451
|
declare function getPostHooks(fullAppData?: string): cowAppDataLatestScheme.CoWHook[];
|
|
420
452
|
declare function isAppDoc(appData: unknown): appData is cowAppDataLatestScheme.AppDataRootSchema;
|
|
453
|
+
declare function isHookBridgeProvider<Q extends BridgeQuoteResult>(provider: BridgeProvider<Q>): provider is HookBridgeProvider<Q>;
|
|
454
|
+
declare function isReceiverAccountBridgeProvider<Q extends BridgeQuoteResult>(provider: BridgeProvider<Q>): provider is ReceiverAccountBridgeProvider<Q>;
|
|
421
455
|
|
|
422
456
|
type BridgingSdkConfig = Required<Omit<BridgingSdkOptions, 'enableLogging' | 'cacheConfig'>>;
|
|
423
457
|
/**
|
|
@@ -851,7 +885,8 @@ interface AcrossBridgeProviderOptions {
|
|
|
851
885
|
interface AcrossQuoteResult extends BridgeQuoteResult {
|
|
852
886
|
suggestedFees: SuggestedFeesResponse;
|
|
853
887
|
}
|
|
854
|
-
declare class AcrossBridgeProvider implements
|
|
888
|
+
declare class AcrossBridgeProvider implements HookBridgeProvider<AcrossQuoteResult> {
|
|
889
|
+
type: "HookBridgeProvider";
|
|
855
890
|
protected api: AcrossApi;
|
|
856
891
|
protected cowShedSdk: CowShedSdk;
|
|
857
892
|
private supportedTokens;
|
|
@@ -1171,8 +1206,9 @@ interface BungeeQuoteResult extends BridgeQuoteResult {
|
|
|
1171
1206
|
bungeeQuote: BungeeQuote;
|
|
1172
1207
|
buildTx: BungeeBuildTx;
|
|
1173
1208
|
}
|
|
1174
|
-
declare class BungeeBridgeProvider implements
|
|
1209
|
+
declare class BungeeBridgeProvider implements HookBridgeProvider<BungeeQuoteResult> {
|
|
1175
1210
|
private options;
|
|
1211
|
+
type: "HookBridgeProvider";
|
|
1176
1212
|
protected api: BungeeApi;
|
|
1177
1213
|
protected cowShedSdk: CowShedSdk;
|
|
1178
1214
|
constructor(options: BungeeBridgeProviderOptions, _adapter?: AbstractProviderAdapter);
|
|
@@ -1196,4 +1232,4 @@ declare class BungeeBridgeProvider implements BridgeProvider<BungeeQuoteResult>
|
|
|
1196
1232
|
private isExtraGasRequired;
|
|
1197
1233
|
}
|
|
1198
1234
|
|
|
1199
|
-
export { AcrossBridgeProvider, type AcrossBridgeProviderOptions, type AcrossQuoteResult, type BestQuoteProgressCallback, type BestQuoteProviderContext, type BridgeCallDetails, type BridgeCosts, type BridgeDeposit, type BridgeHook, BridgeOrderParsingError, type BridgeProvider, BridgeProviderError, type BridgeProviderInfo, BridgeProviderQuoteError, type BridgeQuoteAmountsAndCosts, type BridgeQuoteAndPost, BridgeQuoteErrors, type BridgeQuoteResult, type BridgeQuoteResults, BridgeStatus, type BridgeStatusResult, type BridgingDepositParams, BridgingSdk, BungeeBridgeProvider, type BungeeBridgeProviderOptions, type BungeeQuoteResult, type BuyTokensParams, COW_SHED_PROXY_CREATION_GAS, type CrossChainOrder, type CrossChainQuoteAndPost, DEFAULT_EXTRA_GAS_FOR_HOOK_ESTIMATION, DEFAULT_EXTRA_GAS_PROXY_CREATION, DEFAULT_GAS_COST_FOR_HOOK_ESTIMATION, type GetProviderBuyTokens, HOOK_DAPP_BRIDGE_PROVIDER_PREFIX, type MultiQuoteOptions, type MultiQuoteProgressCallback, type MultiQuoteRequest, type MultiQuoteResult, type ProviderQuoteContext, type QuoteBridgeRequest, type QuoteBridgeRequestWithoutAmount, RAW_PROVIDERS_FILES_PATH, assertIsBridgeQuoteAndPost, assertIsQuoteAndPost, getCrossChainOrder, getPostHooks, isAppDoc, isBridgeQuoteAndPost, isQuoteAndPost };
|
|
1235
|
+
export { AcrossBridgeProvider, type AcrossBridgeProviderOptions, type AcrossQuoteResult, type BestQuoteProgressCallback, type BestQuoteProviderContext, type BridgeCallDetails, type BridgeCosts, type BridgeDeposit, type BridgeHook, BridgeOrderParsingError, type BridgeProvider, BridgeProviderError, type BridgeProviderInfo, BridgeProviderQuoteError, type BridgeQuoteAmountsAndCosts, type BridgeQuoteAndPost, BridgeQuoteErrors, type BridgeQuoteResult, type BridgeQuoteResults, BridgeStatus, type BridgeStatusResult, type BridgingDepositParams, BridgingSdk, BungeeBridgeProvider, type BungeeBridgeProviderOptions, type BungeeQuoteResult, type BuyTokensParams, COW_SHED_PROXY_CREATION_GAS, type CrossChainOrder, type CrossChainQuoteAndPost, DEFAULT_EXTRA_GAS_FOR_HOOK_ESTIMATION, DEFAULT_EXTRA_GAS_PROXY_CREATION, DEFAULT_GAS_COST_FOR_HOOK_ESTIMATION, type GetProviderBuyTokens, HOOK_DAPP_BRIDGE_PROVIDER_PREFIX, type HookBridgeProvider, type MultiQuoteOptions, type MultiQuoteProgressCallback, type MultiQuoteRequest, type MultiQuoteResult, type ProviderQuoteContext, type QuoteBridgeRequest, type QuoteBridgeRequestWithoutAmount, RAW_PROVIDERS_FILES_PATH, type ReceiverAccountBridgeProvider, assertIsBridgeQuoteAndPost, assertIsQuoteAndPost, getCrossChainOrder, getPostHooks, isAppDoc, isBridgeQuoteAndPost, isHookBridgeProvider, isQuoteAndPost, isReceiverAccountBridgeProvider };
|