Create a supplier SKU
curl --request POST \
--url https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"product_id": 123,
"supplier_id": 123,
"sku": "<string>",
"unit_cost": 1,
"moq_quantity": 1,
"moq_unit_id": 123
}
'import requests
url = "https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus"
payload = {
"product_id": 123,
"supplier_id": 123,
"sku": "<string>",
"unit_cost": 1,
"moq_quantity": 1,
"moq_unit_id": 123
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
product_id: 123,
supplier_id: 123,
sku: '<string>',
unit_cost: 1,
moq_quantity: 1,
moq_unit_id: 123
})
};
fetch('https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus', 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://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus",
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([
'product_id' => 123,
'supplier_id' => 123,
'sku' => '<string>',
'unit_cost' => 1,
'moq_quantity' => 1,
'moq_unit_id' => 123
]),
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://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus"
payload := strings.NewReader("{\n \"product_id\": 123,\n \"supplier_id\": 123,\n \"sku\": \"<string>\",\n \"unit_cost\": 1,\n \"moq_quantity\": 1,\n \"moq_unit_id\": 123\n}")
req, _ := http.NewRequest("POST", 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.post("https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"product_id\": 123,\n \"supplier_id\": 123,\n \"sku\": \"<string>\",\n \"unit_cost\": 1,\n \"moq_quantity\": 1,\n \"moq_unit_id\": 123\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"product_id\": 123,\n \"supplier_id\": 123,\n \"sku\": \"<string>\",\n \"unit_cost\": 1,\n \"moq_quantity\": 1,\n \"moq_unit_id\": 123\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": 123,
"product_id": 123,
"supplier_id": 123,
"sku": "<string>",
"unit_cost": 123,
"moq_quantity": 123,
"moq_unit_id": 123,
"moq_unit": {
"id": 123,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"status": "<string>",
"unit_class_id": 123,
"unit_class": {
"id": 123,
"name": "<string>",
"base_class": true
},
"name": "<string>",
"description": "<string>",
"base_unit": true,
"unit_conversion_rules": [
{
"id": 123,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"status": "<string>",
"base_unit_of_measure_id": 123,
"base_unit_of_measure": {
"id": 123,
"name": "<string>",
"unit_class_id": 123,
"base_unit": true
},
"converted_unit_of_measure_id": 123,
"converted_unit_of_measure": {
"id": 123,
"name": "<string>",
"unit_class_id": 123,
"base_unit": true
},
"conversion_factor": 123,
"product_id": 123,
"product": {},
"product_alternate_skus": [
{}
]
}
]
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"product": {
"id": 123,
"sku": "<string>",
"name": "<string>"
},
"supplier": {
"id": 123,
"name": "<string>",
"contact_name": "<string>",
"contact_email": "<string>"
}
}
}{
"message": "<string>"
}{
"message": "<string>",
"errors": {}
}Supplier SKUs
Create a supplier SKU
Creates a new supplier-specific SKU and optional unit cost for a given
product/supplier pair. The combination of product_id + supplier_id + sku
must be unique; the underlying service enforces this constraint.
POST
/
supplier-skus
Create a supplier SKU
curl --request POST \
--url https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"product_id": 123,
"supplier_id": 123,
"sku": "<string>",
"unit_cost": 1,
"moq_quantity": 1,
"moq_unit_id": 123
}
'import requests
url = "https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus"
payload = {
"product_id": 123,
"supplier_id": 123,
"sku": "<string>",
"unit_cost": 1,
"moq_quantity": 1,
"moq_unit_id": 123
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
product_id: 123,
supplier_id: 123,
sku: '<string>',
unit_cost: 1,
moq_quantity: 1,
moq_unit_id: 123
})
};
fetch('https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus', 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://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus",
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([
'product_id' => 123,
'supplier_id' => 123,
'sku' => '<string>',
'unit_cost' => 1,
'moq_quantity' => 1,
'moq_unit_id' => 123
]),
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://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus"
payload := strings.NewReader("{\n \"product_id\": 123,\n \"supplier_id\": 123,\n \"sku\": \"<string>\",\n \"unit_cost\": 1,\n \"moq_quantity\": 1,\n \"moq_unit_id\": 123\n}")
req, _ := http.NewRequest("POST", 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.post("https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"product_id\": 123,\n \"supplier_id\": 123,\n \"sku\": \"<string>\",\n \"unit_cost\": 1,\n \"moq_quantity\": 1,\n \"moq_unit_id\": 123\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{companyName}.api.joinluminous.com/external/api/v1/supplier-skus")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"product_id\": 123,\n \"supplier_id\": 123,\n \"sku\": \"<string>\",\n \"unit_cost\": 1,\n \"moq_quantity\": 1,\n \"moq_unit_id\": 123\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": 123,
"product_id": 123,
"supplier_id": 123,
"sku": "<string>",
"unit_cost": 123,
"moq_quantity": 123,
"moq_unit_id": 123,
"moq_unit": {
"id": 123,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"status": "<string>",
"unit_class_id": 123,
"unit_class": {
"id": 123,
"name": "<string>",
"base_class": true
},
"name": "<string>",
"description": "<string>",
"base_unit": true,
"unit_conversion_rules": [
{
"id": 123,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"status": "<string>",
"base_unit_of_measure_id": 123,
"base_unit_of_measure": {
"id": 123,
"name": "<string>",
"unit_class_id": 123,
"base_unit": true
},
"converted_unit_of_measure_id": 123,
"converted_unit_of_measure": {
"id": 123,
"name": "<string>",
"unit_class_id": 123,
"base_unit": true
},
"conversion_factor": 123,
"product_id": 123,
"product": {},
"product_alternate_skus": [
{}
]
}
]
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"product": {
"id": 123,
"sku": "<string>",
"name": "<string>"
},
"supplier": {
"id": 123,
"name": "<string>",
"contact_name": "<string>",
"contact_email": "<string>"
}
}
}{
"message": "<string>"
}{
"message": "<string>",
"errors": {}
}Authorizations
Authenticate using a bearer token. To create a token, navigate to /settings/api-tokens and click Create API Token.
Body
application/json
Luminous product (rfq) ID
Supplier ID
Supplier-specific SKU
Maximum string length:
255Per-unit cost from this supplier
Required range:
x >= 0Minimum order quantity for this supplier SKU
Required range:
x >= 0ID of the unit of measure the MOQ is expressed in
Response
Supplier SKU created
Show child attributes
Show child attributes
⌘I