korona_client 1.0.0 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (309) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +171 -89
  3. data/config.json +6 -0
  4. data/docs/AccountTransaction.md +2 -0
  5. data/docs/AccountsApi.md +12 -12
  6. data/docs/AddOrUpdateResult.md +1 -0
  7. data/docs/AdditionalInfo.md +9 -0
  8. data/docs/AdditionalReceiptInfoType.md +22 -0
  9. data/docs/AdditionalReceiptInfoTypesApi.md +133 -0
  10. data/docs/AssortmentsApi.md +217 -48
  11. data/docs/Attendance.md +17 -0
  12. data/docs/Cashier.md +1 -0
  13. data/docs/CashiersApi.md +15 -13
  14. data/docs/Category.md +1 -0
  15. data/docs/CommodityGroupsApi.md +423 -0
  16. data/docs/CreationTask.md +17 -0
  17. data/docs/CurrenciesApi.md +15 -13
  18. data/docs/CustomerGroupsApi.md +15 -13
  19. data/docs/CustomerOrder.md +2 -2
  20. data/docs/CustomerOrdersApi.md +52 -46
  21. data/docs/CustomersApi.md +108 -45
  22. data/docs/DayTimePeriod.md +9 -0
  23. data/docs/DeliveryNote.md +22 -0
  24. data/docs/DeliveryNoteItem.md +14 -0
  25. data/docs/DeliveryNotesApi.md +316 -0
  26. data/docs/Deposit.md +12 -0
  27. data/docs/Discount.md +10 -0
  28. data/docs/EconomicZonesApi.md +15 -13
  29. data/docs/EndOfDayStatement.md +1 -1
  30. data/docs/Event.md +2 -0
  31. data/docs/ExternalSystemCall.md +20 -0
  32. data/docs/ExternalSystemCallsApi.md +423 -0
  33. data/docs/ImagesApi.md +8 -7
  34. data/docs/InfoTextsApi.md +15 -13
  35. data/docs/InventoriesApi.md +894 -0
  36. data/docs/KoronaAccount.md +1 -0
  37. data/docs/KoronaAccountApi.md +5 -5
  38. data/docs/MediaUrl.md +8 -0
  39. data/docs/OrganizationalUnit.md +1 -0
  40. data/docs/OrganizationalUnitsApi.md +108 -104
  41. data/docs/PaymentMethod.md +3 -0
  42. data/docs/PaymentMethodsApi.md +15 -13
  43. data/docs/PointsOfSaleApi.md +85 -74
  44. data/docs/Pos.md +5 -3
  45. data/docs/PriceGroupsApi.md +15 -13
  46. data/docs/Product.md +2 -0
  47. data/docs/ProductsApi.md +121 -58
  48. data/docs/Receipt.md +5 -1
  49. data/docs/ReceiptItem.md +3 -0
  50. data/docs/ReceiptsApi.md +20 -14
  51. data/docs/ResultListAdditionalReceiptInfoType.md +13 -0
  52. data/docs/ResultListAttendance.md +13 -0
  53. data/docs/ResultListCreationTask.md +13 -0
  54. data/docs/ResultListDeliveryNote.md +13 -0
  55. data/docs/ResultListExternalSystemCall.md +13 -0
  56. data/docs/ResultListTicket.md +13 -0
  57. data/docs/ResultListTimeTrackingEntity.md +13 -0
  58. data/docs/ResultListTimeTrackingEntry.md +13 -0
  59. data/docs/SalesTaxesApi.md +15 -13
  60. data/docs/Sector.md +1 -0
  61. data/docs/SectorRevenueAccountItem.md +9 -0
  62. data/docs/SectorsApi.md +15 -13
  63. data/docs/Signature.md +10 -0
  64. data/docs/StatisticsApi.md +28 -28
  65. data/docs/StockReceipt.md +1 -0
  66. data/docs/StockReceiptsApi.md +687 -0
  67. data/docs/SuppliersApi.md +15 -13
  68. data/docs/TagsApi.md +303 -13
  69. data/docs/Ticket.md +14 -0
  70. data/docs/TicketCreationApi.md +127 -0
  71. data/docs/TicketPersonalization.md +11 -0
  72. data/docs/TicketingApi.md +975 -76
  73. data/docs/TimeTrackingApi.md +388 -0
  74. data/docs/TimeTrackingEntity.md +13 -0
  75. data/docs/TimeTrackingEntry.md +14 -0
  76. data/docs/TotalPeriod.md +9 -0
  77. data/docs/Validity.md +11 -0
  78. data/korona_client-1.0.0.gem +0 -0
  79. data/korona_client.gemspec +7 -8
  80. data/lib/korona_client.rb +38 -5
  81. data/lib/korona_client/api/accounts_api.rb +24 -26
  82. data/lib/korona_client/api/additional_receipt_info_types_api.rb +155 -0
  83. data/lib/korona_client/api/assortments_api.rb +259 -82
  84. data/lib/korona_client/api/cashiers_api.rb +27 -26
  85. data/lib/korona_client/api/commodity_groups_api.rb +462 -0
  86. data/lib/korona_client/api/currencies_api.rb +27 -26
  87. data/lib/korona_client/api/customer_groups_api.rb +27 -26
  88. data/lib/korona_client/api/customer_orders_api.rb +78 -78
  89. data/lib/korona_client/api/customers_api.rb +137 -77
  90. data/lib/korona_client/api/delivery_notes_api.rb +354 -0
  91. data/lib/korona_client/api/economic_zones_api.rb +27 -26
  92. data/lib/korona_client/api/external_system_calls_api.rb +462 -0
  93. data/lib/korona_client/api/images_api.rb +16 -16
  94. data/lib/korona_client/api/info_texts_api.rb +27 -26
  95. data/lib/korona_client/api/inventories_api.rb +1014 -0
  96. data/lib/korona_client/api/korona_account_api.rb +11 -12
  97. data/lib/korona_client/api/organizational_units_api.rb +157 -162
  98. data/lib/korona_client/api/payment_methods_api.rb +27 -26
  99. data/lib/korona_client/api/points_of_sale_api.rb +127 -121
  100. data/lib/korona_client/api/price_groups_api.rb +27 -26
  101. data/lib/korona_client/api/products_api.rb +154 -95
  102. data/lib/korona_client/api/receipts_api.rb +27 -20
  103. data/lib/korona_client/api/sales_taxes_api.rb +27 -26
  104. data/lib/korona_client/api/sectors_api.rb +27 -26
  105. data/lib/korona_client/api/statistics_api.rb +32 -36
  106. data/lib/korona_client/api/stock_receipts_api.rb +769 -0
  107. data/lib/korona_client/api/suppliers_api.rb +27 -26
  108. data/lib/korona_client/api/tags_api.rb +326 -21
  109. data/lib/korona_client/api/ticket_creation_api.rb +149 -0
  110. data/lib/korona_client/api/ticketing_api.rb +1084 -132
  111. data/lib/korona_client/api/time_tracking_api.rb +425 -0
  112. data/lib/korona_client/api_client.rb +11 -11
  113. data/lib/korona_client/api_error.rb +3 -3
  114. data/lib/korona_client/configuration.rb +4 -4
  115. data/lib/korona_client/models/account.rb +11 -15
  116. data/lib/korona_client/models/account_summary.rb +8 -13
  117. data/lib/korona_client/models/account_transaction.rb +32 -15
  118. data/lib/korona_client/models/add_or_update_result.rb +24 -19
  119. data/lib/korona_client/models/additional_info.rb +192 -0
  120. data/lib/korona_client/models/additional_receipt_info_type.rb +319 -0
  121. data/lib/korona_client/models/address_information.rb +8 -13
  122. data/lib/korona_client/models/admission.rb +8 -13
  123. data/lib/korona_client/models/amount.rb +8 -13
  124. data/lib/korona_client/models/amount_count_data.rb +8 -13
  125. data/lib/korona_client/models/assortment.rb +8 -13
  126. data/lib/korona_client/models/attendance.rb +268 -0
  127. data/lib/korona_client/models/bad_request_error.rb +11 -15
  128. data/lib/korona_client/models/capacity.rb +8 -13
  129. data/lib/korona_client/models/cashier.rb +21 -16
  130. data/lib/korona_client/models/cashier_summary.rb +8 -13
  131. data/lib/korona_client/models/category.rb +19 -15
  132. data/lib/korona_client/models/cloud_subscription.rb +11 -15
  133. data/lib/korona_client/models/commodity_group.rb +8 -13
  134. data/lib/korona_client/models/commodity_group_summary.rb +8 -13
  135. data/lib/korona_client/models/company_identification.rb +8 -13
  136. data/lib/korona_client/models/creation_task.rb +298 -0
  137. data/lib/korona_client/models/currency.rb +8 -13
  138. data/lib/korona_client/models/currency_denomination.rb +11 -15
  139. data/lib/korona_client/models/currency_exchange_rate.rb +8 -13
  140. data/lib/korona_client/models/customer.rb +11 -15
  141. data/lib/korona_client/models/customer_card.rb +11 -15
  142. data/lib/korona_client/models/customer_data.rb +8 -13
  143. data/lib/korona_client/models/customer_group.rb +8 -13
  144. data/lib/korona_client/models/customer_group_summary.rb +8 -13
  145. data/lib/korona_client/models/customer_information.rb +8 -13
  146. data/lib/korona_client/models/customer_order.rb +28 -29
  147. data/lib/korona_client/models/day_rating.rb +8 -13
  148. data/lib/korona_client/models/day_time_period.rb +192 -0
  149. data/lib/korona_client/models/delivery_note.rb +316 -0
  150. data/lib/korona_client/models/delivery_note_item.rb +239 -0
  151. data/lib/korona_client/models/deposit.rb +219 -0
  152. data/lib/korona_client/models/device_information.rb +8 -13
  153. data/lib/korona_client/models/discount.rb +201 -0
  154. data/lib/korona_client/models/economic_zone.rb +8 -13
  155. data/lib/korona_client/models/end_of_day_statement.rb +15 -20
  156. data/lib/korona_client/models/end_of_day_statement_summary.rb +8 -13
  157. data/lib/korona_client/models/entry_gate.rb +8 -13
  158. data/lib/korona_client/models/event.rb +30 -15
  159. data/lib/korona_client/models/external_system_call.rb +295 -0
  160. data/lib/korona_client/models/forbidden_error.rb +11 -15
  161. data/lib/korona_client/models/geo_location.rb +8 -13
  162. data/lib/korona_client/models/info_text.rb +11 -15
  163. data/lib/korona_client/models/interval.rb +8 -13
  164. data/lib/korona_client/models/inventory.rb +14 -18
  165. data/lib/korona_client/models/inventory_list.rb +11 -15
  166. data/lib/korona_client/models/inventory_list_item.rb +8 -13
  167. data/lib/korona_client/models/inventory_list_item_stock.rb +8 -13
  168. data/lib/korona_client/models/korona_account.rb +41 -13
  169. data/lib/korona_client/models/media_url.rb +183 -0
  170. data/lib/korona_client/models/method_not_allowed_error.rb +11 -15
  171. data/lib/korona_client/models/model_reference.rb +8 -12
  172. data/lib/korona_client/models/not_found_error.rb +11 -15
  173. data/lib/korona_client/models/organizational_unit.rb +20 -16
  174. data/lib/korona_client/models/payment.rb +8 -13
  175. data/lib/korona_client/models/payment_method.rb +37 -15
  176. data/lib/korona_client/models/payment_summary.rb +8 -13
  177. data/lib/korona_client/models/period.rb +8 -13
  178. data/lib/korona_client/models/period_list_top_seller.rb +8 -13
  179. data/lib/korona_client/models/period_map_string_revenue_data.rb +8 -13
  180. data/lib/korona_client/models/period_object.rb +8 -13
  181. data/lib/korona_client/models/period_revenue_data.rb +8 -13
  182. data/lib/korona_client/models/pos.rb +31 -15
  183. data/lib/korona_client/models/price_group.rb +8 -13
  184. data/lib/korona_client/models/product.rb +35 -19
  185. data/lib/korona_client/models/product_code.rb +8 -13
  186. data/lib/korona_client/models/product_description.rb +11 -15
  187. data/lib/korona_client/models/product_price.rb +8 -13
  188. data/lib/korona_client/models/product_stock.rb +8 -13
  189. data/lib/korona_client/models/product_subproduct.rb +8 -13
  190. data/lib/korona_client/models/product_supplier_price.rb +8 -13
  191. data/lib/korona_client/models/product_transfer_involved_party_information.rb +8 -13
  192. data/lib/korona_client/models/product_transfer_involved_party_information_data.rb +8 -13
  193. data/lib/korona_client/models/rating.rb +8 -13
  194. data/lib/korona_client/models/receipt.rb +55 -20
  195. data/lib/korona_client/models/receipt_item.rb +40 -14
  196. data/lib/korona_client/models/result_list.rb +14 -19
  197. data/lib/korona_client/models/result_list_account.rb +14 -19
  198. data/lib/korona_client/models/result_list_additional_receipt_info_type.rb +268 -0
  199. data/lib/korona_client/models/result_list_assortment.rb +14 -19
  200. data/lib/korona_client/models/result_list_attendance.rb +268 -0
  201. data/lib/korona_client/models/result_list_cashier.rb +14 -19
  202. data/lib/korona_client/models/result_list_commodity_group.rb +14 -19
  203. data/lib/korona_client/models/result_list_creation_task.rb +268 -0
  204. data/lib/korona_client/models/result_list_currency.rb +14 -19
  205. data/lib/korona_client/models/result_list_customer.rb +14 -19
  206. data/lib/korona_client/models/result_list_customer_group.rb +14 -19
  207. data/lib/korona_client/models/result_list_customer_order.rb +14 -19
  208. data/lib/korona_client/models/result_list_day_rating.rb +14 -19
  209. data/lib/korona_client/models/result_list_delivery_note.rb +268 -0
  210. data/lib/korona_client/models/result_list_economic_zone.rb +14 -19
  211. data/lib/korona_client/models/result_list_end_of_day_statement.rb +14 -19
  212. data/lib/korona_client/models/result_list_entry_gate.rb +14 -19
  213. data/lib/korona_client/models/result_list_event.rb +14 -19
  214. data/lib/korona_client/models/result_list_external_system_call.rb +268 -0
  215. data/lib/korona_client/models/result_list_info_text.rb +14 -19
  216. data/lib/korona_client/models/result_list_inventory.rb +14 -19
  217. data/lib/korona_client/models/result_list_inventory_list.rb +14 -19
  218. data/lib/korona_client/models/result_list_inventory_list_item.rb +14 -19
  219. data/lib/korona_client/models/result_list_organizational_unit.rb +14 -19
  220. data/lib/korona_client/models/result_list_payment_method.rb +14 -19
  221. data/lib/korona_client/models/result_list_pos.rb +14 -19
  222. data/lib/korona_client/models/result_list_price_group.rb +14 -19
  223. data/lib/korona_client/models/result_list_product.rb +14 -19
  224. data/lib/korona_client/models/result_list_product_stock.rb +14 -19
  225. data/lib/korona_client/models/result_list_receipt.rb +14 -19
  226. data/lib/korona_client/models/result_list_sales_tax.rb +14 -19
  227. data/lib/korona_client/models/result_list_sector.rb +14 -19
  228. data/lib/korona_client/models/result_list_stock_receipt.rb +14 -19
  229. data/lib/korona_client/models/result_list_stock_receipt_item.rb +14 -19
  230. data/lib/korona_client/models/result_list_supplier.rb +14 -19
  231. data/lib/korona_client/models/result_list_tag.rb +14 -19
  232. data/lib/korona_client/models/result_list_ticket.rb +268 -0
  233. data/lib/korona_client/models/result_list_ticket_definition.rb +14 -19
  234. data/lib/korona_client/models/result_list_time_tracking_entity.rb +268 -0
  235. data/lib/korona_client/models/result_list_time_tracking_entry.rb +268 -0
  236. data/lib/korona_client/models/revenue_data.rb +8 -13
  237. data/lib/korona_client/models/sales_tax.rb +8 -13
  238. data/lib/korona_client/models/sales_tax_rate.rb +8 -13
  239. data/lib/korona_client/models/sector.rb +21 -15
  240. data/lib/korona_client/models/sector_revenue_account_item.rb +192 -0
  241. data/lib/korona_client/models/sector_sales_tax_item.rb +8 -13
  242. data/lib/korona_client/models/signature.rb +216 -0
  243. data/lib/korona_client/models/statistic.rb +8 -13
  244. data/lib/korona_client/models/statistic_list_top_seller.rb +8 -13
  245. data/lib/korona_client/models/statistic_map_string_revenue_data.rb +8 -13
  246. data/lib/korona_client/models/statistic_revenue_data.rb +8 -13
  247. data/lib/korona_client/models/stock_receipt.rb +21 -16
  248. data/lib/korona_client/models/stock_receipt_item.rb +8 -13
  249. data/lib/korona_client/models/stock_receipt_item_amount.rb +8 -13
  250. data/lib/korona_client/models/stock_receipt_item_identification.rb +8 -13
  251. data/lib/korona_client/models/stock_receipt_item_purchase_price.rb +8 -13
  252. data/lib/korona_client/models/supplier.rb +8 -13
  253. data/lib/korona_client/models/supplier_contact.rb +8 -13
  254. data/lib/korona_client/models/supplier_contact_person.rb +8 -13
  255. data/lib/korona_client/models/supplier_payment_information.rb +11 -15
  256. data/lib/korona_client/models/tag.rb +8 -13
  257. data/lib/korona_client/models/tax_payment.rb +8 -13
  258. data/lib/korona_client/models/tax_summary.rb +8 -13
  259. data/lib/korona_client/models/ticket.rb +237 -0
  260. data/lib/korona_client/models/ticket_definition.rb +8 -13
  261. data/lib/korona_client/models/ticket_personalization.rb +225 -0
  262. data/lib/korona_client/models/time_period.rb +8 -13
  263. data/lib/korona_client/models/time_tracking_entity.rb +232 -0
  264. data/lib/korona_client/models/time_tracking_entry.rb +240 -0
  265. data/lib/korona_client/models/too_many_requests_error.rb +11 -15
  266. data/lib/korona_client/models/top_seller.rb +8 -13
  267. data/lib/korona_client/models/total_period.rb +192 -0
  268. data/lib/korona_client/models/total_price.rb +10 -14
  269. data/lib/korona_client/models/validity.rb +236 -0
  270. data/lib/korona_client/models/weather.rb +11 -15
  271. data/lib/korona_client/version.rb +4 -4
  272. data/node_modules/.yarn-integrity +12 -0
  273. data/spec/api/additional_receipt_info_types_api_spec.rb +66 -0
  274. data/spec/api/commodity_groups_api_spec.rb +133 -0
  275. data/spec/api/delivery_notes_api_spec.rb +112 -0
  276. data/spec/api/external_system_calls_api_spec.rb +133 -0
  277. data/spec/api/inventories_api_spec.rb +253 -0
  278. data/spec/api/stock_receipts_api_spec.rb +201 -0
  279. data/spec/api/ticket_creation_api_spec.rb +63 -0
  280. data/spec/api/time_tracking_api_spec.rb +129 -0
  281. data/spec/models/additional_info_spec.rb +47 -0
  282. data/spec/models/additional_receipt_info_type_spec.rb +125 -0
  283. data/spec/models/attendance_spec.rb +95 -0
  284. data/spec/models/creation_task_spec.rb +99 -0
  285. data/spec/models/day_time_period_spec.rb +47 -0
  286. data/spec/models/delivery_note_item_spec.rb +77 -0
  287. data/spec/models/delivery_note_spec.rb +125 -0
  288. data/spec/models/deposit_spec.rb +65 -0
  289. data/spec/models/discount_spec.rb +53 -0
  290. data/spec/models/external_system_call_spec.rb +113 -0
  291. data/spec/models/media_url_spec.rb +41 -0
  292. data/spec/models/result_list_additional_receipt_info_type_spec.rb +71 -0
  293. data/spec/models/result_list_attendance_spec.rb +71 -0
  294. data/spec/models/result_list_creation_task_spec.rb +71 -0
  295. data/spec/models/result_list_delivery_note_spec.rb +71 -0
  296. data/spec/models/result_list_external_system_call_spec.rb +71 -0
  297. data/spec/models/result_list_ticket_spec.rb +71 -0
  298. data/spec/models/result_list_time_tracking_entity_spec.rb +71 -0
  299. data/spec/models/result_list_time_tracking_entry_spec.rb +71 -0
  300. data/spec/models/sector_revenue_account_item_spec.rb +47 -0
  301. data/spec/models/signature_spec.rb +53 -0
  302. data/spec/models/ticket_personalization_spec.rb +59 -0
  303. data/spec/models/ticket_spec.rb +77 -0
  304. data/spec/models/time_tracking_entity_spec.rb +71 -0
  305. data/spec/models/time_tracking_entry_spec.rb +77 -0
  306. data/spec/models/total_period_spec.rb +47 -0
  307. data/spec/models/validity_spec.rb +63 -0
  308. data/yarn.lock +4 -0
  309. metadata +162 -18
@@ -3,14 +3,14 @@
3
3
 
4
4
  #Our api provides access to our cloud services
5
5
 
6
- OpenAPI spec version: 3
7
- Contact: support@combase.net
6
+ OpenAPI spec version: 2.11.21
7
+
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.1
9
+ Swagger Codegen version: 2.4.8
10
10
 
11
11
  =end
12
12
 
13
- require "uri"
13
+ require 'uri'
14
14
 
15
15
  module KoronaClient
16
16
  class PriceGroupsApi
@@ -19,38 +19,37 @@ module KoronaClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
-
23
- # lists the price group
22
+ # returns the single price group
24
23
  #
25
- # @param korona_account_id the account id
26
- # @param price_group_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
24
+ # @param korona_account_id account id of the KORONA.cloud account
25
+ # @param price_group_id id of the related object (important: id should match the uuid-format)
27
26
  # @param [Hash] opts the optional parameters
28
27
  # @return [PriceGroup]
29
- def get_price_group(korona_account_id, price_group_id_or_number, opts = {})
30
- data, _status_code, _headers = get_price_group_with_http_info(korona_account_id, price_group_id_or_number, opts)
31
- return data
28
+ def get_price_group(korona_account_id, price_group_id, opts = {})
29
+ data, _status_code, _headers = get_price_group_with_http_info(korona_account_id, price_group_id, opts)
30
+ data
32
31
  end
33
32
 
34
- # lists the price group
33
+ # returns the single price group
35
34
  #
36
- # @param korona_account_id the account id
37
- # @param price_group_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
35
+ # @param korona_account_id account id of the KORONA.cloud account
36
+ # @param price_group_id id of the related object (important: id should match the uuid-format)
38
37
  # @param [Hash] opts the optional parameters
39
38
  # @return [Array<(PriceGroup, Fixnum, Hash)>] PriceGroup data, response status code and response headers
40
- def get_price_group_with_http_info(korona_account_id, price_group_id_or_number, opts = {})
39
+ def get_price_group_with_http_info(korona_account_id, price_group_id, opts = {})
41
40
  if @api_client.config.debugging
42
- @api_client.config.logger.debug "Calling API: PriceGroupsApi.get_price_group ..."
41
+ @api_client.config.logger.debug 'Calling API: PriceGroupsApi.get_price_group ...'
43
42
  end
44
43
  # verify the required parameter 'korona_account_id' is set
45
44
  if @api_client.config.client_side_validation && korona_account_id.nil?
46
45
  fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling PriceGroupsApi.get_price_group"
47
46
  end
48
- # verify the required parameter 'price_group_id_or_number' is set
49
- if @api_client.config.client_side_validation && price_group_id_or_number.nil?
50
- fail ArgumentError, "Missing the required parameter 'price_group_id_or_number' when calling PriceGroupsApi.get_price_group"
47
+ # verify the required parameter 'price_group_id' is set
48
+ if @api_client.config.client_side_validation && price_group_id.nil?
49
+ fail ArgumentError, "Missing the required parameter 'price_group_id' when calling PriceGroupsApi.get_price_group"
51
50
  end
52
51
  # resource path
53
- local_var_path = "/accounts/{koronaAccountId}/priceGroups/{priceGroupIdOrNumber}".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'priceGroupIdOrNumber' + '}', price_group_id_or_number.to_s)
52
+ local_var_path = '/accounts/{koronaAccountId}/priceGroups/{priceGroupId}'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'priceGroupId' + '}', price_group_id.to_s)
54
53
 
55
54
  # query parameters
56
55
  query_params = {}
@@ -80,42 +79,43 @@ module KoronaClient
80
79
  end
81
80
  return data, status_code, headers
82
81
  end
83
-
84
82
  # lists all price groups
85
83
  #
86
- # @param korona_account_id the account id
84
+ # @param korona_account_id account id of the KORONA.cloud account
87
85
  # @param [Hash] opts the optional parameters
88
86
  # @option opts [Integer] :page number of the page to fetch
89
87
  # @option opts [Integer] :size amount of objects to return per page
90
88
  # @option opts [String] :sort attribute to sort by (multiple separated by comma; max. 5)
91
89
  # @option opts [Integer] :revision last revision number, objects with a greater revision than this will be returned
92
90
  # @option opts [BOOLEAN] :include_deleted indicates deleted objects should be loaded or not (default: false)
91
+ # @option opts [String] :number number of the related object
93
92
  # @return [ResultListPriceGroup]
94
93
  def get_price_groups(korona_account_id, opts = {})
95
94
  data, _status_code, _headers = get_price_groups_with_http_info(korona_account_id, opts)
96
- return data
95
+ data
97
96
  end
98
97
 
99
98
  # lists all price groups
100
99
  #
101
- # @param korona_account_id the account id
100
+ # @param korona_account_id account id of the KORONA.cloud account
102
101
  # @param [Hash] opts the optional parameters
103
102
  # @option opts [Integer] :page number of the page to fetch
104
103
  # @option opts [Integer] :size amount of objects to return per page
105
104
  # @option opts [String] :sort attribute to sort by (multiple separated by comma; max. 5)
106
105
  # @option opts [Integer] :revision last revision number, objects with a greater revision than this will be returned
107
106
  # @option opts [BOOLEAN] :include_deleted indicates deleted objects should be loaded or not (default: false)
107
+ # @option opts [String] :number number of the related object
108
108
  # @return [Array<(ResultListPriceGroup, Fixnum, Hash)>] ResultListPriceGroup data, response status code and response headers
109
109
  def get_price_groups_with_http_info(korona_account_id, opts = {})
110
110
  if @api_client.config.debugging
111
- @api_client.config.logger.debug "Calling API: PriceGroupsApi.get_price_groups ..."
111
+ @api_client.config.logger.debug 'Calling API: PriceGroupsApi.get_price_groups ...'
112
112
  end
113
113
  # verify the required parameter 'korona_account_id' is set
114
114
  if @api_client.config.client_side_validation && korona_account_id.nil?
115
115
  fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling PriceGroupsApi.get_price_groups"
116
116
  end
117
117
  # resource path
118
- local_var_path = "/accounts/{koronaAccountId}/priceGroups".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
118
+ local_var_path = '/accounts/{koronaAccountId}/priceGroups'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
119
119
 
120
120
  # query parameters
121
121
  query_params = {}
@@ -124,6 +124,7 @@ module KoronaClient
124
124
  query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
125
125
  query_params[:'revision'] = opts[:'revision'] if !opts[:'revision'].nil?
126
126
  query_params[:'includeDeleted'] = opts[:'include_deleted'] if !opts[:'include_deleted'].nil?
127
+ query_params[:'number'] = opts[:'number'] if !opts[:'number'].nil?
127
128
 
128
129
  # header parameters
129
130
  header_params = {}
@@ -3,14 +3,14 @@
3
3
 
4
4
  #Our api provides access to our cloud services
5
5
 
6
- OpenAPI spec version: 3
7
- Contact: support@combase.net
6
+ OpenAPI spec version: 2.11.21
7
+
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.1
9
+ Swagger Codegen version: 2.4.8
10
10
 
11
11
  =end
12
12
 
13
- require "uri"
13
+ require 'uri'
14
14
 
15
15
  module KoronaClient
16
16
  class ProductsApi
@@ -19,27 +19,28 @@ module KoronaClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
-
23
22
  # adds a batch of new products
24
23
  #
25
- # @param korona_account_id the account id
26
- # @param body a array of new products
24
+ # @param korona_account_id account id of the KORONA.cloud account
25
+ # @param body array of new products
27
26
  # @param [Hash] opts the optional parameters
27
+ # @option opts [BOOLEAN] :upsert when set to true, updates the object instead of generating a already-exists-error
28
28
  # @return [Array<AddOrUpdateResult>]
29
29
  def add_products(korona_account_id, body, opts = {})
30
30
  data, _status_code, _headers = add_products_with_http_info(korona_account_id, body, opts)
31
- return data
31
+ data
32
32
  end
33
33
 
34
34
  # adds a batch of new products
35
35
  #
36
- # @param korona_account_id the account id
37
- # @param body a array of new products
36
+ # @param korona_account_id account id of the KORONA.cloud account
37
+ # @param body array of new products
38
38
  # @param [Hash] opts the optional parameters
39
+ # @option opts [BOOLEAN] :upsert when set to true, updates the object instead of generating a already-exists-error
39
40
  # @return [Array<(Array<AddOrUpdateResult>, Fixnum, Hash)>] Array<AddOrUpdateResult> data, response status code and response headers
40
41
  def add_products_with_http_info(korona_account_id, body, opts = {})
41
42
  if @api_client.config.debugging
42
- @api_client.config.logger.debug "Calling API: ProductsApi.add_products ..."
43
+ @api_client.config.logger.debug 'Calling API: ProductsApi.add_products ...'
43
44
  end
44
45
  # verify the required parameter 'korona_account_id' is set
45
46
  if @api_client.config.client_side_validation && korona_account_id.nil?
@@ -50,10 +51,11 @@ module KoronaClient
50
51
  fail ArgumentError, "Missing the required parameter 'body' when calling ProductsApi.add_products"
51
52
  end
52
53
  # resource path
53
- local_var_path = "/accounts/{koronaAccountId}/products".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
54
+ local_var_path = '/accounts/{koronaAccountId}/products'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
54
55
 
55
56
  # query parameters
56
57
  query_params = {}
58
+ query_params[:'upsert'] = opts[:'upsert'] if !opts[:'upsert'].nil?
57
59
 
58
60
  # header parameters
59
61
  header_params = {}
@@ -80,38 +82,37 @@ module KoronaClient
80
82
  end
81
83
  return data, status_code, headers
82
84
  end
83
-
84
- # deletes the product
85
+ # deletes the single product
85
86
  #
86
- # @param korona_account_id the account id
87
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
87
+ # @param korona_account_id account id of the KORONA.cloud account
88
+ # @param product_id id of the related object (important: id should match the uuid-format)
88
89
  # @param [Hash] opts the optional parameters
89
90
  # @return [nil]
90
- def delete_product(korona_account_id, product_id_or_number, opts = {})
91
- delete_product_with_http_info(korona_account_id, product_id_or_number, opts)
92
- return nil
91
+ def delete_product(korona_account_id, product_id, opts = {})
92
+ delete_product_with_http_info(korona_account_id, product_id, opts)
93
+ nil
93
94
  end
94
95
 
95
- # deletes the product
96
+ # deletes the single product
96
97
  #
97
- # @param korona_account_id the account id
98
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
98
+ # @param korona_account_id account id of the KORONA.cloud account
99
+ # @param product_id id of the related object (important: id should match the uuid-format)
99
100
  # @param [Hash] opts the optional parameters
100
101
  # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
101
- def delete_product_with_http_info(korona_account_id, product_id_or_number, opts = {})
102
+ def delete_product_with_http_info(korona_account_id, product_id, opts = {})
102
103
  if @api_client.config.debugging
103
- @api_client.config.logger.debug "Calling API: ProductsApi.delete_product ..."
104
+ @api_client.config.logger.debug 'Calling API: ProductsApi.delete_product ...'
104
105
  end
105
106
  # verify the required parameter 'korona_account_id' is set
106
107
  if @api_client.config.client_side_validation && korona_account_id.nil?
107
108
  fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling ProductsApi.delete_product"
108
109
  end
109
- # verify the required parameter 'product_id_or_number' is set
110
- if @api_client.config.client_side_validation && product_id_or_number.nil?
111
- fail ArgumentError, "Missing the required parameter 'product_id_or_number' when calling ProductsApi.delete_product"
110
+ # verify the required parameter 'product_id' is set
111
+ if @api_client.config.client_side_validation && product_id.nil?
112
+ fail ArgumentError, "Missing the required parameter 'product_id' when calling ProductsApi.delete_product"
112
113
  end
113
114
  # resource path
114
- local_var_path = "/accounts/{koronaAccountId}/products/{productIdOrNumber}".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productIdOrNumber' + '}', product_id_or_number.to_s)
115
+ local_var_path = '/accounts/{koronaAccountId}/products/{productId}'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productId' + '}', product_id.to_s)
115
116
 
116
117
  # query parameters
117
118
  query_params = {}
@@ -140,38 +141,97 @@ module KoronaClient
140
141
  end
141
142
  return data, status_code, headers
142
143
  end
144
+ # deletes a batch of products
145
+ #
146
+ # @param korona_account_id account id of the KORONA.cloud account
147
+ # @param body array of existing products (id or number required)
148
+ # @param [Hash] opts the optional parameters
149
+ # @return [Array<AddOrUpdateResult>]
150
+ def delete_products(korona_account_id, body, opts = {})
151
+ data, _status_code, _headers = delete_products_with_http_info(korona_account_id, body, opts)
152
+ data
153
+ end
143
154
 
144
- # lists the product
155
+ # deletes a batch of products
145
156
  #
146
- # @param korona_account_id the account id
147
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
157
+ # @param korona_account_id account id of the KORONA.cloud account
158
+ # @param body array of existing products (id or number required)
159
+ # @param [Hash] opts the optional parameters
160
+ # @return [Array<(Array<AddOrUpdateResult>, Fixnum, Hash)>] Array<AddOrUpdateResult> data, response status code and response headers
161
+ def delete_products_with_http_info(korona_account_id, body, opts = {})
162
+ if @api_client.config.debugging
163
+ @api_client.config.logger.debug 'Calling API: ProductsApi.delete_products ...'
164
+ end
165
+ # verify the required parameter 'korona_account_id' is set
166
+ if @api_client.config.client_side_validation && korona_account_id.nil?
167
+ fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling ProductsApi.delete_products"
168
+ end
169
+ # verify the required parameter 'body' is set
170
+ if @api_client.config.client_side_validation && body.nil?
171
+ fail ArgumentError, "Missing the required parameter 'body' when calling ProductsApi.delete_products"
172
+ end
173
+ # resource path
174
+ local_var_path = '/accounts/{koronaAccountId}/products'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
175
+
176
+ # query parameters
177
+ query_params = {}
178
+
179
+ # header parameters
180
+ header_params = {}
181
+ # HTTP header 'Accept' (if needed)
182
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
183
+ # HTTP header 'Content-Type'
184
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
185
+
186
+ # form parameters
187
+ form_params = {}
188
+
189
+ # http body (model)
190
+ post_body = @api_client.object_to_http_body(body)
191
+ auth_names = ['basicAuth']
192
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
193
+ :header_params => header_params,
194
+ :query_params => query_params,
195
+ :form_params => form_params,
196
+ :body => post_body,
197
+ :auth_names => auth_names,
198
+ :return_type => 'Array<AddOrUpdateResult>')
199
+ if @api_client.config.debugging
200
+ @api_client.config.logger.debug "API called: ProductsApi#delete_products\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
201
+ end
202
+ return data, status_code, headers
203
+ end
204
+ # returns the single product
205
+ #
206
+ # @param korona_account_id account id of the KORONA.cloud account
207
+ # @param product_id id of the related object (important: id should match the uuid-format)
148
208
  # @param [Hash] opts the optional parameters
149
209
  # @return [Product]
150
- def get_product(korona_account_id, product_id_or_number, opts = {})
151
- data, _status_code, _headers = get_product_with_http_info(korona_account_id, product_id_or_number, opts)
152
- return data
210
+ def get_product(korona_account_id, product_id, opts = {})
211
+ data, _status_code, _headers = get_product_with_http_info(korona_account_id, product_id, opts)
212
+ data
153
213
  end
154
214
 
155
- # lists the product
215
+ # returns the single product
156
216
  #
157
- # @param korona_account_id the account id
158
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
217
+ # @param korona_account_id account id of the KORONA.cloud account
218
+ # @param product_id id of the related object (important: id should match the uuid-format)
159
219
  # @param [Hash] opts the optional parameters
160
220
  # @return [Array<(Product, Fixnum, Hash)>] Product data, response status code and response headers
161
- def get_product_with_http_info(korona_account_id, product_id_or_number, opts = {})
221
+ def get_product_with_http_info(korona_account_id, product_id, opts = {})
162
222
  if @api_client.config.debugging
163
- @api_client.config.logger.debug "Calling API: ProductsApi.get_product ..."
223
+ @api_client.config.logger.debug 'Calling API: ProductsApi.get_product ...'
164
224
  end
165
225
  # verify the required parameter 'korona_account_id' is set
166
226
  if @api_client.config.client_side_validation && korona_account_id.nil?
167
227
  fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling ProductsApi.get_product"
168
228
  end
169
- # verify the required parameter 'product_id_or_number' is set
170
- if @api_client.config.client_side_validation && product_id_or_number.nil?
171
- fail ArgumentError, "Missing the required parameter 'product_id_or_number' when calling ProductsApi.get_product"
229
+ # verify the required parameter 'product_id' is set
230
+ if @api_client.config.client_side_validation && product_id.nil?
231
+ fail ArgumentError, "Missing the required parameter 'product_id' when calling ProductsApi.get_product"
172
232
  end
173
233
  # resource path
174
- local_var_path = "/accounts/{koronaAccountId}/products/{productIdOrNumber}".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productIdOrNumber' + '}', product_id_or_number.to_s)
234
+ local_var_path = '/accounts/{koronaAccountId}/products/{productId}'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productId' + '}', product_id.to_s)
175
235
 
176
236
  # query parameters
177
237
  query_params = {}
@@ -201,46 +261,45 @@ module KoronaClient
201
261
  end
202
262
  return data, status_code, headers
203
263
  end
204
-
205
264
  # lists the product stocks in different warehouses (KORONA.retail required)
206
265
  #
207
- # @param korona_account_id the account id
208
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
266
+ # @param korona_account_id account id of the KORONA.cloud account
267
+ # @param product_id id of the related object (important: id should match the uuid-format)
209
268
  # @param [Hash] opts the optional parameters
210
269
  # @option opts [Integer] :page number of the page to fetch
211
270
  # @option opts [Integer] :size amount of objects to return per page
212
271
  # @option opts [String] :sort attribute to sort by (multiple separated by comma; max. 5)
213
272
  # @option opts [Integer] :revision last revision number, objects with a greater revision than this will be returned
214
273
  # @return [ResultListProductStock]
215
- def get_product_stocks(korona_account_id, product_id_or_number, opts = {})
216
- data, _status_code, _headers = get_product_stocks_with_http_info(korona_account_id, product_id_or_number, opts)
217
- return data
274
+ def get_product_stocks(korona_account_id, product_id, opts = {})
275
+ data, _status_code, _headers = get_product_stocks_with_http_info(korona_account_id, product_id, opts)
276
+ data
218
277
  end
219
278
 
220
279
  # lists the product stocks in different warehouses (KORONA.retail required)
221
280
  #
222
- # @param korona_account_id the account id
223
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
281
+ # @param korona_account_id account id of the KORONA.cloud account
282
+ # @param product_id id of the related object (important: id should match the uuid-format)
224
283
  # @param [Hash] opts the optional parameters
225
284
  # @option opts [Integer] :page number of the page to fetch
226
285
  # @option opts [Integer] :size amount of objects to return per page
227
286
  # @option opts [String] :sort attribute to sort by (multiple separated by comma; max. 5)
228
287
  # @option opts [Integer] :revision last revision number, objects with a greater revision than this will be returned
229
288
  # @return [Array<(ResultListProductStock, Fixnum, Hash)>] ResultListProductStock data, response status code and response headers
230
- def get_product_stocks_with_http_info(korona_account_id, product_id_or_number, opts = {})
289
+ def get_product_stocks_with_http_info(korona_account_id, product_id, opts = {})
231
290
  if @api_client.config.debugging
232
- @api_client.config.logger.debug "Calling API: ProductsApi.get_product_stocks ..."
291
+ @api_client.config.logger.debug 'Calling API: ProductsApi.get_product_stocks ...'
233
292
  end
234
293
  # verify the required parameter 'korona_account_id' is set
235
294
  if @api_client.config.client_side_validation && korona_account_id.nil?
236
295
  fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling ProductsApi.get_product_stocks"
237
296
  end
238
- # verify the required parameter 'product_id_or_number' is set
239
- if @api_client.config.client_side_validation && product_id_or_number.nil?
240
- fail ArgumentError, "Missing the required parameter 'product_id_or_number' when calling ProductsApi.get_product_stocks"
297
+ # verify the required parameter 'product_id' is set
298
+ if @api_client.config.client_side_validation && product_id.nil?
299
+ fail ArgumentError, "Missing the required parameter 'product_id' when calling ProductsApi.get_product_stocks"
241
300
  end
242
301
  # resource path
243
- local_var_path = "/accounts/{koronaAccountId}/products/{productIdOrNumber}/stocks".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productIdOrNumber' + '}', product_id_or_number.to_s)
302
+ local_var_path = '/accounts/{koronaAccountId}/products/{productId}/stocks'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productId' + '}', product_id.to_s)
244
303
 
245
304
  # query parameters
246
305
  query_params = {}
@@ -274,10 +333,9 @@ module KoronaClient
274
333
  end
275
334
  return data, status_code, headers
276
335
  end
277
-
278
336
  # lists all products
279
337
  #
280
- # @param korona_account_id the account id
338
+ # @param korona_account_id account id of the KORONA.cloud account
281
339
  # @param [Hash] opts the optional parameters
282
340
  # @option opts [Integer] :page number of the page to fetch
283
341
  # @option opts [Integer] :size amount of objects to return per page
@@ -285,18 +343,19 @@ module KoronaClient
285
343
  # @option opts [Integer] :revision last revision number, objects with a greater revision than this will be returned
286
344
  # @option opts [BOOLEAN] :include_deleted indicates deleted objects should be loaded or not (default: false)
287
345
  # @option opts [String] :product_codes at least one product code to filter by (multiple separated by comma; max. 10)
288
- # @option opts [String] :commodity_group commodity group id or number to filter by
289
- # @option opts [String] :assortment assortment id or number to filter by
290
- # @option opts [String] :tag tag id or number to filter by
346
+ # @option opts [String] :commodity_group commodity group id to filter by
347
+ # @option opts [String] :assortment assortment id to filter by
348
+ # @option opts [String] :tag tag id to filter by
349
+ # @option opts [String] :number number of the related object
291
350
  # @return [ResultListProduct]
292
351
  def get_products(korona_account_id, opts = {})
293
352
  data, _status_code, _headers = get_products_with_http_info(korona_account_id, opts)
294
- return data
353
+ data
295
354
  end
296
355
 
297
356
  # lists all products
298
357
  #
299
- # @param korona_account_id the account id
358
+ # @param korona_account_id account id of the KORONA.cloud account
300
359
  # @param [Hash] opts the optional parameters
301
360
  # @option opts [Integer] :page number of the page to fetch
302
361
  # @option opts [Integer] :size amount of objects to return per page
@@ -304,20 +363,21 @@ module KoronaClient
304
363
  # @option opts [Integer] :revision last revision number, objects with a greater revision than this will be returned
305
364
  # @option opts [BOOLEAN] :include_deleted indicates deleted objects should be loaded or not (default: false)
306
365
  # @option opts [String] :product_codes at least one product code to filter by (multiple separated by comma; max. 10)
307
- # @option opts [String] :commodity_group commodity group id or number to filter by
308
- # @option opts [String] :assortment assortment id or number to filter by
309
- # @option opts [String] :tag tag id or number to filter by
366
+ # @option opts [String] :commodity_group commodity group id to filter by
367
+ # @option opts [String] :assortment assortment id to filter by
368
+ # @option opts [String] :tag tag id to filter by
369
+ # @option opts [String] :number number of the related object
310
370
  # @return [Array<(ResultListProduct, Fixnum, Hash)>] ResultListProduct data, response status code and response headers
311
371
  def get_products_with_http_info(korona_account_id, opts = {})
312
372
  if @api_client.config.debugging
313
- @api_client.config.logger.debug "Calling API: ProductsApi.get_products ..."
373
+ @api_client.config.logger.debug 'Calling API: ProductsApi.get_products ...'
314
374
  end
315
375
  # verify the required parameter 'korona_account_id' is set
316
376
  if @api_client.config.client_side_validation && korona_account_id.nil?
317
377
  fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling ProductsApi.get_products"
318
378
  end
319
379
  # resource path
320
- local_var_path = "/accounts/{koronaAccountId}/products".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
380
+ local_var_path = '/accounts/{koronaAccountId}/products'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
321
381
 
322
382
  # query parameters
323
383
  query_params = {}
@@ -330,6 +390,7 @@ module KoronaClient
330
390
  query_params[:'commodityGroup'] = opts[:'commodity_group'] if !opts[:'commodity_group'].nil?
331
391
  query_params[:'assortment'] = opts[:'assortment'] if !opts[:'assortment'].nil?
332
392
  query_params[:'tag'] = opts[:'tag'] if !opts[:'tag'].nil?
393
+ query_params[:'number'] = opts[:'number'] if !opts[:'number'].nil?
333
394
 
334
395
  # header parameters
335
396
  header_params = {}
@@ -356,44 +417,43 @@ module KoronaClient
356
417
  end
357
418
  return data, status_code, headers
358
419
  end
359
-
360
- # changes the product
420
+ # updates the single product
361
421
  # if [number] is set, the number of the object will change and the resource location as well
362
- # @param korona_account_id the account id
363
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
422
+ # @param korona_account_id account id of the KORONA.cloud account
423
+ # @param product_id id of the related object (important: id should match the uuid-format)
364
424
  # @param body the properties to update of the product
365
425
  # @param [Hash] opts the optional parameters
366
426
  # @return [nil]
367
- def update_product(korona_account_id, product_id_or_number, body, opts = {})
368
- update_product_with_http_info(korona_account_id, product_id_or_number, body, opts)
369
- return nil
427
+ def update_product(korona_account_id, product_id, body, opts = {})
428
+ update_product_with_http_info(korona_account_id, product_id, body, opts)
429
+ nil
370
430
  end
371
431
 
372
- # changes the product
432
+ # updates the single product
373
433
  # if [number] is set, the number of the object will change and the resource location as well
374
- # @param korona_account_id the account id
375
- # @param product_id_or_number id or number of the related object (important: if a number should match the uuid-format, the system will lookup for an id instead of a number)
434
+ # @param korona_account_id account id of the KORONA.cloud account
435
+ # @param product_id id of the related object (important: id should match the uuid-format)
376
436
  # @param body the properties to update of the product
377
437
  # @param [Hash] opts the optional parameters
378
438
  # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
379
- def update_product_with_http_info(korona_account_id, product_id_or_number, body, opts = {})
439
+ def update_product_with_http_info(korona_account_id, product_id, body, opts = {})
380
440
  if @api_client.config.debugging
381
- @api_client.config.logger.debug "Calling API: ProductsApi.update_product ..."
441
+ @api_client.config.logger.debug 'Calling API: ProductsApi.update_product ...'
382
442
  end
383
443
  # verify the required parameter 'korona_account_id' is set
384
444
  if @api_client.config.client_side_validation && korona_account_id.nil?
385
445
  fail ArgumentError, "Missing the required parameter 'korona_account_id' when calling ProductsApi.update_product"
386
446
  end
387
- # verify the required parameter 'product_id_or_number' is set
388
- if @api_client.config.client_side_validation && product_id_or_number.nil?
389
- fail ArgumentError, "Missing the required parameter 'product_id_or_number' when calling ProductsApi.update_product"
447
+ # verify the required parameter 'product_id' is set
448
+ if @api_client.config.client_side_validation && product_id.nil?
449
+ fail ArgumentError, "Missing the required parameter 'product_id' when calling ProductsApi.update_product"
390
450
  end
391
451
  # verify the required parameter 'body' is set
392
452
  if @api_client.config.client_side_validation && body.nil?
393
453
  fail ArgumentError, "Missing the required parameter 'body' when calling ProductsApi.update_product"
394
454
  end
395
455
  # resource path
396
- local_var_path = "/accounts/{koronaAccountId}/products/{productIdOrNumber}".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productIdOrNumber' + '}', product_id_or_number.to_s)
456
+ local_var_path = '/accounts/{koronaAccountId}/products/{productId}'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s).sub('{' + 'productId' + '}', product_id.to_s)
397
457
 
398
458
  # query parameters
399
459
  query_params = {}
@@ -422,27 +482,26 @@ module KoronaClient
422
482
  end
423
483
  return data, status_code, headers
424
484
  end
425
-
426
- # changes a batch of products
485
+ # updates a batch of products
427
486
  # [number] must be set in the objects, otherwise the object cannot be updated
428
- # @param korona_account_id the account id
429
- # @param body a array of existing products
487
+ # @param korona_account_id account id of the KORONA.cloud account
488
+ # @param body an array of existing products
430
489
  # @param [Hash] opts the optional parameters
431
490
  # @return [Array<AddOrUpdateResult>]
432
491
  def update_products(korona_account_id, body, opts = {})
433
492
  data, _status_code, _headers = update_products_with_http_info(korona_account_id, body, opts)
434
- return data
493
+ data
435
494
  end
436
495
 
437
- # changes a batch of products
496
+ # updates a batch of products
438
497
  # [number] must be set in the objects, otherwise the object cannot be updated
439
- # @param korona_account_id the account id
440
- # @param body a array of existing products
498
+ # @param korona_account_id account id of the KORONA.cloud account
499
+ # @param body an array of existing products
441
500
  # @param [Hash] opts the optional parameters
442
501
  # @return [Array<(Array<AddOrUpdateResult>, Fixnum, Hash)>] Array<AddOrUpdateResult> data, response status code and response headers
443
502
  def update_products_with_http_info(korona_account_id, body, opts = {})
444
503
  if @api_client.config.debugging
445
- @api_client.config.logger.debug "Calling API: ProductsApi.update_products ..."
504
+ @api_client.config.logger.debug 'Calling API: ProductsApi.update_products ...'
446
505
  end
447
506
  # verify the required parameter 'korona_account_id' is set
448
507
  if @api_client.config.client_side_validation && korona_account_id.nil?
@@ -453,7 +512,7 @@ module KoronaClient
453
512
  fail ArgumentError, "Missing the required parameter 'body' when calling ProductsApi.update_products"
454
513
  end
455
514
  # resource path
456
- local_var_path = "/accounts/{koronaAccountId}/products".sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
515
+ local_var_path = '/accounts/{koronaAccountId}/products'.sub('{' + 'koronaAccountId' + '}', korona_account_id.to_s)
457
516
 
458
517
  # query parameters
459
518
  query_params = {}