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

# Create a Flow and Add Trigger Rewards

*Learn how to create a flow in Salesforce.*

# Creating a Flow in Salesforce for Xoxoday Plum Reward Automation

Before you get into creating your flows, you need to Create a Campaign and automation in Xoxoday Plum, Add the Xoxoday Refresh widget, and refresh it, to have all your old and new automation synced in.

​Step 0: Once you have added the widget, click\*\*"Refresh".**​Step 1: On the homepage, Go to Navbar->Select Setup and Click**"Setup"**​Step 2: On the Setup Dashboard, Search for "Flows" under Process Automation and Click**"New Flow".**​Step 3: Now select the template type and Configure the Start Trigger Settings, Under Object: Select Lead/Contact and Click**"done".\*\* \*\*​

<img src="https://mintcdn.com/plum/zXbsSEper5I-0r-9/images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/spaces_-MOeXh7erUO5h_LVpN85_uploads_wTWpcH3RuhFjzPdPUPee_Screenshot_2022-08-09_at_3.jpg?fit=max&auto=format&n=zXbsSEper5I-0r-9&q=85&s=ac51511ee0f19d21cb4d5db5d2fa7f85" alt="" width="2880" height="1520" data-path="images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/spaces_-MOeXh7erUO5h_LVpN85_uploads_wTWpcH3RuhFjzPdPUPee_Screenshot_2022-08-09_at_3.jpg" />

Step 4: **Now next step would be to add a new element: from options select**"Create records".\*\* \*\*​

<img src="https://mintcdn.com/plum/zXbsSEper5I-0r-9/images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_11_04_PM.png?fit=max&auto=format&n=zXbsSEper5I-0r-9&q=85&s=3602dc56e399db451de120ab71e72a10" alt="" width="2880" height="1519" data-path="images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_11_04_PM.png" />

​Step 5: Edit the Create Records settings and under object look for "XoxodayRewardFlowAutomations" and then Click "Done".\*\* (refer to above image)

​Step 6: Now add another element and Select "\*\*Get Records".\*\*​Step 7: Edit the Get Records settings and under object look for "XoxodayRewardFlowAutomations" Once done, "Filter XoxodayRewardFlowAutomations Records" has to be updated. - In fields select "id" - In Values look for "Record (single) variables" ->Select your Xoxoday automation->Select "ID".​

<img src="https://mintcdn.com/plum/zXbsSEper5I-0r-9/images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_39_55_PM.png?fit=max&auto=format&n=zXbsSEper5I-0r-9&q=85&s=4e6fe0581cfa4cc7409b99bf35f243a7" alt="" width="2880" height="1522" data-path="images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_39_55_PM.png" />

Step 8: **Now the element that has to be added is "Action":** Add element->Select Action->Uncategorised-> Action name: Xoxoday Plum Reward API.

<img src="https://mintcdn.com/plum/zXbsSEper5I-0r-9/images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_29_29_PM.png?fit=max&auto=format&n=zXbsSEper5I-0r-9&q=85&s=d6ecc7ea4c83fd6a90741dd13c195116" alt="" width="2880" height="1518" data-path="images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_29_29_PM.png" />

**Step 9:** Update Input fields as per your flow (refer below image)

<img src="https://mintcdn.com/plum/zXbsSEper5I-0r-9/images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_32_39_PM.png?fit=max&auto=format&n=zXbsSEper5I-0r-9&q=85&s=e6956832972afe88ad5426a77708e48b" alt="" width="2880" height="1515" data-path="images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_32_39_PM.png" />

<img src="https://mintcdn.com/plum/zXbsSEper5I-0r-9/images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_36_39_PM.png?fit=max&auto=format&n=zXbsSEper5I-0r-9&q=85&s=b077b088934a4af49f91b720431428b0" alt="" width="2880" height="1519" data-path="images/intercom/help-center-integrations-salesforce-create-a-flow-and-add-trigger-rewards-9414475/Screenshot_2022-08-09_at_6_36_39_PM.png" />

Step 10: Now "Save" your flow and **Activate** it.
