How to wait in cloudflare workers for the client to fully receive response

hi,
is it possible to check that client has fully receive the response from Cloudflare workers. and then save the time difference (start to finish) in kv storage.

like below


addEventListener('fetch', event => {
  event.respondWith(handler(event));
});

async function handler(event) {

	let TimeStampStart = Date.now()
  	res = new Response("someSmallResponse");

	event.waitUntil(

  		// wait for client to fully receive response then
  		let timeStampfinish = Date.now()
  		let totalTimeTaken = TimeStampStart - TimeStampfinish
        await kv.put(totalTimeTaken)
    );

  return res;
}

No, the server has no knowledge of when a client receives or finishes downloading responses. You would need to check that client side and then send that data off to some endpoint to then log.

Alternatively, use Web Analytics which already logs this info