Class: Google::Apis::IamV1::OauthClientCredential

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/iam_v1/classes.rb,
lib/google/apis/iam_v1/representations.rb,
lib/google/apis/iam_v1/representations.rb

Overview

Represents an OauthClientCredential. Used to authenticate an OauthClient while accessing Google Cloud resources on behalf of a user by using OAuth 2.0 Protocol.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ OauthClientCredential

Returns a new instance of OauthClientCredential.



1765
1766
1767
# File 'lib/google/apis/iam_v1/classes.rb', line 1765

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#client_secretString

Output only. The system-generated OAuth client secret. The client secret must be stored securely. If the client secret is leaked, you must delete and re- create the client credential. To learn more, see OAuth client and credential security risks and mitigations Corresponds to the JSON property clientSecret

Returns:

  • (String)


1743
1744
1745
# File 'lib/google/apis/iam_v1/classes.rb', line 1743

def client_secret
  @client_secret
end

#disabledBoolean Also known as: disabled?

Optional. Whether the OauthClientCredential is disabled. You cannot use a disabled OauthClientCredential. Corresponds to the JSON property disabled

Returns:

  • (Boolean)


1749
1750
1751
# File 'lib/google/apis/iam_v1/classes.rb', line 1749

def disabled
  @disabled
end

#display_nameString

Optional. A user-specified display name of the OauthClientCredential. Cannot exceed 32 characters. Corresponds to the JSON property displayName

Returns:

  • (String)


1756
1757
1758
# File 'lib/google/apis/iam_v1/classes.rb', line 1756

def display_name
  @display_name
end

#nameString

Immutable. Identifier. The resource name of the OauthClientCredential. Format: projects/project/locations/location/oauthClients/oauth_client/ credentials/credential` Corresponds to the JSON propertyname`

Returns:

  • (String)


1763
1764
1765
# File 'lib/google/apis/iam_v1/classes.rb', line 1763

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1770
1771
1772
1773
1774
1775
# File 'lib/google/apis/iam_v1/classes.rb', line 1770

def update!(**args)
  @client_secret = args[:client_secret] if args.key?(:client_secret)
  @disabled = args[:disabled] if args.key?(:disabled)
  @display_name = args[:display_name] if args.key?(:display_name)
  @name = args[:name] if args.key?(:name)
end