Acid or spasticity
In the upper tract, hyperacid states or gastroesophageal refulx where acid goes back up into the esophagus, may cause pain.
Blockage of a duct, like the gall bladder or the pancreas
, from a stone or tumor can cause severe pain. In the rest of the small intestine (jejunum, ileum) or large intestine (colon
), spasm of the intestinal wall muscle will cause pain.