La Pyme SDK
import { Lapyme } from "lapyme";
const lapyme = new Lapyme({
bearerAuth: process.env["LAPYME_API_KEY"] ?? "",
});
const product = await lapyme.products.update({
productId: "9c692e8b-0f9a-4f7c-8b99-061a2eb188ae",
body: {
price: 1390000,
},
});
curl --request PUT \
--url https://api.lapyme.com.ar/api/v1/products/{product_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"category_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"image_url": "<string>",
"sku": "<string>",
"barcode": "<string>",
"cost": 1,
"price": 1,
"promotional_price": 1,
"markup_percentage": 5000,
"tax_rate_id": 123,
"is_exempt": true,
"default_supplier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_sales_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_purchase_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"warehouse_stocks": [
{
"warehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"quantity": 1
}
],
"is_active": true
}
'import requests
url = "https://api.lapyme.com.ar/api/v1/products/{product_id}"
payload = {
"name": "<string>",
"description": "<string>",
"category_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"image_url": "<string>",
"sku": "<string>",
"barcode": "<string>",
"cost": 1,
"price": 1,
"promotional_price": 1,
"markup_percentage": 5000,
"tax_rate_id": 123,
"is_exempt": True,
"default_supplier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_sales_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_purchase_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"warehouse_stocks": [
{
"warehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"quantity": 1
}
],
"is_active": True
}
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({
name: '<string>',
description: '<string>',
category_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
image_url: '<string>',
sku: '<string>',
barcode: '<string>',
cost: 1,
price: 1,
promotional_price: 1,
markup_percentage: 5000,
tax_rate_id: 123,
is_exempt: true,
default_supplier_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
default_sales_account_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
default_purchase_account_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
warehouse_stocks: [{warehouse_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a', quantity: 1}],
is_active: true
})
};
fetch('https://api.lapyme.com.ar/api/v1/products/{product_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.lapyme.com.ar/api/v1/products/{product_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([
'name' => '<string>',
'description' => '<string>',
'category_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'image_url' => '<string>',
'sku' => '<string>',
'barcode' => '<string>',
'cost' => 1,
'price' => 1,
'promotional_price' => 1,
'markup_percentage' => 5000,
'tax_rate_id' => 123,
'is_exempt' => true,
'default_supplier_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'default_sales_account_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'default_purchase_account_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'warehouse_stocks' => [
[
'warehouse_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'quantity' => 1
]
],
'is_active' => true
]),
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.lapyme.com.ar/api/v1/products/{product_id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"category_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"image_url\": \"<string>\",\n \"sku\": \"<string>\",\n \"barcode\": \"<string>\",\n \"cost\": 1,\n \"price\": 1,\n \"promotional_price\": 1,\n \"markup_percentage\": 5000,\n \"tax_rate_id\": 123,\n \"is_exempt\": true,\n \"default_supplier_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_sales_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_purchase_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"warehouse_stocks\": [\n {\n \"warehouse_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"quantity\": 1\n }\n ],\n \"is_active\": true\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.lapyme.com.ar/api/v1/products/{product_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"category_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"image_url\": \"<string>\",\n \"sku\": \"<string>\",\n \"barcode\": \"<string>\",\n \"cost\": 1,\n \"price\": 1,\n \"promotional_price\": 1,\n \"markup_percentage\": 5000,\n \"tax_rate_id\": 123,\n \"is_exempt\": true,\n \"default_supplier_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_sales_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_purchase_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"warehouse_stocks\": [\n {\n \"warehouse_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"quantity\": 1\n }\n ],\n \"is_active\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.lapyme.com.ar/api/v1/products/{product_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 \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"category_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"image_url\": \"<string>\",\n \"sku\": \"<string>\",\n \"barcode\": \"<string>\",\n \"cost\": 1,\n \"price\": 1,\n \"promotional_price\": 1,\n \"markup_percentage\": 5000,\n \"tax_rate_id\": 123,\n \"is_exempt\": true,\n \"default_supplier_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_sales_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_purchase_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"warehouse_stocks\": [\n {\n \"warehouse_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"quantity\": 1\n }\n ],\n \"is_active\": true\n}"
response = http.request(request)
puts response.read_body{
"request_id": "<string>",
"data": {
"product": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"category": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
},
"sku": "<string>",
"barcode": "<string>",
"image_url": "<string>",
"currency": "<string>",
"cost": 123,
"price": 123,
"tax_rate": {
"id": 123,
"value": 123
},
"default_supplier": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
},
"is_active": true,
"organization_slug": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"object": "<string>",
"tags": [
{
"object": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"slug": "<string>",
"description": "<string>",
"archived_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"variant_group_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"variant_options": {},
"is_exempt": true,
"metafields": [
{
"key": "<string>",
"value": "<string>"
}
],
"stock_summary": {
"total_quantity": 123,
"warehouse_count": 1,
"by_warehouse": [
{
"warehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"warehouse_name": "<string>",
"quantity": 123,
"on_hand": 123,
"reserved_quantity": 123,
"incoming_quantity": 123
}
]
},
"effective_price": 123,
"applied_price_list": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"is_automatic": true,
"adjustment_percentage": 123,
"tax_inclusive": true
}
}
},
"warnings": [
"<unknown>"
]
}{
"request_id": "req_product_update_1",
"error": {
"code": "INVALID_REQUEST",
"message": "Invalid request for updating products",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "API key is required in the Authorization header",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "FORBIDDEN",
"message": "Your API key does not have permission for this operation",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "NOT_FOUND",
"message": "Product not found",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "CONFLICT",
"message": "A product with this SKU already exists",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_rate_limit_1",
"error": {
"type": "rate_limit_error",
"code": "RATE_LIMITED",
"message": "The organization request limit was reached. Try again later.",
"retryable": true,
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "INTERNAL_ERROR",
"message": "Could not update the product",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}Actualizar producto
Actualiza un producto y devuelve el detalle persistido.
PUT
/
api
/
v1
/
products
/
{product_id}
La Pyme SDK
import { Lapyme } from "lapyme";
const lapyme = new Lapyme({
bearerAuth: process.env["LAPYME_API_KEY"] ?? "",
});
const product = await lapyme.products.update({
productId: "9c692e8b-0f9a-4f7c-8b99-061a2eb188ae",
body: {
price: 1390000,
},
});
curl --request PUT \
--url https://api.lapyme.com.ar/api/v1/products/{product_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"category_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"image_url": "<string>",
"sku": "<string>",
"barcode": "<string>",
"cost": 1,
"price": 1,
"promotional_price": 1,
"markup_percentage": 5000,
"tax_rate_id": 123,
"is_exempt": true,
"default_supplier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_sales_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_purchase_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"warehouse_stocks": [
{
"warehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"quantity": 1
}
],
"is_active": true
}
'import requests
url = "https://api.lapyme.com.ar/api/v1/products/{product_id}"
payload = {
"name": "<string>",
"description": "<string>",
"category_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"image_url": "<string>",
"sku": "<string>",
"barcode": "<string>",
"cost": 1,
"price": 1,
"promotional_price": 1,
"markup_percentage": 5000,
"tax_rate_id": 123,
"is_exempt": True,
"default_supplier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_sales_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"default_purchase_account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"warehouse_stocks": [
{
"warehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"quantity": 1
}
],
"is_active": True
}
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({
name: '<string>',
description: '<string>',
category_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
image_url: '<string>',
sku: '<string>',
barcode: '<string>',
cost: 1,
price: 1,
promotional_price: 1,
markup_percentage: 5000,
tax_rate_id: 123,
is_exempt: true,
default_supplier_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
default_sales_account_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
default_purchase_account_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
warehouse_stocks: [{warehouse_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a', quantity: 1}],
is_active: true
})
};
fetch('https://api.lapyme.com.ar/api/v1/products/{product_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.lapyme.com.ar/api/v1/products/{product_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([
'name' => '<string>',
'description' => '<string>',
'category_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'image_url' => '<string>',
'sku' => '<string>',
'barcode' => '<string>',
'cost' => 1,
'price' => 1,
'promotional_price' => 1,
'markup_percentage' => 5000,
'tax_rate_id' => 123,
'is_exempt' => true,
'default_supplier_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'default_sales_account_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'default_purchase_account_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'warehouse_stocks' => [
[
'warehouse_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'quantity' => 1
]
],
'is_active' => true
]),
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.lapyme.com.ar/api/v1/products/{product_id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"category_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"image_url\": \"<string>\",\n \"sku\": \"<string>\",\n \"barcode\": \"<string>\",\n \"cost\": 1,\n \"price\": 1,\n \"promotional_price\": 1,\n \"markup_percentage\": 5000,\n \"tax_rate_id\": 123,\n \"is_exempt\": true,\n \"default_supplier_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_sales_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_purchase_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"warehouse_stocks\": [\n {\n \"warehouse_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"quantity\": 1\n }\n ],\n \"is_active\": true\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.lapyme.com.ar/api/v1/products/{product_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"category_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"image_url\": \"<string>\",\n \"sku\": \"<string>\",\n \"barcode\": \"<string>\",\n \"cost\": 1,\n \"price\": 1,\n \"promotional_price\": 1,\n \"markup_percentage\": 5000,\n \"tax_rate_id\": 123,\n \"is_exempt\": true,\n \"default_supplier_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_sales_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_purchase_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"warehouse_stocks\": [\n {\n \"warehouse_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"quantity\": 1\n }\n ],\n \"is_active\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.lapyme.com.ar/api/v1/products/{product_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 \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"category_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"image_url\": \"<string>\",\n \"sku\": \"<string>\",\n \"barcode\": \"<string>\",\n \"cost\": 1,\n \"price\": 1,\n \"promotional_price\": 1,\n \"markup_percentage\": 5000,\n \"tax_rate_id\": 123,\n \"is_exempt\": true,\n \"default_supplier_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_sales_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"default_purchase_account_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"warehouse_stocks\": [\n {\n \"warehouse_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"quantity\": 1\n }\n ],\n \"is_active\": true\n}"
response = http.request(request)
puts response.read_body{
"request_id": "<string>",
"data": {
"product": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"category": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
},
"sku": "<string>",
"barcode": "<string>",
"image_url": "<string>",
"currency": "<string>",
"cost": 123,
"price": 123,
"tax_rate": {
"id": 123,
"value": 123
},
"default_supplier": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
},
"is_active": true,
"organization_slug": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"object": "<string>",
"tags": [
{
"object": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"slug": "<string>",
"description": "<string>",
"archived_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"variant_group_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"variant_options": {},
"is_exempt": true,
"metafields": [
{
"key": "<string>",
"value": "<string>"
}
],
"stock_summary": {
"total_quantity": 123,
"warehouse_count": 1,
"by_warehouse": [
{
"warehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"warehouse_name": "<string>",
"quantity": 123,
"on_hand": 123,
"reserved_quantity": 123,
"incoming_quantity": 123
}
]
},
"effective_price": 123,
"applied_price_list": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"is_automatic": true,
"adjustment_percentage": 123,
"tax_inclusive": true
}
}
},
"warnings": [
"<unknown>"
]
}{
"request_id": "req_product_update_1",
"error": {
"code": "INVALID_REQUEST",
"message": "Invalid request for updating products",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "API key is required in the Authorization header",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "FORBIDDEN",
"message": "Your API key does not have permission for this operation",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "NOT_FOUND",
"message": "Product not found",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "CONFLICT",
"message": "A product with this SKU already exists",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}{
"request_id": "req_rate_limit_1",
"error": {
"type": "rate_limit_error",
"code": "RATE_LIMITED",
"message": "The organization request limit was reached. Try again later.",
"retryable": true,
"details": []
}
}{
"request_id": "req_product_update_1",
"error": {
"code": "INTERNAL_ERROR",
"message": "Could not update the product",
"retryable": false,
"type": "invalid_request_error",
"details": []
}
}Authorizations
Incluí tu API key en el header Authorization con el prefijo Bearer.
Headers
ID opcional de la solicitud para trazabilidad. Si se omite, el servidor genera uno.
Path Parameters
ID del producto
Body
application/json
Available options:
both, sales, purchases External product image URL reference. La Pyme displays it best effort and does not copy, ingest, or host the image.
Available options:
product, service, combo, kit Available options:
10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 41, 47, 48, 49, 50, 51, 52, 53, 54, 55, 61, 62, 63, 97, 98, 99, 00, 01, 02, 03, 04, 05, 06, 07, 08, 09 Available options:
PES, DOL Required range:
x >= 0Manual sale price in cents. Mutually exclusive with markup_percentage; send price for manual pricing or markup_percentage for markup pricing.
Required range:
x >= 0Required range:
x >= 0Markup percentage used to calculate the sale price from cost, tax, and organization rounding rules. Mutually exclusive with price; send null to switch back to manual pricing.
Required range:
0 <= x <= 10000Show child attributes
Show child attributes
Was this page helpful?
⌘I

