Question: pkhex how to use mystery gift?
Answer: Start PKHeX and load your save file as described in a previous section.
Click the Mystery Gift button.
Click the Import button and browse to a wonder card.
Right-click an empty slot and choose "Set". If you do not have any empty slots, you will have to overwrite an existing one. ... 
Click Save.
Save your file.