This repository of PowerShell sample scripts show how to access Intune service resources. They demonstrate this by making HTTPS RESTful API requests to the Microsoft Graph API from PowerShell.
Hi, i'm trying to pass simple functions through to these scripts including the tenant admin UPN (so it doesn't ask) and the JSON directory output (again so it doesn't ask). This is to automate the scripting process however I can't seem to get these scripts to accept the passed params?
They seem to have a param configured for use from what i can see? (for $user and $json)
What i'm pushing to the .ps1 via a batch:
powershell.exe -command 'powershell-intune-samples-master\CompliancePolicy\CompliancePolicy_Import_FromJSON.ps1' -User 'user@domain.com' -JSON 'dirname'
Hi, i'm trying to pass simple functions through to these scripts including the tenant admin UPN (so it doesn't ask) and the JSON directory output (again so it doesn't ask). This is to automate the scripting process however I can't seem to get these scripts to accept the passed params?
They seem to have a param configured for use from what i can see? (for $user and $json)
What i'm pushing to the .ps1 via a batch: powershell.exe -command 'powershell-intune-samples-master\CompliancePolicy\CompliancePolicy_Import_FromJSON.ps1' -User 'user@domain.com' -JSON 'dirname'
Any help is much appreciated.