---
title: "Create a domains-only workflow: the server finds people at the given company domains, enriches them, and delivers the results to your webhook"
method: POST
path: "/v1/leads-to-email/domains"
tags: ["leads-to-email"]
---

# Create a domains-only workflow: the server finds people at the given company domains, enriches them, and delivers the results to your webhook

`POST /v1/leads-to-email/domains`

## Request

- Base URL: `https://developer.saleshandy.com` (the document declares no server; this is the origin it was published from)
- URL: `https://developer.saleshandy.com/v1/leads-to-email/domains`
- Auth: API key in header `x-api-key`
- TypeScript: <https://skmtc.dev/saleshandy/apis/develop-with-saleshandy/docs/v1/leads-to-email/domains/post.ts> (a function with typed inputs; its response is checked against the schema)

## Request body

- StartDomainsWorkflowDto
  - `domains` string[], required: Company domains to enrich. Each entry is a bare domain/URL string or an object { domain, jobTitle?, department?, managementLevel?, decisionMaker? } whose criteria filter the people picked for THAT domain.
  - `webhookUrl` string, required: Webhook URL that receives the final result once enrichment completes (single webhook with the enriched records).
  - `filters` object: Search filters AND-combined onto every domain's people search — e.g. { "location": { "includes": ["United States"] } }.
  - `exportColumns` string[]: Columns for the enriched output. Defaults to the key-columns set when omitted or empty.
  - `leadsPerDomain` number: How many people to enrich per domain (top-ranked by lead score). Defaults to 2 when omitted.

## Response `201`

Workflow created. Returns the workflow id to track progress.

- object
  - `message` string
  - `payload` object
    - `success` boolean
    - `id` string
    - `status` string

## Other responses

- `400`: 4000: Failed to create leads-to-email workflow<br><br>
- `401`: 1001: Invalid token<br><br>

## Changes

- **2026-09-16** `a483e105b20f`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/saleshandy/apis/develop-with-saleshandy/changes/v1/leads-to-email/domains/post.md)

---

[API](https://skmtc.dev/saleshandy/apis/develop-with-saleshandy.md) - [All operations](https://skmtc.dev/saleshandy/apis/develop-with-saleshandy/llms.txt) - [OpenAPI document](https://skmtc.dev/saleshandy/apis/develop-with-saleshandy/revisions/e7a29c931aa7?raw)
