Class: InventoryManagementAndItemManagementAndOrderManagementAndPriceManagement::ReleasedController

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

Overview

ReleasedController

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

#allreleasedorders(created_start_date, created_end_date, limit, product_info, ship_node_type, sku, customer_order_id, purchase_order_id, from_expected_ship_date, to_expected_ship_date, shipping_program_type, replacement_info, order_type, wm_sec_access_token, wm_consumer_channel_type, wm_qos_correlation_id, wm_svc_name, accept) ⇒ SuccessfulOperation52

Retrieves all the orders with line items that are in the “created” status, that is, these orders have been released from the Walmart Order Management System to the seller for processing. The released orders are the orders that are ready for a seller to fulfill. Only orders created in last 180 days and a maximum of 20000 orders can be fetched at a time. Attempting to download more than 20000 orders will return an error. purchase orders that were created after this date. Default is current date

  • 7 days. Use either UTC or ISO 8601 formats. Date example:

‘2020-03-16’(yyyy-MM-dd). Date with Timestamp example: ‘2020-03-16T10:30:15Z’(yyyy-MM-dd’T’HH:mm:ssZ). orders that were created before this date. Default is current date. Use either UTC or ISO 8601 formats. Date example: ‘2020-03-16’(yyyy-MM-dd). Date with Timestamp example: ‘2020-03-16T10:30:15Z’(yyyy-MM-dd’T’HH:mm:ssZ). returned. Cannot be larger than 200. the image URL and product weight in response, if available. Allowed values are true or false. shipNode. Allowed values are SellerFulfilled(Default), WFSFulfilled and 3PLFulfilled. ID ID. One customer may have multiple purchase orders. purchase orders that have order lines with an expected ship date after this date. Use either UTC or ISO 8601 formats. Date example: ‘2020-03-16’(yyyy-MM-dd). Date with Timestamp example: ‘2020-03-16T10:30:15Z’(yyyy-MM-dd’T’HH:mm:ssZ) purchase orders that have order lines with an expected ship date before this date. Use either UTC or ISO 8601 formats. Date example: ‘2020-03-16’(yyyy-MM-dd). Date with Timestamp example: ‘2020-03-16T10:30:15Z’(yyyy-MM-dd’T’HH:mm:ssZ) type of program. Allowed value is TWO_DAY, ONE_DAY. Provides additional attributes - originalCustomerOrderID, orderType - related to Replacement order, in response, if available. Allowed values are true or false. regular order , replacement order or preorder. Possible values are REGULAR, REPLACEMENT or PREORDER. The REGULAR or REPLACEMENT will be provided in response only if query parameter replacementInfo=true. access token retrieved in the Token API call to track the consumer request by channel. Use the Consumer Channel Type received during onboarding unique ID which identifies each API call and used to track and debug issues; use a random generated GUID for this ID Name

Parameters:

  • created_start_date (String)

    Required parameter: Fetches all

  • created_end_date (String)

    Required parameter: Fetches all purchase

  • limit (Integer)

    Required parameter: The number of orders to be

  • product_info (TrueClass | FalseClass)

    Required parameter: Provides

  • ship_node_type (String)

    Required parameter: Specifies the type of

  • sku (String)

    Required parameter: A seller-provided Product ID

  • customer_order_id (String)

    Required parameter: The customer order

  • purchase_order_id (String)

    Required parameter: The purchase order

  • from_expected_ship_date (String)

    Required parameter: Fetches all

  • to_expected_ship_date (String)

    Required parameter: Fetches all

  • shipping_program_type (String)

    Required parameter: Specifies the

  • replacement_info (TrueClass | FalseClass)

    Required parameter:

  • order_type (String)

    Required parameter: Specifies if the order is a

  • wm_sec_access_token (String)

    Required parameter: (Required) The

  • wm_consumer_channel_type (String)

    Required parameter: A unique ID

  • wm_qos_correlation_id (String)

    Required parameter: (Required) A

  • wm_svc_name (String)

    Required parameter: (Required) Walmart Service

  • accept (String)

    Required parameter: TODO: type description here

Returns:



72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/controllers/released_controller.rb', line 72

def allreleasedorders(created_start_date,
                      created_end_date,
                      limit,
                      product_info,
                      ship_node_type,
                      sku,
                      customer_order_id,
                      purchase_order_id,
                      from_expected_ship_date,
                      to_expected_ship_date,
                      shipping_program_type,
                      replacement_info,
                      order_type,
                      wm_sec_access_token,
                      wm_consumer_channel_type,
                      wm_qos_correlation_id,
                      wm_svc_name,
                      accept)
  @api_call
    .request(new_request_builder(HttpMethodEnum::GET,
                                 '/orders/released',
                                 Server::DEFAULT)
               .query_param(new_parameter(created_start_date, key: 'createdStartDate'))
               .query_param(new_parameter(created_end_date, key: 'createdEndDate'))
               .query_param(new_parameter(limit, key: 'limit'))
               .query_param(new_parameter(product_info, key: 'productInfo'))
               .query_param(new_parameter(ship_node_type, key: 'shipNodeType'))
               .query_param(new_parameter(sku, key: 'sku'))
               .query_param(new_parameter(customer_order_id, key: 'customerOrderId'))
               .query_param(new_parameter(purchase_order_id, key: 'purchaseOrderId'))
               .query_param(new_parameter(from_expected_ship_date, key: 'fromExpectedShipDate'))
               .query_param(new_parameter(to_expected_ship_date, key: 'toExpectedShipDate'))
               .query_param(new_parameter(shipping_program_type, key: 'shippingProgramType'))
               .query_param(new_parameter(replacement_info, key: 'replacementInfo'))
               .query_param(new_parameter(order_type, key: 'orderType'))
               .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(SuccessfulOperation52.method(:from_hash)))
    .execute
end