Class: AWSCDK::BedrockAgentCore::AddOpenAPITargetOptions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::BedrockAgentCore::AddOpenAPITargetOptions
- Defined in:
- bedrock_agent_core/add_open_api_target_options.rb
Overview
Options for adding an OpenAPI target to a gateway.
Instance Attribute Summary collapse
-
#api_schema ⇒ AWSCDK::BedrockAgentCore::APISchema
readonly
The OpenAPI schema defining the API.
-
#credential_provider_configurations ⇒ Array<AWSCDK::BedrockAgentCore::ICredentialProviderConfig>?
readonly
Credential providers for outbound authentication (OpenAPI targets use API Key or OAuth, not IAM).
-
#description ⇒ String?
readonly
Optional description for the gateway target.
-
#gateway_target_name ⇒ String?
readonly
The name of the gateway target Valid characters are a-z, A-Z, 0-9, _ (underscore) and - (hyphen).
-
#validate_open_api_schema ⇒ Boolean?
readonly
Whether to validate the OpenAPI schema or not Note: Validation is only performed for inline and asset-based schema and during CDK synthesis.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(api_schema:, credential_provider_configurations: nil, description: nil, gateway_target_name: nil, validate_open_api_schema: nil) ⇒ AddOpenAPITargetOptions
constructor
A new instance of AddOpenAPITargetOptions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(api_schema:, credential_provider_configurations: nil, description: nil, gateway_target_name: nil, validate_open_api_schema: nil) ⇒ AddOpenAPITargetOptions
Returns a new instance of AddOpenAPITargetOptions.
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 12 def initialize(api_schema:, credential_provider_configurations: nil, description: nil, gateway_target_name: nil, validate_open_api_schema: nil) @api_schema = api_schema Jsii::Type.check_type(@api_schema, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYmVkcm9ja2FnZW50Y29yZS5BcGlTY2hlbWEifQ==")), "apiSchema") @credential_provider_configurations = credential_provider_configurations Jsii::Type.check_type(@credential_provider_configurations, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLmF3c19iZWRyb2NrYWdlbnRjb3JlLklDcmVkZW50aWFsUHJvdmlkZXJDb25maWcifSwia2luZCI6ImFycmF5In19")), "credentialProviderConfigurations") unless @credential_provider_configurations.nil? @description = description Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil? @gateway_target_name = gateway_target_name Jsii::Type.check_type(@gateway_target_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "gatewayTargetName") unless @gateway_target_name.nil? @validate_open_api_schema = validate_open_api_schema Jsii::Type.check_type(@validate_open_api_schema, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "validateOpenApiSchema") unless @validate_open_api_schema.nil? end |
Instance Attribute Details
#api_schema ⇒ AWSCDK::BedrockAgentCore::APISchema (readonly)
The OpenAPI schema defining the API.
28 29 30 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 28 def api_schema @api_schema end |
#credential_provider_configurations ⇒ Array<AWSCDK::BedrockAgentCore::ICredentialProviderConfig>? (readonly)
Default: - none (no credential configuration on the target; supply providers for secured backends)
Credential providers for outbound authentication (OpenAPI targets use API Key or OAuth, not IAM).
33 34 35 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 33 def credential_provider_configurations @credential_provider_configurations end |
#description ⇒ String? (readonly)
Default: - No description
Optional description for the gateway target.
38 39 40 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 38 def description @description end |
#gateway_target_name ⇒ String? (readonly)
Default: - auto generate
The name of the gateway target Valid characters are a-z, A-Z, 0-9, _ (underscore) and - (hyphen).
43 44 45 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 43 def gateway_target_name @gateway_target_name end |
#validate_open_api_schema ⇒ Boolean? (readonly)
Default: true
Whether to validate the OpenAPI schema or not Note: Validation is only performed for inline and asset-based schema and during CDK synthesis.
S3 schemas cannot be validated at synthesis time.
50 51 52 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 50 def validate_open_api_schema @validate_open_api_schema end |
Class Method Details
.jsii_properties ⇒ Object
52 53 54 55 56 57 58 59 60 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 52 def self.jsii_properties { :api_schema => "apiSchema", :credential_provider_configurations => "credentialProviderConfigurations", :description => "description", :gateway_target_name => "gatewayTargetName", :validate_open_api_schema => "validateOpenApiSchema", } end |
Instance Method Details
#to_jsii ⇒ Object
62 63 64 65 66 67 68 69 70 71 72 |
# File 'bedrock_agent_core/add_open_api_target_options.rb', line 62 def to_jsii result = {} result.merge!({ "apiSchema" => @api_schema, "credentialProviderConfigurations" => @credential_provider_configurations, "description" => @description, "gatewayTargetName" => @gateway_target_name, "validateOpenApiSchema" => @validate_open_api_schema, }) result.compact end |