update docs

This commit is contained in:
Dmitry Novotochinov 2019-10-03 15:33:24 +03:00
parent 34a76aeef9
commit c97d629a7d
No known key found for this signature in database
GPG Key ID: 43D1DAF5AD39C927
1 changed files with 15 additions and 7 deletions

View File

@ -136,9 +136,9 @@ Keycard.generateAndLoadKey(mnemonic, pairing, pin).then(data => console.log(data
"key-uid":"a88d46499e5690c6ad637e243e83cf51be3e2c67e48324b2b2def3e6a0492576"}
```
`address` is an address of root key
`address` is an address of root key `m/44'/60'/0'/0`
`public-key` is public key of root key
`public-key` is public key of root key `m/44'/60'/0'/0`
`wallet-address` is ethereum address of key with derivation path `m/44'/60'/0'/0/0`
@ -158,13 +158,21 @@ Keycard.getKeys(pairing, pin).then(data => console.log(data));
`data` object contains:
```javascript
{"encryption-public-key": "04d36d64bea374b917bc097646cb4e81061c7b0ab0872207480b886e66fb52d53774e303e2aa07a1107776f312b94663566765a8a75cf0a92b0851017b28b356a1",
{"address": "b19a57f4d3241e6a123ea332241d6f03790075b4",
"public-key": "0427cc3998d0e0b8d56b64fad4d1f025914b8cb72558810c74dd34454fcd6907f6f7429a0726dceec9b93c9060103ff8b2e7daa1cb9a4dd62b7ae1ba2232709555",
"wallet-address": "9726cbc67d170307dd80af6416ebe844e7b8eb1c",
"wallet-public-key": "04065670509d295cb8330e02a688eafe83dbbb317486062482725ba1036dba396d635e91afd9a9e7087c0dfeaccf30d2004d092ed250d62b5c75f8bb4c9326d409",
"whisper-address": "438e576b638bff08b2872dd708cf0240811d79af",
"whisper-public-key": "04add221cb97dde8afbf3be27b0bfb3b6842071cb1052abfc3c34d45eba944dc10dcba5d4823fe69148ae17b12ed459237124365c2f46c2b46be9537ce6efa93c8",
"whisper-private-key":"073d77b952b3b92ba66947df53d03b23bc4cc8cf10cbba1060fe25a569c8ee6b",
"wallet-address":"9726cbc67d170307dd80af6416ebe844e7b8eb1c"
"whisper-address": "79db2df8445c2dab351ccbc7ed66220f7cb4636e"}
"whisper-private-key": "073d77b952b3b92ba66947df53d03b23bc4cc8cf10cbba1060fe25a569c8ee6b",
"encryption-public-key": "04d36d64bea374b917bc097646cb4e81061c7b0ab0872207480b886e66fb52d53774e303e2aa07a1107776f312b94663566765a8a75cf0a92b0851017b28b356a1",
"instance-uid": "21c0ce19aa9a26efc02fd32078c08527",
"key-uid":"a88d46499e5690c6ad637e243e83cf51be3e2c67e48324b2b2def3e6a0492576"}
```
Response is identical to `generateAndLoadKey`.
Please refer to `generateAndLoadKey` response for detailed description.
### Sign
```javascript
const pairing = "AFFdkP01GywuaJRQkGDq+OyPHBE9nECEDDCfXhpfaxlo";
@ -267,4 +275,4 @@ Keycard.installApplet().then(() => console.log("applet installed"));
```
### Keycard CLI
You can also interact with keycard (installing and removing applet, getting card info, etc) using [keycard cli](https://github.com/status-im/keycard-cli). You'll need a USB reader for that.
You can also interact with keycard (installing and removing applet, getting card info, etc) using [keycard cli](https://github.com/status-im/keycard-cli). You'll need a USB reader for that.