Skip to main content
PATCH
/
products
/
{id}
Update a product
curl --request PATCH \
  --url https://api.heffl.com/api/v2/products/{id} \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "name": "<string>",
  "price": 123,
  "description": "<string>",
  "sku": "<string>",
  "buyPrice": 123,
  "isActive": true
}
'
{
  "id": "<string>",
  "name": "<string>",
  "price": 123,
  "type": "<string>",
  "isActive": true,
  "description": "<string>",
  "sku": "<string>"
}

Authorizations

x-api-key
string
header
required

API key for authentication. Get yours at app.heffl.com/settings/developers

Path Parameters

id
string
required

Product ID

Body

application/json
name
string

Product name

type
enum<string>

Product type

Available options:
PRODUCT,
SERVICE
price
number

Product price

description
string | null

Product description

sku
string | null

SKU code

buyPrice
number | null

Cost/buy price

isActive
boolean

Whether the product is active

{key}
any

Custom field values using cf_* keys (for example cf_brand).

Response

OK

id
string
required

Product ID

name
string
required

Product name

price
number
required

Product price

type
string
required

Product type (PRODUCT or SERVICE)

isActive
boolean
required

Whether the product is active

description
string | null

Product description

sku
string | null

SKU code