Endoscopic pituitary surgery is done to remove certain types of tumors that start to grow in your pituitary gland: Hormone-secreting tumors. These growths secrete chemical messengers that travel through the blood. Nonhormone-secreting tumors.