Intro
The Discreet daemon has a suite of tools for interacting with it via JSON-RPC calls. Additionally, the daemon supports subscription to ZeroMQ (ZMQ) messages for asynchronous notifications.
The RPC methods are divided into API sets, which can be enabled or disabled by the daemon as needed in the configuration file. Some methods require multiple API sets to be enabled, but for the most part a method will only belong to one API set.
Data Representation
Data in the RPC responses is represented by JSON. For cryptographic objects the Discreet daemon uses, such as hashes, ECC scalars and points, entropy/seed data, EdDSA signatures, and commitments, the JSON-RPC response data is represented by a hexadecimal string. Additionally, raw transactions are represented with hexadecimal strings.
Errors
Some calls will fail if improperly used or if the daemon encounters an issue with executing the RPC method. If this happens, a JSON object representing the error will be returned. This will often contain a helpful error message explaining exactly why the call failed, and may also contain partial data from the call. An error code is also returned, but for now, this is always -1.