Class: WorkOS::TokenQuery

Inherits:
WorkOS::Types::BaseModel
  • Object
show all
Defined in:
lib/workos/sso/token_query.rb

Constant Summary collapse

HASH_ATTRS =
{
  client_id: :client_id,
  client_secret: :client_secret,
  code: :code,
  grant_type: :grant_type,
  subject_token: :subject_token,
  subject_token_type: :subject_token_type,
  organization_id: :organization_id
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ TokenQuery

Returns a new instance of TokenQuery.



26
27
28
29
30
31
32
33
34
35
# File 'lib/workos/sso/token_query.rb', line 26

def initialize(json)
  hash = self.class.normalize(json)
  @client_id = hash[:client_id]
  @client_secret = hash[:client_secret]
  @code = hash[:code]
  @grant_type = hash[:grant_type]
  @subject_token = hash[:subject_token]
  @subject_token_type = hash[:subject_token_type]
  @organization_id = hash[:organization_id]
end

Instance Attribute Details

#client_idObject

Returns the value of attribute client_id.



17
18
19
# File 'lib/workos/sso/token_query.rb', line 17

def client_id
  @client_id
end

#client_secretObject

Returns the value of attribute client_secret.



17
18
19
# File 'lib/workos/sso/token_query.rb', line 17

def client_secret
  @client_secret
end

#codeObject

Returns the value of attribute code.



17
18
19
# File 'lib/workos/sso/token_query.rb', line 17

def code
  @code
end

#grant_typeObject

Returns the value of attribute grant_type.



17
18
19
# File 'lib/workos/sso/token_query.rb', line 17

def grant_type
  @grant_type
end

#organization_idObject

Returns the value of attribute organization_id.



17
18
19
# File 'lib/workos/sso/token_query.rb', line 17

def organization_id
  @organization_id
end

#subject_tokenObject

Returns the value of attribute subject_token.



17
18
19
# File 'lib/workos/sso/token_query.rb', line 17

def subject_token
  @subject_token
end

#subject_token_typeObject

Returns the value of attribute subject_token_type.



17
18
19
# File 'lib/workos/sso/token_query.rb', line 17

def subject_token_type
  @subject_token_type
end