Import an existing key
//Converts a private key string to PrivateKey
PrivateKey privateKey = PrivateKey.fromStringED25519("302e020100300506032b657004220420d763df96caaabf192c67326e87c32a1ae4571f739022c77d2acaae5dd09cfb13");
//The public key associated with the private key
PublicKey publicKey = PublicKey.fromStringED25519("302a300506032b65700321008f556741dcb5e144e5cabfce5355ad5050ec7a6ea15787a5fd759d616e047d24");//Converts a private key string to PrivateKey
const privateKey = PrivateKey.fromStringED25519("302e020100300506032b657004220420d763df96caaabf192c67326e87c32a1ae4571f739022c77d2acaae5dd09cfb13");
//The public key associated with the private key
const publicKey = PublicKey.fromStringED25519("302a300506032b65700321008f556741dcb5e144e5cabfce5355ad5050ec7a6ea15787a5fd759d616e047d24");//Converts a private key string to PrivateKey
privateKey, err := hedera.PrivateKeyFromStringEd25519("302e020100300506032b65700422042012a4a4add3d885bd61d7ce5cff88c5ef2d510651add00a7f64cb90de3359b105")
if err != nil {
panic(err)
}
//The public key associated with the private key
publicKey, err := hedera.PublicKeyFromString("302a300506032b6570032100d292412f1c86507224c1db656050c2162c91983540d608f6a31e9b43359bc5e")
if err != nil {
panic(err)
}Last updated