Module: ParichkiBg

Defined in:
lib/parichki_bg.rb,
lib/parichki_bg/railtie.rb,
lib/parichki_bg/version.rb,
lib/parichki_bg/request/base.rb,
lib/parichki_bg/request/query.rb,
lib/parichki_bg/request/transaction.rb

Defined Under Namespace

Modules: Request Classes: Railtie

Constant Summary collapse

VERSION =
"0.0.1"

Class Method Summary collapse

Class Method Details

.hmac(string) ⇒ Object



40
41
42
# File 'lib/parichki_bg.rb', line 40

def hmac(string)
  OpenSSL::HMAC.hexdigest("sha256", secret_key, string)      
end

.main_api_urlObject



36
37
38
# File 'lib/parichki_bg.rb', line 36

def main_api_url
  "https://api.dir.bg"
end

.secret_keyObject



24
25
26
# File 'lib/parichki_bg.rb', line 24

def secret_key
  @@secret_key
end

.secret_key=(secret_key) ⇒ Object



32
33
34
# File 'lib/parichki_bg.rb', line 32

def secret_key=(secret_key)
  @@secret_key = secret_key
end

.vendor_idObject



20
21
22
# File 'lib/parichki_bg.rb', line 20

def vendor_id
  @@vendor_id
end

.vendor_id=(vendor_id) ⇒ Object



28
29
30
# File 'lib/parichki_bg.rb', line 28

def vendor_id=(vendor_id)
  @@vendor_id = vendor_id
end