namecoin-core
namecoin-core copied to clipboard
Make "name_new" return a JSON object instead of a JSON array
Is your feature request related to a problem? Please describe.
name_new currently returns a JSON array. This is unpleasant for UX, because it requires the user to remember whether the salt or the txid comes first. It also inhibits API extensibility, e.g. it makes implementing https://github.com/namecoin/namecoin-core/issues/464 a lot less pleasant.
Describe the solution you'd like
Make name_new return a JSON object, with fields named salt and txid (see https://github.com/namecoin/namecoin-core/issues/465 for why the former shouldn't be named rand). This is what Electrum-NMC already does.
Describe alternatives you've considered
N/A.
Additional context
N/A.