To make the masala: In a small frying pan, sauté the red chilli peppers, coriander, chilli powder, poppy seeds, cumin, garlic, cardamom and saunf. Let cool and transfer to a small bowl, then grind together with the green chilli peppers, tamarind, ginger and coriander to make a smooth paste. Set aside.
Heat oil in a large frying pan over medium heat and sauté onions until brown. Add masala mixture and sauté for about 7 to 10 minutes.
Add chicken pieces, reduce heat to low and simmer for 25 to 30 minutes or until chicken is cooked through. Bring all to a boil, cook for 1 minute, then remove from heat. Garnish with shredded coconut and serve.