Why do I get a migraine after having an orgasm?

Coital headache. These are generally called benign coital headache, but you need to see a neurologist to get an mri/a to make sure that there is no pressure in your brain.
Coital headache. This is a recognized headache type, occurring with some frequency but still not very common. Measures to prevent this headache may work, such as taking a beta blocker prior to sexual activity, though this may affect sexual performance.
Not unique. The term "thunderclap headache" is used to describe such a phenomenon in many males; and, in your case, this is part of a well-described migraine phenomenon. Have prescribed preventative meds for similar cases, and recommend using an otc approach, such as butterbur, riboflavin, or co-q-10, and would work closely with your doctor. Do not usually get MRI for this, but see if exam is normal first.
Migraine. Orgasm has been a known trigger for migraines. The exact cause is not known. Depending on the frequency of the headaches you may need a prophylactic medication. Talk to your pcp or a neurologist as you may also need an headache-abortive medication.