---
agent:
  instructions: "Use this search API to find relevant content across this site with keywords or natural-language queries, instead of crawling individual pages. Results are returned in Markdown."
  endpoint: "https://elaichi.ai/.well-known/search?q={query}"
  method: "GET"
  documentation: "https://developers.cloudflare.com/ai-search/how-to/search-for-agents/"
---

# Trigger an AI Workflow From a Webhook on Deal Won

> Trigger an AI workflow from a webhook when a deal closes. Your CRM sends it, an agent preps onboarding, and a person approves before anything goes out.

**TL;DR** With Elaichi, you can trigger an AI workflow from a webhook when a deal closes. Your CRM sends the webhook when a deal is won, and Elaichi starts the run on its own address. An agent step preps onboarding, and a named person approves before any message or invoice goes out. Elaichi does not watch events inside your CRM, so the CRM has to send the webhook. Workflows come with the Black plan, and every new workspace starts with a 14-day free trial.

A deal closes on Friday afternoon. By Monday, nobody has made the onboarding task, posted in Slack or sent the first invoice. Someone has to remember, copy the details and write the same email again.

You can trigger an AI workflow from a webhook when a deal closes and let it prep all of it. A [webhook](https://en.wikipedia.org/wiki/Webhook) is a message one app sends to a web address when something happens. Your CRM sends it. Elaichi starts a run. A person approves before anything leaves the building.

## How do you trigger an AI workflow from a webhook when a deal closes?

The CRM sends a webhook to the address of an Elaichi workflow, and that call starts a run. Each workflow can have a webhook start with its own address. The address takes a POST request. It can also take a PUT request, if you allow it.

The deal details travel in the message. The workflow's agent step reads them and gets on with the job. You can read each run step by step afterward, including what the agent did.

Elaichi has no start for an event inside a connected app. It does not poll your CRM or watch deals. The CRM must send the webhook. That sounds like a limit, and it is one. It also keeps the trigger simple: one call in, one run out.

## Which CRMs can send a webhook when a deal closes?

Many CRMs can send one from their own automation tools. You must confirm yours can, and on which plan. HubSpot's help page says its workflow action called "Send a webhook" sends a POST or GET request to an HTTPS address, and lists the plans that include it ([HubSpot webhooks in workflows](https://knowledge.hubspot.com/workflows/how-do-i-use-webhooks-with-hubspot-workflows), checked November 2026). That page covers workflows built on contacts. Read the page for your own object and plan before you plan around it.

For Salesforce and Pipedrive, this post makes no claim. Open each vendor's own docs and look for an outbound webhook or a similar step on the deal object. If your CRM can send a webhook when a deal is won, the rest of this post applies unchanged.

## What should the AI do after a deal closes?

Give the agent step a small, checkable job. It reads the deal, then drafts the work that onboarding needs. Good first jobs:

- A task for the account owner, with the deal size and the promised start date.
- A note for your team's Slack channel with who bought and what.
- A draft invoice in your billing app.
- A draft welcome email in Gmail or Outlook.

Keep the draft steps and the send steps apart. The agent step writes. A later step sends. Between them sits a person. A workflow may have up to five agent steps and up to five approve steps, so you have room.

Emily Carter's team at a small agency does it this way. The agent drafts a welcome email for each closed deal. Emily reads it before it goes out.

## How do you stop the AI from sending the wrong email?

Put an approve step before every step that sends, changes or deletes something. An approve step asks the people you name, and the owner too unless you leave the owner out. You can bar the person who started the run from approving it.

The request reaches the Approvals page in Elaichi, Slack and email. In Slack, the card carries Approve and Reject buttons only when no step that deletes waits behind it. A request expires after 72 hours unless you set another time. A rejection ends the run as cancelled.

Only a person can answer. No AI client, no Elaichi Agent and no workflow can approve or reject. For the wider picture, see [human approval for AI agent actions](/blog/human-approval-for-ai-agent-actions/).

## How do you keep the webhook safe?

Elaichi checks each delivery one of three ways. The default is a signature check, using the [Standard Webhooks](https://www.standardwebhooks.com/) headers. The second is a secret token. The third is a signature with a preset for GitHub, Stripe, Slack or Linear, or one you define. GitHub documents its own scheme in [validating webhook deliveries](https://docs.github.com/en/webhooks/using-webhooks/validating-webhook-deliveries), which shows what a signature check looks like.

Pick the check your CRM can send. A token can ride in a header or in the address as a query value, which helps when a sender cannot set custom headers. Each delivery is capped at 512 KB. A repeated delivery is answered as a duplicate and does not run twice. Credential headers are stripped before the workflow sees the data.

A secret is shown once, in the console. Only a person in the console can reveal, rotate or set it. An AI client cannot.

## How do you build, test and turn on the workflow?

Ask Claude, ChatGPT, Perplexity, Cursor, Microsoft Copilot or the Elaichi Agent to draft it in plain English. A new workflow is a draft. Copy the webhook address from the draft, add it to your CRM, and close a test deal. A delivery to a draft is kept as a sample, so you can replay it.

Then run a test run, called "Test run (changes nothing)" in the console. Steps that only read run for real. Steps that write are recorded as what they would have done. A notify step sends nothing. An approve step says what it would ask and carries on. A test run costs no run time.

When the test looks right, publish. That makes a numbered version. Turning it on is a separate step. A version started by a webhook needs a role that can publish, which Member holds. For the whole loop, see [how Elaichi workflows run](/blog/elaichi-workflows/).

A real run acts as its owner, with the owner's connections and limits. Pick an owner whose access fits the job.

## Do you need Elaichi to do this?

You may not. If your CRM's own workflow tool already creates the task, posts to Slack and sends the email you want, use it. It is one fewer system, and it starts from the deal event with no webhook at all. The same holds when the steps are fixed and need no judgment.

Elaichi earns its place when the prep needs reading and writing across apps, or when a person must approve first. It also helps when the same workflow touches the CRM, Slack and billing app together, with one record of every run. Workflows come with the Black plan. See [what Black includes](/blog/elaichi-black-plan/) for the price.

Every new workspace starts with a 14-day free trial of Black, with every feature on and no card.

[Start the free trial](https://app.elaichi.ai/signup)

## FAQ

### Can an AI workflow start when a deal closes in my CRM?

Yes, if your CRM can send a webhook when a deal is won. In Elaichi, the workflow starts from a webhook address that your CRM calls. Elaichi does not watch for the deal itself. An agent step then preps onboarding, and a person approves before anything is sent.

### Does Elaichi watch HubSpot, Salesforce or Pipedrive for closed deals?

No. Elaichi has no start for an event inside a connected app. The CRM has to send a webhook to the workflow's address. Once the workflow runs, it can read and write in the apps the owner has connected.

### How does Elaichi know a webhook really came from my CRM?

Elaichi checks every delivery. The default check is a signature. You can use a secret token instead, or a signature scheme such as the ones GitHub and Stripe use. A secret is shown once in the console. No AI client can read or change it.

### Will the AI send the welcome email without asking?

Not unless you build it that way. Put an approve step before the step that sends. A named person says yes or no in Elaichi or in Slack, and only a person can answer. A test run never sends anything.

### Who does the workflow run as?

A real run acts as the workflow's owner, with the owner's connections and limits. If the owner can no longer act, the run fails and the workflow pauses.

## Read next

- [AI Workflow Automation With Approvals](/blog/elaichi-workflows/) — AI workflow automation on Elaichi Black. Your own AI writes and test-runs the workflow, a person approves the risky step, and it runs as its owner.
- [Human approval for AI agent actions, with an audit trail](/blog/human-approval-for-ai-agent-actions/) — Human approval for AI agent actions in SaaS apps: client prompts, role restrictions, access requests, workflow approvals and one audit trail.
- [Elaichi Black: Workflows, Dashboards and the Agent](/blog/elaichi-black-plan/) — Elaichi Black puts connectors, workflows, dashboards and AI in one place, under one set of rules. Your own AI does the building. Here is what it adds and costs.
