service/ProductService.php
public static function create(Context $context, Product $product)
    {
        $response = NetLicensingService::getInstance()
            ->post($context, Constants::PRODUCT_ENDPOINT_PATH, $product->asPropertiesMap());

        $createdProduct = null;

        if (!empty($response->items->item[0])) {
            $createdProduct = ItemToProductConverter::convert($response->items->item[0]);
            $createdProduct->exists = true;
        }

        return $createdProduct;
    }
public static function create(Context $context, Product $product)
    {
        $response = NetLicensingService::getInstance()
            ->post($context, Constants::PRODUCT_ENDPOINT_PATH, $product->asPropertiesMap());

        $createdProduct = null;

        if (!empty($response->items->item[0])) {
            $createdProduct = ItemToProductConverter::convert($response->items->item[0]);
            $createdProduct->exists = true;
        }

        return $createdProduct;
    }
Creates new product with given properties.See NetLicensingAPI for details:
https://www.labs64.de/confluence/display/NLICPUB/Product+Services#ProductServices-Createproduct

determines the vendor on whose behalf the call is performed
@param \NetLicensing\Context $context

non-null properties will be taken for the new object, null properties will either stay null, or will
be set to a default value, depending on property.
@param \NetLicensing\Product $product

return the newly created product object
@return Product|null
@throws RestException
@throws \ErrorException