Class: AWSCDK::BedrockAgentCore::FromOauthIdentityOptions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::BedrockAgentCore::FromOauthIdentityOptions
- Defined in:
- bedrock_agent_core/from_oauth_identity_options.rb
Overview
OAuth scopes (and optional custom parameters) when binding an IOAuth2CredentialProvider to a gateway target.
Instance Attribute Summary collapse
-
#custom_parameters ⇒ Hash{String => String}?
readonly
Additional OAuth parameters for the provider.
-
#scopes ⇒ Array<String>
readonly
OAuth scopes the gateway should request for this target.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(scopes:, custom_parameters: nil) ⇒ FromOauthIdentityOptions
constructor
A new instance of FromOauthIdentityOptions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(scopes:, custom_parameters: nil) ⇒ FromOauthIdentityOptions
Returns a new instance of FromOauthIdentityOptions.
9 10 11 12 13 14 |
# File 'bedrock_agent_core/from_oauth_identity_options.rb', line 9 def initialize(scopes:, custom_parameters: nil) @scopes = scopes Jsii::Type.check_type(@scopes, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "scopes") @custom_parameters = custom_parameters Jsii::Type.check_type(@custom_parameters, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoibWFwIn19")), "customParameters") unless @custom_parameters.nil? end |
Instance Attribute Details
#custom_parameters ⇒ Hash{String => String}? (readonly)
Note:
Default: - none
Additional OAuth parameters for the provider.
24 25 26 |
# File 'bedrock_agent_core/from_oauth_identity_options.rb', line 24 def custom_parameters @custom_parameters end |
#scopes ⇒ Array<String> (readonly)
OAuth scopes the gateway should request for this target.
19 20 21 |
# File 'bedrock_agent_core/from_oauth_identity_options.rb', line 19 def scopes @scopes end |
Class Method Details
.jsii_properties ⇒ Object
26 27 28 29 30 31 |
# File 'bedrock_agent_core/from_oauth_identity_options.rb', line 26 def self.jsii_properties { :scopes => "scopes", :custom_parameters => "customParameters", } end |
Instance Method Details
#to_jsii ⇒ Object
33 34 35 36 37 38 39 40 |
# File 'bedrock_agent_core/from_oauth_identity_options.rb', line 33 def to_jsii result = {} result.merge!({ "scopes" => @scopes, "customParameters" => @custom_parameters, }) result.compact end |