Skip to main content
PATCH
/
v1
/
leads
/
{id}
/
status
curl -X PATCH https://api.sendpilot.ai/v1/leads/lead_abc123/status \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "status": "OPPORTUNITY"
  }'
{
  "id": "lead_abc123",
  "linkedinUrl": "https://www.linkedin.com/in/john-doe",
  "previousStatus": "REPLY_RECEIVED",
  "status": "OPPORTUNITY",
  "updatedAt": "2024-02-24T15:30:00.000Z"
}
Manually update a lead’s status. This is useful for marking leads as opportunities or not interested based on external information.

Request

X-API-Key
string
required
Your API key
leadId
string
required
The lead ID
status
string
required
The new status for the lead. Options:
  • OPPORTUNITY - Mark as a sales opportunity
  • NOT_INTERESTED - Mark as not interested
  • DONE - Mark as completed

Response

id
string
Lead identifier
linkedinUrl
string
LinkedIn profile URL
previousStatus
string
The status before this update
status
string
The new status
updatedAt
string
ISO 8601 timestamp of the update
curl -X PATCH https://api.sendpilot.ai/v1/leads/lead_abc123/status \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "status": "OPPORTUNITY"
  }'
{
  "id": "lead_abc123",
  "linkedinUrl": "https://www.linkedin.com/in/john-doe",
  "previousStatus": "REPLY_RECEIVED",
  "status": "OPPORTUNITY",
  "updatedAt": "2024-02-24T15:30:00.000Z"
}
When a lead’s status is updated, a lead.status.changed webhook event will be sent to your registered webhook endpoints.

Authorizations

X-API-Key
string
header
required

API key for authentication

Path Parameters

id
string
required

Lead ID

Body

application/json
status
enum<string>
required

New status for the lead

Available options:
PENDING,
CONNECTION_SENT,
CONNECTION_ACCEPTED,
MESSAGE_SENT,
REPLY_RECEIVED,
DONE
note
string

Optional note for the status change

Response

Lead status updated

success
boolean
required
leadId
string
required
status
string
required
message
string
required