Reading keypresses 32u4

The reason I would like to be able to read and store key presses from the laptop keyboard, is because I'm making something called a macros. My idea is to press a push button wired to the Arduino micro, which tells the board to begin recording any presses. Once I'm done recording for key presses, I press the push button which ends the recording, saves the keys pressed and the duration it was held down, and the duration between the next key press. After all this I press the button one more time that repeats the recording over and over again exactly how I did it. Sorry if this is too complex😅