DeleteResourcePolicyCommand

Deletes the resource policy set for the environment.

Example Syntax

Use a bare-bones client and the command you need to make an API call.

import { MigrationHubRefactorSpacesClient, DeleteResourcePolicyCommand } from "@aws-sdk/client-migration-hub-refactor-spaces"; // ES Modules import
// const { MigrationHubRefactorSpacesClient, DeleteResourcePolicyCommand } = require("@aws-sdk/client-migration-hub-refactor-spaces"); // CommonJS import
const client = new MigrationHubRefactorSpacesClient(config);
const input = { // DeleteResourcePolicyRequest
  Identifier: "STRING_VALUE", // required
};
const command = new DeleteResourcePolicyCommand(input);
const response = await client.send(command);
// {};

DeleteResourcePolicyCommand Input

Parameter
Type
Description
Identifier
Required
string | undefined

Amazon Resource Name (ARN) of the resource associated with the policy.

DeleteResourcePolicyCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.

Throws

Name
Fault
Details
AccessDeniedException
client

The user does not have sufficient access to perform this action.

InternalServerException
server

An unexpected error occurred while processing the request.

ResourceNotFoundException
client

The request references a resource that does not exist.

ThrottlingException
client

Request was denied because the request was throttled.

ValidationException
client

The input does not satisfy the constraints specified by an Amazon Web Service.

MigrationHubRefactorSpacesServiceException
Base exception class for all service exceptions from MigrationHubRefactorSpaces service.