created

created

Appears in:
Hook Type: action

See hook in core

Displaying hooks found in version: woocommerce.10.3.4

do_action('created') is found 2 times:

  • /src/RestApi/Routes/V4/OrderNotes/Controller.php line 306
    		 * @param WP_Comment         $note    Inserted object.
    		 * @param WP_REST_Request $request   Request object.
    		 * @since 10.2.0
    		 */
    		do_action( $this->get_hook_prefix() . 'created', $note, $request );
    
    		$request->set_param( 'context', 'edit' );
    		$response = $this->prepare_item_for_response( $note, $request );
    		$response->set_status( WP_Http::CREATED );
    		$response->header( 'Location', rest_url( sprintf( '/%s/%s/%d', $this->namespace, $this->rest_base, $note_id ) ) );
    
    
  • /src/RestApi/Routes/V4/Orders/Controller.php line 295
    			 * @param WC_Order         $order    Inserted object.
    			 * @param WP_REST_Request $request   Request object.
    			 * @since 10.2.0
    			 */
    			do_action( $this->get_hook_prefix() . 'created', $order, $request );
    
    			$request->set_param( 'context', 'edit' );
    			$response = $this->prepare_item_for_response( $order, $request );
    			$response->set_status( WP_Http::CREATED );
    			$response->header( 'Location', rest_url( sprintf( '/%s/%s/%d', $this->namespace, $this->rest_base, $order->get_id() ) ) );