GoodDay API

Manage Products and Items

Use this guide to create Products and their Items, then read, update and archive them. Start by creating Attribute Definitions for the dimensions and attributes you need. The API reference describes each request and response field.

Send a bearer token with every request. See the authentication guide. Reads need the read:products scope and writes need write:products. Grant both by name; a * wildcard scope doesn't count.

GoodDay enables the Products API per account. Until then, every Products and Attribute Definitions request returns 403 FEATURE_NOT_ENABLED. Ask GoodDay to enable it.

Base URL for every request:

https://api.gooddayai.com/v1

Successful responses put the result in data. List responses also include pagination. Ids are integers.

Products created outside the API (in the GoodDay app, by CSV import or by a sales channel) aren't available on these routes yet. Lists leave them out and reads return 404. Read them with GET /v1/items.

Concepts

Step 1: Create the Attribute Definitions

Send POST /v1/attribute-definitions to create a Definition. Include options when you want to create its allowed values at the same time. Their array order sets their display order. All or nothing.

curl -X POST https://api.gooddayai.com/v1/attribute-definitions \
  -H "Authorization: Bearer gd_yourTokenValueHere" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Color",
    "attributeType": "dimension",
    "valueType": "option",
    "options": [
      { "code": "BLK", "label": "Black" },
      { "code": "NVY", "label": "Navy" }
    ]
  }'

The 201 response contains data.definition and data.options. Each new option includes its id, code, label and sortOrder. The first option has sortOrder: 0. Use the returned ids in later requests, or refer to Definitions by name and options by code.

Create a Size Definition with attributeType: "dimension", valueType: "option" and options with codes S and M. Create Material with attributeType: "data" and valueType: "text". Definition names must be unique in your account, ignoring case. Creating color after Color returns 409 ATTRIBUTE_DEFINITION_NAME_EXISTS. details[].existingId identifies the existing Definition.

Send PATCH /v1/attribute-definitions/{definitionId} to change name or description, or to add, relabel, remove or move options. All or nothing. Omitted fields stay unchanged. sortOrder starts at 0. Adding or moving an option shifts other options around it. A position past the end puts it last. A new option without sortOrder goes last. Changing a dimension option's label updates Item display names that use it. Renaming the Definition does not change Item names. An option still in use cannot be removed and returns 409 ATTRIBUTE_OPTION_IN_USE. Archived Products and Items also prevent option removal.

A Product is treated as linked to Shopify when its Product connection or a non-archived Item has a Shopify link. A Definition rename or option label change that would update a linked Product is rejected with 409 SHOPIFY_LINKED_FIELD_LOCKED. Each detail identifies a Product with productId and the affected request field. The response lists up to 20 Products. If more are affected, another detail states how many were omitted. Make the change through Shopify. A label change that does not affect a linked Product can still succeed.

Use GET /v1/attribute-definitions to list Definitions. Filter by attributeType or an exact name. Use GET /v1/attribute-definitions/{definitionId}/options to list options in sortOrder. Filter by code or id.

A Definition rename or option label change can affect at most 500 Products and Items combined. It can affect at most 5,000 stored attribute values. An affected Product counts with all of its Items, not only the Items whose names change. A label change affects each Product with an Item using that option. A rename affects every Product with that dimension. Split relabels across requests. A single change that is still too large needs GoodDay's help. This includes a label change on a Product with more than 499 Items.

Step 2: Create a Product with its Items

Send POST /v1/products to create a Product with one to three dimensions and up to 2,048 Items. Omit items or send an empty array to add Items later. All or nothing. Name each existing Definition with definitionName, or use definitionId, not both. An unknown Definition returns 422; the request does not create it. Each Item needs one dimensionValues entry for every Product dimension, in any order. For an option dimension, send code, or optionId, not both. For a text dimension, send value.

A new Product defaults to draft. Send status: "active" to create it as active. If you leave out an Item's status or send null, it takes the Product's status; if the Product has none, it is draft. You can explicitly set an Item to either status. Adding Items to an archived Product returns 409 ARCHIVED_PRODUCT_STRUCTURE_LOCKED; reactivate the Product first.

This example refers to the Definitions created in Step 1 by name, and to their options by code.

curl -X POST https://api.gooddayai.com/v1/products \
  -H "Authorization: Bearer gd_yourTokenValueHere" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: create-merino-crew-1" \
  -d '{
    "name": "Merino Crew",
    "sku": "MERINO-CREW",
    "status": "active",
    "dimensions": [{ "definitionName": "Color" }, { "definitionName": "Size" }],
    "attributes": [{ "definitionName": "Material", "value": "100% merino" }],
    "items": [
      {
        "sku": "MERINO-CREW-BLK-S",
        "dimensionValues": [
          { "definitionName": "Color", "code": "BLK" },
          { "definitionName": "Size", "code": "S" }
        ]
      },
      {
        "sku": "MERINO-CREW-BLK-M",
        "dimensionValues": [
          { "definitionName": "Color", "code": "BLK" },
          { "definitionName": "Size", "code": "M" }
        ]
      }
    ]
  }'

Example 201 response. Ids and timestamps are illustrative. The second Item is omitted for space.

{
  "data": {
    "product": {
      "id": 1,
      "status": "active",
      "name": "Merino Crew",
      "sku": "MERINO-CREW",
      "description": null,
      "dimensions": [
        { "definitionId": 1, "name": "Color", "position": 1 },
        { "definitionId": 2, "name": "Size", "position": 2 }
      ],
      "attributes": [{ "definitionId": 3, "name": "Material", "value": "100% merino" }],
      "itemCount": 2,
      "createdAt": "2026-10-29T14:40:21.708Z",
      "updatedAt": "2026-10-29T14:40:21.788Z"
    },
    "items": [
      {
        "id": 3,
        "itemType": "item",
        "productId": 1,
        "groupingProductIds": [],
        "name": null,
        "displayName": "Black / S",
        "sku": "MERINO-CREW-BLK-S",
        "upc": null,
        "description": null,
        "status": "active",
        "archiveReason": null,
        "unitOfMeasure": null,
        "dimensionValues": [
          { "definitionId": 1, "optionId": 1, "code": "BLK", "label": "Black" },
          { "definitionId": 2, "optionId": 3, "code": "S", "label": "S" }
        ],
        "attributes": [],
        "createdAt": "2026-10-29T14:40:21.760Z",
        "updatedAt": "2026-10-29T14:40:21.760Z"
      }
    ]
  }
}

Use attributes for extra information on a Product or Item. A data Definition can be an attribute. A dimension Definition can also be an attribute if it is not one of this Product's dimensions. Product attributes are not copied to Items. Supply each Item's attributes separately.

Step 3: Read Products and Items

GET /v1/products/{productId} returns the Product's dimensions, attributes and itemCount. The count includes draft and active Items. The response does not include the Items themselves.

GET /v1/products lists Products. Filter by status, the Product's sku, createdAt[gte], createdAt[lte], updatedAt[gte] or updatedAt[lte]. Date filters require an ISO 8601 date-time, such as 2026-10-29T14:40:00Z. Dates without times are not accepted. Filter by Product SKU with sku=A&sku=B, up to 250. Item SKUs don't match. Don't separate SKUs with commas: a SKU can contain one. Filter by several ids with ids, up to 250.

Filter by dimension with dimension[<definitionId>]=CODE and by attribute with attribute[<definitionId>]=VALUE. Repeat a key for OR. Different keys are AND. Up to 3 dimension keys, 5 attribute keys and 10 values per key. An unknown Definition id, a Definition the filter cannot use, an unknown option code or a blank value returns 422. A text value that matches nothing returns an empty page. A Product matches on any non-archived Item, and two different Items can satisfy the AND. An attribute filter matches the Product's own attributes.

GET /v1/products/{productId}/items lists the Product's Items. Filter by id, sku, status, updatedAt[gte] or updatedAt[lte]. Date filters require a date-time. By default, Items follow dimension position and option order, such as Black / S, Black / M, Navy / S. Text dimensions use Item id order. An unmatched Item filter returns an empty list. An unavailable Product returns 404. The dimension and attribute filters work here too, with one difference: all conditions must hold on the same Item.

Product and Item lists include all statuses unless you supply status. For multiple statuses, separate values with commas or repeat the parameter. Both lists accept sortBy=createdAt or sortBy=updatedAt. Use sortOrder=desc for descending order. The default is ascending. sortOrder has no effect without sortBy. Products default to ascending id order.

Paging with the cursor

Every list returns pagination. This one comes from the first page of GET /v1/products with no sortBy:

{
  "mode": "cursor",
  "hasMore": true,
  "nextCursor": "eyJpZCI6NTB9"
}

While hasMore is true, send nextCursor as cursor in the next request. Copy it unchanged and keep the same filters and sort settings. An invalid cursor returns 400. Omit cursor to start again. limit defaults to 50. Above 250 returns 422, on every list.

If option order changes while you read a Product's Items, you may miss or repeat Items across pages. Start again from the first page to read them in the new order.

Step 4: Add Items

Send POST /v1/products/{productId}/items to add 1 to 2,048 Items. All or nothing. If the request fails, none of its changes are saved. Check the paths in error.details to find the reported problems. A response may not report every problem. An example error follows.

{
  "error": {
    "code": "SKU_ALREADY_EXISTS",
    "message": "A SKU in this request is already in use.",
    "details": [
      {
        "field": "items[1].sku",
        "code": "SKU_ALREADY_EXISTS",
        "existingId": 3,
        "productId": 1,
        "message": "Another Item or Product already has this SKU",
        "index": 1
      }
    ],
    "documentationUrl": "https://api.gooddayai.com/docs/reference#errors"
  }
}

Step 5: Update the Product and its Items

Send PATCH /v1/products/{productId} to update name, description, status or attributes. Use removeAttributes to remove attributes by Definition id. Omitted fields stay unchanged. attributes adds or replaces the listed values; it does not replace the whole attributes list. To change dimensions, send the complete list. The Product must be a draft that has never had Items. Otherwise, the request returns 409 PRODUCT_STRUCTURE_LOCKED with reason not_draft or item_history. Sending the current dimensions in the same order is accepted, except on a Product linked to Shopify. Any name or dimensions field on a Product linked to Shopify returns 409 SHOPIFY_LINKED_FIELD_LOCKED. Reactivate an archived Product in a separate request before changing its name.

Send PATCH /v1/products/{productId}/items to update 1 to 100 Items. Identify each entry with itemId. All or nothing. The response follows request order. To update one Item, send an array with one entry. Entries apply in request order, so a direct swap of two SKUs in one request fails.

{
  "items": [
    { "itemId": 7, "upc": "012345678905" },
    { "itemId": 3, "attributes": [{ "definitionName": "Material", "value": "merino blend" }] }
  ]
}

Sending dimensionValues replaces the Item's complete set of dimension values. To change them, the Item must have no integration link and no sales order, purchase order, inventory, receipt or adjustment history. Removed order or inventory entries still count as history. Otherwise, the request returns 409 ITEM_STRUCTURE_LOCKED with reason external_link or history. Sending unchanged values does not trigger this particular lock. Attribute changes are not subject to this lock.

One request cannot swap dimension values between two Items. It returns 409 DIMENSION_COMBINATION_ALREADY_EXISTS at the earlier of the two swapped entries, and nothing changes. Entries apply in request order, so the earlier entry asks for values the later Item still has. A later entry may take a combination an earlier entry gave up. An Item may appear only once per request (DUPLICATE_ITEM_IN_REQUEST). So a swap takes two requests. To swap Items A and B, first send A with a free combination, then B with A's old values, in that order in one request. Listing B first returns the same 409. Then send A with B's old values. The swap is not atomic. If the second request fails, A keeps the free combination and B keeps A's old values. Retry the second request until it succeeds, or undo the first with one request that sends B with its own old values, then A with its old values, in that order.

Reactivate an archived Item in a separate request before changing its sku, upc or dimensionValues. These fields cannot be supplied together with reactivation. For an Item linked to Shopify, change these fields through Shopify.

On update, send null to clear description, upc or unitOfMeasure. Omit a field to leave it unchanged. sku cannot be cleared. A unit of measure cannot change while an active work order has work in progress for this Item as a component.

unitOfMeasure takes one of the listed values and common forms such as EA and lbs, which are saved as the listed value.

Step 6: Archive and reactivate

A Product can move from draft to active, from active to archived, or from archived to active. It cannot move directly from draft to archived. An Item can move from draft to active or archived, from active to archived, or from archived to active. Sending the current status changes nothing. An Item archived with its Product may later return to draft when the Product is reactivated. Activating a Product leaves its draft Items as draft.

Set a Product's status to archived to archive all its draft and active Items. Set it to active to restore the Items archived with it that still belong to the Product and remain archived. Each returns to its previous status. If another non-archived Item has one of their dimension combinations, the request returns 409 DIMENSION_COMBINATION_ALREADY_EXISTS and lists the conflicts. All or nothing. While the Product is archived, adding Items returns 409 ARCHIVED_PRODUCT_STRUCTURE_LOCKED. Changing an Item's status or supplying its dimensionValues returns 409 ARCHIVED_PRODUCT_STRUCTURE_LOCKED. Reactivate the Product first. Shopify restrictions can also prevent these changes.

Archiving does not free a Product's or Item's SKU for reuse.

Retries and lost responses

Send an Idempotency-Key with POST and PATCH requests. Use up to 255 characters. Keys are scoped to your token and account. Retry the same request with the same key within 24 hours to receive the saved response. Use a new key for a new request. Changing the method, path or body returns 409 CONFLICT. A request still in progress also returns 409 CONFLICT; retry shortly. These errors have no details.

All or nothing. A lost response does not tell you whether the request succeeded. If you retry Product creation and its SKU already belongs to a Product available on these routes, the response is 409 PRODUCT_ALREADY_EXISTS. This identifies an existing Product; it does not prove the earlier request created it. An example error follows.

{
  "error": {
    "code": "PRODUCT_ALREADY_EXISTS",
    "message": "A Product with this SKU already exists.",
    "details": [
      {
        "field": "sku",
        "code": "PRODUCT_ALREADY_EXISTS",
        "conflictingProductId": 1,
        "message": "A Product with this SKU already exists"
      }
    ],
    "documentationUrl": "https://api.gooddayai.com/docs/reference#errors"
  }
}

Use details[].conflictingProductId to get the Product and list its Items with GET /v1/products/{productId}/items. Compare them with the request you intended to send. Repeating Item creation can return 409 SKU_ALREADY_EXISTS if a requested SKU is already in use. When available, details[].existingId identifies the existing Item and productId identifies its Product.

A 409 SKU_ALREADY_EXISTS response may omit existingId. Missing ids do not prove the resource is unavailable. Look up the SKU with GET /v1/items?sku=.... This failed request saved no changes.

Errors

Errors contain an error object with a code, a message and any available details. Use error.code and details[].code to decide what to do. Each detail identifies a field or request entry, such as items[2].dimensionValues[0].code. Array positions start at 0. When validation details have different codes, the top-level code is VALIDATION_ERROR. Check all returned details. An invalid or unsupported field in a request body returns 400, and so does an invalid cursor. An invalid or unsupported query parameter returns 422. An unavailable Product or Definition id in the path returns 404. Invalid references in a request body normally return 422.

A missing or invalid bearer token returns 401. If you exceed the rate limit, the response is 429 Too Many Requests with a Retry-After header giving the seconds to wait. Wait that long, then retry.

Code Meaning
FEATURE_NOT_ENABLED The Products API is not enabled for this account. Ask GoodDay to enable it.
ATTRIBUTE_DEFINITION_NAME_EXISTS A Definition already uses this name. Reuse the Definition identified by details[].existingId, or choose another name.
ATTRIBUTE_OPTION_EXISTS This Definition already has an option with this code. Reuse the option identified by details[].existingId, or choose another code.
DUPLICATE_OPTION_IN_REQUEST An option code is repeated, an option id appears twice in the same option array, or an option is both removed and relabeled or moved. Remove the conflicting entry. The same option may be relabeled and moved in one request.
ATTRIBUTE_FIELD_IMMUTABLE attributeType, valueType and option codes cannot be changed. Omit these fields from the update. Create a new Definition or option if you need a different type or code.
ATTRIBUTE_OPTION_IN_USE The option is still held by Products or Items, archived ones included. details[].inUseCount says how many. Keep the option, or change those values and try again.
ATTRIBUTE_DISPLAY_CHANGE_TOO_LARGE The change exceeds 500 affected Products and Items combined, or 5,000 stored attribute values. An affected Product counts with all of its Items. Split relabels across requests. A single change that is still too large needs GoodDay's help.
ATTRIBUTE_DEFINITION_NOT_FOUND No active Definition matches this id or name. List Attribute Definitions and use an existing id or name.
ATTRIBUTE_DEFINITION_NOT_DIMENSION This Definition cannot be used as a Product dimension. Use a Definition with attributeType: "dimension" and valueType: "option" or "text".
DUPLICATE_DIMENSION The same Definition appears more than once in dimensions. Include it once.
TOO_MANY_DIMENSIONS The request contains more than three dimensions. Send one to three.
DIMENSION_VALUE_NOT_FOUND No option matches the requested dimension value. List that Definition's options and use an existing option id or code.
DIMENSION_VALUES_MISMATCH A dimension is missing a value, has more than one value, or has text that is empty or contains only spaces. Send exactly one nonblank value for each Product dimension. details[].definitionId identifies a missing or repeated dimension; an empty or space-only text value is reported at its own dimensionValues[j] entry.
NOT_A_PRODUCT_DIMENSION A dimensionValues entry does not identify one of this Product's dimensions. Get the Product and use a Definition listed in its dimensions.
ATTRIBUTE_OPTION_NOT_FOUND The option does not belong to this Definition or has been removed. This can affect an attribute value or an option update, move or removal. List the Definition's options and use an existing id or code.
ATTRIBUTE_VALUE_TYPE_MISMATCH The supplied value does not match the Definition's value type, or options were supplied for a Definition that does not accept them. For an option Definition, send optionId or code. For a text Definition, send nonblank value.
ATTRIBUTE_IS_DIMENSION A Definition cannot be both an attribute and a dimension of the same Product. Set an Item's dimension value through dimensionValues. When changing Product dimensions, remove any conflicting Product attribute.
DUPLICATE_ATTRIBUTE_IN_REQUEST The same Definition appears twice in an attributes list, or is both set and removed in one request. Keep only one action for that attribute.
DERIVED_NAME_TOO_LONG The dimension values would make an Item display name longer than 200 characters, or an option label is too long for an affected Item. Shorten the labels or text values identified in the error.
SKU_ALREADY_EXISTS Another Item or Product already uses this SKU. Archived ones also reserve their SKUs. Use a different SKU, or look up the existing one with GET /v1/items?sku=....
PRODUCT_ALREADY_EXISTS A Product available on these routes already uses this SKU. Use details[].conflictingProductId to get it and list its Items before deciding whether to create anything else.
DUPLICATE_SKU_IN_REQUEST The request repeats a SKU, including an Item using the new Product's SKU. Give each Product and Item a distinct SKU. Matching ignores case and accents.
RESERVED_SKU_PREFIX The SKU starts with __gd_product__:, which is reserved. Choose a different SKU.
DIMENSION_COMBINATION_ALREADY_EXISTS Another non-archived Item in this Product has the same dimension values. Use a different combination, or archive the conflicting Item before retrying.
DUPLICATE_COMBINATION_IN_REQUEST Two new Items in the request have the same dimension values. Remove the duplicate or give it a different combination.
ITEM_LIMIT_EXCEEDED The change would exceed the Product's limit of 4,096 non-archived Items. Add or reactivate fewer Items, or archive Items first.
ITEM_NOT_IN_PRODUCT An itemId does not identify an Item in this Product. List the Product's Items and use an id from that list.
DUPLICATE_ITEM_IN_REQUEST The update includes the same Item more than once. Combine its changes into one entry.
INVALID_PRODUCT_STATUS_TRANSITION This Product cannot move directly to the requested status. Allowed changes are draft to active, active to archived, and archived to active.
INVALID_ITEM_STATUS_TRANSITION This Item cannot move directly to the requested status. Allowed changes are draft to active or archived, active to archived, and archived to active.
PRODUCT_STRUCTURE_LOCKED The Product is not a draft or has had Items. Its dimensions cannot change. Check reason for not_draft or item_history. Use a new Product if you need different dimensions.
ITEM_STRUCTURE_LOCKED The Item has an integration link or order, inventory, receipt or adjustment history. Its dimension values cannot change. Check reason for external_link or history. Use a new Item if you need a different combination.
ARCHIVED_PRODUCT_STRUCTURE_LOCKED The Product is archived. Reactivate it before changing its name, adding Items, changing an Item's status or supplying Item dimension values. Each returns 409.
SHOPIFY_LINKED_FIELD_LOCKED Make this change through Shopify. For a Product linked to Shopify, the API rejects name, dimensions and new Items. For a linked Item, it rejects sku, upc and dimensionValues. It also rejects Definition renames and option label changes that would update a linked Product.
UNIT_OF_MEASURE_LOCKED The Item is a component of an active work order with work in progress. Keep its current unit until that work no longer prevents the change.
REQUEST_ENTRY_LIMIT_EXCEEDED The request exceeds 20,480 dimension values, attribute values and attribute removals combined. Split the work into smaller requests.
PAYLOAD_TOO_LARGE The Product or Item request body exceeds 2 MiB (2,097,152 bytes). Send a smaller request.
RESOURCE_NOT_FOUND The Product or Attribute Definition in the path is unavailable to this account on these routes. Check the id and account.
AUTHORIZATION_ERROR The token lacks the required scope. Reads need read:products; writes need write:products. A * wildcard scope doesn't count.
CONFLICT For details[].field: "concurrentWrite", another change prevented this request from completing. Nothing was saved; retry the request. For productStructure, the message is "The Product is stored in a state this request cannot change. Contact GoodDay to fix it." Contact GoodDay with the Product id and the X-Request-Id. Without details, the retry key may be in progress or belong to a different request. Retry shortly if it is in progress. Use a new key for a different request.
VALIDATION_ERROR Check the reported field paths and any detail codes. Correct the request before retrying. An archived Item must be reactivated in a separate request before changing its SKU, UPC or dimension values.

Limits

Limit Value
Items in a Product creation request or an add-Items request Up to 2,048. Product creation may omit Items; adding Items requires at least one.
Items in an Item update request 1 to 100
Non-archived Items per Product 4,096
Attribute values supplied for each Product or Item in one request Up to 50
Attribute removals supplied for each Product or Item in one request Up to 50
Total dimension values, attribute values and attribute removals in a Product creation, Item creation or Item update request 20,480 combined
Entries in each options array of a Definition request 1,000 per array
Products and Items affected by one Definition rename or option label change 500 Products and Items combined. At most 5,000 stored attribute values. An affected Product counts with all of its Items.
Product and Item request body size 2 MiB (2,097,152 bytes of the request body)
Results per page Defaults to 50. Above 250 returns 422, on every list.
Time a retry key can return the original response 24 hours