Alladdin

Work in progress

Site en construction

الموقع قيد الإنشاء

Alladdin
PUT

Update a lead

Scope: crm:deals.write https://api.alladdin.com/api/v2/leads/{leadId}

Updates an existing lead.

Parameters

Path parameters

leadId string required

Lead ID

Request body

object funnel_id string

Funnel ID

contact_id string

Contact ID

name string

Lead name

stage_id string | null

Stage ID

value number | null

Deal value

potential number | null

Deal potential

due_date string<date> | null

Due date (YYYY-MM-DD)

assigned_to string | null

Assigned user ID

custom_fields[] object[] | null

Custom fields

status string

Lead status

Enum: open won lost

Request

python
import requests

url = "https://api.alladdin.com/api/v2/leads/{leadId}"
headers = {
    "Authorization": "Bearer YOUR_API_KEY",
    "Accept": "application/json",
}

payload = {
    "funnel_id": "string",
    "contact_id": "string",
    "name": "string",
    "stage_id": "string",
    "value": 0,
    "potential": 0,
    "due_date": "2024-01-15",
    "assigned_to": "string",
    "custom_fields": [
        {}
    ],
    "status": "open"
}
response = requests.put(url, headers=headers, json=payload)
print(response.json())

Responses

Response

json
{
  "id": "string"
}

Success responses

200 Lead updated application/json object id string

Error responses

400 Bad request application/json 401 Invalid or missing API key application/json 403 Insufficient permissions application/json 404 Lead not found application/json 422 Validation error application/json 429 Rate limit exceeded application/json

← PreviousUpdate a lead task →

Next →Update lead dates →