AWS bedrock-agentcore documentation change
Summary
Added built-in Smithy models section, removed testing instructions, and clarified restrictions on custom Smithy models
Security assessment
While the change restricts custom Smithy models to AWS services, this appears to be a feature limitation rather than a security fix. No vulnerabilities or security controls are explicitly addressed.
Diff
diff --git a/bedrock-agentcore/latest/devguide/gateway-building-smithy-targets.md b/bedrock-agentcore/latest/devguide/gateway-building-smithy-targets.md index 9def4e1f7..b80023d99 100644 --- a//bedrock-agentcore/latest/devguide/gateway-building-smithy-targets.md +++ b//bedrock-agentcore/latest/devguide/gateway-building-smithy-targets.md @@ -5 +5 @@ -Understanding Smithy Model TargetsRequired PermissionsSmithy Model TypesSmithy Feature SupportCreating a Smithy targetUpdating a Smithy Model TargetTesting Your Smithy Model TargetAdvanced Smithy Model Target Configurations +Built-in Smithy ModelsUnderstanding Smithy Model TargetsRequired PermissionsSmithy Model TypesSmithy Feature SupportCreating a Smithy targetUpdating a Smithy Model TargetAdvanced Smithy Model Target Configurations @@ -12,0 +13,29 @@ Smithy is a language for defining services and SDKs that works well with Gateway +## Built-in Smithy Models + +Gateway provides built-in Smithy models for popular AWS services. When you create a Smithy target without specifying a model, it defaults to the DynamoDB model: + + + # Create a Smithy target with default DynamoDB model + smithy_target = agentcore_client.create_gateway_target( + gatewayIdentifier=gateway["gatewayId"], + name="DynamoDBTarget", + targetConfiguration={"mcp": {"smithyModel": {}}}, # Empty - uses default DynamoDB model + credentialProviderConfigurations=[{"credentialProviderType": "GATEWAY_IAM_ROLE"}] + ) + + +You can find Smithy API models for hundreds of AWS services in the [AWS API Models repository](https://github.com/aws/api-models-aws). Popular services include: + + * DynamoDB (default) + + * S3 + + * Lambda + + * EC2 + + * RDS + + + + @@ -77 +106 @@ JSON -AgentCore Gateway supports built-in AWS service models. Custom Smithy models are not currently supported. +AgentCore Gateway supports built-in AWS service models only. Smithy models are restricted to AWS services and custom Smithy models for non-AWS services are not supported. @@ -399,43 +427,0 @@ You can update an existing Smithy model target using the `UpdateGatewayTarget` A -## Testing Your Smithy Model Target - -After adding a Smithy model target to your Gateway, you can test it by making requests to the Gateway endpoint: - - * **Obtain an access token** from your identity provider (as described in the "Set Up Gateway" guide) - - * **Make a request to the Gateway endpoint** : - - curl -sS -X POST https://{gatewayId}.gateway.{region}.amazonaws.com/mcp \ - --header 'Content-Type: application/json' \ - --header "Authorization: Bearer {access_token}" \ - --data '{ - "jsonrpc": "2.0", - "id": 1, - "method": "tools/call", - "params": { - "name": "DynamoDB_GetItem", - "arguments": { - "TableName": "YourTableName", - "Key": { "id": {"S": "item-id-1"} } - } - } - }' - - - * **Verify the response** from the service: - - { - "jsonrpc": "2.0", - "id": 1, - "result": { - "Item": { - "id": {"S": "item-id-1"}, - "name": {"S": "Example Item"}, - "description": {"S": "This is an example item"} - } - } - } - - - - -