Preheat oven to 180 C / Gas 4. Grease a loaf tin with butter and dust with a little flour.
Heat a frying pan over medium heat without any oil. Add walnuts and cook, shaking the pan every so often, until nuts are toasted and golden brown, about one or two minutes. Transfer to a plate and set aside to cool. Once cooled, chop into coarse pieces.
Mix flour, baking powder, mixed spice and 1 teaspoon of salt together in a bowl; set aside.
In a second bowl, mix the eggs with sugar and vanilla extract. Drizzle in olive oil while you continue to beat. Add flour gradually until well combined. Fold in grated and drained courgettes and toasted walnuts.
Bake the cake in preheated oven for about 75 minutes, until the cake is golden brown on top, but still a little soft inside.
Allow the cake to cool in the tin for a few minutes; remove from tin and cool completely on a wire rack.