chengkun
2025-09-05 4822304b63e1bd6327860af7f3db0133cecf167f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<?php
/**
* This class is autogenerated by the Spapi class generator
* Date of generation: 2022-05-26
* Specification: https://github.com/amzn/selling-partner-api-models/blob/main/models/vendor-direct-fulfillment-orders-api-model/vendorDirectFulfillmentOrders_2021-12-28.json
* Source MD5 signature: 1ed4d32acafd031c861da6392731fac2
*
*
* Selling Partner API for Direct Fulfillment Orders
* The Selling Partner API for Direct Fulfillment Orders provides programmatic access to a direct fulfillment vendor's order data.
*/
namespace DoubleBreak\Spapi\Api;
use DoubleBreak\Spapi\Client;
 
class VendorDirectFulfillmentOrders extends Client {
 
  /**
  * Operation getOrders
  *
  * @param array $queryParams
  *    - *shipFromPartyId* string - The vendor warehouse identifier for the fulfillment warehouse. If not specified, the result will contain orders for all warehouses.
  *    - *status* string - Returns only the purchase orders that match the specified status. If not specified, the result will contain orders that match any status.
  *    - *limit* integer - The limit to the number of purchase orders returned.
  *    - *createdAfter* string - Purchase orders that became available after this date and time will be included in the result. Must be in ISO-8601 date/time format.
  *    - *createdBefore* string - Purchase orders that became available before this date and time will be included in the result. Must be in ISO-8601 date/time format.
  *    - *sortOrder* string - Sort the list in ascending or descending order by order creation date.
  *    - *nextToken* string - Used for pagination when there are more orders than the specified result size limit. The token value is returned in the previous API call.
  *    - *includeDetails* string - When true, returns the complete purchase order details. Otherwise, only purchase order numbers are returned.
  *
  */
  public function getOrders($queryParams = [])
  {
    return $this->send("/vendor/directFulfillment/orders/2021-12-28/purchaseOrders", [
      'method' => 'GET',
      'query' => $queryParams,
    ]);
  }
 
  public function getOrdersAsync($queryParams = [])
  {
    return $this->sendAsync("/vendor/directFulfillment/orders/2021-12-28/purchaseOrders", [
      'method' => 'GET',
      'query' => $queryParams,
    ]);
  }
 
  /**
  * Operation getOrder
  *
  * @param string $purchaseOrderNumber The order identifier for the purchase order that you want. Formatting Notes: alpha-numeric code.
  *
  */
  public function getOrder($purchaseOrderNumber)
  {
    return $this->send("/vendor/directFulfillment/orders/2021-12-28/purchaseOrders/{$purchaseOrderNumber}", [
      'method' => 'GET',
    ]);
  }
 
  public function getOrderAsync($purchaseOrderNumber)
  {
    return $this->sendAsync("/vendor/directFulfillment/orders/2021-12-28/purchaseOrders/{$purchaseOrderNumber}", [
      'method' => 'GET',
    ]);
  }
 
  /**
  * Operation submitAcknowledgement
  *
  */
  public function submitAcknowledgement($body = [])
  {
    return $this->send("/vendor/directFulfillment/orders/2021-12-28/acknowledgements", [
      'method' => 'POST',
      'json' => $body
    ]);
  }
 
  public function submitAcknowledgementAsync($body = [])
  {
    return $this->sendAsync("/vendor/directFulfillment/orders/2021-12-28/acknowledgements", [
      'method' => 'POST',
      'json' => $body
    ]);
  }
}