Create New Product

Shopify Partner
1 0 1


i try to create a new product with a fetch call. I am using php to add a new product.

But i get this error: 

{"errors":{"product":"Required parameter missing or invalid"}}

Reply 1 (1)

Shopify Staff
246 58 71

Hi there 👋


From that error message is seems like you are missing one of the required parameters. Would you be able to share your code you are using to make the API request?

In the developer documentation you should find code sample for creating products with the Shopify API in PHP. 

use Shopify\Clients\Graphql;

$client = new Graphql("", $accessToken);
$query = <<<QUERY
  mutation {
    productCreate(input: {title: "Sweet new product", productType: "Snowboard", vendor: "JadedPixel"}) {
      product {

$response = $client->query(["query" => $query]);

To learn more visit the Shopify Help Center or the Community Blog.