Sha256: 1006bad344fe14fee91a106379f4ea0d3c87892c225860131a21b04e49526ce7
Contents?: true
Size: 520 Bytes
Versions: 6
Compression:
Stored size: 520 Bytes
Contents
module PaxfulClient class BaseRequest include APIClientBase::Request attribute :key, String attribute :secret, String attribute :page, Integer, default: 1 private def body nonce = Time.now.to_i apiseal = OpenSSL::HMAC.hexdigest( "SHA256", secret, "apikey=#{key}&nonce=#{nonce}&page=#{page}", ) [ "apikey=#{key}", "nonce=#{nonce}", "page=#{page}", "apiseal=#{apiseal}", ].join("&") end end end
Version data entries
6 entries across 6 versions & 1 rubygems