GatewayTargetApiGatewayProps

class aws_cdk.aws_bedrock_agentcore_alpha.GatewayTargetApiGatewayProps(*, description=None, gateway_target_name=None, api_gateway_tool_configuration, gateway, rest_api, credential_provider_configurations=None, metadata_configuration=None, stage=None)

Bases: GatewayTargetCommonProps

(experimental) Properties for creating an API Gateway-based Gateway Target.

Parameters:
  • description (Optional[str]) – (experimental) Optional description for the gateway target The description can have up to 200 characters. Default: - No description

  • gateway_target_name (Optional[str]) – (experimental) The name of the gateway target The name must be unique within the gateway Pattern: ^([0-9a-zA-Z][-]?){1,100}$. Default: - auto generate

  • api_gateway_tool_configuration (Union[ApiGatewayToolConfiguration, Dict[str, Any]]) – (experimental) Tool configuration defining which operations to expose.

  • gateway (IGateway) – (experimental) The gateway this target belongs to [disable-awslint:prefer-ref-interface].

  • rest_api (IRestApi) – (experimental) The REST API to integrate with Must be in the same account and region as the gateway [disable-awslint:prefer-ref-interface].

  • credential_provider_configurations (Optional[Sequence[ICredentialProviderConfig]]) – (experimental) Credential providers for authentication API Gateway targets support IAM and API key authentication. Default: - Empty array (service handles IAM automatically)

  • metadata_configuration (Union[MetadataConfiguration, Dict[str, Any], None]) – (experimental) Metadata configuration for passing headers and query parameters Allows you to pass additional context through headers and query parameters. Default: - No metadata configuration

  • stage (Optional[str]) – (experimental) The stage name of the REST API. Default: - Uses the deployment stage from the RestApi (restApi.deploymentStage.stageName)

Stability:

experimental

ExampleMetadata:

fixture=default infused

Example:

gateway = agentcore.Gateway(self, "MyGateway",
    gateway_name="my-gateway"
)

api = apigateway.RestApi(self, "MyApi",
    rest_api_name="my-api"
)

# Create a gateway target using the static factory method
api_gateway_target = agentcore.GatewayTarget.for_api_gateway(self, "MyApiGatewayTarget",
    gateway_target_name="my-api-gateway-target",
    description="Target for API Gateway REST API integration",
    gateway=gateway,
    rest_api=api,
    api_gateway_tool_configuration=agentcore.ApiGatewayToolConfiguration(
        tool_filters=[agentcore.ApiGatewayToolFilter(
            filter_path="/pets/*",
            methods=[agentcore.ApiGatewayHttpMethod.GET, agentcore.ApiGatewayHttpMethod.POST]
        )
        ]
    ),
    metadata_configuration=agentcore.MetadataConfiguration(
        allowed_request_headers=["X-User-Id"],
        allowed_query_parameters=["limit"]
    )
)

Attributes

api_gateway_tool_configuration

(experimental) Tool configuration defining which operations to expose.

Stability:

experimental

credential_provider_configurations

(experimental) Credential providers for authentication API Gateway targets support IAM and API key authentication.

Default:
  • Empty array (service handles IAM automatically)

Stability:

experimental

description

(experimental) Optional description for the gateway target The description can have up to 200 characters.

Default:
  • No description

Stability:

experimental

gateway

prefer-ref-interface].

Stability:

experimental

Type:

(experimental) The gateway this target belongs to [disable-awslint

gateway_target_name

^([0-9a-zA-Z][-]?){1,100}$.

Default:
  • auto generate

Stability:

experimental

Type:

(experimental) The name of the gateway target The name must be unique within the gateway Pattern

metadata_configuration

(experimental) Metadata configuration for passing headers and query parameters Allows you to pass additional context through headers and query parameters.

Default:
  • No metadata configuration

Stability:

experimental

rest_api

prefer-ref-interface].

Stability:

experimental

Type:

(experimental) The REST API to integrate with Must be in the same account and region as the gateway [disable-awslint

stage

(experimental) The stage name of the REST API.

Default:
  • Uses the deployment stage from the RestApi (restApi.deploymentStage.stageName)

Stability:

experimental