handle client requests