To create a fully custom automation, you can build a flow from scratch:
- On your computer, go to https://studio.workspace.google.com and click New flow
.
- Click the Starter to choose which event or schedule will launch your flow.
- Click Choose a step and select the task the flow will perform.
- At the top of the page, click the pencil
to name your flow.
- Optional: Before you turn on your flow, to make sure it works properly, click Test run
Start.
- This runs the flow immediately so you can verify the output.
- If everything works fine, you get a "Run Completed" message.
- After you complete your edits, click Turn on.
Every flow has 2 main parts:
- Starter: This is the event that starts your flow. A starter can be a schedule, like “every Friday at 5 PM,” or an event, like to receive a new email with an attachment. Each flow has only one starter.
- Steps: These are the tasks the flow performs after it starts. You can add multiple steps to a flow. A step could be:
- “Draft a reply.”
- “Notify me in Chat.”
Tip: Variables are placeholders for information from your starter or previous steps. They let you create dynamic and powerful flows.
- For example, you can use a variable to insert the subject line of an email from your starter into a Google Chat message step. Learn how to use variables to pass data in your flow.
Build your flow from scratch with an example
In this example, you'll create a flow from scratch that automatically drafts a reply in Gmail whenever you receive an email that contains the word 'Invoice'.
Step 1: Choose your starter
- On your computer, go to studio.workspace.google.com
click New flow
.
- Click Choose a starter
When I get an email. This tells the flow when to begin.
- On the right of the configuration panel, under "Which messages to check," select Specific emails.
- Find the "Has the words" field.
- Enter:
Invoice- This tells the flow to run only when an email contains the word "Invoice" in its subject or body.
For a full list of all available starters and steps, go to Guide to Starters and Steps in Workspace Studio.
Step 2: Add a step
- Below your starter, click Choose a step.
- Under the "Gmail" category, select Draft a reply.
Step 3: Use variables to create a dynamic message
- On your "Draft a reply" step, click inside the Message field.
- Enter:
Hello, - Press Enter for a new line and type:
I received the invoice regarding: - Click Variables +
Step 1: When I get an email
Email subject.
- Press Enter.
- Type:
I will review it and get back to you.-
Your message should look like this:
Hello,I received the invoice regarding:[Email subject]I will review it and get back to you.
-
- When your flow runs, it automatically replaces the variable chips with the actual details from the email. Learn more about using variables.
Step 4: Name, test & turn on your flow
- At the top of the page, click the pencil
to name your flow.
- At the bottom, click Test run.
- A new window will show that allows you to select a recent email from your inbox that matches your starter conditions to test the flow with.
- In the "Email received" field, enter:
Invoice-
This finds recent emails that match your starter conditions.
-
-
Select an email.
- Click Start.
- If everything works fine, you get a "Run Completed" message and should find a new draft email in your Gmail Drafts folder.
- When you're finished, click Turn on.
You've now built a smart and custom flow from scratch that filters your email and keeps your team informed in real time.