curl --request PUT \
--url https://api.salesive.com/api/v1/products/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"price": 17.99,
"quantity": 95,
"featured": false
}
'import requests
url = "https://api.salesive.com/api/v1/products/{id}"
payload = {
"price": 17.99,
"quantity": 95,
"featured": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({price: 17.99, quantity: 95, featured: false})
};
fetch('https://api.salesive.com/api/v1/products/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.salesive.com/api/v1/products/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'price' => 17.99,
'quantity' => 95,
'featured' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.salesive.com/api/v1/products/{id}"
payload := strings.NewReader("{\n \"price\": 17.99,\n \"quantity\": 95,\n \"featured\": false\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.salesive.com/api/v1/products/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"price\": 17.99,\n \"quantity\": 95,\n \"featured\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.salesive.com/api/v1/products/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"price\": 17.99,\n \"quantity\": 95,\n \"featured\": false\n}"
response = http.request(request)
puts response.read_body{
"status": 200,
"success": true,
"message": "Update a product",
"data": {
"_id": "66a1f2c4e1b3a40012ab34cd",
"name": "Classic Tee",
"slug": "classic-tee",
"description": "Soft cotton t-shirt",
"price": 17.99,
"promoPrice": 14.99,
"weight": 0.3,
"quantity": 95,
"category": {
"_id": "66a1f0aae1b3a40012ab1100",
"name": "Apparel"
},
"images": [
"https://cdn.salesive.com/p/classic-tee.jpg"
],
"featured": false,
"listed": true,
"hasVariants": false,
"variants": [],
"shop": {
"_id": "66a1eee0e1b3a40012ab0001",
"name": "Acme Store",
"currency": {
"symbol": "$",
"code": "USD"
}
},
"updatedAt": "2026-06-28T09:15:00.000Z"
}
}{
"status": 401,
"success": false,
"message": "Unauthorized",
"data": {}
}{
"status": 403,
"success": false,
"message": "Forbidden: missing required scope",
"data": {}
}Update a product
Updates a product in the store.
curl --request PUT \
--url https://api.salesive.com/api/v1/products/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"price": 17.99,
"quantity": 95,
"featured": false
}
'import requests
url = "https://api.salesive.com/api/v1/products/{id}"
payload = {
"price": 17.99,
"quantity": 95,
"featured": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({price: 17.99, quantity: 95, featured: false})
};
fetch('https://api.salesive.com/api/v1/products/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.salesive.com/api/v1/products/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'price' => 17.99,
'quantity' => 95,
'featured' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.salesive.com/api/v1/products/{id}"
payload := strings.NewReader("{\n \"price\": 17.99,\n \"quantity\": 95,\n \"featured\": false\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.salesive.com/api/v1/products/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"price\": 17.99,\n \"quantity\": 95,\n \"featured\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.salesive.com/api/v1/products/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"price\": 17.99,\n \"quantity\": 95,\n \"featured\": false\n}"
response = http.request(request)
puts response.read_body{
"status": 200,
"success": true,
"message": "Update a product",
"data": {
"_id": "66a1f2c4e1b3a40012ab34cd",
"name": "Classic Tee",
"slug": "classic-tee",
"description": "Soft cotton t-shirt",
"price": 17.99,
"promoPrice": 14.99,
"weight": 0.3,
"quantity": 95,
"category": {
"_id": "66a1f0aae1b3a40012ab1100",
"name": "Apparel"
},
"images": [
"https://cdn.salesive.com/p/classic-tee.jpg"
],
"featured": false,
"listed": true,
"hasVariants": false,
"variants": [],
"shop": {
"_id": "66a1eee0e1b3a40012ab0001",
"name": "Acme Store",
"currency": {
"symbol": "$",
"code": "USD"
}
},
"updatedAt": "2026-06-28T09:15:00.000Z"
}
}{
"status": 401,
"success": false,
"message": "Unauthorized",
"data": {}
}{
"status": 403,
"success": false,
"message": "Forbidden: missing required scope",
"data": {}
}shop and user are stripped and cannot be reassigned. Supplying variants merges by variant _id (existing) or adds new ones. Requires the WRITE_INVENTORY scope.Authorizations
Installed-app access token (prefix app_), issued by the OAuth install flow. The store is bound to the token server-side — never send a shop id.
Path Parameters
ObjectId of the product to update.
Body
Product name.
Product description (max 10000 chars).
Base price (>= 0).
Weight (>= 0).
Stock quantity (>= 0).
Sale/promotional price (>= 0); nullable.
Category ObjectId.
Array of image URLs.
Video URL; nullable.
Whether the product is featured.
Whether the product is listed in the storefront.
Low-stock threshold (>= 0).
Product variants; merged by variant _id or appended. Each variant: attributes (required), price (required), promoPrice, quantity, weight, sku.
Show child attributes
Show child attributes
Product barcode; nullable.
Response
Update a product — success.
200
true
"Update a product"
An ecommerce catalog product.
Show child attributes
Show child attributes
{
"_id": "66a1f2c4e1b3a40012ab34cd",
"name": "Classic Tee",
"slug": "classic-tee",
"description": "Soft cotton t-shirt",
"price": 17.99,
"promoPrice": 14.99,
"weight": 0.3,
"quantity": 95,
"category": {
"_id": "66a1f0aae1b3a40012ab1100",
"name": "Apparel"
},
"images": [
"https://cdn.salesive.com/p/classic-tee.jpg"
],
"featured": false,
"listed": true,
"hasVariants": false,
"variants": [],
"shop": {
"_id": "66a1eee0e1b3a40012ab0001",
"name": "Acme Store",
"currency": { "symbol": "$", "code": "USD" }
},
"updatedAt": "2026-06-28T09:15:00.000Z"
}
Was this page helpful?

