Heat the oil in a large non-stick pan. Add the cumin, onion and chillies and cook until the onions are soft and beginning to colour.
When the onions are cooked, stir in the turmeric, salt, carrots and potatoes. Cover the pan and cook over a low heat, stirring often. If necessary, add a splash of water to prevent the vegetables from burning.
After about 15 minutes, add the cucumber and beans. Cover the pan again and cook for a further 5-10 minutes until all the vegetables are tender.
Meanwhile, place the shallots, ginger and coconut (complete with its soaking liquid) into a blender. Blend to a fine paste before adding to the pan, along with the peas. Cook for a further five minutes, stirring thoroughly. Tear the curry leaves into the pan and stir in the yoghurt.
To serve, take the pan off the heat and pour the coconut oil over the vegetables, if using. Spoon the mixture on to six serving plates and serve with basmati rice.