API method for listing all hosts