Class GatewayExceptionLevel
Exception levels for gateway.
Namespace: Amazon.CDK.AWS.BedrockAgentCore
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class GatewayExceptionLevel : DeputyBase
Syntax (vb)
Public Class GatewayExceptionLevel Inherits DeputyBase
Remarks
ExampleMetadata: fixture=default infused
Examples
// Create a KMS key for encryption
var encryptionKey = new Key(this, "GatewayEncryptionKey", new KeyProps {
EnableKeyRotation = true,
Description = "KMS key for gateway encryption"
});
// Create gateway with KMS encryption
var gateway = new Gateway(this, "MyGateway", new GatewayProps {
GatewayName = "my-encrypted-gateway",
Description = "Gateway with KMS encryption",
ProtocolConfiguration = new McpProtocolConfiguration(new McpConfiguration {
Instructions = "Use this gateway to connect to external MCP tools",
SearchType = McpGatewaySearchType.SEMANTIC,
SupportedVersions = new [] { MCPProtocolVersion.MCP_2025_03_26 }
}),
AuthorizerConfiguration = GatewayAuthorizer.UsingCustomJwt(new CustomJwtConfiguration {
DiscoveryUrl = "https://auth.example.com/.well-known/openid-configuration",
AllowedAudience = new [] { "my-app" },
AllowedClients = new [] { "my-client-id" },
AllowedScopes = new [] { "read", "write" }
}),
KmsKey = encryptionKey,
ExceptionLevel = GatewayExceptionLevel.DEBUG
});
Synopsis
Properties
| DEBUG | Debug mode for granular exception messages. |
| Value | The exception level string value. |
Methods
| Of(string) | Use a custom exception level not yet defined in this class. |
| ToString() | Returns the string value. |
Properties
DEBUG
Debug mode for granular exception messages.
public static GatewayExceptionLevel DEBUG { get; }
Property Value
Remarks
Allows the return of specific error messages related to the gateway target configuration to help you with debugging.
Value
The exception level string value.
public virtual string Value { get; }
Property Value
Remarks
ExampleMetadata: fixture=default infused
Methods
Of(string)
Use a custom exception level not yet defined in this class.
public static GatewayExceptionLevel Of(string value)
Parameters
- value string
The exception level string value.
Returns
Remarks
ExampleMetadata: fixture=default infused
ToString()
Returns the string value.
public override string ToString()
Returns
Remarks
ExampleMetadata: fixture=default infused