Destroying a Salesforce Tenant Secret
Use the post /v1/cckm/sfdc/keys/{id}/destroy
API to destroy an ARCHIVED
(backup) Salesforce tenant secret. The status of the tenant secret changes from ARCHIVED
to DESTROYED
.
Only a tenant secret with the status ARCHIVED
can be destroyed. An ACTIVE
tenant secret cannot be destroyed.
Syntax
curl -k '<IP>/api/v1/cckm/sfdc/keys/{id}/destroy' -X POST -H 'Authorization: Bearer AUTHTOKEN' --compressed
Here, {id}
represents the resource ID of the Salesforce tenant secret.
Request Parameter
Parameter | Type | Description |
---|---|---|
AUTHTOKEN | string | Authorization token. |
Example Request
curl -k 'https://127.0.0.1/api/v1/cckm/sfdc/keys/eca1ff8e-8609-48a2-becd-40e9d13300dc' -X POST -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiI0MmFmZDExNy02YzllLTRhNGUtOTAwYS1lYjlhNDNjYWE5ZDIiLCJzdWIiOiJsb2NhbHwzMTI5ODdkMS0wOWNiLTQxZTEtOThmNy1jZjRhNzgwNTZiMTMiLCJpc3MiOiJreWxvIiwiYWNjIjoia3lsbyIsInByZWZlcnJlZF91c2VybmFtZSI6ImFkbWluIiwiY3VzdCI6eyJkb21haW5faWQiOiIwMDAwMDAwMC0wMDAwLTAwMDAtMDAwMC0wMDAwMDAwMDAwMDAiLCJncm91cHMiOlsiYWRtaW4iXSwic2lkIjoiNDVmOWE3NWUtMzI1NC00NWJkLWE0NzYtOWU2NWUyNjdmNGVkIiwiem9uZV9pZCI6IjAwMDAwMDAwLTAwMDAtMDAwMC0wMDAwLTAwMDAwMDAwMDAwMCJ9LCJqd3RpZCI6IjdiYzNkOWM4LWRiYTQtNDVmMy05YWNiLWI3NGM2MzQyYzYyMCIsImlhdCI6MTYxNDc1MTg1MSwiZXhwIjoxNjE0NzUyMTUxfQ.ahdxfM7-WA4u7sotHy6qelc9MkoZytst7oZWsvE7Cr0' --compressed
Example Response
{
"id": "eca1ff8e-8609-48a2-becd-40e9d13300dc",
"uri": "kylo:kylo:cckm:Tenant_Secret:eca1ff8e-8609-48a2-becd-40e9d13300dc",
"account": "kylo:kylo:admin:accounts:kylo",
"createdAt": "2021-07-23T05:29:26.988554Z",
"updatedAt": "2021-07-23T05:29:26.987104Z",
"cloud_name": "sfdc",
"name": "sfdc-secret-1",
"organization_id": "00DB000000040bIMAQ",
"error_msg": "",
"sfdc_params": {
"salesforce_id": "02GB0000000HYswMAG",
"created_by_id": "005B00000021BO4IAM",
"last_modified_date": "2021-07-23T05:29:26.000+0000",
"last_modified_by_id": "005B00000021BO4IAM",
"system_modstamp": "2021-07-23T05:29:26.000+0000",
"secret_value_hash": "UNKNOWM=",
"secret_value": "CgMyMzISEKnfsHQqWBk/IND/PXoSoFkaMHdChRNCLK42IWmHXUeDWrA30jI5mWqKoamniRMTtlsIERPUIAWybZG+cNRU6E+Weg==",
"version": 2191,
"status": "DESTROYED",
"source": "HSM",
"type": "Data"
},
"backup_key_id": "f7a4397b885c4cb5a0ace78aa676952b31df08a10eb543f985f6982db56b4502",
"backup_key_name": "00DB000000040bIMAQ:Data:2191:02GB0000000HYswMAG",
"backup_key_tier": "local"
}
The sample output displays that the status of the Salesforce tenant secret with the ID eca1ff8e-8609-48a2-becd-40e9d13300dc
becomes DESTROYED
.
Response Codes
Response Code | Description |
---|---|
2xx | Success |
4xx | Client errors |
5xx | Server errors |
Refer to HTTP status codes for details.