Vendedores
Base: https://api.nivesistemas.com.br · 4 endpoints
GET /sellers
Seção intitulada “GET /sellers”Listar vendedores
Query params
| Campo | Tipo | Obrigatório | Descrição |
|---|---|---|---|
q |
string | não | Busca |
curl -X GET "https://api.nivesistemas.com.br/sellers" \ -H "Authorization: Bearer sl_live_exemplo_abc123xyz789" \ -H "X-Store-Slug: loja-demo"const res = await fetch("https://api.nivesistemas.com.br/sellers", { method: "GET", headers: { Authorization: "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", },});const data = await res.json();import requests
res = requests.request( "GET", "https://api.nivesistemas.com.br/sellers", headers={ "Authorization": "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", },)print(res.json())POST /sellers
Seção intitulada “POST /sellers”Criar vendedor
Corpo (JSON)
| Campo | Tipo | Obrigatório | Descrição |
|---|---|---|---|
name |
string | sim | Nome |
employeeCode |
string | não | Código do funcionário |
commissionPercent |
number | não | Comissão % |
active |
boolean | não | Ativo |
curl -X POST "https://api.nivesistemas.com.br/sellers" \ -H "Authorization: Bearer sl_live_exemplo_abc123xyz789" \ -H "X-Store-Slug: loja-demo" \ -H "Content-Type: application/json" \ -d '{"name":"Exemplo","employeeCode":"","commissionPercent":0,"active":true}'const res = await fetch("https://api.nivesistemas.com.br/sellers", { method: "POST", headers: { Authorization: "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", "Content-Type": "application/json", }, body: JSON.stringify({ "name": "Exemplo", "employeeCode": "", "commissionPercent": 0, "active": true }),});const data = await res.json();import requests
res = requests.request( "POST", "https://api.nivesistemas.com.br/sellers", headers={ "Authorization": "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", }, json={ "name": "Exemplo", "employeeCode": "", "commissionPercent": 0, "active": True },)print(res.json())PATCH /sellers/:id
Seção intitulada “PATCH /sellers/:id”Atualizar vendedor
Parâmetros de rota: id
Corpo (JSON)
| Campo | Tipo | Obrigatório | Descrição |
|---|---|---|---|
name |
string | não | Nome e demais campos |
curl -X PATCH "https://api.nivesistemas.com.br/sellers/{id}" \ -H "Authorization: Bearer sl_live_exemplo_abc123xyz789" \ -H "X-Store-Slug: loja-demo" \ -H "Content-Type: application/json" \ -d '{"name":"Exemplo"}'const res = await fetch("https://api.nivesistemas.com.br/sellers/{id}", { method: "PATCH", headers: { Authorization: "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", "Content-Type": "application/json", }, body: JSON.stringify({ "name": "Exemplo" }),});const data = await res.json();import requests
res = requests.request( "PATCH", "https://api.nivesistemas.com.br/sellers/{id}", headers={ "Authorization": "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", }, json={ "name": "Exemplo" },)print(res.json())DELETE /sellers/:id
Seção intitulada “DELETE /sellers/:id”Excluir vendedor
Parâmetros de rota: id
Resposta: 204 No Content
curl -X DELETE "https://api.nivesistemas.com.br/sellers/{id}" \ -H "Authorization: Bearer sl_live_exemplo_abc123xyz789" \ -H "X-Store-Slug: loja-demo"const res = await fetch("https://api.nivesistemas.com.br/sellers/{id}", { method: "DELETE", headers: { Authorization: "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", },});const data = await res.json();import requests
res = requests.request( "DELETE", "https://api.nivesistemas.com.br/sellers/{id}", headers={ "Authorization": "Bearer sl_live_exemplo_abc123xyz789", "X-Store-Slug": "loja-demo", },)print(res.json())
