flowcommerce 0.2.70 → 0.2.71

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: 344b115ecd577331f251bde2fd751f6e19ac7865
4
- data.tar.gz: 51e7376275bbb8d339d22db3978a77214c57d37a
3
+ metadata.gz: 51f81ace8da1bdfefe2e132fe6c62abac246c843
4
+ data.tar.gz: 69768a0b4baeedb1c3a51bdce1ba4176dd2ec0d0
5
5
  SHA512:
6
- metadata.gz: 24af73699ce2c351483d8c8efb094b6f6eab928abfa52202a283dd17946d17b0a19948849fd57029d1658e4b53002d21f883fdc70a22a57b52b97bddc3b1801d
7
- data.tar.gz: cd69eba2a9db6dbd46afddacd9728419b9ec7e5d22496da3985f74a82523c952d0a8e67c7744f4d3a556ddf642077554b8caf46a04ce16907f4814f86ceecd5c
6
+ metadata.gz: 45c3ab813e97a63ef5f67f1920bd1036db0e55175327697ad2cc9bbd4431b24d621e920ab686580fe2c4701bef4fcf0018911713b3c87291eda310a7d9aeb843
7
+ data.tar.gz: 497245ee7562bceb9f45793c3dfa1e1c0cec162da7543c7991bdd2f404d540b47885c45566df4f429911837f1ebf44fd967abf92b875a548956ba986402a83d7
@@ -1,6 +1,6 @@
1
1
  # Generated by API Builder - https://www.apibuilder.io
2
2
  # Service version: 0.6.19
3
- # apibuilder 0.14.3 app.apibuilder.io/flow/api/0.6.39/ruby_client
3
+ # apibuilder 0.14.3 app.apibuilder.io/flow/api/0.6.43/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 = 'apibuilder 0.14.3 app.apibuilder.io/flow/api/0.6.39/ruby_client' unless defined?(Constants::USER_AGENT)
28
+ USER_AGENT = 'apibuilder 0.14.3 app.apibuilder.io/flow/api/0.6.43/ruby_client' unless defined?(Constants::USER_AGENT)
29
29
  VERSION = '0.6.19' unless defined?(Constants::VERSION)
30
30
  VERSION_MAJOR = 0 unless defined?(VERSION_MAJOR)
31
31
 
@@ -412,6 +412,10 @@ module Io
412
412
  @feeds ||= ::Io::Flow::V0::Clients::Feeds.new(self)
413
413
  end
414
414
 
415
+ def flow_roles
416
+ @flow_roles ||= ::Io::Flow::V0::Clients::FlowRoles.new(self)
417
+ end
418
+
415
419
  def fulfillments
416
420
  @fulfillments ||= ::Io::Flow::V0::Clients::Fulfillments.new(self)
417
421
  end
@@ -460,6 +464,14 @@ module Io
460
464
  @password_reset_forms ||= ::Io::Flow::V0::Clients::PasswordResetForms.new(self)
461
465
  end
462
466
 
467
+ def permission_audits
468
+ @permission_audits ||= ::Io::Flow::V0::Clients::PermissionAudits.new(self)
469
+ end
470
+
471
+ def permission_checks
472
+ @permission_checks ||= ::Io::Flow::V0::Clients::PermissionChecks.new(self)
473
+ end
474
+
463
475
  def scheduled_exports
464
476
  @scheduled_exports ||= ::Io::Flow::V0::Clients::ScheduledExports.new(self)
465
477
  end
@@ -5338,6 +5350,28 @@ module Io
5338
5350
 
5339
5351
  end
5340
5352
 
5353
+ class FlowRoles
5354
+
5355
+ def initialize(client)
5356
+ @client = HttpClient::Preconditions.assert_class('client', client, ::Io::Flow::V0::Client)
5357
+ end
5358
+
5359
+ # List roles in use by this organization.
5360
+ def get_organization_and_roles_by_organization(organization)
5361
+ HttpClient::Preconditions.assert_class('organization', organization, String)
5362
+ r = @client.request("/permission/organization/#{CGI.escape(organization)}/roles").get
5363
+ r.map { |x| ::Io::Flow::V0::Models::FlowRole.from_json(x) }
5364
+ end
5365
+
5366
+ # List roles in use by this partner.
5367
+ def get_partners_and_roles_by_partner(partner)
5368
+ HttpClient::Preconditions.assert_class('partner', partner, String)
5369
+ r = @client.request("/permission/partners/#{CGI.escape(partner)}/roles").get
5370
+ r.map { |x| ::Io::Flow::V0::Models::FlowRole.from_json(x) }
5371
+ end
5372
+
5373
+ end
5374
+
5341
5375
  class Fulfillments
5342
5376
 
5343
5377
  def initialize(client)
@@ -5774,6 +5808,41 @@ module Io
5774
5808
 
5775
5809
  end
5776
5810
 
5811
+ class PermissionAudits
5812
+
5813
+ def initialize(client)
5814
+ @client = HttpClient::Preconditions.assert_class('client', client, ::Io::Flow::V0::Client)
5815
+ end
5816
+
5817
+ # List all permitted routes and behaviors known to flow, along with the roles
5818
+ # and authentication techniques that could be used to connect to them.
5819
+ def get
5820
+ r = @client.request("/permission/audits").get
5821
+ r.map { |x| ::Io::Flow::V0::Models::FlowRole.from_json(x) }
5822
+ end
5823
+
5824
+ end
5825
+
5826
+ class PermissionChecks
5827
+
5828
+ def initialize(client)
5829
+ @client = HttpClient::Preconditions.assert_class('client', client, ::Io::Flow::V0::Client)
5830
+ end
5831
+
5832
+ # Returns permissions for the specified organization for the current request.
5833
+ # Used by integrators to test headers.
5834
+ def get(incoming={})
5835
+ opts = HttpClient::Helper.symbolize_keys(incoming)
5836
+ query = {
5837
+ :permitted_method => (x = opts.delete(:permitted_method); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::PermittedHttpMethod) ? x : ::Io::Flow::V0::Models::PermittedHttpMethod.apply(x)).value),
5838
+ :path => (x = opts.delete(:path); x.nil? ? nil : HttpClient::Preconditions.assert_class('path', x, String))
5839
+ }.delete_if { |k, v| v.nil? }
5840
+ r = @client.request("/permission/checks/all").with_query(query).get
5841
+ ::Io::Flow::V0::Models::PermissionCheck.new(r)
5842
+ end
5843
+
5844
+ end
5845
+
5777
5846
  class ScheduledExports
5778
5847
 
5779
5848
  def initialize(client)
@@ -6517,6 +6586,66 @@ module Io
6517
6586
 
6518
6587
  end
6519
6588
 
6589
+ class AuthorizationPayloadParameters
6590
+
6591
+ module Types
6592
+ GOOGLE_PAY_AUTHORIZATION_PAYLOAD = 'google_pay_authorization_payload' unless defined?(GOOGLE_PAY_AUTHORIZATION_PAYLOAD)
6593
+ end
6594
+
6595
+ attr_reader :discriminator
6596
+
6597
+ def initialize(incoming={})
6598
+ opts = HttpClient::Helper.symbolize_keys(incoming)
6599
+ HttpClient::Preconditions.require_keys(opts, [:discriminator], 'AuthorizationPayloadParameters')
6600
+ @discriminator = HttpClient::Preconditions.assert_class('discriminator', opts.delete(:discriminator), String)
6601
+ end
6602
+
6603
+ def subtype_to_hash
6604
+ raise 'Cannot serialize an instance of authorization_payload_parameters directly - must use one of the specific types: google_pay_authorization_payload'
6605
+ end
6606
+
6607
+ def to_hash
6608
+ subtype_to_hash.merge(:discriminator => @discriminator)
6609
+ end
6610
+
6611
+ def AuthorizationPayloadParameters.from_json(hash)
6612
+ HttpClient::Preconditions.assert_class('hash', hash, Hash)
6613
+ discriminator = HttpClient::Helper.symbolize_keys(hash)[:discriminator].to_s.strip
6614
+ if discriminator.empty?
6615
+ raise "Union type[authorization_payload_parameters] requires a field named 'discriminator'"
6616
+ end
6617
+ case discriminator
6618
+ when Types::GOOGLE_PAY_AUTHORIZATION_PAYLOAD; GooglePayAuthorizationPayload.new(hash)
6619
+ else AuthorizationPayloadParametersUndefinedType.new(:discriminator => discriminator)
6620
+ end
6621
+ end
6622
+
6623
+ end
6624
+
6625
+ class AuthorizationPayloadParametersUndefinedType < AuthorizationPayloadParameters
6626
+
6627
+ attr_reader :name
6628
+
6629
+ def initialize(incoming={})
6630
+ super(:discriminator => 'undefined_type')
6631
+ opts = HttpClient::Helper.symbolize_keys(incoming)
6632
+ @name = HttpClient::Preconditions.assert_class('name', opts.delete(:discriminator), String)
6633
+ end
6634
+
6635
+ def subtype_to_hash
6636
+ raise 'Unable to serialize undefined type to json'
6637
+ end
6638
+
6639
+ def copy(incoming={})
6640
+ raise 'Operation not supported for undefined type'
6641
+ end
6642
+
6643
+ def to_hash
6644
+ raise 'Operation not supported for undefined type'
6645
+ end
6646
+
6647
+ end
6648
+
6520
6649
  class AvailableFilter
6521
6650
 
6522
6651
  module Types
@@ -7036,6 +7165,8 @@ module Io
7036
7165
  CATALOG_ITEM_DELETED = 'catalog_item_deleted' unless defined?(CATALOG_ITEM_DELETED)
7037
7166
  SUBCATALOG_ITEM_UPSERTED = 'subcatalog_item_upserted' unless defined?(SUBCATALOG_ITEM_UPSERTED)
7038
7167
  SUBCATALOG_ITEM_DELETED = 'subcatalog_item_deleted' unless defined?(SUBCATALOG_ITEM_DELETED)
7168
+ B2B_INVOICE_UPSERTED = 'b2b_invoice_upserted' unless defined?(B2B_INVOICE_UPSERTED)
7169
+ B2B_INVOICE_DELETED = 'b2b_invoice_deleted' unless defined?(B2B_INVOICE_DELETED)
7039
7170
  CONSUMER_INVOICE_UPSERTED = 'consumer_invoice_upserted' unless defined?(CONSUMER_INVOICE_UPSERTED)
7040
7171
  CONSUMER_INVOICE_DELETED = 'consumer_invoice_deleted' unless defined?(CONSUMER_INVOICE_DELETED)
7041
7172
  CREDIT_MEMO_UPSERTED = 'credit_memo_upserted' unless defined?(CREDIT_MEMO_UPSERTED)
@@ -7172,7 +7303,7 @@ module Io
7172
7303
  end
7173
7304
 
7174
7305
  def subtype_to_hash
7175
- raise 'Cannot serialize an instance of event directly - must use one of the specific types: attribute_upserted, attribute_deleted, attribute_upserted_v2, attribute_deleted_v2, catalog_upserted, catalog_deleted, subcatalog_upserted, subcatalog_deleted, catalog_item_upserted, catalog_item_deleted, subcatalog_item_upserted, subcatalog_item_deleted, consumer_invoice_upserted, consumer_invoice_deleted, credit_memo_upserted, credit_memo_deleted, crossdock_shipment_upserted, rate_deleted, rate_upserted, available_promotions_upserted, available_promotions_deleted, available_promotions_upserted_v2, available_promotions_deleted_v2, allocation_deleted_v2, allocation_upserted_v2, currency_format_deleted, currency_format_upserted, experience_deleted, experience_upserted, experience_deleted_v2, experience_upserted_v2, experience_price_book_mapping_deleted, experience_price_book_mapping_upserted, experience_logistics_settings_upserted, experience_logistics_settings_deleted, item_margin_deleted, item_margin_upserted, item_sales_margin_deleted, item_sales_margin_upserted, label_format_deleted, label_format_upserted, order_deleted, order_upserted, order_deleted_v2, order_upserted_v2, order_identifier_deleted, order_identifier_upserted, order_identifier_deleted_v2, order_identifier_upserted_v2, pricing_deleted, pricing_upserted, fraud_status_changed, center_upserted, center_deleted, tier_upserted, tier_deleted, delivery_option_upserted, delivery_option_deleted, shipping_configuration_upserted, shipping_configuration_deleted, tier_upserted_v2, tier_deleted_v2, shipping_lane_upserted, shipping_lane_deleted, hs6_code_upserted, hs6_code_deleted, hs10_code_upserted, hs10_code_deleted, item_origin_upserted, item_origin_deleted, harmonized_item_upserted, harmonized_item_deleted, harmonized_landed_cost_upserted, fully_harmonized_item_upserted, experience_inventory_item_upserted, experience_inventory_item_deleted, rule_upserted, rule_deleted, serial_upserted, serial_deleted, snapshot_upserted, snapshot_deleted, label_upserted, notification_upserted, notification_deleted, manifested_label_upserted, manifested_label_deleted, local_item_upserted, local_item_deleted, membership_upserted, membership_deleted, membership_upserted_v2, membership_deleted_v2, organization_upserted, organization_deleted, organization_upserted_v2, organization_deleted_v2, organization_short_id_upserted, organization_short_id_deleted, authorization_deleted_v2, authorization_status_changed, card_authorization_upserted_v2, online_authorization_upserted_v2, capture_upserted_v2, capture_deleted, card_upserted_v2, card_deleted, payment_upserted, payment_deleted, refund_upserted_v2, refund_capture_upserted_v2, reversal_upserted, reversal_deleted, capture_identifier_upserted, capture_identifier_deleted, refund_identifier_upserted, refund_identifier_deleted, virtual_card_capture_upserted, virtual_card_capture_deleted, virtual_card_refund_upserted, virtual_card_refund_deleted, price_book_upserted, price_book_deleted, price_book_item_upserted, price_book_item_deleted, organization_rates_published, organization_countries_published, organization_ratecard_transit_windows_published, return_upserted, return_deleted, targeting_item_upserted, targeting_item_deleted, targeting_item_deleted_v2, tracking_label_event_upserted'
7306
+ raise 'Cannot serialize an instance of event directly - must use one of the specific types: attribute_upserted, attribute_deleted, attribute_upserted_v2, attribute_deleted_v2, catalog_upserted, catalog_deleted, subcatalog_upserted, subcatalog_deleted, catalog_item_upserted, catalog_item_deleted, subcatalog_item_upserted, subcatalog_item_deleted, b2b_invoice_upserted, b2b_invoice_deleted, consumer_invoice_upserted, consumer_invoice_deleted, credit_memo_upserted, credit_memo_deleted, crossdock_shipment_upserted, rate_deleted, rate_upserted, available_promotions_upserted, available_promotions_deleted, available_promotions_upserted_v2, available_promotions_deleted_v2, allocation_deleted_v2, allocation_upserted_v2, currency_format_deleted, currency_format_upserted, experience_deleted, experience_upserted, experience_deleted_v2, experience_upserted_v2, experience_price_book_mapping_deleted, experience_price_book_mapping_upserted, experience_logistics_settings_upserted, experience_logistics_settings_deleted, item_margin_deleted, item_margin_upserted, item_sales_margin_deleted, item_sales_margin_upserted, label_format_deleted, label_format_upserted, order_deleted, order_upserted, order_deleted_v2, order_upserted_v2, order_identifier_deleted, order_identifier_upserted, order_identifier_deleted_v2, order_identifier_upserted_v2, pricing_deleted, pricing_upserted, fraud_status_changed, center_upserted, center_deleted, tier_upserted, tier_deleted, delivery_option_upserted, delivery_option_deleted, shipping_configuration_upserted, shipping_configuration_deleted, tier_upserted_v2, tier_deleted_v2, shipping_lane_upserted, shipping_lane_deleted, hs6_code_upserted, hs6_code_deleted, hs10_code_upserted, hs10_code_deleted, item_origin_upserted, item_origin_deleted, harmonized_item_upserted, harmonized_item_deleted, harmonized_landed_cost_upserted, fully_harmonized_item_upserted, experience_inventory_item_upserted, experience_inventory_item_deleted, rule_upserted, rule_deleted, serial_upserted, serial_deleted, snapshot_upserted, snapshot_deleted, label_upserted, notification_upserted, notification_deleted, manifested_label_upserted, manifested_label_deleted, local_item_upserted, local_item_deleted, membership_upserted, membership_deleted, membership_upserted_v2, membership_deleted_v2, organization_upserted, organization_deleted, organization_upserted_v2, organization_deleted_v2, organization_short_id_upserted, organization_short_id_deleted, authorization_deleted_v2, authorization_status_changed, card_authorization_upserted_v2, online_authorization_upserted_v2, capture_upserted_v2, capture_deleted, card_upserted_v2, card_deleted, payment_upserted, payment_deleted, refund_upserted_v2, refund_capture_upserted_v2, reversal_upserted, reversal_deleted, capture_identifier_upserted, capture_identifier_deleted, refund_identifier_upserted, refund_identifier_deleted, virtual_card_capture_upserted, virtual_card_capture_deleted, virtual_card_refund_upserted, virtual_card_refund_deleted, price_book_upserted, price_book_deleted, price_book_item_upserted, price_book_item_deleted, organization_rates_published, organization_countries_published, organization_ratecard_transit_windows_published, return_upserted, return_deleted, targeting_item_upserted, targeting_item_deleted, targeting_item_deleted_v2, tracking_label_event_upserted'
7176
7307
  end
7177
7308
 
7178
7309
  def to_hash
@@ -7198,6 +7329,8 @@ module Io
7198
7329
  when Types::CATALOG_ITEM_DELETED; CatalogItemDeleted.new(hash)
7199
7330
  when Types::SUBCATALOG_ITEM_UPSERTED; SubcatalogItemUpserted.new(hash)
7200
7331
  when Types::SUBCATALOG_ITEM_DELETED; SubcatalogItemDeleted.new(hash)
7332
+ when Types::B2B_INVOICE_UPSERTED; B2bInvoiceUpserted.new(hash)
7333
+ when Types::B2B_INVOICE_DELETED; B2bInvoiceDeleted.new(hash)
7201
7334
  when Types::CONSUMER_INVOICE_UPSERTED; ConsumerInvoiceUpserted.new(hash)
7202
7335
  when Types::CONSUMER_INVOICE_DELETED; ConsumerInvoiceDeleted.new(hash)
7203
7336
  when Types::CREDIT_MEMO_UPSERTED; CreditMemoUpserted.new(hash)
@@ -8056,6 +8189,66 @@ module Io
8056
8189
 
8057
8190
  end
8058
8191
 
8192
+ # All roles available to attach to a user.
8193
+ class FlowRole
8194
+
8195
+ module Types
8196
+ FLOW_USER_ROLE = 'flow_user_role' unless defined?(FLOW_USER_ROLE)
8197
+ FLOW_ADDON_ROLE = 'flow_addon_role' unless defined?(FLOW_ADDON_ROLE)
8198
+ end
8199
+
8200
+ attr_reader :__discriminator__
8201
+
8202
+ def initialize(incoming={})
8203
+ opts = HttpClient::Helper.symbolize_keys(incoming)
8204
+ @__discriminator__ = opts[:__discriminator__] ||'flow_role'
8205
+ end
8206
+
8207
+ def subtype_to_hash
8208
+ raise 'Cannot serialize an instance of flow_role directly - must use one of the specific types: flow_user_role, flow_addon_role'
8209
+ end
8210
+
8211
+ def to_hash
8212
+ { @__discriminator__ => subtype_to_hash }
8213
+ end
8214
+
8215
+ def FlowRole.from_json(hash)
8216
+ HttpClient::Preconditions.assert_class('hash', hash, Hash)
8217
+ hash.map do |union_type_name, data|
8218
+ case union_type_name
8219
+ when Types::FLOW_USER_ROLE; FlowUserRole.new(data)
8220
+ when Types::FLOW_ADDON_ROLE; FlowAddonRole.new(data)
8221
+ else FlowRoleUndefinedType.new(:__discriminator__ => union_type_name)
8222
+ end
8223
+ end.first
8224
+ end
8225
+
8226
+ end
8227
+
8228
+ class FlowRoleUndefinedType < FlowRole
8229
+
8230
+ attr_reader :name
8231
+
8232
+ def initialize(incoming={})
8233
+ super(:__discriminator__ => 'undefined_type')
8234
+ opts = HttpClient::Helper.symbolize_keys(incoming)
8235
+ @name = HttpClient::Preconditions.assert_class('name', opts.delete(:__discriminator__), String)
8236
+ end
8237
+
8238
+ def subtype_to_hash
8239
+ raise 'Unable to serialize undefined type to json'
8240
+ end
8241
+
8242
+ def copy(incoming={})
8243
+ raise 'Operation not supported for undefined type'
8244
+ end
8245
+
8246
+ def to_hash
8247
+ raise 'Operation not supported for undefined type'
8248
+ end
8249
+
8250
+ end
8251
+
8059
8252
  class GatewayAuthenticationData
8060
8253
 
8061
8254
  module Types
@@ -9996,6 +10189,62 @@ module Io
9996
10189
 
9997
10190
  end
9998
10191
 
10192
+ class AuthenticationTechnique
10193
+
10194
+ attr_reader :value
10195
+
10196
+ def initialize(value)
10197
+ @value = HttpClient::Preconditions.assert_class('value', value, String)
10198
+ end
10199
+
10200
+ # Returns the instance of AuthenticationTechnique for this value, creating a new instance for an unknown value
10201
+ def AuthenticationTechnique.apply(value)
10202
+ if value.instance_of?(AuthenticationTechnique)
10203
+ value
10204
+ else
10205
+ HttpClient::Preconditions.assert_class_or_nil('value', value, String)
10206
+ value.nil? ? nil : (from_string(value) || AuthenticationTechnique.new(value))
10207
+ end
10208
+ end
10209
+
10210
+ # Returns the instance of AuthenticationTechnique for this value, or nil if not found
10211
+ def AuthenticationTechnique.from_string(value)
10212
+ HttpClient::Preconditions.assert_class('value', value, String)
10213
+ AuthenticationTechnique.ALL.find { |v| v.value == value }
10214
+ end
10215
+
10216
+ def AuthenticationTechnique.ALL
10217
+ @@all ||= [AuthenticationTechnique.anonymous, AuthenticationTechnique.session, AuthenticationTechnique.token, AuthenticationTechnique.user]
10218
+ end
10219
+
10220
+ # No authentication necessary.
10221
+ def AuthenticationTechnique.anonymous
10222
+ @@_anonymous ||= AuthenticationTechnique.new('anonymous')
10223
+ end
10224
+
10225
+ # A browser has been assigned an identifier by flow to track their use of our
10226
+ # service for an organization.
10227
+ def AuthenticationTechnique.session
10228
+ @@_session ||= AuthenticationTechnique.new('session')
10229
+ end
10230
+
10231
+ # A token. Tokens carry the same permissions as the user who originally created
10232
+ # them.
10233
+ def AuthenticationTechnique.token
10234
+ @@_token ||= AuthenticationTechnique.new('token')
10235
+ end
10236
+
10237
+ # A user logs into Flow.
10238
+ def AuthenticationTechnique.user
10239
+ @@_user ||= AuthenticationTechnique.new('user')
10240
+ end
10241
+
10242
+ def to_hash
10243
+ value
10244
+ end
10245
+
10246
+ end
10247
+
9999
10248
  class AuthorizationDeclineCode
10000
10249
 
10001
10250
  attr_reader :value
@@ -11691,7 +11940,7 @@ module Io
11691
11940
  end
11692
11941
 
11693
11942
  def EventType.ALL
11694
- @@all ||= [EventType.attribute_upserted, EventType.attribute_deleted, EventType.attribute_upserted_v2, EventType.attribute_deleted_v2, EventType.catalog_upserted, EventType.catalog_deleted, EventType.subcatalog_upserted, EventType.subcatalog_deleted, EventType.catalog_item_upserted, EventType.catalog_item_deleted, EventType.subcatalog_item_upserted, EventType.subcatalog_item_deleted, EventType.consumer_invoice_upserted, EventType.consumer_invoice_deleted, EventType.credit_memo_upserted, EventType.credit_memo_deleted, EventType.crossdock_shipment_upserted, EventType.rate_deleted, EventType.rate_upserted, EventType.available_promotions_upserted, EventType.available_promotions_deleted, EventType.available_promotions_upserted_v2, EventType.available_promotions_deleted_v2, EventType.allocation_deleted_v2, EventType.allocation_upserted_v2, EventType.currency_format_deleted, EventType.currency_format_upserted, EventType.experience_deleted, EventType.experience_upserted, EventType.experience_deleted_v2, EventType.experience_upserted_v2, EventType.experience_price_book_mapping_deleted, EventType.experience_price_book_mapping_upserted, EventType.experience_logistics_settings_upserted, EventType.experience_logistics_settings_deleted, EventType.item_margin_deleted, EventType.item_margin_upserted, EventType.item_sales_margin_deleted, EventType.item_sales_margin_upserted, EventType.label_format_deleted, EventType.label_format_upserted, EventType.order_deleted, EventType.order_upserted, EventType.order_deleted_v2, EventType.order_upserted_v2, EventType.order_identifier_deleted, EventType.order_identifier_upserted, EventType.order_identifier_deleted_v2, EventType.order_identifier_upserted_v2, EventType.pricing_deleted, EventType.pricing_upserted, EventType.fraud_status_changed, EventType.center_upserted, EventType.center_deleted, EventType.tier_upserted, EventType.tier_deleted, EventType.delivery_option_upserted, EventType.delivery_option_deleted, EventType.shipping_configuration_upserted, EventType.shipping_configuration_deleted, EventType.tier_upserted_v2, EventType.tier_deleted_v2, EventType.shipping_lane_upserted, EventType.shipping_lane_deleted, EventType.hs6_code_upserted, EventType.hs6_code_deleted, EventType.hs10_code_upserted, EventType.hs10_code_deleted, EventType.item_origin_upserted, EventType.item_origin_deleted, EventType.harmonized_item_upserted, EventType.harmonized_item_deleted, EventType.harmonized_landed_cost_upserted, EventType.fully_harmonized_item_upserted, EventType.experience_inventory_item_upserted, EventType.experience_inventory_item_deleted, EventType.rule_upserted, EventType.rule_deleted, EventType.serial_upserted, EventType.serial_deleted, EventType.snapshot_upserted, EventType.snapshot_deleted, EventType.label_upserted, EventType.notification_upserted, EventType.notification_deleted, EventType.manifested_label_upserted, EventType.manifested_label_deleted, EventType.local_item_upserted, EventType.local_item_deleted, EventType.membership_upserted, EventType.membership_deleted, EventType.membership_upserted_v2, EventType.membership_deleted_v2, EventType.organization_upserted, EventType.organization_deleted, EventType.organization_upserted_v2, EventType.organization_deleted_v2, EventType.organization_short_id_upserted, EventType.organization_short_id_deleted, EventType.authorization_deleted_v2, EventType.authorization_status_changed, EventType.card_authorization_upserted_v2, EventType.online_authorization_upserted_v2, EventType.capture_upserted_v2, EventType.capture_deleted, EventType.card_upserted_v2, EventType.card_deleted, EventType.payment_upserted, EventType.payment_deleted, EventType.refund_upserted_v2, EventType.refund_capture_upserted_v2, EventType.reversal_upserted, EventType.reversal_deleted, EventType.capture_identifier_upserted, EventType.capture_identifier_deleted, EventType.refund_identifier_upserted, EventType.refund_identifier_deleted, EventType.virtual_card_capture_upserted, EventType.virtual_card_capture_deleted, EventType.virtual_card_refund_upserted, EventType.virtual_card_refund_deleted, EventType.price_book_upserted, EventType.price_book_deleted, EventType.price_book_item_upserted, EventType.price_book_item_deleted, EventType.organization_rates_published, EventType.organization_countries_published, EventType.organization_ratecard_transit_windows_published, EventType.return_upserted, EventType.return_deleted, EventType.targeting_item_upserted, EventType.targeting_item_deleted, EventType.targeting_item_deleted_v2, EventType.tracking_label_event_upserted]
11943
+ @@all ||= [EventType.attribute_upserted, EventType.attribute_deleted, EventType.attribute_upserted_v2, EventType.attribute_deleted_v2, EventType.catalog_upserted, EventType.catalog_deleted, EventType.subcatalog_upserted, EventType.subcatalog_deleted, EventType.catalog_item_upserted, EventType.catalog_item_deleted, EventType.subcatalog_item_upserted, EventType.subcatalog_item_deleted, EventType.b2b_invoice_upserted, EventType.b2b_invoice_deleted, EventType.consumer_invoice_upserted, EventType.consumer_invoice_deleted, EventType.credit_memo_upserted, EventType.credit_memo_deleted, EventType.crossdock_shipment_upserted, EventType.rate_deleted, EventType.rate_upserted, EventType.available_promotions_upserted, EventType.available_promotions_deleted, EventType.available_promotions_upserted_v2, EventType.available_promotions_deleted_v2, EventType.allocation_deleted_v2, EventType.allocation_upserted_v2, EventType.currency_format_deleted, EventType.currency_format_upserted, EventType.experience_deleted, EventType.experience_upserted, EventType.experience_deleted_v2, EventType.experience_upserted_v2, EventType.experience_price_book_mapping_deleted, EventType.experience_price_book_mapping_upserted, EventType.experience_logistics_settings_upserted, EventType.experience_logistics_settings_deleted, EventType.item_margin_deleted, EventType.item_margin_upserted, EventType.item_sales_margin_deleted, EventType.item_sales_margin_upserted, EventType.label_format_deleted, EventType.label_format_upserted, EventType.order_deleted, EventType.order_upserted, EventType.order_deleted_v2, EventType.order_upserted_v2, EventType.order_identifier_deleted, EventType.order_identifier_upserted, EventType.order_identifier_deleted_v2, EventType.order_identifier_upserted_v2, EventType.pricing_deleted, EventType.pricing_upserted, EventType.fraud_status_changed, EventType.center_upserted, EventType.center_deleted, EventType.tier_upserted, EventType.tier_deleted, EventType.delivery_option_upserted, EventType.delivery_option_deleted, EventType.shipping_configuration_upserted, EventType.shipping_configuration_deleted, EventType.tier_upserted_v2, EventType.tier_deleted_v2, EventType.shipping_lane_upserted, EventType.shipping_lane_deleted, EventType.hs6_code_upserted, EventType.hs6_code_deleted, EventType.hs10_code_upserted, EventType.hs10_code_deleted, EventType.item_origin_upserted, EventType.item_origin_deleted, EventType.harmonized_item_upserted, EventType.harmonized_item_deleted, EventType.harmonized_landed_cost_upserted, EventType.fully_harmonized_item_upserted, EventType.experience_inventory_item_upserted, EventType.experience_inventory_item_deleted, EventType.rule_upserted, EventType.rule_deleted, EventType.serial_upserted, EventType.serial_deleted, EventType.snapshot_upserted, EventType.snapshot_deleted, EventType.label_upserted, EventType.notification_upserted, EventType.notification_deleted, EventType.manifested_label_upserted, EventType.manifested_label_deleted, EventType.local_item_upserted, EventType.local_item_deleted, EventType.membership_upserted, EventType.membership_deleted, EventType.membership_upserted_v2, EventType.membership_deleted_v2, EventType.organization_upserted, EventType.organization_deleted, EventType.organization_upserted_v2, EventType.organization_deleted_v2, EventType.organization_short_id_upserted, EventType.organization_short_id_deleted, EventType.authorization_deleted_v2, EventType.authorization_status_changed, EventType.card_authorization_upserted_v2, EventType.online_authorization_upserted_v2, EventType.capture_upserted_v2, EventType.capture_deleted, EventType.card_upserted_v2, EventType.card_deleted, EventType.payment_upserted, EventType.payment_deleted, EventType.refund_upserted_v2, EventType.refund_capture_upserted_v2, EventType.reversal_upserted, EventType.reversal_deleted, EventType.capture_identifier_upserted, EventType.capture_identifier_deleted, EventType.refund_identifier_upserted, EventType.refund_identifier_deleted, EventType.virtual_card_capture_upserted, EventType.virtual_card_capture_deleted, EventType.virtual_card_refund_upserted, EventType.virtual_card_refund_deleted, EventType.price_book_upserted, EventType.price_book_deleted, EventType.price_book_item_upserted, EventType.price_book_item_deleted, EventType.organization_rates_published, EventType.organization_countries_published, EventType.organization_ratecard_transit_windows_published, EventType.return_upserted, EventType.return_deleted, EventType.targeting_item_upserted, EventType.targeting_item_deleted, EventType.targeting_item_deleted_v2, EventType.tracking_label_event_upserted]
11695
11944
  end
11696
11945
 
11697
11946
  def EventType.attribute_upserted
@@ -11742,6 +11991,14 @@ module Io
11742
11991
  @@_subcatalog_item_deleted ||= EventType.new('subcatalog_item_deleted')
11743
11992
  end
11744
11993
 
11994
+ def EventType.b2b_invoice_upserted
11995
+ @@_b2b_invoice_upserted ||= EventType.new('b2b_invoice_upserted')
11996
+ end
11997
+
11998
+ def EventType.b2b_invoice_deleted
11999
+ @@_b2b_invoice_deleted ||= EventType.new('b2b_invoice_deleted')
12000
+ end
12001
+
11745
12002
  def EventType.consumer_invoice_upserted
11746
12003
  @@_consumer_invoice_upserted ||= EventType.new('consumer_invoice_upserted')
11747
12004
  end
@@ -12474,6 +12731,96 @@ module Io
12474
12731
 
12475
12732
  end
12476
12733
 
12734
+ class FlowAddonRole < FlowRole
12735
+
12736
+ attr_reader :value
12737
+
12738
+ def initialize(value)
12739
+ super(:name => FlowRole::Types::FLOW_ADDON_ROLE, :__discriminator__ => 'flow_addon_role')
12740
+ @value = HttpClient::Preconditions.assert_class('value', value, String)
12741
+ end
12742
+
12743
+ # Returns the instance of FlowAddonRole for this value, creating a new instance for an unknown value
12744
+ def FlowAddonRole.apply(value)
12745
+ if value.instance_of?(FlowAddonRole)
12746
+ value
12747
+ else
12748
+ HttpClient::Preconditions.assert_class_or_nil('value', value, String)
12749
+ value.nil? ? nil : (from_string(value) || FlowAddonRole.new(value))
12750
+ end
12751
+ end
12752
+
12753
+ # Returns the instance of FlowAddonRole for this value, or nil if not found
12754
+ def FlowAddonRole.from_string(value)
12755
+ HttpClient::Preconditions.assert_class('value', value, String)
12756
+ FlowAddonRole.ALL.find { |v| v.value == value }
12757
+ end
12758
+
12759
+ def FlowAddonRole.ALL
12760
+ @@all ||= [FlowAddonRole.consumer_data_viewer, FlowAddonRole.membership_manager, FlowAddonRole.flow_operations]
12761
+ end
12762
+
12763
+ # Can view consumer's private data
12764
+ def FlowAddonRole.consumer_data_viewer
12765
+ @@_consumer_data_viewer ||= FlowAddonRole.new('consumer_data_viewer')
12766
+ end
12767
+
12768
+ # Can invite new users to the org.
12769
+ def FlowAddonRole.membership_manager
12770
+ @@_membership_manager ||= FlowAddonRole.new('membership_manager')
12771
+ end
12772
+
12773
+ # User works at Flow and can perform additional backend functions for an
12774
+ # organization.
12775
+ def FlowAddonRole.flow_operations
12776
+ @@_flow_operations ||= FlowAddonRole.new('flow_operations')
12777
+ end
12778
+
12779
+ def subtype_to_hash
12780
+ value
12781
+ end
12782
+
12783
+ end
12784
+
12785
+ class FlowBehavior
12786
+
12787
+ attr_reader :value
12788
+
12789
+ def initialize(value)
12790
+ @value = HttpClient::Preconditions.assert_class('value', value, String)
12791
+ end
12792
+
12793
+ # Returns the instance of FlowBehavior for this value, creating a new instance for an unknown value
12794
+ def FlowBehavior.apply(value)
12795
+ if value.instance_of?(FlowBehavior)
12796
+ value
12797
+ else
12798
+ HttpClient::Preconditions.assert_class_or_nil('value', value, String)
12799
+ value.nil? ? nil : (from_string(value) || FlowBehavior.new(value))
12800
+ end
12801
+ end
12802
+
12803
+ # Returns the instance of FlowBehavior for this value, or nil if not found
12804
+ def FlowBehavior.from_string(value)
12805
+ HttpClient::Preconditions.assert_class('value', value, String)
12806
+ FlowBehavior.ALL.find { |v| v.value == value }
12807
+ end
12808
+
12809
+ def FlowBehavior.ALL
12810
+ @@all ||= [FlowBehavior.view_consumer_data]
12811
+ end
12812
+
12813
+ # Allows user to view consumers' personal data.
12814
+ def FlowBehavior.view_consumer_data
12815
+ @@_view_consumer_data ||= FlowBehavior.new('view_consumer_data')
12816
+ end
12817
+
12818
+ def to_hash
12819
+ value
12820
+ end
12821
+
12822
+ end
12823
+
12477
12824
  class FlowFieldName
12478
12825
 
12479
12826
  attr_reader :value
@@ -12523,6 +12870,61 @@ module Io
12523
12870
 
12524
12871
  end
12525
12872
 
12873
+ class FlowUserRole < FlowRole
12874
+
12875
+ attr_reader :value
12876
+
12877
+ def initialize(value)
12878
+ super(:name => FlowRole::Types::FLOW_USER_ROLE, :__discriminator__ => 'flow_user_role')
12879
+ @value = HttpClient::Preconditions.assert_class('value', value, String)
12880
+ end
12881
+
12882
+ # Returns the instance of FlowUserRole for this value, creating a new instance for an unknown value
12883
+ def FlowUserRole.apply(value)
12884
+ if value.instance_of?(FlowUserRole)
12885
+ value
12886
+ else
12887
+ HttpClient::Preconditions.assert_class_or_nil('value', value, String)
12888
+ value.nil? ? nil : (from_string(value) || FlowUserRole.new(value))
12889
+ end
12890
+ end
12891
+
12892
+ # Returns the instance of FlowUserRole for this value, or nil if not found
12893
+ def FlowUserRole.from_string(value)
12894
+ HttpClient::Preconditions.assert_class('value', value, String)
12895
+ FlowUserRole.ALL.find { |v| v.value == value }
12896
+ end
12897
+
12898
+ def FlowUserRole.ALL
12899
+ @@all ||= [FlowUserRole.organization_admin, FlowUserRole.organization_merchant, FlowUserRole.organization_operations, FlowUserRole.partner_operations]
12900
+ end
12901
+
12902
+ # Can fully administrate a merchant organization.
12903
+ def FlowUserRole.organization_admin
12904
+ @@_organization_admin ||= FlowUserRole.new('organization_admin')
12905
+ end
12906
+
12907
+ # Can access merchant functions such as analytics, billing, experiences.
12908
+ def FlowUserRole.organization_merchant
12909
+ @@_organization_merchant ||= FlowUserRole.new('organization_merchant')
12910
+ end
12911
+
12912
+ # Can access customer service functions and retreive relevant data.
12913
+ def FlowUserRole.organization_operations
12914
+ @@_organization_operations ||= FlowUserRole.new('organization_operations')
12915
+ end
12916
+
12917
+ # Can operate a partner (distribution center) account with Flow.
12918
+ def FlowUserRole.partner_operations
12919
+ @@_partner_operations ||= FlowUserRole.new('partner_operations')
12920
+ end
12921
+
12922
+ def subtype_to_hash
12923
+ value
12924
+ end
12925
+
12926
+ end
12927
+
12526
12928
  class FraudLiability
12527
12929
 
12528
12930
  attr_reader :value
@@ -14442,6 +14844,60 @@ module Io
14442
14844
 
14443
14845
  end
14444
14846
 
14847
+ class PermittedHttpMethod
14848
+
14849
+ attr_reader :value
14850
+
14851
+ def initialize(value)
14852
+ @value = HttpClient::Preconditions.assert_class('value', value, String)
14853
+ end
14854
+
14855
+ # Returns the instance of PermittedHttpMethod for this value, creating a new instance for an unknown value
14856
+ def PermittedHttpMethod.apply(value)
14857
+ if value.instance_of?(PermittedHttpMethod)
14858
+ value
14859
+ else
14860
+ HttpClient::Preconditions.assert_class_or_nil('value', value, String)
14861
+ value.nil? ? nil : (from_string(value) || PermittedHttpMethod.new(value))
14862
+ end
14863
+ end
14864
+
14865
+ # Returns the instance of PermittedHttpMethod for this value, or nil if not found
14866
+ def PermittedHttpMethod.from_string(value)
14867
+ HttpClient::Preconditions.assert_class('value', value, String)
14868
+ PermittedHttpMethod.ALL.find { |v| v.value == value }
14869
+ end
14870
+
14871
+ def PermittedHttpMethod.ALL
14872
+ @@all ||= [PermittedHttpMethod.get, PermittedHttpMethod.post, PermittedHttpMethod.put, PermittedHttpMethod.delete, PermittedHttpMethod.patch]
14873
+ end
14874
+
14875
+ def PermittedHttpMethod.get
14876
+ @@_get ||= PermittedHttpMethod.new('GET')
14877
+ end
14878
+
14879
+ def PermittedHttpMethod.post
14880
+ @@_post ||= PermittedHttpMethod.new('POST')
14881
+ end
14882
+
14883
+ def PermittedHttpMethod.put
14884
+ @@_put ||= PermittedHttpMethod.new('PUT')
14885
+ end
14886
+
14887
+ def PermittedHttpMethod.delete
14888
+ @@_delete ||= PermittedHttpMethod.new('DELETE')
14889
+ end
14890
+
14891
+ def PermittedHttpMethod.patch
14892
+ @@_patch ||= PermittedHttpMethod.new('PATCH')
14893
+ end
14894
+
14895
+ def to_hash
14896
+ value
14897
+ end
14898
+
14899
+ end
14900
+
14445
14901
  class PriceBookStatus
14446
14902
 
14447
14903
  attr_reader :value
@@ -17866,6 +18322,33 @@ module Io
17866
18322
 
17867
18323
  end
17868
18324
 
18325
+ # Used to complete an inline authorization like Google Pay or Apple Pay.
18326
+ class AuthorizationPayload
18327
+
18328
+ attr_reader :parameters
18329
+
18330
+ def initialize(incoming={})
18331
+ opts = HttpClient::Helper.symbolize_keys(incoming)
18332
+ HttpClient::Preconditions.require_keys(opts, [:parameters], 'AuthorizationPayload')
18333
+ @parameters = (x = opts.delete(:parameters); x.is_a?(::Io::Flow::V0::Models::AuthorizationPayloadParameters) ? x : ::Io::Flow::V0::Models::AuthorizationPayloadParameters.from_json(x))
18334
+ end
18335
+
18336
+ def to_json
18337
+ JSON.dump(to_hash)
18338
+ end
18339
+
18340
+ def copy(incoming={})
18341
+ AuthorizationPayload.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
18342
+ end
18343
+
18344
+ def to_hash
18345
+ {
18346
+ :parameters => parameters.to_hash
18347
+ }
18348
+ end
18349
+
18350
+ end
18351
+
17869
18352
  class AuthorizationReference
17870
18353
 
17871
18354
  attr_reader :id, :key, :order
@@ -18333,11 +18816,11 @@ module Io
18333
18816
  # (e.g. Flow purchasing inventory to resell to a consumer).
18334
18817
  class B2bInvoice
18335
18818
 
18336
- attr_reader :id, :buyer, :seller, :status, :date, :key, :order, :economic_title_location, :center, :destination, :lines, :documents, :attributes
18819
+ attr_reader :id, :buyer, :seller, :status, :date, :key, :order, :economic_title_location, :center, :destination, :tax, :lines, :documents, :attributes
18337
18820
 
18338
18821
  def initialize(incoming={})
18339
18822
  opts = HttpClient::Helper.symbolize_keys(incoming)
18340
- HttpClient::Preconditions.require_keys(opts, [:id, :buyer, :seller, :status, :date, :key, :order, :economic_title_location, :lines, :documents, :attributes], 'B2bInvoice')
18823
+ HttpClient::Preconditions.require_keys(opts, [:id, :buyer, :seller, :status, :date, :key, :order, :economic_title_location, :tax, :lines, :documents, :attributes], 'B2bInvoice')
18341
18824
  @id = HttpClient::Preconditions.assert_class('id', opts.delete(:id), String)
18342
18825
  @buyer = (x = opts.delete(:buyer); x.is_a?(::Io::Flow::V0::Models::MerchantOfRecordEntity) ? x : ::Io::Flow::V0::Models::MerchantOfRecordEntity.new(x))
18343
18826
  @seller = (x = opts.delete(:seller); x.is_a?(::Io::Flow::V0::Models::MerchantOfRecordEntity) ? x : ::Io::Flow::V0::Models::MerchantOfRecordEntity.new(x))
@@ -18348,6 +18831,7 @@ module Io
18348
18831
  @economic_title_location = HttpClient::Preconditions.assert_class('economic_title_location', opts.delete(:economic_title_location), String)
18349
18832
  @center = (x = opts.delete(:center); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::ConsumerInvoiceCenterReference) ? x : ::Io::Flow::V0::Models::ConsumerInvoiceCenterReference.new(x)))
18350
18833
  @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)))
18834
+ @tax = (x = opts.delete(:tax); x.is_a?(::Io::Flow::V0::Models::Money) ? x : ::Io::Flow::V0::Models::Money.new(x))
18351
18835
  @lines = HttpClient::Preconditions.assert_class('lines', opts.delete(:lines), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::ConsumerInvoiceLine) ? x : ::Io::Flow::V0::Models::ConsumerInvoiceLine.from_json(x)) }
18352
18836
  @documents = HttpClient::Preconditions.assert_class('documents', opts.delete(:documents), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::ConsumerInvoiceDocument) ? x : ::Io::Flow::V0::Models::ConsumerInvoiceDocument.new(x)) }
18353
18837
  @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 }
@@ -18373,6 +18857,7 @@ module Io
18373
18857
  :economic_title_location => economic_title_location,
18374
18858
  :center => center.nil? ? nil : center.to_hash,
18375
18859
  :destination => destination.nil? ? nil : destination.to_hash,
18860
+ :tax => tax.to_hash,
18376
18861
  :lines => lines.map { |o| o.to_hash },
18377
18862
  :documents => documents.map { |o| o.to_hash },
18378
18863
  :attributes => attributes
@@ -18381,6 +18866,102 @@ module Io
18381
18866
 
18382
18867
  end
18383
18868
 
18869
+ class B2bInvoiceDeleted < Event
18870
+
18871
+ attr_reader :event_id, :timestamp, :organization, :b2b_invoice
18872
+
18873
+ def initialize(incoming={})
18874
+ super(:discriminator => Event::Types::B2B_INVOICE_DELETED)
18875
+ opts = HttpClient::Helper.symbolize_keys(incoming)
18876
+ HttpClient::Preconditions.require_keys(opts, [:event_id, :timestamp, :organization, :b2b_invoice], 'B2bInvoiceDeleted')
18877
+ @event_id = HttpClient::Preconditions.assert_class('event_id', opts.delete(:event_id), String)
18878
+ @timestamp = HttpClient::Preconditions.assert_class('timestamp', HttpClient::Helper.to_date_time_iso8601(opts.delete(:timestamp)), DateTime)
18879
+ @organization = HttpClient::Preconditions.assert_class('organization', opts.delete(:organization), String)
18880
+ @b2b_invoice = (x = opts.delete(:b2b_invoice); x.is_a?(::Io::Flow::V0::Models::B2bInvoice) ? x : ::Io::Flow::V0::Models::B2bInvoice.new(x))
18881
+ end
18882
+
18883
+ def to_json
18884
+ JSON.dump(to_hash)
18885
+ end
18886
+
18887
+ def copy(incoming={})
18888
+ B2bInvoiceDeleted.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
18889
+ end
18890
+
18891
+ def subtype_to_hash
18892
+ {
18893
+ :event_id => event_id,
18894
+ :timestamp => timestamp,
18895
+ :organization => organization,
18896
+ :b2b_invoice => b2b_invoice.to_hash
18897
+ }
18898
+ end
18899
+
18900
+ end
18901
+
18902
+ class B2bInvoiceUpserted < Event
18903
+
18904
+ attr_reader :event_id, :timestamp, :organization, :b2b_invoice
18905
+
18906
+ def initialize(incoming={})
18907
+ super(:discriminator => Event::Types::B2B_INVOICE_UPSERTED)
18908
+ opts = HttpClient::Helper.symbolize_keys(incoming)
18909
+ HttpClient::Preconditions.require_keys(opts, [:event_id, :timestamp, :organization, :b2b_invoice], 'B2bInvoiceUpserted')
18910
+ @event_id = HttpClient::Preconditions.assert_class('event_id', opts.delete(:event_id), String)
18911
+ @timestamp = HttpClient::Preconditions.assert_class('timestamp', HttpClient::Helper.to_date_time_iso8601(opts.delete(:timestamp)), DateTime)
18912
+ @organization = HttpClient::Preconditions.assert_class('organization', opts.delete(:organization), String)
18913
+ @b2b_invoice = (x = opts.delete(:b2b_invoice); x.is_a?(::Io::Flow::V0::Models::B2bInvoice) ? x : ::Io::Flow::V0::Models::B2bInvoice.new(x))
18914
+ end
18915
+
18916
+ def to_json
18917
+ JSON.dump(to_hash)
18918
+ end
18919
+
18920
+ def copy(incoming={})
18921
+ B2bInvoiceUpserted.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
18922
+ end
18923
+
18924
+ def subtype_to_hash
18925
+ {
18926
+ :event_id => event_id,
18927
+ :timestamp => timestamp,
18928
+ :organization => organization,
18929
+ :b2b_invoice => b2b_invoice.to_hash
18930
+ }
18931
+ end
18932
+
18933
+ end
18934
+
18935
+ class BehaviorAudit
18936
+
18937
+ attr_reader :behavior, :authentication_techniques, :roles
18938
+
18939
+ def initialize(incoming={})
18940
+ opts = HttpClient::Helper.symbolize_keys(incoming)
18941
+ HttpClient::Preconditions.require_keys(opts, [:behavior, :authentication_techniques, :roles], 'BehaviorAudit')
18942
+ @behavior = (x = opts.delete(:behavior); x.is_a?(::Io::Flow::V0::Models::FlowBehavior) ? x : ::Io::Flow::V0::Models::FlowBehavior.apply(x))
18943
+ @authentication_techniques = HttpClient::Preconditions.assert_class('authentication_techniques', opts.delete(:authentication_techniques), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::AuthenticationTechnique) ? x : ::Io::Flow::V0::Models::AuthenticationTechnique.apply(x)) }
18944
+ @roles = HttpClient::Preconditions.assert_class('roles', opts.delete(:roles), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) }
18945
+ end
18946
+
18947
+ def to_json
18948
+ JSON.dump(to_hash)
18949
+ end
18950
+
18951
+ def copy(incoming={})
18952
+ BehaviorAudit.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
18953
+ end
18954
+
18955
+ def to_hash
18956
+ {
18957
+ :behavior => behavior.value,
18958
+ :authentication_techniques => authentication_techniques.map { |o| o.value },
18959
+ :roles => roles.map { |o| o.to_hash }
18960
+ }
18961
+ end
18962
+
18963
+ end
18964
+
18384
18965
  class BillingAddress
18385
18966
 
18386
18967
  attr_reader :name, :streets, :city, :province, :postal, :country, :company
@@ -24677,6 +25258,33 @@ module Io
24677
25258
 
24678
25259
  end
24679
25260
 
25261
+ class GooglePayAuthorizationPayload < AuthorizationPayloadParameters
25262
+
25263
+ attr_reader :payload
25264
+
25265
+ def initialize(incoming={})
25266
+ super(:discriminator => AuthorizationPayloadParameters::Types::GOOGLE_PAY_AUTHORIZATION_PAYLOAD)
25267
+ opts = HttpClient::Helper.symbolize_keys(incoming)
25268
+ HttpClient::Preconditions.require_keys(opts, [:payload], 'GooglePayAuthorizationPayload')
25269
+ @payload = HttpClient::Preconditions.assert_class('payload', HttpClient::Helper.to_object(opts.delete(:payload)), Hash)
25270
+ end
25271
+
25272
+ def to_json
25273
+ JSON.dump(to_hash)
25274
+ end
25275
+
25276
+ def copy(incoming={})
25277
+ GooglePayAuthorizationPayload.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
25278
+ end
25279
+
25280
+ def subtype_to_hash
25281
+ {
25282
+ :payload => payload
25283
+ }
25284
+ end
25285
+
25286
+ end
25287
+
24680
25288
  class HarmonizationDocument < Document
24681
25289
 
24682
25290
  attr_reader :code, :categories, :origin
@@ -26233,7 +26841,7 @@ module Io
26233
26841
  # Executes a widget-based payment based on the provided payment method.
26234
26842
  class InlineAuthorizationForm < AuthorizationForm
26235
26843
 
26236
- attr_reader :method, :issuer, :order_number, :amount, :currency, :billing_address, :key, :attributes, :ip
26844
+ attr_reader :method, :issuer, :order_number, :amount, :currency, :billing_address, :key, :attributes, :ip, :payload
26237
26845
 
26238
26846
  def initialize(incoming={})
26239
26847
  super(:discriminator => AuthorizationForm::Types::INLINE_AUTHORIZATION_FORM)
@@ -26248,6 +26856,7 @@ module Io
26248
26856
  @key = (x = opts.delete(:key); x.nil? ? nil : HttpClient::Preconditions.assert_class('key', x, String))
26249
26857
  @attributes = (x = opts.delete(:attributes); x.nil? ? nil : HttpClient::Preconditions.assert_class('attributes', x, Hash).inject({}) { |h, d| h[d[0]] = HttpClient::Preconditions.assert_class('attributes', d[1], String); h })
26250
26858
  @ip = (x = opts.delete(:ip); x.nil? ? nil : HttpClient::Preconditions.assert_class('ip', x, String))
26859
+ @payload = (x = opts.delete(:payload); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::AuthorizationPayload) ? x : ::Io::Flow::V0::Models::AuthorizationPayload.new(x)))
26251
26860
  end
26252
26861
 
26253
26862
  def to_json
@@ -26268,7 +26877,8 @@ module Io
26268
26877
  :billing_address => billing_address.nil? ? nil : billing_address.to_hash,
26269
26878
  :key => key,
26270
26879
  :attributes => attributes.nil? ? nil : attributes,
26271
- :ip => ip
26880
+ :ip => ip,
26881
+ :payload => payload.nil? ? nil : payload.to_hash
26272
26882
  }
26273
26883
  end
26274
26884
 
@@ -27053,16 +27663,17 @@ module Io
27053
27663
  # become a member of the organization.
27054
27664
  class Invitation
27055
27665
 
27056
- attr_reader :id, :organization, :email, :name, :role, :expiration
27666
+ attr_reader :id, :organization, :email, :name, :role, :roles, :expiration
27057
27667
 
27058
27668
  def initialize(incoming={})
27059
27669
  opts = HttpClient::Helper.symbolize_keys(incoming)
27060
- HttpClient::Preconditions.require_keys(opts, [:id, :organization, :email, :name, :role, :expiration], 'Invitation')
27670
+ HttpClient::Preconditions.require_keys(opts, [:id, :organization, :email, :name, :expiration], 'Invitation')
27061
27671
  @id = HttpClient::Preconditions.assert_class('id', opts.delete(:id), String)
27062
27672
  @organization = (x = opts.delete(:organization); x.is_a?(::Io::Flow::V0::Models::ExpandableOrganization) ? x : ::Io::Flow::V0::Models::ExpandableOrganization.from_json(x))
27063
27673
  @email = HttpClient::Preconditions.assert_class('email', opts.delete(:email), String)
27064
27674
  @name = (x = opts.delete(:name); x.is_a?(::Io::Flow::V0::Models::Name) ? x : ::Io::Flow::V0::Models::Name.new(x))
27065
- @role = (x = opts.delete(:role); x.is_a?(::Io::Flow::V0::Models::Role) ? x : ::Io::Flow::V0::Models::Role.apply(x))
27675
+ @role = (x = opts.delete(:role); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::Role) ? x : ::Io::Flow::V0::Models::Role.apply(x)))
27676
+ @roles = (x = opts.delete(:roles); x.nil? ? nil : HttpClient::Preconditions.assert_class('roles', x, Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) })
27066
27677
  @expiration = HttpClient::Preconditions.assert_class('expiration', HttpClient::Helper.to_date_time_iso8601(opts.delete(:expiration)), DateTime)
27067
27678
  end
27068
27679
 
@@ -27080,7 +27691,8 @@ module Io
27080
27691
  :organization => organization.to_hash,
27081
27692
  :email => email,
27082
27693
  :name => name.to_hash,
27083
- :role => role.value,
27694
+ :role => role.nil? ? nil : role.value,
27695
+ :roles => roles.nil? ? nil : roles.map { |o| o.to_hash },
27084
27696
  :expiration => expiration
27085
27697
  }
27086
27698
  end
@@ -27118,7 +27730,7 @@ module Io
27118
27730
 
27119
27731
  class InvitationForm
27120
27732
 
27121
- attr_reader :organization, :email, :name, :role
27733
+ attr_reader :organization, :email, :name, :role, :roles
27122
27734
 
27123
27735
  def initialize(incoming={})
27124
27736
  opts = HttpClient::Helper.symbolize_keys(incoming)
@@ -27127,6 +27739,7 @@ module Io
27127
27739
  @email = HttpClient::Preconditions.assert_class('email', opts.delete(:email), String)
27128
27740
  @name = (x = opts.delete(:name); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::Name) ? x : ::Io::Flow::V0::Models::Name.new(x)))
27129
27741
  @role = (x = (x = opts.delete(:role); x.nil? ? "member" : x); x.is_a?(::Io::Flow::V0::Models::Role) ? x : ::Io::Flow::V0::Models::Role.apply(x))
27742
+ @roles = (x = opts.delete(:roles); x.nil? ? nil : HttpClient::Preconditions.assert_class('roles', x, Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) })
27130
27743
  end
27131
27744
 
27132
27745
  def to_json
@@ -27142,7 +27755,8 @@ module Io
27142
27755
  :organization => organization,
27143
27756
  :email => email,
27144
27757
  :name => name.nil? ? nil : name.to_hash,
27145
- :role => role.value
27758
+ :role => role.value,
27759
+ :roles => roles.nil? ? nil : roles.map { |o| o.to_hash }
27146
27760
  }
27147
27761
  end
27148
27762
 
@@ -29378,15 +29992,16 @@ module Io
29378
29992
  # organization
29379
29993
  class Membership
29380
29994
 
29381
- attr_reader :id, :organization, :user, :role
29995
+ attr_reader :id, :organization, :user, :role, :roles
29382
29996
 
29383
29997
  def initialize(incoming={})
29384
29998
  opts = HttpClient::Helper.symbolize_keys(incoming)
29385
- HttpClient::Preconditions.require_keys(opts, [:id, :organization, :user, :role], 'Membership')
29999
+ HttpClient::Preconditions.require_keys(opts, [:id, :organization, :user, :roles], 'Membership')
29386
30000
  @id = HttpClient::Preconditions.assert_class('id', opts.delete(:id), String)
29387
30001
  @organization = (x = opts.delete(:organization); x.is_a?(::Io::Flow::V0::Models::ExpandableOrganization) ? x : ::Io::Flow::V0::Models::ExpandableOrganization.from_json(x))
29388
30002
  @user = (x = opts.delete(:user); x.is_a?(::Io::Flow::V0::Models::ExpandableUser) ? x : ::Io::Flow::V0::Models::ExpandableUser.from_json(x))
29389
- @role = (x = opts.delete(:role); x.is_a?(::Io::Flow::V0::Models::Role) ? x : ::Io::Flow::V0::Models::Role.apply(x))
30003
+ @role = (x = opts.delete(:role); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::Role) ? x : ::Io::Flow::V0::Models::Role.apply(x)))
30004
+ @roles = HttpClient::Preconditions.assert_class('roles', opts.delete(:roles), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) }
29390
30005
  end
29391
30006
 
29392
30007
  def to_json
@@ -29402,7 +30017,8 @@ module Io
29402
30017
  :id => id,
29403
30018
  :organization => organization.to_hash,
29404
30019
  :user => user.to_hash,
29405
- :role => role.value
30020
+ :role => role.nil? ? nil : role.value,
30021
+ :roles => roles.map { |o| o.to_hash }
29406
30022
  }
29407
30023
  end
29408
30024
 
@@ -29473,7 +30089,7 @@ module Io
29473
30089
  # Top level resource to create a membership.
29474
30090
  class MembershipForm
29475
30091
 
29476
- attr_reader :organization, :user, :role
30092
+ attr_reader :organization, :user, :role, :roles
29477
30093
 
29478
30094
  def initialize(incoming={})
29479
30095
  opts = HttpClient::Helper.symbolize_keys(incoming)
@@ -29481,6 +30097,7 @@ module Io
29481
30097
  @organization = HttpClient::Preconditions.assert_class('organization', opts.delete(:organization), String)
29482
30098
  @user = HttpClient::Preconditions.assert_class('user', opts.delete(:user), String)
29483
30099
  @role = (x = (x = opts.delete(:role); x.nil? ? "member" : x); x.is_a?(::Io::Flow::V0::Models::Role) ? x : ::Io::Flow::V0::Models::Role.apply(x))
30100
+ @roles = HttpClient::Preconditions.assert_class('roles', (x = opts.delete(:roles); x.nil? ? [] : x), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) }
29484
30101
  end
29485
30102
 
29486
30103
  def to_json
@@ -29495,20 +30112,22 @@ module Io
29495
30112
  {
29496
30113
  :organization => organization,
29497
30114
  :user => user,
29498
- :role => role.value
30115
+ :role => role.value,
30116
+ :roles => roles.map { |o| o.to_hash }
29499
30117
  }
29500
30118
  end
29501
30119
 
29502
30120
  end
29503
30121
 
29504
- # Top level resource to create a membership.
30122
+ # Top level resource to update a membership.
29505
30123
  class MembershipPutForm
29506
30124
 
29507
- attr_reader :role
30125
+ attr_reader :role, :roles
29508
30126
 
29509
30127
  def initialize(incoming={})
29510
30128
  opts = HttpClient::Helper.symbolize_keys(incoming)
29511
30129
  @role = (x = (x = opts.delete(:role); x.nil? ? "member" : x); x.is_a?(::Io::Flow::V0::Models::Role) ? x : ::Io::Flow::V0::Models::Role.apply(x))
30130
+ @roles = HttpClient::Preconditions.assert_class('roles', (x = opts.delete(:roles); x.nil? ? [] : x), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) }
29512
30131
  end
29513
30132
 
29514
30133
  def to_json
@@ -29521,7 +30140,8 @@ module Io
29521
30140
 
29522
30141
  def to_hash
29523
30142
  {
29524
- :role => role.value
30143
+ :role => role.value,
30144
+ :roles => roles.map { |o| o.to_hash }
29525
30145
  }
29526
30146
  end
29527
30147
 
@@ -33603,6 +34223,134 @@ module Io
33603
34223
 
33604
34224
  end
33605
34225
 
34226
+ # Returns all known permissions, along with their authorization technique and
34227
+ # all of the roles which contain them.
34228
+ class PermissionAudit
34229
+
34230
+ attr_reader :routes, :behaviors
34231
+
34232
+ def initialize(incoming={})
34233
+ opts = HttpClient::Helper.symbolize_keys(incoming)
34234
+ HttpClient::Preconditions.require_keys(opts, [:routes, :behaviors], 'PermissionAudit')
34235
+ @routes = HttpClient::Preconditions.assert_class('routes', opts.delete(:routes), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::RouteAudit) ? x : ::Io::Flow::V0::Models::RouteAudit.new(x)) }
34236
+ @behaviors = HttpClient::Preconditions.assert_class('behaviors', opts.delete(:behaviors), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::BehaviorAudit) ? x : ::Io::Flow::V0::Models::BehaviorAudit.new(x)) }
34237
+ end
34238
+
34239
+ def to_json
34240
+ JSON.dump(to_hash)
34241
+ end
34242
+
34243
+ def copy(incoming={})
34244
+ PermissionAudit.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
34245
+ end
34246
+
34247
+ def to_hash
34248
+ {
34249
+ :routes => routes.map { |o| o.to_hash },
34250
+ :behaviors => behaviors.map { |o| o.to_hash }
34251
+ }
34252
+ end
34253
+
34254
+ end
34255
+
34256
+ # Used to test an integration's permissions, including identifying the
34257
+ # authentication technique that will be used for similar requests.
34258
+ class PermissionCheck
34259
+
34260
+ attr_reader :authentication_technique, :user, :roles, :behaviors, :routes
34261
+
34262
+ def initialize(incoming={})
34263
+ opts = HttpClient::Helper.symbolize_keys(incoming)
34264
+ HttpClient::Preconditions.require_keys(opts, [:authentication_technique, :roles, :behaviors, :routes], 'PermissionCheck')
34265
+ @authentication_technique = (x = opts.delete(:authentication_technique); x.is_a?(::Io::Flow::V0::Models::AuthenticationTechnique) ? x : ::Io::Flow::V0::Models::AuthenticationTechnique.apply(x))
34266
+ @user = (x = opts.delete(:user); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::User) ? x : ::Io::Flow::V0::Models::User.new(x)))
34267
+ @roles = HttpClient::Preconditions.assert_class('roles', opts.delete(:roles), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) }
34268
+ @behaviors = HttpClient::Preconditions.assert_class('behaviors', opts.delete(:behaviors), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowBehavior) ? x : ::Io::Flow::V0::Models::FlowBehavior.apply(x)) }
34269
+ @routes = HttpClient::Preconditions.assert_class('routes', opts.delete(:routes), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::PermittedRoute) ? x : ::Io::Flow::V0::Models::PermittedRoute.new(x)) }
34270
+ end
34271
+
34272
+ def to_json
34273
+ JSON.dump(to_hash)
34274
+ end
34275
+
34276
+ def copy(incoming={})
34277
+ PermissionCheck.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
34278
+ end
34279
+
34280
+ def to_hash
34281
+ {
34282
+ :authentication_technique => authentication_technique.value,
34283
+ :user => user.nil? ? nil : user.to_hash,
34284
+ :roles => roles.map { |o| o.to_hash },
34285
+ :behaviors => behaviors.map { |o| o.value },
34286
+ :routes => routes.map { |o| o.to_hash }
34287
+ }
34288
+ end
34289
+
34290
+ end
34291
+
34292
+ # Returned if no permissions are available for a request.
34293
+ class PermissionError
34294
+
34295
+ attr_reader :code, :messages, :granting_roles, :admin_users
34296
+
34297
+ def initialize(incoming={})
34298
+ opts = HttpClient::Helper.symbolize_keys(incoming)
34299
+ HttpClient::Preconditions.require_keys(opts, [:code, :messages], 'PermissionError')
34300
+ @code = (x = opts.delete(:code); x.is_a?(::Io::Flow::V0::Models::GenericErrorCode) ? x : ::Io::Flow::V0::Models::GenericErrorCode.apply(x))
34301
+ @messages = HttpClient::Preconditions.assert_class('messages', opts.delete(:messages), Array).map { |v| HttpClient::Preconditions.assert_class('messages', v, String) }
34302
+ @granting_roles = (x = opts.delete(:granting_roles); x.nil? ? nil : HttpClient::Preconditions.assert_class('granting_roles', x, Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) })
34303
+ @admin_users = (x = opts.delete(:admin_users); x.nil? ? nil : HttpClient::Preconditions.assert_class('admin_users', x, Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::User) ? x : ::Io::Flow::V0::Models::User.new(x)) })
34304
+ end
34305
+
34306
+ def to_json
34307
+ JSON.dump(to_hash)
34308
+ end
34309
+
34310
+ def copy(incoming={})
34311
+ PermissionError.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
34312
+ end
34313
+
34314
+ def to_hash
34315
+ {
34316
+ :code => code.value,
34317
+ :messages => messages,
34318
+ :granting_roles => granting_roles.nil? ? nil : granting_roles.map { |o| o.to_hash },
34319
+ :admin_users => admin_users.nil? ? nil : admin_users.map { |o| o.to_hash }
34320
+ }
34321
+ end
34322
+
34323
+ end
34324
+
34325
+ # A Flow API route and method.
34326
+ class PermittedRoute
34327
+
34328
+ attr_reader :method, :path
34329
+
34330
+ def initialize(incoming={})
34331
+ opts = HttpClient::Helper.symbolize_keys(incoming)
34332
+ HttpClient::Preconditions.require_keys(opts, [:method, :path], 'PermittedRoute')
34333
+ @method = (x = opts.delete(:method); x.is_a?(::Io::Flow::V0::Models::PermittedHttpMethod) ? x : ::Io::Flow::V0::Models::PermittedHttpMethod.apply(x))
34334
+ @path = HttpClient::Preconditions.assert_class('path', opts.delete(:path), String)
34335
+ end
34336
+
34337
+ def to_json
34338
+ JSON.dump(to_hash)
34339
+ end
34340
+
34341
+ def copy(incoming={})
34342
+ PermittedRoute.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
34343
+ end
34344
+
34345
+ def to_hash
34346
+ {
34347
+ :method => method.value,
34348
+ :path => path
34349
+ }
34350
+ end
34351
+
34352
+ end
34353
+
33606
34354
  class PfsInventoryCheckResponse
33607
34355
 
33608
34356
  attr_reader :items
@@ -33948,7 +34696,7 @@ module Io
33948
34696
  # Represents the price of a single item within a price book.
33949
34697
  class PriceBookItem
33950
34698
 
33951
- attr_reader :id, :key, :price_book, :price, :item_number, :schedule
34699
+ attr_reader :id, :key, :price_book, :price, :item_number, :schedule, :item_attributes
33952
34700
 
33953
34701
  def initialize(incoming={})
33954
34702
  opts = HttpClient::Helper.symbolize_keys(incoming)
@@ -33959,6 +34707,7 @@ module Io
33959
34707
  @price = (x = opts.delete(:price); x.is_a?(::Io::Flow::V0::Models::Price) ? x : ::Io::Flow::V0::Models::Price.new(x))
33960
34708
  @item_number = HttpClient::Preconditions.assert_class('item_number', opts.delete(:item_number), String)
33961
34709
  @schedule = (x = opts.delete(:schedule); x.is_a?(::Io::Flow::V0::Models::PriceBookItemSchedule) ? x : ::Io::Flow::V0::Models::PriceBookItemSchedule.new(x))
34710
+ @item_attributes = (x = opts.delete(:item_attributes); x.nil? ? nil : HttpClient::Preconditions.assert_class('item_attributes', x, Hash).inject({}) { |h, d| h[d[0]] = HttpClient::Preconditions.assert_class('item_attributes', d[1], String); h })
33962
34711
  end
33963
34712
 
33964
34713
  def to_json
@@ -33976,7 +34725,8 @@ module Io
33976
34725
  :price_book => price_book.to_hash,
33977
34726
  :price => price.to_hash,
33978
34727
  :item_number => item_number,
33979
- :schedule => schedule.to_hash
34728
+ :schedule => schedule.to_hash,
34729
+ :item_attributes => item_attributes.nil? ? nil : item_attributes
33980
34730
  }
33981
34731
  end
33982
34732
 
@@ -34018,7 +34768,7 @@ module Io
34018
34768
  # Represents the form to create an item in a pricebook.
34019
34769
  class PriceBookItemForm
34020
34770
 
34021
- attr_reader :price_book_key, :price, :item_number, :schedule
34771
+ attr_reader :price_book_key, :price, :item_number, :schedule, :item_attributes
34022
34772
 
34023
34773
  def initialize(incoming={})
34024
34774
  opts = HttpClient::Helper.symbolize_keys(incoming)
@@ -34027,6 +34777,7 @@ module Io
34027
34777
  @price = (x = opts.delete(:price); x.is_a?(::Io::Flow::V0::Models::Money) ? x : ::Io::Flow::V0::Models::Money.new(x))
34028
34778
  @item_number = HttpClient::Preconditions.assert_class('item_number', opts.delete(:item_number), String)
34029
34779
  @schedule = (x = opts.delete(:schedule); x.is_a?(::Io::Flow::V0::Models::PriceBookItemSchedule) ? x : ::Io::Flow::V0::Models::PriceBookItemSchedule.new(x))
34780
+ @item_attributes = (x = opts.delete(:item_attributes); x.nil? ? nil : HttpClient::Preconditions.assert_class('item_attributes', x, Hash).inject({}) { |h, d| h[d[0]] = HttpClient::Preconditions.assert_class('item_attributes', d[1], String); h })
34030
34781
  end
34031
34782
 
34032
34783
  def to_json
@@ -34042,7 +34793,8 @@ module Io
34042
34793
  :price_book_key => price_book_key,
34043
34794
  :price => price.to_hash,
34044
34795
  :item_number => item_number,
34045
- :schedule => schedule.to_hash
34796
+ :schedule => schedule.to_hash,
34797
+ :item_attributes => item_attributes.nil? ? nil : item_attributes
34046
34798
  }
34047
34799
  end
34048
34800
 
@@ -36753,6 +37505,38 @@ module Io
36753
37505
 
36754
37506
  end
36755
37507
 
37508
+ class RouteAudit
37509
+
37510
+ attr_reader :method, :path, :authentication_techniques, :roles
37511
+
37512
+ def initialize(incoming={})
37513
+ opts = HttpClient::Helper.symbolize_keys(incoming)
37514
+ HttpClient::Preconditions.require_keys(opts, [:method, :path, :authentication_techniques, :roles], 'RouteAudit')
37515
+ @method = (x = opts.delete(:method); x.is_a?(::Io::Flow::V0::Models::PermittedHttpMethod) ? x : ::Io::Flow::V0::Models::PermittedHttpMethod.apply(x))
37516
+ @path = HttpClient::Preconditions.assert_class('path', opts.delete(:path), String)
37517
+ @authentication_techniques = HttpClient::Preconditions.assert_class('authentication_techniques', opts.delete(:authentication_techniques), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::AuthenticationTechnique) ? x : ::Io::Flow::V0::Models::AuthenticationTechnique.apply(x)) }
37518
+ @roles = HttpClient::Preconditions.assert_class('roles', opts.delete(:roles), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowRole) ? x : ::Io::Flow::V0::Models::FlowRole.from_json(x)) }
37519
+ end
37520
+
37521
+ def to_json
37522
+ JSON.dump(to_hash)
37523
+ end
37524
+
37525
+ def copy(incoming={})
37526
+ RouteAudit.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
37527
+ end
37528
+
37529
+ def to_hash
37530
+ {
37531
+ :method => method.value,
37532
+ :path => path,
37533
+ :authentication_techniques => authentication_techniques.map { |o| o.value },
37534
+ :roles => roles.map { |o| o.to_hash }
37535
+ }
37536
+ end
37537
+
37538
+ end
37539
+
36756
37540
  class RuleDeleted < Event
36757
37541
 
36758
37542
  attr_reader :event_id, :timestamp, :id
@@ -39019,6 +39803,34 @@ module Io
39019
39803
 
39020
39804
  end
39021
39805
 
39806
+ # A simple model, used to convey permitted behaviors along with approval of a
39807
+ # request for a specific permitted route.
39808
+ class SimplePermissionCheck
39809
+
39810
+ attr_reader :behaviors
39811
+
39812
+ def initialize(incoming={})
39813
+ opts = HttpClient::Helper.symbolize_keys(incoming)
39814
+ HttpClient::Preconditions.require_keys(opts, [:behaviors], 'SimplePermissionCheck')
39815
+ @behaviors = HttpClient::Preconditions.assert_class('behaviors', opts.delete(:behaviors), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::FlowBehavior) ? x : ::Io::Flow::V0::Models::FlowBehavior.apply(x)) }
39816
+ end
39817
+
39818
+ def to_json
39819
+ JSON.dump(to_hash)
39820
+ end
39821
+
39822
+ def copy(incoming={})
39823
+ SimplePermissionCheck.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
39824
+ end
39825
+
39826
+ def to_hash
39827
+ {
39828
+ :behaviors => behaviors.map { |o| o.value }
39829
+ }
39830
+ end
39831
+
39832
+ end
39833
+
39022
39834
  # Simplified form for notifying Flow of a Fulfillment shipped entirely in a
39023
39835
  # single tracked package.
39024
39836
  class SinglePackageShippingNotificationForm < ShippingNotificationForm
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.70
4
+ version: 0.2.71
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: 2018-09-14 00:00:00.000000000 Z
11
+ date: 2018-09-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json