API Reference
- Addresses
- Attachments
- Calls
- Contacts
- Credit Applications
- Customers
- Deals
- Definitions
- DMV Fees
- Documents
- Fees
- Holidays
- Insurance Policies
- Insurance Quotes
- Leads
- Lead Events
- Listings
- Locations
- Logs
- Meetings
- Messages
- Pre-Approvals
- Sales Reps
- Searches
- Service Quotes
- Service Orders
- Taxes And Fees
- Templates
- CRM Trades
- Trades
- VDP Emails
- CRM Vehicles
- Vehicles
- Web Events
- Webhooks
Leads
Updates a Lead
Updates a Lead
PATCH
/
leads
/
{id}
Copy
curl --request PATCH \
--url https://commerce.driv.ly/api/leads/{id} \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"processStatuses": "Qualified Lead",
"reason": "Do Not Contact",
"latestEvent": 123,
"notes": "<string>",
"statusTracker": "<string>",
"searches": [
123
],
"attachments": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"phone": "<string>",
"call": "<string>",
"zipcode": "<string>",
"email": "<string>",
"loginEmail": "<string>",
"purchaseOption": "<string>",
"timeToPurchase": [
"ASAP"
],
"monthlyPayment": 123,
"budgetLower": "<string>",
"budgetUpper": "<string>",
"mileageLower": 123,
"mileageUpper": 123,
"cashDown": 123,
"newOrUsed": "<string>",
"bodyStyle": [
"truck"
],
"carStyle": [
"sedan"
],
"truckStyle": [
"crew"
],
"suvStyle": [
"small/compact"
],
"vanStyle": [
"cargo"
],
"yearLower": 123,
"yearUpper": 123,
"year": 123,
"make": "<string>",
"model": "<string>",
"exterior": [
"Silver"
],
"interior": [
"Black"
],
"fuelType": [
"Gasoline"
],
"drivetrain": [
"Four Wheel Drive"
],
"transmission": [
"Automatic"
],
"comfort": [
"Leather/premium Seats"
],
"safety": [
"Adaptive Cruise Control"
],
"entertainment": [
"Premium Audio System"
],
"utility": [
"Towing Package"
],
"subscribe": true,
"agree": true,
"customer": "<string>",
"messageNotifications": true,
"emailNotifications": true,
"emailAlerts": true,
"emailOffers": true,
"leadEvents": [
123
],
"cfZipcode": "<string>",
"cfState": "<string>",
"cfCity": "<string>",
"completedDate": "<string>",
"localTime": "<string>",
"trade": [
123
],
"messages": [
123
],
"creditScore": "<string>",
"contactScore": "<string>",
"contactBelongsTo": "<string>",
"contactType": "<string>",
"contactValid": true,
"testingCustomer": true,
"estimatedAgeRange": "<string>",
"estimatedAddress": "<string>",
"estimatedZipcode": "<string>",
"meetings": [
123
],
"makeAndModel": "<string>",
"conversation": "<string>",
"city": "<string>",
"state": "<string>",
"preApprovalId": "<string>",
"vdpEmails": [
123
],
"favorites": [
123
],
"calls": [
123
],
"salesRep": 123,
"preApprovals": [
123
],
"anonymousId": "<string>",
"manual": true,
"trim": "<string>",
"oneOwner": true,
"customers": 123,
"updatedAt": "<string>",
"createdAt": "<string>"
}'
Copy
{
"doc": {
"processStatuses": "Qualified Lead",
"reason": "Do Not Contact",
"latestEvent": 123,
"notes": "<string>",
"statusTracker": "<string>",
"searches": [
123
],
"attachments": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"phone": "<string>",
"call": "<string>",
"zipcode": "<string>",
"email": "<string>",
"loginEmail": "<string>",
"purchaseOption": "<string>",
"timeToPurchase": [
"ASAP"
],
"monthlyPayment": 123,
"budgetLower": "<string>",
"budgetUpper": "<string>",
"mileageLower": 123,
"mileageUpper": 123,
"cashDown": 123,
"newOrUsed": "<string>",
"bodyStyle": [
"truck"
],
"carStyle": [
"sedan"
],
"truckStyle": [
"crew"
],
"suvStyle": [
"small/compact"
],
"vanStyle": [
"cargo"
],
"yearLower": 123,
"yearUpper": 123,
"year": 123,
"make": "<string>",
"model": "<string>",
"exterior": [
"Silver"
],
"interior": [
"Black"
],
"fuelType": [
"Gasoline"
],
"drivetrain": [
"Four Wheel Drive"
],
"transmission": [
"Automatic"
],
"comfort": [
"Leather/premium Seats"
],
"safety": [
"Adaptive Cruise Control"
],
"entertainment": [
"Premium Audio System"
],
"utility": [
"Towing Package"
],
"subscribe": true,
"agree": true,
"customer": "<string>",
"messageNotifications": true,
"emailNotifications": true,
"emailAlerts": true,
"emailOffers": true,
"leadEvents": [
123
],
"cfZipcode": "<string>",
"cfState": "<string>",
"cfCity": "<string>",
"completedDate": "<string>",
"localTime": "<string>",
"trade": [
123
],
"messages": [
123
],
"creditScore": "<string>",
"contactScore": "<string>",
"contactBelongsTo": "<string>",
"contactType": "<string>",
"contactValid": true,
"testingCustomer": true,
"estimatedAgeRange": "<string>",
"estimatedAddress": "<string>",
"estimatedZipcode": "<string>",
"meetings": [
123
],
"makeAndModel": "<string>",
"conversation": "<string>",
"city": "<string>",
"state": "<string>",
"preApprovalId": "<string>",
"vdpEmails": [
123
],
"favorites": [
123
],
"calls": [
123
],
"salesRep": 123,
"preApprovals": [
123
],
"anonymousId": "<string>",
"manual": true,
"trim": "<string>",
"oneOwner": true,
"customers": 123,
"updatedAt": "<string>",
"createdAt": "<string>"
},
"message": "<string>"
}
Usage with the Drivly SDK
Usage with the Drivly SDK
Make sure you install our SDK first. You can find out how, and more here.
Copy
import { SDK } from '@drivly/commerce'
import type { leads } from '@drivly/commerce'
const sdk = new SDK(...)
const leads = await sdk.leads.update(leadsId: string, data: leads): Promise<leads>
Authorizations
Path Parameters
id of the Lead
Query Parameters
number of levels to automatically populate relationships and uploads
retrieves document(s) in a specific locale
specifies a fallback locale if no locale value exists
Body
application/json
Response
200
application/json
ok
The response is of type object
.
Copy
curl --request PATCH \
--url https://commerce.driv.ly/api/leads/{id} \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"processStatuses": "Qualified Lead",
"reason": "Do Not Contact",
"latestEvent": 123,
"notes": "<string>",
"statusTracker": "<string>",
"searches": [
123
],
"attachments": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"phone": "<string>",
"call": "<string>",
"zipcode": "<string>",
"email": "<string>",
"loginEmail": "<string>",
"purchaseOption": "<string>",
"timeToPurchase": [
"ASAP"
],
"monthlyPayment": 123,
"budgetLower": "<string>",
"budgetUpper": "<string>",
"mileageLower": 123,
"mileageUpper": 123,
"cashDown": 123,
"newOrUsed": "<string>",
"bodyStyle": [
"truck"
],
"carStyle": [
"sedan"
],
"truckStyle": [
"crew"
],
"suvStyle": [
"small/compact"
],
"vanStyle": [
"cargo"
],
"yearLower": 123,
"yearUpper": 123,
"year": 123,
"make": "<string>",
"model": "<string>",
"exterior": [
"Silver"
],
"interior": [
"Black"
],
"fuelType": [
"Gasoline"
],
"drivetrain": [
"Four Wheel Drive"
],
"transmission": [
"Automatic"
],
"comfort": [
"Leather/premium Seats"
],
"safety": [
"Adaptive Cruise Control"
],
"entertainment": [
"Premium Audio System"
],
"utility": [
"Towing Package"
],
"subscribe": true,
"agree": true,
"customer": "<string>",
"messageNotifications": true,
"emailNotifications": true,
"emailAlerts": true,
"emailOffers": true,
"leadEvents": [
123
],
"cfZipcode": "<string>",
"cfState": "<string>",
"cfCity": "<string>",
"completedDate": "<string>",
"localTime": "<string>",
"trade": [
123
],
"messages": [
123
],
"creditScore": "<string>",
"contactScore": "<string>",
"contactBelongsTo": "<string>",
"contactType": "<string>",
"contactValid": true,
"testingCustomer": true,
"estimatedAgeRange": "<string>",
"estimatedAddress": "<string>",
"estimatedZipcode": "<string>",
"meetings": [
123
],
"makeAndModel": "<string>",
"conversation": "<string>",
"city": "<string>",
"state": "<string>",
"preApprovalId": "<string>",
"vdpEmails": [
123
],
"favorites": [
123
],
"calls": [
123
],
"salesRep": 123,
"preApprovals": [
123
],
"anonymousId": "<string>",
"manual": true,
"trim": "<string>",
"oneOwner": true,
"customers": 123,
"updatedAt": "<string>",
"createdAt": "<string>"
}'
Copy
{
"doc": {
"processStatuses": "Qualified Lead",
"reason": "Do Not Contact",
"latestEvent": 123,
"notes": "<string>",
"statusTracker": "<string>",
"searches": [
123
],
"attachments": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"phone": "<string>",
"call": "<string>",
"zipcode": "<string>",
"email": "<string>",
"loginEmail": "<string>",
"purchaseOption": "<string>",
"timeToPurchase": [
"ASAP"
],
"monthlyPayment": 123,
"budgetLower": "<string>",
"budgetUpper": "<string>",
"mileageLower": 123,
"mileageUpper": 123,
"cashDown": 123,
"newOrUsed": "<string>",
"bodyStyle": [
"truck"
],
"carStyle": [
"sedan"
],
"truckStyle": [
"crew"
],
"suvStyle": [
"small/compact"
],
"vanStyle": [
"cargo"
],
"yearLower": 123,
"yearUpper": 123,
"year": 123,
"make": "<string>",
"model": "<string>",
"exterior": [
"Silver"
],
"interior": [
"Black"
],
"fuelType": [
"Gasoline"
],
"drivetrain": [
"Four Wheel Drive"
],
"transmission": [
"Automatic"
],
"comfort": [
"Leather/premium Seats"
],
"safety": [
"Adaptive Cruise Control"
],
"entertainment": [
"Premium Audio System"
],
"utility": [
"Towing Package"
],
"subscribe": true,
"agree": true,
"customer": "<string>",
"messageNotifications": true,
"emailNotifications": true,
"emailAlerts": true,
"emailOffers": true,
"leadEvents": [
123
],
"cfZipcode": "<string>",
"cfState": "<string>",
"cfCity": "<string>",
"completedDate": "<string>",
"localTime": "<string>",
"trade": [
123
],
"messages": [
123
],
"creditScore": "<string>",
"contactScore": "<string>",
"contactBelongsTo": "<string>",
"contactType": "<string>",
"contactValid": true,
"testingCustomer": true,
"estimatedAgeRange": "<string>",
"estimatedAddress": "<string>",
"estimatedZipcode": "<string>",
"meetings": [
123
],
"makeAndModel": "<string>",
"conversation": "<string>",
"city": "<string>",
"state": "<string>",
"preApprovalId": "<string>",
"vdpEmails": [
123
],
"favorites": [
123
],
"calls": [
123
],
"salesRep": 123,
"preApprovals": [
123
],
"anonymousId": "<string>",
"manual": true,
"trim": "<string>",
"oneOwner": true,
"customers": 123,
"updatedAt": "<string>",
"createdAt": "<string>"
},
"message": "<string>"
}
Assistant
Responses are generated using AI and may contain mistakes.