addPolicyFragment

Method
📦 Aspire.Hosting.Azure.ApiManagement v17.0.0-preview.1.26567.5
interface AzureApiManagementResource {
// ... omitted for brevity
addPolicyFragment(
name: string,
policyXml: string,
description?: string,
fragmentName?: string): AzureApiManagementPolicyFragmentResource;
}

Signature

methodaddPolicyFragmentbuilder
Adds a reusable policy fragment to the API Management service.
addPolicyFragment(
name: string,
policyXml: string,
description?: string,
fragmentName?: string): AzureApiManagementPolicyFragmentResource
namestringThe globally unique Aspire resource name and default physical policy-fragment name.
policyXmlstringOne or more well-formed APIM policy elements without a `fragment` envelope.
descriptionstringoptionalAn optional description.
fragmentNamestringoptionalThe physical policy-fragment identifier in API Management. The resource name is used when omitted.
AzureApiManagementPolicyFragmentResource

Applies to

This method applies to the following types: