finished initial implementation -- need to handle optional and required keys somehow