How to Create a Custom AI Agent Workflow for Your Business in 2026

4/6/2026

#AI Agents#Tutorial#Automation#Google#SEO#No-Code
How to Create a Custom AI Agent Workflow for Your Business in 2026

If you have ever spent your Monday morning pulling data from Google Search Console, copying numbers into a spreadsheet, writing a summary, and emailing it to your team — you are the perfect candidate for an AI agent.

An AI agent is an automated program that connects to your tools, runs on a schedule, and handles tasks that would otherwise eat up hours of your week. In this guide, I will walk you through building a custom AI agent workflow from scratch using Embeddable's AI Agent Builder, step by step.

By the end, you will have a working agent that connects to Google services, runs on your schedule, and delivers results to your inbox automatically.

Want to skip the setup and get started immediately? Use our free Weekly SEO Audit agent template — it connects to your Google Search Console, pulls your data, and emails you a weekly report. Just click "Use This Template" and connect your Google account.

What You Will Build

We will build a Weekly SEO Digest Agent that:

  1. Connects to your Google Search Console account
  2. Pulls keyword data, clicks, impressions, and position data
  3. Compares this week vs. last week and this month vs. last month
  4. Uses AI to generate insights and recommendations
  5. Sends a formatted email report to you every Monday morning

This is one of the most popular agent use cases, but the same principles apply to any workflow — analytics monitoring, spreadsheet automation, calendar management, email processing, and more.

Prerequisites

  • A free Embeddable account
  • A Google account with Search Console access (for this example)
  • About 10 minutes

No coding knowledge is required. The AI builds the code for you.

Step 1: Create a New Agent

Navigate to your Embeddable dashboard and switch to Agent Mode using the toggle at the top. Click the prompt textarea and describe what you want:

Build an agent that connects to my Google Search Console,
pulls weekly SEO data, and emails me a digest every Monday
at 9 AM with AI-generated insights about my rankings.

The AI will start building your agent. It will:

  • Suggest a name for your agent (e.g., "SEO Weekly Insights Digest")
  • Ask clarifying questions using interactive buttons in the chat
  • Prompt you to connect required Google services

Step 2: Connect Your Google Services

When the AI detects your agent needs Google Search Console access, it will show an inline Connect button directly in the chat. This is the OAuth flow — click the button, select your Google account in the popup, grant the requested permissions, and you are done.

You can also manage connections later from the Connectors tab in the agent editor sidebar.

Supported Google Integrations

ServiceWhat Agents Can Do
Google Search ConsoleRead keyword rankings, clicks, impressions, CTR, position data
Google AnalyticsPull traffic reports, user behavior data, conversion metrics
GmailRead and send emails programmatically
Google SheetsRead and write spreadsheet data
Google CalendarCreate events, read schedules, add Meet links
Google DriveAccess and manage files

Each service requires a one-time OAuth connection. Once connected, the agent can access it on every run.

Step 3: Configure Secrets (If Needed)

Some agents need API keys for external services. When the AI generates code that requires a secret, it will show a secure input field in the chat where you can paste the key.

For our SEO digest, we do not need any API keys — the Google OAuth connection and built-in email delivery handle everything. But if you were building an agent that calls a third-party API (like OpenAI, Slack webhooks, or a custom endpoint), you would configure secrets here.

Secrets are encrypted at rest and accessible in the agent code via process.env.SECRET_NAME. You can manage them from the Secrets tab in the agent editor.

Step 4: Test with Run Now

Once the AI finishes building your agent, click the Run Now button to execute it immediately. The run trace shows every step in real time:

Starting agent execution...
Loaded functions/main.ts (5,240 chars)
Loaded 2 connector tokens: GOOGLE_SEARCH_CONSOLE_ACCESS_TOKEN, GOOGLE_ACCESS_TOKEN
Executing agent function...
[tool] google.searchConsole.listSites()
[tool] google.searchConsole.query(site: sc-domain:example.com, 2026-03-31 → 2026-04-06)
[tool] google.searchConsole.query(site: sc-domain:example.com, 2026-03-24 → 2026-03-30)
[ai] generate(prompt: "Analyze this SEO data...")
[tool] email.send(to: [email protected], subject: "Weekly SEO Digest")
Completed in 12.4s | Tokens used: 1,847

Check your inbox — the report should be there within seconds.

If something goes wrong, the run trace shows exactly where the error occurred. Common issues include missing OAuth connections (connect in the Connectors tab) or incorrect email addresses in the code (ask the AI to update it).

Step 5: Schedule Your Agent

Once the test run succeeds, set up a recurring schedule. Go to the Schedule tab and create a new automation:

  • Type: Schedule
  • Cron: 0 9 * * 1 (every Monday at 9 AM UTC)
  • Timezone: Your timezone

The agent will now run automatically every Monday morning. You will see run history, status, and logs in the Runs tab.

Common Schedules

ScheduleCron ExpressionUse Case
Every Monday at 9 AM0 9 * * 1Weekly reports
Every day at 8 AM0 8 * * *Daily monitoring
Every hour0 * * * *Real-time alerting
First day of month0 9 1 * *Monthly summaries

Step 6: Trigger via API (Optional)

Every agent gets a unique API endpoint for external triggering. Go to the API tab to find your trigger URL:

curl -X POST https://embeddable.co/api/ai/trigger-agent/YOUR_AGENT_ID \
  -H "x-api-key: YOUR_API_KEY"

This is useful for:

  • Triggering agents from CI/CD pipelines
  • Running agents in response to webhook events
  • Integrating agents into your own applications

More Agent Ideas

The SEO digest is just one example. Here are other popular agent workflows you can build:

Data Monitoring

  • Traffic drop detector — Checks Google Analytics daily, alerts you if traffic drops more than 20%
  • Competitor price tracker — Scrapes competitor websites and emails you when prices change
  • Uptime monitor — Pings your website every 5 minutes and sends alerts on downtime

Reporting

  • Monthly analytics summary — Pulls GA4 data and generates a board-ready report
  • Google Sheets digest — Reads sales data from a spreadsheet and emails weekly summaries
  • Keyword position tracker — Monitors your top 50 keywords and flags position changes

Productivity

  • Meeting prep agent — Reads your Google Calendar, researches attendees, emails you a brief
  • Email digest — Scans Gmail for important messages and sends a daily summary
  • Content calendar — Creates Google Calendar events from a spreadsheet content plan

Notifications

  • Hacker News digest — Scrapes top stories, filters by topic, emails you a curated feed
  • Review monitor — Watches for new Google Reviews and notifies your team
  • Form submission alerter — Sends formatted notifications when forms are submitted

Browse our agent templates for ready-to-use starting points.

Tips for Building Better Agents

Start simple. Build the core workflow first, then add complexity. A basic "fetch data and email report" agent is more valuable running today than a perfect multi-step workflow that never ships.

Use built-in email. The tools.email.send() function works on every run without any setup. Avoid using Gmail for sending unless you specifically need to send from a personal Gmail address.

Test with Run Now first. Always verify your agent works manually before scheduling it. The run trace shows exactly what happened and where errors occur.

Use memory for state. If your agent needs to remember something between runs (like the last processed date), use ctx.memory.set() and ctx.memory.get(). Memory persists across runs.

Keep secrets in the Secrets tab. Never hardcode API keys in your agent code. Use process.env.SECRET_NAME and store values in the encrypted Secrets tab.

Troubleshooting

"OAuth token not found" — The service is not connected. Go to the Connectors tab and connect it.

"Insufficient scope" — The OAuth connection was made with old permissions. Disconnect and reconnect the service to get updated scopes.

Agent runs but email does not arrive — Check that the email address is correct in your code. Also check your spam folder. The built-in email uses Resend, which has high deliverability.

Run times out — Agents have a 10-minute execution limit. If your workflow is complex, try breaking it into smaller steps or reducing the data volume.

What is Next

You now have a working AI agent that connects to Google services, processes data with AI, and delivers results on a schedule. The same pattern works for any automated workflow — change the data source, the processing logic, and the output destination to match your needs.

Ready to build? Start with the SEO template or create your agent from scratch.