---
title: "Create Lead"
method: POST
path: "/{sub_domain}/api/leads"
tags: ["Leads"]
---

# Create Lead

`POST /{sub_domain}/api/leads`

## Request

- Base URL: `https://api.commpeak.com/dialer`
- URL: `https://api.commpeak.com/dialer/{sub_domain}/api/leads`
- Auth: API key in header `Authorization`

Create one or more leads in a single request.

**When to use.** Import leads into your account in bulk. To change existing leads, use `PUT /leads/{id}` for one lead or `PUT /leads/mass-update` for many.

**Request body.** A JSON array of lead objects. Only `phone` is required on each lead. Other fields are optional, including `first_name`, `last_name`, `phone2`, address fields, purchase details, `email`, `birthdate`, `loan_amount`, and a `customFields` object of your own field name and value pairs.

**Returns.** `{ "leads": [ ... ] }` containing the created leads, each with its assigned `id` and any `customFields`.

**Example.** `POST /api/leads` with body `[ { "phone": "12125551234", "first_name": "John" } ]`

## Path parameters

- `sub_domain` string, required: Dialer Name (subdomain)

## Request body

- LeadCreateInput[]
  - `first_name` string, nullable: First name.
  - `last_name` string, nullable: Last name.
  - `phone` string, required: Phone.
  - `phone2` string, nullable: Phone2.
  - `address1` string, nullable: Address1.
  - `address2` string, nullable: Address2.
  - `country` string, nullable: Country name / ISO / ISO3.
  - `state` string, nullable: State.
  - `city` string, nullable: City.
  - `zip` string, nullable: Zip.
  - `lat` number, nullable: Latitude.
  - `lng` number, nullable: Longitude.
  - `timezone` string, nullable: Timezone.
  - `original_identifier` string, nullable: Original identifier.
  - `support_site` string, nullable: Support site.
  - `purchase_site` string, nullable: Purchase site.
  - `purchase_date` string, nullable: Purchase date.
  - `purchase_amount` string, nullable: Purchase amount.
  - `purchase_product_name` string, nullable: Purchase product name.
  - `purchase_card_name` string, nullable: Purchase card name.
  - `purchase_card_type` string, nullable: Purchase card type.
  - `purchase_card_digits` string, nullable: Purchase card digits.
  - `email` string, nullable: Email.
  - `birthdate` string, nullable: Birthdate.
  - `loan_amount` string, nullable: Loan amount.
  - `customFields` object, nullable: Custom field name/value pairs.

## Response `201`

Successful Response

- LeadsListResponse
  - `leads` LeadItem[], required
    - `id` integer, nullable: Lead ID.
    - `lead_file_id` integer, nullable: Lead file ID.
    - `api_user_id` integer, nullable: API user ID.
    - `first_name` string, nullable: First name.
    - `last_name` string, nullable: Last name.
    - `phone` string, nullable: Phone.
    - `phone_normalized` string, nullable: Phone normalized.
    - `country_id` integer, nullable: Country ID.
    - `timezone_id` integer, nullable: Timezone ID.
    - `support_site` string, nullable: Support site.
    - `purchase_site` string, nullable: Purchase site.
    - `purchase_amount` integer, nullable: Purchase amount.
    - `is_deleted` integer, nullable: Is deleted (1 - deleted, 0 - active).
    - `is_do_not_call` integer, nullable: Is do not call.
    - `is_locked` integer, nullable: Is locked (1 - in call, 0 - available).
    - `hlr` integer, nullable: HLR.
    - `created_at` string, nullable: Created at.
    - `updated_at` string, nullable: Updated at.
    - `customFields` object, nullable: Custom field name/value pairs.
  - `total_leads` integer, nullable: Total number of leads in the response.

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/commpeak/apis/commpeak-dialer-api.md) - [All operations](https://skmtc.dev/commpeak/apis/commpeak-dialer-api/llms.txt) - [OpenAPI document](https://skmtc.dev/commpeak/apis/commpeak-dialer-api/revisions/18c5edc07544?raw)
