They work by increasing glucose transport inside cells or some work by decreasing the absorption of glucose from the intestine.
These drugs try to lower the blood glucose levels and come with their side effects, the actual treatment is lifestyle changes and a healthy diet (vegetarian).