---
title: "POST /subscriptions/{subscriptionId}/providers/Microsoft.Resources/deploymentStacks/{deploymentStackName}/validate"
method: POST
path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deploymentStacks/{deploymentStackName}/validate"
tags: ["DeploymentStacksAtSubscription"]
---

# POST /subscriptions/{subscriptionId}/providers/Microsoft.Resources/deploymentStacks/{deploymentStackName}/validate

`POST /subscriptions/{subscriptionId}/providers/Microsoft.Resources/deploymentStacks/{deploymentStackName}/validate`

Runs preflight validation on the Deployment stack template at the specified scope to verify its acceptance to Azure Resource Manager.

## Path parameters

- `deploymentStackName` string, required

## Parameters

- `../../../../../../common-types/resource-management/v6/types.json#/components/parameters/ApiVersionParameter` — unresolved $ref
- `../../../../../../common-types/resource-management/v6/types.json#/components/parameters/SubscriptionIdParameter` — unresolved $ref

## Request body

- DeploymentStack — unresolved $ref

## Response `200`

Azure operation completed successfully.

- DeploymentStackValidateResult — The Deployment stack validation result.
  - `id` string — String Id used to locate any resource on Azure.
  - `name` string — Name of this resource.
  - `type` string — Type of this resource.
  - `systemData` SystemData — unresolved $ref
  - `error` ErrorDetail — unresolved $ref
  - `properties` DeploymentStackValidateProperties — The Deployment stack validation result details.
    - `actionOnUnmanage` ActionOnUnmanage — Defines the behavior of resources that are no longer managed after the stack is updated or deleted.
      - `resources` 'delete' | 'detach', required — Specifies an action for a newly unmanaged resource.
      - `resourceGroups` 'delete' | 'detach' — Specifies an action for a newly unmanaged resource group.
      - `managementGroups` 'delete' | 'detach' — Specifies an action for a newly unmanaged resource.
      - `resourcesWithoutDeleteSupport` 'detach' | 'fail' — Specifies an action for resources that do not support deletion.
    - `correlationId` string — The correlation id of the Deployment stack validate operation. It is in GUID format and is used for tracing.
    - `denySettings` DenySettings — Defines how resources deployed by the Deployment stack are locked.
      - `mode` 'denyDelete' | 'denyWriteAndDelete' | 'none', required — denySettings Mode that defines denied actions.
      - `excludedPrincipals` string[] — List of AAD principal IDs excluded from the lock. Up to 5 principals are permitted.
      - `excludedActions` string[] — List of role-based management operations that are excluded from the denySettings. Up to 200 actions are permitted. If the denySetting mode is set to 'denyWriteAndDelete', then the following actions are automatically appended to 'excludedActions': '*\/read' and 'Microsoft.Authorization/locks/delete'. If the denySetting mode is set to 'denyDelete', then the following actions are automatically appended to 'excludedActions': 'Microsoft.Authorization/locks/delete'. Duplicate actions will be removed.
      - `applyToChildScopes` boolean — DenySettings will be applied to child resource scopes of every managed resource with a deny assignment.
    - `deploymentScope` string — The Deployment stack deployment scope.
    - `description` string — The Deployment stack validation description.
    - `parameters` object — Deployment parameters.
    - `templateLink` DeploymentStacksTemplateLink — Entity representing the reference to the template.
      - `uri` string — The URI of the template to deploy. Use either the uri or id property, but not both.
      - `id` string — The resourceId of a Template Spec. Use either the id or uri property, but not both.
      - `relativePath` string — The relativePath property can be used to deploy a linked template at a location relative to the parent. If the parent template was linked with a TemplateSpec, this will reference an artifact in the TemplateSpec. If the parent was linked with a URI, the child deployment will be a combination of the parent and relativePath URIs.
      - `queryString` string — The query string (for example, a SAS token) to be used with the templateLink URI.
      - `contentVersion` string — If included, must match the ContentVersion in the template.
    - `validatedResources` ResourceReference[] — The array of resources that were validated.
      - `id` string — The ARM Resource ID of a resource managed by the deployment stack.
      - `extension` DeploymentExtension — Details about the usage of a deployment extension.
        - `name` string, required — The extension name.
        - `version` string, required — The extension version.
        - `configId` string — The configuration ID of the extension usage. It uniquely identifies a target the extension deploys to.
        - `config` DeploymentExtensionConfig — The configuration of a deployment extension. The keys of this object should align with the extension config schema.
      - `type` string — The resource type.
      - `identifiers` object — The extensible resource identifiers.
      - `apiVersion` string — The API version the resource was deployed with
    - `deploymentExtensions` DeploymentExtension[] — The deployment extensions.
      - `name` string, required — The extension name.
      - `version` string, required — The extension version.
      - `configId` string — The configuration ID of the extension usage. It uniquely identifies a target the extension deploys to.
      - `config` DeploymentExtensionConfig — The configuration of a deployment extension. The keys of this object should align with the extension config schema.
    - `validationLevel` 'Template' | 'Provider' | 'ProviderNoRbac' — The level of validation performed on the deployment.

## Other responses

- `202` — Resource operation accepted.
- `400` — Resource validation failed.
- `default` — An unexpected error response.

## Changes

- **2026-07-13** (2022-08-01-preview) `f7437878802d` — 1 info
  - endpoint added
- **2025-06-04** (2022-08-01-preview) `46e0d627c40f` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/azure/apis/resources-microsoft-resources-deploymentstacks/changes/subscriptions/:subscriptionId/providers/Microsoft.Resources/deploymentStacks/:deploymentStackName/validate/post.md)

---

[API](https://skmtc.dev/azure/apis/resources-microsoft-resources-deploymentstacks.md) · [All operations](https://skmtc.dev/azure/apis/resources-microsoft-resources-deploymentstacks/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/azure/resources-microsoft-resources-deploymentstacks/revisions/0817df7a4e67/schema)
