Added documentation, added check for api key, changed some method names