Added next/prev api support