Delen via


Resource Groups - Delete

Hiermee verwijdert u een resourcegroep.
Wanneer u een resourcegroep verwijdert, worden alle bijbehorende resources ook verwijderd. Als u een resourcegroep verwijdert, worden alle sjabloonimplementaties en momenteel opgeslagen bewerkingen verwijderd.

DELETE https://management.azure.com/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}?api-version=2021-04-01
DELETE https://management.azure.com/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}?forceDeletionTypes={forceDeletionTypes}&api-version=2021-04-01

URI-parameters

Name In Vereist Type Description
resourceGroupName
path True

string

minLength: 1
maxLength: 90
pattern: ^[-\w\._\(\)]+$

De naam van de resourcegroep die u wilt verwijderen. De naam is niet hoofdlettergevoelig.

subscriptionId
path True

string

De microsoft Azure-abonnements-id.

api-version
query True

string

De API-versie die voor deze bewerking moet worden gebruikt.

forceDeletionTypes
query

string

De resourcetypen die u wilt afdwingen verwijderen. Momenteel wordt alleen het volgende ondersteund: forceDeletionTypes=Microsoft.Compute/virtualMachines,Microsoft.Compute/virtualMachineScaleSets

Antwoorden

Name Type Description
200 OK

OK

202 Accepted

Geaccepteerd

Other Status Codes

CloudError

Foutreactie waarin wordt beschreven waarom de bewerking is mislukt.

Beveiliging

azure_auth

Azure Active Directory OAuth2-stroom

Type: oauth2
Stroom: implicit
Autorisatie-URL: https://login.microsoftonline.com/common/oauth2/authorize

Bereiken

Name Description
user_impersonation Uw gebruikersaccount imiteren

Voorbeelden

Force delete all the Virtual Machines and Virtual Machine Scale Sets in a resource group
Force delete all the Virtual Machines in a resource group

Force delete all the Virtual Machines and Virtual Machine Scale Sets in a resource group

Voorbeeldaanvraag

DELETE https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/my-resource-group?forceDeletionTypes=Microsoft.Compute/virtualMachines,Microsoft.Compute/virtualMachineScaleSets&api-version=2021-04-01

Voorbeeldrespons

Force delete all the Virtual Machines in a resource group

Voorbeeldaanvraag

DELETE https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/my-resource-group?forceDeletionTypes=Microsoft.Compute/virtualMachines&api-version=2021-04-01

Voorbeeldrespons

Definities

Name Description
CloudError

Een foutbericht voor een aanvraag voor resourcebeheer.

ErrorAdditionalInfo

Aanvullende informatie over de resourcebeheerfout.

ErrorResponse

Foutreactie

CloudError

Een foutbericht voor een aanvraag voor resourcebeheer.

Name Type Description
error

ErrorResponse

Foutreactie
Veelvoorkomende foutreactie voor alle Azure Resource Manager-API's om foutdetails te retourneren voor mislukte bewerkingen. (Dit volgt ook de OData-foutreactie-indeling.)

ErrorAdditionalInfo

Aanvullende informatie over de resourcebeheerfout.

Name Type Description
info

object

De aanvullende informatie.

type

string

Het extra informatietype.

ErrorResponse

Foutreactie

Name Type Description
additionalInfo

ErrorAdditionalInfo[]

De fout bevat aanvullende informatie.

code

string

De foutcode.

details

ErrorResponse[]

De foutdetails.

message

string

Het foutbericht.

target

string

Het foutdoel.