Sha256: 69d9c967bb0c6eea1bdc7f99d007078d0b5045e034182f064c4edc39e2ce6fc6

Contents?: true

Size: 268 Bytes

Versions: 5

Compression:

Stored size: 268 Bytes

Contents

require "base64"

module Moip2
  module Auth
    class Basic
      def initialize(token, secret)
        @token = token
        @secret = secret
      end

      def header
        %(Basic #{Base64.strict_encode64("#{@token}:#{@secret}")})
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
moip2-1.3.1 lib/moip2/auth/basic.rb
moip2-1.2.1 lib/moip2/auth/basic.rb
moip2-1.2.0 lib/moip2/auth/basic.rb
moip2-1.1.0 lib/moip2/auth/basic.rb
moip2-1.0.0 lib/moip2/auth/basic.rb