def METHOD_NAME(self, filename: str, metadata: GenericMetadata) -> None:
    cbi_container = self.create_json_dictionary(metadata)
    with open(filename, "w", encoding="utf-8") as f:
        f.write(json.dumps(cbi_container, indent=4))