Heat the oil in a frying pan. Add the onion and fry for about 4 minutes, stirring occasionally. Then add the garlic and fry for another minute, stirring constantly, until it is fragrant.
Then add the diced courgettes.
Now add the vegetable stock, pureed tomatoes and red lentils and cook for about 15 minutes, stirring occasionally.
Cook the pasta in salted water.
Serve the pasta with the sauce and some fresh herbs.