@avalabs/vm-module-types 0.8.0 → 0.10.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/balance.d.cts +2 -1
- package/dist/balance.d.ts +2 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/module.d.cts +5 -2
- package/dist/module.d.ts +5 -2
- package/dist/network-fee.d.cts +1 -0
- package/dist/network-fee.d.ts +1 -0
- package/package.json +2 -2
package/dist/balance.d.cts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { Network, Storage } from './common.cjs';
|
|
2
2
|
import { Error } from './error.cjs';
|
|
3
|
-
import {
|
|
3
|
+
import { TokenType, NetworkContractToken, NetworkToken } from './token.cjs';
|
|
4
4
|
import { PChainBalance, XChainBalances } from '@avalabs/glacier-sdk';
|
|
5
5
|
|
|
6
6
|
type GetBalancesParams = {
|
|
7
7
|
addresses: string[];
|
|
8
8
|
network: Network;
|
|
9
|
+
tokenTypes?: TokenType[];
|
|
9
10
|
customTokens?: NetworkContractToken[];
|
|
10
11
|
currency: string;
|
|
11
12
|
storage?: Storage;
|
package/dist/balance.d.ts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { Network, Storage } from './common.js';
|
|
2
2
|
import { Error } from './error.js';
|
|
3
|
-
import {
|
|
3
|
+
import { TokenType, NetworkContractToken, NetworkToken } from './token.js';
|
|
4
4
|
import { PChainBalance, XChainBalances } from '@avalabs/glacier-sdk';
|
|
5
5
|
|
|
6
6
|
type GetBalancesParams = {
|
|
7
7
|
addresses: string[];
|
|
8
8
|
network: Network;
|
|
9
|
+
tokenTypes?: TokenType[];
|
|
9
10
|
customTokens?: NetworkContractToken[];
|
|
10
11
|
currency: string;
|
|
11
12
|
storage?: Storage;
|
package/dist/index.d.cts
CHANGED
|
@@ -3,7 +3,7 @@ export { RawSimplePriceResponse, RawSimplePriceResponseSchema, SimplePriceRespon
|
|
|
3
3
|
export { GetBalancesParams, GetBalancesResponse, NetworkTokenWithBalance, NftTokenWithBalance, TokenAttribute, TokenBalanceData, TokenMarketData, TokenWithBalance, TokenWithBalanceAVM, TokenWithBalanceBTC, TokenWithBalanceERC20, TokenWithBalanceEVM, TokenWithBalancePVM } from './balance.cjs';
|
|
4
4
|
export { Error } from './error.cjs';
|
|
5
5
|
export { Manifest, parseManifest } from './manifest.cjs';
|
|
6
|
-
export { AppInfo, ConstructorParams, Module } from './module.cjs';
|
|
6
|
+
export { AppInfo, ConstructorParams, Module, NetworkFeeParam } from './module.cjs';
|
|
7
7
|
export { NetworkFees } from './network-fee.cjs';
|
|
8
8
|
export { AddressItem, Alert, AlertDetails, AlertType, ApprovalController, ApprovalParams, ApprovalResponse, BaseDetailItem, BitcoinTransactionData, BtcTxUpdateFn, CurrencyItem, DappInfo, DataItem, DateItem, DetailItem, DetailItemType, DetailSection, DisplayData, EvmTxUpdateFn, LinkItem, LinkItemValue, MessageTypeProperty, MessageTypes, NodeIDItem, RpcError, RpcMethod, RpcRequest, RpcResponse, SigningData, SigningResult, TextItem, TypedData, TypedDataV1 } from './rpc.cjs';
|
|
9
9
|
export { ERC1155Token, ERC20Token, ERC721Token, NONERCToken, NetworkContractToken, NetworkToken, TokenType } from './token.cjs';
|
package/dist/index.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ export { RawSimplePriceResponse, RawSimplePriceResponseSchema, SimplePriceRespon
|
|
|
3
3
|
export { GetBalancesParams, GetBalancesResponse, NetworkTokenWithBalance, NftTokenWithBalance, TokenAttribute, TokenBalanceData, TokenMarketData, TokenWithBalance, TokenWithBalanceAVM, TokenWithBalanceBTC, TokenWithBalanceERC20, TokenWithBalanceEVM, TokenWithBalancePVM } from './balance.js';
|
|
4
4
|
export { Error } from './error.js';
|
|
5
5
|
export { Manifest, parseManifest } from './manifest.js';
|
|
6
|
-
export { AppInfo, ConstructorParams, Module } from './module.js';
|
|
6
|
+
export { AppInfo, ConstructorParams, Module, NetworkFeeParam } from './module.js';
|
|
7
7
|
export { NetworkFees } from './network-fee.js';
|
|
8
8
|
export { AddressItem, Alert, AlertDetails, AlertType, ApprovalController, ApprovalParams, ApprovalResponse, BaseDetailItem, BitcoinTransactionData, BtcTxUpdateFn, CurrencyItem, DappInfo, DataItem, DateItem, DetailItem, DetailItemType, DetailSection, DisplayData, EvmTxUpdateFn, LinkItem, LinkItemValue, MessageTypeProperty, MessageTypes, NodeIDItem, RpcError, RpcMethod, RpcRequest, RpcResponse, SigningData, SigningResult, TextItem, TypedData, TypedDataV1 } from './rpc.js';
|
|
9
9
|
export { ERC1155Token, ERC20Token, ERC721Token, NONERCToken, NetworkContractToken, NetworkToken, TokenType } from './token.js';
|
package/dist/module.d.cts
CHANGED
|
@@ -23,15 +23,18 @@ type ConstructorParams = {
|
|
|
23
23
|
environment: Environment;
|
|
24
24
|
appInfo: AppInfo;
|
|
25
25
|
};
|
|
26
|
+
type NetworkFeeParam = Network & {
|
|
27
|
+
caipId?: string;
|
|
28
|
+
};
|
|
26
29
|
interface Module {
|
|
27
30
|
getProvider: (network: Network) => JsonRpcBatchInternal | BitcoinProvider | Avalanche.JsonRpcProvider;
|
|
28
31
|
getManifest: () => Manifest | undefined;
|
|
29
32
|
getBalances: (params: GetBalancesParams) => Promise<GetBalancesResponse>;
|
|
30
33
|
getTransactionHistory: (params: GetTransactionHistory) => Promise<TransactionHistoryResponse>;
|
|
31
|
-
getNetworkFee: (network:
|
|
34
|
+
getNetworkFee: (network: NetworkFeeParam) => Promise<NetworkFees>;
|
|
32
35
|
getAddress: (params: GetAddressParams) => Promise<GetAddressResponse>;
|
|
33
36
|
getTokens: (network: Network) => Promise<NetworkContractToken[]>;
|
|
34
37
|
onRpcRequest: (request: RpcRequest, chain: Network) => Promise<RpcResponse>;
|
|
35
38
|
}
|
|
36
39
|
|
|
37
|
-
export { AppInfo, ConstructorParams, Module };
|
|
40
|
+
export { AppInfo, ConstructorParams, Module, NetworkFeeParam };
|
package/dist/module.d.ts
CHANGED
|
@@ -23,15 +23,18 @@ type ConstructorParams = {
|
|
|
23
23
|
environment: Environment;
|
|
24
24
|
appInfo: AppInfo;
|
|
25
25
|
};
|
|
26
|
+
type NetworkFeeParam = Network & {
|
|
27
|
+
caipId?: string;
|
|
28
|
+
};
|
|
26
29
|
interface Module {
|
|
27
30
|
getProvider: (network: Network) => JsonRpcBatchInternal | BitcoinProvider | Avalanche.JsonRpcProvider;
|
|
28
31
|
getManifest: () => Manifest | undefined;
|
|
29
32
|
getBalances: (params: GetBalancesParams) => Promise<GetBalancesResponse>;
|
|
30
33
|
getTransactionHistory: (params: GetTransactionHistory) => Promise<TransactionHistoryResponse>;
|
|
31
|
-
getNetworkFee: (network:
|
|
34
|
+
getNetworkFee: (network: NetworkFeeParam) => Promise<NetworkFees>;
|
|
32
35
|
getAddress: (params: GetAddressParams) => Promise<GetAddressResponse>;
|
|
33
36
|
getTokens: (network: Network) => Promise<NetworkContractToken[]>;
|
|
34
37
|
onRpcRequest: (request: RpcRequest, chain: Network) => Promise<RpcResponse>;
|
|
35
38
|
}
|
|
36
39
|
|
|
37
|
-
export { AppInfo, ConstructorParams, Module };
|
|
40
|
+
export { AppInfo, ConstructorParams, Module, NetworkFeeParam };
|
package/dist/network-fee.d.cts
CHANGED
package/dist/network-fee.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@avalabs/vm-module-types",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"main": "dist/index.cjs",
|
|
5
5
|
"module": "dist/index.js",
|
|
6
6
|
"typings": "dist/index.d.ts",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"eslint-config-custom": "0.0.1"
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
|
-
"ethers": "
|
|
29
|
+
"ethers": "6.8.1"
|
|
30
30
|
},
|
|
31
31
|
"scripts": {
|
|
32
32
|
"build": "tsup",
|