Add support for pagination