@ember-finance/sdk 2.21.0-ccip.0 → 2.21.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/src/abis/index.d.ts +1 -3
- package/dist/src/abis/index.js +1 -4
- package/dist/src/api/v2/models/account-transaction-transaction-data.d.ts +1 -2
- package/dist/src/api/v2/models/account-transaction.d.ts +0 -2
- package/dist/src/api/v2/models/account-transaction.js +1 -3
- package/dist/src/api/v2/models/chain.d.ts +0 -6
- package/dist/src/api/v2/models/evm-contracts.d.ts +0 -9
- package/dist/src/api/v2/models/evm-oftadapter.d.ts +0 -11
- package/dist/src/api/v2/models/evm-oftadapter.js +1 -4
- package/dist/src/api/v2/models/evm-oftpeer.d.ts +0 -12
- package/dist/src/api/v2/models/index.d.ts +0 -4
- package/dist/src/api/v2/models/index.js +0 -4
- package/dist/src/evm-vaults/interfaces/index.d.ts +0 -39
- package/dist/src/evm-vaults/on-chain-calls/tx-builder.d.ts +1 -15
- package/dist/src/evm-vaults/on-chain-calls/tx-builder.js +0 -36
- package/dist/src/evm-vaults/on-chain-calls/user.d.ts +1 -40
- package/dist/src/evm-vaults/on-chain-calls/user.js +0 -75
- package/dist/src/evm-vaults/on-chain-calls/vault-reader.d.ts +1 -14
- package/dist/src/evm-vaults/on-chain-calls/vault-reader.js +0 -30
- package/dist/src/evm-vaults/utils/deployment-parser.d.ts +1 -46
- package/dist/src/evm-vaults/utils/deployment-parser.js +0 -74
- package/dist/src/evm-vaults/utils/index.d.ts +0 -1
- package/dist/src/evm-vaults/utils/index.js +0 -1
- package/dist/src/sui-vaults/on-chain-calls/operator.d.ts +0 -63
- package/dist/src/sui-vaults/on-chain-calls/operator.js +0 -90
- package/dist/src/sui-vaults/on-chain-calls/tx-builder.d.ts +0 -120
- package/dist/src/sui-vaults/on-chain-calls/tx-builder.js +6 -357
- package/dist/src/sui-vaults/on-chain-calls/user.d.ts +0 -58
- package/dist/src/sui-vaults/on-chain-calls/user.js +3 -96
- package/dist/src/sui-vaults/on-chain-calls/vault-admin.d.ts +0 -21
- package/dist/src/sui-vaults/on-chain-calls/vault-admin.js +0 -32
- package/package.json +1 -1
- package/dist/src/abis/CcipRouter.json +0 -58
- package/dist/src/api/v2/models/bridge-transaction.d.ts +0 -50
- package/dist/src/api/v2/models/bridge-transaction.js +0 -14
- package/dist/src/api/v2/models/evm-ccip-lane.d.ts +0 -73
- package/dist/src/api/v2/models/evm-ccip-lane.js +0 -14
- package/dist/src/api/v2/models/evm-ccip-rate-limits.d.ts +0 -36
- package/dist/src/api/v2/models/evm-ccip-rate-limits.js +0 -14
- package/dist/src/api/v2/models/evm-ccip-token-pool.d.ts +0 -122
- package/dist/src/api/v2/models/evm-ccip-token-pool.js +0 -17
- package/dist/src/evm-vaults/utils/ccip.d.ts +0 -23
- package/dist/src/evm-vaults/utils/ccip.js +0 -32
|
@@ -326,15 +326,6 @@ export declare class VaultAdminCalls extends OnChainCalls {
|
|
|
326
326
|
* @returns OnChainCallResponse
|
|
327
327
|
*/
|
|
328
328
|
atomicSetStrategySuilend(vaultId: string, poolCoinType: string, lendingMarketId: string, reserveArrayIndex: NumStr, options?: IVaultOptionalParams & SuiTransactionBlockResponseOptions): Promise<OnChainCallResponse>;
|
|
329
|
-
/**
|
|
330
|
-
* Set the AlphaLend strategy for an atomic vault
|
|
331
|
-
* @param vaultId The id of the atomic vault
|
|
332
|
-
* @param lendingProtocolId Object id of the AlphaLend LendingProtocol
|
|
333
|
-
* @param marketId The AlphaLend market id
|
|
334
|
-
* @param options Optional tx execution params
|
|
335
|
-
* @returns OnChainCallResponse
|
|
336
|
-
*/
|
|
337
|
-
atomicSetStrategyAlphalend(vaultId: string, lendingProtocolId: string, marketId: NumStr, options?: IVaultOptionalParams & SuiTransactionBlockResponseOptions): Promise<OnChainCallResponse>;
|
|
338
329
|
/**
|
|
339
330
|
* Switch an atomic vault from the Suilend strategy to STRATEGY_NONE,
|
|
340
331
|
* draining cTokens back into the vault balance
|
|
@@ -345,16 +336,4 @@ export declare class VaultAdminCalls extends OnChainCalls {
|
|
|
345
336
|
* @returns OnChainCallResponse
|
|
346
337
|
*/
|
|
347
338
|
atomicSetStrategyNoneFromSuilend(vaultId: string, poolCoinType: string, lendingMarketId: string, options?: IVaultOptionalParams & SuiTransactionBlockResponseOptions): Promise<OnChainCallResponse>;
|
|
348
|
-
/**
|
|
349
|
-
* Switch an atomic vault from the AlphaLend strategy to STRATEGY_NONE,
|
|
350
|
-
* draining the full position collateral back into the vault balance
|
|
351
|
-
* @param vaultId The id of the atomic vault
|
|
352
|
-
* @param lendingProtocolId Object id of the AlphaLend LendingProtocol
|
|
353
|
-
* @param acceptResidual Abandon a dust residual rather than aborting the exit.
|
|
354
|
-
* Only pass true deliberately: the residual is forfeited, and the exit burns the
|
|
355
|
-
* PositionCap that could otherwise reach it.
|
|
356
|
-
* @param options Optional tx execution params
|
|
357
|
-
* @returns OnChainCallResponse
|
|
358
|
-
*/
|
|
359
|
-
atomicSetStrategyNoneFromAlphalend(vaultId: string, lendingProtocolId: string, acceptResidual: boolean, options?: IVaultOptionalParams & SuiTransactionBlockResponseOptions): Promise<OnChainCallResponse>;
|
|
360
339
|
}
|
|
@@ -549,22 +549,6 @@ export class VaultAdminCalls extends OnChainCalls {
|
|
|
549
549
|
this.txBuilder.atomicSetStrategySuilend(vaultId, poolCoinType, lendingMarketId, reserveArrayIndex, { ...options, txBlock: txb });
|
|
550
550
|
return this.execCall(txb, options);
|
|
551
551
|
}
|
|
552
|
-
/**
|
|
553
|
-
* Set the AlphaLend strategy for an atomic vault
|
|
554
|
-
* @param vaultId The id of the atomic vault
|
|
555
|
-
* @param lendingProtocolId Object id of the AlphaLend LendingProtocol
|
|
556
|
-
* @param marketId The AlphaLend market id
|
|
557
|
-
* @param options Optional tx execution params
|
|
558
|
-
* @returns OnChainCallResponse
|
|
559
|
-
*/
|
|
560
|
-
async atomicSetStrategyAlphalend(vaultId, lendingProtocolId, marketId, options) {
|
|
561
|
-
const txb = options?.txBlock || new TransactionBlock();
|
|
562
|
-
this.txBuilder.atomicSetStrategyAlphalend(vaultId, lendingProtocolId, marketId, {
|
|
563
|
-
...options,
|
|
564
|
-
txBlock: txb
|
|
565
|
-
});
|
|
566
|
-
return this.execCall(txb, options);
|
|
567
|
-
}
|
|
568
552
|
/**
|
|
569
553
|
* Switch an atomic vault from the Suilend strategy to STRATEGY_NONE,
|
|
570
554
|
* draining cTokens back into the vault balance
|
|
@@ -579,20 +563,4 @@ export class VaultAdminCalls extends OnChainCalls {
|
|
|
579
563
|
this.txBuilder.atomicSetStrategyNoneFromSuilend(vaultId, poolCoinType, lendingMarketId, { ...options, txBlock: txb });
|
|
580
564
|
return this.execCall(txb, options);
|
|
581
565
|
}
|
|
582
|
-
/**
|
|
583
|
-
* Switch an atomic vault from the AlphaLend strategy to STRATEGY_NONE,
|
|
584
|
-
* draining the full position collateral back into the vault balance
|
|
585
|
-
* @param vaultId The id of the atomic vault
|
|
586
|
-
* @param lendingProtocolId Object id of the AlphaLend LendingProtocol
|
|
587
|
-
* @param acceptResidual Abandon a dust residual rather than aborting the exit.
|
|
588
|
-
* Only pass true deliberately: the residual is forfeited, and the exit burns the
|
|
589
|
-
* PositionCap that could otherwise reach it.
|
|
590
|
-
* @param options Optional tx execution params
|
|
591
|
-
* @returns OnChainCallResponse
|
|
592
|
-
*/
|
|
593
|
-
async atomicSetStrategyNoneFromAlphalend(vaultId, lendingProtocolId, acceptResidual, options) {
|
|
594
|
-
const txb = options?.txBlock || new TransactionBlock();
|
|
595
|
-
this.txBuilder.atomicSetStrategyNoneFromAlphalend(vaultId, lendingProtocolId, acceptResidual, { ...options, txBlock: txb });
|
|
596
|
-
return this.execCall(txb, options);
|
|
597
|
-
}
|
|
598
566
|
}
|
package/package.json
CHANGED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"abi": [
|
|
3
|
-
{
|
|
4
|
-
"type": "function",
|
|
5
|
-
"name": "getFee",
|
|
6
|
-
"stateMutability": "view",
|
|
7
|
-
"inputs": [
|
|
8
|
-
{ "name": "destChainSelector", "type": "uint64" },
|
|
9
|
-
{
|
|
10
|
-
"name": "message",
|
|
11
|
-
"type": "tuple",
|
|
12
|
-
"components": [
|
|
13
|
-
{ "name": "receiver", "type": "bytes" },
|
|
14
|
-
{ "name": "data", "type": "bytes" },
|
|
15
|
-
{
|
|
16
|
-
"name": "tokenAmounts",
|
|
17
|
-
"type": "tuple[]",
|
|
18
|
-
"components": [
|
|
19
|
-
{ "name": "token", "type": "address" },
|
|
20
|
-
{ "name": "amount", "type": "uint256" }
|
|
21
|
-
]
|
|
22
|
-
},
|
|
23
|
-
{ "name": "feeToken", "type": "address" },
|
|
24
|
-
{ "name": "extraArgs", "type": "bytes" }
|
|
25
|
-
]
|
|
26
|
-
}
|
|
27
|
-
],
|
|
28
|
-
"outputs": [{ "name": "fee", "type": "uint256" }]
|
|
29
|
-
},
|
|
30
|
-
{
|
|
31
|
-
"type": "function",
|
|
32
|
-
"name": "ccipSend",
|
|
33
|
-
"stateMutability": "payable",
|
|
34
|
-
"inputs": [
|
|
35
|
-
{ "name": "destinationChainSelector", "type": "uint64" },
|
|
36
|
-
{
|
|
37
|
-
"name": "message",
|
|
38
|
-
"type": "tuple",
|
|
39
|
-
"components": [
|
|
40
|
-
{ "name": "receiver", "type": "bytes" },
|
|
41
|
-
{ "name": "data", "type": "bytes" },
|
|
42
|
-
{
|
|
43
|
-
"name": "tokenAmounts",
|
|
44
|
-
"type": "tuple[]",
|
|
45
|
-
"components": [
|
|
46
|
-
{ "name": "token", "type": "address" },
|
|
47
|
-
{ "name": "amount", "type": "uint256" }
|
|
48
|
-
]
|
|
49
|
-
},
|
|
50
|
-
{ "name": "feeToken", "type": "address" },
|
|
51
|
-
{ "name": "extraArgs", "type": "bytes" }
|
|
52
|
-
]
|
|
53
|
-
}
|
|
54
|
-
],
|
|
55
|
-
"outputs": [{ "name": "messageId", "type": "bytes32" }]
|
|
56
|
-
}
|
|
57
|
-
]
|
|
58
|
-
}
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Ember Protocol Vaults API
|
|
3
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 2.0.0
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
import type { Asset } from "./asset.js";
|
|
13
|
-
import type { VaultSlice } from "./vault-slice.js";
|
|
14
|
-
/**
|
|
15
|
-
* Vault shares moving between chains. BridgeOut burns them on the origin chain, BridgeIn mints them on the destination; the two are separate transactions on separate chains rather than one record, because each chain reports its own half. Carries no transport discriminator: a vault has exactly one bridge, so which one carried a given transfer is a property of the vault rather than of the transaction. Read it from the vault\'s own bridge config.
|
|
16
|
-
* @export
|
|
17
|
-
* @interface BridgeTransaction
|
|
18
|
-
*/
|
|
19
|
-
export interface BridgeTransaction {
|
|
20
|
-
/**
|
|
21
|
-
* The timestamp of the event
|
|
22
|
-
* @type {number}
|
|
23
|
-
* @memberof BridgeTransaction
|
|
24
|
-
*/
|
|
25
|
-
timestamp?: number;
|
|
26
|
-
/**
|
|
27
|
-
* The amount of shares bridged
|
|
28
|
-
* @type {string}
|
|
29
|
-
* @memberof BridgeTransaction
|
|
30
|
-
*/
|
|
31
|
-
sharesAmount?: string;
|
|
32
|
-
/**
|
|
33
|
-
*
|
|
34
|
-
* @type {Asset}
|
|
35
|
-
* @memberof BridgeTransaction
|
|
36
|
-
*/
|
|
37
|
-
sharesCoin?: Asset;
|
|
38
|
-
/**
|
|
39
|
-
*
|
|
40
|
-
* @type {VaultSlice}
|
|
41
|
-
* @memberof BridgeTransaction
|
|
42
|
-
*/
|
|
43
|
-
vault?: VaultSlice;
|
|
44
|
-
/**
|
|
45
|
-
* The transaction hash on this chain
|
|
46
|
-
* @type {string}
|
|
47
|
-
* @memberof BridgeTransaction
|
|
48
|
-
*/
|
|
49
|
-
txDigest?: string;
|
|
50
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/* tslint:disable */
|
|
2
|
-
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* Ember Protocol Vaults API
|
|
5
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
-
*
|
|
7
|
-
* The version of the OpenAPI document: 2.0.0
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
-
* https://openapi-generator.tech
|
|
12
|
-
* Do not edit the class manually.
|
|
13
|
-
*/
|
|
14
|
-
export {};
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Ember Protocol Vaults API
|
|
3
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 2.0.0
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
import type { EvmCcipRateLimits } from "./evm-ccip-rate-limits.js";
|
|
13
|
-
/**
|
|
14
|
-
* One configured destination. remoteNetwork and remoteAddress mean the same as on an OFT peer; the rest has no LayerZero equivalent.
|
|
15
|
-
* @export
|
|
16
|
-
* @interface EvmCcipLane
|
|
17
|
-
*/
|
|
18
|
-
export interface EvmCcipLane {
|
|
19
|
-
/**
|
|
20
|
-
* The remote chain\'s network name, e.g. atlantic. The map key is a CCIP chain selector, so read this instead.
|
|
21
|
-
* @type {string}
|
|
22
|
-
* @memberof EvmCcipLane
|
|
23
|
-
*/
|
|
24
|
-
remoteNetwork?: string;
|
|
25
|
-
/**
|
|
26
|
-
* The bridge contract at the far end, as a plain address. Same meaning as remoteAddress on an OFT peer.
|
|
27
|
-
* @type {string}
|
|
28
|
-
* @memberof EvmCcipLane
|
|
29
|
-
*/
|
|
30
|
-
remoteAddress?: string;
|
|
31
|
-
/**
|
|
32
|
-
* The remote chain\'s CCIP selector, carried as a string because it is 64-bit
|
|
33
|
-
* @type {string}
|
|
34
|
-
* @memberof EvmCcipLane
|
|
35
|
-
*/
|
|
36
|
-
remoteChainSelector?: string;
|
|
37
|
-
/**
|
|
38
|
-
* The remote CCIP token pool address
|
|
39
|
-
* @type {string}
|
|
40
|
-
* @memberof EvmCcipLane
|
|
41
|
-
*/
|
|
42
|
-
remotePool?: string;
|
|
43
|
-
/**
|
|
44
|
-
* The remote receipt token address
|
|
45
|
-
* @type {string}
|
|
46
|
-
* @memberof EvmCcipLane
|
|
47
|
-
*/
|
|
48
|
-
remoteToken?: string;
|
|
49
|
-
/**
|
|
50
|
-
*
|
|
51
|
-
* @type {EvmCcipRateLimits}
|
|
52
|
-
* @memberof EvmCcipLane
|
|
53
|
-
*/
|
|
54
|
-
rateLimits?: EvmCcipRateLimits;
|
|
55
|
-
/**
|
|
56
|
-
* The timestamp when the lane was configured
|
|
57
|
-
* @type {string}
|
|
58
|
-
* @memberof EvmCcipLane
|
|
59
|
-
*/
|
|
60
|
-
configuredAt?: string;
|
|
61
|
-
/**
|
|
62
|
-
* The transaction hash of the lane configuration
|
|
63
|
-
* @type {string}
|
|
64
|
-
* @memberof EvmCcipLane
|
|
65
|
-
*/
|
|
66
|
-
txHash?: string;
|
|
67
|
-
/**
|
|
68
|
-
* The block number of the lane configuration
|
|
69
|
-
* @type {number}
|
|
70
|
-
* @memberof EvmCcipLane
|
|
71
|
-
*/
|
|
72
|
-
blockNumber?: number;
|
|
73
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/* tslint:disable */
|
|
2
|
-
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* Ember Protocol Vaults API
|
|
5
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
-
*
|
|
7
|
-
* The version of the OpenAPI document: 2.0.0
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
-
* https://openapi-generator.tech
|
|
12
|
-
* Do not edit the class manually.
|
|
13
|
-
*/
|
|
14
|
-
export {};
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Ember Protocol Vaults API
|
|
3
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 2.0.0
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
* Per-lane outbound rate limiting. Has no LayerZero equivalent, so it is deliberately not flattened into a shared shape.
|
|
14
|
-
* @export
|
|
15
|
-
* @interface EvmCcipRateLimits
|
|
16
|
-
*/
|
|
17
|
-
export interface EvmCcipRateLimits {
|
|
18
|
-
/**
|
|
19
|
-
* Whether rate limiting is enforced on this lane
|
|
20
|
-
* @type {boolean}
|
|
21
|
-
* @memberof EvmCcipRateLimits
|
|
22
|
-
*/
|
|
23
|
-
enabled?: boolean;
|
|
24
|
-
/**
|
|
25
|
-
* Token bucket capacity, in receipt token base units
|
|
26
|
-
* @type {string}
|
|
27
|
-
* @memberof EvmCcipRateLimits
|
|
28
|
-
*/
|
|
29
|
-
capacity?: string;
|
|
30
|
-
/**
|
|
31
|
-
* Refill rate, in receipt token base units per second
|
|
32
|
-
* @type {string}
|
|
33
|
-
* @memberof EvmCcipRateLimits
|
|
34
|
-
*/
|
|
35
|
-
rate?: string;
|
|
36
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/* tslint:disable */
|
|
2
|
-
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* Ember Protocol Vaults API
|
|
5
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
-
*
|
|
7
|
-
* The version of the OpenAPI document: 2.0.0
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
-
* https://openapi-generator.tech
|
|
12
|
-
* Do not edit the class manually.
|
|
13
|
-
*/
|
|
14
|
-
export {};
|
|
@@ -1,122 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Ember Protocol Vaults API
|
|
3
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 2.0.0
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
import type { EvmCcipLane } from "./evm-ccip-lane.js";
|
|
13
|
-
/**
|
|
14
|
-
* The CCIP half of a vault\'s bridge, the counterpart to EvmOFTAdapter. A vault has one active transport; different vaults use different ones.
|
|
15
|
-
* @export
|
|
16
|
-
* @interface EvmCcipTokenPool
|
|
17
|
-
*/
|
|
18
|
-
export interface EvmCcipTokenPool {
|
|
19
|
-
/**
|
|
20
|
-
* The CCIP token pool contract address
|
|
21
|
-
* @type {string}
|
|
22
|
-
* @memberof EvmCcipTokenPool
|
|
23
|
-
*/
|
|
24
|
-
address?: string;
|
|
25
|
-
/**
|
|
26
|
-
* The contract name (e.g., EmberTokenPool)
|
|
27
|
-
* @type {string}
|
|
28
|
-
* @memberof EvmCcipTokenPool
|
|
29
|
-
*/
|
|
30
|
-
contractName?: string;
|
|
31
|
-
/**
|
|
32
|
-
* Which bridge this entry describes. Read this rather than inferring the transport from which map the entry was found in.
|
|
33
|
-
* @type {string}
|
|
34
|
-
* @memberof EvmCcipTokenPool
|
|
35
|
-
*/
|
|
36
|
-
bridgeTransport?: EvmCcipTokenPoolBridgeTransportEnum;
|
|
37
|
-
/**
|
|
38
|
-
* The pool\'s on-chain typeAndVersion (e.g., EmberBurnMintTokenPool 1.0.0)
|
|
39
|
-
* @type {string}
|
|
40
|
-
* @memberof EvmCcipTokenPool
|
|
41
|
-
*/
|
|
42
|
-
typeAndVersion?: string;
|
|
43
|
-
/**
|
|
44
|
-
* The key of the associated vault
|
|
45
|
-
* @type {string}
|
|
46
|
-
* @memberof EvmCcipTokenPool
|
|
47
|
-
*/
|
|
48
|
-
vaultKey?: string;
|
|
49
|
-
/**
|
|
50
|
-
* The address of the associated vault
|
|
51
|
-
* @type {string}
|
|
52
|
-
* @memberof EvmCcipTokenPool
|
|
53
|
-
*/
|
|
54
|
-
vaultAddress?: string;
|
|
55
|
-
/**
|
|
56
|
-
* The receipt token symbol
|
|
57
|
-
* @type {string}
|
|
58
|
-
* @memberof EvmCcipTokenPool
|
|
59
|
-
*/
|
|
60
|
-
receiptTokenSymbol?: string;
|
|
61
|
-
/**
|
|
62
|
-
* The receipt token decimals
|
|
63
|
-
* @type {number}
|
|
64
|
-
* @memberof EvmCcipTokenPool
|
|
65
|
-
*/
|
|
66
|
-
decimals?: number;
|
|
67
|
-
/**
|
|
68
|
-
* The CCIP Router for this chain
|
|
69
|
-
* @type {string}
|
|
70
|
-
* @memberof EvmCcipTokenPool
|
|
71
|
-
*/
|
|
72
|
-
router?: string;
|
|
73
|
-
/**
|
|
74
|
-
* The CCIP RMN proxy for this chain
|
|
75
|
-
* @type {string}
|
|
76
|
-
* @memberof EvmCcipTokenPool
|
|
77
|
-
*/
|
|
78
|
-
rmnProxy?: string;
|
|
79
|
-
/**
|
|
80
|
-
* The CCIP token admin registry for this chain
|
|
81
|
-
* @type {string}
|
|
82
|
-
* @memberof EvmCcipTokenPool
|
|
83
|
-
*/
|
|
84
|
-
tokenAdminRegistry?: string;
|
|
85
|
-
/**
|
|
86
|
-
* This chain\'s CCIP selector. A 64-bit value, carried as a string because it exceeds what a JSON number holds exactly.
|
|
87
|
-
* @type {string}
|
|
88
|
-
* @memberof EvmCcipTokenPool
|
|
89
|
-
*/
|
|
90
|
-
chainSelector?: string;
|
|
91
|
-
/**
|
|
92
|
-
* The owner address
|
|
93
|
-
* @type {string}
|
|
94
|
-
* @memberof EvmCcipTokenPool
|
|
95
|
-
*/
|
|
96
|
-
owner?: string;
|
|
97
|
-
/**
|
|
98
|
-
* The deployment timestamp
|
|
99
|
-
* @type {string}
|
|
100
|
-
* @memberof EvmCcipTokenPool
|
|
101
|
-
*/
|
|
102
|
-
deployedAt?: string;
|
|
103
|
-
/**
|
|
104
|
-
* The block number at which the pool was deployed
|
|
105
|
-
* @type {number}
|
|
106
|
-
* @memberof EvmCcipTokenPool
|
|
107
|
-
*/
|
|
108
|
-
deploymentBlockNumber?: number;
|
|
109
|
-
/**
|
|
110
|
-
* Map of configured destinations by remote CCIP chain selector
|
|
111
|
-
* @type {{ [key: string]: EvmCcipLane; }}
|
|
112
|
-
* @memberof EvmCcipTokenPool
|
|
113
|
-
*/
|
|
114
|
-
lanes?: {
|
|
115
|
-
[key: string]: EvmCcipLane;
|
|
116
|
-
};
|
|
117
|
-
}
|
|
118
|
-
export declare const EvmCcipTokenPoolBridgeTransportEnum: {
|
|
119
|
-
readonly LayerZero: "LayerZero";
|
|
120
|
-
readonly Ccip: "CCIP";
|
|
121
|
-
};
|
|
122
|
-
export type EvmCcipTokenPoolBridgeTransportEnum = (typeof EvmCcipTokenPoolBridgeTransportEnum)[keyof typeof EvmCcipTokenPoolBridgeTransportEnum];
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/* tslint:disable */
|
|
2
|
-
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* Ember Protocol Vaults API
|
|
5
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
-
*
|
|
7
|
-
* The version of the OpenAPI document: 2.0.0
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
-
* https://openapi-generator.tech
|
|
12
|
-
* Do not edit the class manually.
|
|
13
|
-
*/
|
|
14
|
-
export const EvmCcipTokenPoolBridgeTransportEnum = {
|
|
15
|
-
LayerZero: "LayerZero",
|
|
16
|
-
Ccip: "CCIP"
|
|
17
|
-
};
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/** The native currency, as CCIP names it when no fee token is given. */
|
|
2
|
-
export declare const ZERO_ADDRESS = "0x0000000000000000000000000000000000000000";
|
|
3
|
-
/**
|
|
4
|
-
* Encodes a receiver for a CCIP message.
|
|
5
|
-
*
|
|
6
|
-
* CCIP carries the receiver as `bytes` rather than `address`, because the far
|
|
7
|
-
* end of a lane need not be an EVM chain. On an EVM destination that is the
|
|
8
|
-
* address left-padded to 32 bytes, which is why the same account looks
|
|
9
|
-
* different on the two sides of a transfer.
|
|
10
|
-
*/
|
|
11
|
-
export declare const encodeCcipReceiver: (receiver: string) => string;
|
|
12
|
-
/**
|
|
13
|
-
* Encodes CCIP extraArgs.
|
|
14
|
-
*
|
|
15
|
-
* `allowOutOfOrderExecution` is true because a token transfer carries no
|
|
16
|
-
* message the destination has to apply in sequence; requiring ordering would
|
|
17
|
-
* make one stuck message block every later one on the lane.
|
|
18
|
-
*
|
|
19
|
-
* gasLimit is 0 by default: a plain token transfer runs no code on the
|
|
20
|
-
* destination beyond the pool's own mint, and paying for gas that is never used
|
|
21
|
-
* only raises the fee.
|
|
22
|
-
*/
|
|
23
|
-
export declare const encodeCcipExtraArgs: (destinationGasLimit?: bigint) => string;
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { AbiCoder, getAddress, zeroPadValue } from "ethers";
|
|
2
|
-
/** The native currency, as CCIP names it when no fee token is given. */
|
|
3
|
-
export const ZERO_ADDRESS = "0x0000000000000000000000000000000000000000";
|
|
4
|
-
/**
|
|
5
|
-
* Tag for CCIP's EVMExtraArgsV2, the first four bytes of
|
|
6
|
-
* keccak256("CCIP EVMExtraArgsV2"). Verified against a deployed ramp.
|
|
7
|
-
*/
|
|
8
|
-
const EVM_EXTRA_ARGS_V2_TAG = "0x181dcf10";
|
|
9
|
-
/**
|
|
10
|
-
* Encodes a receiver for a CCIP message.
|
|
11
|
-
*
|
|
12
|
-
* CCIP carries the receiver as `bytes` rather than `address`, because the far
|
|
13
|
-
* end of a lane need not be an EVM chain. On an EVM destination that is the
|
|
14
|
-
* address left-padded to 32 bytes, which is why the same account looks
|
|
15
|
-
* different on the two sides of a transfer.
|
|
16
|
-
*/
|
|
17
|
-
export const encodeCcipReceiver = (receiver) => zeroPadValue(getAddress(receiver), 32);
|
|
18
|
-
/**
|
|
19
|
-
* Encodes CCIP extraArgs.
|
|
20
|
-
*
|
|
21
|
-
* `allowOutOfOrderExecution` is true because a token transfer carries no
|
|
22
|
-
* message the destination has to apply in sequence; requiring ordering would
|
|
23
|
-
* make one stuck message block every later one on the lane.
|
|
24
|
-
*
|
|
25
|
-
* gasLimit is 0 by default: a plain token transfer runs no code on the
|
|
26
|
-
* destination beyond the pool's own mint, and paying for gas that is never used
|
|
27
|
-
* only raises the fee.
|
|
28
|
-
*/
|
|
29
|
-
export const encodeCcipExtraArgs = (destinationGasLimit = 0n) => {
|
|
30
|
-
const encoded = AbiCoder.defaultAbiCoder().encode(["uint256", "bool"], [destinationGasLimit, true]);
|
|
31
|
-
return EVM_EXTRA_ARGS_V2_TAG + encoded.slice(2);
|
|
32
|
-
};
|