Skip to main content
Join the Agentforce Hackathon on Nov. 18-19 to compete for a $20,000 Grand Prize. Sign up now. Terms apply.
予想時間

Use Your Flow

Create Test Contacts, Engagements, and a Cohort

Finally, it’s time to put our flow to work!

Your Trailhead Playground trial of PMM includes helpful example data, but for this project we create two new test contacts, each with a program engagement, and add them to a new program cohort to test our flow.

We enter your email address for both of the test contacts. This way we know that the flow will send an email, but no one will receive it but you.

Let’s create the first test contact.

  1. Find and select Programs from the App Launcher ().
  2. Switch to the All list view and click Remedial Reading Program.
  3. Click the Add Contact to Program quick action.
  4. In the Client field, select + New Contact then enter these details:
    • First Name: Brock
    • Last Name: Biagini
    • Email: Enter your email address, but add +pmmflowtest1 before the @ symbol. For example, bbiagani+pmmflowtest1@example.com.
    • Click Save.
  1. In the Role field, select Client.
  2. In the Stage field, select Active.
  3. In the Program Cohort field, select + New Program Cohort then enter these details:
    • Program Cohort: PMM Flow Test
    • Status: Active
    • Program: Remedial Reading Program
    • Click Save.
  1. Click Save.

Now, let’s create our second test contact.

  1. On the Remedial Reading Program record, click Add Contact to Program again.
  2. In the Client field, select + New Contact then enter these details:
    • First Name: Aaron
    • Last Name: Yount
    • Email: Enter your email address, but add +pmmflowtest2 before the @ symbol. For example, ayount+pmmflowtest2@example.com.
    • Click Save.
  1. In the Role field, select Client.
  2. In the Stage field, select Active.
  3. In the Program Cohort field, select PMM Flow Test.
  4. Click Save.

Send the Email

It’s time to test the flow! (Drum roll, please.)

  1. In Global Search, find and select our cohort PMM Flow Test.
  2. Check that there are two program engagements listed in the Program Engagements related list. Both should have a Stage value of Active.
  3. Click the Email Program Participants quick action.

  4. Our confirmation message should appear. Click Finish.

Note that each time you press the button in this flow, it sends an email to every active participant in the cohort. (Read on for ideas on how to prevent duplicate sends.)

Check Your Inbox

Go to the inbox of the email address you used in our test contact records. You should have received two emails, one for Brock Biagini and another for Aaron Yount.

Two messages in an inbox

Also, be sure to open your email to make sure that your name and email address appear at the bottom. The merge fields and other settings we selected should populate the signature with the information of the user who starts the flow.

An example of the email in the inbox

Let’s pause and remember the logic of our Get Records element here: It was looking for program engagements with a Stage value of Active that were associated with the program cohort where the button was activated. If you were to go back to one of our new program engagement records and change the Stage to anything but Active, then press the quick action again, only one email would be sent. If you’re testing a flow on your own, you can set up a contact in each Stage before your first send to see how every field value works with the flow.

Ideas for Building on This Flow

This flow was a simple example to get you used to using email templates and flow to send a message to your program participants. Using this flow as a base, you can experiment to create amazing flows that help your users better deliver your services.

We don’t expect you to build these in this project, but here are some ideas for you to experiment with.

  • Change the filter on the Get Records element to look for program engagements with a status of Withdrawn and set up a template email directing program participants to register for another session.
  • Create a new field on the program engagement record and use an Update Records element in flow to record when a program participant has been sent a welcome email. Update your filter to exclude any program engagement that has already been welcomed. No more duplicate messages!
  • Use Decision and Screen elements in flow to allow your users to choose from several different email templates to send.
  • Create a new schedule-triggered flow to send a batch of welcome emails to all new program engagements in a particular program, using much of the logic we used in this project.

What else can you think of? If you’d like help, or to share what you’ve learned, join the Program Management Module (PMM) group in the Trailblazer Community. We added the link in Resources.

With this foundation in building flows for PMM, you have what you need to start building on your own. 

Be sure to click Verify to check your work on this last step.

Good luck and have fun! 

Resources

Salesforce ヘルプで Trailhead のフィードバックを共有してください。

Trailhead についての感想をお聞かせください。[Salesforce ヘルプ] サイトから新しいフィードバックフォームにいつでもアクセスできるようになりました。

詳細はこちら フィードバックの共有に進む