Aside from following the instructions here:
https://support.apple.com/en-gb/ht201065
you basically need to use internet recovery to erase your drive and reinstall the original OS version so it will not be tied to your Apple ID and the buyer can set it up with their own. Here are the new key combos depending on which OS you are running: