createProduct

Version 2024-11-01

📘

Important

The Buy with Prime API is offered as a preview and might change as we receive feedback and iterate on the interfaces. We are sharing this early documentation to help you learn about the Buy with Prime API as we write and iterate on the content.

Overview

Create a Product.

ℹ️

Required scope(s)

View & Edit Catalog Data

Response

Return type CreateProductResponse

Arguments

ArgumentDescription
input (CreateProductInput required)

Specifies the input fields required to create a new Product.

Examples


Create Product

Request

mutation CreateProduct {
    createProduct(
        input: {
            externalId: "product-externalId"
            amazonSku: {
                value: "product-amazon-sku"
            }
            sku: "product-sku"
            offerPrime: true
            productDetailPageUrl: "https://example.com/products/my-product"
            image: {
                sourceUrl: "https://example.com/products/my-product.jpg"
            }
        }
    ) {
        id
    }
}

Response

{
    "data": {
        "createProduct": {
            "id": "abcdef01234567"
        }
    }
}