@metamask/keyring-api 11.1.0 → 13.0.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/CHANGELOG.md +25 -1
- package/dist/api/account.cjs +7 -4
- package/dist/api/account.cjs.map +1 -1
- package/dist/api/account.d.cts +6 -1
- package/dist/api/account.d.cts.map +1 -1
- package/dist/api/account.d.mts +6 -1
- package/dist/api/account.d.mts.map +1 -1
- package/dist/api/account.mjs +7 -4
- package/dist/api/account.mjs.map +1 -1
- package/dist/api/asset.cjs +5 -6
- package/dist/api/asset.cjs.map +1 -1
- package/dist/api/asset.d.cts +2 -2
- package/dist/api/asset.d.cts.map +1 -1
- package/dist/api/asset.d.mts +2 -2
- package/dist/api/asset.d.mts.map +1 -1
- package/dist/api/asset.mjs +1 -2
- package/dist/api/asset.mjs.map +1 -1
- package/dist/api/balance.cjs +3 -4
- package/dist/api/balance.cjs.map +1 -1
- package/dist/api/balance.d.cts.map +1 -1
- package/dist/api/balance.d.mts.map +1 -1
- package/dist/api/balance.mjs +1 -2
- package/dist/api/balance.mjs.map +1 -1
- package/dist/api/caip.cjs +3 -3
- package/dist/api/caip.cjs.map +1 -1
- package/dist/api/caip.d.cts.map +1 -1
- package/dist/api/caip.d.mts.map +1 -1
- package/dist/api/caip.mjs +1 -1
- package/dist/api/caip.mjs.map +1 -1
- package/dist/api/index.cjs +1 -0
- package/dist/api/index.cjs.map +1 -1
- package/dist/api/index.d.cts +1 -0
- package/dist/api/index.d.cts.map +1 -1
- package/dist/api/index.d.mts +1 -0
- package/dist/api/index.d.mts.map +1 -1
- package/dist/api/index.mjs +1 -0
- package/dist/api/index.mjs.map +1 -1
- package/dist/api/keyring.cjs +2 -0
- package/dist/api/keyring.cjs.map +1 -1
- package/dist/api/keyring.d.cts +1 -1
- package/dist/api/keyring.d.cts.map +1 -1
- package/dist/api/keyring.d.mts +1 -1
- package/dist/api/keyring.d.mts.map +1 -1
- package/dist/api/keyring.mjs +2 -0
- package/dist/api/keyring.mjs.map +1 -1
- package/dist/{utils → api}/pagination.cjs +3 -3
- package/dist/api/pagination.cjs.map +1 -0
- package/dist/{utils → api}/pagination.d.cts +1 -1
- package/dist/api/pagination.d.cts.map +1 -0
- package/dist/{utils → api}/pagination.d.mts +1 -1
- package/dist/api/pagination.d.mts.map +1 -0
- package/dist/{utils → api}/pagination.mjs +1 -1
- package/dist/api/pagination.mjs.map +1 -0
- package/dist/api/request.cjs +6 -7
- package/dist/api/request.cjs.map +1 -1
- package/dist/api/request.d.cts +5 -5
- package/dist/api/request.d.cts.map +1 -1
- package/dist/api/request.d.mts +5 -5
- package/dist/api/request.d.mts.map +1 -1
- package/dist/api/request.mjs +1 -2
- package/dist/api/request.mjs.map +1 -1
- package/dist/api/response.cjs +6 -6
- package/dist/api/response.cjs.map +1 -1
- package/dist/api/response.d.cts +1 -1
- package/dist/api/response.d.cts.map +1 -1
- package/dist/api/response.d.mts +1 -1
- package/dist/api/response.d.mts.map +1 -1
- package/dist/api/response.mjs +1 -1
- package/dist/api/response.mjs.map +1 -1
- package/dist/api/transaction.cjs +7 -8
- package/dist/api/transaction.cjs.map +1 -1
- package/dist/api/transaction.d.cts +65 -65
- package/dist/api/transaction.d.cts.map +1 -1
- package/dist/api/transaction.d.mts +65 -65
- package/dist/api/transaction.d.mts.map +1 -1
- package/dist/api/transaction.mjs +1 -2
- package/dist/api/transaction.mjs.map +1 -1
- package/dist/btc/constants.cjs +17 -0
- package/dist/btc/constants.cjs.map +1 -0
- package/dist/btc/constants.d.cts +12 -0
- package/dist/btc/constants.d.cts.map +1 -0
- package/dist/btc/constants.d.mts +12 -0
- package/dist/btc/constants.d.mts.map +1 -0
- package/dist/btc/constants.mjs +14 -0
- package/dist/btc/constants.mjs.map +1 -0
- package/dist/btc/index.cjs +1 -0
- package/dist/btc/index.cjs.map +1 -1
- package/dist/btc/index.d.cts +1 -0
- package/dist/btc/index.d.cts.map +1 -1
- package/dist/btc/index.d.mts +1 -0
- package/dist/btc/index.d.mts.map +1 -1
- package/dist/btc/index.mjs +1 -0
- package/dist/btc/index.mjs.map +1 -1
- package/dist/btc/types.cjs +2 -2
- package/dist/btc/types.cjs.map +1 -1
- package/dist/btc/types.d.cts +3 -1
- package/dist/btc/types.d.cts.map +1 -1
- package/dist/btc/types.d.mts +3 -1
- package/dist/btc/types.d.mts.map +1 -1
- package/dist/btc/types.mjs +2 -2
- package/dist/btc/types.mjs.map +1 -1
- package/dist/eth/constants.cjs +13 -0
- package/dist/eth/constants.cjs.map +1 -0
- package/dist/eth/constants.d.cts +8 -0
- package/dist/eth/constants.d.cts.map +1 -0
- package/dist/eth/constants.d.mts +8 -0
- package/dist/eth/constants.d.mts.map +1 -0
- package/dist/eth/constants.mjs +10 -0
- package/dist/eth/constants.mjs.map +1 -0
- package/dist/eth/erc4337/types.cjs +10 -11
- package/dist/eth/erc4337/types.cjs.map +1 -1
- package/dist/eth/erc4337/types.d.cts +5 -5
- package/dist/eth/erc4337/types.d.cts.map +1 -1
- package/dist/eth/erc4337/types.d.mts +5 -5
- package/dist/eth/erc4337/types.d.mts.map +1 -1
- package/dist/eth/erc4337/types.mjs +1 -2
- package/dist/eth/erc4337/types.mjs.map +1 -1
- package/dist/eth/index.cjs +1 -0
- package/dist/eth/index.cjs.map +1 -1
- package/dist/eth/index.d.cts +1 -0
- package/dist/eth/index.d.cts.map +1 -1
- package/dist/eth/index.d.mts +1 -0
- package/dist/eth/index.d.mts.map +1 -1
- package/dist/eth/index.mjs +1 -0
- package/dist/eth/index.mjs.map +1 -1
- package/dist/eth/types.cjs +11 -6
- package/dist/eth/types.cjs.map +1 -1
- package/dist/eth/types.d.cts +10 -2
- package/dist/eth/types.d.cts.map +1 -1
- package/dist/eth/types.d.mts +10 -2
- package/dist/eth/types.d.mts.map +1 -1
- package/dist/eth/types.mjs +7 -2
- package/dist/eth/types.mjs.map +1 -1
- package/dist/eth/utils.cjs.map +1 -1
- package/dist/eth/utils.d.cts.map +1 -1
- package/dist/eth/utils.d.mts.map +1 -1
- package/dist/eth/utils.mjs.map +1 -1
- package/dist/events.cjs +67 -1
- package/dist/events.cjs.map +1 -1
- package/dist/events.d.cts +169 -0
- package/dist/events.d.cts.map +1 -1
- package/dist/events.d.mts +169 -0
- package/dist/events.d.mts.map +1 -1
- package/dist/events.mjs +66 -0
- package/dist/events.mjs.map +1 -1
- package/dist/index.cjs +2 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -9
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts +3 -9
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +2 -8
- package/dist/index.mjs.map +1 -1
- package/dist/{internal/api.cjs → rpc.cjs} +71 -42
- package/dist/rpc.cjs.map +1 -0
- package/dist/{internal/api.d.cts → rpc.d.cts} +141 -104
- package/dist/rpc.d.cts.map +1 -0
- package/dist/{internal/api.d.mts → rpc.d.mts} +141 -104
- package/dist/rpc.d.mts.map +1 -0
- package/dist/{internal/api.mjs → rpc.mjs} +33 -5
- package/dist/rpc.mjs.map +1 -0
- package/dist/sol/constants.cjs +15 -0
- package/dist/sol/constants.cjs.map +1 -0
- package/dist/sol/constants.d.cts +10 -0
- package/dist/sol/constants.d.cts.map +1 -0
- package/dist/sol/constants.d.mts +10 -0
- package/dist/sol/constants.d.mts.map +1 -0
- package/dist/sol/constants.mjs +12 -0
- package/dist/sol/constants.mjs.map +1 -0
- package/dist/sol/index.cjs +1 -0
- package/dist/sol/index.cjs.map +1 -1
- package/dist/sol/index.d.cts +1 -0
- package/dist/sol/index.d.cts.map +1 -1
- package/dist/sol/index.d.mts +1 -0
- package/dist/sol/index.d.mts.map +1 -1
- package/dist/sol/index.mjs +1 -0
- package/dist/sol/index.mjs.map +1 -1
- package/dist/sol/types.cjs +3 -3
- package/dist/sol/types.cjs.map +1 -1
- package/dist/sol/types.d.cts +3 -1
- package/dist/sol/types.d.cts.map +1 -1
- package/dist/sol/types.d.mts +3 -1
- package/dist/sol/types.d.mts.map +1 -1
- package/dist/sol/types.mjs +1 -1
- package/dist/sol/types.mjs.map +1 -1
- package/package.json +11 -14
- package/dist/JsonRpcRequest.cjs +0 -13
- package/dist/JsonRpcRequest.cjs.map +0 -1
- package/dist/JsonRpcRequest.d.cts +0 -17
- package/dist/JsonRpcRequest.d.cts.map +0 -1
- package/dist/JsonRpcRequest.d.mts +0 -17
- package/dist/JsonRpcRequest.d.mts.map +0 -1
- package/dist/JsonRpcRequest.mjs +0 -10
- package/dist/JsonRpcRequest.mjs.map +0 -1
- package/dist/KeyringClient.cjs +0 -130
- package/dist/KeyringClient.cjs.map +0 -1
- package/dist/KeyringClient.d.cts +0 -31
- package/dist/KeyringClient.d.cts.map +0 -1
- package/dist/KeyringClient.d.mts +0 -31
- package/dist/KeyringClient.d.mts.map +0 -1
- package/dist/KeyringClient.mjs +0 -126
- package/dist/KeyringClient.mjs.map +0 -1
- package/dist/KeyringSnapRpcClient.cjs +0 -68
- package/dist/KeyringSnapRpcClient.cjs.map +0 -1
- package/dist/KeyringSnapRpcClient.d.cts +0 -40
- package/dist/KeyringSnapRpcClient.d.cts.map +0 -1
- package/dist/KeyringSnapRpcClient.d.mts +0 -40
- package/dist/KeyringSnapRpcClient.d.mts.map +0 -1
- package/dist/KeyringSnapRpcClient.mjs +0 -63
- package/dist/KeyringSnapRpcClient.mjs.map +0 -1
- package/dist/internal/api.cjs.map +0 -1
- package/dist/internal/api.d.cts.map +0 -1
- package/dist/internal/api.d.mts.map +0 -1
- package/dist/internal/api.mjs.map +0 -1
- package/dist/internal/eth/EthKeyring.cjs +0 -3
- package/dist/internal/eth/EthKeyring.cjs.map +0 -1
- package/dist/internal/eth/EthKeyring.d.cts +0 -34
- package/dist/internal/eth/EthKeyring.d.cts.map +0 -1
- package/dist/internal/eth/EthKeyring.d.mts +0 -34
- package/dist/internal/eth/EthKeyring.d.mts.map +0 -1
- package/dist/internal/eth/EthKeyring.mjs +0 -2
- package/dist/internal/eth/EthKeyring.mjs.map +0 -1
- package/dist/internal/eth/index.cjs +0 -3
- package/dist/internal/eth/index.cjs.map +0 -1
- package/dist/internal/eth/index.d.cts +0 -2
- package/dist/internal/eth/index.d.cts.map +0 -1
- package/dist/internal/eth/index.d.mts +0 -2
- package/dist/internal/eth/index.d.mts.map +0 -1
- package/dist/internal/eth/index.mjs +0 -2
- package/dist/internal/eth/index.mjs.map +0 -1
- package/dist/internal/events.cjs +0 -72
- package/dist/internal/events.cjs.map +0 -1
- package/dist/internal/events.d.cts +0 -162
- package/dist/internal/events.d.cts.map +0 -1
- package/dist/internal/events.d.mts +0 -162
- package/dist/internal/events.d.mts.map +0 -1
- package/dist/internal/events.mjs +0 -69
- package/dist/internal/events.mjs.map +0 -1
- package/dist/internal/index.cjs +0 -21
- package/dist/internal/index.cjs.map +0 -1
- package/dist/internal/index.d.cts +0 -6
- package/dist/internal/index.d.cts.map +0 -1
- package/dist/internal/index.d.mts +0 -6
- package/dist/internal/index.d.mts.map +0 -1
- package/dist/internal/index.mjs +0 -5
- package/dist/internal/index.mjs.map +0 -1
- package/dist/internal/rpc.cjs +0 -34
- package/dist/internal/rpc.cjs.map +0 -1
- package/dist/internal/rpc.d.cts +0 -27
- package/dist/internal/rpc.d.cts.map +0 -1
- package/dist/internal/rpc.d.mts +0 -27
- package/dist/internal/rpc.d.mts.map +0 -1
- package/dist/internal/rpc.mjs +0 -30
- package/dist/internal/rpc.mjs.map +0 -1
- package/dist/internal/types.cjs +0 -52
- package/dist/internal/types.cjs.map +0 -1
- package/dist/internal/types.d.cts +0 -392
- package/dist/internal/types.d.cts.map +0 -1
- package/dist/internal/types.d.mts +0 -392
- package/dist/internal/types.d.mts.map +0 -1
- package/dist/internal/types.mjs +0 -49
- package/dist/internal/types.mjs.map +0 -1
- package/dist/rpc-handler.cjs +0 -143
- package/dist/rpc-handler.cjs.map +0 -1
- package/dist/rpc-handler.d.cts +0 -30
- package/dist/rpc-handler.d.cts.map +0 -1
- package/dist/rpc-handler.d.mts +0 -30
- package/dist/rpc-handler.d.mts.map +0 -1
- package/dist/rpc-handler.mjs +0 -138
- package/dist/rpc-handler.mjs.map +0 -1
- package/dist/snap-utils.cjs +0 -20
- package/dist/snap-utils.cjs.map +0 -1
- package/dist/snap-utils.d.cts +0 -12
- package/dist/snap-utils.d.cts.map +0 -1
- package/dist/snap-utils.d.mts +0 -12
- package/dist/snap-utils.d.mts.map +0 -1
- package/dist/snap-utils.mjs +0 -17
- package/dist/snap-utils.mjs.map +0 -1
- package/dist/superstruct.cjs +0 -109
- package/dist/superstruct.cjs.map +0 -1
- package/dist/superstruct.d.cts +0 -102
- package/dist/superstruct.d.cts.map +0 -1
- package/dist/superstruct.d.mts +0 -102
- package/dist/superstruct.d.mts.map +0 -1
- package/dist/superstruct.mjs +0 -102
- package/dist/superstruct.mjs.map +0 -1
- package/dist/utils/index.cjs +0 -20
- package/dist/utils/index.cjs.map +0 -1
- package/dist/utils/index.d.cts +0 -4
- package/dist/utils/index.d.cts.map +0 -1
- package/dist/utils/index.d.mts +0 -4
- package/dist/utils/index.d.mts.map +0 -1
- package/dist/utils/index.mjs +0 -4
- package/dist/utils/index.mjs.map +0 -1
- package/dist/utils/pagination.cjs.map +0 -1
- package/dist/utils/pagination.d.cts.map +0 -1
- package/dist/utils/pagination.d.mts.map +0 -1
- package/dist/utils/pagination.mjs.map +0 -1
- package/dist/utils/types.cjs +0 -29
- package/dist/utils/types.cjs.map +0 -1
- package/dist/utils/types.d.cts +0 -42
- package/dist/utils/types.d.cts.map +0 -1
- package/dist/utils/types.d.mts +0 -42
- package/dist/utils/types.d.mts.map +0 -1
- package/dist/utils/types.mjs +0 -26
- package/dist/utils/types.mjs.map +0 -1
- package/dist/utils/typing.cjs +0 -20
- package/dist/utils/typing.cjs.map +0 -1
- package/dist/utils/typing.d.cts +0 -33
- package/dist/utils/typing.d.cts.map +0 -1
- package/dist/utils/typing.d.mts +0 -33
- package/dist/utils/typing.d.mts.map +0 -1
- package/dist/utils/typing.mjs +0 -17
- package/dist/utils/typing.mjs.map +0 -1
@@ -1,8 +1,34 @@
|
|
1
1
|
import type { Infer } from "@metamask/superstruct";
|
2
|
+
/**
|
3
|
+
* Keyring RPC methods used by the API.
|
4
|
+
*/
|
5
|
+
export declare enum KeyringRpcMethod {
|
6
|
+
ListAccounts = "keyring_listAccounts",
|
7
|
+
GetAccount = "keyring_getAccount",
|
8
|
+
CreateAccount = "keyring_createAccount",
|
9
|
+
ListAccountTransactions = "keyring_listAccountTransactions",
|
10
|
+
GetAccountBalances = "keyring_getAccountBalances",
|
11
|
+
FilterAccountChains = "keyring_filterAccountChains",
|
12
|
+
UpdateAccount = "keyring_updateAccount",
|
13
|
+
DeleteAccount = "keyring_deleteAccount",
|
14
|
+
ExportAccount = "keyring_exportAccount",
|
15
|
+
ListRequests = "keyring_listRequests",
|
16
|
+
GetRequest = "keyring_getRequest",
|
17
|
+
SubmitRequest = "keyring_submitRequest",
|
18
|
+
ApproveRequest = "keyring_approveRequest",
|
19
|
+
RejectRequest = "keyring_rejectRequest"
|
20
|
+
}
|
21
|
+
/**
|
22
|
+
* Check if a method is a keyring RPC method.
|
23
|
+
*
|
24
|
+
* @param method - Method to check.
|
25
|
+
* @returns Whether the method is a keyring RPC method.
|
26
|
+
*/
|
27
|
+
export declare function isKeyringRpcMethod(method: string): boolean;
|
2
28
|
export declare const ListAccountsRequestStruct: import("@metamask/superstruct").Struct<{
|
3
|
-
jsonrpc: "2.0";
|
4
|
-
id: string | number | null;
|
5
29
|
method: "keyring_listAccounts";
|
30
|
+
id: string | number | null;
|
31
|
+
jsonrpc: "2.0";
|
6
32
|
}, {
|
7
33
|
method: import("@metamask/superstruct").Struct<"keyring_listAccounts", "keyring_listAccounts">;
|
8
34
|
jsonrpc: import("@metamask/superstruct").Struct<"2.0", "2.0">;
|
@@ -12,14 +38,16 @@ export type ListAccountsRequest = Infer<typeof ListAccountsRequestStruct>;
|
|
12
38
|
export declare const ListAccountsResponseStruct: import("@metamask/superstruct").Struct<{
|
13
39
|
type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2wpkh" | "solana:data-account";
|
14
40
|
id: string;
|
15
|
-
address: string;
|
16
41
|
options: Record<string, import("@metamask/utils").Json>;
|
42
|
+
address: string;
|
43
|
+
scopes: string[];
|
17
44
|
methods: string[];
|
18
45
|
}[], import("@metamask/superstruct").Struct<{
|
19
46
|
type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2wpkh" | "solana:data-account";
|
20
47
|
id: string;
|
21
|
-
address: string;
|
22
48
|
options: Record<string, import("@metamask/utils").Json>;
|
49
|
+
address: string;
|
50
|
+
scopes: string[];
|
23
51
|
methods: string[];
|
24
52
|
}, {
|
25
53
|
id: import("@metamask/superstruct").Struct<string, null>;
|
@@ -30,14 +58,15 @@ export declare const ListAccountsResponseStruct: import("@metamask/superstruct")
|
|
30
58
|
"solana:data-account": "solana:data-account";
|
31
59
|
}>;
|
32
60
|
address: import("@metamask/superstruct").Struct<string, null>;
|
61
|
+
scopes: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
33
62
|
options: import("@metamask/superstruct").Struct<Record<string, import("@metamask/utils").Json>, null>;
|
34
63
|
methods: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
35
64
|
}>>;
|
36
65
|
export type ListAccountsResponse = Infer<typeof ListAccountsResponseStruct>;
|
37
66
|
export declare const GetAccountRequestStruct: import("@metamask/superstruct").Struct<{
|
38
|
-
jsonrpc: "2.0";
|
39
|
-
id: string | number | null;
|
40
67
|
method: "keyring_getAccount";
|
68
|
+
id: string | number | null;
|
69
|
+
jsonrpc: "2.0";
|
41
70
|
params: {
|
42
71
|
id: string;
|
43
72
|
};
|
@@ -55,8 +84,9 @@ export type GetAccountRequest = Infer<typeof GetAccountRequestStruct>;
|
|
55
84
|
export declare const GetAccountResponseStruct: import("@metamask/superstruct").Struct<{
|
56
85
|
type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2wpkh" | "solana:data-account";
|
57
86
|
id: string;
|
58
|
-
address: string;
|
59
87
|
options: Record<string, import("@metamask/utils").Json>;
|
88
|
+
address: string;
|
89
|
+
scopes: string[];
|
60
90
|
methods: string[];
|
61
91
|
}, {
|
62
92
|
id: import("@metamask/superstruct").Struct<string, null>;
|
@@ -67,14 +97,15 @@ export declare const GetAccountResponseStruct: import("@metamask/superstruct").S
|
|
67
97
|
"solana:data-account": "solana:data-account";
|
68
98
|
}>;
|
69
99
|
address: import("@metamask/superstruct").Struct<string, null>;
|
100
|
+
scopes: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
70
101
|
options: import("@metamask/superstruct").Struct<Record<string, import("@metamask/utils").Json>, null>;
|
71
102
|
methods: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
72
103
|
}>;
|
73
104
|
export type GetAccountResponse = Infer<typeof GetAccountResponseStruct>;
|
74
105
|
export declare const CreateAccountRequestStruct: import("@metamask/superstruct").Struct<{
|
75
|
-
jsonrpc: "2.0";
|
76
|
-
id: string | number | null;
|
77
106
|
method: "keyring_createAccount";
|
107
|
+
id: string | number | null;
|
108
|
+
jsonrpc: "2.0";
|
78
109
|
params: {
|
79
110
|
options: Record<string, import("@metamask/utils").Json>;
|
80
111
|
};
|
@@ -92,8 +123,9 @@ export type CreateAccountRequest = Infer<typeof CreateAccountRequestStruct>;
|
|
92
123
|
export declare const CreateAccountResponseStruct: import("@metamask/superstruct").Struct<{
|
93
124
|
type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2wpkh" | "solana:data-account";
|
94
125
|
id: string;
|
95
|
-
address: string;
|
96
126
|
options: Record<string, import("@metamask/utils").Json>;
|
127
|
+
address: string;
|
128
|
+
scopes: string[];
|
97
129
|
methods: string[];
|
98
130
|
}, {
|
99
131
|
id: import("@metamask/superstruct").Struct<string, null>;
|
@@ -104,14 +136,15 @@ export declare const CreateAccountResponseStruct: import("@metamask/superstruct"
|
|
104
136
|
"solana:data-account": "solana:data-account";
|
105
137
|
}>;
|
106
138
|
address: import("@metamask/superstruct").Struct<string, null>;
|
139
|
+
scopes: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
107
140
|
options: import("@metamask/superstruct").Struct<Record<string, import("@metamask/utils").Json>, null>;
|
108
141
|
methods: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
109
142
|
}>;
|
110
143
|
export type CreateAccountResponse = Infer<typeof CreateAccountResponseStruct>;
|
111
144
|
export declare const ListAccountTransactionsRequestStruct: import("@metamask/superstruct").Struct<{
|
112
|
-
jsonrpc: "2.0";
|
113
|
-
id: string | number | null;
|
114
145
|
method: "keyring_listAccountTransactions";
|
146
|
+
id: string | number | null;
|
147
|
+
jsonrpc: "2.0";
|
115
148
|
params: {
|
116
149
|
id: string;
|
117
150
|
pagination: {
|
@@ -134,7 +167,7 @@ export declare const ListAccountTransactionsRequestStruct: import("@metamask/sup
|
|
134
167
|
next?: string | null;
|
135
168
|
}, {
|
136
169
|
limit: import("@metamask/superstruct").Struct<number, null>;
|
137
|
-
next: import("@metamask/superstruct").Struct<string | import("
|
170
|
+
next: import("@metamask/superstruct").Struct<string | import("@metamask/keyring-utils").ExactOptionalTag | null, null>;
|
138
171
|
}>;
|
139
172
|
}>;
|
140
173
|
jsonrpc: import("@metamask/superstruct").Struct<"2.0", "2.0">;
|
@@ -142,32 +175,35 @@ export declare const ListAccountTransactionsRequestStruct: import("@metamask/sup
|
|
142
175
|
}>;
|
143
176
|
export type ListAccountTransactionsRequest = Infer<typeof ListAccountTransactionsRequestStruct>;
|
144
177
|
export declare const ListAccountTransactionsResponseStruct: import("@metamask/superstruct").Struct<{
|
145
|
-
next: string | null;
|
146
178
|
data: {
|
147
179
|
type: "send" | "receive";
|
148
180
|
id: string;
|
149
|
-
account: string;
|
150
|
-
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
151
|
-
timestamp: number | null;
|
152
|
-
chain: `${string}:${string}`;
|
153
181
|
from: {
|
154
182
|
address: string;
|
155
183
|
asset: {
|
184
|
+
unit: string;
|
156
185
|
type: `${string}:${string}/${string}:${string}`;
|
157
186
|
fungible: true;
|
158
|
-
unit: string;
|
159
187
|
amount: string;
|
160
188
|
} | {
|
161
189
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
162
190
|
fungible: false;
|
163
191
|
} | null;
|
164
192
|
}[];
|
193
|
+
events: {
|
194
|
+
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
195
|
+
timestamp: number | null;
|
196
|
+
}[];
|
197
|
+
chain: `${string}:${string}`;
|
198
|
+
account: string;
|
199
|
+
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
200
|
+
timestamp: number | null;
|
165
201
|
to: {
|
166
202
|
address: string;
|
167
203
|
asset: {
|
204
|
+
unit: string;
|
168
205
|
type: `${string}:${string}/${string}:${string}`;
|
169
206
|
fungible: true;
|
170
|
-
unit: string;
|
171
207
|
amount: string;
|
172
208
|
} | {
|
173
209
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -177,46 +213,47 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
177
213
|
fees: {
|
178
214
|
type: "base" | "priority";
|
179
215
|
asset: {
|
216
|
+
unit: string;
|
180
217
|
type: `${string}:${string}/${string}:${string}`;
|
181
218
|
fungible: true;
|
182
|
-
unit: string;
|
183
219
|
amount: string;
|
184
220
|
} | {
|
185
221
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
186
222
|
fungible: false;
|
187
223
|
};
|
188
224
|
}[];
|
189
|
-
events: {
|
190
|
-
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
191
|
-
timestamp: number | null;
|
192
|
-
}[];
|
193
225
|
}[];
|
226
|
+
next: string | null;
|
194
227
|
}, {
|
195
228
|
data: import("@metamask/superstruct").Struct<{
|
196
229
|
type: "send" | "receive";
|
197
230
|
id: string;
|
198
|
-
account: string;
|
199
|
-
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
200
|
-
timestamp: number | null;
|
201
|
-
chain: `${string}:${string}`;
|
202
231
|
from: {
|
203
232
|
address: string;
|
204
233
|
asset: {
|
234
|
+
unit: string;
|
205
235
|
type: `${string}:${string}/${string}:${string}`;
|
206
236
|
fungible: true;
|
207
|
-
unit: string;
|
208
237
|
amount: string;
|
209
238
|
} | {
|
210
239
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
211
240
|
fungible: false;
|
212
241
|
} | null;
|
213
242
|
}[];
|
243
|
+
events: {
|
244
|
+
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
245
|
+
timestamp: number | null;
|
246
|
+
}[];
|
247
|
+
chain: `${string}:${string}`;
|
248
|
+
account: string;
|
249
|
+
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
250
|
+
timestamp: number | null;
|
214
251
|
to: {
|
215
252
|
address: string;
|
216
253
|
asset: {
|
254
|
+
unit: string;
|
217
255
|
type: `${string}:${string}/${string}:${string}`;
|
218
256
|
fungible: true;
|
219
|
-
unit: string;
|
220
257
|
amount: string;
|
221
258
|
} | {
|
222
259
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -226,44 +263,44 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
226
263
|
fees: {
|
227
264
|
type: "base" | "priority";
|
228
265
|
asset: {
|
266
|
+
unit: string;
|
229
267
|
type: `${string}:${string}/${string}:${string}`;
|
230
268
|
fungible: true;
|
231
|
-
unit: string;
|
232
269
|
amount: string;
|
233
270
|
} | {
|
234
271
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
235
272
|
fungible: false;
|
236
273
|
};
|
237
274
|
}[];
|
238
|
-
events: {
|
239
|
-
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
240
|
-
timestamp: number | null;
|
241
|
-
}[];
|
242
275
|
}[], import("@metamask/superstruct").Struct<{
|
243
276
|
type: "send" | "receive";
|
244
277
|
id: string;
|
245
|
-
account: string;
|
246
|
-
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
247
|
-
timestamp: number | null;
|
248
|
-
chain: `${string}:${string}`;
|
249
278
|
from: {
|
250
279
|
address: string;
|
251
280
|
asset: {
|
281
|
+
unit: string;
|
252
282
|
type: `${string}:${string}/${string}:${string}`;
|
253
283
|
fungible: true;
|
254
|
-
unit: string;
|
255
284
|
amount: string;
|
256
285
|
} | {
|
257
286
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
258
287
|
fungible: false;
|
259
288
|
} | null;
|
260
289
|
}[];
|
290
|
+
events: {
|
291
|
+
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
292
|
+
timestamp: number | null;
|
293
|
+
}[];
|
294
|
+
chain: `${string}:${string}`;
|
295
|
+
account: string;
|
296
|
+
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
297
|
+
timestamp: number | null;
|
261
298
|
to: {
|
262
299
|
address: string;
|
263
300
|
asset: {
|
301
|
+
unit: string;
|
264
302
|
type: `${string}:${string}/${string}:${string}`;
|
265
303
|
fungible: true;
|
266
|
-
unit: string;
|
267
304
|
amount: string;
|
268
305
|
} | {
|
269
306
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -273,19 +310,15 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
273
310
|
fees: {
|
274
311
|
type: "base" | "priority";
|
275
312
|
asset: {
|
313
|
+
unit: string;
|
276
314
|
type: `${string}:${string}/${string}:${string}`;
|
277
315
|
fungible: true;
|
278
|
-
unit: string;
|
279
316
|
amount: string;
|
280
317
|
} | {
|
281
318
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
282
319
|
fungible: false;
|
283
320
|
};
|
284
321
|
}[];
|
285
|
-
events: {
|
286
|
-
status: "submitted" | "unconfirmed" | "confirmed" | "failed";
|
287
|
-
timestamp: number | null;
|
288
|
-
}[];
|
289
322
|
}, {
|
290
323
|
id: import("@metamask/superstruct").Struct<string, null>;
|
291
324
|
chain: import("@metamask/superstruct").Struct<`${string}:${string}`, null>;
|
@@ -304,9 +337,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
304
337
|
from: import("@metamask/superstruct").Struct<{
|
305
338
|
address: string;
|
306
339
|
asset: {
|
340
|
+
unit: string;
|
307
341
|
type: `${string}:${string}/${string}:${string}`;
|
308
342
|
fungible: true;
|
309
|
-
unit: string;
|
310
343
|
amount: string;
|
311
344
|
} | {
|
312
345
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -315,9 +348,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
315
348
|
}[], import("@metamask/superstruct").Struct<{
|
316
349
|
address: string;
|
317
350
|
asset: {
|
351
|
+
unit: string;
|
318
352
|
type: `${string}:${string}/${string}:${string}`;
|
319
353
|
fungible: true;
|
320
|
-
unit: string;
|
321
354
|
amount: string;
|
322
355
|
} | {
|
323
356
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -326,9 +359,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
326
359
|
}, {
|
327
360
|
address: import("@metamask/superstruct").Struct<string, null>;
|
328
361
|
asset: import("@metamask/superstruct").Struct<{
|
362
|
+
unit: string;
|
329
363
|
type: `${string}:${string}/${string}:${string}`;
|
330
364
|
fungible: true;
|
331
|
-
unit: string;
|
332
365
|
amount: string;
|
333
366
|
} | {
|
334
367
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -338,9 +371,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
338
371
|
to: import("@metamask/superstruct").Struct<{
|
339
372
|
address: string;
|
340
373
|
asset: {
|
374
|
+
unit: string;
|
341
375
|
type: `${string}:${string}/${string}:${string}`;
|
342
376
|
fungible: true;
|
343
|
-
unit: string;
|
344
377
|
amount: string;
|
345
378
|
} | {
|
346
379
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -349,9 +382,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
349
382
|
}[], import("@metamask/superstruct").Struct<{
|
350
383
|
address: string;
|
351
384
|
asset: {
|
385
|
+
unit: string;
|
352
386
|
type: `${string}:${string}/${string}:${string}`;
|
353
387
|
fungible: true;
|
354
|
-
unit: string;
|
355
388
|
amount: string;
|
356
389
|
} | {
|
357
390
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -360,9 +393,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
360
393
|
}, {
|
361
394
|
address: import("@metamask/superstruct").Struct<string, null>;
|
362
395
|
asset: import("@metamask/superstruct").Struct<{
|
396
|
+
unit: string;
|
363
397
|
type: `${string}:${string}/${string}:${string}`;
|
364
398
|
fungible: true;
|
365
|
-
unit: string;
|
366
399
|
amount: string;
|
367
400
|
} | {
|
368
401
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -372,9 +405,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
372
405
|
fees: import("@metamask/superstruct").Struct<{
|
373
406
|
type: "base" | "priority";
|
374
407
|
asset: {
|
408
|
+
unit: string;
|
375
409
|
type: `${string}:${string}/${string}:${string}`;
|
376
410
|
fungible: true;
|
377
|
-
unit: string;
|
378
411
|
amount: string;
|
379
412
|
} | {
|
380
413
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -383,9 +416,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
383
416
|
}[], import("@metamask/superstruct").Struct<{
|
384
417
|
type: "base" | "priority";
|
385
418
|
asset: {
|
419
|
+
unit: string;
|
386
420
|
type: `${string}:${string}/${string}:${string}`;
|
387
421
|
fungible: true;
|
388
|
-
unit: string;
|
389
422
|
amount: string;
|
390
423
|
} | {
|
391
424
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -397,9 +430,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
397
430
|
priority: "priority";
|
398
431
|
}>;
|
399
432
|
asset: import("@metamask/superstruct").Struct<{
|
433
|
+
unit: string;
|
400
434
|
type: `${string}:${string}/${string}:${string}`;
|
401
435
|
fungible: true;
|
402
|
-
unit: string;
|
403
436
|
amount: string;
|
404
437
|
} | {
|
405
438
|
id: `${string}:${string}/${string}:${string}/${string}`;
|
@@ -426,9 +459,9 @@ export declare const ListAccountTransactionsResponseStruct: import("@metamask/su
|
|
426
459
|
}>;
|
427
460
|
export type ListAccountTransactionsResponse = Infer<typeof ListAccountTransactionsResponseStruct>;
|
428
461
|
export declare const GetAccountBalancesRequestStruct: import("@metamask/superstruct").Struct<{
|
429
|
-
jsonrpc: "2.0";
|
430
|
-
id: string | number | null;
|
431
462
|
method: "keyring_getAccountBalances";
|
463
|
+
id: string | number | null;
|
464
|
+
jsonrpc: "2.0";
|
432
465
|
params: {
|
433
466
|
id: string;
|
434
467
|
assets: string[];
|
@@ -452,9 +485,9 @@ export declare const GetAccountBalancesResponseStruct: import("@metamask/superst
|
|
452
485
|
}>, null>;
|
453
486
|
export type GetAccountBalancesResponse = Infer<typeof GetAccountBalancesResponseStruct>;
|
454
487
|
export declare const FilterAccountChainsStruct: import("@metamask/superstruct").Struct<{
|
455
|
-
jsonrpc: "2.0";
|
456
|
-
id: string | number | null;
|
457
488
|
method: "keyring_filterAccountChains";
|
489
|
+
id: string | number | null;
|
490
|
+
jsonrpc: "2.0";
|
458
491
|
params: {
|
459
492
|
id: string;
|
460
493
|
chains: string[];
|
@@ -475,15 +508,16 @@ export type FilterAccountChainsRequest = Infer<typeof FilterAccountChainsStruct>
|
|
475
508
|
export declare const FilterAccountChainsResponseStruct: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
476
509
|
export type FilterAccountChainsResponse = Infer<typeof FilterAccountChainsResponseStruct>;
|
477
510
|
export declare const UpdateAccountRequestStruct: import("@metamask/superstruct").Struct<{
|
478
|
-
jsonrpc: "2.0";
|
479
|
-
id: string | number | null;
|
480
511
|
method: "keyring_updateAccount";
|
512
|
+
id: string | number | null;
|
513
|
+
jsonrpc: "2.0";
|
481
514
|
params: {
|
482
515
|
account: {
|
483
516
|
type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2wpkh" | "solana:data-account";
|
484
517
|
id: string;
|
485
|
-
address: string;
|
486
518
|
options: Record<string, import("@metamask/utils").Json>;
|
519
|
+
address: string;
|
520
|
+
scopes: string[];
|
487
521
|
methods: string[];
|
488
522
|
};
|
489
523
|
};
|
@@ -493,16 +527,18 @@ export declare const UpdateAccountRequestStruct: import("@metamask/superstruct")
|
|
493
527
|
account: {
|
494
528
|
type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2wpkh" | "solana:data-account";
|
495
529
|
id: string;
|
496
|
-
address: string;
|
497
530
|
options: Record<string, import("@metamask/utils").Json>;
|
531
|
+
address: string;
|
532
|
+
scopes: string[];
|
498
533
|
methods: string[];
|
499
534
|
};
|
500
535
|
}, {
|
501
536
|
account: import("@metamask/superstruct").Struct<{
|
502
537
|
type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2wpkh" | "solana:data-account";
|
503
538
|
id: string;
|
504
|
-
address: string;
|
505
539
|
options: Record<string, import("@metamask/utils").Json>;
|
540
|
+
address: string;
|
541
|
+
scopes: string[];
|
506
542
|
methods: string[];
|
507
543
|
}, {
|
508
544
|
id: import("@metamask/superstruct").Struct<string, null>;
|
@@ -513,6 +549,7 @@ export declare const UpdateAccountRequestStruct: import("@metamask/superstruct")
|
|
513
549
|
"solana:data-account": "solana:data-account";
|
514
550
|
}>;
|
515
551
|
address: import("@metamask/superstruct").Struct<string, null>;
|
552
|
+
scopes: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
516
553
|
options: import("@metamask/superstruct").Struct<Record<string, import("@metamask/utils").Json>, null>;
|
517
554
|
methods: import("@metamask/superstruct").Struct<string[], import("@metamask/superstruct").Struct<string, null>>;
|
518
555
|
}>;
|
@@ -524,9 +561,9 @@ export type UpdateAccountRequest = Infer<typeof UpdateAccountRequestStruct>;
|
|
524
561
|
export declare const UpdateAccountResponseStruct: import("@metamask/superstruct").Struct<null, null>;
|
525
562
|
export type UpdateAccountResponse = Infer<typeof UpdateAccountResponseStruct>;
|
526
563
|
export declare const DeleteAccountRequestStruct: import("@metamask/superstruct").Struct<{
|
527
|
-
jsonrpc: "2.0";
|
528
|
-
id: string | number | null;
|
529
564
|
method: "keyring_deleteAccount";
|
565
|
+
id: string | number | null;
|
566
|
+
jsonrpc: "2.0";
|
530
567
|
params: {
|
531
568
|
id: string;
|
532
569
|
};
|
@@ -544,9 +581,9 @@ export type DeleteAccountRequest = Infer<typeof DeleteAccountRequestStruct>;
|
|
544
581
|
export declare const DeleteAccountResponseStruct: import("@metamask/superstruct").Struct<null, null>;
|
545
582
|
export type DeleteAccountResponse = Infer<typeof DeleteAccountResponseStruct>;
|
546
583
|
export declare const ExportAccountRequestStruct: import("@metamask/superstruct").Struct<{
|
547
|
-
jsonrpc: "2.0";
|
548
|
-
id: string | number | null;
|
549
584
|
method: "keyring_exportAccount";
|
585
|
+
id: string | number | null;
|
586
|
+
jsonrpc: "2.0";
|
550
587
|
params: {
|
551
588
|
id: string;
|
552
589
|
};
|
@@ -564,9 +601,9 @@ export type ExportAccountRequest = Infer<typeof ExportAccountRequestStruct>;
|
|
564
601
|
export declare const ExportAccountResponseStruct: import("@metamask/superstruct").Struct<Record<string, import("@metamask/utils").Json>, null>;
|
565
602
|
export type ExportAccountResponse = Infer<typeof ExportAccountResponseStruct>;
|
566
603
|
export declare const ListRequestsRequestStruct: import("@metamask/superstruct").Struct<{
|
567
|
-
jsonrpc: "2.0";
|
568
|
-
id: string | number | null;
|
569
604
|
method: "keyring_listRequests";
|
605
|
+
id: string | number | null;
|
606
|
+
jsonrpc: "2.0";
|
570
607
|
}, {
|
571
608
|
method: import("@metamask/superstruct").Struct<"keyring_listRequests", "keyring_listRequests">;
|
572
609
|
jsonrpc: import("@metamask/superstruct").Struct<"2.0", "2.0">;
|
@@ -575,37 +612,37 @@ export declare const ListRequestsRequestStruct: import("@metamask/superstruct").
|
|
575
612
|
export type ListRequestsRequest = Infer<typeof ListRequestsRequestStruct>;
|
576
613
|
export declare const ListRequestsResponseStruct: import("@metamask/superstruct").Struct<{
|
577
614
|
id: string;
|
578
|
-
scope: string;
|
579
|
-
account: string;
|
580
615
|
request: {
|
581
616
|
method: string;
|
582
|
-
params?: import("@metamask/utils").Json
|
617
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
583
618
|
};
|
584
|
-
}[], import("@metamask/superstruct").Struct<{
|
585
|
-
id: string;
|
586
619
|
scope: string;
|
587
620
|
account: string;
|
621
|
+
}[], import("@metamask/superstruct").Struct<{
|
622
|
+
id: string;
|
588
623
|
request: {
|
589
624
|
method: string;
|
590
|
-
params?: import("@metamask/utils").Json
|
625
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
591
626
|
};
|
627
|
+
scope: string;
|
628
|
+
account: string;
|
592
629
|
}, {
|
593
630
|
id: import("@metamask/superstruct").Struct<string, null>;
|
594
631
|
scope: import("@metamask/superstruct").Struct<string, null>;
|
595
632
|
account: import("@metamask/superstruct").Struct<string, null>;
|
596
633
|
request: import("@metamask/superstruct").Struct<{
|
597
634
|
method: string;
|
598
|
-
params?: import("@metamask/utils").Json
|
635
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
599
636
|
}, {
|
600
637
|
method: import("@metamask/superstruct").Struct<string, null>;
|
601
|
-
params: import("@metamask/superstruct").Struct<import("
|
638
|
+
params: import("@metamask/superstruct").Struct<import("@metamask/keyring-utils").ExactOptionalTag | Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[], null>;
|
602
639
|
}>;
|
603
640
|
}>>;
|
604
641
|
export type ListRequestsResponse = Infer<typeof ListRequestsResponseStruct>;
|
605
642
|
export declare const GetRequestRequestStruct: import("@metamask/superstruct").Struct<{
|
606
|
-
jsonrpc: "2.0";
|
607
|
-
id: string | number | null;
|
608
643
|
method: "keyring_getRequest";
|
644
|
+
id: string | number | null;
|
645
|
+
jsonrpc: "2.0";
|
609
646
|
params: {
|
610
647
|
id: string;
|
611
648
|
};
|
@@ -622,58 +659,58 @@ export declare const GetRequestRequestStruct: import("@metamask/superstruct").St
|
|
622
659
|
export type GetRequestRequest = Infer<typeof GetRequestRequestStruct>;
|
623
660
|
export declare const GetRequestResponseStruct: import("@metamask/superstruct").Struct<{
|
624
661
|
id: string;
|
625
|
-
scope: string;
|
626
|
-
account: string;
|
627
662
|
request: {
|
628
663
|
method: string;
|
629
|
-
params?: import("@metamask/utils").Json
|
664
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
630
665
|
};
|
666
|
+
scope: string;
|
667
|
+
account: string;
|
631
668
|
}, {
|
632
669
|
id: import("@metamask/superstruct").Struct<string, null>;
|
633
670
|
scope: import("@metamask/superstruct").Struct<string, null>;
|
634
671
|
account: import("@metamask/superstruct").Struct<string, null>;
|
635
672
|
request: import("@metamask/superstruct").Struct<{
|
636
673
|
method: string;
|
637
|
-
params?: import("@metamask/utils").Json
|
674
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
638
675
|
}, {
|
639
676
|
method: import("@metamask/superstruct").Struct<string, null>;
|
640
|
-
params: import("@metamask/superstruct").Struct<import("
|
677
|
+
params: import("@metamask/superstruct").Struct<import("@metamask/keyring-utils").ExactOptionalTag | Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[], null>;
|
641
678
|
}>;
|
642
679
|
}>;
|
643
680
|
export type GetRequestResponse = Infer<typeof GetRequestResponseStruct>;
|
644
681
|
export declare const SubmitRequestRequestStruct: import("@metamask/superstruct").Struct<{
|
645
|
-
jsonrpc: "2.0";
|
646
|
-
id: string | number | null;
|
647
682
|
method: "keyring_submitRequest";
|
683
|
+
id: string | number | null;
|
684
|
+
jsonrpc: "2.0";
|
648
685
|
params: {
|
649
686
|
id: string;
|
650
|
-
scope: string;
|
651
|
-
account: string;
|
652
687
|
request: {
|
653
688
|
method: string;
|
654
|
-
params?: import("@metamask/utils").Json
|
689
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
655
690
|
};
|
691
|
+
scope: string;
|
692
|
+
account: string;
|
656
693
|
};
|
657
694
|
}, {
|
658
695
|
method: import("@metamask/superstruct").Struct<"keyring_submitRequest", "keyring_submitRequest">;
|
659
696
|
params: import("@metamask/superstruct").Struct<{
|
660
697
|
id: string;
|
661
|
-
scope: string;
|
662
|
-
account: string;
|
663
698
|
request: {
|
664
699
|
method: string;
|
665
|
-
params?: import("@metamask/utils").Json
|
700
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
666
701
|
};
|
702
|
+
scope: string;
|
703
|
+
account: string;
|
667
704
|
}, {
|
668
705
|
id: import("@metamask/superstruct").Struct<string, null>;
|
669
706
|
scope: import("@metamask/superstruct").Struct<string, null>;
|
670
707
|
account: import("@metamask/superstruct").Struct<string, null>;
|
671
708
|
request: import("@metamask/superstruct").Struct<{
|
672
709
|
method: string;
|
673
|
-
params?: import("@metamask/utils").Json
|
710
|
+
params?: Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[];
|
674
711
|
}, {
|
675
712
|
method: import("@metamask/superstruct").Struct<string, null>;
|
676
|
-
params: import("@metamask/superstruct").Struct<import("
|
713
|
+
params: import("@metamask/superstruct").Struct<import("@metamask/keyring-utils").ExactOptionalTag | Record<string, import("@metamask/utils").Json> | import("@metamask/utils").Json[], null>;
|
677
714
|
}>;
|
678
715
|
}>;
|
679
716
|
jsonrpc: import("@metamask/superstruct").Struct<"2.0", "2.0">;
|
@@ -687,23 +724,23 @@ export declare const SubmitRequestResponseStruct: import("@metamask/superstruct"
|
|
687
724
|
url?: string;
|
688
725
|
};
|
689
726
|
} | {
|
690
|
-
pending: false;
|
691
727
|
result: import("@metamask/utils").Json;
|
728
|
+
pending: false;
|
692
729
|
}, null>;
|
693
730
|
export type SubmitRequestResponse = Infer<typeof SubmitRequestResponseStruct>;
|
694
731
|
export declare const ApproveRequestRequestStruct: import("@metamask/superstruct").Struct<{
|
695
|
-
jsonrpc: "2.0";
|
696
|
-
id: string | number | null;
|
697
732
|
method: "keyring_approveRequest";
|
733
|
+
id: string | number | null;
|
734
|
+
jsonrpc: "2.0";
|
698
735
|
params: {
|
699
|
-
id: string;
|
700
736
|
data: Record<string, import("@metamask/utils").Json>;
|
737
|
+
id: string;
|
701
738
|
};
|
702
739
|
}, {
|
703
740
|
method: import("@metamask/superstruct").Struct<"keyring_approveRequest", "keyring_approveRequest">;
|
704
741
|
params: import("@metamask/superstruct").Struct<{
|
705
|
-
id: string;
|
706
742
|
data: Record<string, import("@metamask/utils").Json>;
|
743
|
+
id: string;
|
707
744
|
}, {
|
708
745
|
id: import("@metamask/superstruct").Struct<string, null>;
|
709
746
|
data: import("@metamask/superstruct").Struct<Record<string, import("@metamask/utils").Json>, null>;
|
@@ -715,9 +752,9 @@ export type ApproveRequestRequest = Infer<typeof ApproveRequestRequestStruct>;
|
|
715
752
|
export declare const ApproveRequestResponseStruct: import("@metamask/superstruct").Struct<null, null>;
|
716
753
|
export type ApproveRequestResponse = Infer<typeof ApproveRequestResponseStruct>;
|
717
754
|
export declare const RejectRequestRequestStruct: import("@metamask/superstruct").Struct<{
|
718
|
-
jsonrpc: "2.0";
|
719
|
-
id: string | number | null;
|
720
755
|
method: "keyring_rejectRequest";
|
756
|
+
id: string | number | null;
|
757
|
+
jsonrpc: "2.0";
|
721
758
|
params: {
|
722
759
|
id: string;
|
723
760
|
};
|
@@ -734,4 +771,4 @@ export declare const RejectRequestRequestStruct: import("@metamask/superstruct")
|
|
734
771
|
export type RejectRequestRequest = Infer<typeof RejectRequestRequestStruct>;
|
735
772
|
export declare const RejectRequestResponseStruct: import("@metamask/superstruct").Struct<null, null>;
|
736
773
|
export type RejectRequestResponse = Infer<typeof RejectRequestResponseStruct>;
|
737
|
-
//# sourceMappingURL=
|
774
|
+
//# sourceMappingURL=rpc.d.mts.map
|