flowcommerce 0.1.8 → 0.1.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7ae533a1a3b60f29dfe0404ea185af409a351a46
4
- data.tar.gz: 4a8bf7fbe84cb44b49540bff8d6acdd3b44ff7f1
3
+ metadata.gz: 6c2ddcddcbef8ec1b269a96498f537b5e82e4663
4
+ data.tar.gz: 9f736908c34f7ee33e4d6a5f40f8e23ddc37aea4
5
5
  SHA512:
6
- metadata.gz: 064657d5fe0e8b02819e7bdb44563e0b10db54f70626edb658e494721776235288d10f6b8fecea3a0540cc682b622e441386d6a55898acb49e11b45466fe88c5
7
- data.tar.gz: 807ce355135ebcba9f29d8414adf3955f1600e1faab6de8f3f55fc1563123b962fdb050e1bb798140af0c30e65420fc11623dd00c0862e2f71e85e958e2f1247
6
+ metadata.gz: ddf637c5e1bae0b4d86bf4774d258a02328d7d1c6be69977f24d8aaed700a991633e30681913030b1a31153fbd13ccba097edc1af1b2b5205a97c04610e8bb04
7
+ data.tar.gz: 36a42a866bfe11b4f0a05ecb60d558e96f900cd4cbde4271926585b5d43c16796ebea6bd20be47afcd37c75c7a10e3b54ac1839c64c4ec5caf3a898db735cadf
@@ -1,6 +1,6 @@
1
1
  # Generated by apidoc - http://www.apidoc.me
2
2
  # Service version: 0.1.77
3
- # apidoc:0.11.51 http://www.apidoc.me/flow/api/0.2.23/ruby_client
3
+ # apidoc:0.11.51 http://www.apidoc.me/flow/api/0.2.24/ruby_client
4
4
 
5
5
  require 'cgi'
6
6
  require 'net/http'
@@ -25,7 +25,7 @@ module Io
25
25
 
26
26
  BASE_URL = 'https://api.flow.io' unless defined?(Constants::BASE_URL)
27
27
  NAMESPACE = 'io.flow.v0' unless defined?(Constants::NAMESPACE)
28
- USER_AGENT = 'apidoc:0.11.51 http://www.apidoc.me/flow/api/0.2.23/ruby_client' unless defined?(Constants::USER_AGENT)
28
+ USER_AGENT = 'apidoc:0.11.51 http://www.apidoc.me/flow/api/0.2.24/ruby_client' unless defined?(Constants::USER_AGENT)
29
29
  VERSION = '0.1.77' unless defined?(Constants::VERSION)
30
30
  VERSION_MAJOR = 0 unless defined?(VERSION_MAJOR)
31
31
 
@@ -14977,16 +14977,17 @@ module Io
14977
14977
  # duties.
14978
14978
  class OrderEstimate
14979
14979
 
14980
- attr_reader :items, :destination, :deliveries, :prices, :total
14980
+ attr_reader :items, :destination, :deliveries, :prices, :total, :lines
14981
14981
 
14982
14982
  def initialize(incoming={})
14983
14983
  opts = HttpClient::Helper.symbolize_keys(incoming)
14984
14984
  HttpClient::Preconditions.require_keys(opts, [:items, :destination, :deliveries, :prices, :total], 'OrderEstimate')
14985
14985
  @items = HttpClient::Preconditions.assert_class('items', opts.delete(:items), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::LocalizedLineItem) ? x : ::Io::Flow::V0::Models::LocalizedLineItem.new(x)) }
14986
- @destination = (x = opts.delete(:destination); x.is_a?(::Io::Flow::V0::Models::Address) ? x : ::Io::Flow::V0::Models::Address.new(x))
14986
+ @destination = (x = opts.delete(:destination); x.is_a?(::Io::Flow::V0::Models::OrderAddress) ? x : ::Io::Flow::V0::Models::OrderAddress.new(x))
14987
14987
  @deliveries = HttpClient::Preconditions.assert_class('deliveries', opts.delete(:deliveries), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::DeliveryEstimate) ? x : ::Io::Flow::V0::Models::DeliveryEstimate.new(x)) }
14988
14988
  @prices = HttpClient::Preconditions.assert_class('prices', opts.delete(:prices), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::OrderPriceDetail) ? x : ::Io::Flow::V0::Models::OrderPriceDetail.new(x)) }
14989
14989
  @total = (x = opts.delete(:total); x.is_a?(::Io::Flow::V0::Models::LocalizedTotal) ? x : ::Io::Flow::V0::Models::LocalizedTotal.new(x))
14990
+ @lines = (x = opts.delete(:lines); x.nil? ? nil : HttpClient::Preconditions.assert_class('lines', x, Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::Line) ? x : ::Io::Flow::V0::Models::Line.new(x)) })
14990
14991
  end
14991
14992
 
14992
14993
  def to_json
@@ -15003,7 +15004,8 @@ module Io
15003
15004
  :destination => destination.to_hash,
15004
15005
  :deliveries => deliveries.map { |o| o.to_hash },
15005
15006
  :prices => prices.map { |o| o.to_hash },
15006
- :total => total.to_hash
15007
+ :total => total.to_hash,
15008
+ :lines => lines.nil? ? nil : lines.map { |o| o.to_hash }
15007
15009
  }
15008
15010
  end
15009
15011
 
@@ -15012,13 +15014,13 @@ module Io
15012
15014
  # Form to get a lightweight estimate of an order.
15013
15015
  class OrderEstimateForm
15014
15016
 
15015
- attr_reader :destination, :items
15017
+ attr_reader :items, :destination
15016
15018
 
15017
15019
  def initialize(incoming={})
15018
15020
  opts = HttpClient::Helper.symbolize_keys(incoming)
15019
- HttpClient::Preconditions.require_keys(opts, [:destination, :items], 'OrderEstimateForm')
15020
- @destination = (x = opts.delete(:destination); x.is_a?(::Io::Flow::V0::Models::Address) ? x : ::Io::Flow::V0::Models::Address.new(x))
15021
+ HttpClient::Preconditions.require_keys(opts, [:items], 'OrderEstimateForm')
15021
15022
  @items = HttpClient::Preconditions.assert_class('items', opts.delete(:items), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::LineItemForm) ? x : ::Io::Flow::V0::Models::LineItemForm.new(x)) }
15023
+ @destination = (x = opts.delete(:destination); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::OrderAddress) ? x : ::Io::Flow::V0::Models::OrderAddress.new(x)))
15022
15024
  end
15023
15025
 
15024
15026
  def to_json
@@ -15031,8 +15033,8 @@ module Io
15031
15033
 
15032
15034
  def to_hash
15033
15035
  {
15034
- :destination => destination.to_hash,
15035
- :items => items.map { |o| o.to_hash }
15036
+ :items => items.map { |o| o.to_hash },
15037
+ :destination => destination.nil? ? nil : destination.to_hash
15036
15038
  }
15037
15039
  end
15038
15040
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flowcommerce
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.8
4
+ version: 0.1.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Flow Commerce, Inc.