Enabling ModTap will give you access to the following keycodes and can simply be added to the modules list.
from kmk.modules.modtap import ModTap
modtap = ModTap()
# optional: set a custom tap timeout in ms
# modtap.tap_time = 300
Custom HoldTap Behavior
The full ModTap signature is as follows:
KC.MT(KC.TAP, KC.HOLD, prefer_hold=True, tap_interrupted=False, tap_time=None)
prefer_hold: decides which keycode the ModTap key resolves to when another key is pressed before the timeout finishes. When
Truethe hold keycode is chosen, the tap keycode when
tap_interrupted: decides if the timeout will interrupt at the first other key press/down, or after the first other key up/release. Set to
Truefor interrupt on release.
tap_time: length of the tap timeout in milliseconds.
Each of these parameters can be set for every ModTap key individually.