Skip to content
v2.278.0

CfnResourcePolicyProps Struct ​

Properties for defining a CfnResourcePolicy.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_aps as aps } from 'aws-cdk-lib';
const cfnResourcePolicyProps: aps.CfnResourcePolicyProps = {
  policyDocument: 'policyDocument',
  workspaceArn: 'workspaceArn',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_aps as aps

cfn_resource_policy_props = aps.CfnResourcePolicyProps(
    policy_document="policyDocument",
    workspace_arn="workspaceArn"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.aps.*;

CfnResourcePolicyProps cfnResourcePolicyProps = CfnResourcePolicyProps.builder()
        .policyDocument("policyDocument")
        .workspaceArn("workspaceArn")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.APS;

var cfnResourcePolicyProps = new CfnResourcePolicyProps {
    PolicyDocument = "policyDocument",
    WorkspaceArn = "workspaceArn"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

cfnResourcePolicyProps := &CfnResourcePolicyProps{
	PolicyDocument: jsii.String("policyDocument"),
	WorkspaceArn: jsii.String("workspaceArn"),
}

Properties ​

policyDocumentstringpolicy_documentstrpolicyDocumentStringPolicyDocumentstringPolicyDocument*string required #
The JSON to use as the Resource-based Policy.
workspaceArnstringworkspace_arnstrworkspaceArnStringWorkspaceArnstringWorkspaceArn*string required #
An ARN identifying a Workspace.