A subspecialty of internal medicine concerned with the metabolism, physiology, and disorders of the endocrine system.