HMBS and autoimmune pancreatitis: AIP is caused by a partial deficiency of porphobilinogen deaminase (PBGD) (alternative name hydroxymethylbilane synthase (HMBS)), which is the third enzyme in the heme biosynthetic pathway.