Dilaudid is an opioid medication. medication is used for moderately severe pain. It also helps in relief from acute pain and chronic cancer pain. It is treated well by coughing. Dilaudid is made up of morphine. It works in the brain to change how your body feels and responds to pain. The dosage is based on the medical condition and responds to treatment.