Resource

sealed class Resource

Represents a resource within the AgentCore Policy system. Resources are the targets of policy evaluation. Currently, only AgentCore Gateways are supported as resources for policy enforcement.

Inheritors

Types

Link copied to clipboard
data class Arn(val value: String) : Resource

The Amazon Resource Name (ARN) of the resource. This globally unique identifier specifies the exact resource that policies will be evaluated against for access control decisions.

Link copied to clipboard

Functions

Link copied to clipboard
fun asArn(): String

Casts this Resource as a Arn and retrieves its kotlin.String value. Throws an exception if the Resource is not a Arn.

Link copied to clipboard

Casts this Resource as a Arn and retrieves its kotlin.String value. Returns null if the Resource is not a Arn.