flowcommerce 0.2.12 → 0.2.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/flow_commerce/flow_api_v0_client.rb +656 -27
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5e209e01320fef03cfe22e4855bc420ae533e67a
|
4
|
+
data.tar.gz: 45de4ca93686ff823612e4773dee781e83221ed5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 11ef494dd9aa6a1f7e1a431f275bc76e86e167f64721e49ac9f627533ed47463bf29c72c887cb0e7cb8c3fcc4af709222f51cf3f84367016fadef2f7eac34b81
|
7
|
+
data.tar.gz: 70cafeea55dc71d6256f6943be0475d0224c124f6cdbd9def42ac2249be4320502578ff384c1211bd64388c77ce882d301250583d0127276a79609eff349062a
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# Generated by apidoc - http://www.apidoc.me
|
2
2
|
# Service version: 0.3.17
|
3
|
-
# apidoc:0.11.
|
3
|
+
# apidoc:0.11.78 http://www.apidoc.me/flow/api/0.3.22/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.
|
28
|
+
USER_AGENT = 'apidoc:0.11.78 http://www.apidoc.me/flow/api/0.3.22/ruby_client' unless defined?(Constants::USER_AGENT)
|
29
29
|
VERSION = '0.3.17' unless defined?(Constants::VERSION)
|
30
30
|
VERSION_MAJOR = 0 unless defined?(VERSION_MAJOR)
|
31
31
|
|
@@ -308,6 +308,10 @@ module Io
|
|
308
308
|
@exports ||= ::Io::Flow::V0::Clients::Exports.new(self)
|
309
309
|
end
|
310
310
|
|
311
|
+
def feeds
|
312
|
+
@feeds ||= ::Io::Flow::V0::Clients::Feeds.new(self)
|
313
|
+
end
|
314
|
+
|
311
315
|
def healthchecks
|
312
316
|
@healthchecks ||= ::Io::Flow::V0::Clients::Healthchecks.new(self)
|
313
317
|
end
|
@@ -1096,6 +1100,7 @@ module Io
|
|
1096
1100
|
HttpClient::Preconditions.assert_class('organization', organization, String)
|
1097
1101
|
opts = HttpClient::Helper.symbolize_keys(incoming)
|
1098
1102
|
query = {
|
1103
|
+
:ip => (x = opts.delete(:ip); x.nil? ? nil : HttpClient::Preconditions.assert_class('ip', x, String)),
|
1099
1104
|
:country => (x = opts.delete(:country); x.nil? ? nil : HttpClient::Preconditions.assert_class('country', x, String))
|
1100
1105
|
}.delete_if { |k, v| v.nil? }
|
1101
1106
|
r = @client.request("/#{CGI.escape(organization)}/countries").with_query(query).get
|
@@ -3667,6 +3672,49 @@ module Io
|
|
3667
3672
|
|
3668
3673
|
end
|
3669
3674
|
|
3675
|
+
class Feeds
|
3676
|
+
|
3677
|
+
def initialize(client)
|
3678
|
+
@client = HttpClient::Preconditions.assert_class('client', client, ::Io::Flow::V0::Client)
|
3679
|
+
end
|
3680
|
+
|
3681
|
+
def get(organization, incoming={})
|
3682
|
+
HttpClient::Preconditions.assert_class('organization', organization, String)
|
3683
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
3684
|
+
query = {
|
3685
|
+
:id => (x = opts.delete(:id); x.nil? ? nil : HttpClient::Preconditions.assert_class('id', x, Array).map { |v| HttpClient::Preconditions.assert_class('id', v, String) }),
|
3686
|
+
:limit => HttpClient::Preconditions.assert_class('limit', (x = opts.delete(:limit); x.nil? ? 25 : x), Integer),
|
3687
|
+
:offset => HttpClient::Preconditions.assert_class('offset', (x = opts.delete(:offset); x.nil? ? 0 : x), Integer),
|
3688
|
+
:sort => HttpClient::Preconditions.assert_class('sort', (x = opts.delete(:sort); x.nil? ? "-created_at" : x), String)
|
3689
|
+
}.delete_if { |k, v| v.nil? }
|
3690
|
+
r = @client.request("/#{CGI.escape(organization)}/feeds").with_query(query).get
|
3691
|
+
r.map { |x| ::Io::Flow::V0::Models::Feed.from_json(x) }
|
3692
|
+
end
|
3693
|
+
|
3694
|
+
def delete_by_id(organization, id)
|
3695
|
+
HttpClient::Preconditions.assert_class('organization', organization, String)
|
3696
|
+
HttpClient::Preconditions.assert_class('id', id, String)
|
3697
|
+
r = @client.request("/#{CGI.escape(organization)}/feeds/#{CGI.escape(id)}").delete
|
3698
|
+
nil
|
3699
|
+
end
|
3700
|
+
|
3701
|
+
def post_catalog(organization, catalog_feed_form_post)
|
3702
|
+
HttpClient::Preconditions.assert_class('organization', organization, String)
|
3703
|
+
HttpClient::Preconditions.assert_class('catalog_feed_form_post', catalog_feed_form_post, ::Io::Flow::V0::Models::CatalogFeedFormPost)
|
3704
|
+
r = @client.request("/#{CGI.escape(organization)}/feeds/catalog").with_json(catalog_feed_form_post.to_json).post
|
3705
|
+
::Io::Flow::V0::Models::CatalogFeed.new(r)
|
3706
|
+
end
|
3707
|
+
|
3708
|
+
def put_catalog_by_id(organization, id, catalog_feed_form_put)
|
3709
|
+
HttpClient::Preconditions.assert_class('organization', organization, String)
|
3710
|
+
HttpClient::Preconditions.assert_class('id', id, String)
|
3711
|
+
HttpClient::Preconditions.assert_class('catalog_feed_form_put', catalog_feed_form_put, ::Io::Flow::V0::Models::CatalogFeedFormPut)
|
3712
|
+
r = @client.request("/#{CGI.escape(organization)}/feeds/catalog/#{CGI.escape(id)}").with_json(catalog_feed_form_put.to_json).put
|
3713
|
+
::Io::Flow::V0::Models::CatalogFeed.new(r)
|
3714
|
+
end
|
3715
|
+
|
3716
|
+
end
|
3717
|
+
|
3670
3718
|
class Healthchecks
|
3671
3719
|
|
3672
3720
|
def initialize(client)
|
@@ -4089,6 +4137,13 @@ module Io
|
|
4089
4137
|
::Io::Flow::V0::Models::OrganizationSession.new(r)
|
4090
4138
|
end
|
4091
4139
|
|
4140
|
+
def post_shopify_by_shop(shop, session_form)
|
4141
|
+
HttpClient::Preconditions.assert_class('shop', shop, String)
|
4142
|
+
HttpClient::Preconditions.assert_class('session_form', session_form, ::Io::Flow::V0::Models::SessionForm)
|
4143
|
+
r = @client.request("/sessions/shopify/#{CGI.escape(shop)}").with_json(session_form.to_json).post
|
4144
|
+
::Io::Flow::V0::Models::ShopifySession.new(r)
|
4145
|
+
end
|
4146
|
+
|
4092
4147
|
end
|
4093
4148
|
|
4094
4149
|
class SessionAuthorizations
|
@@ -5490,6 +5545,68 @@ module Io
|
|
5490
5545
|
|
5491
5546
|
end
|
5492
5547
|
|
5548
|
+
# Describes types of feeds that may be produced by Flow.
|
5549
|
+
class Feed
|
5550
|
+
|
5551
|
+
module Types
|
5552
|
+
# A localized product catalog.
|
5553
|
+
CATALOG_FEED = 'catalog_feed' unless defined?(CATALOG_FEED)
|
5554
|
+
end
|
5555
|
+
|
5556
|
+
attr_reader :discriminator
|
5557
|
+
|
5558
|
+
def initialize(incoming={})
|
5559
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
5560
|
+
HttpClient::Preconditions.require_keys(opts, [:discriminator], 'Feed')
|
5561
|
+
@discriminator = HttpClient::Preconditions.assert_class('discriminator', opts.delete(:discriminator), String)
|
5562
|
+
end
|
5563
|
+
|
5564
|
+
def subtype_to_hash
|
5565
|
+
raise 'Cannot serialize an instance of feed directly - must use one of the specific types: catalog_feed'
|
5566
|
+
end
|
5567
|
+
|
5568
|
+
def to_hash
|
5569
|
+
subtype_to_hash.merge(:discriminator => @discriminator)
|
5570
|
+
end
|
5571
|
+
|
5572
|
+
def Feed.from_json(hash)
|
5573
|
+
HttpClient::Preconditions.assert_class('hash', hash, Hash)
|
5574
|
+
discriminator = HttpClient::Helper.symbolize_keys(hash)[:discriminator].to_s.strip
|
5575
|
+
if discriminator.empty?
|
5576
|
+
raise "Union type[feed] requires a field named 'discriminator'"
|
5577
|
+
end
|
5578
|
+
case discriminator
|
5579
|
+
when Types::CATALOG_FEED; CatalogFeed.new(hash)
|
5580
|
+
else FeedUndefinedType.new(:discriminator => discriminator)
|
5581
|
+
end
|
5582
|
+
end
|
5583
|
+
|
5584
|
+
end
|
5585
|
+
|
5586
|
+
class FeedUndefinedType < Feed
|
5587
|
+
|
5588
|
+
attr_reader :name
|
5589
|
+
|
5590
|
+
def initialize(incoming={})
|
5591
|
+
super(:discriminator => 'undefined_type')
|
5592
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
5593
|
+
@name = HttpClient::Preconditions.assert_class('name', opts.delete(:discriminator), String)
|
5594
|
+
end
|
5595
|
+
|
5596
|
+
def subtype_to_hash
|
5597
|
+
raise 'Unable to serialize undefined type to json'
|
5598
|
+
end
|
5599
|
+
|
5600
|
+
def copy(incoming={})
|
5601
|
+
raise 'Operation not supported for undefined type'
|
5602
|
+
end
|
5603
|
+
|
5604
|
+
def to_hash
|
5605
|
+
raise 'Operation not supported for undefined type'
|
5606
|
+
end
|
5607
|
+
|
5608
|
+
end
|
5609
|
+
|
5493
5610
|
# Types of rules used to apply on inventory to calculate available quantity
|
5494
5611
|
class InventoryStrategy
|
5495
5612
|
|
@@ -7685,6 +7802,55 @@ module Io
|
|
7685
7802
|
|
7686
7803
|
end
|
7687
7804
|
|
7805
|
+
class FlowFieldName
|
7806
|
+
|
7807
|
+
attr_reader :value
|
7808
|
+
|
7809
|
+
def initialize(value)
|
7810
|
+
@value = HttpClient::Preconditions.assert_class('value', value, String)
|
7811
|
+
end
|
7812
|
+
|
7813
|
+
# Returns the instance of FlowFieldName for this value, creating a new instance for an unknown value
|
7814
|
+
def FlowFieldName.apply(value)
|
7815
|
+
if value.instance_of?(FlowFieldName)
|
7816
|
+
value
|
7817
|
+
else
|
7818
|
+
HttpClient::Preconditions.assert_class_or_nil('value', value, String)
|
7819
|
+
value.nil? ? nil : (from_string(value) || FlowFieldName.new(value))
|
7820
|
+
end
|
7821
|
+
end
|
7822
|
+
|
7823
|
+
# Returns the instance of FlowFieldName for this value, or nil if not found
|
7824
|
+
def FlowFieldName.from_string(value)
|
7825
|
+
HttpClient::Preconditions.assert_class('value', value, String)
|
7826
|
+
FlowFieldName.ALL.find { |v| v.value == value }
|
7827
|
+
end
|
7828
|
+
|
7829
|
+
def FlowFieldName.ALL
|
7830
|
+
@@all ||= [FlowFieldName.item_number, FlowFieldName.sku_attribute, FlowFieldName.product_id_attribute]
|
7831
|
+
end
|
7832
|
+
|
7833
|
+
# The Flow catalog item number
|
7834
|
+
def FlowFieldName.item_number
|
7835
|
+
@@_item_number ||= FlowFieldName.new('item-number')
|
7836
|
+
end
|
7837
|
+
|
7838
|
+
# A Flow catalog attribute named 'sku'
|
7839
|
+
def FlowFieldName.sku_attribute
|
7840
|
+
@@_sku_attribute ||= FlowFieldName.new('sku-attribute')
|
7841
|
+
end
|
7842
|
+
|
7843
|
+
# A Flow catalog attribute named 'product_id'
|
7844
|
+
def FlowFieldName.product_id_attribute
|
7845
|
+
@@_product_id_attribute ||= FlowFieldName.new('product_id-attribute')
|
7846
|
+
end
|
7847
|
+
|
7848
|
+
def to_hash
|
7849
|
+
value
|
7850
|
+
end
|
7851
|
+
|
7852
|
+
end
|
7853
|
+
|
7688
7854
|
class GenericErrorCode
|
7689
7855
|
|
7690
7856
|
attr_reader :value
|
@@ -7863,6 +8029,94 @@ module Io
|
|
7863
8029
|
|
7864
8030
|
end
|
7865
8031
|
|
8032
|
+
class IncomingFeedFormat
|
8033
|
+
|
8034
|
+
attr_reader :value
|
8035
|
+
|
8036
|
+
def initialize(value)
|
8037
|
+
@value = HttpClient::Preconditions.assert_class('value', value, String)
|
8038
|
+
end
|
8039
|
+
|
8040
|
+
# Returns the instance of IncomingFeedFormat for this value, creating a new instance for an unknown value
|
8041
|
+
def IncomingFeedFormat.apply(value)
|
8042
|
+
if value.instance_of?(IncomingFeedFormat)
|
8043
|
+
value
|
8044
|
+
else
|
8045
|
+
HttpClient::Preconditions.assert_class_or_nil('value', value, String)
|
8046
|
+
value.nil? ? nil : (from_string(value) || IncomingFeedFormat.new(value))
|
8047
|
+
end
|
8048
|
+
end
|
8049
|
+
|
8050
|
+
# Returns the instance of IncomingFeedFormat for this value, or nil if not found
|
8051
|
+
def IncomingFeedFormat.from_string(value)
|
8052
|
+
HttpClient::Preconditions.assert_class('value', value, String)
|
8053
|
+
IncomingFeedFormat.ALL.find { |v| v.value == value }
|
8054
|
+
end
|
8055
|
+
|
8056
|
+
def IncomingFeedFormat.ALL
|
8057
|
+
@@all ||= [IncomingFeedFormat.google_xml, IncomingFeedFormat.google_sheet]
|
8058
|
+
end
|
8059
|
+
|
8060
|
+
# Google RSS-like product catalog feed
|
8061
|
+
def IncomingFeedFormat.google_xml
|
8062
|
+
@@_google_xml ||= IncomingFeedFormat.new('google-xml')
|
8063
|
+
end
|
8064
|
+
|
8065
|
+
# Google Sheet-based product catalog feed
|
8066
|
+
def IncomingFeedFormat.google_sheet
|
8067
|
+
@@_google_sheet ||= IncomingFeedFormat.new('google-sheet')
|
8068
|
+
end
|
8069
|
+
|
8070
|
+
def to_hash
|
8071
|
+
value
|
8072
|
+
end
|
8073
|
+
|
8074
|
+
end
|
8075
|
+
|
8076
|
+
class IncomingFieldName
|
8077
|
+
|
8078
|
+
attr_reader :value
|
8079
|
+
|
8080
|
+
def initialize(value)
|
8081
|
+
@value = HttpClient::Preconditions.assert_class('value', value, String)
|
8082
|
+
end
|
8083
|
+
|
8084
|
+
# Returns the instance of IncomingFieldName for this value, creating a new instance for an unknown value
|
8085
|
+
def IncomingFieldName.apply(value)
|
8086
|
+
if value.instance_of?(IncomingFieldName)
|
8087
|
+
value
|
8088
|
+
else
|
8089
|
+
HttpClient::Preconditions.assert_class_or_nil('value', value, String)
|
8090
|
+
value.nil? ? nil : (from_string(value) || IncomingFieldName.new(value))
|
8091
|
+
end
|
8092
|
+
end
|
8093
|
+
|
8094
|
+
# Returns the instance of IncomingFieldName for this value, or nil if not found
|
8095
|
+
def IncomingFieldName.from_string(value)
|
8096
|
+
HttpClient::Preconditions.assert_class('value', value, String)
|
8097
|
+
IncomingFieldName.ALL.find { |v| v.value == value }
|
8098
|
+
end
|
8099
|
+
|
8100
|
+
def IncomingFieldName.ALL
|
8101
|
+
@@all ||= [IncomingFieldName.id, IncomingFieldName.mpn]
|
8102
|
+
end
|
8103
|
+
|
8104
|
+
# The id field of the incoming feed
|
8105
|
+
def IncomingFieldName.id
|
8106
|
+
@@_id ||= IncomingFieldName.new('id')
|
8107
|
+
end
|
8108
|
+
|
8109
|
+
# The Manufacturer's Product Number (MPN) field of the incoming feed
|
8110
|
+
def IncomingFieldName.mpn
|
8111
|
+
@@_mpn ||= IncomingFieldName.new('mpn')
|
8112
|
+
end
|
8113
|
+
|
8114
|
+
def to_hash
|
8115
|
+
value
|
8116
|
+
end
|
8117
|
+
|
8118
|
+
end
|
8119
|
+
|
7866
8120
|
class InvitationErrorCode
|
7867
8121
|
|
7868
8122
|
attr_reader :value
|
@@ -8449,6 +8703,60 @@ module Io
|
|
8449
8703
|
|
8450
8704
|
end
|
8451
8705
|
|
8706
|
+
class OutgoingFeedFormat
|
8707
|
+
|
8708
|
+
attr_reader :value
|
8709
|
+
|
8710
|
+
def initialize(value)
|
8711
|
+
@value = HttpClient::Preconditions.assert_class('value', value, String)
|
8712
|
+
end
|
8713
|
+
|
8714
|
+
# Returns the instance of OutgoingFeedFormat for this value, creating a new instance for an unknown value
|
8715
|
+
def OutgoingFeedFormat.apply(value)
|
8716
|
+
if value.instance_of?(OutgoingFeedFormat)
|
8717
|
+
value
|
8718
|
+
else
|
8719
|
+
HttpClient::Preconditions.assert_class_or_nil('value', value, String)
|
8720
|
+
value.nil? ? nil : (from_string(value) || OutgoingFeedFormat.new(value))
|
8721
|
+
end
|
8722
|
+
end
|
8723
|
+
|
8724
|
+
# Returns the instance of OutgoingFeedFormat for this value, or nil if not found
|
8725
|
+
def OutgoingFeedFormat.from_string(value)
|
8726
|
+
HttpClient::Preconditions.assert_class('value', value, String)
|
8727
|
+
OutgoingFeedFormat.ALL.find { |v| v.value == value }
|
8728
|
+
end
|
8729
|
+
|
8730
|
+
def OutgoingFeedFormat.ALL
|
8731
|
+
@@all ||= [OutgoingFeedFormat.facebook_xml, OutgoingFeedFormat.google_tsv, OutgoingFeedFormat.google_xml, OutgoingFeedFormat.criteo_xml]
|
8732
|
+
end
|
8733
|
+
|
8734
|
+
# Facebook RSS XML product catalog feed
|
8735
|
+
def OutgoingFeedFormat.facebook_xml
|
8736
|
+
@@_facebook_xml ||= OutgoingFeedFormat.new('facebook-xml')
|
8737
|
+
end
|
8738
|
+
|
8739
|
+
# Google Tab Seperated Values product catalog feed
|
8740
|
+
def OutgoingFeedFormat.google_tsv
|
8741
|
+
@@_google_tsv ||= OutgoingFeedFormat.new('google-tsv')
|
8742
|
+
end
|
8743
|
+
|
8744
|
+
# Google RSS XML product catalog feed
|
8745
|
+
def OutgoingFeedFormat.google_xml
|
8746
|
+
@@_google_xml ||= OutgoingFeedFormat.new('google-xml')
|
8747
|
+
end
|
8748
|
+
|
8749
|
+
# Criteo RSS XML product catalog feed
|
8750
|
+
def OutgoingFeedFormat.criteo_xml
|
8751
|
+
@@_criteo_xml ||= OutgoingFeedFormat.new('criteo-xml')
|
8752
|
+
end
|
8753
|
+
|
8754
|
+
def to_hash
|
8755
|
+
value
|
8756
|
+
end
|
8757
|
+
|
8758
|
+
end
|
8759
|
+
|
8452
8760
|
class PaymentErrorCode
|
8453
8761
|
|
8454
8762
|
attr_reader :value
|
@@ -10081,17 +10389,17 @@ module Io
|
|
10081
10389
|
|
10082
10390
|
class AccountOrdersExportType < ExportType
|
10083
10391
|
|
10084
|
-
attr_reader :
|
10392
|
+
attr_reader :statement_id, :transaction_summary_id, :transaction_posted_on_or_after, :transaction_posted_after, :transaction_posted_on_or_before, :transaction_posted_before
|
10085
10393
|
|
10086
10394
|
def initialize(incoming={})
|
10087
10395
|
super(:discriminator => ExportType::Types::ACCOUNT_ORDERS_EXPORT_TYPE)
|
10088
10396
|
opts = HttpClient::Helper.symbolize_keys(incoming)
|
10089
|
-
@
|
10397
|
+
@statement_id = (x = opts.delete(:statement_id); x.nil? ? nil : HttpClient::Preconditions.assert_class('statement_id', x, String))
|
10090
10398
|
@transaction_summary_id = (x = opts.delete(:transaction_summary_id); x.nil? ? nil : HttpClient::Preconditions.assert_class('transaction_summary_id', x, String))
|
10091
|
-
@
|
10092
|
-
@
|
10093
|
-
@
|
10094
|
-
@
|
10399
|
+
@transaction_posted_on_or_after = (x = opts.delete(:transaction_posted_on_or_after); x.nil? ? nil : HttpClient::Preconditions.assert_class('transaction_posted_on_or_after', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10400
|
+
@transaction_posted_after = (x = opts.delete(:transaction_posted_after); x.nil? ? nil : HttpClient::Preconditions.assert_class('transaction_posted_after', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10401
|
+
@transaction_posted_on_or_before = (x = opts.delete(:transaction_posted_on_or_before); x.nil? ? nil : HttpClient::Preconditions.assert_class('transaction_posted_on_or_before', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10402
|
+
@transaction_posted_before = (x = opts.delete(:transaction_posted_before); x.nil? ? nil : HttpClient::Preconditions.assert_class('transaction_posted_before', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10095
10403
|
end
|
10096
10404
|
|
10097
10405
|
def to_json
|
@@ -10104,12 +10412,12 @@ module Io
|
|
10104
10412
|
|
10105
10413
|
def subtype_to_hash
|
10106
10414
|
{
|
10107
|
-
:
|
10415
|
+
:statement_id => statement_id,
|
10108
10416
|
:transaction_summary_id => transaction_summary_id,
|
10109
|
-
:
|
10110
|
-
:
|
10111
|
-
:
|
10112
|
-
:
|
10417
|
+
:transaction_posted_on_or_after => transaction_posted_on_or_after,
|
10418
|
+
:transaction_posted_after => transaction_posted_after,
|
10419
|
+
:transaction_posted_on_or_before => transaction_posted_on_or_before,
|
10420
|
+
:transaction_posted_before => transaction_posted_before
|
10113
10421
|
}
|
10114
10422
|
end
|
10115
10423
|
|
@@ -10117,17 +10425,17 @@ module Io
|
|
10117
10425
|
|
10118
10426
|
class AccountTransactionsExportType < ExportType
|
10119
10427
|
|
10120
|
-
attr_reader :
|
10428
|
+
attr_reader :statement_id, :transaction_summary_id, :posted_on_or_after, :posted_after, :posted_on_or_before, :posted_before
|
10121
10429
|
|
10122
10430
|
def initialize(incoming={})
|
10123
10431
|
super(:discriminator => ExportType::Types::ACCOUNT_TRANSACTIONS_EXPORT_TYPE)
|
10124
10432
|
opts = HttpClient::Helper.symbolize_keys(incoming)
|
10125
|
-
@
|
10433
|
+
@statement_id = (x = opts.delete(:statement_id); x.nil? ? nil : HttpClient::Preconditions.assert_class('statement_id', x, String))
|
10126
10434
|
@transaction_summary_id = (x = opts.delete(:transaction_summary_id); x.nil? ? nil : HttpClient::Preconditions.assert_class('transaction_summary_id', x, String))
|
10127
|
-
@
|
10128
|
-
@
|
10129
|
-
@
|
10130
|
-
@
|
10435
|
+
@posted_on_or_after = (x = opts.delete(:posted_on_or_after); x.nil? ? nil : HttpClient::Preconditions.assert_class('posted_on_or_after', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10436
|
+
@posted_after = (x = opts.delete(:posted_after); x.nil? ? nil : HttpClient::Preconditions.assert_class('posted_after', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10437
|
+
@posted_on_or_before = (x = opts.delete(:posted_on_or_before); x.nil? ? nil : HttpClient::Preconditions.assert_class('posted_on_or_before', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10438
|
+
@posted_before = (x = opts.delete(:posted_before); x.nil? ? nil : HttpClient::Preconditions.assert_class('posted_before', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
10131
10439
|
end
|
10132
10440
|
|
10133
10441
|
def to_json
|
@@ -10140,12 +10448,12 @@ module Io
|
|
10140
10448
|
|
10141
10449
|
def subtype_to_hash
|
10142
10450
|
{
|
10143
|
-
:
|
10451
|
+
:statement_id => statement_id,
|
10144
10452
|
:transaction_summary_id => transaction_summary_id,
|
10145
|
-
:
|
10146
|
-
:
|
10147
|
-
:
|
10148
|
-
:
|
10453
|
+
:posted_on_or_after => posted_on_or_after,
|
10454
|
+
:posted_after => posted_after,
|
10455
|
+
:posted_on_or_before => posted_on_or_before,
|
10456
|
+
:posted_before => posted_before
|
10149
10457
|
}
|
10150
10458
|
end
|
10151
10459
|
|
@@ -12040,6 +12348,106 @@ module Io
|
|
12040
12348
|
|
12041
12349
|
end
|
12042
12350
|
|
12351
|
+
# Describes a catalog feed.
|
12352
|
+
class CatalogFeed < Feed
|
12353
|
+
|
12354
|
+
attr_reader :id, :experience_feed_summaries, :incoming_feed, :outgoing_feed, :feed_statistics_summary
|
12355
|
+
|
12356
|
+
def initialize(incoming={})
|
12357
|
+
super(:discriminator => Feed::Types::CATALOG_FEED)
|
12358
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
12359
|
+
HttpClient::Preconditions.require_keys(opts, [:id, :experience_feed_summaries, :incoming_feed, :outgoing_feed, :feed_statistics_summary], 'CatalogFeed')
|
12360
|
+
@id = HttpClient::Preconditions.assert_class('id', opts.delete(:id), String)
|
12361
|
+
@experience_feed_summaries = HttpClient::Preconditions.assert_class('experience_feed_summaries', opts.delete(:experience_feed_summaries), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::ExperienceFeedSummary) ? x : ::Io::Flow::V0::Models::ExperienceFeedSummary.new(x)) }
|
12362
|
+
@incoming_feed = (x = opts.delete(:incoming_feed); x.is_a?(::Io::Flow::V0::Models::IncomingFeed) ? x : ::Io::Flow::V0::Models::IncomingFeed.new(x))
|
12363
|
+
@outgoing_feed = (x = opts.delete(:outgoing_feed); x.is_a?(::Io::Flow::V0::Models::OutgoingFeed) ? x : ::Io::Flow::V0::Models::OutgoingFeed.new(x))
|
12364
|
+
@feed_statistics_summary = (x = opts.delete(:feed_statistics_summary); x.is_a?(::Io::Flow::V0::Models::FeedStatisticsSummary) ? x : ::Io::Flow::V0::Models::FeedStatisticsSummary.new(x))
|
12365
|
+
end
|
12366
|
+
|
12367
|
+
def to_json
|
12368
|
+
JSON.dump(to_hash)
|
12369
|
+
end
|
12370
|
+
|
12371
|
+
def copy(incoming={})
|
12372
|
+
CatalogFeed.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
12373
|
+
end
|
12374
|
+
|
12375
|
+
def subtype_to_hash
|
12376
|
+
{
|
12377
|
+
:id => id,
|
12378
|
+
:experience_feed_summaries => experience_feed_summaries.map { |o| o.to_hash },
|
12379
|
+
:incoming_feed => incoming_feed.to_hash,
|
12380
|
+
:outgoing_feed => outgoing_feed.to_hash,
|
12381
|
+
:feed_statistics_summary => feed_statistics_summary.to_hash
|
12382
|
+
}
|
12383
|
+
end
|
12384
|
+
|
12385
|
+
end
|
12386
|
+
|
12387
|
+
# Specify a catalog feed for one or more experiences.
|
12388
|
+
class CatalogFeedFormPost
|
12389
|
+
|
12390
|
+
attr_reader :experience_keys, :incoming_feed, :outgoing_feed_form
|
12391
|
+
|
12392
|
+
def initialize(incoming={})
|
12393
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
12394
|
+
HttpClient::Preconditions.require_keys(opts, [:experience_keys, :incoming_feed, :outgoing_feed_form], 'CatalogFeedFormPost')
|
12395
|
+
@experience_keys = HttpClient::Preconditions.assert_class('experience_keys', opts.delete(:experience_keys), Array).map { |v| HttpClient::Preconditions.assert_class('experience_keys', v, String) }
|
12396
|
+
@incoming_feed = (x = opts.delete(:incoming_feed); x.is_a?(::Io::Flow::V0::Models::IncomingFeed) ? x : ::Io::Flow::V0::Models::IncomingFeed.new(x))
|
12397
|
+
@outgoing_feed_form = (x = opts.delete(:outgoing_feed_form); x.is_a?(::Io::Flow::V0::Models::OutgoingFeed) ? x : ::Io::Flow::V0::Models::OutgoingFeed.new(x))
|
12398
|
+
end
|
12399
|
+
|
12400
|
+
def to_json
|
12401
|
+
JSON.dump(to_hash)
|
12402
|
+
end
|
12403
|
+
|
12404
|
+
def copy(incoming={})
|
12405
|
+
CatalogFeedFormPost.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
12406
|
+
end
|
12407
|
+
|
12408
|
+
def to_hash
|
12409
|
+
{
|
12410
|
+
:experience_keys => experience_keys,
|
12411
|
+
:incoming_feed => incoming_feed.to_hash,
|
12412
|
+
:outgoing_feed_form => outgoing_feed_form.to_hash
|
12413
|
+
}
|
12414
|
+
end
|
12415
|
+
|
12416
|
+
end
|
12417
|
+
|
12418
|
+
# Specify a catalog feed for one or more experiences.
|
12419
|
+
class CatalogFeedFormPut
|
12420
|
+
|
12421
|
+
attr_reader :id, :experience_keys, :incoming_feed, :outgoing_feed_form
|
12422
|
+
|
12423
|
+
def initialize(incoming={})
|
12424
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
12425
|
+
HttpClient::Preconditions.require_keys(opts, [:id, :experience_keys, :incoming_feed, :outgoing_feed_form], 'CatalogFeedFormPut')
|
12426
|
+
@id = HttpClient::Preconditions.assert_class('id', opts.delete(:id), String)
|
12427
|
+
@experience_keys = HttpClient::Preconditions.assert_class('experience_keys', opts.delete(:experience_keys), Array).map { |v| HttpClient::Preconditions.assert_class('experience_keys', v, String) }
|
12428
|
+
@incoming_feed = (x = opts.delete(:incoming_feed); x.is_a?(::Io::Flow::V0::Models::IncomingFeed) ? x : ::Io::Flow::V0::Models::IncomingFeed.new(x))
|
12429
|
+
@outgoing_feed_form = (x = opts.delete(:outgoing_feed_form); x.is_a?(::Io::Flow::V0::Models::OutgoingFeed) ? x : ::Io::Flow::V0::Models::OutgoingFeed.new(x))
|
12430
|
+
end
|
12431
|
+
|
12432
|
+
def to_json
|
12433
|
+
JSON.dump(to_hash)
|
12434
|
+
end
|
12435
|
+
|
12436
|
+
def copy(incoming={})
|
12437
|
+
CatalogFeedFormPut.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
12438
|
+
end
|
12439
|
+
|
12440
|
+
def to_hash
|
12441
|
+
{
|
12442
|
+
:id => id,
|
12443
|
+
:experience_keys => experience_keys,
|
12444
|
+
:incoming_feed => incoming_feed.to_hash,
|
12445
|
+
:outgoing_feed_form => outgoing_feed_form.to_hash
|
12446
|
+
}
|
12447
|
+
end
|
12448
|
+
|
12449
|
+
end
|
12450
|
+
|
12043
12451
|
class CatalogItemDeleted < Event
|
12044
12452
|
|
12045
12453
|
attr_reader :event_id, :timestamp, :organization, :number, :catalog
|
@@ -13637,6 +14045,36 @@ module Io
|
|
13637
14045
|
|
13638
14046
|
end
|
13639
14047
|
|
14048
|
+
class ExperienceFeedSummary
|
14049
|
+
|
14050
|
+
attr_reader :experience, :url, :last_construct_date
|
14051
|
+
|
14052
|
+
def initialize(incoming={})
|
14053
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
14054
|
+
HttpClient::Preconditions.require_keys(opts, [:experience, :url], 'ExperienceFeedSummary')
|
14055
|
+
@experience = (x = opts.delete(:experience); x.is_a?(::Io::Flow::V0::Models::ExperienceReference) ? x : ::Io::Flow::V0::Models::ExperienceReference.new(x))
|
14056
|
+
@url = HttpClient::Preconditions.assert_class('url', opts.delete(:url), String)
|
14057
|
+
@last_construct_date = (x = opts.delete(:last_construct_date); x.nil? ? nil : HttpClient::Preconditions.assert_class('last_construct_date', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
14058
|
+
end
|
14059
|
+
|
14060
|
+
def to_json
|
14061
|
+
JSON.dump(to_hash)
|
14062
|
+
end
|
14063
|
+
|
14064
|
+
def copy(incoming={})
|
14065
|
+
ExperienceFeedSummary.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
14066
|
+
end
|
14067
|
+
|
14068
|
+
def to_hash
|
14069
|
+
{
|
14070
|
+
:experience => experience.to_hash,
|
14071
|
+
:url => url,
|
14072
|
+
:last_construct_date => last_construct_date
|
14073
|
+
}
|
14074
|
+
end
|
14075
|
+
|
14076
|
+
end
|
14077
|
+
|
13640
14078
|
# Experiences define a local experience for a given geographic region
|
13641
14079
|
class ExperienceForm
|
13642
14080
|
|
@@ -13682,6 +14120,45 @@ module Io
|
|
13682
14120
|
|
13683
14121
|
end
|
13684
14122
|
|
14123
|
+
# Experience Geo summarizes an experience along with geographic info
|
14124
|
+
class ExperienceGeo
|
14125
|
+
|
14126
|
+
attr_reader :key, :name, :region, :country, :currency, :language, :measurement_system
|
14127
|
+
|
14128
|
+
def initialize(incoming={})
|
14129
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
14130
|
+
HttpClient::Preconditions.require_keys(opts, [:key, :name, :region, :country, :currency, :language, :measurement_system], 'ExperienceGeo')
|
14131
|
+
@key = HttpClient::Preconditions.assert_class('key', opts.delete(:key), String)
|
14132
|
+
@name = HttpClient::Preconditions.assert_class('name', opts.delete(:name), String)
|
14133
|
+
@region = (x = opts.delete(:region); x.is_a?(::Io::Flow::V0::Models::RegionReference) ? x : ::Io::Flow::V0::Models::RegionReference.new(x))
|
14134
|
+
@country = HttpClient::Preconditions.assert_class('country', opts.delete(:country), String)
|
14135
|
+
@currency = HttpClient::Preconditions.assert_class('currency', opts.delete(:currency), String)
|
14136
|
+
@language = HttpClient::Preconditions.assert_class('language', opts.delete(:language), String)
|
14137
|
+
@measurement_system = (x = opts.delete(:measurement_system); x.is_a?(::Io::Flow::V0::Models::MeasurementSystem) ? x : ::Io::Flow::V0::Models::MeasurementSystem.apply(x))
|
14138
|
+
end
|
14139
|
+
|
14140
|
+
def to_json
|
14141
|
+
JSON.dump(to_hash)
|
14142
|
+
end
|
14143
|
+
|
14144
|
+
def copy(incoming={})
|
14145
|
+
ExperienceGeo.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
14146
|
+
end
|
14147
|
+
|
14148
|
+
def to_hash
|
14149
|
+
{
|
14150
|
+
:key => key,
|
14151
|
+
:name => name,
|
14152
|
+
:region => region.to_hash,
|
14153
|
+
:country => country,
|
14154
|
+
:currency => currency,
|
14155
|
+
:language => language,
|
14156
|
+
:measurement_system => measurement_system.value
|
14157
|
+
}
|
14158
|
+
end
|
14159
|
+
|
14160
|
+
end
|
14161
|
+
|
13685
14162
|
class ExperienceReference < ExpandableExperience
|
13686
14163
|
|
13687
14164
|
attr_reader :key
|
@@ -14073,6 +14550,33 @@ module Io
|
|
14073
14550
|
|
14074
14551
|
end
|
14075
14552
|
|
14553
|
+
# A brief packet of statistics about a live feed. Will be blank for most new
|
14554
|
+
# feeds.
|
14555
|
+
class FeedStatisticsSummary
|
14556
|
+
|
14557
|
+
attr_reader :last_incoming_date
|
14558
|
+
|
14559
|
+
def initialize(incoming={})
|
14560
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
14561
|
+
@last_incoming_date = (x = opts.delete(:last_incoming_date); x.nil? ? nil : HttpClient::Preconditions.assert_class('last_incoming_date', HttpClient::Helper.to_date_time_iso8601(x), DateTime))
|
14562
|
+
end
|
14563
|
+
|
14564
|
+
def to_json
|
14565
|
+
JSON.dump(to_hash)
|
14566
|
+
end
|
14567
|
+
|
14568
|
+
def copy(incoming={})
|
14569
|
+
FeedStatisticsSummary.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
14570
|
+
end
|
14571
|
+
|
14572
|
+
def to_hash
|
14573
|
+
{
|
14574
|
+
:last_incoming_date => last_incoming_date
|
14575
|
+
}
|
14576
|
+
end
|
14577
|
+
|
14578
|
+
end
|
14579
|
+
|
14076
14580
|
class Ference
|
14077
14581
|
|
14078
14582
|
attr_reader :id
|
@@ -15531,6 +16035,39 @@ module Io
|
|
15531
16035
|
|
15532
16036
|
end
|
15533
16037
|
|
16038
|
+
# Describe a feed incoming to Flow
|
16039
|
+
class IncomingFeed
|
16040
|
+
|
16041
|
+
attr_reader :url, :format, :minute, :item_link
|
16042
|
+
|
16043
|
+
def initialize(incoming={})
|
16044
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
16045
|
+
HttpClient::Preconditions.require_keys(opts, [:url, :format, :item_link], 'IncomingFeed')
|
16046
|
+
@url = HttpClient::Preconditions.assert_class('url', opts.delete(:url), String)
|
16047
|
+
@format = (x = opts.delete(:format); x.is_a?(::Io::Flow::V0::Models::IncomingFeedFormat) ? x : ::Io::Flow::V0::Models::IncomingFeedFormat.apply(x))
|
16048
|
+
@minute = HttpClient::Preconditions.assert_class('minute', (x = opts.delete(:minute); x.nil? ? 55 : x), Integer)
|
16049
|
+
@item_link = (x = opts.delete(:item_link); x.is_a?(::Io::Flow::V0::Models::ItemLink) ? x : ::Io::Flow::V0::Models::ItemLink.new(x))
|
16050
|
+
end
|
16051
|
+
|
16052
|
+
def to_json
|
16053
|
+
JSON.dump(to_hash)
|
16054
|
+
end
|
16055
|
+
|
16056
|
+
def copy(incoming={})
|
16057
|
+
IncomingFeed.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
16058
|
+
end
|
16059
|
+
|
16060
|
+
def to_hash
|
16061
|
+
{
|
16062
|
+
:url => url,
|
16063
|
+
:format => format.value,
|
16064
|
+
:minute => minute,
|
16065
|
+
:item_link => item_link.to_hash
|
16066
|
+
}
|
16067
|
+
end
|
16068
|
+
|
16069
|
+
end
|
16070
|
+
|
15534
16071
|
# Enables backorders, setting an optional number of units that we allow for
|
15535
16072
|
# backorder. For example, a backorder w/ quantity 10 will enable selling until
|
15536
16073
|
# the actual inventory quantity is -10.
|
@@ -16340,6 +16877,36 @@ module Io
|
|
16340
16877
|
|
16341
16878
|
end
|
16342
16879
|
|
16880
|
+
# Describes how items from an incoming feed will link with localized items in a
|
16881
|
+
# Flow catalog to create an outgoing feed.
|
16882
|
+
class ItemLink
|
16883
|
+
|
16884
|
+
attr_reader :incoming_field_name, :flow_field_name
|
16885
|
+
|
16886
|
+
def initialize(incoming={})
|
16887
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
16888
|
+
HttpClient::Preconditions.require_keys(opts, [:incoming_field_name, :flow_field_name], 'ItemLink')
|
16889
|
+
@incoming_field_name = (x = opts.delete(:incoming_field_name); x.is_a?(::Io::Flow::V0::Models::IncomingFieldName) ? x : ::Io::Flow::V0::Models::IncomingFieldName.apply(x))
|
16890
|
+
@flow_field_name = (x = opts.delete(:flow_field_name); x.is_a?(::Io::Flow::V0::Models::FlowFieldName) ? x : ::Io::Flow::V0::Models::FlowFieldName.apply(x))
|
16891
|
+
end
|
16892
|
+
|
16893
|
+
def to_json
|
16894
|
+
JSON.dump(to_hash)
|
16895
|
+
end
|
16896
|
+
|
16897
|
+
def copy(incoming={})
|
16898
|
+
ItemLink.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
16899
|
+
end
|
16900
|
+
|
16901
|
+
def to_hash
|
16902
|
+
{
|
16903
|
+
:incoming_field_name => incoming_field_name.value,
|
16904
|
+
:flow_field_name => flow_field_name.value
|
16905
|
+
}
|
16906
|
+
end
|
16907
|
+
|
16908
|
+
end
|
16909
|
+
|
16343
16910
|
# Defines a fixed and percent margin to apply to items matching a query.
|
16344
16911
|
class ItemMargin
|
16345
16912
|
|
@@ -17188,7 +17755,7 @@ module Io
|
|
17188
17755
|
@currency = (x = opts.delete(:currency); x.is_a?(::Io::Flow::V0::Models::Currency) ? x : ::Io::Flow::V0::Models::Currency.new(x))
|
17189
17756
|
@language = (x = opts.delete(:language); x.is_a?(::Io::Flow::V0::Models::Language) ? x : ::Io::Flow::V0::Models::Language.new(x))
|
17190
17757
|
@locale = (x = opts.delete(:locale); x.is_a?(::Io::Flow::V0::Models::Locale) ? x : ::Io::Flow::V0::Models::Locale.new(x))
|
17191
|
-
@experience = (x = opts.delete(:experience); x.is_a?(::Io::Flow::V0::Models::
|
17758
|
+
@experience = (x = opts.delete(:experience); x.is_a?(::Io::Flow::V0::Models::ExperienceGeo) ? x : ::Io::Flow::V0::Models::ExperienceGeo.new(x))
|
17192
17759
|
end
|
17193
17760
|
|
17194
17761
|
def to_json
|
@@ -19396,7 +19963,7 @@ module Io
|
|
19396
19963
|
|
19397
19964
|
class OrganizationSession < Session
|
19398
19965
|
|
19399
|
-
attr_reader :id, :organization, :environment, :attributes, :local
|
19966
|
+
attr_reader :id, :organization, :environment, :attributes, :ip, :local
|
19400
19967
|
|
19401
19968
|
def initialize(incoming={})
|
19402
19969
|
super(:discriminator => Session::Types::ORGANIZATION_SESSION)
|
@@ -19406,6 +19973,7 @@ module Io
|
|
19406
19973
|
@organization = HttpClient::Preconditions.assert_class('organization', opts.delete(:organization), String)
|
19407
19974
|
@environment = (x = opts.delete(:environment); x.is_a?(::Io::Flow::V0::Models::Environment) ? x : ::Io::Flow::V0::Models::Environment.apply(x))
|
19408
19975
|
@attributes = HttpClient::Preconditions.assert_class('attributes', opts.delete(:attributes), Hash).inject({}) { |h, d| h[d[0]] = HttpClient::Preconditions.assert_class('attributes', d[1], String); h }
|
19976
|
+
@ip = (x = opts.delete(:ip); x.nil? ? nil : HttpClient::Preconditions.assert_class('ip', x, String))
|
19409
19977
|
@local = (x = opts.delete(:local); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::LocalSession) ? x : ::Io::Flow::V0::Models::LocalSession.new(x)))
|
19410
19978
|
end
|
19411
19979
|
|
@@ -19423,6 +19991,7 @@ module Io
|
|
19423
19991
|
:organization => organization,
|
19424
19992
|
:environment => environment.value,
|
19425
19993
|
:attributes => attributes,
|
19994
|
+
:ip => ip,
|
19426
19995
|
:local => local.nil? ? nil : local.to_hash
|
19427
19996
|
}
|
19428
19997
|
end
|
@@ -19669,6 +20238,64 @@ module Io
|
|
19669
20238
|
|
19670
20239
|
end
|
19671
20240
|
|
20241
|
+
# Describes the outgoing feed constructed by Flow
|
20242
|
+
class OutgoingFeed
|
20243
|
+
|
20244
|
+
attr_reader :format, :minute
|
20245
|
+
|
20246
|
+
def initialize(incoming={})
|
20247
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
20248
|
+
HttpClient::Preconditions.require_keys(opts, [:format], 'OutgoingFeed')
|
20249
|
+
@format = (x = opts.delete(:format); x.is_a?(::Io::Flow::V0::Models::OutgoingFeedFormat) ? x : ::Io::Flow::V0::Models::OutgoingFeedFormat.apply(x))
|
20250
|
+
@minute = HttpClient::Preconditions.assert_class('minute', (x = opts.delete(:minute); x.nil? ? 0 : x), Integer)
|
20251
|
+
end
|
20252
|
+
|
20253
|
+
def to_json
|
20254
|
+
JSON.dump(to_hash)
|
20255
|
+
end
|
20256
|
+
|
20257
|
+
def copy(incoming={})
|
20258
|
+
OutgoingFeed.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
20259
|
+
end
|
20260
|
+
|
20261
|
+
def to_hash
|
20262
|
+
{
|
20263
|
+
:format => format.value,
|
20264
|
+
:minute => minute
|
20265
|
+
}
|
20266
|
+
end
|
20267
|
+
|
20268
|
+
end
|
20269
|
+
|
20270
|
+
# Describes the outgoing feed constructed by Flow
|
20271
|
+
class OutgoingFeedForm
|
20272
|
+
|
20273
|
+
attr_reader :format, :minute
|
20274
|
+
|
20275
|
+
def initialize(incoming={})
|
20276
|
+
opts = HttpClient::Helper.symbolize_keys(incoming)
|
20277
|
+
HttpClient::Preconditions.require_keys(opts, [:format], 'OutgoingFeedForm')
|
20278
|
+
@format = (x = opts.delete(:format); x.is_a?(::Io::Flow::V0::Models::OutgoingFeedFormat) ? x : ::Io::Flow::V0::Models::OutgoingFeedFormat.apply(x))
|
20279
|
+
@minute = HttpClient::Preconditions.assert_class('minute', (x = opts.delete(:minute); x.nil? ? 0 : x), Integer)
|
20280
|
+
end
|
20281
|
+
|
20282
|
+
def to_json
|
20283
|
+
JSON.dump(to_hash)
|
20284
|
+
end
|
20285
|
+
|
20286
|
+
def copy(incoming={})
|
20287
|
+
OutgoingFeedForm.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
|
20288
|
+
end
|
20289
|
+
|
20290
|
+
def to_hash
|
20291
|
+
{
|
20292
|
+
:format => format.value,
|
20293
|
+
:minute => minute
|
20294
|
+
}
|
20295
|
+
end
|
20296
|
+
|
20297
|
+
end
|
20298
|
+
|
19672
20299
|
# Represents packaging available to ship items
|
19673
20300
|
class Packaging
|
19674
20301
|
|
@@ -22585,7 +23212,7 @@ module Io
|
|
22585
23212
|
|
22586
23213
|
class ShopifySession < Session
|
22587
23214
|
|
22588
|
-
attr_reader :id, :organization, :environment, :attributes, :local, :shop, :cart, :experiments
|
23215
|
+
attr_reader :id, :organization, :environment, :attributes, :ip, :local, :shop, :cart, :experiments
|
22589
23216
|
|
22590
23217
|
def initialize(incoming={})
|
22591
23218
|
super(:discriminator => Session::Types::SHOPIFY_SESSION)
|
@@ -22595,6 +23222,7 @@ module Io
|
|
22595
23222
|
@organization = HttpClient::Preconditions.assert_class('organization', opts.delete(:organization), String)
|
22596
23223
|
@environment = (x = opts.delete(:environment); x.is_a?(::Io::Flow::V0::Models::Environment) ? x : ::Io::Flow::V0::Models::Environment.apply(x))
|
22597
23224
|
@attributes = HttpClient::Preconditions.assert_class('attributes', opts.delete(:attributes), Hash).inject({}) { |h, d| h[d[0]] = HttpClient::Preconditions.assert_class('attributes', d[1], String); h }
|
23225
|
+
@ip = (x = opts.delete(:ip); x.nil? ? nil : HttpClient::Preconditions.assert_class('ip', x, String))
|
22598
23226
|
@local = (x = opts.delete(:local); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::LocalSession) ? x : ::Io::Flow::V0::Models::LocalSession.new(x)))
|
22599
23227
|
@shop = HttpClient::Preconditions.assert_class('shop', opts.delete(:shop), String)
|
22600
23228
|
@cart = (x = opts.delete(:cart); x.is_a?(::Io::Flow::V0::Models::CartReference) ? x : ::Io::Flow::V0::Models::CartReference.new(x))
|
@@ -22615,6 +23243,7 @@ module Io
|
|
22615
23243
|
:organization => organization,
|
22616
23244
|
:environment => environment.value,
|
22617
23245
|
:attributes => attributes,
|
23246
|
+
:ip => ip,
|
22618
23247
|
:local => local.nil? ? nil : local.to_hash,
|
22619
23248
|
:shop => shop,
|
22620
23249
|
:cart => cart.to_hash,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: flowcommerce
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Flow Commerce, Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04-
|
11
|
+
date: 2017-04-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json
|