Skip to main content
DELETE
/
customers
/
{id}
Deletes an existing Customer
curl --request DELETE \
  --url https://commerce.driv.ly/api/customers/{id} \
  --header 'Authorization: <api-key>'
{
  "doc": {
    "updatedAt": "<string>",
    "createdAt": "<string>",
    "customerId": "<string>",
    "leads": [
      123
    ],
    "address": 123,
    "shippingContact": 123,
    "deals": [
      123
    ],
    "createdBy": 123,
    "lastModifiedBy": 123,
    "email": "<string>",
    "phone": "<string>",
    "insurancePolicies": [
      123
    ],
    "tenants": [
      123
    ],
    "consumerStatus": "SOLD",
    "consumerFirstName": "<string>",
    "consumerMiddleName": "<string>",
    "consumerLastName": "<string>",
    "consumerSuffix": "<string>",
    "consumerDateOfBirth": "<string>",
    "consumerEducationLevel": "<string>",
    "consumerVehicles": [
      123
    ],
    "consumerPhoneType": "<string>",
    "consumerDriversLicense": "<string>",
    "consumerDriversLicenseState": "<string>",
    "consumerDriversLicenseNumber": "<string>",
    "consumerDriversLicenseExp": "<string>",
    "consumerDriversLicenseExpiration": "<string>",
    "consumerPreApprovals": [
      123
    ],
    "consumerGetPreApproved": "<string>",
    "consumerProvideProofOfInsurance": "<string>",
    "consumerLoginToBank": "<string>",
    "consumerConnectCar": "<string>",
    "consumerProvideProofOfIncome": "<string>",
    "consumerConsumerId": "<string>",
    "consumerCreditApplicationId": "<string>",
    "deals2": [
      123
    ],
    "consumerSocialSecurity": "<string>",
    "consumerDriversLicenceState": "<string>",
    "consumerIncome": 123,
    "consumerIncomeInterval": "<string>",
    "consumerEmploymentStatusCode": "<string>",
    "consumerEmploymentDuration": 123,
    "consumerEmployerName": "<string>",
    "consumerEmployerPhone": "<string>",
    "consumerEmploymentTitle": "<string>",
    "consumerPreviousEmployerName": "<string>",
    "consumerPreviousEmployerPhone": "<string>",
    "consumerPreviousEmploymentTitle": "<string>",
    "consumerPreviousEmploymentDuration": 123,
    "consumerPreviousEmploymentincome": 123,
    "consumerTimeAtResidence": 123,
    "consumerPreviousAddressLine1": "<string>",
    "consumerPreviousAddressLine2": "<string>",
    "consumerPreviousAddressCity": "<string>",
    "consumerPreviousAddressState": "<string>",
    "consumerPreviousZip": "<string>",
    "consumerPreviousAddressDuration": 123,
    "consumerResidenceType": "<string>",
    "consumerRentMortgage": 123,
    "consumerOtherIncomeDescription": "<string>",
    "consumerOtherIncomeAmount": 123,
    "consumerLeadSource": [
      "Car Concierge (Andrew)"
    ],
    "companyName": "<string>",
    "companyDealerDeals": [
      123
    ],
    "companyDealsFacilitated": [
      123
    ],
    "companyInsuranceQuotes": [
      123
    ],
    "companyType": [
      "Dealer"
    ],
    "companyWebsite": "<string>",
    "companyStripeConnectLink": "<string>",
    "companyCustomerPortalLink": "<string>",
    "companyServiceQuotes": [
      123
    ],
    "companyServiceOrders": "<string>",
    "companyServiceQuotesPartners": [
      123
    ],
    "companyVisibility": "<string>",
    "companyTenants2": [
      123
    ],
    "companyCustomer": [
      123
    ],
    "companyTrades": [
      123
    ],
    "companyTenants3": [
      123
    ],
    "companyPartnerBrand": 123,
    "companyDeals3": [
      123
    ],
    "companyRouteOneDealer": "<string>",
    "companyTransportServiceOrders": [
      123
    ]
  },
  "message": "<string>"
}
Make sure you install our SDK first. You can find out how, and more here.
import { SDK } from '@drivly/commerce'
import type { customers } from '@drivly/commerce'

const sdk = new SDK(...)

const customers = await sdk.customers.delete(customersId: string): Promise<void>

Authorizations

Authorization
string
header
required

Path Parameters

id
string
required

id of the Customer

Query Parameters

depth
number

number of levels to automatically populate relationships and uploads

locale
string

retrieves document(s) in a specific locale

fallback-locale
string

specifies a fallback locale if no locale value exists

Response

ok

doc
Customer · object
required
message
string
required