Retrieve a single lead

You can fetch a single lead.

 

Request Path Parameters
Parameter Type Required Description
org_id number Yes The unique identifier of your organization
id number Yes The unique identifier of the lead

 

Example Request & Response


$ curl https://api.custerem.com/<org_id>/leads/<id>/ \
-X GET \
-H 'Authorization: X-API-KEY <Your API Key>' \
-H 'Content-Type: application/json' \

 

200 OK

{
    "lead": {
        "id": 3,
        "opportunities": [
            {
                "id": 9,
                "status": {
                    "id": 19,
                    "title": "Won",
                    "pipeline": {
                        "id": 4,
                        "name": "Sales Pipeline"
                    },
                    "color": "#88dd88"
                },
                "estimated_close": "2022-02-17T07:04:00Z",
                "value": "1.00",
                "value_cycle": "M",
                "lead": {
                    "id": 3,
                    "created_at": "2022-02-05T07:10:06.049156Z",
                    "updated_at": "2022-02-05T07:10:06.049184Z",
                    "company_name": "Custerem",
                    "user_company": 1,
                    "contact_company": 2,
                    "assigned_user": 1,
                    "contacts": [
                        3,
                        2
                    ]
                },
                "notes": "",
                "user": {
                    "id": 2,
                    "email": "hayri.cicek@custerem.com",
                    "profile": {
                        "name": "Hayri Cicek"
                    }
                },
                "contact": {
                    "id": 2,
                    "first_name": "John",
                    "last_name": "Doe",
                    "phone_number": "",
                    "email": "mail@example.com"
                },
                "confidence": 44,
                "created_at": "2022-02-22T07:04:52.043720Z",
                "updated_at": "2022-02-22T07:05:04.400515Z"
            }
        ],
        "company_name": "Joe Enterprise",
        "contact_company": 2,
        "contacts": [
            {
                "id": 3,
                "first_name": "Hayri",
                "last_name": "Cicek",
                "job_title": "",
                "email": "mail@example.com",
                "phone_number": "",
                "company": {
                    "id": 3,
                    "name": "My Company"
                }
            }
        ],
        "created_at": "2022-02-05T07:10:06.049156Z",
        "lead_tasks": [
            {
                "id": 2,
                "task_description": "2343r",
                "date": "2022-02-26T07:13:00Z",
                "user": {
                    "id": 1,
                    "email": "hayri.cicek@custerem.com",
                    "profile": {
                        "name": "Hayri Cicek"
                    }
                },
                "done": false
            }
        ]
    }
}

 

404 Not Found

{
    "status_code": 404,
    "message": "Lead with id 2 not found"
}