Analysis: AWS Delete
Analysis: AWS Delete
#340780
Description
The /analysis/cloud/aws/<analysisId> resource can be used to delete the audit and all associated scheduler entries of the cloud analysis specified by <analysisId>.
- The single-day and 60-day historical audits are removed, if they exist.
- The audit and all associated scheduler entries, are deleted, if they exist.
When executing the delete operation in an environment observe the following:
- When deleting an audit for an environment associated with a single account, the operation proceeds as outlined above.
- When deleting an audit for a payer account with multiple linked accounts, If Densify determines that there is a many-to-one relationship for this account, then the delete request fails. This type of multi-account connection can only be created through the Cloud Connection Wizard and must be deleted through the Cloud Connection Wizard.
During a delete operation, any attempt to access other associated endpoints related to the specified <analysisId> (i.e. GET, PUT, POST) will trigger a "400 Bad Request" error response.
While the delete operation is in progress, you can check the status (using the /analysis/cloud/aws/<analysisId>/status resource) or wait for the results to be published to an optional webhook URI.
Collected data is saved for the defined retention period and the environment and associated analysis structure are saved in case you want to generate reports on the historical data or restart data collection. Since the environment and analyses are not deleted, a GET call for the specified <analysisId> will always succeed regardless of whether the associated connection has been deleted.
If you use a GET call to list available environment and analyses, for which the audits have been deleted, they are still listed. You can reestablish the audit without have to re-create the analysis. You will still see the data in the Densify Console.
Resource
/analysis/cloud/aws/analysisId
Supported Operations
Table: AWS Supported Operations
Operation |
HTTP Method |
Input |
Output |
Description |
DELETE /analysis/cloud/aws/<analysisId> |
Request Body Parameter:
|
This resource operation is used to delete audit and audit-related items for the specified analysis. |
Table: AWS Analysis Path Parameters
Parameter Name |
Type |
Description |
string |
The unique, referenced ID of the AWS analysis. |
Table: AWS Analysis Request Body Parameters
Parameter Name |
Type |
Description |
(optional) |
|
The webhook definition to an external application. Status can be sent to the webhook-defined application when the delete operation is complete. See Parameters for details of each parameter in the webhook definition. |
Table: AWS Analysis Response Schema
Element |
Type |
Filter/Sort |
Description |
string |
|
The informational message returned with the status response. |
|
number |
|
The HTTP response code of the request. Possible status values include:
|
Examples
Example: Deleting AWS Data Collection
The following example shows you how to delete the AWS audit and send the results to a WebHook.
Example: Deleting an AWS Audit that is in Progress
The following example shows you the response if you attempt to delete an audit that is in progress.
Example: Deleting an AWS Payer Account Audit
The following example shows you the response if you attempt to delete an audit that has more than one account associated with the specified analysis ID.
If Densify determines that there is a many-to-one relationship for this connection, then the delete request fails. This type of multi-subscription connection can only be created through the Cloud Connection Wizard and must be deleted through the Cloud Connection Wizard.

Request:
DELETE /analysis/cloud/aws/aws/fd9234a7b43c-7e4b-4084-8f46-b898c2c2
Response:
{
"message": "Account dfc04848-3848-44c0-b85a-02311951de36 was created via UI and subscriptions [cc377154-9605-4cb0-8b41-1b39e1c4ac0f,3d4ba999-cbd8-40b8-9998-574be6824a97] are incompatible with API use; please delete via UI",
"status": 500
}