Skip to main content
PUT
/
api
/
v3
/
products
/
{update}
Update product
curl --request PUT \
  --url https://api.artisn.desarrollo-redbrand.com/api/api/v3/products/{update} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "productId": "Coffee-product-id",
  "name": "Small Coffee",
  "type": "PRODUCT",
  "description": "The bestest Coffee",
  "standardTime": true,
  "featured": true,
  "schedules": [
    {
      "day": "MONDAY",
      "startDate": "2019-02-24",
      "endDate": "2019-02-25",
      "startTime": "08:00",
      "endTime": "12:00"
    }
  ],
  "tags": [
    "to share"
  ],
  "upselling": [
    "lg-coffee"
  ],
  "images": [
    {
      "imageCategoryId": "product",
      "fileUrl": "https://path/to/file.png"
    }
  ],
  "taxesInfo": {
    "taxRate": 0,
    "vatRatePercentage": 0
  },
  "priceInfo": {
    "price": 4.99,
    "pointPrice": null
  },
  "categories": [
    "Coffes-category-id"
  ],
  "additionalInfo": {
    "menu_level": 0
  }
}
'
import requests

url = "https://api.artisn.desarrollo-redbrand.com/api/api/v3/products/{update}"

payload = {
"productId": "Coffee-product-id",
"name": "Small Coffee",
"type": "PRODUCT",
"description": "The bestest Coffee",
"standardTime": True,
"featured": True,
"schedules": [
{
"day": "MONDAY",
"startDate": "2019-02-24",
"endDate": "2019-02-25",
"startTime": "08:00",
"endTime": "12:00"
}
],
"tags": ["to share"],
"upselling": ["lg-coffee"],
"images": [
{
"imageCategoryId": "product",
"fileUrl": "https://path/to/file.png"
}
],
"taxesInfo": {
"taxRate": 0,
"vatRatePercentage": 0
},
"priceInfo": {
"price": 4.99,
"pointPrice": None
},
"categories": ["Coffes-category-id"],
"additionalInfo": { "menu_level": 0 }
}
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({
productId: 'Coffee-product-id',
name: 'Small Coffee',
type: 'PRODUCT',
description: 'The bestest Coffee',
standardTime: true,
featured: true,
schedules: [
{
day: 'MONDAY',
startDate: '2019-02-24',
endDate: '2019-02-25',
startTime: '08:00',
endTime: '12:00'
}
],
tags: ['to share'],
upselling: ['lg-coffee'],
images: [{imageCategoryId: 'product', fileUrl: 'https://path/to/file.png'}],
taxesInfo: {taxRate: 0, vatRatePercentage: 0},
priceInfo: {price: 4.99, pointPrice: null},
categories: ['Coffes-category-id'],
additionalInfo: {menu_level: 0}
})
};

fetch('https://api.artisn.desarrollo-redbrand.com/api/api/v3/products/{update}', 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.artisn.desarrollo-redbrand.com/api/api/v3/products/{update}",
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([
'productId' => 'Coffee-product-id',
'name' => 'Small Coffee',
'type' => 'PRODUCT',
'description' => 'The bestest Coffee',
'standardTime' => true,
'featured' => true,
'schedules' => [
[
'day' => 'MONDAY',
'startDate' => '2019-02-24',
'endDate' => '2019-02-25',
'startTime' => '08:00',
'endTime' => '12:00'
]
],
'tags' => [
'to share'
],
'upselling' => [
'lg-coffee'
],
'images' => [
[
'imageCategoryId' => 'product',
'fileUrl' => 'https://path/to/file.png'
]
],
'taxesInfo' => [
'taxRate' => 0,
'vatRatePercentage' => 0
],
'priceInfo' => [
'price' => 4.99,
'pointPrice' => null
],
'categories' => [
'Coffes-category-id'
],
'additionalInfo' => [
'menu_level' => 0
]
]),
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.artisn.desarrollo-redbrand.com/api/api/v3/products/{update}"

payload := strings.NewReader("{\n \"productId\": \"Coffee-product-id\",\n \"name\": \"Small Coffee\",\n \"type\": \"PRODUCT\",\n \"description\": \"The bestest Coffee\",\n \"standardTime\": true,\n \"featured\": true,\n \"schedules\": [\n {\n \"day\": \"MONDAY\",\n \"startDate\": \"2019-02-24\",\n \"endDate\": \"2019-02-25\",\n \"startTime\": \"08:00\",\n \"endTime\": \"12:00\"\n }\n ],\n \"tags\": [\n \"to share\"\n ],\n \"upselling\": [\n \"lg-coffee\"\n ],\n \"images\": [\n {\n \"imageCategoryId\": \"product\",\n \"fileUrl\": \"https://path/to/file.png\"\n }\n ],\n \"taxesInfo\": {\n \"taxRate\": 0,\n \"vatRatePercentage\": 0\n },\n \"priceInfo\": {\n \"price\": 4.99,\n \"pointPrice\": null\n },\n \"categories\": [\n \"Coffes-category-id\"\n ],\n \"additionalInfo\": {\n \"menu_level\": 0\n }\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.artisn.desarrollo-redbrand.com/api/api/v3/products/{update}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"productId\": \"Coffee-product-id\",\n \"name\": \"Small Coffee\",\n \"type\": \"PRODUCT\",\n \"description\": \"The bestest Coffee\",\n \"standardTime\": true,\n \"featured\": true,\n \"schedules\": [\n {\n \"day\": \"MONDAY\",\n \"startDate\": \"2019-02-24\",\n \"endDate\": \"2019-02-25\",\n \"startTime\": \"08:00\",\n \"endTime\": \"12:00\"\n }\n ],\n \"tags\": [\n \"to share\"\n ],\n \"upselling\": [\n \"lg-coffee\"\n ],\n \"images\": [\n {\n \"imageCategoryId\": \"product\",\n \"fileUrl\": \"https://path/to/file.png\"\n }\n ],\n \"taxesInfo\": {\n \"taxRate\": 0,\n \"vatRatePercentage\": 0\n },\n \"priceInfo\": {\n \"price\": 4.99,\n \"pointPrice\": null\n },\n \"categories\": [\n \"Coffes-category-id\"\n ],\n \"additionalInfo\": {\n \"menu_level\": 0\n }\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.artisn.desarrollo-redbrand.com/api/api/v3/products/{update}")

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 \"productId\": \"Coffee-product-id\",\n \"name\": \"Small Coffee\",\n \"type\": \"PRODUCT\",\n \"description\": \"The bestest Coffee\",\n \"standardTime\": true,\n \"featured\": true,\n \"schedules\": [\n {\n \"day\": \"MONDAY\",\n \"startDate\": \"2019-02-24\",\n \"endDate\": \"2019-02-25\",\n \"startTime\": \"08:00\",\n \"endTime\": \"12:00\"\n }\n ],\n \"tags\": [\n \"to share\"\n ],\n \"upselling\": [\n \"lg-coffee\"\n ],\n \"images\": [\n {\n \"imageCategoryId\": \"product\",\n \"fileUrl\": \"https://path/to/file.png\"\n }\n ],\n \"taxesInfo\": {\n \"taxRate\": 0,\n \"vatRatePercentage\": 0\n },\n \"priceInfo\": {\n \"price\": 4.99,\n \"pointPrice\": null\n },\n \"categories\": [\n \"Coffes-category-id\"\n ],\n \"additionalInfo\": {\n \"menu_level\": 0\n }\n}"

response = http.request(request)
puts response.read_body
{
  "message": "Producto actualizado exitosamente.",
  "productId": "Coffee-product-id"
}
{
"error": "Invalid data"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Updated product information

productId
string
required
Example:

"Coffee-product-id"

name
string
required
Example:

"Small Coffee"

type
string
required
Example:

"PRODUCT"

description
string
required
Example:

"The bestest Coffee"

standardTime
boolean
Example:

true

Example:

true

schedules
object[]
tags
string[]
upselling
string[]
images
object[]
taxesInfo
object
priceInfo
object
categories
string[]
additionalInfo
object

Response

Product updated successfully

message
string
Example:

"Producto actualizado exitosamente."

productId
string
Example:

"Coffee-product-id"