DM customers on Messenger when their HubSpot deal moves stages

By General Input

Every time a deal moves in HubSpot, your customer gets a perfectly tailored Messenger note. Celebrations for closed-won, check-ins after a proposal, soft asks after a loss.

Integrations

  • HubSpot
  • Manychat

Type

Agentic Task

Categories

  • Sales
  • Marketing

Build me an agent workflow that reacts to HubSpot deal stage changes by sending the customer a perfectly tailored Manychat Messenger DM.

Trigger: a HubSpot webhook fired when a deal's dealstage property changes. The webhook payload gives you the deal ID and the new stage value.

When the webhook fires, the agent should do this:

1. Call HubSpot Get Deal on the incoming deal ID. Request the dealname, dealstage, amount, pipeline, and hubspot_owner_id properties, and include the contacts association so we can resolve the primary contact.

2. Take the first associated contact ID and call HubSpot Get Contact to fetch the contact's email, firstname, and lastname.

3. Call Manychat Find Subscriber by System Field with that email. If no subscriber is returned, stop silently. Do not log a noisy error and do not try to create the subscriber. Many HubSpot contacts will simply not be in the Messenger audience and that is fine.

4. If a subscriber is found, decide what to say based on the new dealstage. Default behaviors:

- Proposal Sent: a friendly check-in offering to answer any open questions about the proposal.

- Closed Won: a celebratory message thanking them and pointing to the onboarding next steps.

- Closed Lost: a soft, low-pressure feedback request asking what would have made it a better fit.

For any other stage value, skip silently. Make the stage map easy to edit in one place so I can add more stages later.

5. Use AI to draft the actual message text in the brand voice. The voice is short, casual, and Messenger-appropriate. Two or three sentences max, no formal sign-off, no corporate jargon, address the customer by first name when we have it. The AI is only used for drafting copy. It does not decide which stage triggers which message.

6. Call Manychat Send Content to deliver the message to the subscriber. Use the Dynamic Block v2 format with one text message and two quick-reply buttons appropriate to the stage. Suggested defaults: Proposal Sent gets 'Got a question' and 'Looks good', Closed Won gets 'Start onboarding' and 'Talk to a human', Closed Lost gets 'Share feedback' and 'Maybe later'. Quick replies should route to existing flows or simply capture a reply, whichever the user has set up.

7. Call Manychat Set Custom Field by Name on the same subscriber to mirror the new HubSpot deal stage into a field called hubspot_deal_stage (case-insensitive). This keeps Manychat segments and future automations in sync with where the deal is in HubSpot.

Other requirements: dedupe so the same stage transition only fires one DM (HubSpot can send the same change event more than once). Respect Messenger's 24-hour messaging window. If Send Content returns a messaging-restriction error, log it and move on without retrying. Keep the stage-to-message rules in a single config block at the top of the workflow so I can edit copy, quick replies, and stage names without hunting through code.

Related prompts

Explore more prompts
Turn Mailjet email clicks into ranked HubSpot follow-upsiMessage campaign console with pre-flight checks and delivery boardA searchable RFP answer library your bid team drafts fromSee which target accounts just started advertising on LinkedInAccount health board that puts product usage next to your CRMLook up a customer's full chat history mid conversationLusha prospecting workbench with credit-safe revealsWhich companies your LinkedIn ads reach, matched to your CRMLead response desk with a running clock on every new leadApprove Lusha enrichment field by field before HubSpot saves it