Sha256: 08e8aa98753374685d8e9f029c615122f1d41b663b19a4f081fb5249b45d0e7e

Contents?: true

Size: 422 Bytes

Versions: 1

Compression:

Stored size: 422 Bytes

Contents

module Xdelivery
  class Client

    attr_accessor :merchant_no, :access_key

    def initialize(merchant_no, access_key)
      self.merchant_no = merchant_no
      self.access_key = access_key
    end

    def create_orders!
      api = API::Orders.new(merchant_no, access_key)
      yield(api)
      api.create!
    end

    def ping!
      api = API::Ping.new(merchant_no, access_key)
      api.ping!
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
xdelivery-0.1.0 lib/xdelivery/client.rb