This topic describes how to delete a specified unit resource specification by using the API.
Request
Request parameters
| Parameter | Required | Type | Description |
|---|---|---|---|
| name | Yes | String | The name of the unit resource specification to be deleted. |
Request example
DELETE 10.10.10.1:2886/api/v1/unit/config/s1
Response
| Parameter | Type | Description |
|---|---|---|
| successful | bool | Indicates whether the request is successful. |
| timestamp | time.Time | The timestamp when the server processed the request. |
| duration | int | The time (in milliseconds) that the server took to process the request. |
| status | int | The HTTP status code. |
| traceId | string | The trace ID of the request. |
| error | ApiError | The error information generated during the request. It contains the following fields:
|
Example
Request example
DELETE 10.10.10.1:2886/api/v1/unit/config/s1
Response example
{
"successful": true,
"timestamp": "2024-10-14T16:14:51.852430189+08:00",
"duration": 14,
"status": 200,
"traceId": "f44c8455e0a8b1a1"
}
References
You can also call the API by using the SDK.
For more information about how to call the API by using obshell-sdk-python, see Delete a resource specification.
For more information about how to call the API by using obshell-sdk-go, see Delete a resource specification.