Skip to content

Conversation

Copy link

Copilot AI commented Oct 24, 2025

Problem

Several policies that were previously classified as Settings Catalog now have unique policy types with different technologies values (such as windows365, microsoftSense, endpointPrivilegeManagement, etc.). These policies can no longer be imported with the existing Settings Catalog scripts, nor by Intune's native import/export feature, which were designed only for traditional MDM policies filtering by technologies has 'mdm'.

Solution

This PR introduces a new ConfigurationPolicy folder with a comprehensive set of PowerShell scripts that mirror the functionality of existing scripts like SettingsCatalog_Export.ps1 and DeviceConfiguration_Import_FromJSON.ps1, but with support for all technology types.

New Scripts Added

  1. ConfigurationPolicy_Get.ps1 - Retrieves and displays all configuration policies with their key properties
  2. ConfigurationPolicy_Export.ps1 - Exports configuration policies to JSON format with optional filtering by platform and/or technology
  3. ConfigurationPolicy_Import_FromJSON.ps1 - Imports configuration policies from JSON files with full settings restoration
  4. ConfigurationPolicy_Remove.ps1 - Removes configuration policies with user confirmation
  5. ConfigurationPolicy_Assign.ps1 - Assigns policies to Azure AD groups (supports both include and exclude assignments)
  6. ConfigurationPolicy_Get_Assign.ps1 - Retrieves and displays all assignments for a specific policy
  7. readme.md - Comprehensive documentation with usage examples and clear explanations

Technology Types Supported

Unlike the Settings Catalog scripts which only support mdm, these Configuration Policy scripts support all technology types:

  • mdm - Traditional Mobile Device Management (Settings Catalog)
  • windows365 - Windows 365 Cloud PC policies
  • microsoftSense - Microsoft Defender for Endpoint policies
  • endpointPrivilegeManagement - Endpoint Privilege Management policies
  • configManager - Configuration Manager policies
  • appleRemoteManagement - Apple Remote Management policies
  • And 7+ additional technology types

Usage Example

# Export all configuration policies regardless of technology type
Connect-MgGraph -Scopes "DeviceManagementConfiguration.Read.All"
.\ConfigurationPolicy_Export.ps1
# Specify export path: C:\IntuneBackup

# Import a policy back
Connect-MgGraph -Scopes "DeviceManagementConfiguration.ReadWrite.All"
.\ConfigurationPolicy_Import_FromJSON.ps1
# Specify JSON file path: C:\IntuneBackup\MyPolicy_24-10-2025-10-30-00.json

Key Features

  • Complete technology support - Works with all policy technology types, not just MDM
  • Consistent with repository patterns - Follows the same structure as DeviceConfiguration scripts
  • Template preservation - Maintains templateReference for template-based policies
  • Comprehensive error handling - Includes proper error handling and user-friendly prompts
  • Well documented - Includes detailed readme with usage examples for all scenarios

This solution enables administrators to backup, migrate, and automate management of modern Intune configuration policies across all supported technology types, addressing the gap left by the Settings Catalog scripts.

Original prompt

This section details on the original issue you should resolve

<issue_title>Import/Export Scripts for former Settings Catalog Policies</issue_title>
<issue_description>Several policies that were previously classified as Settings Catalog now have unique policy types, and can no longer be imported with the Settings Catalog scripts, nor by Intune's native import/export feature which was designed for Settings Catalog.

Please provide scripts to handle the import/export of these new policy types, mirroring the functionality of existing scripts such as SettingsCatalog_Export.ps1 and DeviceConfiguration_Import_FromJSON.ps1.</issue_description>

Comments on the Issue (you are @copilot in this section)

Fixes #27


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 4 commits October 24, 2025 06:13
…types

Co-authored-by: Mahopper <29206133+Mahopper@users.noreply.github.com>
Co-authored-by: Mahopper <29206133+Mahopper@users.noreply.github.com>
Co-authored-by: Mahopper <29206133+Mahopper@users.noreply.github.com>
Co-authored-by: Mahopper <29206133+Mahopper@users.noreply.github.com>
Copilot AI changed the title [WIP] Add import/export scripts for new policy types Add Configuration Policy import/export scripts for all technology types Oct 24, 2025
Copilot AI requested a review from Mahopper October 24, 2025 06:24
Copilot finished work on behalf of Mahopper October 24, 2025 06:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Import/Export Scripts for former Settings Catalog Policies

2 participants