@BATRA, SUDEEP Thanks for reaching out to Microsoft Q&A, apologize for any inconvenience caused on this.
We don't have any default cmdlet to delete the resources that were created using arm template or through bicep template.
When deploying your resources, you specify that the deployment is either an incremental update or a complete update. The difference between these two modes is how Resource Manager handles existing resources in the resource group that aren't in the template.
For both modes, Resource Manager tries to create all resources specified in the template. If the resource already exists in the resource group and its settings are unchanged, no operation is taken for that resource. If you change the property values for a resource, the resource is updated with those new values. If you try to update the location or type of an existing resource, the deployment fails with an error. Instead, deploy a new resource with the location or type that you need.
- The default mode is incremental.
- Complete mode: In complete mode, Resource Manager deletes resources that exist in the resource group but aren't specified in the template.
Note : Always use the what-if operation before deploying a template in complete mode. What-if shows you which resources will be created, deleted, or modified. Use what-if to avoid unintentionally deleting resources.
- If your deployment got failed and if you want to roll back to last successful recent deployment you can use the parameter
-RollbackToLastDeployment
in the az deployment group create cmdlet which has couple of limitations as well refer to this documentation.
Feel free to reach back to me if you have any further questions on this.