Skip to content

Commit dc429ac

Browse files
authored
Merge pull request #357 from KomodoPlatform/kdf/add/get_wallet_names
2 parents 1da1d1c + ca203e5 commit dc429ac

File tree

4 files changed

+76
-0
lines changed

4 files changed

+76
-0
lines changed

filepathSlugs.json

+9
Original file line numberDiff line numberDiff line change
@@ -2860,6 +2860,15 @@
28602860
"response-not-currently-staking",
28612861
"response-staking-active"
28622862
],
2863+
"src/pages/komodo-defi-framework/api/v20/get_wallet_names/index.mdx": [
2864+
"get-wallet-names",
2865+
"arguments",
2866+
"response",
2867+
"examples",
2868+
"command",
2869+
"response-in-no-login-mode",
2870+
"response-while-logged-in"
2871+
],
28632872
"src/pages/komodo-defi-framework/api/v20/index.mdx": [
28642873
"komodo-de-fi-sdk-rpc-protocol-v2-0",
28652874
"request",

src/data/sidebar.json

+4
Original file line numberDiff line numberDiff line change
@@ -483,6 +483,10 @@
483483
"title": "get_public_key_hash",
484484
"href": "/komodo-defi-framework/api/v20/get_public_key_hash/"
485485
},
486+
{
487+
"title": "get_wallet_names",
488+
"href": "/komodo-defi-framework/api/v20/get_wallet_names/"
489+
},
486490
{
487491
"title": "get_raw_transaction",
488492
"href": "/komodo-defi-framework/api/v20/get_raw_transaction/"

src/pages/komodo-defi-framework/api/index.mdx

+1
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ Below is a table of the currently available legacy, v2.0 and v2.0 (Dev) methods:
5555
| [get\_relay\_mesh](/komodo-defi-framework/api/legacy/get_relay_mesh/#get-relay-mesh) | | |
5656
| | [get\_staking\_infos](/komodo-defi-framework/api/v20/get_staking_infos/#get-staking-infos) | |
5757
| [get\_trade\_fee](/komodo-defi-framework/api/legacy/get_trade_fee/#get-trade-fee) | | |
58+
| | [get\_wallet\_names](/komodo-defi-framework/api/v20/get_wallet_names/#get-wallet-names) | |
5859
| [import\_swaps](/komodo-defi-framework/api/legacy/import_swaps/#import-swaps) | | |
5960
| [kmd\_rewards\_info](/komodo-defi-framework/api/legacy/kmd_rewards_info/#kmd-rewards-info) | | |
6061
| | | [lightning::nodes::add\_trusted\_node](/komodo-defi-framework/api/v20-dev/lightning/nodes/#add-trusted-node) |
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
export const title = "Komodo DeFi Framework Method: Get Wallet Names";
2+
export const description = "The get_wallet_names method returns a list of wallet names for a user's device.";
3+
4+
# get\_wallet\_names
5+
6+
The `get_wallet_names` method returns returns a list of wallet names for a user's device. If the user is logged in, it will also return the name of the active wallet.
7+
8+
## Arguments
9+
10+
| Structure | Type | Description |
11+
| --------- | ---- | ----------- |
12+
| (none) | | |
13+
14+
#### Response
15+
16+
| Structure | Type | Description |
17+
| ----------------- | ------ | ---------------------------------------------------------------------------- |
18+
| wallet\_names | list | Names of wallets stored on a user's device. |
19+
| activated\_wallet | string | Names of the currrently active wallet. If not yet logged in, returns `null`. |
20+
21+
#### 📌 Examples
22+
23+
#### Command
24+
25+
<CodeGroup title="" tag="POST" label="get_wallet_names" mm2MethodDecorate="true">
26+
```json
27+
{
28+
"userpass": "RPC_UserP@SSW0RD",
29+
"mmrpc": "2.0",
30+
"method": "get_wallet_names",
31+
"id": 0
32+
}
33+
```
34+
</CodeGroup>
35+
36+
<CollapsibleSection expandedText="Hide Response" collapsedText="Show Response">
37+
#### Response (in no-login mode)
38+
39+
```json
40+
{
41+
"mmrpc": "2.0",
42+
"result": {
43+
"wallet_names": ["Robert Paulson", "Spartacus", "John Galt", "Kaiser Soze"],
44+
"activated_wallet": null
45+
},
46+
"id": 0
47+
}
48+
```
49+
50+
#### Response (while logged in)
51+
52+
```json
53+
{
54+
"mmrpc": "2.0",
55+
"result": {
56+
"wallet_names": ["Robert Paulson", "Spartacus", "John Galt", "Kaiser Soze"],
57+
"activated_wallet": "Robert Paulson"
58+
},
59+
"id": 0
60+
}
61+
```
62+
</CollapsibleSection>

0 commit comments

Comments
 (0)