udpated post and query apis