Class: FactPulse::Helpers::ChorusProCredentials

Inherits:
Object
  • Object
show all
Defined in:
lib/factpulse/helpers/client.rb

Overview

Credentials Chorus Pro pour le mode Zero-Trust. Ces credentials sont passés dans chaque requête et ne sont jamais stockés côté serveur.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(piste_client_id:, piste_client_secret:, chorus_pro_login:, chorus_pro_password:, sandbox: true) ⇒ ChorusProCredentials

Returns a new instance of ChorusProCredentials.



10
11
12
13
# File 'lib/factpulse/helpers/client.rb', line 10

def initialize(piste_client_id:, piste_client_secret:, chorus_pro_login:, chorus_pro_password:, sandbox: true)
  @piste_client_id, @piste_client_secret = piste_client_id, piste_client_secret
  , @chorus_pro_password, @sandbox = , chorus_pro_password, sandbox
end

Instance Attribute Details

#chorus_pro_loginObject (readonly)

Returns the value of attribute chorus_pro_login.



9
10
11
# File 'lib/factpulse/helpers/client.rb', line 9

def 
  
end

#chorus_pro_passwordObject (readonly)

Returns the value of attribute chorus_pro_password.



9
10
11
# File 'lib/factpulse/helpers/client.rb', line 9

def chorus_pro_password
  @chorus_pro_password
end

#piste_client_idObject (readonly)

Returns the value of attribute piste_client_id.



9
10
11
# File 'lib/factpulse/helpers/client.rb', line 9

def piste_client_id
  @piste_client_id
end

#piste_client_secretObject (readonly)

Returns the value of attribute piste_client_secret.



9
10
11
# File 'lib/factpulse/helpers/client.rb', line 9

def piste_client_secret
  @piste_client_secret
end

#sandboxObject (readonly)

Returns the value of attribute sandbox.



9
10
11
# File 'lib/factpulse/helpers/client.rb', line 9

def sandbox
  @sandbox
end

Instance Method Details

#to_hObject



14
15
16
17
# File 'lib/factpulse/helpers/client.rb', line 14

def to_h
  { 'piste_client_id' => @piste_client_id, 'piste_client_secret' => @piste_client_secret,
    'chorus_pro_login' => , 'chorus_pro_password' => @chorus_pro_password, 'sandbox' => @sandbox }
end