BedrockAgentCoreControl / Client / get_agent_runtime

get_agent_runtime

BedrockAgentCoreControl.Client.get_agent_runtime(**kwargs)

Gets an Amazon Bedrock AgentCore Runtime.

See also: AWS API Documentation

Request Syntax

response = client.get_agent_runtime(
    agentRuntimeId='string',
    agentRuntimeVersion='string'
)
Parameters:
  • agentRuntimeId (string) –

    [REQUIRED]

    The unique identifier of the AgentCore Runtime to retrieve.

  • agentRuntimeVersion (string) – The version of the AgentCore Runtime to retrieve.

Return type:

dict

Returns:

Response Syntax

{
    'agentRuntimeArn': 'string',
    'agentRuntimeName': 'string',
    'agentRuntimeId': 'string',
    'agentRuntimeVersion': 'string',
    'createdAt': datetime(2015, 1, 1),
    'lastUpdatedAt': datetime(2015, 1, 1),
    'roleArn': 'string',
    'networkConfiguration': {
        'networkMode': 'PUBLIC'|'VPC',
        'networkModeConfig': {
            'securityGroups': [
                'string',
            ],
            'subnets': [
                'string',
            ],
            'requireServiceS3Endpoint': True|False
        }
    },
    'status': 'CREATING'|'CREATE_FAILED'|'UPDATING'|'UPDATE_FAILED'|'READY'|'DELETING',
    'lifecycleConfiguration': {
        'idleRuntimeSessionTimeout': 123,
        'maxLifetime': 123
    },
    'failureReason': 'string',
    'description': 'string',
    'workloadIdentityDetails': {
        'workloadIdentityArn': 'string'
    },
    'agentRuntimeArtifact': {
        'containerConfiguration': {
            'containerUri': 'string'
        },
        'codeConfiguration': {
            'code': {
                's3': {
                    'bucket': 'string',
                    'prefix': 'string',
                    'versionId': 'string'
                }
            },
            'runtime': 'PYTHON_3_10'|'PYTHON_3_11'|'PYTHON_3_12'|'PYTHON_3_13'|'PYTHON_3_14'|'NODE_22',
            'entryPoint': [
                'string',
            ]
        }
    },
    'protocolConfiguration': {
        'serverProtocol': 'MCP'|'HTTP'|'A2A'|'AGUI'
    },
    'environmentVariables': {
        'string': 'string'
    },
    'authorizerConfiguration': {
        'customJWTAuthorizer': {
            'discoveryUrl': 'string',
            'allowedAudience': [
                'string',
            ],
            'allowedClients': [
                'string',
            ],
            'allowedScopes': [
                'string',
            ],
            'customClaims': [
                {
                    'inboundTokenClaimName': 'string',
                    'inboundTokenClaimValueType': 'STRING'|'STRING_ARRAY',
                    'authorizingClaimMatchValue': {
                        'claimMatchValue': {
                            'matchValueString': 'string',
                            'matchValueStringList': [
                                'string',
                            ]
                        },
                        'claimMatchOperator': 'EQUALS'|'CONTAINS'|'CONTAINS_ANY'
                    }
                },
            ],
            'privateEndpoint': {
                'selfManagedLatticeResource': {
                    'resourceConfigurationIdentifier': 'string'
                },
                'managedVpcResource': {
                    'vpcIdentifier': 'string',
                    'subnetIds': [
                        'string',
                    ],
                    'endpointIpAddressType': 'IPV4'|'IPV6',
                    'securityGroupIds': [
                        'string',
                    ],
                    'tags': {
                        'string': 'string'
                    },
                    'routingDomain': 'string'
                }
            },
            'privateEndpointOverrides': [
                {
                    'domain': 'string',
                    'privateEndpoint': {
                        'selfManagedLatticeResource': {
                            'resourceConfigurationIdentifier': 'string'
                        },
                        'managedVpcResource': {
                            'vpcIdentifier': 'string',
                            'subnetIds': [
                                'string',
                            ],
                            'endpointIpAddressType': 'IPV4'|'IPV6',
                            'securityGroupIds': [
                                'string',
                            ],
                            'tags': {
                                'string': 'string'
                            },
                            'routingDomain': 'string'
                        }
                    }
                },
            ]
        }
    },
    'requestHeaderConfiguration': {
        'requestHeaderAllowlist': [
            'string',
        ]
    },
    'metadataConfiguration': {
        'requireMMDSV2': True|False
    },
    'filesystemConfigurations': [
        {
            'sessionStorage': {
                'mountPath': 'string'
            },
            's3FilesAccessPoint': {
                'accessPointArn': 'string',
                'mountPath': 'string'
            },
            'efsAccessPoint': {
                'accessPointArn': 'string',
                'mountPath': 'string'
            }
        },
    ]
}

Response Structure

  • (dict) –

    • agentRuntimeArn (string) –

      The Amazon Resource Name (ARN) of the AgentCore Runtime.

    • agentRuntimeName (string) –

      The name of the AgentCore Runtime.

    • agentRuntimeId (string) –

      The unique identifier of the AgentCore Runtime.

    • agentRuntimeVersion (string) –

      The version of the AgentCore Runtime.

    • createdAt (datetime) –

      The timestamp when the AgentCore Runtime was created.

    • lastUpdatedAt (datetime) –

      The timestamp when the AgentCore Runtime was last updated.

    • roleArn (string) –

      The IAM role ARN that provides permissions for the AgentCore Runtime.

    • networkConfiguration (dict) –

      The network configuration for the AgentCore Runtime.

      • networkMode (string) –

        The network mode for the AgentCore Runtime.

      • networkModeConfig (dict) –

        The network mode configuration for the AgentCore Runtime.

        • securityGroups (list) –

          The security groups associated with the VPC configuration.

          • (string) –

        • subnets (list) –

          The subnets associated with the VPC configuration.

          • (string) –

        • requireServiceS3Endpoint (boolean) –

          Note

          This field applies only to Agent Runtimes. It is not applicable to Browsers or Code Interpreters.

          Controls whether a service-managed Amazon S3 gateway endpoint is provisioned in the VPC network topology for the agent runtime. This gateway is used by Amazon Bedrock AgentCore Runtime to download code and container images during agent startup.

          Starting May 5, 2026, Amazon Bedrock AgentCore Runtime is gradually rolling out a change to how network isolation is configured for VPC mode agents. Agent runtimes created on or after this rollout will no longer include the service-managed Amazon S3 gateway. Instead, all network access, including to Amazon S3, is governed exclusively by your VPC configuration. This field cannot be set on agent runtimes created after the rollout. Passing this field in an UpdateAgentRuntime request for these agent runtimes returns a ValidationException.

          Agent runtimes created before the rollout are not affected and continue to operate with the service-managed Amazon S3 gateway. To enforce full VPC network isolation on these existing agent runtimes, set this field to false via the UpdateAgentRuntime API. Before opting out, ensure your VPC provides the Amazon S3 access required for agent startup. If this field is not specified or is set to true, the service-managed Amazon S3 gateway remains provisioned.

          This field is only supported in the UpdateAgentRuntime API for pre-rollout agent runtimes. Passing this field in a CreateAgentRuntime request returns a ValidationException.

    • status (string) –

      The current status of the AgentCore Runtime.

    • lifecycleConfiguration (dict) –

      The life cycle configuration for the AgentCore Runtime.

      • idleRuntimeSessionTimeout (integer) –

        Timeout in seconds for idle runtime sessions. When a session remains idle for this duration, it will be automatically terminated. Default: 900 seconds (15 minutes).

      • maxLifetime (integer) –

        Maximum lifetime for the instance in seconds. Once reached, instances will be automatically terminated and replaced. Default: 28800 seconds (8 hours).

    • failureReason (string) –

      The reason for failure if the AgentCore Runtime is in a failed state.

    • description (string) –

      The description of the AgentCore Runtime.

    • workloadIdentityDetails (dict) –

      The workload identity details for the AgentCore Runtime.

      • workloadIdentityArn (string) –

        The ARN associated with the workload identity.

    • agentRuntimeArtifact (dict) –

      The artifact of the AgentCore Runtime.

      Note

      This is a Tagged Union structure. Only one of the following top level keys will be set: containerConfiguration, codeConfiguration. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

      'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
      
      • containerConfiguration (dict) –

        The container configuration for the agent artifact.

        • containerUri (string) –

          The ECR URI of the container.

      • codeConfiguration (dict) –

        The code configuration for the agent runtime artifact, including the source code location and execution settings.

        • code (dict) –

          The source code location and configuration details.

          Note

          This is a Tagged Union structure. Only one of the following top level keys will be set: s3. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

          'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
          
          • s3 (dict) –

            The Amazon Amazon S3 object that contains the source code for the agent runtime.

            • bucket (string) –

              The name of the Amazon S3 bucket. This bucket contains the stored data.

            • prefix (string) –

              The prefix for objects in the Amazon S3 bucket. This prefix is added to the object keys to organize the data.

            • versionId (string) –

              The version ID of the Amazon Amazon S3 object. If not specified, the latest version of the object is used.

        • runtime (string) –

          The runtime environment for executing the agent code. Specify the programming language and version to use for the agent runtime. For valid values, see the list of supported runtimes.

        • entryPoint (list) –

          The entry point for the code execution, specifying the function or method that should be invoked when the code runs.

          • (string) –

    • protocolConfiguration (dict) –

      The protocol configuration for an agent runtime. This structure defines how the agent runtime communicates with clients.

      • serverProtocol (string) –

        The server protocol for the agent runtime. This field specifies which protocol the agent runtime uses to communicate with clients.

    • environmentVariables (dict) –

      Environment variables set in the AgentCore Runtime environment.

      • (string) –

        • (string) –

    • authorizerConfiguration (dict) –

      The authorizer configuration for the AgentCore Runtime.

      Note

      This is a Tagged Union structure. Only one of the following top level keys will be set: customJWTAuthorizer. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

      'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
      
      • customJWTAuthorizer (dict) –

        The inbound JWT-based authorization, specifying how incoming requests should be authenticated.

        • discoveryUrl (string) –

          This URL is used to fetch OpenID Connect configuration or authorization server metadata for validating incoming tokens.

        • allowedAudience (list) –

          Represents individual audience values that are validated in the incoming JWT token validation process.

          • (string) –

        • allowedClients (list) –

          Represents individual client IDs that are validated in the incoming JWT token validation process.

          • (string) –

        • allowedScopes (list) –

          An array of scopes that are allowed to access the token.

          • (string) –

        • customClaims (list) –

          An array of objects that define a custom claim validation name, value, and operation

          • (dict) –

            Defines the name of a custom claim field and rules for finding matches to authenticate its value.

            • inboundTokenClaimName (string) –

              The name of the custom claim field to check.

            • inboundTokenClaimValueType (string) –

              The data type of the claim value to check for.

              • Use STRING if you want to find an exact match to a string you define.

              • Use STRING_ARRAY if you want to fnd a match to at least one value in an array you define.

            • authorizingClaimMatchValue (dict) –

              Defines the value or values to match for and the relationship of the match.

              • claimMatchValue (dict) –

                The value or values to match for.

                Note

                This is a Tagged Union structure. Only one of the following top level keys will be set: matchValueString, matchValueStringList. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

                'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
                
                • matchValueString (string) –

                  The string value to match for.

                • matchValueStringList (list) –

                  An array of strings to check for a match.

                  • (string) –

              • claimMatchOperator (string) –

                Defines the relationship between the claim field value and the value or values you’re matching for.

        • privateEndpoint (dict) –

          The private endpoint configuration for a gateway target. Defines how the gateway connects to private resources in your VPC.

          Note

          This is a Tagged Union structure. Only one of the following top level keys will be set: selfManagedLatticeResource, managedVpcResource. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

          'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
          
          • selfManagedLatticeResource (dict) –

            Configuration for connecting to a private resource using a self-managed VPC Lattice resource configuration.

            Note

            This is a Tagged Union structure. Only one of the following top level keys will be set: resourceConfigurationIdentifier. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

            'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
            
            • resourceConfigurationIdentifier (string) –

              The ARN or ID of the VPC Lattice resource configuration.

          • managedVpcResource (dict) –

            Configuration for connecting to a private resource using a managed VPC Lattice resource. The gateway creates and manages the VPC Lattice resources on your behalf.

            • vpcIdentifier (string) –

              The ID of the VPC that contains your private resource.

            • subnetIds (list) –

              The subnet IDs within the VPC where the VPC Lattice resource gateway is placed.

              • (string) –

            • endpointIpAddressType (string) –

              The IP address type for the resource configuration endpoint.

            • securityGroupIds (list) –

              The security group IDs to associate with the VPC Lattice resource gateway. If not specified, the default security group for the VPC is used.

              • (string) –

            • tags (dict) –

              Tags to apply to the managed VPC Lattice resource gateway.

              • (string) –

                • (string) –

            • routingDomain (string) –

              An intermediate domain to use as the resource configuration endpoint instead of the actual target domain. Use this when you want to route traffic through an intermediate component such as a VPC endpoint or internal load balancer. For more information, see xref:lattice-vpc-egress-routing-domain[Route traffic through an intermediate domain].

        • privateEndpointOverrides (list) –

          The private endpoint overrides for the custom JWT authorizer configuration.

          • (dict) –

            A mapping of a specific domain to a private endpoint for secure connectivity through a VPC Lattice resource configuration.

            • domain (string) –

              The domain to override with a private endpoint.

            • privateEndpoint (dict) –

              The private endpoint configuration for the specified domain.

              Note

              This is a Tagged Union structure. Only one of the following top level keys will be set: selfManagedLatticeResource, managedVpcResource. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

              'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
              
              • selfManagedLatticeResource (dict) –

                Configuration for connecting to a private resource using a self-managed VPC Lattice resource configuration.

                Note

                This is a Tagged Union structure. Only one of the following top level keys will be set: resourceConfigurationIdentifier. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

                'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
                
                • resourceConfigurationIdentifier (string) –

                  The ARN or ID of the VPC Lattice resource configuration.

              • managedVpcResource (dict) –

                Configuration for connecting to a private resource using a managed VPC Lattice resource. The gateway creates and manages the VPC Lattice resources on your behalf.

                • vpcIdentifier (string) –

                  The ID of the VPC that contains your private resource.

                • subnetIds (list) –

                  The subnet IDs within the VPC where the VPC Lattice resource gateway is placed.

                  • (string) –

                • endpointIpAddressType (string) –

                  The IP address type for the resource configuration endpoint.

                • securityGroupIds (list) –

                  The security group IDs to associate with the VPC Lattice resource gateway. If not specified, the default security group for the VPC is used.

                  • (string) –

                • tags (dict) –

                  Tags to apply to the managed VPC Lattice resource gateway.

                  • (string) –

                    • (string) –

                • routingDomain (string) –

                  An intermediate domain to use as the resource configuration endpoint instead of the actual target domain. Use this when you want to route traffic through an intermediate component such as a VPC endpoint or internal load balancer. For more information, see xref:lattice-vpc-egress-routing-domain[Route traffic through an intermediate domain].

    • requestHeaderConfiguration (dict) –

      Configuration for HTTP request headers that will be passed through to the runtime.

      Note

      This is a Tagged Union structure. Only one of the following top level keys will be set: requestHeaderAllowlist. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

      'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
      
      • requestHeaderAllowlist (list) –

        A list of HTTP request headers that are allowed to be passed through to the runtime.

        • (string) –

    • metadataConfiguration (dict) –

      Configuration for microVM Metadata Service (MMDS) settings for the AgentCore Runtime.

      • requireMMDSV2 (boolean) –

        Enables MMDSv2 (microVM Metadata Service Version 2) requirement for the agent runtime. When set to true, the runtime microVM will only accept MMDSv2 requests.

    • filesystemConfigurations (list) –

      The filesystem configurations mounted into the AgentCore Runtime.

      • (dict) –

        Configuration for a filesystem that can be mounted into the AgentCore Runtime.

        Note

        This is a Tagged Union structure. Only one of the following top level keys will be set: sessionStorage, s3FilesAccessPoint, efsAccessPoint. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

        'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
        
        • sessionStorage (dict) –

          Configuration for session storage. Session storage provides persistent storage that is preserved across AgentCore Runtime session invocations.

          • mountPath (string) –

            The mount path for the session storage filesystem inside the AgentCore Runtime. The path must be under /mnt with exactly one subdirectory level (for example, /mnt/data).

        • s3FilesAccessPoint (dict) –

          Configuration for an Amazon S3 Files access point to mount into the AgentCore Runtime.

          • accessPointArn (string) –

            The ARN of the S3 Files access point to mount into the AgentCore Runtime.

          • mountPath (string) –

            The mount path for the S3 Files access point inside the AgentCore Runtime. The path must be under /mnt with exactly one subdirectory level (for example, /mnt/data).

        • efsAccessPoint (dict) –

          Configuration for an Amazon EFS access point to mount into the AgentCore Runtime.

          • accessPointArn (string) –

            The ARN of the EFS access point to mount into the AgentCore Runtime.

          • mountPath (string) –

            The mount path for the EFS access point inside the AgentCore Runtime. The path must be under /mnt with exactly one subdirectory level (for example, /mnt/data).

Exceptions

  • BedrockAgentCoreControl.Client.exceptions.AccessDeniedException

  • BedrockAgentCoreControl.Client.exceptions.ValidationException

  • BedrockAgentCoreControl.Client.exceptions.ResourceNotFoundException

  • BedrockAgentCoreControl.Client.exceptions.ThrottlingException

  • BedrockAgentCoreControl.Client.exceptions.InternalServerException