Place the onion, garlic and ginger in a food processor and blend to a purée. Heat the oil in a large flameproof casserole dish, add the onion mixture and cook for 5 mins until softened. Add the chillies, curry leaves, thyme, curry powder and 2 tsp salt. Cook for 2-3 mins until fragrant.
Tip the mutton or goat into the pan. Cook for 5 mins over a medium-high heat until the meat has browned. Add the chopped tomatoes and stock. Increase the heat, bring to the boil and cook for 10 mins. Reduce heat, cover and leave to simmer gently for 2½ hrs – remove the lid for the final 30 mins of cooking. Add the beans to heat through, plus more chilli if you want it spicier. After 5 mins more, remove from the heat. Add the lemon juice and coriander, and stir well. Serve with warmed roti and rice.