> ## Documentation Index
> Fetch the complete documentation index at: https://docs.os.default.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Handing off closed-won deals from sales to customer success with Default

> How to automate the sales to customer success handoff with Default: the CRM Record Updated trigger fires when a Salesforce Opportunity or HubSpot Deal reaches Closed Won, Round-Robin picks a customer success manager from a queue, Update Record writes them to the Account or Company, Create Slack Channel and Add Member to Slack Channel open a deal channel for the rep and the manager, Send Slack Message posts the deal context, and the kickoff meeting is booked from a booking link or the Chrome extension.

The sales to customer success handoff, also called the post-sales handoff or the sales to CS handoff,
moves a closed-won deal from the rep who sold it to the customer success manager (CSM) who onboards
the customer. It breaks down when nobody is assigned, the CSM hears about the deal days later, or
the deal context stays in the rep's head.

Default runs the handoff as a workflow. When a deal reaches Closed Won in Salesforce or HubSpot, it
picks a CSM from a queue, writes them to the CRM, opens a Slack channel with the rep and the CSM,
and posts the deal details there. The kickoff meeting is then booked from the CSM's booking link or
from the Chrome extension.

<Note>
  This page covers the handoff after a deal closes. To hand a lead from a sales development rep to
  an account executive, see [Handing off leads and meetings between reps](/scheduling/rep-handoffs).
</Note>

## The sales to customer success handoff at a glance

1. **The deal closes.** The **CRM Record Updated** trigger fires when a Salesforce Opportunity or a
   HubSpot Deal moves to your closed won stage.
2. **Default finds the account.** **Match Record** finds the Account in Salesforce or the Company in
   HubSpot that the deal belongs to.
3. **A queue picks the CSM.** **Round-Robin** picks a member of your customer success queue and
   passes them to later nodes as **Latest assigned user**.
4. **The CRM gets the CSM.** **Update Record** writes the CSM as the owner of the Account or
   Company.
5. **The team gets a channel.** **Create Slack Channel** opens a channel for the account, and
   **Add Member to Slack Channel** adds the CSM and the rep who closed the deal.
6. **The context lands in the channel.** **Send Slack Message** posts the deal details and asks the
   CSM to book the kickoff. Teams without Slack can use **Send Internal Email** instead.
7. **The kickoff gets booked.** See [Book the kickoff meeting](#book-the-kickoff-meeting).

## Handoff checklist: what the workflow carries over

| Item | Where the workflow gets it | Where it lands |
| - | - | - |
| The CSM | **Round-Robin** | The Account or Company owner, the Slack channel, and the message |
| The rep who closed the deal | The Opportunity or Deal owner, from the trigger | The Slack channel |
| Deal name, amount, and close date | The Opportunity or Deal, inserted with `{{` | The Slack message |
| What the rep promised and what comes next | Deal fields your reps fill in, such as the Opportunity's `Next Step` and `Description` | The Slack message |
| A reminder to book the kickoff | **Create Activity** or **Create Engagement**, optional | A CRM task owned by the CSM |

The workflow carries what is on the CRM record when the deal closes. A field the rep left empty
arrives empty in the message.

## Setup for the handoff workflow

| Requirement | Where | Why |
| - | - | - |
| Salesforce or HubSpot connected | **Settings** → **Integrations**. See [Salesforce](/settings/integrations/salesforce) and [HubSpot](/settings/integrations/hubspot). | The trigger watches your deals, and **Update Record** writes the owner. |
| Slack connected | **Settings** → **Integrations**. See [Slack](/settings/integrations/slack). | The Slack nodes need it. Connecting needs admin access. |
| A customer success queue | **Routing** → **Queues**, with a policy whose **Assignment Units** include **Objects**. See [Queues](/queues) and [Policies](/policies). | **Round-Robin** picks the CSM from this queue and counts each owner write as an assignment. |
| Each CSM and rep mapped | **Settings** → **Users**, on the **Mappings** tab. See [Users](/settings/users). | Default turns **Latest assigned user** into a Salesforce user, a HubSpot owner, and a Slack user through these mappings. |
| A kickoff event | **Scheduling** → **Event Types**. See [Events](/events). | The kickoff is booked on it. |

## Build the handoff workflow

This example uses Salesforce. The HubSpot differences follow the steps.

<Steps>
  <Step title="Trigger on Closed Won">
    In **Workflows**, create a workflow and add the **CRM Record Updated** trigger. Set **CRM** to
    **Salesforce** and **Record** to **Opportunity**. Under **Condition**, add `Stage` **equals**
    `Closed Won`, and **Fields Updated** **contains any of** `Stage`, so the workflow runs when a
    deal moves to Closed Won and not on every later edit of a won deal. To leave out renewals and
    upsells, add a condition on a field such as the Opportunity's `Type`.
  </Step>

  <Step title="Find the Account">
    Add **Match Record**. Set **CRM** to **Salesforce** and **Record** to **Account**, and under
    **Match Details**, match the Account's `Account ID` to the Opportunity's `Account ID` from the
    trigger. Build the next steps on the **Match** branch.
  </Step>

  <Step title="Pick the CSM">
    Add **Round-Robin** and set **Queue** to your customer success queue, for example
    `Customer Success`. To choose the queue by segment or region instead, use a
    [Rules of Engagement](/rules-of-engagement) node, and use **Latest resolved user** wherever
    these steps say **Latest assigned user**.
  </Step>

  <Step title="Write the CSM to the Account">
    Add **Update Record**. Set **Platform** to **Salesforce**, **Record Type** to **Account**, and
    **Record to update** to the Account from **Match Record**. In **Fields**, set **Owner ID** to
    **Latest assigned user**.
  </Step>

  <Step title="Open a channel for the account">
    Add **Create Slack Channel**. In **Channel Name**, type `cs-` and insert the Account's name with
    `{{`. Turn on **Make Channel Private?** to keep the channel to invited members. Optionally, set a
    **Topic**, such as the deal's close date.
  </Step>

  <Step title="Add the CSM and the rep">
    Add **Add Member to Slack Channel**. Set **Slack Channel** to **Latest Created Slack Channel**.
    In **Internal Members**, pick **Latest assigned user** and the Opportunity's owner from the
    trigger. Default converts each of them to their Slack user. To invite someone from the customer
    as a guest, add their email under **External Members**.
  </Step>

  <Step title="Post the deal context">
    Add **Send Slack Message** and set **Slack channels** to **Latest Created Slack Channel**. In
    **Message**, type `@` to mention **Latest assigned user**, and type `{{` to insert the
    Opportunity's name, `Amount`, `Close Date`, and `Next Step`. End with the ask, for example
    "Please send the customer your kickoff link."
  </Step>

  <Step title="Add a kickoff task (optional)">
    Add **Create Activity** with **CRM** set to **Salesforce** and **Type** set to Task. In
    **Fields**, set the subject, a due date, and the owner to **Latest assigned user**. Set
    **Associated record (optional)** to the Account from **Match Record**.
  </Step>

  <Step title="Test and publish">
    Select **Test**, fill in the **Test payload** with a test Opportunity's real values, including
    the ID of a test Account. Set `StageName` to `Closed Won` and add `"StageName"` to
    `fieldsUpdated`, because the test checks the trigger's **Condition** first. Then select
    **Run Test**. Check the Account owner in Salesforce and the
    new channel in Slack. Then select **Publish** and check that the status next to the
    [deployment switch](/workflows#the-deployment-switch) reads **Live**. A new workflow goes live
    when you first publish it. If the status reads **Paused**, turn the switch on.
  </Step>
</Steps>

<Warning>
  A test performs real actions. It changes the Account owner, counts the assignment in the queue,
  creates the Slack channel, and posts the message. Use a test Account and a channel you can
  archive.
</Warning>

Default lowercases the channel name, turns spaces into hyphens, drops every character other than
letters, numbers, hyphens, and underscores, and keeps the first 80 characters. Slack channel names
are unique per workspace, so a second deal with the same account fails to create the same channel.
See [Notification nodes](/workflows/steps-notifications#create-slack-channel).

### Write the CSM to the owner field

The queue counts an assignment only when **Update Record** writes **Latest assigned user** to a
standard owner field: **Owner ID** on a Salesforce Account, or `Company owner` on a HubSpot Company.
Each counted write shows in **Routing** → **Assignments**, on the **Object assignments** tab.

If your rep stays the Account owner and you keep the CSM in a custom user field, such as a
Salesforce lookup to User or a HubSpot user property, the workflow still writes the CSM there. The
queue doesn't count that write, though, so the counts never change and the same CSM can win every
time. Write the CSM to the owner field when the queue should take turns.

## Salesforce and HubSpot differences in the handoff

| | Salesforce | HubSpot |
| - | - | - |
| Trigger **Record** | **Opportunity** | **Deal** |
| Closed won condition | `Stage` **equals** `Closed Won`, plus **Fields Updated** **contains any of** `Stage` | `Deal Stage` is your closed won stage, plus **Fields Updated** **contains any of** `Deal Stage`. Each HubSpot pipeline has its own closed won stage, so add each one you use. |
| Finding the account | **Match Record** on **Account**, matched on the Opportunity's `Account ID` | **Match Record** on **Company**: turn on **Match by association**, set **Source record type** to **Deal**, and set **Source record** to the Deal from the trigger |
| Owner field to write | **Owner ID** on the Account | `Company owner` on the Company |
| The rep to add to Slack | The Opportunity's owner | The Deal's owner |
| Kickoff task | **Create Activity** with **Type** set to Task | **Create Engagement** with **Engagement type** set to Task, and **Associated record type** set to **Company** |
| When the workflow starts | Salesforce sends changes to Default as they happen | Default checks HubSpot for changes every few minutes |
| Mapping each person needs | Salesforce User ID and Slack User ID | HubSpot Owner ID and Slack User ID |

## Book the kickoff meeting

The handoff workflow can't book the kickoff by itself. **Send Internal Email** reaches only people
in your Default workspace, and a **Display Scheduler** node shows a booking page to someone booking
right then, which a closed-won update doesn't have. Book the kickoff in 1 of these ways:

| Option | Who acts | How |
| - | - | - |
| The CSM sends their booking link | The CSM | In **Scheduling** → **Event Types**, a host's own booking link shows below each event they host. The CSM copies it and sends it to the customer. See [Booking links](/events#booking-links). |
| The rep books on the CSM's calendar during the closing call | The rep | The Chrome extension runs a kickoff workflow that shows the CSM's calendar. See the steps below. |
| A meeting already booked with the rep moves to the CSM | The rep or an admin | **Reassign** the meeting to the CSM by name. The rep leaves the invite, and the customer gets a new invite from the CSM. See [Reassign a booked meeting](/scheduling/rep-handoffs#reassign-a-booked-meeting-to-another-rep). |

### Book the kickoff from the Chrome extension

<Steps>
  <Step title="Build the kickoff workflow">
    An admin creates a workflow with the **Extension** trigger, then adds **Match Record** that finds
    the customer's Account from their email, for example with the **domain matches** operator on
    the Account's website. See
    [Match an account by company domain](/workflows/steps-crm#match-an-account-by-company-domain).
  </Step>

  <Step title="Show the CSM's calendar">
    On **Match**, add **Display Scheduler** with your kickoff event. Turn off **Use event hosts** and
    set the host to the matched Account's owner, which the handoff workflow set to the CSM. On
    **No Match**, add a **Display Scheduler** that keeps **Use event hosts** on, so the rep can still
    book. Publish the workflow.
  </Step>

  <Step title="Book on the call">
    After the deal is Closed Won and the handoff workflow has run, the rep loads the customer's email
    in the [Chrome extension](/chrome-extension), selects **Book a meeting with**, picks the kickoff
    workflow, and selects **Submit**. The booking page shows the CSM as the **Host** and adds the rep
    under **Additional hosts**. The rep picks a time with the customer and selects **Confirm**.
  </Step>
</Steps>

**Test** isn't available for workflows that start from the **Extension** trigger, so try the kickoff
workflow from the extension with a test contact. Once the kickoff is booked, the confirmation and
reminders you set on the event go out. See [Messages](/scheduling-messages).

## What to expect after a deal closes

* **Salesforce handoffs start first.** Salesforce sends changes to Default as they happen. Default
  checks HubSpot every few minutes, so HubSpot handoffs start a little later.
* **Each move to Closed Won starts 1 run.** A deal that is reopened and closed again starts another
  run, which picks a CSM again and tries to create the same channel again.
* **The run log shows every step.** Select **Runs** at the top of the workflow and open the run.
  **Round-Robin** shows who it picked, and the Slack nodes show who they added. See
  [Run logs](/workflows/run-logs).
* **The CRM and Slack match.** The Account or Company owner is the CSM, and the channel has the CSM,
  the rep, and the deal message.

## Troubleshoot the handoff workflow

| What you see | What to check |
| - | - |
| The workflow never starts | Check that the status reads **Live**, that the **Condition** uses your exact closed won stage, and that **Fields Updated** names the stage field. A deal created already in Closed Won doesn't start it, because the trigger fires on changes to existing records. |
| **Round-Robin** fails because the queue has no active members | Turn the queue on and add active members in **Routing** → **Queues**. |
| **Update Record** fails for the CSM | Map the CSM's Salesforce user or HubSpot owner in **Settings** → **Users**. |
| The same CSM gets every account | Write the CSM to the owner field, and check that the queue's policy includes **Objects** in **Assignment Units**. See [Write the CSM to the owner field](#write-the-csm-to-the-owner-field). |
| **Create Slack Channel** fails | A channel with that name already exists, often from an earlier deal with the same account. Add something unique to **Channel Name**, such as the Opportunity's name, or limit the trigger to new business. |
| **Add Member to Slack Channel** skips a person, or fails | Map each person's Slack user in **Settings** → **Users**. The node fails only when it adds nobody. |

Related: [Sales workflow software from Default](https://www.default.com/product/sales-workflow-software)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.