CfnSessionProps Struct
Properties for defining a CfnSession.
| Source | |
|---|---|
| Type last changed |
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_bedrock as bedrock } from 'aws-cdk-lib';
const cfnSessionProps: bedrock.CfnSessionProps = {
encryptionKeyArn: 'encryptionKeyArn',
sessionMetadata: {
sessionMetadataKey: 'sessionMetadata',
},
tags: [{
key: 'key',
value: 'value',
}],
};
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_bedrock as bedrock
cfn_session_props = bedrock.CfnSessionProps(
encryption_key_arn="encryptionKeyArn",
session_metadata={
"session_metadata_key": "sessionMetadata"
},
tags=[CfnTag(
key="key",
value="value"
)]
)
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.bedrock.*;
CfnSessionProps cfnSessionProps = CfnSessionProps.builder()
.encryptionKeyArn("encryptionKeyArn")
.sessionMetadata(Map.of(
"sessionMetadataKey", "sessionMetadata"))
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.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.Bedrock;
var cfnSessionProps = new CfnSessionProps {
EncryptionKeyArn = "encryptionKeyArn",
SessionMetadata = new Dictionary<string, string> {
{ "sessionMetadataKey", "sessionMetadata" }
},
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
};
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"
cfnSessionProps := &CfnSessionProps{
EncryptionKeyArn: jsii.String("encryptionKeyArn"),
SessionMetadata: map[string]*string{
"sessionMetadataKey": jsii.String("sessionMetadata"),
},
Tags: []CfnTag{
&CfnTag{
Key: jsii.String("key"),
Value: jsii.String("value"),
},
},
}
Properties
encryptionKeyArnoptionalstringencryption_key_arnoptionalstrencryptionKeyArnoptionalStringEncryptionKeyArnoptionalstringEncryptionKeyArnoptional*string #The Amazon Resource Name (ARN) of the KMS key to use to encrypt the session data.
sessionMetadataoptionalIResolvable | { [key: string]: string }session_metadataoptionaltyping.Union[IResolvable, typing.Mapping[str, str]]sessionMetadataoptionalIResolvableSessionMetadataoptionalIResolvableSessionMetadataoptionalinterface{} #A map of key-value pairs containing attributes to be persisted across the session.