Heat oil in a pan and temper with mustard seeds and asafoetida. After it stops spluttering, add the onion, ginger, garlic and green chilies. Saute till light brown.
Add the beans and all the dry spices. Stir fry for 2-3 minutes. Add the coconut and ground peanuts. Mix well and switch off the flame.
Garnish with coriander leaves and serve as a side dish with rice or chapati.