Class: AWSCDK::BedrockAgentCore::OAuthConfiguration
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::BedrockAgentCore::OAuthConfiguration
- Defined in:
- bedrock_agent_core/o_auth_configuration.rb
Overview
OAuth configuration.
Instance Attribute Summary collapse
-
#custom_parameters ⇒ Hash{String => String}?
readonly
Custom parameters for the OAuth flow.
-
#provider_arn ⇒ String
readonly
The OAuth credential provider ARN.
-
#scopes ⇒ Array<String>
readonly
The OAuth scopes for the credential provider.
-
#secret_arn ⇒ String
readonly
The ARN of the Secrets Manager secret containing OAuth credentials (client ID and secret).
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(provider_arn:, scopes:, secret_arn:, custom_parameters: nil) ⇒ OAuthConfiguration
constructor
A new instance of OAuthConfiguration.
- #to_jsii ⇒ Object
Constructor Details
#initialize(provider_arn:, scopes:, secret_arn:, custom_parameters: nil) ⇒ OAuthConfiguration
Returns a new instance of OAuthConfiguration.
11 12 13 14 15 16 17 18 19 20 |
# File 'bedrock_agent_core/o_auth_configuration.rb', line 11 def initialize(provider_arn:, scopes:, secret_arn:, custom_parameters: nil) @provider_arn = provider_arn Jsii::Type.check_type(@provider_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "providerArn") @scopes = scopes Jsii::Type.check_type(@scopes, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "scopes") @secret_arn = secret_arn Jsii::Type.check_type(@secret_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "secretArn") @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)
Default: - No custom parameters
Custom parameters for the OAuth flow.
50 51 52 |
# File 'bedrock_agent_core/o_auth_configuration.rb', line 50 def custom_parameters @custom_parameters end |
#provider_arn ⇒ String (readonly)
The OAuth credential provider ARN.
This is returned when creating the OAuth credential provider via Console or API. Format: arn:aws:bedrock-agentcore:region:account:token-vault/id/oauth2credentialprovider/name Required: Yes
29 30 31 |
# File 'bedrock_agent_core/o_auth_configuration.rb', line 29 def provider_arn @provider_arn end |
#scopes ⇒ Array<String> (readonly)
The OAuth scopes for the credential provider. These scopes define the level of access requested from the OAuth provider.
Array Members: Minimum number of 0 items. Maximum number of 100 items. Length Constraints: Minimum length of 1. Maximum length of 64. Required: Yes
37 38 39 |
# File 'bedrock_agent_core/o_auth_configuration.rb', line 37 def scopes @scopes end |
#secret_arn ⇒ String (readonly)
The ARN of the Secrets Manager secret containing OAuth credentials (client ID and secret).
This is returned when creating the OAuth credential provider via Console or API. Format: arn:aws:secretsmanager:region:account:secret:name Required: Yes
45 46 47 |
# File 'bedrock_agent_core/o_auth_configuration.rb', line 45 def secret_arn @secret_arn end |
Class Method Details
.jsii_properties ⇒ Object
52 53 54 55 56 57 58 59 |
# File 'bedrock_agent_core/o_auth_configuration.rb', line 52 def self.jsii_properties { :provider_arn => "providerArn", :scopes => "scopes", :secret_arn => "secretArn", :custom_parameters => "customParameters", } end |
Instance Method Details
#to_jsii ⇒ Object
61 62 63 64 65 66 67 68 69 70 |
# File 'bedrock_agent_core/o_auth_configuration.rb', line 61 def to_jsii result = {} result.merge!({ "providerArn" => @provider_arn, "scopes" => @scopes, "secretArn" => @secret_arn, "customParameters" => @custom_parameters, }) result.compact end |