This is the proposed API for whisper v5.
Returns the current semver version number.
none
String
- The semver version number.
// Request
curl -X POST --data '{"jsonrpc":"2.0","method":"shh_version","params":[],"id":1}'
// Result
{
"id":1,
"jsonrpc": "2.0",
"result": "5.0.0"
}
Returns diagnostic information about the whisper node.
none
Object
- diagnostic information with the following properties:
memory
-Number
: Memory size of the floating messages in bytes.message
-Number
: Number of floating messages.
// Request
curl -X POST --data '{"jsonrpc":"2.0","method":"shh_info","params":[],"id":1}'
// Result
{
"id":1,
"jsonrpc": "2.0",
"result": {
"memory": 10000,
"messages": 20
}
}
Sets the maximal message length allowed by this node. This rejects incoming and outgoing messages with a size larger than set by this function.
Number
: Message size in bytes.
Boolean
- true
on success and an error on failure.
// Request
curl -X POST --data '{"jsonrpc":"2.0","method":"shh_setMaxMessageLength","params":[234567],"id":1}'
// Result
{
"id":1,
"jsonrpc": "2.0",
"result": true
}