Skip to main content
POST
/
v3
/
products
/
create-update
Update or Create Product
curl --request POST \
  --url https://api.{tenant}.getomneo.com/api/v3/products/create-update \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "<string>",
  "handle": "<string>",
  "external_id": "<string>",
  "brand": "<string>",
  "variants": [
    {
      "sku": "<string>",
      "price": 123,
      "position": 123,
      "title": "<string>",
      "external_id": "<string>",
      "barcode": "<string>",
      "description": "<string>",
      "available_quantity": 123,
      "price_discounted": 123,
      "price_comparison": 123,
      "price_cost": 123,
      "tags": [
        "<string>"
      ],
      "images": [
        {
          "url": "<string>",
          "sort_order": 123
        }
      ],
      "options": [
        {
          "value": "<string>",
          "name": "<string>",
          "sort_order": 123
        }
      ]
    }
  ],
  "description": "<string>",
  "web_url": "<string>",
  "currency": "<string>",
  "position": 123,
  "systems": [
    "<string>"
  ],
  "channels": [
    "<string>"
  ],
  "tags": [
    "<string>"
  ],
  "images": [
    {
      "url": "<string>",
      "sort_order": 123
    }
  ]
}
'
import requests

url = "https://api.{tenant}.getomneo.com/api/v3/products/create-update"

payload = {
"title": "<string>",
"handle": "<string>",
"external_id": "<string>",
"brand": "<string>",
"variants": [
{
"sku": "<string>",
"price": 123,
"position": 123,
"title": "<string>",
"external_id": "<string>",
"barcode": "<string>",
"description": "<string>",
"available_quantity": 123,
"price_discounted": 123,
"price_comparison": 123,
"price_cost": 123,
"tags": ["<string>"],
"images": [
{
"url": "<string>",
"sort_order": 123
}
],
"options": [
{
"value": "<string>",
"name": "<string>",
"sort_order": 123
}
]
}
],
"description": "<string>",
"web_url": "<string>",
"currency": "<string>",
"position": 123,
"systems": ["<string>"],
"channels": ["<string>"],
"tags": ["<string>"],
"images": [
{
"url": "<string>",
"sort_order": 123
}
]
}
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
handle: '<string>',
external_id: '<string>',
brand: '<string>',
variants: [
{
sku: '<string>',
price: 123,
position: 123,
title: '<string>',
external_id: '<string>',
barcode: '<string>',
description: '<string>',
available_quantity: 123,
price_discounted: 123,
price_comparison: 123,
price_cost: 123,
tags: ['<string>'],
images: [{url: '<string>', sort_order: 123}],
options: [{value: '<string>', name: '<string>', sort_order: 123}]
}
],
description: '<string>',
web_url: '<string>',
currency: '<string>',
position: 123,
systems: ['<string>'],
channels: ['<string>'],
tags: ['<string>'],
images: [{url: '<string>', sort_order: 123}]
})
};

fetch('https://api.{tenant}.getomneo.com/api/v3/products/create-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.{tenant}.getomneo.com/api/v3/products/create-update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'title' => '<string>',
'handle' => '<string>',
'external_id' => '<string>',
'brand' => '<string>',
'variants' => [
[
'sku' => '<string>',
'price' => 123,
'position' => 123,
'title' => '<string>',
'external_id' => '<string>',
'barcode' => '<string>',
'description' => '<string>',
'available_quantity' => 123,
'price_discounted' => 123,
'price_comparison' => 123,
'price_cost' => 123,
'tags' => [
'<string>'
],
'images' => [
[
'url' => '<string>',
'sort_order' => 123
]
],
'options' => [
[
'value' => '<string>',
'name' => '<string>',
'sort_order' => 123
]
]
]
],
'description' => '<string>',
'web_url' => '<string>',
'currency' => '<string>',
'position' => 123,
'systems' => [
'<string>'
],
'channels' => [
'<string>'
],
'tags' => [
'<string>'
],
'images' => [
[
'url' => '<string>',
'sort_order' => 123
]
]
]),
CURLOPT_HTTPHEADER => [
"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.{tenant}.getomneo.com/api/v3/products/create-update"

payload := strings.NewReader("{\n \"title\": \"<string>\",\n \"handle\": \"<string>\",\n \"external_id\": \"<string>\",\n \"brand\": \"<string>\",\n \"variants\": [\n {\n \"sku\": \"<string>\",\n \"price\": 123,\n \"position\": 123,\n \"title\": \"<string>\",\n \"external_id\": \"<string>\",\n \"barcode\": \"<string>\",\n \"description\": \"<string>\",\n \"available_quantity\": 123,\n \"price_discounted\": 123,\n \"price_comparison\": 123,\n \"price_cost\": 123,\n \"tags\": [\n \"<string>\"\n ],\n \"images\": [\n {\n \"url\": \"<string>\",\n \"sort_order\": 123\n }\n ],\n \"options\": [\n {\n \"value\": \"<string>\",\n \"name\": \"<string>\",\n \"sort_order\": 123\n }\n ]\n }\n ],\n \"description\": \"<string>\",\n \"web_url\": \"<string>\",\n \"currency\": \"<string>\",\n \"position\": 123,\n \"systems\": [\n \"<string>\"\n ],\n \"channels\": [\n \"<string>\"\n ],\n \"tags\": [\n \"<string>\"\n ],\n \"images\": [\n {\n \"url\": \"<string>\",\n \"sort_order\": 123\n }\n ]\n}")

req, _ := http.NewRequest("POST", url, payload)

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.post("https://api.{tenant}.getomneo.com/api/v3/products/create-update")
.header("Content-Type", "application/json")
.body("{\n \"title\": \"<string>\",\n \"handle\": \"<string>\",\n \"external_id\": \"<string>\",\n \"brand\": \"<string>\",\n \"variants\": [\n {\n \"sku\": \"<string>\",\n \"price\": 123,\n \"position\": 123,\n \"title\": \"<string>\",\n \"external_id\": \"<string>\",\n \"barcode\": \"<string>\",\n \"description\": \"<string>\",\n \"available_quantity\": 123,\n \"price_discounted\": 123,\n \"price_comparison\": 123,\n \"price_cost\": 123,\n \"tags\": [\n \"<string>\"\n ],\n \"images\": [\n {\n \"url\": \"<string>\",\n \"sort_order\": 123\n }\n ],\n \"options\": [\n {\n \"value\": \"<string>\",\n \"name\": \"<string>\",\n \"sort_order\": 123\n }\n ]\n }\n ],\n \"description\": \"<string>\",\n \"web_url\": \"<string>\",\n \"currency\": \"<string>\",\n \"position\": 123,\n \"systems\": [\n \"<string>\"\n ],\n \"channels\": [\n \"<string>\"\n ],\n \"tags\": [\n \"<string>\"\n ],\n \"images\": [\n {\n \"url\": \"<string>\",\n \"sort_order\": 123\n }\n ]\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.{tenant}.getomneo.com/api/v3/products/create-update")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"title\": \"<string>\",\n \"handle\": \"<string>\",\n \"external_id\": \"<string>\",\n \"brand\": \"<string>\",\n \"variants\": [\n {\n \"sku\": \"<string>\",\n \"price\": 123,\n \"position\": 123,\n \"title\": \"<string>\",\n \"external_id\": \"<string>\",\n \"barcode\": \"<string>\",\n \"description\": \"<string>\",\n \"available_quantity\": 123,\n \"price_discounted\": 123,\n \"price_comparison\": 123,\n \"price_cost\": 123,\n \"tags\": [\n \"<string>\"\n ],\n \"images\": [\n {\n \"url\": \"<string>\",\n \"sort_order\": 123\n }\n ],\n \"options\": [\n {\n \"value\": \"<string>\",\n \"name\": \"<string>\",\n \"sort_order\": 123\n }\n ]\n }\n ],\n \"description\": \"<string>\",\n \"web_url\": \"<string>\",\n \"currency\": \"<string>\",\n \"position\": 123,\n \"systems\": [\n \"<string>\"\n ],\n \"channels\": [\n \"<string>\"\n ],\n \"tags\": [\n \"<string>\"\n ],\n \"images\": [\n {\n \"url\": \"<string>\",\n \"sort_order\": 123\n }\n ]\n}"

response = http.request(request)
puts response.read_body
{
  "data": {
    "id": 123,
    "title": "<string>",
    "handle": "<string>",
    "type": "<string>",
    "external_id": "<string>",
    "status": "<string>",
    "brand": "<string>",
    "department": "<string>",
    "link_brand": "<string>",
    "link_department": "<string>",
    "web_url": "<string>",
    "description": "<string>",
    "currency": "<string>",
    "position": 123,
    "images": "<string>",
    "systems": [
      "<string>"
    ],
    "channels": [
      "<string>"
    ],
    "tags": [
      "<string>"
    ],
    "options": "<string>",
    "custom_fields": [
      {
        "name": "<string>",
        "handle": "<string>",
        "namespace": "<string>",
        "value": "<string>",
        "type": "<string>",
        "custom_fieldable_type": "<string>",
        "custom_fieldable": {
          "id": "<string>",
          "external_id": "<string>",
          "profile_id": "<string>",
          "meta": "<string>",
          "total": "<string>",
          "total_original": "<string>",
          "rounding": "<string>",
          "margin": "<string>",
          "is_void": "<string>",
          "transacted_at": "<string>",
          "timezone": "<string>",
          "payments": "<string>",
          "receipt_is_email": "<string>",
          "receipt_ref": "<string>",
          "linked_receipt_ref": "<string>",
          "claimed_at": "<string>",
          "receipt_email": "<string>",
          "currency_id": "<string>",
          "currency_rate": "<string>",
          "currency": "<string>",
          "type": "<string>",
          "status": "<string>",
          "order_number": "<string>",
          "order_id": "<string>",
          "external_order_id": "<string>",
          "created_at": "<string>",
          "updated_at": "<string>"
        },
        "created_at": "<string>",
        "updated_at": "<string>",
        "is_index": 123
      }
    ],
    "variants": [
      {
        "id": 123,
        "product_id": 123,
        "sku": "<string>",
        "external_id": "<string>",
        "barcode": "<string>",
        "web_url": "<string>",
        "handle": "<string>",
        "title": "<string>",
        "description": "<string>",
        "position": 123,
        "price": 123,
        "price_discounted": 123,
        "price_comparison": 123,
        "price_cost": 123,
        "available_quantity": 123,
        "images": "<string>",
        "meta": [
          "<unknown>"
        ],
        "tags": [
          "<string>"
        ],
        "options": [
          {
            "name": "<string>",
            "value": "<string>",
            "sort_order": 123
          }
        ],
        "created_at": "<string>",
        "updated_at": "<string>",
        "deleted_at": "<string>"
      }
    ],
    "organisation": {
      "id": 123,
      "name": "<string>",
      "handle": "<string>",
      "description": "<string>",
      "short_description": "<string>",
      "icon": "<string>",
      "image_url": "<string>",
      "notes": "<string>",
      "type": "<string>",
      "status": "<string>",
      "is_tenant": 123,
      "is_active": 123,
      "phone": "<string>",
      "email": "<string>",
      "secondary_phone": "<string>",
      "domain": "<string>",
      "authorised_domains": [
        "<unknown>"
      ],
      "meta": [
        "<unknown>"
      ],
      "locations": [
        {
          "id": 123,
          "type": "<string>",
          "name": "<string>",
          "handle": "<string>",
          "description": "<string>",
          "phone": "<string>",
          "email": "<string>",
          "timezone": "<string>",
          "external_id": "<string>",
          "external_code": "<string>",
          "is_published": true,
          "is_permanently_closed": true,
          "address": {
            "id": 123,
            "address_line_1": "<string>",
            "address_line_2": "<string>",
            "address_line_3": "<string>",
            "company": "<string>",
            "latitude": 123,
            "longitude": 123,
            "city": "<string>",
            "postcode": "<string>",
            "state": "<string>",
            "country": "<string>",
            "notes": "<string>",
            "external_id": "<string>",
            "is_default": true,
            "created_at": "<string>",
            "updated_at": "<string>",
            "meta": [
              "<unknown>"
            ],
            "name": "<string>",
            "type": "<string>",
            "phone": "<string>",
            "iso": "<string>",
            "iso_state": "<string>",
            "profile_id": "<string>",
            "custom_fields": {}
          },
          "normal_hours": [
            [
              "<unknown>"
            ]
          ],
          "special_hours": [
            [
              "<unknown>"
            ]
          ],
          "tags": [
            "<string>"
          ],
          "custom_fields": {},
          "icon": "<string>",
          "country_iso_3": "<string>",
          "image_url": "<string>",
          "created_at": "<string>",
          "updated_at": "<string>",
          "departments": [
            {
              "id": 123,
              "name": "<string>",
              "handle": "<string>",
              "external_id": "<string>",
              "external_code": "<string>",
              "description": "<string>",
              "short_description": "<string>",
              "url": "<string>",
              "image_url": "<string>",
              "internal_note": "<string>",
              "meta": [
                "<unknown>"
              ],
              "brand_id": 123,
              "location_id": 123,
              "brand": {
                "name": "<string>",
                "handle": "<string>"
              },
              "created_at": "<string>",
              "updated_at": "<string>"
            }
          ]
        }
      ],
      "address": {
        "id": 123,
        "address_line_1": "<string>",
        "address_line_2": "<string>",
        "address_line_3": "<string>",
        "company": "<string>",
        "latitude": 123,
        "longitude": 123,
        "city": "<string>",
        "postcode": "<string>",
        "state": "<string>",
        "country": "<string>",
        "notes": "<string>",
        "external_id": "<string>",
        "is_default": true,
        "created_at": "<string>",
        "updated_at": "<string>",
        "meta": [
          "<unknown>"
        ],
        "name": "<string>",
        "type": "<string>",
        "phone": "<string>",
        "iso": "<string>",
        "iso_state": "<string>",
        "profile_id": "<string>",
        "custom_fields": {}
      },
      "custom_fields": {},
      "created_at": "<string>",
      "updated_at": "<string>"
    },
    "meta": [
      "<unknown>"
    ],
    "created_at": "<string>",
    "updated_at": "<string>"
  }
}
{
"message": "<string>"
}
{
"message": "<string>"
}
{
"message": "<string>",
"errors": {}
}
{
"errors": [
"<string>"
]
}

Body

application/json
title
string
required
handle
string
required
external_id
string
required
brand
string
required
variants
object[]
required
Minimum array length: 1
type
enum<string> | null
Available options:
appointment,
simple,
configurable,
downloadable,
gift,
bundle,
voucher,
service,
subscription
status
enum<string>
Available options:
new,
active,
rundown,
discontinued,
ranged,
deleted,
archived,
draft
description
string | null
web_url
string | null
currency
string | null
position
integer
systems
string[]
Minimum array length: 1
channels
string[]
Minimum array length: 1
tags
string[]
images
object[]

Response

Product

data
Product · object
required