TL;DR it depends what you want to do, but most of the time event or hardware will do what you need.
If all you need is to get “was a key pressed, which one, and when”, then the event functions are probably your best bet. It’s sort of the “default” for PsychoPy. It checks whether a key has been pressed, and it gets a list of the keys and their timestamps.
When it comes to keyboards, hardware is basically the same as event, just newer and shinier, and it adds the ability to pull duration information (i.e., how long a key was held down, after it has been released). If you were using more than one keyboard, hardware.keyboard can handle that too.
By and large iohub would only be worth it if you were already using iohub for something else, like an eye-tracker, and I believe it’s better at letting you send events to other hardware, but having not done much of that myself I can’t swear to it. Iohub is also more useful if you find yourself using a non-standard keyboard in some way, or a non-standard input that you want to treat like a keyboard.
There’s also other things you can do if, for example, you want to check on each frame whether a given key is being held down. Iohub can handle this, but I find it easier to just access the Pyglet keyboard events directly in that case. See here: Tracking Key release