Update product

Updates an existing product or component in the Sodtrack catalog, identified by its internal id or its sku.

PATCH/api/integration/product

Request

cURL
curl -X PATCH "https://dev.integration.cl.sodtrack-shared.sodtrack.com/api/integration/product" \
  -H "Authorization: Bearer $SODTRACK_TOKEN" \
  -H "origin: <your-origin>"

Base URL: https://dev.integration.cl.sodtrack-shared.sodtrack.com · other environments

Headers

NameTypeDescription
originstring

Responses

Update product
{
  "id": "316",
  "sku": "COMP-0001",
  "name": "Oil filter premium",
  "description": "High-flow oil filter (updated)",
  "category": "Filters",
  "brand": "K&N",
  "type": "component"
}

Error responses for this endpoint follow the shared error reference.

Purpose

Updates an existing product or component in the Sodtrack catalog, identified by its internal id or its sku.

This is a partial update: only the fields you send are changed. The target product is selected through the product object, which specifies whether you are addressing it by internal id or by sku. The updated product is returned in full.


Authentication

HeaderRequiredDescription
x-api-keyExternal integration API key provided by Sodtrack.

Field Definitions

🔎 Product selector

FieldTypeRequiredDescription
productobjectIdentifies the product/component to update.
product.typestringOne of: "productId", "productSku". Determines how product.value is interpreted.
product.valuestringInternal Sodtrack id when type is "productId", or the sku when type is "productSku".

📦 Product (fields to update)

FieldTypeRequiredDescription
namestringNew display name. Left unchanged if omitted.
descriptionstringNew description. Left unchanged if omitted.
categorystringCategory name. Created automatically if it does not exist.
brandstringBrand name. Created automatically if it does not exist.

🏷️ Tags

FieldTypeRequiredDescription
tagsarrayWhen sent, replaces the product's full tag set. Omit to leave tags untouched.
tags[].namestring✅ when a tag is sentTag name. Created automatically if it does not exist.
tags[].valuestring✅ when a tag is sentValue assigned to the tag.

Example Request — by sku

json
{
  "product": { "type": "productSku", "value": "COMP-0001" },
  "description": "High-flow oil filter (updated)",
  "category": "Filters",
  "brand": "K&N",
  "tags": [
    { "name": "Warranty", "value": "24 months" }
  ]
}

Example Request — by internal id

json
{
  "product": { "type": "productId", "value": "326" },
  "name": "Oil filter premium"
}

Response Example

json
{
  "id": "316",
  "sku": "COMP-0001",
  "name": "Oil filter premium",
  "description": "High-flow oil filter (updated)",
  "category": "Filters",
  "brand": "K&N",
  "type": "component"
}

Response Fields

FieldTypeDescription
idstringUnique Sodtrack identifier of the product.
skustringProduct/component code.
namestringDisplay name.
descriptionstringDescription, or null.
categorystringResolved category name, or null.
brandstringResolved brand name, or null.
typestring"product" or "component".

Error Responses

HTTP StatusErrorDescription
400 Bad RequestInvalidParametersThe product selector is missing/invalid, or product.type is not "productId" / "productSku".
401 UnauthorizedMissing or invalid x-api-key.
404 Not FoundNo product exists for the given id or sku.
500 Internal Server ErrorUnexpected server error. Contact Sodtrack support.

Business Rules & Constraints

Product selection

product.typeproduct.value contains
"productId"The internal Sodtrack id of the product.
"productSku"The sku of the product.

Only "productId" and "productSku" are supported. Any other selector type is rejected with 400 Bad Request.

Partial update

Only the fields present in the request are modified. Omitted fields keep their current values.

Tag replacement

When tags is included, the product's existing tags are replaced by the provided set. To keep current tags, omit the tags field. Sending an empty name/value is not valid.