interface IPrompt
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.Bedrock.Alpha.IPrompt |
![]() | github.com/aws/aws-cdk-go/awsbedrockalpha/v2#IPrompt |
![]() | software.amazon.awscdk.services.bedrock.alpha.IPrompt |
![]() | aws_cdk.aws_bedrock_alpha.IPrompt |
![]() | @aws-cdk/aws-bedrock-alpha ยป IPrompt |
Implemented by
Prompt
Obtainable from
Prompt
.fromPromptAttributes()
Represents a Prompt, either created with CDK or imported.
Properties
Name | Type | Description |
---|---|---|
env | Resource | The environment this resource belongs to. |
node | Node | The tree node. |
prompt | string | The ARN of the prompt. |
prompt | string | The ID of the prompt. |
prompt | string | The version of the prompt. |
stack | Stack | The stack in which this resource is defined. |
kms | IKey | Optional KMS encryption key associated with this prompt. |
env
Type:
Resource
The environment this resource belongs to.
For resources that are created and managed by the CDK (generally, those created by creating new class instances like Role, Bucket, etc.), this is always the same as the environment of the stack they belong to; however, for imported resources (those obtained from static methods like fromRoleArn, fromBucketName, etc.), that might be different than the stack they were imported into.
node
Type:
Node
The tree node.
promptArn
Type:
string
The ARN of the prompt. Example
"arn:aws:bedrock:us-east-1:123456789012:prompt/PROMPT12345"
promptId
Type:
string
The ID of the prompt. Example
"PROMPT12345"
promptVersion
Type:
string
The version of the prompt.
stack
Type:
Stack
The stack in which this resource is defined.
kmsKey?
Type:
IKey
(optional)
Optional KMS encryption key associated with this prompt.
Methods
Name | Description |
---|---|
apply | Apply the given removal policy to this resource. |
grant | Grant the given identity permissions to get the prompt. |
applyRemovalPolicy(policy)
public applyRemovalPolicy(policy: RemovalPolicy): void
Parameters
- policy
Removal
Policy
Apply the given removal policy to this resource.
The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you've removed it from the CDK application or because you've made a change that requires the resource to be replaced.
The resource can be deleted (RemovalPolicy.DESTROY
), or left in your AWS
account for data recovery and cleanup later (RemovalPolicy.RETAIN
).
grantGet(grantee)
public grantGet(grantee: IGrantable): Grant
Parameters
- grantee
IGrantable
Returns
Grant the given identity permissions to get the prompt.