First working instance of the api
Added another check to ensure data and key are the same
Updated return codes