Delete files¶
Delete temporary files, which cannot be recovered after deletion.
HTTP
POST $CLOUDSIGMA_API_BASE/connectors/file/delete
Before you call¶
Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region. Prepare personal access token, target workspace ID and temporary file ID that can access the target workspace. Make sure the file is no longer needed before deleting it.
Request body¶
Replace $CLOUDSIGMA_API_KEY, $WORKSPACE_ID, $CONN_FILE_ID in the example with actual values.
Shell
curl -X POST "$CLOUDSIGMA_API_BASE/connectors/file/delete" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
-H 'Content-Type: application/json' \
-d "{
\"conn_file_id\": \"$CONN_FILE_ID\"
}"
Field |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
The ID of the temporary file to be deleted. Cannot be empty. |
Successful response¶
JSON
{
"code": "OK",
"msg": "OK",
"data": null
}
Error response¶
JSON
{
"code": "ErrParamInvalid",
"msg": "invalid file identifier"
}
Field |
Type |
Description |
|---|---|---|
|
string |
error code. |
|
string |
Readable error message. |
Last updated on