code: def rpc_get_name_cost( self, name, **con_info ):
          
          if not check_name(name):
              return {'error': 'Invalid name or namespace', 'http_status': 400}
  
          db = get_db_state(self.working_dir)
          ret = get_name_cost( db, name )
          db.close()
  
          if ret is None:
              return {"error": "Unknown/invalid namespace", 'http_status': 404}
  
          return self.success_response(ret)
docs: Return the cost of a given name.
          Returns {'amount': ..., 'units': ...}