Class: Google::Apis::IntegrationsV1::GoogleCloudIntegrationsV1alphaOAuth2ResourceOwnerCredentials

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

Overview

For resource owner credentials grant, the client will ask the user for their authorization credentials (ususally a username and password) and send a POST request to the authorization server. The authorization server will respond with a JSON object containing the access token.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudIntegrationsV1alphaOAuth2ResourceOwnerCredentials

Returns a new instance of GoogleCloudIntegrationsV1alphaOAuth2ResourceOwnerCredentials.



9623
9624
9625
# File 'lib/google/apis/integrations_v1/classes.rb', line 9623

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

Instance Attribute Details

#access_tokenGoogle::Apis::IntegrationsV1::GoogleCloudIntegrationsV1alphaAccessToken

The access token represents the authorization of a specific application to access specific parts of a user’s data. Corresponds to the JSON property accessToken



9579
9580
9581
# File 'lib/google/apis/integrations_v1/classes.rb', line 9579

def access_token
  @access_token
end

#client_idString

The client's ID. Corresponds to the JSON property clientId

Returns:

  • (String)


9584
9585
9586
# File 'lib/google/apis/integrations_v1/classes.rb', line 9584

def client_id
  @client_id
end

#client_secretString

The client's secret. Corresponds to the JSON property clientSecret

Returns:

  • (String)


9589
9590
9591
# File 'lib/google/apis/integrations_v1/classes.rb', line 9589

def client_secret
  @client_secret
end

#passwordString

The user's password. Corresponds to the JSON property password

Returns:

  • (String)


9594
9595
9596
# File 'lib/google/apis/integrations_v1/classes.rb', line 9594

def password
  @password
end

#request_typeString

Represent how to pass parameters to fetch access token Corresponds to the JSON property requestType

Returns:

  • (String)


9599
9600
9601
# File 'lib/google/apis/integrations_v1/classes.rb', line 9599

def request_type
  @request_type
end

#scopeString

A space-delimited list of requested scope permissions. Corresponds to the JSON property scope

Returns:

  • (String)


9604
9605
9606
# File 'lib/google/apis/integrations_v1/classes.rb', line 9604

def scope
  @scope
end

#token_endpointString

The token endpoint is used by the client to obtain an access token by presenting its authorization grant or refresh token. Corresponds to the JSON property tokenEndpoint

Returns:

  • (String)


9610
9611
9612
# File 'lib/google/apis/integrations_v1/classes.rb', line 9610

def token_endpoint
  @token_endpoint
end

#token_paramsGoogle::Apis::IntegrationsV1::GoogleCloudIntegrationsV1alphaParameterMap

A generic multi-map that holds key value pairs. They keys and values can be of any type, unless specified. Corresponds to the JSON property tokenParams



9616
9617
9618
# File 'lib/google/apis/integrations_v1/classes.rb', line 9616

def token_params
  @token_params
end

#usernameString

The user's username. Corresponds to the JSON property username

Returns:

  • (String)


9621
9622
9623
# File 'lib/google/apis/integrations_v1/classes.rb', line 9621

def username
  @username
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



9628
9629
9630
9631
9632
9633
9634
9635
9636
9637
9638
# File 'lib/google/apis/integrations_v1/classes.rb', line 9628

def update!(**args)
  @access_token = args[:access_token] if args.key?(:access_token)
  @client_id = args[:client_id] if args.key?(:client_id)
  @client_secret = args[:client_secret] if args.key?(:client_secret)
  @password = args[:password] if args.key?(:password)
  @request_type = args[:request_type] if args.key?(:request_type)
  @scope = args[:scope] if args.key?(:scope)
  @token_endpoint = args[:token_endpoint] if args.key?(:token_endpoint)
  @token_params = args[:token_params] if args.key?(:token_params)
  @username = args[:username] if args.key?(:username)
end