ultracart_api 4.0.67.rc → 4.0.69.rc

Sign up to get free protection for your applications and to get access to all the features.
@@ -300,6 +300,70 @@ module UltracartClient
300
300
  return data, status_code, headers
301
301
  end
302
302
 
303
+ # Retrieves digital items from the digital library (which are digital files that may be attached to normal items) that having a matching external id
304
+ # Retrieves digital items from the digital library (which are digital files that may be attached to normal items) that having a matching external id. Be aware that these are not normal items that can be added to a shopping cart. Rather, they are digital files that may be associated with normal items.
305
+ # @param external_id [String] The external id to match against.
306
+ # @param [Hash] opts the optional parameters
307
+ # @return [ItemDigitalItemsResponse]
308
+ def get_digital_items_by_external_id(external_id, opts = {})
309
+ data, _status_code, _headers = get_digital_items_by_external_id_with_http_info(external_id, opts)
310
+ data
311
+ end
312
+
313
+ # Retrieves digital items from the digital library (which are digital files that may be attached to normal items) that having a matching external id
314
+ # Retrieves digital items from the digital library (which are digital files that may be attached to normal items) that having a matching external id. Be aware that these are not normal items that can be added to a shopping cart. Rather, they are digital files that may be associated with normal items.
315
+ # @param external_id [String] The external id to match against.
316
+ # @param [Hash] opts the optional parameters
317
+ # @return [Array<(ItemDigitalItemsResponse, Integer, Hash)>] ItemDigitalItemsResponse data, response status code and response headers
318
+ def get_digital_items_by_external_id_with_http_info(external_id, opts = {})
319
+ if @api_client.config.debugging
320
+ @api_client.config.logger.debug 'Calling API: ItemApi.get_digital_items_by_external_id ...'
321
+ end
322
+ # verify the required parameter 'external_id' is set
323
+ if @api_client.config.client_side_validation && external_id.nil?
324
+ fail ArgumentError, "Missing the required parameter 'external_id' when calling ItemApi.get_digital_items_by_external_id"
325
+ end
326
+ # resource path
327
+ local_var_path = '/item/digital_library/by_external/{external_id}'.sub('{' + 'external_id' + '}', CGI.escape(external_id.to_s))
328
+
329
+ # query parameters
330
+ query_params = opts[:query_params] || {}
331
+
332
+ # header parameters
333
+ header_params = opts[:header_params] || {}
334
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
335
+ # HTTP header 'Accept' (if needed)
336
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
337
+
338
+ # form parameters
339
+ form_params = opts[:form_params] || {}
340
+
341
+ # http body (model)
342
+ post_body = opts[:debug_body]
343
+
344
+ # return_type
345
+ return_type = opts[:debug_return_type] || 'ItemDigitalItemsResponse'
346
+
347
+ # auth_names
348
+ auth_names = opts[:debug_auth_names] || ['ultraCartOauth', 'ultraCartSimpleApiKey']
349
+
350
+ new_options = opts.merge(
351
+ :operation => :"ItemApi.get_digital_items_by_external_id",
352
+ :header_params => header_params,
353
+ :query_params => query_params,
354
+ :form_params => form_params,
355
+ :body => post_body,
356
+ :auth_names => auth_names,
357
+ :return_type => return_type
358
+ )
359
+
360
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
361
+ if @api_client.config.debugging
362
+ @api_client.config.logger.debug "API called: ItemApi#get_digital_items_by_external_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
363
+ end
364
+ return data, status_code, headers
365
+ end
366
+
303
367
  # Retrieve an item
304
368
  # Retrieves a single item using the specified item oid.
305
369
  # @param merchant_item_oid [Integer] The item oid to retrieve.