Angular Factory service for creating APIs which interact with Google Endpoint APIs