adding getRequest function