updated api to have server overwrite client data