// Paginate through all customers
$allCustomers = [];
$cursor = null;
$pageNumber = 1;
do {
// Get current page (20 customers per page)
$page = RevenueCat::listCustomers(20, $cursor);
echo "Page {$pageNumber}: " . count($page->items()) . " customers\n";
// Process customers on this page
foreach ($page->items() as $customer) {
echo $customer->getId();
echo $customer->getLastSeenPlatform();
$allCustomers[] = $customer; // Collect all customers
}
// See [CustomerData](DATA.md#customerdata) for all available methods
// Get cursor for next page
$cursor = $page->nextCursor();
$pageNumber++;
} while ($cursor); // Continue until no more pages
echo "Total customers found: " . count($allCustomers);
// Custom page size and starting point
$page = RevenueCat::listCustomers(100, 'cursor_123');