Skip to content

Latest commit

 

History

History
38 lines (31 loc) · 1.12 KB

File metadata and controls

38 lines (31 loc) · 1.12 KB
description Automatically generated file. DO NOT MODIFY
// Code snippets are only available for the latest version. Current version is 5.x

// Dependencies
using Microsoft.Graph.Beta.Models;

var requestBody = new OnAttributeCollectionSubmitCustomExtension
{
	OdataType = "#microsoft.graph.onAttributeCollectionSubmitCustomExtension",
	DisplayName = "attributeCollectionSubmitName",
	Description = "example description",
	AuthenticationConfiguration = new AzureAdTokenAuthentication
	{
		OdataType = "#microsoft.graph.azureAdTokenAuthentication",
		ResourceId = "api://contoso.com/fb96de85-2abe-4b02-b45f-64ba122c509e",
	},
	EndpointConfiguration = new HttpRequestEndpoint
	{
		OdataType = "#microsoft.graph.httpRequestEndpoint",
		TargetUrl = "https://contoso.com",
	},
	ClientConfiguration = new CustomExtensionClientConfiguration
	{
		TimeoutInMilliseconds = 2000,
		MaximumRetries = 1,
	},
};

// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Identity.CustomAuthenticationExtensions.PostAsync(requestBody);