Heat oil in a large saucepan over medium heat. When hot, add onions and cook until translucent, about 4 minutes. Add mushrooms and squash and cook, stirring often, until tender, about 5 minutes.
Add broth and bring to a boil. Add orzo and continue to simmer until pasta is cooked, about 15 minutes.
Taste and season with salt and pepper.
Whisk eggs thoroughly in a medium bowl. Using a soup ladle, while whisking the eggs briskly, slowly add hot broth to the eggs. Once you've added about a cup of broth to the eggs, return everything to the saucepan and add lemon and zest.
Heat on low, stirring often, until the broth thickens slightly. Do not boil (if you have a thermometer, heat to 175°F).
Serve immediately.