package class tree deprecated index help com.samsung.android.sdk.coldwallet class scwservice java.lang.object com.samsung.android.sdk.coldwallet.scwservice public class scwservice extends java.lang.object class for the proxy to use the samsung blockchain keystore service. the keystore's hd wallet seed is bip-39 compatible see also: https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki nested class summary nested classes modifier and type class and description static class scwservice.scwcheckformandatoryappupdatecallback callback for checkformandatoryappupdate api static class scwservice.scwgetaddresslistcallback callback for getaddresslist api static class scwservice.scwgetextendedpublickeylistcallback callback for getextendedpublickeylist api static class scwservice.scwsignbtctransactioncallback callback for signbtctransaction api static class scwservice.scwsignethpersonalmessagecallback callback for signethpersonalmessage api static class scwservice.scwsignethtransactioncallback callback for signethtransaction api static class scwservice.scwsignklaytransactioncallback callback for signklaytransaction api method summary all methods static methods instance methods concrete methods modifier and type method and description void checkformandatoryappupdate(scwservice.scwcheckformandatoryappupdatecallback callback) checks whether a mandatory update of samsung blockchain keystore is needed or not. void getaddresslist(scwservice.scwgetaddresslistcallback callback, java.util.arraylist<java.lang.string> hdpath) request to get a list of addresses that corresponds to a list of hd paths void getextendedpublickeylist(scwservice.scwgetextendedpublickeylistcallback callback, java.util.arraylist<java.lang.string> hdpath) request to get a list of extended public keys that corresponds to a list of hd paths static scwservice getinstance() return the instance of the keystore proxy object int getkeystoreapilevel() get api level which the keystore in the device supports java.lang.string getseedhash() get the pseudo seed hash which is randomly generated when the hd wallet created whenever the seed for the wallet is changed, this key shall be changed. int[] getsupportedcoins() get coin types supported by samsung blockchain keystore void signbtctransaction(scwservice.scwsignbtctransactioncallback callback, byte[] transaction, java.util.list<java.lang.string> hdpathlist, java.util.list<byte[]> utxotxlist, java.lang.string changehdpath) request to sign bitcoin transaction void signethpersonalmessage(scwservice.scwsignethpersonalmessagecallback callback, byte[] msg, java.lang.string hdpath) request to sign ethereum typed structured data void signethtransaction(scwservice.scwsignethtransactioncallback callback, byte[] transaction, java.lang.string hdpath) request to sign ethereum transaction void signklaytransaction(scwservice.scwsignklaytransactioncallback callback, byte[] transaction, java.lang.string hdpath, int networkid) request to sign klay transaction methods inherited from class java.lang.object equals, getclass, hashcode, notify, notifyall, tostring, wait, wait, wait method detail getinstance public static scwservice getinstance() return the instance of the keystore proxy object returns: the instance, or null if samsung blockchain keystore is not available on the device getkeystoreapilevel public int getkeystoreapilevel() get api level which the keystore in the device supports caution : you should check the api level before invoking any apis. otherwise, it will return scwapilevelexception. if keystore api level is lower than the required level, update the keystore app first via scwdeeplink.galaxy_store returns: api level since: api level 1 getseedhash public java.lang.string getseedhash() get the pseudo seed hash which is randomly generated when the hd wallet created whenever the seed for the wallet is changed, this key shall be changed. returns: null if keystore does not support wallet key, zero-length string if the wallet is not created. otherwise, wallet is created. since: api level 1 getsupportedcoins public int[] getsupportedcoins() get coin types supported by samsung blockchain keystore returns: array of coin types, scwcointype throws: scwapilevelexception - api level exception since: api level 1 see also: https://github.com/satoshilabs/slips/blob/master/slip-0044.md checkformandatoryappupdate public void checkformandatoryappupdate(@nonnull scwservice.scwcheckformandatoryappupdatecallback callback) checks whether a mandatory update of samsung blockchain keystore is needed or not. do not call this method in the background thread. if there is a mandatory update, you need to open the app update link, scwdeeplink.galaxy_store parameters: callback - result callback since: api level 1 getextendedpublickeylist public void getextendedpublickeylist(@nonnull scwservice.scwgetextendedpublickeylistcallback callback, @nonnull java.util.arraylist<java.lang.string> hdpath) request to get a list of extended public keys that corresponds to a list of hd paths parameters: callback - result callback hdpath - the hd path list to bring the public keys. the depth of a path should be between 3 and 6. for example, "m/44'/60'", "m/44'/60'/0'/0/0" since: api level 1 see also: https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki getaddresslist public void getaddresslist(@nonnull scwservice.scwgetaddresslistcallback callback, @nonnull java.util.arraylist<java.lang.string> hdpath) request to get a list of addresses that corresponds to a list of hd paths parameters: callback - result callback hdpath - the hd path list to bring the addresses. the depth of a path should be between 3 and 6. for example, "m/44'/60'", "m/44'/60'/0'/0/0" since: api level 1 see also: https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki signethtransaction public void signethtransaction(@nonnull scwservice.scwsignethtransactioncallback callback, @nonnull byte[] transaction, @nonnull java.lang.string hdpath) request to sign ethereum transaction parameters: callback - result callback transaction - a byte array of a rlp-encoded unsigned ethereum transaction hdpath - hd path that corresponds to public key needed for signing since: api level 1 signethpersonalmessage public void signethpersonalmessage(@nonnull scwservice.scwsignethpersonalmessagecallback callback, @nonnull byte[] msg, @nonnull java.lang.string hdpath) request to sign ethereum typed structured data parameters: callback - result callback msg - a byte array of raw message to be signed. the keystore will add "ethereum signed message:\n" prefix, so it should not be included in msg. hdpath - hd path that corresponds to public key needed for signing since: api level 1 see also: https://github.com/ethereum/eips/blob/master/eips/eip-712.md signklaytransaction public void signklaytransaction(@nonnull scwservice.scwsignklaytransactioncallback callback, @nonnull byte[] transaction, @nonnull java.lang.string hdpath, @nonnull int networkid) request to sign klay transaction parameters: callback - result callback transaction - a byte array of a raw transaction to be signed by samsung blockchain keystore. the transaction is same as the sigrlp value mentioned in klaytn's official document. hdpath - hd path that corresponds to public key needed for signing networkid - the klaytn network id, or the integer to identify the network. "8217" is klaytn cypress mainnet and "1001" is klaytn baobab testnet. since: api level 2 see also: https://docs.klaytn.com/node/en/installation/config signbtctransaction public void signbtctransaction(@nonnull scwservice.scwsignbtctransactioncallback callback, @nonnull byte[] transaction, @nonnull java.util.list<java.lang.string> hdpathlist, @nonnull java.util.list<byte[]> utxotxlist, @nonnull java.lang.string changehdpath) request to sign bitcoin transaction parameters: callback - result callback transaction - a byte array of a serialized unsigned bitcoin transaction to be signed by samsung blockchain keystore hdpathlist - a list of hd paths that corresponds to utxo's public key utxotxlist - a list of byte array of the serialized transaction which contain the utxo used in this transaction changehdpath - hd path that corresponds to the change address since: api level 2 see also: https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki, https://github.com/bitcoin/bips/blob/master/bip-0049.mediawiki, https://github.com/bitcoin/bips/blob/master/bip-0084.mediawiki