Variations

Obter Variação de Produto

get
Autorizações
Parâmetros de rota
product_idstringObrigatório
idstringObrigatório
Respostas
200
OK
application/json
get
GET /api/sales/products/{product_id}/variations/{id} HTTP/1.1
Host: api.zydon.com.br
Authorization: Bearer JWT
Accept: */*
{
  "id": "text",
  "product_id": "text",
  "sku": "text",
  "price": 1,
  "stock": 1,
  "variation_weight": 1,
  "variation_width": 1,
  "variation_height": 1,
  "variation_depth": 1,
  "packaging_weight": 1,
  "packaging_width": 1,
  "packaging_height": 1,
  "packaging_depth": 1
}

Atualizar Variação de Produto

put
Autorizações
Parâmetros de rota
product_idstringObrigatório
idstringObrigatório
Corpo
skustringOpcional
pricenumberOpcional
stocknumberOpcional
variation_weightnumberOpcional
variation_widthnumberOpcional
variation_heightnumberOpcional
variation_depthnumberOpcional
packaging_weightnumberOpcional
packaging_widthnumberOpcional
packaging_heightnumberOpcional
packaging_depthnumberOpcional
Respostas
200
Variation updated successfully
application/json
put
PUT /api/sales/products/{product_id}/variations/{id} HTTP/1.1
Host: api.zydon.com.br
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 198

{
  "sku": "text",
  "price": 1,
  "stock": 1,
  "variation_weight": 1,
  "variation_width": 1,
  "variation_height": 1,
  "variation_depth": 1,
  "packaging_weight": 1,
  "packaging_width": 1,
  "packaging_height": 1,
  "packaging_depth": 1
}
{
  "id": "text",
  "product_id": "text",
  "sku": "text",
  "price": 1,
  "stock": 1,
  "variation_weight": 1,
  "variation_width": 1,
  "variation_height": 1,
  "variation_depth": 1,
  "packaging_weight": 1,
  "packaging_width": 1,
  "packaging_height": 1,
  "packaging_depth": 1
}

Remover Variação de Produto

delete
Autorizações
Parâmetros de rota
product_idstringObrigatório
idstringObrigatório
Respostas
204
Variation removed successfully
application/json
delete
DELETE /api/sales/products/{product_id}/variations/{id} HTTP/1.1
Host: api.zydon.com.br
Authorization: Bearer JWT
Accept: */*
{
  "id": "text"
}

Listar Variações de Produto

get
Autorizações
Parâmetros de rota
product_idstringObrigatório
Parâmetros de consulta
searchstringOpcionalDefault: ""
pageinteger · int32OpcionalDefault: 0
perPageinteger · int32OpcionalDefault: 25
sortstringOpcionalDefault: ""
dirstringOpcionalDefault: asc
Respostas
200
OK
application/json
get
GET /api/sales/products/{product_id}/variations HTTP/1.1
Host: api.zydon.com.br
Authorization: Bearer JWT
Accept: */*
{
  "id": "text",
  "product_id": "text",
  "sku": "text",
  "price": 1,
  "stock": 1,
  "variation_weight": 1,
  "variation_width": 1,
  "variation_height": 1,
  "variation_depth": 1,
  "packaging_weight": 1,
  "packaging_width": 1,
  "packaging_height": 1,
  "packaging_depth": 1
}

Criar Variação de Produto

post
Autorizações
Parâmetros de rota
product_idstringObrigatório
Corpo
idstringObrigatório
skustringOpcional
pricenumberOpcional
stocknumberOpcional
variation_weightnumberOpcional
variation_widthnumberOpcional
variation_heightnumberOpcional
variation_depthnumberOpcional
packaging_weightnumberOpcional
packaging_widthnumberOpcional
packaging_heightnumberOpcional
packaging_depthnumberOpcional
Respostas
201
Variation created successfully
application/json
post
POST /api/sales/products/{product_id}/variations HTTP/1.1
Host: api.zydon.com.br
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 210

{
  "id": "text",
  "sku": "text",
  "price": 1,
  "stock": 1,
  "variation_weight": 1,
  "variation_width": 1,
  "variation_height": 1,
  "variation_depth": 1,
  "packaging_weight": 1,
  "packaging_width": 1,
  "packaging_height": 1,
  "packaging_depth": 1
}
{
  "id": "text",
  "product_id": "text",
  "sku": "text",
  "price": 1,
  "stock": 1,
  "variation_weight": 1,
  "variation_width": 1,
  "variation_height": 1,
  "variation_depth": 1,
  "packaging_weight": 1,
  "packaging_width": 1,
  "packaging_height": 1,
  "packaging_depth": 1
}