Class: AWSCDK::Cognito::UserPoolResourceServerProps

Inherits:
UserPoolResourceServerOptions
  • Object
show all
Defined in:
cognito/user_pool_resource_server_props.rb

Overview

Properties for the UserPoolResourceServer construct.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(identifier:, scopes: nil, user_pool_resource_server_name: nil, user_pool:) ⇒ UserPoolResourceServerProps

Returns a new instance of UserPoolResourceServerProps.

Parameters:



11
12
13
14
15
16
17
18
19
20
# File 'cognito/user_pool_resource_server_props.rb', line 11

def initialize(identifier:, scopes: nil, user_pool_resource_server_name: nil, user_pool:)
  @identifier = identifier
  Jsii::Type.check_type(@identifier, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "identifier")
  @scopes = scopes
  Jsii::Type.check_type(@scopes, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLmF3c19jb2duaXRvLlJlc291cmNlU2VydmVyU2NvcGUifSwia2luZCI6ImFycmF5In19")), "scopes") unless @scopes.nil?
  @user_pool_resource_server_name = user_pool_resource_server_name
  Jsii::Type.check_type(@user_pool_resource_server_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "userPoolResourceServerName") unless @user_pool_resource_server_name.nil?
  @user_pool = user_pool
  Jsii::Type.check_type(@user_pool, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19jb2duaXRvLklVc2VyUG9vbFJlZiJ9")), "userPool")
end

Instance Attribute Details

#identifierString (readonly)

A unique resource server identifier for the resource server.

Returns:

  • (String)


25
26
27
# File 'cognito/user_pool_resource_server_props.rb', line 25

def identifier
  @identifier
end

#scopesArray<AWSCDK::Cognito::ResourceServerScope>? (readonly)

Note:

Default: - No scopes will be added

Oauth scopes.

Returns:



30
31
32
# File 'cognito/user_pool_resource_server_props.rb', line 30

def scopes
  @scopes
end

#user_poolAWSCDK::Interfaces::AWSCognito::IUserPoolRef (readonly)

The user pool to add this resource server to.



39
40
41
# File 'cognito/user_pool_resource_server_props.rb', line 39

def user_pool
  @user_pool
end

#user_pool_resource_server_nameString? (readonly)

Note:

Default: - same as identifier

A friendly name for the resource server.

Returns:

  • (String, nil)


35
36
37
# File 'cognito/user_pool_resource_server_props.rb', line 35

def user_pool_resource_server_name
  @user_pool_resource_server_name
end

Class Method Details

.jsii_propertiesObject



41
42
43
44
45
46
47
48
# File 'cognito/user_pool_resource_server_props.rb', line 41

def self.jsii_properties
  {
    :identifier => "identifier",
    :scopes => "scopes",
    :user_pool_resource_server_name => "userPoolResourceServerName",
    :user_pool => "userPool",
  }
end

Instance Method Details

#to_jsiiObject



50
51
52
53
54
55
56
57
58
59
60
# File 'cognito/user_pool_resource_server_props.rb', line 50

def to_jsii
  result = {}
  result.merge!(super)
  result.merge!({
    "identifier" => @identifier,
    "scopes" => @scopes,
    "userPoolResourceServerName" => @user_pool_resource_server_name,
    "userPool" => @user_pool,
  })
  result.compact
end