Heat oil in a pan & add dried red chilly. Fry it for half a minute. Remove it from the pan & keep aside. Add finely sliced onions & salt. Cook till the onions become soft. It doesn't have to become brown. Add Kashmiri chilly powder. Fry it for a minute. Add sliced tomato & cook till it becomes soft. Add coconut & mix well. Remove from fire & let it cool completely.
Grind the fried dried red chillies first. Add the onion, tomato & coconut mixture to that & grind to a smooth paste. Do not add water. Serve with idly or dosa.