Skip to Content
StoreOSv0.27.1
Core GraphQL APIReferenceMutations

Inventory__apply Seed Dataset

Creates sample products/collections from a curated dataset. Existing handles are skipped. Products are marked isDemo. Requires a signed-in staff user. Needs the `inventory__Product` `create` permission. Send the `x-tenant` header (the gateway sets it from your API key).

MUTATIONinventory__applySeedDataset(input: ApplySeedDatasetInput!): SeedDatasetResult!

Creates sample products/collections from a curated dataset. Existing handles are skipped. Products are marked isDemo. Requires a signed-in staff user. Needs the inventory__Product create permission. Send the x-tenant header (the gateway sets it from your API key).

Arguments

input*

Returns

  1. inventory__applySeedDataset
created*Int!
datasetId*String!
failed*Int!
items*
skipped*Int!
Example Request
mutation Inventory__applySeedDataset($input: ApplySeedDatasetInput!) {  inventory__applySeedDataset(input: $input) {    created    datasetId    failed    items {      handle      message      status      title    }    skipped  }}
Variables
{  "input": {    "datasetId": "string"  }}
Example Response
{  "data": {    "inventory__applySeedDataset": {      "created": 10,      "datasetId": "string",      "failed": 10,      "items": [        {          "handle": "string",          "message": "string",          "status": "string",          "title": "string"        }      ],      "skipped": 10    }  }}