<?php
require_once '/Users/dwindown/Local Sites/woonoow/app/public/wp-load.php';

$request = new WP_REST_Request('POST', '/woonoow/v1/products');
$request->set_header('Content-Type', 'application/json');
$request->set_body(json_encode([
    'name' => 'Test Virtual Product',
    'type' => 'simple',
    'virtual' => true,
    'downloadable' => true
]));

$response = \WooNooW\Api\ProductsController::create_product($request);
print_r($response->get_data());
