adding some methods and hashes to the api controller