@@ -131,14 +131,26 @@ FulfillmentOrder.prototype.fulfillments = function fulfillments(id) {
131
131
* Halts all fulfillment work on a fulfillment order with
132
132
* status OPEN and changes the status of the fulfillment order to ON_HOLD.
133
133
*
134
- * @param {Number } id Order ID
135
- * @return {Promise } Promise that resolves with the result
134
+ * @param {Number } id Fulfillment Order id (fulfillment_order_id).
135
+ * @param {Object } params
136
+ * @param {String } params.reason 'awaiting_paymet' | 'high_risk_of_fraud'
137
+ * | 'incorrect_address' | 'inventory_out_of_stock' | 'other'.
138
+ * @param {String } params.reason_notes (optiona) Additional information about
139
+ * the fulfillment hold reason.
140
+ * @param {Boolean } params.notify_merchant (optional) Whether the merchant
141
+ * should receive a notification about the fulfillment hold.
142
+ * If set to true, then the merchant will be notified on the Shopify
143
+ * mobile app (if they use it to manage their store).
144
+ * The default value is false.
145
+ * @param {Array } params.fulfillment_order_line_items (optional) array of
146
+ * fulfillment order line item ids and the quantity of each to move.
147
+ * @return {Promise } Promise that resolves with the result.
136
148
* @public
137
149
*/
138
150
FulfillmentOrder . prototype . hold = function hold ( id , params ) {
139
151
const url = this . buildUrl ( `${ id } /hold` ) ;
140
152
return this . shopify
141
- . request ( url , 'POST' , undefined , params )
153
+ . request ( url , 'POST' , undefined , { fulfillment_hold : params } )
142
154
. then ( ( body ) => body [ this . key ] ) ;
143
155
} ;
144
156
0 commit comments