WC_REST_Orders_V1_Controller::prepare_line_items( array $posted, string $action = 'create' )
Create or update a line item.
Description Description
Parameters Parameters
- $posted
-
(Required) Line item data.
- $action
-
(Optional) 'create' to add line item or 'update' to update it.
Default value: 'create'
Return Return
Source Source
File: includes/rest-api/Controllers/Version1/class-wc-rest-orders-v1-controller.php