CreateProduct
in package
Uses
RequiresManageWoocommerce
Mutation to create a new product.
Demonstrates: DI via init(), inherited capability (trait), ApiException with extensions.
Table of Contents
- $repository : ProductRepository
- The product repository.
- execute() : object
- Execute the mutation.
Properties
$repository
The product repository.
private
ProductRepository
$repository
Methods
execute()
Execute the mutation.
public
execute(CreateProductInput $input) : object
Parameters
- $input : CreateProductInput
-
The product creation data.
