add segment to take care of pagination