code: func (n *NodeConfig) MarshalJSON() ([]byte, error) {
  	confJSON := nodeConfigJSON{
  		ID:              n.ID.String(),
  		Name:            n.Name,
  		Services:        n.Services,
  		Port:            n.Port,
  		EnableMsgEvents: n.EnableMsgEvents,
  	}
  	if n.PrivateKey != nil {
  		confJSON.PrivateKey = hex.EncodeToString(crypto.FromECDSA(n.PrivateKey))
  	}
  	return json.Marshal(confJSON)
  }
docs: // MarshalJSON implements the json.Marshaler interface by encoding the config
  // fields as strings