Twins - DigitalTwins Delete
Deletes a digital twin. All relationships referencing the digital twin must already be deleted. Status codes:
- 204 No Content
- 400 Bad Request
- InvalidArgument - The digital twin id is invalid.
- RelationshipsNotDeleted - The digital twin contains relationships.
- 404 Not Found
- DigitalTwinNotFound - The digital twin was not found.
- 412 Precondition Failed
- PreconditionFailed - The precondition check (If-Match or If-None-Match) failed.
DELETE https://digitaltwins-hostname/digitaltwins/{id}?api-version=2023-10-31
Name | In | Required | Type | Description |
---|---|---|---|---|
id
|
path | True |
string |
The id of the digital twin. The id is unique within the service and case sensitive. |
api-version
|
query | True |
string |
The requested API version. |
Name | Required | Type | Description |
---|---|---|---|
If-Match |
string |
Only perform the operation if the entity's etag matches one of the etags provided or * is provided. |
|
traceparent |
string |
Identifies the request in a distributed tracing system. |
|
tracestate |
string |
Provides vendor-specific trace identification information and is a companion to traceparent. |
Name | Type | Description |
---|---|---|
204 No Content |
Success |
|
Other Status Codes |
Default response. Headers x-ms-error-code: string |
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize?resource=0b07f429-9f4b-4714-9392-cc5e8e80c8b0
Sample request
DELETE https://digitaltwins-hostname/digitaltwins/myTwinId?api-version=2023-10-31
Sample response
Name | Description |
---|---|
Error |
Error definition. |
Error |
Error response. |
Inner |
A more specific error description than was provided by the containing error. |
Error definition.
Name | Type | Description |
---|---|---|
code |
string |
Service specific error code which serves as the substatus for the HTTP error code. |
details |
Error[] |
Internal error details. |
innererror |
An object containing more specific information than the current object about the error. |
|
message |
string |
A human-readable representation of the error. |
Error response.
Name | Type | Description |
---|---|---|
error |
The error details. |
A more specific error description than was provided by the containing error.
Name | Type | Description |
---|---|---|
code |
string |
A more specific error code than was provided by the containing error. |
innererror |
An object containing more specific information than the current object about the error. |