generate_mnemonic
generate_mnemonic
调用生成长度24的助记词,用于派生私钥。
请求参数
无
响应结果
generate_mnemonic
调用返回一个JSON对象,主要包含以下字段:
- mnemonic:助记词
- success:是否成功
示例代码
请求:
curl --insecure \
--cert ~/.chia/mainnet/config/ssl/wallet/private_wallet.crt \
--key ~/.chia/mainnet/config/ssl/wallet/private_wallet.key \
-d '{"":""}' \
-H "Content-Type: application/json" \
-X POST \
https://localhost:9256/generate_mnemonic
响应:
{
"mnemonic": [
"consider",
"toe",
"board",
"output",
"coral",
"demise",
"latin",
"avocado",
"sight",
"fluid",
"bracket",
"fortune",
"assault",
"cinnamon",
"chronic",
"demand",
"fiscal",
"sea",
"target",
"lake",
"table",
"found",
"raise",
"exhibit"
],
"success": true
}