Class: CollavreSlack::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/collavre_slack/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



5
6
7
8
9
10
11
# File 'lib/collavre_slack/configuration.rb', line 5

def initialize
  @client_id = ENV.fetch("SLACK_CLIENT_ID", "")
  @client_secret = ENV.fetch("SLACK_CLIENT_SECRET", "")
  @signing_secret = ENV.fetch("SLACK_SIGNING_SECRET", "")
  @redirect_uri = ENV.fetch("SLACK_REDIRECT_URI", "")
  @scopes = ENV.fetch("SLACK_SCOPES", "chat:write,channels:read,channels:history,groups:read,im:read,mpim:read,users:read,users:read.email,reactions:read,reactions:write")
end

Instance Attribute Details

#client_idObject

Returns the value of attribute client_id.



3
4
5
# File 'lib/collavre_slack/configuration.rb', line 3

def client_id
  @client_id
end

#client_secretObject

Returns the value of attribute client_secret.



3
4
5
# File 'lib/collavre_slack/configuration.rb', line 3

def client_secret
  @client_secret
end

#redirect_uriObject

Returns the value of attribute redirect_uri.



3
4
5
# File 'lib/collavre_slack/configuration.rb', line 3

def redirect_uri
  @redirect_uri
end

#scopesObject

Returns the value of attribute scopes.



3
4
5
# File 'lib/collavre_slack/configuration.rb', line 3

def scopes
  @scopes
end

#signing_secretObject

Returns the value of attribute signing_secret.



3
4
5
# File 'lib/collavre_slack/configuration.rb', line 3

def signing_secret
  @signing_secret
end