How would the client cancel a request? Since the HTTP protocol does not support cancellation, the only thing I can think of is a client actively dropping the TCP connection with the server. I'm not sure how Ktor deals with clients disconnecting while processing a request, and if you can tap into that to cancel whatever job you are running.