It's been covered here before; but not for a while. This is a condensed version summarizing the primary targets of opioid analgesia.
1) Ascending Inhibition (Dorsal Horn)
Mu receptor activity inhibits sensory afferent pathways, reducing the flow of noxious stimulus to the brain.
Presynaptic receptors: block the release of substance P.
Post synaptic receptors: desensitize the receiving neuron to excitatory stimulation.
2) Descending Modulation (PAG, Medulla, Spinal Cord)
PAG: Opioids inhibit GABA interneurons allowing excitatory transmission to the medulla.
Projections to the medulla activate descending interneurons which release serotonin & norepinephrine at the spinal level. Both act through a2 adrenergic and 5-HT receptors to modulate ascending pain pathways; potentiating the action of opioids at the spinal level.
3) Altered Emotional Perception (Limbic Pathways i.e. Pleasure Centers)
Mu receptors throughout the ventral tegmental area (VTA) inhibit GABA's inhibitory role; allowing a burst in the transmission of dopamine from the VTA. Dopamine pathways project to key areas of the brain involved in emotional processing, including the Nucleus Accumbens, producing a state of well being and reducing the emotional perception of pain.
4) Reduced Sympathetic Reaction (LC, Hypothalamic Pituitary Adrenal Axis)
Mu receptors mediate depression of the locus coeruleus (LC) and reduce sympathetic arousal. The LC plays a role in the body's physiological response to pain (i.e. fight or flight mode, adreno-response) and other stressors. LC inhibition produces sedation, relaxation & anxiolysis.