Updated API to include data storage