added api support for pig and dug