added functionality for batchrequest