To make sure that the recipient received the file completely, just wait for the ACK packet to arrive at the last byte sent. But as far as I know, existing TCP drivers do not allow this information to be obtained.
In addition, the HTTP.SYS driver and the IIS web server hide the real TCP socket.
Therefore, the output could be to place a separate samopny HTTP server on a separate port that would not use persistent connections — in this case, the file can be deleted after the end of the incoming stream.
But there is another problem. The fact is that any proxy server will be happy to cache the result of the request - and forget to give it to the client. And browsers are happy to make fun of the protocol (for example, forget to close the connection) ...
Therefore, you need to decide what is more important: delete the file or deliver it to the user.
In the second case, it is best to delete the file by timer. For example, a month after the first download.
In the first case, you can take this code as a basis: FilePathResult.cs - and add the file deletion there after the full upload.