Method: Peddler::APIs::VendorOrdersV1#get_purchase_orders_status

Defined in:
lib/peddler/apis/vendor_orders_v1.rb

#get_purchase_orders_status(limit: nil, sort_order: nil, next_token: nil, created_after: nil, created_before: nil, updated_after: nil, updated_before: nil, purchase_order_number: nil, purchase_order_status: nil, item_confirmation_status: nil, item_receive_status: nil, ordering_vendor_code: nil, ship_to_party_id: nil, rate_limit: 10.0) ⇒ Peddler::Response

Note:

This operation can make a static sandbox call.

Returns purchase order statuses based on the filters that you specify. Date range to search must not be more than 7 days. You can return a list of purchase order statuses using the available filters, or a single purchase order status by providing the purchase order number.

Parameters:

  • limit (Integer) (defaults to: nil)

    The limit to the number of records returned. Default value is 100 records.

  • sort_order (String) (defaults to: nil)

    Sort in ascending or descending order by purchase order creation date.

  • next_token (String) (defaults to: nil)

    Used for pagination when there are more purchase orders than the specified result size limit.

  • created_after (String) (defaults to: nil)

    Purchase orders that became available after this timestamp will be included in the result. Must be in ISO-8601 date/time format.

  • created_before (String) (defaults to: nil)

    Purchase orders that became available before this timestamp will be included in the result. Must be in ISO-8601 date/time format.

  • updated_after (String) (defaults to: nil)

    Purchase orders for which the last purchase order update happened after this timestamp will be included in the result. Must be in ISO-8601 date/time format.

  • updated_before (String) (defaults to: nil)

    Purchase orders for which the last purchase order update happened before this timestamp will be included in the result. Must be in ISO-8601 date/time format.

  • purchase_order_number (String) (defaults to: nil)

    Provides purchase order status for the specified purchase order number.

  • purchase_order_status (String) (defaults to: nil)

    Filters purchase orders based on the specified purchase order status. If not included in filter, this will return purchase orders for all statuses.

  • item_confirmation_status (String) (defaults to: nil)

    Filters purchase orders based on their item confirmation status. If the item confirmation status is not included in the filter, purchase orders for all confirmation statuses are included.

  • item_receive_status (String) (defaults to: nil)

    Filters purchase orders based on the purchase order’s item receive status. If the item receive status is not included in the filter, purchase orders for all receive statuses are included.

  • ordering_vendor_code (String) (defaults to: nil)

    Filters purchase orders based on the specified ordering vendor code. This value should be same as ‘sellingParty.partyId’ in the purchase order. If not included in filter, all purchase orders for all the vendor codes that exist in the vendor group used to authorize API client application are returned.

  • ship_to_party_id (String) (defaults to: nil)

    Filters purchase orders for a specific buyer’s Fulfillment Center/warehouse by providing ship to location id here. This value should be same as ‘shipToParty.partyId’ in the purchase order. If not included in filter, this will return purchase orders for all the buyer’s warehouses used for vendor group purchase orders.

  • rate_limit (Float) (defaults to: 10.0)

    Requests per second

Returns:



134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
# File 'lib/peddler/apis/vendor_orders_v1.rb', line 134

def get_purchase_orders_status(limit: nil, sort_order: nil, next_token: nil, created_after: nil,
  created_before: nil, updated_after: nil, updated_before: nil, purchase_order_number: nil,
  purchase_order_status: nil, item_confirmation_status: nil, item_receive_status: nil, ordering_vendor_code: nil,
  ship_to_party_id: nil, rate_limit: 10.0)
  path = "/vendor/orders/v1/purchaseOrdersStatus"
  params = {
    "limit" => limit,
    "sortOrder" => sort_order,
    "nextToken" => next_token,
    "createdAfter" => created_after,
    "createdBefore" => created_before,
    "updatedAfter" => updated_after,
    "updatedBefore" => updated_before,
    "purchaseOrderNumber" => purchase_order_number,
    "purchaseOrderStatus" => purchase_order_status,
    "itemConfirmationStatus" => item_confirmation_status,
    "itemReceiveStatus" => item_receive_status,
    "orderingVendorCode" => ordering_vendor_code,
    "shipToPartyId" => ship_to_party_id,
  }.compact

  meter(rate_limit).get(path, params:)
end