from MaxIcsRegistry import MaxIcsRegistry class Settings: def __init__(self, staging): registry = MaxIcsRegistry.from_env(staging=False, skip_delay=True) building_center_info = registry.get_info("building-knowledge-information-center") self.api_key = building_center_info["api_in"][registry.node_id]["key"] self.base_url = "http://{}:{}/api/buildings/".format( building_center_info["service_addr"], building_center_info["service_port"] )