Preheat your oven to 350°F (175°C). Position a rack in the center of the oven so the casserole can bake evenly. Coat the bottom and sides of a 2-quart (1.9 L) oven-safe casserole dish with 1 teaspoon (5 mL) vegetable oil. The dish should have a thin, even coating to help prevent sticking.
Wash and dry the zucchini, then shred it using the large holes of a box grater. Measure 4 cups (approximately 500 g) of loosely packed shredded zucchini. If it looks very wet, gently pat it with a clean kitchen towel or paper towels to remove excess surface moisture. Don't squeeze it completely dry; the zucchini should still look moist and fresh.
Finely chop 1 medium yellow onion (approximately 150 g) into small, even pieces. Crack 2 large eggs (approximately 100 g without shells) into a medium mixing bowl and beat with a whisk or fork until the yolks and whites are fully combined. The eggs should look smooth and evenly yellow, with no separate streaks of egg white.
Place the shredded zucchini and chopped onion in a large mixing bowl. Add the beaten eggs, 1 package (8.5 oz / 241 g) dry corn muffin mix, 1/2 teaspoon (approximately 3 g) fine salt, and 1/4 teaspoon (approximately 0.5 g) ground black pepper. Stir until the dry mix is evenly moistened and distributed throughout the vegetables. The mixture should be thick, with no visible pockets of dry mix.
Add one 4 oz (113.5 g) portion of shredded sharp Cheddar cheese to the zucchini mixture. Fold gently with a large spoon or silicone spatula until the cheese is evenly distributed. The filling should look thick and chunky rather than smooth or pourable. Avoid excessive stirring once everything is combined.
Transfer the zucchini and cornbread mixture into the prepared 2-quart (1.9 L) casserole dish. Spread it into an even layer with the back of a spoon or silicone spatula, making sure the mixture reaches the corners. Sprinkle the remaining 4 oz (113.5 g) shredded sharp Cheddar evenly across the top.
Place the uncovered casserole on the center rack of the preheated 350°F (175°C) oven. Bake for approximately 60 minutes, until the top is golden brown, the edges are lightly browned, and the center looks set rather than wet or loose. Insert a toothpick or thin kitchen knife into the center. It should come out without raw batter, although a little melted cheese or moisture from the vegetables is normal.
Remove the casserole from the oven using oven mitts and place the dish on a wire cooling rack. Let it rest for 10 minutes before cutting. During this time, the filling will firm up slightly, making it easier to serve. Cut into 8 portions and serve warm, when the cheese is still soft and the casserole holds together.