Skip to content

Update product by ID

PATCH
/v1/products/{product_id}
curl --request PATCH \
--url https://api.loyx.se/partners/v1/products/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "brand": "example", "categories": [ "example" ], "description": "example", "external_product_id": "example", "identifiers": [ { "type": "example", "value": "example" } ], "is_loyalty_program_eligible": true, "loyx_app_active": true, "loyx_business_app_active": true, "name": "example", "page_url": "example", "price": { "currency": "SEK", "value": 1 }, "stores": [ { "price": { "currency": "SEK", "value": 1 }, "store_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" } ], "unit": "example" }'

Partially update a product. Only include the fields you want to change. Omitted fields are left unchanged. Set a field to null to clear it.

product_id
required
Product Id

The product’s internal UUID.

string format: uuid

The product’s internal UUID.

Idempotency-Key
Any of:
string

Optional. When provided, retrying with the same key returns the original result.

Media typeapplication/json
ProductUpdateRequest

Partial update for an existing product.

Only fields explicitly sent in the request body are applied. Fields sent as null clear their value, except price, name, loyx_app_active, loyx_business_app_active and is_loyalty_program_eligible, which cannot be cleared; omitted fields are left unchanged. Immutable fields (company_id, company_logo_url, etc.) are rejected at the service layer.

object
brand
Any of:
string
<= 255 characters
categories
Any of:
Array<string>
description
Any of:
string
<= 2000 characters
external_product_id
Any of:
string
>= 1 characters <= 255 characters
identifiers
Any of:
Array<object>
<= 20 items
IdentifierInput

Typed product identifier (gtin / ean13 / ean8 / sku / pos).

object
type
required
Type

Identifier type: gtin, ean13, ean8, sku, or pos.

string
value
required
Value
string
>= 1 characters <= 255 characters
is_loyalty_program_eligible
Any of:
boolean
loyx_app_active
Any of:
boolean
loyx_business_app_active
Any of:
boolean
name
Any of:
string
>= 1 characters <= 255 characters
page_url
Any of:
string
<= 2048 characters
price
Any of:
PriceInput

Monetary amount in minor units + currency code (request input).

object
currency
Currency

ISO 4217 currency code

string
default: SEK
value
required
Value

Amount in minor units (e.g. öre, cents)

integer
stores
Any of:
Array<object>
>= 1 items
ProductStoreInput

Store assortment entry: a store that carries the product.

object
price
Any of:
PriceInput

Monetary amount in minor units + currency code (request input).

object
currency
Currency

ISO 4217 currency code

string
default: SEK
value
required
Value

Amount in minor units (e.g. öre, cents)

integer
store_id
required
Store Id

Internal UUID of a store that carries this product.

string format: uuid
unit
Any of:
string

The updated product.

Media typeapplication/json
ProductResponse

Catalog-only product response.

Per-store pricing lives in the stores_products schemas (GET /stores/{store_id}/products).

object
_id
required
Id
string format: uuid
brand
Any of:
string
categories
Categories
Array<string>
company_category
Any of:
string
company_display_name
Any of:
string
company_logo_url
Any of:
string
created_at
required
Created At
string format: date-time
description
Any of:
string
external_product_id
Any of:
string
identifiers
Identifiers
Array<object>
IdentifierResponse

Typed product identifier in API responses.

object
type
required
Type
string
value
required
Value
string
image_link
Any of:
string
is_loyalty_program_eligible
required
Is Loyalty Program Eligible
boolean
loyx_app_active
required
Loyx App Active
boolean
loyx_business_app_active
required
Loyx Business App Active
boolean
name
required
Name
string
page_url
Any of:
string
price
required
Any of:
PriceSchema

Monetary amount in minor units + currency code + formatting metadata (response).

Includes minor_units (divisor to convert to major units) and locale (RFC 5646) so the client can display prices without hardcoding rules.

object
currency
Currency

ISO 4217 currency code

string
default: SEK
locale
required
Locale

RFC 5646 locale for formatting (e.g. sv-SE)

string
minor_units
required
Minor Units

Divisor to convert to major units (e.g. 100 for SEK)

integer
value
required
Value

Amount in minor units (e.g. öre, cents)

integer
unit
required
Unit
string
updated_at
required
Updated At
string format: date-time

Example

{
"price": {
"currency": "SEK"
}
}

missing_token, invalid_authorization_header or invalid_token: get a new access token and retry once.

Media typeapplication/json
ErrorResponse

Standard error response format.

object
error
required
ErrorDetail

Error detail structure (Stripe-like format).

object
code
required
Code

Machine-readable error code

string
details
Any of:
Array<object>
FieldErrorDetail

One failing field of a validation error.

object
message
required
Message

Why the value was refused

string
param
required
Param

Dotted path of the field, e.g. items.0.unit_price.value

string
doc_url
Any of:
string
message
required
Message

Human-readable error message

string
param
Any of:
string
type
required
Type

Error type category

string
request_id
Any of:
string

Example generated

{
"error": {
"code": "example",
"details": [
{
"message": "example",
"param": "example"
}
],
"doc_url": "example",
"message": "example",
"param": "example",
"type": "example"
},
"request_id": "example"
}

insufficient_scope: the API key lacks the scope this route needs.

Media typeapplication/json
ErrorResponse

Standard error response format.

object
error
required
ErrorDetail

Error detail structure (Stripe-like format).

object
code
required
Code

Machine-readable error code

string
details
Any of:
Array<object>
FieldErrorDetail

One failing field of a validation error.

object
message
required
Message

Why the value was refused

string
param
required
Param

Dotted path of the field, e.g. items.0.unit_price.value

string
doc_url
Any of:
string
message
required
Message

Human-readable error message

string
param
Any of:
string
type
required
Type

Error type category

string
request_id
Any of:
string

Example generated

{
"error": {
"code": "example",
"details": [
{
"message": "example",
"param": "example"
}
],
"doc_url": "example",
"message": "example",
"param": "example",
"type": "example"
},
"request_id": "example"
}

Product not found.

Media typeapplication/json
ErrorResponse

Standard error response format.

object
error
required
ErrorDetail

Error detail structure (Stripe-like format).

object
code
required
Code

Machine-readable error code

string
details
Any of:
Array<object>
FieldErrorDetail

One failing field of a validation error.

object
message
required
Message

Why the value was refused

string
param
required
Param

Dotted path of the field, e.g. items.0.unit_price.value

string
doc_url
Any of:
string
message
required
Message

Human-readable error message

string
param
Any of:
string
type
required
Type

Error type category

string
request_id
Any of:
string

Example generated

{
"error": {
"code": "example",
"details": [
{
"message": "example",
"param": "example"
}
],
"doc_url": "example",
"message": "example",
"param": "example",
"type": "example"
},
"request_id": "example"
}

Another product already has this external_product_id.

Media typeapplication/json
ErrorResponse

Standard error response format.

object
error
required
ErrorDetail

Error detail structure (Stripe-like format).

object
code
required
Code

Machine-readable error code

string
details
Any of:
Array<object>
FieldErrorDetail

One failing field of a validation error.

object
message
required
Message

Why the value was refused

string
param
required
Param

Dotted path of the field, e.g. items.0.unit_price.value

string
doc_url
Any of:
string
message
required
Message

Human-readable error message

string
param
Any of:
string
type
required
Type

Error type category

string
request_id
Any of:
string

Example generated

{
"error": {
"code": "example",
"details": [
{
"message": "example",
"param": "example"
}
],
"doc_url": "example",
"message": "example",
"param": "example",
"type": "example"
},
"request_id": "example"
}

Validation Error

Media typeapplication/json
ErrorResponse

Standard error response format.

object
error
required
ErrorDetail

Error detail structure (Stripe-like format).

object
code
required
Code

Machine-readable error code

string
details
Any of:
Array<object>
FieldErrorDetail

One failing field of a validation error.

object
message
required
Message

Why the value was refused

string
param
required
Param

Dotted path of the field, e.g. items.0.unit_price.value

string
doc_url
Any of:
string
message
required
Message

Human-readable error message

string
param
Any of:
string
type
required
Type

Error type category

string
request_id
Any of:
string

Example generated

{
"error": {
"code": "example",
"details": [
{
"message": "example",
"param": "example"
}
],
"doc_url": "example",
"message": "example",
"param": "example",
"type": "example"
},
"request_id": "example"
}

rate_limit_exceeded: wait Retry-After seconds.

Media typeapplication/json
ErrorResponse

Standard error response format.

object
error
required
ErrorDetail

Error detail structure (Stripe-like format).

object
code
required
Code

Machine-readable error code

string
details
Any of:
Array<object>
FieldErrorDetail

One failing field of a validation error.

object
message
required
Message

Why the value was refused

string
param
required
Param

Dotted path of the field, e.g. items.0.unit_price.value

string
doc_url
Any of:
string
message
required
Message

Human-readable error message

string
param
Any of:
string
type
required
Type

Error type category

string
request_id
Any of:
string

Example generated

{
"error": {
"code": "example",
"details": [
{
"message": "example",
"param": "example"
}
],
"doc_url": "example",
"message": "example",
"param": "example",
"type": "example"
},
"request_id": "example"
}

internal_server_error or database_error (type internal_error): our fault. Retry with backoff; quote request_id.

Media typeapplication/json
ErrorResponse

Standard error response format.

object
error
required
ErrorDetail

Error detail structure (Stripe-like format).

object
code
required
Code

Machine-readable error code

string
details
Any of:
Array<object>
FieldErrorDetail

One failing field of a validation error.

object
message
required
Message

Why the value was refused

string
param
required
Param

Dotted path of the field, e.g. items.0.unit_price.value

string
doc_url
Any of:
string
message
required
Message

Human-readable error message

string
param
Any of:
string
type
required
Type

Error type category

string
request_id
Any of:
string

Example generated

{
"error": {
"code": "example",
"details": [
{
"message": "example",
"param": "example"
}
],
"doc_url": "example",
"message": "example",
"param": "example",
"type": "example"
},
"request_id": "example"
}