A set of string key and string value pairs to be sent to apps for users to whom the configuration is scoped, unalterned by this service Inherited from managedAppConfiguration
deployedAppCount
Int32
Count of apps to which the current policy is deployed.
isAssigned
Boolean
Indicates if the policy is deployed to any inclusion groups or not.
Response
If successful, this method returns a 201 Created response code and a targetedManagedAppConfiguration object in the response body.
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new TargetedManagedAppConfiguration
{
OdataType = "#microsoft.graph.targetedManagedAppConfiguration",
DisplayName = "Display Name value",
Description = "Description value",
Version = "Version value",
CustomSettings = new List<KeyValuePair>
{
new KeyValuePair
{
OdataType = "microsoft.graph.keyValuePair",
Name = "Name value",
Value = "Value value",
},
},
DeployedAppCount = 0,
IsAssigned = true,
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.DeviceAppManagement.TargetedManagedAppConfigurations.PostAsync(requestBody);
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
TargetedManagedAppConfiguration targetedManagedAppConfiguration = new TargetedManagedAppConfiguration();
targetedManagedAppConfiguration.setOdataType("#microsoft.graph.targetedManagedAppConfiguration");
targetedManagedAppConfiguration.setDisplayName("Display Name value");
targetedManagedAppConfiguration.setDescription("Description value");
targetedManagedAppConfiguration.setVersion("Version value");
LinkedList<KeyValuePair> customSettings = new LinkedList<KeyValuePair>();
KeyValuePair keyValuePair = new KeyValuePair();
keyValuePair.setOdataType("microsoft.graph.keyValuePair");
keyValuePair.setName("Name value");
keyValuePair.setValue("Value value");
customSettings.add(keyValuePair);
targetedManagedAppConfiguration.setCustomSettings(customSettings);
targetedManagedAppConfiguration.setDeployedAppCount(0);
targetedManagedAppConfiguration.setIsAssigned(true);
TargetedManagedAppConfiguration result = graphClient.deviceAppManagement().targetedManagedAppConfigurations().post(targetedManagedAppConfiguration);
Here is an example of the response. Note: The response object shown here may be truncated for brevity. All of the properties will be returned from an actual call.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see: https://aka.ms/ContentUserFeedback.