Module: MagicAdmin::Config

Defined in:
lib/magic-admin/config.rb

Class Method Summary collapse

Class Method Details

.api_baseObject

Description:

Method provides you api base url

Returns:

api base url


61
62
63
# File 'lib/magic-admin/config.rb', line 61

def self.api_base
  "https://api.magic.link"
end

.languageObject

Description:

Method provides you sdk programming language

Returns:

sdk programming language


21
22
23
# File 'lib/magic-admin/config.rb', line 21

def self.language
  "ruby"
end

.language_versionObject

Description:

Method provides you sdk programming language version

Returns:

sdk programming language version


30
31
32
# File 'lib/magic-admin/config.rb', line 30

def self.language_version
  RUBY_VERSION
end

.nbf_grace_periodObject

Description:

Method provides you nbf grace period

Returns:

nbf grace period


70
71
72
# File 'lib/magic-admin/config.rb', line 70

def self.nbf_grace_period
  300
end

.platformObject

Description:

Method provides you platform information

Returns:

user platform information


12
13
14
# File 'lib/magic-admin/config.rb', line 12

def self.platform
  RUBY_PLATFORM
end

.publisherObject

Description:

Method provides you sdk publisher name

Returns:

sdk publisher name


52
53
54
# File 'lib/magic-admin/config.rb', line 52

def self.publisher
  "MagicLabs"
end

.user_nameObject

Description:

Method provides you installation machine user_name

Returns:

installation machine user_name


39
40
41
42
43
44
45
# File 'lib/magic-admin/config.rb', line 39

def self.user_name
   = Etc.getlogin

  return "None" if .nil?

  Etc.getpwnam().gecos.split(/,/).first
end