Record user events

this is a question:

i am working on a simple app where the user will download a test image, do some retouching to the image, and upload it again-- through a user panel.
the panel will display the time, as they have a time limit

most importantly, the event of the download completing and the event of the initiation of the reupload need to be recorded.

i would really appreciate suggestions on where to look to accomplish this!