Class: Io::Flow::V0::Models::ImportType

Inherits:
Object
  • Object
show all
Defined in:
lib/flow_commerce/flow_api_v0_client.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ ImportType

Returns a new instance of ImportType.



21272
21273
21274
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21272

def initialize(value)
  @value = HttpClient::Preconditions.assert_class('value', value, String)
end

Instance Attribute Details

#valueObject (readonly)

Returns the value of attribute value.



21270
21271
21272
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21270

def value
  @value
end

Class Method Details

.ALLObject



21292
21293
21294
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21292

def ImportType.ALL
  @@all ||= [ImportType.catalog_items, ImportType.catalog_items_external, ImportType.customs_descriptions, ImportType.customs_description_tariffs, ImportType.experiences_with_settings, ImportType.harmonization_codes, ImportType.item_prices, ImportType.item_form_overlays, ImportType.price_book_items, ImportType.price_book_items_query, ImportType.ratecard_lanes, ImportType.order_service_changes]
end

.apply(value) ⇒ Object

Returns the instance of ImportType for this value, creating a new instance for an unknown value



21277
21278
21279
21280
21281
21282
21283
21284
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21277

def ImportType.apply(value)
  if value.instance_of?(ImportType)
    value
  else
    HttpClient::Preconditions.assert_class_or_nil('value', value, String)
    value.nil? ? nil : (from_string(value) || ImportType.new(value))
  end
end

.catalog_itemsObject

Provides bulk upsert of items into an organization’s catalog.



21297
21298
21299
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21297

def ImportType.catalog_items
  @@_catalog_items ||= ImportType.new('catalog_items')
end

.catalog_items_externalObject

Provides bulk list of items from an external resource to be upserted into an organization’s catalog.



21303
21304
21305
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21303

def ImportType.catalog_items_external
  @@_catalog_items_external ||= ImportType.new('catalog_items_external')
end

.customs_description_tariffsObject

Provides upload of customs descriptions and corresponding tariffs. These are independent of any catalog, product, or item.



21314
21315
21316
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21314

def ImportType.customs_description_tariffs
  @@_customs_description_tariffs ||= ImportType.new('customs_description_tariffs')
end

.customs_descriptionsObject

Provides upload of customs descriptions for the products in a catalog.



21308
21309
21310
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21308

def ImportType.customs_descriptions
  @@_customs_descriptions ||= ImportType.new('customs_descriptions')
end

.experiences_with_settingsObject

Provides bulk upsert of experiences with associated settings.



21319
21320
21321
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21319

def ImportType.experiences_with_settings
  @@_experiences_with_settings ||= ImportType.new('experiences_with_settings')
end

.from_string(value) ⇒ Object

Returns the instance of ImportType for this value, or nil if not found



21287
21288
21289
21290
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21287

def ImportType.from_string(value)
  HttpClient::Preconditions.assert_class('value', value, String)
  ImportType.ALL.find { |v| v.value == value }
end

.harmonization_codesObject

Provides upload of HS-6 and HS-10 codes for the items in a catalog



21324
21325
21326
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21324

def ImportType.harmonization_codes
  @@_harmonization_codes ||= ImportType.new('harmonization_codes')
end

.item_form_overlaysObject

Item form overlays allow you to upload additional catalog item information that will be applied to each catalog item, even if you later modify the item. You can think of this import as providing catalog item data that will be overlaid on top of the content in your core catalog.



21339
21340
21341
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21339

def ImportType.item_form_overlays
  @@_item_form_overlays ||= ImportType.new('item_form_overlays')
end

.item_pricesObject

Provides bulk upsert of item pricing into an organization’s catalog, updating only the prices and associated price attributes while preserving all other item information.



21331
21332
21333
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21331

def ImportType.item_prices
  @@_item_prices ||= ImportType.new('item_prices')
end

.order_service_changesObject

Provides way to upload service level changes for orders that require updated shipping methods.



21362
21363
21364
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21362

def ImportType.order_service_changes
  @@_order_service_changes ||= ImportType.new('order_service_changes')
end

.price_book_itemsObject

Provides bulk upsert of price book items based on item number.



21344
21345
21346
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21344

def ImportType.price_book_items
  @@_price_book_items ||= ImportType.new('price_book_items')
end

.price_book_items_queryObject

Provides bulk upsert of price book items based on a query (e.g. update all items by sku or product id).



21350
21351
21352
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21350

def ImportType.price_book_items_query
  @@_price_book_items_query ||= ImportType.new('price_book_items_query')
end

.ratecard_lanesObject

Provides way to upload a new ratecard with lanes and rates for a service level.



21356
21357
21358
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21356

def ImportType.ratecard_lanes
  @@_ratecard_lanes ||= ImportType.new('ratecard_lanes')
end

Instance Method Details

#to_hashObject



21366
21367
21368
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21366

def to_hash
  value
end