Update a Lead
PUT/api/leads/{id}
Headers
| Field | Type | Description |
|---|---|---|
| authtoken | String | Authentication token, generated from admin area |
Parameters
| Field | Type | Description |
|---|---|---|
| id | Number | lead unique ID. |
| company_name | string | Mandatory Lead Name. |
| owner_id | string | Mandatory Lead owner id |
| lead_status_id | string | Mandatory Lead status id |
| lead_source_id | string | Mandatory Lead source id |
| address | string | Optional Lead address |
| city | string | Optional Lead city |
| state | string | Optional Lead state |
| zip | string | Optional Lead zip |
| country | string | Optional Lead country |
| phone | string | Optional Lead phone |
| website | string | Optional Lead website |
| vat_number | string | Optional Lead vat number |
curl -X PUT "https://yoursite.com/api/leads/123" \
-H "authtoken: YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "company_name": "...", "owner_id": "...", "lead_status_id": "...", "lead_source_id": "...", "address": "...", "city": "...", "state": "...", "zip": "...", "country": "...", "phone": "...", "website": "...", "vat_number": "..." }' Success-Response:
HTTP/1.1 200 OK
{
"status": true,
"message": "Lead Update Successful."
}
HTTP/1.1 404 Not Found
{
"status": false,
"message": "Lead Update Fail."
}