Saltar para o conteúdo principal
PATCH
/
v1
/
deals
/
{id}
Atualizar negócio
curl --request PATCH \
  --url https://api.vendaze.com/v1/deals/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "pipeline_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "stage_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "currency": "BRL",
  "price_cts": 1,
  "owner_email": "joao@empresa.com",
  "forecast_date": "2023-11-07T05:31:56Z",
  "person_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "company_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "tags": [
    "<string>"
  ],
  "custom_fields": [
    {
      "field_key": "origem_negocio",
      "value": "<string>"
    }
  ],
  "products": [
    {
      "product_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "quantity": 1,
      "unit_price_cts": 50000
    }
  ],
  "association_mode": "append"
}
'
{
  "data": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "name": "Contrato Anual Acme Corp",
    "pipeline_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "stage_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "price_cts": 250000,
    "currency": "BRL",
    "owner": {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "email": "joao@empresa.com",
      "name": "João Silva"
    },
    "source": "Minha Integração",
    "forecast_date": "2026-12-31T00:00:00Z",
    "entity_id": "NEG-0001",
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z",
    "pipeline": {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "name": "<string>"
    },
    "stage": {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "name": "<string>"
    },
    "products": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "product_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "name": "<string>",
        "quantity": 2,
        "unit_price_cts": 50000,
        "total_price_cts": 100000
      }
    ],
    "custom_fields": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "value": "<unknown>",
        "field": {
          "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "label": "<string>",
          "key": "<string>",
          "type": "<string>"
        }
      }
    ],
    "tags": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "name": "<string>",
        "color_text": "<string>",
        "color_background": "<string>"
      }
    ],
    "people": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "full_name": "<string>"
      }
    ],
    "companies": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "full_name": "<string>"
      }
    ]
  }
}

Documentation Index

Fetch the complete documentation index at: https://developers.vendaze.com/llms.txt

Use this file to discover all available pages before exploring further.

Autorizações

Authorization
string
header
obrigatório

OAuth 2.1 access token.

Parâmetros de caminho

id
string<uuid>
obrigatório

UUID do recurso.

Corpo

application/json
name
string
Maximum string length: 70
pipeline_id
string<uuid>
stage_id
string<uuid>
currency
enum<string>

Código ISO 4217 de moeda suportado pela Vendaze.

Opções disponíveis:
AED,
ARS,
AUD,
BRL,
CAD,
CHF,
CLP,
CNY,
COP,
DKK,
EGP,
EUR,
GBP,
HKD,
ILS,
INR,
JPY,
KWD,
MAD,
MXN,
MYR,
NGN,
NOK,
NZD,
PEN,
QAR,
SAR,
SEK,
SGD,
TRY,
USD,
UYU,
ZAR
Exemplo:

"BRL"

price_cts
integer

Valor em centavos. Se a requisição incluir produtos associados (products), este valor e a moeda (currency) serão ignorados. O negócio herdará automaticamente a soma calculada dos produtos e a moeda do primeiro produto associado.

Intervalo necessário: x >= 0
owner_email
string<email> | null

E-mail do membro do workspace a definir como responsável. Envie null para remover o responsável. Deve ser membro deste workspace.

Exemplo:

"joao@empresa.com"

forecast_date
string<date-time> | null
person_ids
string<uuid>[]
company_ids
string<uuid>[]
tags
string[]

Nomes (keys) das tags a associar. Se a tag não existir, será criada automaticamente.

Required string length: 1 - 30
custom_fields
object[]

Valores de campos adicionais. O comportamento depende de association_mode. No modo append, substitui o valor de cada field_key enviado sem alterar os demais.

products
object[]
association_mode
enum<string>
padrão:append

append: adiciona sem remover existentes. replace: remove todas as associações dos tipos enviados e insere as novas.

Opções disponíveis:
append,
replace

Resposta

Negócio atualizado com sucesso.

data
object