Automatically categorize your Calendly events in Salesforce


You can customize your Salesforce flow to automatically categorize your Calendly events within Salesforce. For example, you may want to categorize your meetings by department, goal, or function, such as customer engagement or onboarding. Categorizing your meetings can be helpful for reporting.

How categorization works

Once you modify your Salesforce flow and add custom fields, the flow can automatically categorize a  scheduled meeting based on the Calendly URL slug used to schedule with. Your URL slug is the last part of your Calendly link, which identifies your event type. 

How to map Salesforce fields based on your Calendly link

In the following steps, we'll categorize meetings by Meeting Type and Meeting Subtype, as examples. We'll create custom fields for these categories on the Activity object for use as Event records. We'll then assign the URL slug as the value for the Meeting Type and Meeting Subtype fields. 

The following table shows how you can use your unique slug to categorize by Meeting Type and Meeting Subtype.

Calendly event type URL Slug Meeting Type Meeting Subtype pricing-review Customer Engagement Customer meeting account-overview Customer Engagement Customer meeting discovery-call Lead Engagement Welcome/kickoff meeting 30-minute-demo Lead Engagement Demo


Step 1: Create custom fields

  • Before you begin, be sure your event object has the needed fields created (Meeting Type and Meeting Subtype).
    • Custom fields for Tasks and Events must be created at the Activity level. If you are unsure how to create fields on the event object, you can refer to this Salesforce article.

Step 2: Open your flow

  1. In Salesforce Setup, search for Flows. Select Flows.
    • If you haven't customized the CreateEventTemplate before, you'll need to create a new flow based on the template. To do so, open the CreateEventTemplate, customize it directly, then Save as. Saving it will create a new flow. You can call the new flow something like "CreateEvent."
    • If you've already customized the CreateEventTemplate flow, then open your customized flow.

Step 3: Add a Decision element and create Outcomes

  1. From the Toolbox on the left-hand side, drag a Decision element and place it next to the Decision, Do We Have a Record? element. 

  2. Set the Label to something like "What event was scheduled?" You can also add details to the Description, if you'd like. 

  3. Add an Outcome.

  4. Under Outcome details, set the Label to your Meeting Subtype names, or use a label that helps you identify which event type was scheduled. For example, you could set the label to something like "Onboarding Meeting.” Once you add a label, the Outcome API Name will automatically populate.

  5. Add the following conditions: 
    Outcome 1: 
    Resource = {!$Record.Calendly__EventTypeSlug__c}
    Operator = Equals
    Value = insert your Calendly slug, for example, pricing-review
    Note: See above table for examples of your Calendly slug. 

  6. Add an Outcome for each meeting subtype you'd like to use.

Step 4: Create Resources for Meeting Types and Subtypes

  1. From the Toolbox on the left-hand side, switch to the Manager tools, and select New Resource.

  2. At Resource Type, select Variable.

  3. At API Name, enter Meeting Type.

  4. At Data Type, select Text.

  5. Select Done.

  6. Repeat these steps to create a Resource for Meeting Subtype.Meeting_Type_Resource.png

Step 5: Add Assignment elements

  1. Next to the new Decision element you created in Step 2, add an Assignment element to the right.

  2. At Label, enter a name similar to the corresponding Outcome label you created, such as "Onboarding Kickoff Meeting." The API name will automatically populate.

  3. At Set Variable Values, enter the following:
    Variable = {!MeetingType}
    Note: This references the resource you created in Step 3.
    Operator = Equals
    Value = your_meeting_type_here

  4. Select + Add Assignment

  5. At Set Variable Values enter the following:
    Variable = {!MeetingSubtype}
    Note: This references the resource you created in Step 3.
    Operator = Equals
    Value = your_meeting_subtype_here

  6. Select Done.

  7. Repeat these steps for each Outcome option you created in Step 2.

Step 6: Map your custom fields 

For more details on field mapping, view Choose how to map Calendly data to Salesforce fields.

  1. Select the Create Event element.

  2. Select + Add Field from the bottom of the existing field mappings.

  3. At Field enter Meeting_Type__c referencing your custom field.

  4. At Value enter {!MeetingType} referencing the resource you created in Step 3.

  5. Select + Add Field to add another field mapping.

  6. At Field enter Meeting_Subtype__c referencing your custom field.

  7. At Value enter {!MeetingSubtype} referencing the resource you created in Step 3.

  8. Select Done.

Step 7: Connect the elements

  1. Connect the Decision element to the Assignment elements and select the matching Outcome.

  2. Connect the Assignment elements to the Create Event element. 

  3. Save and Activate the flow.
    Note: If you have not previously made any modifications to the CreateEventTemplate, you may only see the option to Save As. In this case, Save As and give the flow a title. Then, Deactivate the CreateEventTemplate flow.

Final results

When you book a meeting through your Calendly link, you should see the Meeting Type and Subtype (or whichever fields you created) mapped to the Event!