Trying to Update an Order Line
API request send to : https://api.ordoro.com/v3/order/{order_number}/line/{order_line_id}
$data = array(
‘quantity’ => 2,
“item_price” => 9.99,
“total_price” => 19.98,
);
public function updateOrderLine($orderNumber,$orderLineId,$data){
$url = ‘https://api.ordoro.com/v3/order/’. $orderNumber .‘/line/’.$orderLineId;
curl_setopt($this->ch, CURLOPT_URL, $url);
curl_setopt($this->ch, CURLOPT_CUSTOMREQUEST, ‘PUT’);
curl_setopt($this->ch, CURLOPT_POSTFIELDS, json_encode($data));
$result = curl_exec($this->ch);
curl_close($this->ch);
return $result;
}
Error Msg: ^ “{“error_message”: “Additional properties are not allowed (‘item_price’, ‘total_price’, ‘quantity’ were unexpected)”, “param”: null}”