Move one or more configurations to the trash

Open in ChatGPT Open in ChatGPT to ask questions about this page
Open in Claude Open in Claude to ask questions about this page
Copy as MarkdownCopy this page as markdown to use with AI assistants
View as Markdown Open this page as markdown in a new tab

Moves one or more configurations to the trash. Trashed configurations can be restored or permanently deleted later.

Request URL

https://{server-hostname}:8383/dcapi/configuration/moveToTrash

Scope

Configurations.DELETECopied!

Header

Authorization: d92d4xxxxxxxxxxxxx15f52

Request Parameters

- Request Headers

Content-TypestringMandatory
application/moveConfigToTrash.v1+jsonapplication/moveConfigToTrash.v1+jsonCopied!
AcceptstringMandatory
application/moveConfigToTrashStatus.v1+jsonapplication/moveConfigToTrashStatus.v1+jsonCopied!

- Request Body

application/json
JSON object
Hide Sub-Attributes
collectionIdsarrayOptional

Array of active configuration collection IDs to move to trash. Each ID must reference a valid active configuration belonging to the requesting customer. Fetch from Get Configurations View . Maximum 500 entries.

Sample Request

Curl
Java
Python
Deluge
PowerShell
Copied!
curl --request POST \
  --url https://appdomain/dcapi/configuration/moveToTrash \
  --header 'Accept: application/moveConfigToTrashStatus.v1+json' \
  --header 'Authorization:  d92d4xxxxxxxxxxxxx15f52' \
  --header 'Content-Type: application/moveConfigToTrash.v1+json' \
  --data '{"collectionIds":[12345,12346,12347]}'
Show full

Sample Request Body

Move multiple collections to trash

Copied!
  {
    "collectionIds": [
      12345,
      12346,
      12347
    ]
  }
                
Show full

Response Parameters

- HTTP code 200

Response Body - application/json
JSON object
Hide Sub-Attributes
statusstring

Result of the operation — Success when all collections were moved to trash

collectionNamearray

List of configuration display names that were moved to trash

- HTTP code 401

Response Body - application/json
JSON object
Hide Sub-Attributes
errorCodelong

Unauthorized error code returned when authentication credentials are missing, expired, or invalid (authentication=required)

errorMsgstring

Authentication failure reason

- HTTP code 500

Response Body - application/json
JSON object
Hide Sub-Attributes
error_codestring

50001: internal server error code indicating unexpected exception in the service layer

error_descriptionstring

Internal server error. Contact administrator.

Possible Response Codes

200HTTP code
401HTTP code
500HTTP code

Sample Response: HTTP 200

All collections successfully moved to trash

Copied!
  {
    "status": "Success",
    "collectionName": [
      "Firewall_Policy_Win11",
      "Chrome_Settings_v2"
    ]
  }
                
Show full

Sample Response: HTTP 401

User lacks write role, scope, or customer does not own the collection

Copied!
  {
    "error_description": "Access denied - You are not allowed to access the requested resource.",
    "error_code": "UAC_UNAUTHORIZED"
  }
                
Show full

Sample Response: HTTP 500

Unexpected failure during the trash operation

Copied!
  {
    "error_description": "Internal server error. Contact administrator.",
    "error_code": "50001"
  }
                
Show full

Duration: 1 minute | Threshold: 30 | Lock period: 5 minutes

Duration - Time window for the threshold.
Threshold - Number of API calls allowed within the specified duration.
Lock Period - Wait time before consecutive API requests.