---
title: "Log inbound sales emails in your CRM · Polpo Mail"
description: "Post every email to sales@ to your CRM or lead database as JSON, with your API key in a custom header, so no enquiry gets lost in an inbox."
url: https://polpomail.com/use-cases/crm-leads
last_updated: 2026-11-26
---

[Use cases](https://polpomail.com/use-cases)

# Log inbound sales emails in your CRM

Post every email to sales@ to your CRM or lead database as JSON, with your API key in a custom header, so no enquiry gets lost in an inbox.

[Create your free workspace](https://polpomail.com/signup) [How webhooks work](https://polpomail.com/webhooks)

## Why automate it

Leads that arrive by email often never reach the CRM. A webhook on sales@ sends each enquiry to your CRM's inbound endpoint, or to a small function that creates the contact and the deal.

How it works

## Set it up in three steps

1. 1

   ### Filter on sales@

   Set To or Cc matches to sales@*, or a pattern such as ^(sales|hello)@ to cover several addresses.
2. 2

   ### Add your CRM credentials as a header

   Request headers are sent with every call, for example Authorization: Bearer <your CRM key>. Extra JSON fields such as pipeline and source are added to the payload.
3. 3

   ### Create the lead

   Use the sender's name and address for the contact and the subject and text for the deal notes.

Settings

## The webhook to create

In Settings › Developer, after you sign in.

|  |  |
| --- | --- |
| Format | JSON |
| From matches | empty (any sender) |
| To or Cc matches | `sales@*` |
| Request headers | `Authorization: Bearer <your CRM API key>` |
| Extra JSON | `{"pipeline": "inbound", "source": "email"}` |

- Every enquiry lands in the CRM, including ones that arrive at night or during holidays.
- Your own fields (pipeline, source, owner) arrive with each lead.
- One pattern such as ^(sales|hello)@ covers several sales addresses.

Example

## Node.js (Express): create a lead

Every request includes the webhook's token in `X-Polpo-Webhook-Token`; check it first. See the [payload reference](https://polpomail.com/developers#webhooks).

```
app.post("/hooks/leads", express.json(), async (req, res) => {
  if (req.get("X-Polpo-Webhook-Token") !== process.env.POLPO_TOKEN) return res.sendStatus(401);
  const { message: m, pipeline, source } = req.body;
  await crm.leads.create({
    name: m.from.name || m.from.address,
    email: m.from.address,
    title: m.subject,
    notes: m.text,
    pipeline, source,
  });
  res.sendStatus(204);
});
```

FAQ

## Common questions

**My CRM expects a specific JSON format. Can I change the field names?**

You can add fields with extra JSON, but the standard fields keep their names. If your CRM needs a fixed format, put a small function or a no-code tool such as n8n, Zapier or Make in between to map the fields.

**How do I keep the CRM key secret?**

Put it in a request header on the webhook. Headers are only visible to you in Settings › Developer and are sent over HTTPS when your endpoint uses https://.

**Is this included in the free plan?**

Yes. Webhooks, the REST API and access tokens are included free, with up to 5 webhooks per mailbox and up to 10 mailboxes per domain.

## More use cases

[### Support tickets from support@ Send every email to support@ to your helpdesk or your own ticket system as JSON the moment it arrives, with sender, subject, body and attachments. See how →](https://polpomail.com/use-cases/support-tickets) [### Supplier invoices to accounting When an invoice arrives at invoices@, your webhook gets the details and a link to download each PDF with the REST API, ready for bookkeeping or OCR. See how →](https://polpomail.com/use-cases/invoice-processing) [### Alerts in Slack, Teams or Discord Forward alert, order or VIP emails to a team chat channel: a webhook sends the email to a small function or automation that posts the message. See how →](https://polpomail.com/use-cases/chat-alerts) [### Zapier, Make and n8n without polling Use a webhook as an instant email trigger for no-code automations: point it at a Zapier Catch Hook, a Make custom webhook or an n8n Webhook node. See how →](https://polpomail.com/use-cases/no-code-automation) [### AI triage and auto-sorting Send each new email to your own AI classifier, then file, flag or draft a reply with the REST API: email triage you control, on your own domain. See how →](https://polpomail.com/use-cases/ai-email-triage)

## Start with one webhook.

Free business email on your own domain, with webhooks and a REST API included.

[Create your free workspace](https://polpomail.com/signup)
