Class: InventoryManagementAndItemManagementAndOrderManagementAndPriceManagement::WfpreferenceController

Inherits:
BaseController
  • Object
show all
Defined in:
lib/inventory_management_and_item_management_and_order_management_and_price_management/controllers/wfpreference_controller.rb

Overview

WfpreferenceController

Constant Summary

Constants inherited from BaseController

BaseController::GLOBAL_ERRORS

Instance Attribute Summary

Attributes inherited from BaseController

#config, #http_call_back

Instance Method Summary collapse

Methods inherited from BaseController

#initialize, #new_parameter, #new_request_builder, #new_response_handler, user_agent

Constructor Details

This class inherits a constructor from InventoryManagementAndItemManagementAndOrderManagementAndPriceManagement::BaseController

Instance Method Details

#update_walmart_fundedincentivesenrollmentforallitems(auto_enroll_enabled, wm_sec_access_token, wm_consumer_channel_type, wm_qos_correlation_id, wm_svc_name, accept) ⇒ SuccessfulOperation43

Updates the enrollment status of all items in the Walmart-funded incentives program. By default, all items are auto-enrolled in Walmart-funded incentives, meaning that eligible items are automatically included in these programs to benefit from price reductions funded by Walmart. If you wish to permanently turn off Walmart-funded incentives for all items in your catalog, you can use this API to set the Walmart-funded incentives program status to ‘OFF`. The default value of this variable is `ON`. Any changes to preferences will lock in (disable) the preference option for a period of 4 hours, as indicated by the `isDisabled` response field of the API. For more information and usage examples, refer to the <a href=“developer.walmart.com/us-marketplace/docs/manage-enrollment- all-items-in-walmart-funded-incentives”>Pricing API Guide</a> Specify the boolean for enabling auto enrollment. Examples of the allowed values are `true` or `false`. obtained from the Token API. This is required for authenticating requests to Walmart Marketplace APIs. to identify the consumer request by channel. Use the Consumer Channel Type received during onboarding. identifies each API call and is used to track and debug issues. Use a randomly generated GUID for this ID. Walmart service being called.

Parameters:

  • auto_enroll_enabled (TrueClass | FalseClass)

    Required parameter:

  • wm_sec_access_token (String)

    Required parameter: Access token

  • wm_consumer_channel_type (String)

    Required parameter: A unique ID

  • wm_qos_correlation_id (String)

    Required parameter: A unique ID that

  • wm_svc_name (String)

    Required parameter: Specifies the name of the

  • accept (String)

    Required parameter: TODO: type description here

Returns:



40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/controllers/wfpreference_controller.rb', line 40

def update_walmart_fundedincentivesenrollmentforallitems(auto_enroll_enabled,
                                                         wm_sec_access_token,
                                                         wm_consumer_channel_type,
                                                         wm_qos_correlation_id,
                                                         wm_svc_name,
                                                         accept)
  @api_call
    .request(new_request_builder(HttpMethodEnum::PUT,
                                 '/price/incentives/wfpreference',
                                 Server::DEFAULT)
               .query_param(new_parameter(auto_enroll_enabled, key: 'autoEnrollEnabled'))
               .header_param(new_parameter(wm_sec_access_token, key: 'WM_SEC.ACCESS_TOKEN'))
               .header_param(new_parameter(wm_consumer_channel_type, key: 'WM_CONSUMER.CHANNEL.TYPE'))
               .header_param(new_parameter(wm_qos_correlation_id, key: 'WM_QOS.CORRELATION_ID'))
               .header_param(new_parameter(wm_svc_name, key: 'WM_SVC.NAME'))
               .header_param(new_parameter(accept, key: 'Accept')))
    .response(new_response_handler
                .deserializer(APIHelper.method(:custom_type_deserializer))
                .deserialize_into(SuccessfulOperation43.method(:from_hash)))
    .execute
end