[ [ 'from' => '573010000002', 'id' => 'TEST_INT_1', 'type' => 'interactive', 'interactive' => [ 'type' => 'list_reply', 'list_reply' => ['id' => 'option_2', 'title' => 'Consultar resultados'] ], 'timestamp' => time() ] ] ]; // Set current menu for user (simulate that menu was shown previously) $db = Database::getInstance(); $db->update('users', ['current_menu_id' => 1, 'current_step' => 1], 'phone_number = :phone', ['phone' => '573010000002']); // Use reflection to call private method processconversations $ref = new ReflectionClass($w); $m = $ref->getMethod('processconversations'); $m->setAccessible(true); $m->invoke($w, $value); // Check DB for last conversations for that phone $db = Database::getInstance(); $user = $db->fetch('SELECT * FROM users WHERE phone_number = ?', ['573010000002']); if ($user) { $rows = $db->fetchAll('SELECT * FROM conversations WHERE user_id = ? ORDER BY created_at DESC LIMIT 5', [$user['id']]); print_r($user); print_r($rows); } else { echo "User not found\n"; }