Following the discussion of #42, we should update the protos by renaming the Name field of the Create*Account request message to Label and make it optional in the service instead of being required.
Also, we should update the response message by returning the AccountInfo of the newly created account.
Internally, we should rename the related domain's actual Name field to Label and add a new one Namespace.
The namespace is something immutable and assigned by the service to every account. It could be a string like <root_path_purpose>-account-<derivation index>, for example 84-account-0 for account 0 of wallet with root path m/84'/<network>'. The namespace must be used by the repo to identify an account uniquely.
The label, instead, is something mutable and set by the user optionally. If a label is set, the user/client can refer to the account with it, otherwise the namespace must be used.
We should add also a new rpc SetAccountLabel to allow one to change account label at will.
Following the discussion of #42, we should update the protos by renaming the
Name
field of theCreate*Account
request message toLabel
and make it optional in the service instead of being required. Also, we should update the response message by returning theAccountInfo
of the newly created account.Internally, we should rename the related domain's actual
Name
field toLabel
and add a new oneNamespace
.The namespace is something immutable and assigned by the service to every account. It could be a string like
<root_path_purpose>-account-<derivation index>
, for example84-account-0
for account 0 of wallet with root pathm/84'/<network>'
. The namespace must be used by the repo to identify an account uniquely.The label, instead, is something mutable and set by the user optionally. If a label is set, the user/client can refer to the account with it, otherwise the namespace must be used.
We should add also a new rpc
SetAccountLabel
to allow one to change account label at will.