crm-v1-deals

Criar negociação

Criar negociação

post/deals

Request

  • Base URL
    https://crm.rdstation.com/api/v1
  • URL
    https://crm.rdstation.com/api/v1/deals
  • Auth
    API key in query parameter token

Request body

Example request

{
  "campaign": {
    "_id": "63d83e4f8cc2e6000f8e91c8"
  },
  "contacts": [
    {
      "birthday": {
        "day": 11,
        "month": 9,
        "year": 1979
      },
      "emails": [
        {
          "email": "email1@empresa.com"
        }
      ],
      "facebook": "https://...",
      "legal_bases": [
        {
          "category": "data_processing",
          "status": "granted",
          "type": "consent"
        }
      ],
      "linkedin": "http://...",
      "name": "Alexandre",
      "phones": [
        {
          "phone": "3165585457",
          "type": "cellphone"
        }
      ],
      "skype": "alexandre@email.com",
      "title": "Gerente"
    }
  ],
  "deal": {
    "deal_custom_fields": [
      {
        "custom_field_id": "63c188a315b034000fbf62d1",
        "value": "Opção A"
      }
    ],
    "deal_stage_id": "633de55c96c4ac0019c8a638",
    "name": "Negociação",
    "rating": 1,
    "user_id": "5d1e122a572a6c0034f2e595"
  },
  "deal_products": [
    {
      "amount": 1.1,
      "base_price": 199.91,
      "description": "Description Product 1",
      "discount_type": "value",
      "name": "Product 01",
      "price": 199.91,
      "recurrence": "spare",
      "total": 199.91
    }
  ],
  "deal_source": {
    "_id": "61140ea5c794c70001b71985"
  },
  "distribution_settings": {
    "owner": {
      "email": "contato@email.com",
      "id": "5d1e122a572a6c0034f2e595",
      "type": "team"
    }
  },
  "organization": {
    "_id": "64d3eb42e42434000114c68b"
  }
}

Response

Success

_idstring
amount_montlynumber
amount_totalnumber
amount_uniquenumber
best_moment_to_touchboolean
c_cf_errorsobject
campaign_idstring
closed_atstring date-time nullable
contact_errorsobject
created_atstring
deal_lost_reason_idstring nullable
deal_source_idstring
errorsobject
from_rdsm_integrationboolean
holdboolean nullable
idstring
interactionsnumber
last_note_contentstring nullable
namestring
prediction_datestring date nullable
ratingnumber
updated_atstring
winboolean nullable

Example response

{
  "_id": "ID",
  "amount_total": 399.83,
  "amount_unique": 399.83,
  "best_moment_to_touch": true,
  "campaign": {
    "_id": "ID",
    "id": "ID",
    "name": "Campanha A"
  },
  "campaign_id": "ID",
  "created_at": "2023-08-30T22:43:58.453-03:00",
  "deal_custom_fields": [
    {
      "custom_field": {
        "_id": "ID",
        "allow_new": true,
        "created_at": "2023-01-13T13:36:51.156-03:00",
        "for": "deal",
        "instance_id": "ID",
        "label": "Assuntos relacionados",
        "opts": [
          "Assunto 2",
          "Assunto 3",
          "Opção A"
        ],
        "order": 1,
        "type": "option",
        "updated_at": "2023-08-30T21:51:06.034-03:00"
      },
      "custom_field_id": "ID",
      "value": "Opção A"
    }
  ],
  "deal_products": [
    {
      "_id": "ID",
      "amount": 1.1,
      "base_price": 199.91,
      "created_at": "2023-08-30T22:43:58.644-03:00",
      "description": "Description Product 1",
      "discount_type": "value",
      "id": "ID",
      "name": "Product 01",
      "price": 199.91,
      "product_id": "ID",
      "recurrence": "spare",
      "total": 199.91,
      "updated_at": "2023-08-30T22:43:58.644-03:00"
    }
  ],
  "deal_source": {
    "_id": "ID",
    "id": "ID",
    "name": "3.0"
  },
  "deal_source_id": "ID",
  "deal_stage": {
    "_id": "ID",
    "deal_pipeline_id": "ID",
    "id": "ID",
    "name": "Converteu",
    "nickname": "C"
  },
  "deal_stage_histories": [
    {
      "_id": "ID",
      "deal_stage_id": "ID",
      "id": "ID",
      "start_date": "2023-08-30T22:43:58.449-03:00"
    }
  ],
  "id": "ID",
  "name": "Negociação",
  "organization": {
    "_id": "ID",
    "id": "ID",
    "name": "A2 Tecnologia & Inovação",
    "visible": true
  },
  "rating": 1,
  "stop_time_limit": {
    "expiration_date_time": "2026-05-25T22:43:58.453-03:00"
  },
  "updated_at": "2023-08-30T22:43:58.677-03:00",
  "user": {
    "_id": "ID",
    "id": "ID",
    "name": "NAME"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.