1. Preheat the oven to 400º.
2. Heat the oil in an ovenproof skillet over medium-low heat. Add the onion, if desired, and saute with salt and pepper to taste for about 5 minutes.
3. Add the red pepper; sauté for 5 minutes, stirring frequently. Remove the vegetables; set aside.
4. In a small bowl, vigorously whisk the eggs with salt and pepper and basil or thyme, if desired.
5. Spray the skillet and heat over medium heat. Add the eggs and cook for 1 minute. Arrange the onions, if using, over the eggs and arrange the red pepper in a pinwheel shape (or scatter it). Sprinkle on the cheese, if desired.
6. Bake the eggs on the middle rack of the oven for about 14 minutes, or until set.
7. Place the skillet under the broiler for 1 to 2 minutes to help the frittata rise. It should be slightly moist, but a toothpick inserted in the center should come out dry.
8. Cut into wedges and serve hot or at room temperature.