Leads and deals

Update a lead or deal

Changes the title, value, notes, contact or company. Only the fields you send change. Archived records return 404.

PATCH
/crm/lead-deals/{id}

Changes the title, value, notes, contact or company. Only the fields you send change. Archived records return 404.

Authorization

x-api-key
x-api-key<token>

Company API key, created under Settings > API Keys.

In: header

Path Parameters

id*string

The lead or deal id.

Header Parameters

x-company-id?string

Optional with an API key or OAuth token: leave it out and the company the key or token belongs to is used. If sent, it must be that same company, otherwise the request is refused with 403 API_KEY_WRONG_COMPANY or OAUTH_WRONG_COMPANY.

Match^[0-9a-fA-F]{24}$

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X PATCH "https://example.com/crm/lead-deals/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "address": "string",  "archiveBatchId": "string",  "archivedAt": "2019-08-24T14:15:22Z",  "assignedCompanyAt": "2019-08-24T14:15:22Z",  "assignedCompanyId": "string",  "assignedMembershipId": "string",  "attribution": {    "firstTouch": {      "capturedAt": "string",      "fbclid": "string",      "gclid": "string",      "landingPage": "string",      "msclkid": "string",      "referrer": "string",      "ttclid": "string",      "utmCampaign": "string",      "utmContent": "string",      "utmMedium": "string",      "utmSource": "string",      "utmTerm": "string"    },    "lastTouch": {      "capturedAt": "string",      "fbclid": "string",      "gclid": "string",      "landingPage": "string",      "msclkid": "string",      "referrer": "string",      "ttclid": "string",      "utmCampaign": "string",      "utmContent": "string",      "utmMedium": "string",      "utmSource": "string",      "utmTerm": "string"    }  },  "closedAt": "2019-08-24T14:15:22Z",  "companyEntityId": "string",  "companyId": "string",  "contactId": "string",  "createdAt": "2019-08-24T14:15:22Z",  "firstResponseAt": "2019-08-24T14:15:22Z",  "formIntakeNonce": "string",  "id": "string",  "isChainIntake": true,  "isExample": true,  "lastActivityActorId": "string",  "lastActivityAt": "2019-08-24T14:15:22Z",  "lastWorkActivityAt": "2019-08-24T14:15:22Z",  "location": {    "coordinates": [      0,      0    ],    "type": "Point"  },  "lostReason": "string",  "nextActivityAt": "2019-08-24T14:15:22Z",  "nextActivityKind": "string",  "nextActivityLabel": "string",  "notes": "string",  "number": 0,  "outcome": "Lost",  "ownerId": "string",  "phase": "DEAL",  "pipelineId": "string",  "rank": "string",  "rejectedAt": "2019-08-24T14:15:22Z",  "rejectedReason": "string",  "responseDeadlineAt": "2019-08-24T14:15:22Z",  "source": "Booking",  "sourceFormId": "string",  "stageId": "string",  "title": "string",  "updatedAt": "2019-08-24T14:15:22Z",  "value": 0}