Skip to main content

Paligo API

Create variable variant

const inputBody = '{
  "title": "Acme 2000",
  "variable_set_id": 380
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'
};

fetch('https://{instance}.paligoapp.com/api/v2/variants/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

Body parameter

{
  "title": "Acme 2000",
  "variable_set_id": 380
}

Responses

Status

Meaning

Description

Schema

201

Created

Successful response.

Variant

{
  "id": 123,
  "variable_set_id": 380,
  "title": "Acme 2000"
}