Added a maxResponses var to limit the number of responses returned.